/* ============================================
   LOVEMY - AMERICAN TRUCK STOP SOCIAL CLUB
   Design tokens and component styles
   ============================================ */

:root {
    --background: #FAF6EF;
    --foreground: #2D2520;
    --card: #FFFFFF;
    --card-foreground: #2D2520;
    --popover: #FFFFFF;
    --popover-foreground: #2D2520;
    --primary: #8A4220;
    --primary-foreground: #FFFFFF;
    --secondary: #44546B;
    --secondary-foreground: #FFFFFF;
    --muted: #EFE6D6;
    --muted-foreground: #4A3D2E;
    --accent: #7E3A18;
    --accent-foreground: #FFFFFF;
    --destructive: #8A241B;
    --destructive-foreground: #FFFFFF;
    --border: #E0D4BF;
    --input: #F3EBDB;
    --ring: #8A4220;

    /* Brand-specific tokens */
    --espresso: #2D2520;
    --espresso-deep: #211912;
    --cream: #FAF6EF;
    --cream-warm: #F3EBDB;
    --rust: #8A4220;
    --rust-deep: #6B3214;
    --rust-bright: #C86A3A;
    --denim: #4A5F7B;
    --amber: #D89A4A;

    /* Spacing scale */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 40px;
    --space-2xl: 56px;
    --space-3xl: 96px;

    /* Layout */
    --container-max: 1180px;
    --container-narrow: 720px;
    --header-h: 72px;
    --radius-sm: 4px;
    --radius: 6px;
    --radius-lg: 12px;

    /* Type */
    --font-display: "Alfa Slab One", Georgia, serif;
    --font-body: "Bitter", Georgia, serif;
    --font-hand: "Caveat", "Brush Script MT", cursive;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(45, 37, 32, 0.08);
    --shadow: 0 4px 12px rgba(45, 37, 32, 0.10);
    --shadow-md: 0 8px 24px rgba(45, 37, 32, 0.14);
    --shadow-lg: 0 16px 40px rgba(45, 37, 32, 0.18);

    /* Motion */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --t-fast: 160ms;
    --t-base: 240ms;
    --t-slow: 280ms;
}

.dark {
    --background: #2D2520;
    --foreground: #FAF6EF;
    --card: #3A2F28;
    --card-foreground: #FAF6EF;
    --popover: #3A2F28;
    --popover-foreground: #FAF6EF;
    --primary: #E08A4F;
    --primary-foreground: #2D2520;
    --secondary: #8FA3BC;
    --secondary-foreground: #2D2520;
    --muted: #3F3329;
    --muted-foreground: #D8C9B0;
    --accent: #E0A040;
    --accent-foreground: #2D2520;
    --destructive: #B23A2E;
    --destructive-foreground: #FAF6EF;
    --border: #4A3D33;
    --input: #3F3329;
    --ring: #E08A4F;

    --espresso: #1C1611;
    --espresso-deep: #0F0B08;
    --cream: #FAF6EF;
    --cream-warm: #3F3329;
    --rust: #E08A4F;
    --rust-deep: #C86A3A;
    --rust-bright: #E08A4F;
    --denim: #A8BCD4;
    --amber: #E0A040;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.65;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img, video, iframe, svg, embed, object { max-width: 100%; height: auto; display: block; }

a { color: var(--rust); text-decoration: none; transition: color var(--t-fast) var(--ease); }
a:hover { color: var(--rust-deep); text-decoration: underline; }

/* Inline links inside body prose must be underlined for a11y (link-in-text-block) */
p > a, li > a { text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px; }
p > a:hover, li > a:hover { text-decoration-thickness: 2px; }

p { margin: 0 0 var(--space-lg); overflow-wrap: break-word; }
li { overflow-wrap: break-word; }

pre, code { max-width: 100%; overflow-x: auto; }

input, textarea, select, button { font: inherit; max-width: 100%; }

[class*="grid"] > *, [class*="flex"] > * { min-width: 0; }

section { overflow: clip; }

.skip-link {
    position: absolute; top: -100px; left: 0;
    padding: 12px 20px;
    background: var(--rust); color: #fff;
    z-index: 2000;
    text-decoration: none;
    border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { top: 0; color: #fff; }

.sr-only {
    position: absolute; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ============================================
   TYPOGRAPHY - Roadside diner signage feel
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 var(--space-md);
    color: var(--foreground);
}

h1 { font-size: clamp(32px, 5vw, 48px); }
h2 { font-size: clamp(26px, 4vw, 36px); }
h3 { font-size: clamp(20px, 2.5vw, 24px); }
h4 { font-size: 20px; }

.eyebrow {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--rust);
    margin-bottom: var(--space-md);
}

.hand {
    font-family: var(--font-hand);
    font-weight: 600;
}

.hand--amber { color: var(--amber); }
.hand--rust { color: var(--rust); }

/* ============================================
   LAYOUT - Container, sections
   ============================================ */
.container { width: 100%; max-width: var(--container-max); margin: 0 auto; padding: 0 var(--space-lg); }
.container-narrow { width: 100%; max-width: var(--container-narrow); margin: 0 auto; padding: 0 var(--space-lg); }

.section { padding: var(--space-2xl) 0; }
.section--lg { padding: var(--space-3xl) 0; }
.section--cream { background: var(--cream-warm); }
.section--espresso { background: var(--espresso); color: var(--cream); }
.section--espresso h1, .section--espresso h2, .section--espresso h3 { color: var(--cream); }
.section--espresso a { color: var(--amber); }
.section--espresso .eyebrow,
.hero--espresso .eyebrow { color: var(--amber); }
.section--espresso .testimonial-name,
.section--espresso .testimonial-role,
.section--espresso .hand--amber,
.section--espresso .hand--rust,
.hero--espresso .hand--amber,
.hero--espresso .hand--rust,
.hero--espresso .hero-micro { color: var(--amber); }
.section--espresso .testimonial,
.section--espresso .testimonial::before { color: var(--amber); }
.section--espresso .testimonial { border-left-color: var(--amber); }
.section--espresso .testimonial::before { color: var(--amber); }
.section--muted { background: var(--muted); }

@media (min-width: 1024px) {
    .section { padding: var(--space-3xl) 0; }
}

/* ============================================
   BUTTONS - Diner-stop CTAs
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    min-height: 48px;
    padding: 14px 26px;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    text-decoration: none;
    transition: transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); box-shadow: inset 0 2px 6px rgba(0,0,0,0.18); }

.btn-primary {
    background: var(--rust-deep);
    color: #FFFFFF;
}
.btn-primary:hover { background: var(--espresso); color: #FFFFFF; }
.dark .btn-primary { background: var(--rust-bright); color: #2D2520; }
.dark .btn-primary:hover { background: var(--amber); color: #2D2520; }

.btn-secondary {
    background: transparent;
    color: var(--cream);
    border-color: var(--cream);
}
.section--espresso .btn-secondary { color: var(--cream); border-color: var(--cream); }
.btn-secondary:hover { background: var(--cream); color: var(--espresso); }

.btn-outline {
    background: transparent;
    color: var(--foreground);
    border-color: var(--denim);
}
.btn-outline:hover { background: var(--denim); color: #FFFFFF; }

.btn-lg { min-height: 56px; padding: 18px 36px; font-size: 17px; }

/* ============================================
   SITE HEADER - Sticky truck-stop signboard
   ============================================ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--background);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 0 rgba(45,37,32,0.04);
}

.header-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-sm);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    flex-shrink: 0;
}
@media (max-width: 1023px) {
    .header-actions .header-cta { display: none; }
    .header-actions .theme-toggle { min-height: 44px; min-width: 44px; padding: 0 10px; }
}
@media (min-width: 1024px) {
    .header-actions { gap: var(--space-md); }
}

.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--rust);
    text-decoration: none;
    flex-shrink: 0;
}
.site-brand:hover { color: var(--rust-deep); text-decoration: none; }
.brand-mark { display: inline-flex; color: var(--rust); }
.brand-wordmark {
    font-family: var(--font-display);
    font-size: 24px;
    letter-spacing: 0.02em;
    color: var(--foreground);
}
.brand-steam {
    animation: steamRise 4s ease-in-out infinite;
    transform-origin: center bottom;
}
@keyframes steamRise {
    0%, 100% { opacity: 0.6; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-2px); }
}

/* Mobile toggle */
.mobile-menu-toggle {
    width: 44px; height: 44px;
    background: transparent; border: 0; cursor: pointer;
    display: inline-flex; flex-direction: column;
    justify-content: center; align-items: center;
    gap: 5px; padding: 0;
    z-index: 1001;
}
.mobile-menu-toggle span {
    display: block;
    width: 24px; height: 2px;
    background: var(--foreground);
    transition: transform var(--t-base) var(--ease), opacity var(--t-base) var(--ease);
}
.mobile-menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mobile-menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.mobile-menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Primary nav - mobile-first (hidden by default) */
.primary-nav {
    display: none;
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0; bottom: 0;
    background: var(--background);
    z-index: 999;
    overflow-y: auto;
    padding: var(--space-lg);
    flex-direction: column;
    gap: var(--space-md);
}
.primary-nav.is-open { display: flex; }

.nav-list {
    list-style: none;
    margin: 0; padding: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
}
.nav-list > li { width: 100%; }
.nav-list a, .nav-trigger {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 48px;
    padding: 12px var(--space-md);
    color: var(--foreground);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 17px;
    background: transparent;
    border: 0;
    border-radius: var(--radius);
    text-decoration: none;
    cursor: pointer;
    text-align: left;
}
.nav-list a:hover, .nav-trigger:hover { background: var(--muted); color: var(--rust); text-decoration: none; }

.nav-trigger { justify-content: space-between; }
.caret { font-size: 12px; transition: transform var(--t-fast) var(--ease); }
.nav-trigger[aria-expanded="true"] .caret { transform: rotate(180deg); }

.dropdown-panel {
    list-style: none;
    margin: 0; padding: 0 0 0 var(--space-md);
    display: none;
    flex-direction: column;
    background: transparent;
    border-left: 2px solid var(--border);
    margin-left: var(--space-md);
}
.dropdown-panel.is-open { display: flex; }
.dropdown-panel a {
    font-size: 15px;
    font-weight: 500;
    min-height: 44px;
}

.nav-actions {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    margin-top: var(--space-md);
    padding-top: var(--space-md);
    border-top: 1px solid var(--border);
}
.nav-actions .mobile-cta { width: 100%; }
.header-cta { width: auto; }

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 16px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--foreground);
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 600;
}
.theme-toggle:hover { background: var(--muted); }
.theme-icon-dark { display: none; }
.dark .theme-icon-light { display: none; }
.dark .theme-icon-dark { display: inline; }

@media (min-width: 1024px) {
    .mobile-menu-toggle { display: none; }
    .primary-nav {
        display: flex !important;
        position: static;
        flex-direction: row;
        align-items: center;
        justify-content: flex-end;
        padding: 0;
        background: transparent;
        overflow: visible;
        gap: var(--space-md);
        flex: 1;
    }
    .nav-list { flex-direction: row; align-items: center; gap: 2px; }
    .nav-list > li { width: auto; position: relative; }
    .nav-list a, .nav-trigger {
        min-height: 44px;
        padding: 8px 14px;
        font-size: 15px;
    }
    .dropdown-panel {
        position: absolute;
        top: calc(100% + 4px);
        left: 0;
        min-width: 240px;
        max-width: calc(100vw - var(--space-lg) * 2);
        margin-left: 0;
        padding: var(--space-sm);
        background: var(--popover);
        border: 1px solid var(--border);
        border-radius: var(--radius);
        box-shadow: var(--shadow-md);
        z-index: 1000;
    }
    .dropdown-panel a { font-size: 14px; padding: 8px 12px; min-height: 36px; }
    .dropdown-panel.is-open { display: flex; }
    .nav-actions { display: none; }
    .theme-toggle { min-height: 40px; padding: 0 12px; }
}

/* ============================================
   FOOTER - 4-column truck stop bulletin board
   ============================================ */
.site-footer {
    background: var(--espresso);
    color: var(--cream);
    padding: var(--space-3xl) 0 var(--space-lg);
    margin-top: var(--space-3xl);
}
.dark .site-footer { background: var(--espresso-deep); }

.footer-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xl);
}
.footer-col { min-width: 0; }
.footer-brand-col .site-brand--footer { color: var(--rust); }
.footer-brand-col .brand-mark { color: var(--rust); }
.footer-brand-col .brand-wordmark { color: var(--cream); }
.footer-tagline { font-size: 15px; color: rgba(250, 246, 239, 0.85); margin: var(--space-md) 0; }
.footer-caveat { font-family: var(--font-hand); font-size: 22px; color: var(--amber); margin: 0; }

.footer-heading {
    font-family: var(--font-display);
    font-size: 16px;
    letter-spacing: 0.04em;
    color: var(--amber);
    margin: 0 0 var(--space-md);
}
.footer-heading--spaced { margin-top: var(--space-lg); }

.footer-links { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.footer-links a {
    color: rgba(250, 246, 239, 0.85);
    font-size: 14px;
    text-decoration: none;
}
.footer-links a:hover { color: var(--amber); text-decoration: underline; }

.footer-bottom {
    max-width: var(--container-max);
    margin: var(--space-2xl) auto 0;
    padding: var(--space-lg) var(--space-lg) 0;
    border-top: 1px solid rgba(250, 246, 239, 0.12);
    text-align: center;
    font-size: 13px;
    color: rgba(250, 246, 239, 0.65);
}
.footer-bottom p { margin: 4px 0; }
.footer-meta { font-family: var(--font-hand); font-size: 18px; color: var(--amber); }

@media (min-width: 768px) {
    .footer-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
    .footer-inner { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; }
}

/* ============================================
   POLAROID PROFILE CARD
   Signature visual - white frame, tilt, handwritten caption
   ============================================ */
.polaroid {
    background: #FFFFFF;
    padding: 14px 14px 48px;
    box-shadow: var(--shadow-md);
    border-radius: 2px;
    transition: transform var(--t-slow) var(--ease), box-shadow var(--t-slow) var(--ease);
    margin: 0 auto;
    max-width: 280px;
    position: relative;
    background-image: linear-gradient(135deg, rgba(45,37,32,0.02) 0%, rgba(45,37,32,0) 50%);
}
.dark .polaroid { background: #F3EBDB; }
.polaroid--tilt-left { transform: rotate(-2deg); }
.polaroid--tilt-right { transform: rotate(2deg); }
.polaroid--tilt-none { transform: rotate(0); }
.polaroid:hover { transform: rotate(0) translateY(-6px); box-shadow: var(--shadow-lg); }

.polaroid-photo {
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--muted);
    margin-bottom: var(--space-md);
    position: relative;
}
.polaroid-photo img {
    width: 100%; height: 100%;
    object-fit: cover;
    filter: saturate(1.04) contrast(1.02) sepia(0.05);
}
.polaroid-photo-placeholder {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, var(--muted) 0%, var(--cream-warm) 100%);
}

.polaroid-caption {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 4px;
}
.polaroid-name {
    font-family: var(--font-hand);
    font-size: 22px;
    font-weight: 700;
    color: var(--rust-deep);
    line-height: 1.1;
}
.polaroid-meta {
    font-family: var(--font-body);
    font-size: 12px;
    color: #5B4A38;
    margin-top: 2px;
    letter-spacing: 0.04em;
}
.polaroid-note {
    font-family: var(--font-hand);
    font-size: 16px;
    color: #5B4A38;
    margin-top: 4px;
}
.polaroid-link {
    margin-top: 4px;
    font-size: 12px;
    font-weight: 700;
    color: var(--rust);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Polaroid grid */
.polaroid-grid {
    display: grid;
    gap: var(--space-lg);
    grid-template-columns: 1fr;
}
@media (min-width: 600px) {
    .polaroid-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
    .polaroid-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1280px) {
    .polaroid-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Mobile carousel option */
.polaroid-carousel {
    display: flex;
    gap: var(--space-lg);
    overflow-x: auto;
    padding: var(--space-md) var(--space-lg) var(--space-xl);
    margin: 0 calc(-1 * var(--space-lg));
    scroll-snap-type: x mandatory;
}
.polaroid-carousel .polaroid {
    flex: 0 0 240px;
    scroll-snap-align: start;
}
@media (min-width: 768px) {
    .polaroid-carousel {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        overflow: visible;
        margin: 0;
        padding: 0;
    }
    .polaroid-carousel .polaroid { flex: initial; max-width: 100%; }
}
@media (min-width: 1024px) {
    .polaroid-carousel { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ============================================
   FAQ ACCORDION
   ============================================ */
.faq-accordion {
    max-width: 820px;
    margin: 0 auto;
}
.faq-item {
    border-bottom: 1px solid var(--border);
    transition: background var(--t-fast) var(--ease);
}
.faq-item[open] { background: var(--cream-warm); }
.dark .faq-item[open] { background: rgba(63, 51, 41, 0.6); }

.faq-question {
    list-style: none;
    cursor: pointer;
    padding: 20px 48px 20px var(--space-md);
    font-family: var(--font-body);
    font-size: 18px;
    font-weight: 600;
    color: var(--foreground);
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-md);
}
.faq-question::-webkit-details-marker { display: none; }
.faq-question::marker { content: ""; }
.faq-question:hover { color: var(--rust); }

.faq-icon {
    width: 24px; height: 24px;
    position: relative;
    flex-shrink: 0;
}
.faq-icon::before, .faq-icon::after {
    content: "";
    position: absolute;
    background: var(--rust);
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    transition: transform var(--t-base) var(--ease);
}
.faq-icon::before { width: 16px; height: 2px; }
.faq-icon::after { width: 2px; height: 16px; }
.faq-item[open] .faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); opacity: 0; }
.faq-item[open] .faq-icon::before { transform: translate(-50%, -50%) rotate(180deg); }

.faq-answer {
    padding: 0 var(--space-md) var(--space-lg);
    animation: faqFade var(--t-slow) var(--ease);
}
.faq-answer p {
    margin: 0;
    font-size: 17px;
    line-height: 1.65;
    color: var(--foreground);
}
@keyframes faqFade {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 767px) {
    .faq-question { padding: 16px 44px 16px var(--space-md); font-size: 17px; }
    .faq-answer { padding: 0 var(--space-md) var(--space-md); }
}

/* ============================================
   CTA BANNER
   ============================================ */
.cta-banner {
    background: var(--espresso);
    color: var(--cream);
    padding: var(--space-3xl) var(--space-lg);
    text-align: center;
    position: relative;
}
.dark .cta-banner { background: var(--espresso-deep); }
.cta-banner-inner {
    max-width: 720px;
    margin: 0 auto;
}
.cta-banner-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 36px);
    color: var(--cream);
    margin: 0 0 var(--space-md);
}
.cta-banner-sub {
    font-size: 18px;
    color: rgba(250, 246, 239, 0.85);
    margin: 0 0 var(--space-lg);
}
.cta-banner-micro {
    display: block;
    font-family: var(--font-hand);
    font-size: 22px;
    color: var(--amber);
    margin-top: var(--space-md);
}
.cta-banner .btn-primary { color: #FFFFFF; }
.dark .cta-banner .btn-primary { color: #2D2520; }

/* ============================================
   INFO CARD GRID
   ============================================ */
.info-card-grid {
    display: grid;
    gap: var(--space-lg);
    grid-template-columns: 1fr;
}
@media (min-width: 768px) { .info-card-grid--cols-2, .info-card-grid--cols-3, .info-card-grid--cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) {
    .info-card-grid--cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .info-card-grid--cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1280px) {
    .info-card-grid--cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.info-card {
    background: var(--muted);
    padding: 28px;
    border-radius: var(--radius);
    border: 1px solid rgba(91, 114, 144, 0.2);
    transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
    min-width: 0;
}
.info-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.dark .info-card { background: var(--card); border-color: var(--border); }

.info-card-icon {
    width: 56px; height: 56px;
    border-radius: 50%;
    background: var(--rust);
    color: #FFFFFF;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin-bottom: var(--space-md);
}
.dark .info-card-icon { color: #2D2520; }

.info-card-step {
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--cream);
    color: var(--rust);
    border: 2px solid var(--rust);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 22px;
    margin-bottom: var(--space-md);
}

.info-card-title {
    font-family: var(--font-display);
    font-size: 22px;
    margin: 0 0 var(--space-sm);
    color: var(--foreground);
}
.info-card-desc {
    font-size: 16px;
    line-height: 1.6;
    color: var(--foreground);
    margin: 0 0 var(--space-md);
}
.info-card-link {
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--rust);
}
.info-card-link:hover { color: var(--rust-deep); text-decoration: none; }

/* ============================================
   TESTIMONIAL QUOTE
   ============================================ */
.testimonial {
    border-left: 4px solid var(--rust);
    padding-left: var(--space-lg);
    margin: 0;
    position: relative;
    max-width: 760px;
}
.testimonial::before {
    content: "\201C";
    position: absolute;
    top: -16px;
    left: var(--space-md);
    font-family: var(--font-display);
    font-size: 64px;
    color: var(--rust);
    opacity: 0.4;
    line-height: 1;
    pointer-events: none;
}
.testimonial-quote {
    margin: 0;
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(20px, 2.4vw, 26px);
    line-height: 1.4;
    color: var(--foreground);
}
.testimonial-quote p { margin: 0; }

.testimonial-attribution {
    margin-top: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-md);
}
.testimonial-avatar {
    width: 56px; height: 56px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid var(--cream);
    box-shadow: var(--shadow-sm);
}
.testimonial-meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.testimonial-name {
    font-family: var(--font-hand);
    font-size: 22px;
    color: var(--rust-deep);
    line-height: 1.1;
}
.testimonial-role {
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--denim);
}
.dark .testimonial-role { color: var(--secondary); }
.dark .testimonial-name { color: var(--amber); }
.dark .testimonial { border-left-color: var(--amber); }
.dark .testimonial::before { color: var(--amber); }

/* ============================================
   BREADCRUMB NAV
   ============================================ */
.breadcrumb {
    padding: var(--space-md) 0;
    background: transparent;
}
.breadcrumb-list {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 14px;
}
.breadcrumb-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--foreground);
}
.breadcrumb-item a {
    color: var(--denim);
    text-decoration: none;
    font-family: var(--font-body);
}
.dark .breadcrumb-item a { color: var(--secondary); }
.breadcrumb-item a:hover { text-decoration: underline; color: var(--rust); }
.breadcrumb-item [aria-current="page"] {
    font-weight: 700;
    color: var(--foreground);
}
.breadcrumb-sep {
    color: var(--denim);
    opacity: 0.6;
}
@media (max-width: 600px) {
    .breadcrumb-item:not(:last-child):not(:nth-last-child(2)) { display: none; }
    .breadcrumb-item:nth-last-child(3)::before {
        content: "…";
        margin-right: 6px;
        color: var(--denim);
    }
}

/* ============================================
   HERO PATTERNS
   ============================================ */
.hero {
    padding: var(--space-2xl) 0 var(--space-3xl);
    position: relative;
}
.hero--espresso { background: var(--espresso); color: var(--cream); }
.hero--espresso h1, .hero--espresso h2 { color: var(--cream); }
.hero--cream { background: var(--cream-warm); }
.hero-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}
.hero-grid {
    display: grid;
    gap: var(--space-2xl);
    grid-template-columns: 1fr;
    align-items: center;
}
@media (min-width: 900px) {
    .hero-grid { grid-template-columns: 1.2fr 1fr; }
}
.hero-title { font-size: clamp(32px, 5.5vw, 54px); margin-bottom: var(--space-md); }
.hero-sub { font-size: clamp(17px, 2vw, 20px); margin-bottom: var(--space-xl); max-width: 56ch; }
.hero--espresso .hero-sub { color: rgba(250, 246, 239, 0.88); }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-md); align-items: center; }
.hero-micro {
    font-family: var(--font-hand);
    font-size: 22px;
    color: var(--rust-deep);
    margin-top: var(--space-md);
}
.dark .hero-micro { color: var(--amber); }

/* ============================================
   ENGAGEMENT & CRO PATTERNS
   ============================================ */
/* TL;DR / Summary box */
.summary-box {
    background: var(--cream-warm);
    border-left: 4px solid var(--denim);
    padding: var(--space-lg) var(--space-xl);
    border-radius: var(--radius);
    margin: var(--space-lg) 0 var(--space-xl);
}
.dark .summary-box { background: var(--card); border-left-color: var(--secondary); }
.summary-box h3, .summary-box h2 {
    font-family: var(--font-display);
    font-size: 18px;
    margin: 0 0 var(--space-sm);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--denim);
}
.dark .summary-box h3, .dark .summary-box h2 { color: var(--secondary); }
.summary-box ul { padding-left: 20px; margin: 0; }
.summary-box li { margin-bottom: 6px; }

/* Callout / highlight box */
.callout {
    background: var(--muted);
    border: 1px solid var(--border);
    border-left: 4px solid var(--rust);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius);
    margin: var(--space-lg) 0;
}
.callout--warning { border-left-color: var(--denim); }
.callout--tip { border-left-color: var(--rust); }
.callout-label {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--rust);
    margin-bottom: 6px;
}
.callout p:last-child { margin-bottom: 0; }

/* Stat highlight */
.stat-highlight {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: var(--space-lg);
    background: var(--cream-warm);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}
.dark .stat-highlight { background: var(--card); }
.stat-number {
    font-family: var(--font-display);
    font-size: clamp(36px, 5vw, 56px);
    color: var(--rust);
    line-height: 1;
}
.stat-label {
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--foreground);
    margin-top: 8px;
}
.stat-source {
    font-size: 12px;
    color: var(--muted-foreground);
    margin-top: 4px;
}

/* Pull quote (used inline in articles) */
.pull-quote {
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(22px, 2.6vw, 28px);
    line-height: 1.35;
    border-left: 4px solid var(--rust);
    padding: var(--space-md) 0 var(--space-md) var(--space-lg);
    margin: var(--space-xl) 0;
    color: var(--foreground);
}

/* Comparison table */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
}
.table-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    margin: var(--space-lg) 0;
    border-radius: var(--radius);
}
.table-wrapper:focus-visible { outline: 3px solid var(--rust); outline-offset: 2px; }
.polaroid-carousel:focus-visible { outline: 3px solid var(--rust); outline-offset: 4px; }
.comparison-table th, .comparison-table td {
    padding: var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
    overflow-wrap: break-word;
    color: var(--card-foreground);
}
.comparison-table tbody th {
    color: var(--card-foreground);
    background: var(--card);
    font-family: var(--font-body);
    font-size: 15px;
    text-transform: none;
    letter-spacing: 0;
    font-weight: 700;
}
.comparison-table th {
    font-family: var(--font-display);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    background: var(--espresso);
    color: var(--cream);
    font-weight: 400;
}
.comparison-table td.col-highlight {
    background: rgba(156, 77, 34, 0.10);
    border-left: 3px solid var(--rust);
    border-right: 3px solid var(--rust);
    font-weight: 600;
}
.comparison-table th.col-highlight {
    background: var(--rust);
    color: #FFFFFF;
    border-left: 3px solid var(--rust);
    border-right: 3px solid var(--rust);
}
.dark .comparison-table th.col-highlight {
    background: var(--rust-bright);
    color: #2D2520;
}
.comparison-table tr:last-child td { border-bottom: 0; }
.check { color: var(--rust); font-weight: 700; }
.cross { color: var(--muted-foreground); }

/* Trust badges row */
.trust-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: var(--space-xl);
    padding: var(--space-lg) 0;
    opacity: 0.85;
}
.trust-item {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted-foreground);
}

/* Two-column split */
.two-col {
    display: grid;
    gap: var(--space-2xl);
    grid-template-columns: 1fr;
    align-items: start;
}
@media (min-width: 900px) {
    .two-col { grid-template-columns: 1fr 1fr; gap: var(--space-3xl); }
}
.two-col--narrow { gap: var(--space-xl); }

/* Article prose */
.prose {
    max-width: 720px;
    margin: 0 auto;
}
.prose p, .prose ul, .prose ol { font-size: 17px; line-height: 1.75; }
.prose h2 { margin-top: var(--space-2xl); }
.prose h3 { margin-top: var(--space-xl); }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin-bottom: 10px; }
.prose img { border-radius: var(--radius); margin: var(--space-lg) 0; }
.prose blockquote { margin: var(--space-xl) 0; }

/* Article meta */
.article-meta {
    font-family: var(--font-body);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--denim);
    margin-bottom: var(--space-md);
}

/* Pros and cons grid */
.pros-cons {
    display: grid;
    gap: var(--space-lg);
    grid-template-columns: 1fr;
}
@media (min-width: 700px) { .pros-cons { grid-template-columns: 1fr 1fr; } }
.pros-cons > div {
    padding: var(--space-lg);
    border-radius: var(--radius);
    background: var(--muted);
    border-top: 4px solid var(--rust);
}
.dark .pros-cons > div { background: var(--card); }
.pros-cons .cons { border-top-color: var(--denim); }
.pros-cons h3 {
    font-family: var(--font-display);
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--rust);
    margin: 0 0 var(--space-md);
}
.pros-cons .cons h3 { color: var(--denim); }
.dark .pros-cons .cons h3 { color: var(--secondary); }
.pros-cons ul { padding-left: 20px; margin: 0; }
.pros-cons li { margin-bottom: 8px; }

/* Section heading wrapper */
.section-head {
    text-align: center;
    max-width: 760px;
    margin: 0 auto var(--space-2xl);
}
.section-head--left { text-align: left; margin-left: 0; }
.section-head p { font-size: 17px; color: var(--foreground); }

/* ============================================
   ANIMATIONS - Scroll reveal
   ============================================ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 640ms var(--ease), transform 640ms var(--ease);
}
.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
    .animate-on-scroll { opacity: 1; transform: none; transition: none; }
    .brand-steam { animation: none; }
    * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* Stagger helper (set --stagger via inline style on parent) */
.stagger > *:nth-child(1) { transition-delay: 0ms; }
.stagger > *:nth-child(2) { transition-delay: 80ms; }
.stagger > *:nth-child(3) { transition-delay: 160ms; }
.stagger > *:nth-child(4) { transition-delay: 240ms; }
.stagger > *:nth-child(5) { transition-delay: 320ms; }
.stagger > *:nth-child(6) { transition-delay: 400ms; }

/* ============================================
   UTILITIES
   ============================================ */
.text-center { text-align: center; }
.text-left { text-align: left; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

/* Focus styles */
a:focus-visible, button:focus-visible, summary:focus-visible, .btn:focus-visible {
    outline: 3px solid var(--rust);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* ============================================
   STATES HUB EXTRAS
   ============================================ */
.state-card-extra {
    background: var(--espresso);
    color: var(--cream);
    border: 1px solid var(--rust);
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 320px;
}
.state-card-extra .info-card-title,
.state-card-extra .info-card-desc { color: var(--cream); }
.state-card-extra .info-card-icon {
    background: var(--rust-bright);
    color: var(--espresso);
}
.state-card-extra .info-card-link { color: var(--amber); }
.state-card-extra .info-card-link:hover { color: var(--cream); }
.dark .state-card-extra { background: var(--espresso-deep); }

/* ============================================
   REGISTER STUB
   ============================================ */
.register-stub {
    min-height: calc(100vh - var(--header-h) - 200px);
    display: flex;
    align-items: center;
    padding: var(--space-2xl) 0;
    background: var(--cream-warm);
}
.dark .register-stub { background: var(--background); }

.register-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: var(--space-2xl) var(--space-xl);
    text-align: center;
    box-shadow: var(--shadow-md);
    max-width: 520px;
    margin: 0 auto;
}
.register-mark {
    display: inline-flex;
    color: var(--rust);
    margin-bottom: var(--space-md);
}
.register-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 36px);
    margin: 0 0 var(--space-sm);
    color: var(--foreground);
}
.register-caveat {
    font-family: var(--font-hand);
    font-size: 28px;
    font-weight: 700;
    color: var(--rust-deep);
    margin: 0 0 var(--space-md);
}
.dark .register-caveat { color: var(--amber); }
.register-msg {
    font-size: 16px;
    color: var(--foreground);
    margin: 0 0 var(--space-lg);
}
.register-actions {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    align-items: stretch;
    margin-bottom: var(--space-lg);
}
@media (min-width: 600px) {
    .register-actions {
        flex-direction: row;
        justify-content: center;
    }
}
.register-foot {
    font-size: 14px;
    color: var(--foreground);
    margin: 0;
}
.register-foot a {
    color: var(--espresso);
    text-decoration: underline;
    font-weight: 700;
}
.dark .register-foot { color: var(--cream); }
.dark .register-foot a { color: var(--amber); }