/* =========================================================================
   NERETVA ESPRESSO MACHINES - GLOBAL STYLESHEET
   Mobile-First, Premium, Minimalist
   ========================================================================= */

:root {
    /* Premium Coffee/Neutral Palette */
    --bg-color: #FAFAFA;
    --text-dark: #1A1A1A;
    --text-muted: #666666;
    --brand-primary: #C3996B;
    /* Soft gold/brass tone */
    --brand-primary-hover: #AB8156;
    --surface-light: #FFFFFF;
    --border-color: #E5E5E5;
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
    --header-height: 64px;
    --max-width: 1200px;
    --container: 1100px;
    --pad: clamp(16px, 4vw, 32px);
    --radius: 14px;
    --h1: clamp(1.7rem, 4.5vw, 2.8rem);
    --h2: clamp(1.3rem, 3.2vw, 2rem);
    --text: clamp(1rem, 1.2vw, 1.05rem);
    --lh: 1.55;
}

/* Base Reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

img {
    max-width: 100%;
    height: auto;
}

html {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--text-dark);
    line-height: 1.6;
    scroll-behavior: smooth;
}

body {
    font-size: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

h1 {
    font-size: var(--h1);
}

h2 {
    font-size: var(--h2);
}

h3 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1.2rem;
}

a {
    color: var(--brand-primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--brand-primary-hover);
}

/* Layout Utilities */
.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--pad);
}

.section {
    padding: 4rem 0;
}

.bg-white {
    background-color: var(--surface-light);
}

/* Header & Navigation */
.site-header {
    position: sticky;
    top: 0;
    background-color: var(--surface-light);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
}

.site-header .header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-dark);
    letter-spacing: -0.01em;
}

.nav-desktop {
    display: none;
}

.nav-desktop ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-desktop a {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 0.95rem;
}

.hamburger {
    display: block;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-dark);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background-color: var(--surface-light);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    z-index: 999;
    padding: 2rem 1.5rem;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu ul {
    list-style: none;
}

.mobile-menu li {
    margin-bottom: 1.5rem;
}

.mobile-menu a {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
}

/* Buttons */
.btn {
    display: inline-block;
    background-color: var(--brand-primary);
    color: #fff;
    padding: 0.875rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
    text-align: center;
    transition: background-color 0.2s;
    width: 100%;
    /* Mobile first */
}

.btn:hover {
    background-color: var(--brand-primary-hover);
    color: #fff;
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-dark);
}

.btn-outline:hover {
    border-color: var(--text-dark);
    background-color: var(--surface-light);
    color: var(--text-dark);
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 3rem 0;
    background-color: var(--surface-light);
}

.hero p.lead {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 2rem;
}

.hero-img-placeholder {
    width: 100%;
    max-width: 600px;
    height: 300px;
    background-color: #EFEFEF;
    border-radius: 8px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.model-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
    object-fit: contain;
}

/* Sticky Mobile CTA */
@media (max-width: 768px) {
    .sticky-cta {
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background: #b88b5e;
        text-align: center;
        padding: 14px 0;
        z-index: 9999;
        display: block;
    }

    .sticky-cta a {
        color: #ffffff;
        font-weight: 600;
        text-decoration: none;
        font-size: 1rem;
        display: block;
    }

    body {
        padding-bottom: 70px;
    }
}

@media (min-width: 769px) {
    .sticky-cta {
        display: none;
    }

    .sticky-cta-spacer {
        display: none;
    }
}

.sticky-cta-spacer {
    height: 80px;
    display: block;
}

.cta-button {
    display: inline-block;
    margin-top: 12px;
    padding: 14px 22px;
    background: #b88b5e;
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: background-color 0.2s ease;
}

.cta-button:hover {
    background-color: #9a724a;
}

.product-hero {
    margin-bottom: 40px;
}

.price-cta-box {
    background: #f5f5f5;
    padding: 20px;
    border-radius: 8px;
    margin: 24px 0;
}

.price-cta-box p {
    margin-bottom: 12px;
    font-weight: 500;
}

.summary-card {
    background: #ffffff;
    border: 1px solid #eee;
    padding: 24px;
    border-radius: 10px;
    margin-top: 32px;
}

.summary-card ul {
    margin-top: 16px;
}

.secondary-cta {
    background: #222;
}

/* Grid System */
.grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: 1fr;
}

.card {
    background: var(--surface-light);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
}

/* Footer */
.site-footer {
    margin-top: auto;
    background-color: #111;
    color: #CCC;
    padding: 3rem 0;
    font-size: 0.875rem;
}

.site-footer a {
    color: #FFF;
}

.footer-nav {
    list-style: none;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.disclaimer {
    font-size: 0.8rem;
    color: #888;
    margin-top: 2rem;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

/* Schema Breadcrumbs Visuals */
.breadcrumbs {
    font-size: 0.875rem;
    margin-bottom: 2rem;
    color: var(--text-muted);
}

.breadcrumbs a {
    color: var(--text-muted);
}

.breadcrumbs span {
    margin: 0 0.5rem;
}

/* Lists and Tables */
.content-list {
    list-style: disc;
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.content-list li {
    margin-bottom: 0.5rem;
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}

.comparison-table th,
.comparison-table td {
    border: 1px solid var(--border-color);
    padding: 1rem;
    text-align: left;
}

.comparison-table th {
    background-color: #F5F5F5;
    font-weight: 600;
}

/* FAQs */
.faq-item {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.5rem;
}

.faq-item h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* Desktop Overrides */
@media (min-width: 768px) {
    .section {
        padding: 5rem 0;
    }

    .hero {
        padding: 6rem 0;
    }

    .hamburger {
        display: none;
    }

    .nav-desktop {
        display: block;
    }

    .mobile-menu {
        display: none !important;
    }

    .grid-2 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }

    .btn {
        width: auto;
    }

    .sticky-cta,
    .sticky-cta-spacer {
        display: none;
    }

    .footer-nav {
        flex-direction: row;
        gap: 2rem;
    }
}

.brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.brand-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 14px;
    /* adds spacing between logo and text */
}

.brand-logo {
    max-height: 48px;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain;
    margin-right: 0;
    /* keep clean */
}

.brand-logo {
    margin-right: 14px !important;
    /* fallback if gap fails anywhere */
}

.brand-text,
.brand-name {
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
    color: var(--text-dark);
}

.main-nav ul {
    display: flex;
    gap: clamp(12px, 2vw, 22px);
    list-style: none;
    flex-wrap: nowrap;
}

.main-nav a {
    text-decoration: none;
    font-weight: 500;
}

.breadcrumbs {
    font-size: clamp(0.85rem, 2.2vw, 0.95rem);
    margin: 10px auto 0;
    max-width: var(--container, 1200px);
    padding-inline: var(--pad);
    opacity: 0.85;
}

.breadcrumbs a {
    text-decoration: none;
}

.breadcrumbs .sep {
    margin: 0 8px;
    opacity: 0.6;
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block !important;
    }

    table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap;
    }

    .hero,
    .models-grid,
    .cards-grid {
        display: block;
    }

    .hero h1 {
        margin-top: clamp(16px, 4vw, 24px);
    }

    .hero .cta-row {
        flex-direction: column;
        gap: 12px;
    }
}

.table-wrap,
table {
    width: 100%;
}

table {
    border-collapse: collapse;
}

th,
td {
    padding: clamp(10px, 2.5vw, 14px);
}

.nav-overlay {
    position: fixed;
    inset: 0;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-100%);
    transition: transform .35s ease;
    z-index: 1000;
}

.nav-overlay.is-open {
    transform: translateY(0);
}

.nav-overlay .main-nav {
    display: block !important;
}

.nav-overlay .main-nav ul {
    display: flex;
    flex-direction: column;
    /* CRITICAL */
    align-items: center;
    /* horizontal center */
    justify-content: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-overlay .main-nav li {
    margin: 18px 0;
}

.nav-overlay .main-nav a {
    font-size: clamp(1.6rem, 6vw, 2rem);
    font-weight: 600;
    color: #1a1a1a;
    text-decoration: none;
}

body.menu-open {
    overflow: hidden;
}

.nav-toggle {
    display: none;
    background: none;
    border: 0;
    cursor: pointer;
    position: relative;
    z-index: 1001;
    /* must be above overlay */
    padding: 8px;
}

.nav-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background: #111;
    /* force visible dark color */
    margin: 6px 0;
    border-radius: 2px;
    transition: .3s;
}

@media (min-width: 769px) {

    /* Overlay becomes inert container on desktop */
    .nav-overlay {
        position: static !important;
        inset: auto !important;
        background: transparent !important;
        transform: none !important;
        transition: none !important;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        z-index: auto !important;
        height: auto !important;
    }

    /* Desktop nav visible and horizontal */
    .nav-overlay .main-nav {
        display: block !important;
    }

    .nav-overlay .main-nav ul {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: clamp(14px, 2vw, 24px) !important;
        text-align: left !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .nav-overlay .main-nav li {
        margin: 0 !important;
    }

    .nav-overlay .main-nav a {
        font-size: 0.98rem !important;
        font-weight: 500 !important;
        color: inherit !important;
        text-decoration: none !important;
        letter-spacing: 0.2px !important;
    }

    /* Hamburger hidden on desktop */
    .nav-toggle {
        display: none !important;
    }

    /* Desktop must never lock scroll */
    body.menu-open {
        overflow: auto !important;
    }
}

@media (max-width: 768px) {

    /* Hide normal header nav in flow (overlay will show it) */
    .nav-overlay .main-nav {
        display: block !important;
        /* nav lives INSIDE overlay */
    }

    /* Fullscreen white overlay */
    .nav-overlay {
        position: fixed !important;
        inset: 0 !important;
        background: #ffffff !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        transform: translateY(-100%) !important;
        transition: transform .32s ease !important;
        z-index: 1000 !important;
    }

    .nav-overlay.is-open {
        transform: translateY(0) !important;
    }

    /* Vertical centered list, one item per line */
    .nav-overlay .main-nav ul {
        display: flex !important;
        flex-direction: column !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 18px !important;
        text-align: center !important;
        margin: 0 !important;
        padding: 0 !important;
        list-style: none !important;
    }

    .nav-overlay .main-nav li {
        margin: 0 !important;
        width: 100% !important;
    }

    .nav-overlay .main-nav a {
        display: block !important;
        width: 100% !important;
        font-size: clamp(1.35rem, 5.2vw, 1.9rem) !important;
        font-weight: 600 !important;
        color: #111 !important;
        text-decoration: none !important;
        padding: 6px 0 !important;
    }

    /* Hamburger visible + clickable above overlay */
    .nav-toggle {
        display: block !important;
        position: relative !important;
        z-index: 1001 !important;
    }

    /* Lock scroll when menu open */
    body.menu-open {
        overflow: hidden !important;
    }


}