/*
Theme Name: Nordic Essence
Theme URI: https://example.com/
Author: Your Name
Author URI: https://example.com/
Description: A simple custom theme for a company site.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nordicessence
*/

html {
    height: 100%;
}

body {
    margin: 0;
    font-family: 'Roboto', Arial, sans-serif;
    background: #fff;
    color: #222;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', Arial, sans-serif;
}

p {
    font-family: 'Roboto', Arial, sans-serif;
    font-weight: 100;
}

.site-header {
    background: #fff;
    color: #222;
    padding: 10px 0;
    text-align: left;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    margin: 0;
    padding: 0 24px;
    box-sizing: border-box;
}

.company-row {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
}

.site-navigation .verkkokauppa-link,
.site-navigation .verkkokauppa-link:visited {
    color: #ac9273;
    margin-left: 16px;
}

.site-title-link,
.site-title-link:hover,
.site-title-link:visited {
    text-decoration: none;
    color: inherit;
}

.site-title {
    font-size: 2.2rem;
    font-weight: 600;
    font-family: 'Roboto', Arial, sans-serif;
    letter-spacing: 2px;
}

.site-slogan {
    font-size: 0.65rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    color: #555;
    margin-top: 2px;
    margin-bottom: 0;
}

.site-navigation {
    margin-left: auto;
    display: flex;
    gap: 24px;
}

.site-navigation li {
    list-style: none;
}

.site-navigation a {
    color: #222;
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    text-transform: uppercase;
    transition: color 0.2s;
}

a {
    font-family: 'Montserrat', sans-serif;
}

.site-navigation a:hover {
    color: #dbd2c4;
}

.site-navigation a.current-menu-item,
.site-navigation a.current_page_item {
    color: #ac9273;
}

.site-content {
    width: 100%;
    margin: 0px;
    padding: 0px;
    min-height: 400px;
    background: #fff;
}

.site-content--padded {
    padding: 0 40px;
    box-sizing: border-box;
}

/* Custom block style: Purple Large */
.is-style-purple-large,
.is-style-purple-large a {
    font-size: 44px;
    color: #bea5e6;
}

.site-content {
    flex: 1;
}

.site-footer {
    background: #efebe5;
    color: #222;
    padding: 20px 0;
    font-size: 1rem;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin: 0;
    padding: 0 24px;
    box-sizing: border-box;
}

.footer-left {
    text-align: left;
}

.footer-right {
    text-align: right;
}

.footer-right a {
    color: #222;
    text-decoration: none;
    text-transform: uppercase;
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    transition: color 0.2s;
}

.footer-right a:visited {
    color: #222;
}

.footer-right a:hover {
    color: #dbd2c4;
}

/* Hamburger button */
.hamburger-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 28px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
}

.hamburger-btn span {
    display: block;
    width: 100%;
    height: 2px;
    background: #222;
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.hamburger-btn.is-open span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger-btn.is-open span:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.is-open span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Mobile menu overlay */
.mobile-menu {
    display: none;
    position: fixed;
    inset: 0;
    background: #fff;
    z-index: 999;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 24px;
}

.mobile-menu.is-open {
    display: flex;
}

.mobile-menu-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: none;
    border: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: #222;
    line-height: 1;
    padding: 0;
}

.mobile-menu-close:hover {
    color: #555;
}

.mobile-menu-logo {
    margin-top: 56px;
    margin-bottom: 36px;
}

.mobile-menu-logo img {
    width: 140px;
    height: auto;
    display: block;
    margin: 0 auto;
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-nav li {
    list-style: none;
}

.mobile-menu-nav a {
    font-size: 1.4rem;
    color: #222;
    text-decoration: none;
    font-family: 'Oswald', sans-serif;
    font-weight: 300;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: color 0.2s;
}

.mobile-menu-nav a:hover {
    color: #dbd2c4;
}

/* Responsive breakpoint */
@media (max-width: 1024px) {
    .hamburger-btn {
        display: flex;
    }

    .site-navigation {
        display: none;
    }
}

/* =============================================
   Product Catalog Grid
   ============================================= */

.catalog-intro {
    padding: 32px 24px 0;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 32px 24px;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

/* Each card */
.catalog-card {
    display: flex;
    flex-direction: column;
}

/* Square image wrapper */
.catalog-card__image-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    background: #f4f0eb;
}

.catalog-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: filter 0.35s ease;
}

/* Hover overlay */
.catalog-card__overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.78);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    opacity: 0;
    transition: opacity 0.35s ease;
}

.catalog-card__excerpt {
    color: #000;
    font-family: 'Roboto', Arial, sans-serif;
    font-weight: 400;
    font-size: 0.88rem;
    line-height: 1.55;
    text-align: center;
    margin: 0;
}

/* Hover state: blur image, reveal overlay */
.catalog-card__image-wrap:hover .catalog-card__img {
    filter: blur(5px) scale(1.04);
}

.catalog-card__image-wrap:hover .catalog-card__overlay {
    opacity: 1;
}

/* Title below the image */
.catalog-card__title {
    margin: 10px 0 0;
    font-family: 'Roboto', Arial, sans-serif;
    font-size: 0.95rem;
    font-weight: 400;
    text-align: center;
    color: #222;
}

.catalog-card__link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Responsive: 2 columns on tablet */
@media (max-width: 900px) {
    .catalog-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        padding: 24px 16px;
    }
}

/* Responsive: 1 column on small desktop/browser */
@media (max-width: 540px) {
    .catalog-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile devices: 2-column compact grid (device check, overrides above) */
.is-mobile .catalog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 16px 12px;
}

.is-mobile .catalog-card__title {
    font-size: 0.78rem;
}

.is-mobile .catalog-card__excerpt {
    font-size: 0.75rem;
}
