/* Google Fonts for brand testing - all loaded, just change font-family in .logo-text */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@700&family=Comfortaa:wght@700&family=Quicksand:wght@700&family=Nunito:wght@700&family=Baloo+2:wght@700&family=Righteous&display=swap');

/* Define layer order - earlier layers have lower priority */
@layer reset, theme, base, components, utilities, overrides;

/* ============================================
   LAYER: RESET
   ============================================ */
@layer reset {
    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }
}

/* ============================================
   LAYER: THEME
   ============================================ */
@layer theme {
    :root {
        /* Mobile keyboard inset (set dynamically by mobile-input.js via VisualViewport API) */
        --kb-inset: 0px;

        /* Dark theme (default) */
        --bg-primary: oklch(0.15 0 0);
        --bg-secondary: oklch(0.2 0 0);
        --bg-card: oklch(0.2 0 0 / 0.8);
        --text-primary: oklch(1 0 0);
        --text-secondary: oklch(0.75 0 0);
        --text-tertiary: oklch(0.6 0 0);

        /* Cyan colors */
        --cyan: oklch(0.9 0.15 195);
        --cyan-dim: oklch(0.9 0.15 195 / 0.3);
        --cyan-bright: oklch(0.9 0.15 195 / 0.5);

        /* Magenta colors */
        --magenta: oklch(0.7 0.3 330);
        --magenta-dim: oklch(0.7 0.3 330 / 0.3);

        /* Blue colors */
        --blue: oklch(0.6 0.2 250);

        /* Accent colors */
        --green: oklch(0.8 0.2 150);
        --orange: oklch(0.7 0.18 50);
        --yellow: oklch(0.9 0.2 100);

        /* Vocabulary highlighting (dark theme) */
        --vocab-highlight: oklch(0.85 0.18 180);
        --vocab-bg: oklch(0.85 0.18 180 / 0.15);
        --vocab-bg-hover: oklch(0.85 0.18 180 / 0.25);

        --border-color: var(--cyan-dim);
        --border-hover: var(--cyan-bright);
        /* --gradient-primary: linear-gradient(135deg, var(--cyan) 0%, var(--magenta) 100%); */
        /* --gradient-primary: linear-gradient(135deg, var(--cyan) 0%, var(--orange) 100%); */ /* cyan to orange */
        --gradient-primary: linear-gradient(135deg, var(--cyan) 0%, var(--blue) 100%); /* cyan to blue */
        --gradient-secondary: linear-gradient(135deg, var(--cyan) 0%, var(--blue) 100%);
        --shadow-glow: 0 0 20px oklch(0.9 0.15 195 / 0.5), 0 0 40px oklch(0.7 0.3 330 / 0.3);
        --nav-bg: oklch(0.15 0 0 / 0.8);
        --grid-color: oklch(0.9 0.15 195 / 0.03);
        --radial-glow: oklch(0.9 0.15 195 / 0.2);
    }

    [data-theme="light"] {
        /* Light theme */
        --bg-primary: oklch(1 0 0);
        --bg-secondary: oklch(0.98 0 0);
        --bg-card: oklch(1 0 0 / 0.9);
        --text-primary: oklch(0.25 0 0);
        --text-secondary: oklch(0.45 0 0);
        --text-tertiary: oklch(0.6 0 0);

        /* Light theme cyan/blue colors */
        --cyan: oklch(0.7 0.12 210);
        --cyan-dim: oklch(0.7 0.12 210 / 0.3);
        --cyan-bright: oklch(0.7 0.12 210 / 0.6);

        /* Light theme blue/purple */
        --magenta: oklch(0.6 0.15 270);
        --blue: oklch(0.6 0.18 250);

        /* Vocabulary highlighting (light theme) */
        --vocab-highlight: oklch(0.5 0.2 270);
        --vocab-bg: oklch(0.8 0.08 270 / 0.35);
        --vocab-bg-hover: oklch(0.75 0.1 270 / 0.5);

        --border-color: var(--cyan-dim);
        --border-hover: var(--cyan-bright);
        --gradient-primary: linear-gradient(135deg, var(--cyan) 0%, var(--blue) 100%);
        --gradient-secondary: linear-gradient(135deg, var(--cyan) 0%, var(--magenta) 100%);
        --shadow-glow: 0 10px 25px oklch(0.7 0.12 210 / 0.3);
        --nav-bg: oklch(1 0 0 / 0.95);
        --grid-color: oklch(0.7 0.12 210 / 0.05);
        --radial-glow: oklch(0.7 0.12 210 / 0.15);
    }
}

/* ============================================
   LAYER: BASE
   ============================================ */
@layer base {
    /* iOS flickering fix - GPU compositing for interactive elements */
    button,
    a,
    input,
    select,
    textarea,
    [role="button"],
    .clickable {
        transform: translateZ(0);
    }
    body {
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        line-height: 1.6;
        color: var(--text-secondary);
        overflow-x: hidden;
        background: var(--bg-primary);
        transition: background 0.3s ease, color 0.3s ease;
    }
}

/* ============================================
   LAYER: UTILITIES
   ============================================ */
@layer utilities {
    .container {
        max-inline-size: 1200px;
        margin-inline: auto;
        padding-inline: 20px;
    }

    .hidden {
        display: none !important;
    }

    .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;
    }
}

/* ============================================
   LAYER: COMPONENTS
   ============================================ */
@layer components {
    /* Navigation */
    @scope (nav) {
    :scope {
        position: fixed;
        inset-block-start: 0;
        inline-size: 100%;
        background: var(--nav-bg);
        backdrop-filter: blur(20px);
        box-shadow: 0 4px 30px oklch(0.9 0.15 195 / 0.1);
        border-block-end: 1px solid var(--border-color);
        z-index: 1000;
        padding-block: 1rem;
        transition: background 0.3s ease, border-color 0.3s ease;
    }

    .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .logo-link {
        text-decoration: none;
        transition: opacity 0.3s ease;
    }

    .logo-link:hover {
        opacity: 0.8;
    }

    .logo {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-size: 1.8rem;
        font-weight: 700;
    }

    .logo-icon {
        flex-shrink: 0;
    }

    .logo-icon rect {
        fill: #4F46E5;
    }

    .logo-text {
        font-family: 'Fredoka', sans-serif;
        /* font-family: 'Comfortaa', sans-serif; */
        /* font-family: 'Quicksand', sans-serif; */
        /* font-family: 'Nunito', sans-serif; */
        /* font-family: 'Baloo 2', sans-serif; */
        /* font-family: 'Righteous', sans-serif; */
        text-transform: uppercase;
        letter-spacing: 2px;
        background: var(--gradient-primary);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }

    .nav-links {
        display: flex;
        gap: 2rem;
        list-style: none;

        & a {
            text-decoration: none;
            color: var(--text-secondary);
            font-weight: 500;
            transition: color 0.3s;

            &:hover {
                color: var(--cyan);
            }
        }
    }

    .hamburger {
        display: none;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0.5rem;
        width: 40px;
        height: 40px;
        z-index: 1001;
        transition: transform 0.3s ease;
        position: relative;

        & span {
            display: block;
            width: 24px;
            height: 2px;
            background: var(--text-primary);
            border-radius: 2px;
            transition: all 0.3s ease;
            position: relative;
        }

        &.active span:nth-child(1) {
            transform: translateY(7px) rotate(45deg);
        }

        &.active span:nth-child(2) {
            opacity: 0;
        }

        &.active span:nth-child(3) {
            transform: translateY(-7px) rotate(-45deg);
        }
    }

    .nav-actions {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .theme-toggle {
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        border-radius: 50px;
        padding-block: 0.5rem;
        padding-inline: 1rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-size: 0.9rem;
        color: var(--text-secondary);
        transition: all 0.3s ease;

        &:hover {
            border-color: var(--border-hover);
            transform: translateZ(0) translateY(-2px);
        }
    }

    .theme-toggle-icon {
        font-size: 1.2rem;
    }

    .cta-button {
        background: var(--gradient-primary);
        color: var(--bg-primary);
        padding-block: 0.75rem;
        padding-inline: 1.5rem;
        border-radius: 50px;
        text-decoration: none;
        font-weight: 600;
        transition: transform 0.3s, box-shadow 0.3s;
        border: none;
        cursor: pointer;

        &:hover {
            transform: translateZ(0) translateY(-2px);
        }
    }

    .user-menu {
        position: relative;
    }

    .user-button {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        padding-block: 0.5rem;
        padding-inline: 1rem;
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        border-radius: 50px;
        cursor: pointer;
        transition: all 0.3s ease;
        color: var(--text-primary);

        &:hover {
            border-color: var(--border-hover);
            transform: translateZ(0) translateY(-2px);
        }
    }

    .user-avatar {
        inline-size: 32px;
        block-size: 32px;
        border-radius: 50%;
        background: var(--gradient-primary);
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 700;
        font-size: 0.9rem;
        color: var(--bg-primary);
    }

    .user-dropdown {
        position: absolute;
        inset-block-start: calc(100% + 0.5rem);
        inset-inline-end: 0;
        min-inline-size: 200px;
        background: var(--bg-secondary);
        border: 1px solid var(--border-color);
        border-radius: 12px;
        box-shadow: 0 20px 60px oklch(0 0 0 / 0.2);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        z-index: 1000;

        &.show {
            opacity: 1;
            visibility: visible;
            transform: translateY(0);
        }

        & a {
            display: block;
            padding-block: 0.75rem;
            padding-inline: 1.25rem;
            color: var(--text-secondary);
            text-decoration: none;
            transition: all 0.2s ease;

            &:hover {
                background: var(--bg-card);
                color: var(--cyan);
            }

            &:first-child {
                border-start-start-radius: 12px;
                border-start-end-radius: 12px;
            }

            &:last-child {
                border-end-start-radius: 12px;
                border-end-end-radius: 12px;
            }
        }

        & hr {
            border: none;
            border-block-start: 1px solid var(--border-color);
            margin-block: 0.5rem;
        }
    }
}
} /* End components layer */

/* ============================================
   LAYER: OVERRIDES
   ============================================ */
@layer overrides {
    /* CTA button fix for all CTA sections */
    .final-cta a.cta-button,
    .final-cta a.cta-button:link,
    .final-cta a.cta-button:visited,
    .final-cta a.cta-button:active,
    .topic-cta a.cta-button,
    .topic-cta a.cta-button:link,
    .topic-cta a.cta-button:visited,
    .topic-cta a.cta-button:active {
        background: var(--gradient-primary) !important;
        color: var(--bg-primary) !important;
        padding: 1rem 2rem !important;
        border-radius: 50px !important;
        text-decoration: none !important;
        font-weight: 600 !important;
        font-size: 1.1rem !important;
        display: inline-block !important;
        transition: transform 0.3s, box-shadow 0.3s !important;
        border: none !important;
        cursor: pointer !important;
    }

    .final-cta a.cta-button:hover,
    .topic-cta a.cta-button:hover {
        transform: translateY(-2px) !important;
    }

    /* Theme overrides for nav */
    [data-theme="dark"] nav .logo {
    filter: drop-shadow(0 0 20px oklch(0.9 0.15 195 / 0.5));
}

[data-theme="light"] nav .nav-links a:hover {
    color: var(--cyan);
}

[data-theme="dark"] nav .cta-button {
    box-shadow: 0 0 20px oklch(0.9 0.15 195 / 0.5), 0 0 40px oklch(0.7 0.3 330 / 0.3);
}

[data-theme="light"] nav .cta-button {
    box-shadow: 0 4px 15px oklch(0.7 0.12 210 / 0.3);
}

[data-theme="dark"] nav .cta-button:hover {
    box-shadow: 0 0 30px oklch(0.9 0.15 195 / 0.8), 0 0 60px oklch(0.7 0.3 330 / 0.5);
}

[data-theme="light"] nav .cta-button:hover {
    box-shadow: 0 8px 25px oklch(0.7 0.12 210 / 0.4);
}

/* Hero Section */
@scope (.hero) {
    :scope {
        margin-top: 80px;
        padding-block: 100px;
        background: var(--bg-primary);
        position: relative;
        overflow: hidden;
        transition: background 0.3s ease;
    }

    :scope::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-image:
            linear-gradient(var(--grid-color) 1px, transparent 1px),
            linear-gradient(90deg, var(--grid-color) 1px, transparent 1px);
        background-size: 50px 50px;
        animation: gridMove 20s linear infinite;
    }

    :scope::after {
        content: '';
        position: absolute;
        top: -50%;
        right: -10%;
        width: 80%;
        height: 150%;
        background: radial-gradient(circle, var(--radial-glow) 0%, transparent 70%);
        animation: float 20s ease-in-out infinite;
    }

    .container {
        display: grid;
        grid-template-columns: 2fr 3.5fr;
        gap: 3rem;
        align-items: center;
        position: relative;
        z-index: 1;
    }

    .hero-content {
        & .hero-tagline {
            font-size: 0.85rem;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.1em;
            color: var(--cyan);
            margin-block-end: 0.5rem;
        }

        & .hero-headline {
            font-size: 2.2rem;
            font-weight: 700;
            line-height: 1.3;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & .gradient-text {
            background: var(--gradient-primary);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }

        & p {
            font-size: 1rem;
            color: var(--text-secondary);
            margin-block-end: 1rem;
            line-height: 1.6;
            transition: color 0.3s ease;
        }
    }

    .hero-buttons {
        display: flex;
        gap: 1rem;
    }

    .cta-button {
        background: var(--gradient-primary);
        color: var(--bg-primary);
        padding-block: 0.75rem;
        padding-inline: 1.5rem;
        border-radius: 50px;
        text-decoration: none;
        font-weight: 600;
        transition: transform 0.3s, box-shadow 0.3s;
        border: none;
        cursor: pointer;
        font-size: 1rem;

        &:hover {
            transform: translateZ(0) translateY(-2px);
        }
    }

    .secondary-button {
        background: var(--bg-card);
        color: var(--text-primary);
        padding-block: 0.75rem;
        padding-inline: 1.5rem;
        border-radius: 50px;
        text-decoration: none;
        font-weight: 600;
        border: 2px solid var(--border-color);
        transition: all 0.3s;
        backdrop-filter: blur(10px);

        &:hover {
            border-color: var(--border-hover);
            transform: translateZ(0) translateY(-2px);
        }
    }

    .hero-visual {
        position: relative;
        height: 500px;
    }

    .card-demo {
        position: absolute;
        background: var(--bg-card);
        backdrop-filter: blur(20px);
        border: 1px solid var(--border-color);
        border-radius: 20px;
        padding: 2rem;
        animation: cardFloat 6s ease-in-out infinite;
        transition: background 0.3s ease, border-color 0.3s ease;
        box-shadow: 0 20px 60px oklch(0.9 0.15 195 / 0.2), 0 0 40px oklch(0.7 0.3 330 / 0.1);

        &:hover {
            animation-play-state: paused;
        }
    }

    .card-demo:nth-child(1) {
        top: 10%;
        left: 10%;
        width: 300px;
        animation-delay: 0s;
    }

    .card-demo:nth-child(2) {
        top: 40%;
        right: 5%;
        width: 280px;
        animation-delay: 2s;
    }

    .card-demo:nth-child(3) {
        bottom: 10%;
        left: 20%;
        width: 260px;
        animation-delay: 4s;
    }

    .card-question {
        font-size: 1.1rem;
        color: var(--text-tertiary);
        margin-block-end: 1rem;
        transition: color 0.3s ease;
    }

    .card-answer {
        font-size: 2rem;
        font-weight: 700;
        margin-block-end: 1.5rem;
        transition: color 0.3s ease, text-shadow 0.3s ease;
        color: var(--cyan);
        text-shadow: 0 0 20px var(--cyan-bright);
    }

    .card-status {
        display: inline-block;
        padding: 0.5rem 1rem;
        border-radius: 50px;
        font-size: 0.85rem;
        font-weight: 600;
    }

    .status-learning {
        background: oklch(0.7 0.18 50 / 0.2);
        color: var(--orange);
        border: 1px solid var(--orange);
        box-shadow: 0 0 10px oklch(0.7 0.18 50 / 0.3);
    }

    .status-mastered {
        background: oklch(0.8 0.2 150 / 0.2);
        color: var(--green);
        border: 1px solid var(--green);
        box-shadow: 0 0 10px oklch(0.8 0.2 150 / 0.3);
    }
}

/* Animations */
@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    50% { transform: translate(-20px, 20px) rotate(5deg); }
}

@keyframes cardFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Theme-specific overrides for hero */
[data-theme="dark"] .hero .hero-content .gradient-text {
    filter: drop-shadow(0 0 20px oklch(0.9 0.15 195 / 0.5));
}

[data-theme="dark"] .hero .cta-button {
    box-shadow: 0 0 20px oklch(0.9 0.15 195 / 0.5), 0 0 40px oklch(0.7 0.3 330 / 0.3);

    &:hover {
        box-shadow: 0 0 30px oklch(0.9 0.15 195 / 0.8), 0 0 60px oklch(0.7 0.3 330 / 0.5);
    }
}

[data-theme="light"] .hero .cta-button {
    box-shadow: 0 4px 15px oklch(0.7 0.12 210 / 0.3);

    &:hover {
        box-shadow: 0 8px 25px oklch(0.7 0.12 210 / 0.4);
    }
}

[data-theme="dark"] .hero .secondary-button {
    box-shadow: 0 0 20px oklch(0.9 0.15 195 / 0.3);

    &:hover {
        box-shadow: 0 0 30px oklch(0.9 0.15 195 / 0.6);
    }
}

[data-theme="light"] .hero .secondary-button:hover {
    box-shadow: 0 4px 15px oklch(0.7 0.12 210 / 0.3);
}

[data-theme="light"] .hero .card-answer {
    color: var(--cyan);
    text-shadow: none;
}

[data-theme="light"] .hero .card-demo {
    box-shadow: 0 20px 60px oklch(0 0 0 / 0.1);
}

/* Hero Try-It Form Styles */
.hero .hero-try-form {
    margin-block: 1.5rem;
}

.hero .try-input-group {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.hero .try-input-group input {
    flex: 1;
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
    border: 2px solid var(--cyan-dim);
    border-radius: 14px;
    background: var(--bg-card);
    color: var(--cyan);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.hero .try-input-group input:focus {
    outline: none;
    border-color: var(--cyan);
    box-shadow: 0 0 25px var(--cyan-dim);
    transform: translateY(-2px);
}

.hero .try-input-group input::placeholder {
    color: var(--cyan) !important;
    opacity: 1 !important;
    -webkit-text-fill-color: var(--cyan);
}

.hero .try-input-group input::-webkit-input-placeholder {
    color: var(--cyan) !important;
    opacity: 1 !important;
    -webkit-text-fill-color: var(--cyan);
}

.hero .try-input-group input::-moz-placeholder {
    color: var(--cyan) !important;
    opacity: 1 !important;
}

.hero .try-input-group button {
    white-space: nowrap;
    padding: 1rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--bg-primary);
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.hero .try-input-group button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px var(--cyan-dim);
}

.hero .try-input-group button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.hero .try-hint {
    font-size: 0.85rem;
    color: var(--text-tertiary);
    margin: 0;
}

.hero .hero-topics {
    margin-top: 1.5rem;
}

.hero .hero-topics .popular-topics-label {
    font-size: 0.9rem;
    color: var(--text-tertiary);
    margin-bottom: 0.75rem;
}

.hero .hero-topics .topic-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hero .hero-topics .topic-pill {
    padding: 0.4rem 0.9rem;
    font-size: 0.85rem;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-secondary);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
}

.hero .hero-topics .topic-pill:hover {
    border-color: var(--cyan);
    color: var(--cyan);
}

/* Hero Visual - Demo cards and Results */
.hero .hero-demo-cards {
    position: relative;
    height: 100%;
}

.hero .hero-visual .try-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
}

.hero .hero-visual .try-cards-container {
    width: 100%;
    max-width: 500px;
}

.hero .hero-visual .try-results-cta {
    margin-top: 1.5rem;
}

.hero .hero-visual .try-results-cta p {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.hero .hero-visual .try-results-cta .cta-button {
    display: inline-block;
    background: var(--gradient-primary);
    color: var(--bg-primary);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

.hero .hero-visual .try-results-cta .cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px var(--cyan-dim);
}

.hero .hero-visual .try-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.hero .hero-visual .try-loading .spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: var(--cyan);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

.hero .hero-visual .try-loading p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.hero .hero-visual .try-error {
    padding: 1rem 1.5rem;
    background: oklch(0.4 0.15 20 / 0.2);
    border: 1px solid oklch(0.65 0.2 25);
    border-radius: 12px;
    color: oklch(0.8 0.15 25);
    text-align: center;
}

/* Try Results Section - Shows generated cards */
.try-results-section {
    padding-block: 60px 80px;
    background: linear-gradient(
        180deg,
        var(--bg-secondary) 0%,
        var(--bg-primary) 50%,
        var(--bg-secondary) 100%
    );
    text-align: center;
    position: relative;
    overflow: hidden;
    border-top: 2px solid var(--cyan);
    border-bottom: 2px solid var(--cyan);
}

.try-results-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 100% 60% at 50% 0%, var(--cyan) 0%, transparent 60%);
    opacity: 0.4;
    pointer-events: none;
}

.try-results-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 100% 60% at 50% 100%, var(--cyan) 0%, transparent 60%);
    opacity: 0.25;
    pointer-events: none;
}

.try-results-section .try-results {
    position: relative;
    z-index: 1;
}

.try-results-section .try-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 1000px;
    margin-inline: auto;
    margin-bottom: 2rem;
    padding-inline: 1rem;
}

.try-results-section .try-card {
    perspective: 1000px;
    height: 200px;
    cursor: pointer;
}

.try-results-section .try-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.try-results-section .try-card.flipped .try-card-inner {
    transform: rotateY(180deg);
}

.try-results-section .try-card-front,
.try-results-section .try-card-back {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 2px solid var(--border-color);
    background: var(--bg-card);
    box-shadow: 0 10px 30px oklch(0 0 0 / 0.2);
}

.try-results-section .try-card-front {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%);
}

.try-results-section .try-card-back {
    background: var(--gradient-primary);
    transform: rotateY(180deg);
}

.try-results-section .try-card-number {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--cyan-dim);
    color: var(--cyan);
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.try-results-section .try-card-question {
    font-size: 1.1rem;
    color: var(--text-primary);
    text-align: center;
    line-height: 1.5;
}

.try-results-section .try-card-hint {
    position: absolute;
    bottom: 0.75rem;
    font-size: 0.8rem;
    color: var(--cyan);
    opacity: 0.8;
    font-weight: 500;
}

.try-results-section .try-card-answer {
    font-size: 1.3rem;
    font-weight: 600;
    color: white;
    text-align: center;
    text-shadow: 0 2px 10px oklch(0 0 0 / 0.3);
}

.try-results-section .try-results-cta {
    margin-top: 2rem;
    position: relative;
    z-index: 1;
}

.try-results-section .try-results-cta p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.try-results-section .try-results-cta .cta-button {
    background: var(--gradient-primary);
    color: var(--bg-primary);
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    display: inline-block;
    transition: transform 0.2s, box-shadow 0.2s;
}

.try-results-section .try-results-cta .cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--cyan-dim);
}

.try-results-section .try-loading {
    padding: 3rem;
    position: relative;
    z-index: 1;
}

.try-results-section .try-loading .spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: var(--cyan);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-inline: auto;
    margin-bottom: 1rem;
}

.try-results-section .try-loading p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.try-results-section .try-error {
    padding: 1rem 2rem;
    background: oklch(0.4 0.15 20 / 0.2);
    border: 1px solid oklch(0.65 0.2 25);
    border-radius: 12px;
    color: oklch(0.8 0.15 25);
    max-width: 500px;
    margin-inline: auto;
    position: relative;
    z-index: 1;
}

/* Try It Section - Anonymous AI Generation */
@scope (.try-it-section) {
    :scope {
        padding-block: 110px 132px;
        background: linear-gradient(
            180deg,
            var(--bg-secondary) 0%,
            var(--bg-primary) 50%,
            var(--bg-secondary) 100%
        );
        text-align: center;
        position: relative;
        overflow: hidden;
        border-top: 2px solid var(--cyan);
        border-bottom: 2px solid var(--cyan);
    }

    :scope::before {
        content: '';
        position: absolute;
        inset: 0;
        background: radial-gradient(ellipse 100% 60% at 50% 0%, var(--cyan) 0%, transparent 60%);
        opacity: 0.4;
        pointer-events: none;
    }

    :scope::after {
        content: '';
        position: absolute;
        inset: 0;
        background: radial-gradient(ellipse 100% 60% at 50% 100%, var(--cyan) 0%, transparent 60%);
        opacity: 0.25;
        pointer-events: none;
    }

    h2 {
        font-size: clamp(2.2rem, 5.5vw, 3.3rem);
        color: var(--text-primary);
        margin-bottom: 1.1rem;
        position: relative;
        z-index: 1;
        font-weight: 700;
    }

    & > .container > p {
        color: var(--text-secondary);
        font-size: 1.375rem;
        margin-bottom: 2.75rem;
        position: relative;
        z-index: 1;
    }

    .try-generate-form {
        max-width: 770px;
        margin-inline: auto;
        position: relative;
        z-index: 1;
    }

    .try-input-group {
        display: flex;
        gap: 0.825rem;
        margin-bottom: 1.1rem;
    }

    .try-input-group input {
        flex: 1;
        padding: 1.375rem 1.65rem;
        font-size: 1.21rem;
        border: 2px solid var(--cyan-dim);
        border-radius: 18px;
        background: var(--bg-card);
        color: var(--text-primary);
        transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
    }

    .try-input-group input:focus {
        outline: none;
        border-color: var(--cyan);
        box-shadow: 0 0 33px var(--cyan-dim);
        transform: translateY(-2px);
    }

    .try-input-group input::placeholder {
        color: var(--text-primary);
        opacity: 0.5;
    }

    .try-input-group button {
        white-space: nowrap;
        padding: 1.1rem 1.65rem;
        background: var(--gradient-primary);
        color: var(--bg-primary);
        border: none;
        border-radius: 13px;
        font-size: 1.1rem;
        font-weight: 600;
        cursor: pointer;
        transition: transform 0.2s, box-shadow 0.2s;
    }

    .try-input-group button:hover {
        transform: translateY(-2px);
        box-shadow: 0 0 20px var(--cyan-dim);
    }

    .try-input-group button:disabled {
        opacity: 0.6;
        cursor: not-allowed;
        transform: none;
    }

    .try-hint {
        font-size: 0.85rem;
        color: var(--text-tertiary);
    }

    .try-results {
        margin-top: 3rem;
        position: relative;
        z-index: 1;
    }

    .try-cards-container {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 1.5rem;
        max-width: 1000px;
        margin-inline: auto;
        margin-bottom: 2rem;
        padding-inline: 1rem;
    }

    .try-card {
        perspective: 1000px;
        height: 200px;
        cursor: pointer;
    }

    .try-card-inner {
        position: relative;
        width: 100%;
        height: 100%;
        transition: transform 0.6s;
        transform-style: preserve-3d;
    }

    .try-card.flipped .try-card-inner {
        transform: rotateY(180deg);
    }

    .try-card-front,
    .try-card-back {
        position: absolute;
        inset: 0;
        backface-visibility: hidden;
        border-radius: 16px;
        padding: 1.5rem;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        border: 2px solid var(--border-color);
        background: var(--bg-card);
        box-shadow: 0 10px 30px oklch(0 0 0 / 0.2);
    }

    .try-card-front {
        background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%);
    }

    .try-card-back {
        background: var(--gradient-primary);
        transform: rotateY(180deg);
    }

    .try-card-number {
        position: absolute;
        top: 0.75rem;
        left: 0.75rem;
        width: 28px;
        height: 28px;
        border-radius: 50%;
        background: var(--cyan-dim);
        color: var(--cyan);
        font-size: 0.85rem;
        font-weight: 600;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .try-card-question {
        font-size: 1.1rem;
        color: var(--text-primary);
        text-align: center;
        line-height: 1.5;
    }

    .try-card-hint {
        position: absolute;
        bottom: 0.75rem;
        font-size: 0.8rem;
        color: var(--cyan);
        opacity: 0.8;
        font-weight: 500;
    }

    .try-card-answer {
        font-size: 1.3rem;
        font-weight: 600;
        color: white;
        text-align: center;
        text-shadow: 0 2px 10px oklch(0 0 0 / 0.3);
    }

    .try-results-cta {
        margin-top: 2rem;
    }

    .try-results-cta p {
        font-size: 1.1rem;
        color: var(--text-secondary);
        margin-bottom: 1rem;
    }

    .try-loading {
        padding: 3rem;
        position: relative;
        z-index: 1;
    }

    .try-loading .spinner {
        width: 48px;
        height: 48px;
        border: 4px solid var(--border-color);
        border-top-color: var(--cyan);
        border-radius: 50%;
        animation: spin 1s linear infinite;
        margin-inline: auto;
        margin-bottom: 1rem;
    }

    @keyframes spin {
        to { transform: rotate(360deg); }
    }

    .try-loading p {
        color: var(--text-secondary);
    }

    .try-error {
        padding: 1rem 2rem;
        background: oklch(0.4 0.15 25 / 0.2);
        border: 1px solid oklch(0.6 0.2 25);
        border-radius: 8px;
        color: oklch(0.8 0.15 25);
        max-width: 500px;
        margin-inline: auto;
        margin-top: 1rem;
        position: relative;
        z-index: 1;
    }

    .hidden {
        display: none !important;
    }
}

/* Try-it input and button overrides (outside @scope for better browser support) */
/* Each pseudo-element must be separate - combined rules fail in some browsers */
/* Using opacity: 1 to prevent accumulation from other rules */
.try-it-section .try-input-group input::placeholder {
    color: oklch(0.89 0.2 194.41) !important;
    opacity: 1 !important;
}
.try-it-section .try-input-group input::-webkit-input-placeholder {
    color: oklch(0.89 0.2 194.41) !important;
    opacity: 1 !important;
}
.try-it-section .try-input-group input::-moz-placeholder {
    color: oklch(0.89 0.2 194.41) !important;
    opacity: 1 !important;
}

[data-theme="light"] .try-it-section .try-input-group input::placeholder {
    color: oklch(0.5 0.08 210) !important;
    opacity: 1 !important;
}
[data-theme="light"] .try-it-section .try-input-group input::-webkit-input-placeholder {
    color: oklch(0.5 0.08 210) !important;
    opacity: 1 !important;
}
[data-theme="light"] .try-it-section .try-input-group input::-moz-placeholder {
    color: oklch(0.5 0.08 210) !important;
    opacity: 1 !important;
}

.try-it-section .try-input-group button {
    background: var(--gradient-primary);
    color: var(--bg-primary);
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    padding: 1rem 1.5rem;
}

.try-it-section .try-results-cta .cta-button {
    display: inline-block;
    background: var(--gradient-primary);
    color: var(--bg-primary);
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.try-it-section .try-results-cta .cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px var(--cyan-dim);
}

/* Try-it responsive */
@media (max-width: 600px) {
    .try-it-section .try-input-group {
        flex-direction: column;
    }

    .try-it-section .try-input-group button {
        width: 100%;
    }

    .try-it-section .try-cards-container {
        grid-template-columns: 1fr;
    }
}

/* Popular Topics Pills */
.popular-topics {
    margin-top: 2rem;
    text-align: center;
}

.popular-topics-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.topic-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.topic-pill {
    display: inline-block;
    padding: 0.4rem 0.9rem;
    background: var(--bg-secondary);
    border: 1px solid var(--cyan-dim);
    border-radius: 20px;
    color: var(--text-primary);
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.topic-pill:hover {
    background: var(--cyan-dim);
    color: var(--bg-primary);
    transform: translateY(-2px);
}

a.topic-pill {
    background: linear-gradient(135deg, var(--cyan-dim) 0%, var(--orange) 100%);
    color: var(--bg-primary);
    font-weight: 500;
}

a.topic-pill:hover {
    box-shadow: 0 0 15px var(--cyan-dim);
}

/* Challenge Mode - Type it in 10 seconds */
.challenge-card {
    background: var(--bg-card);
    border: 2px solid var(--cyan-dim);
    border-radius: 16px;
    padding: 2rem;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    transition: all 0.3s ease;
}

.challenge-card.timer-critical {
    animation: pulse-danger 0.5s ease infinite;
    border-color: var(--orange);
}

.challenge-card.exploding {
    animation: explode 0.6s ease forwards;
}

.challenge-card.success {
    animation: success-flash 0.5s ease;
    border-color: #4ade80;
}

@keyframes pulse-danger {
    0%, 100% { box-shadow: 0 0 20px oklch(0.7 0.2 30 / 0.3); }
    50% { box-shadow: 0 0 40px oklch(0.7 0.2 30 / 0.6); }
}

@keyframes explode {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); }
    100% { transform: scale(0.8); opacity: 0; }
}

@keyframes success-flash {
    0% { background: var(--bg-card); }
    50% { background: oklch(0.5 0.2 140 / 0.3); }
    100% { background: var(--bg-card); }
}

.challenge-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.challenge-progress {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.challenge-timer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timer-icon {
    font-size: 1.5rem;
    animation: shake 0.5s ease infinite;
}

@keyframes shake {
    0%, 100% { transform: rotate(-5deg); }
    50% { transform: rotate(5deg); }
}

.timer-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--orange);
    min-width: 2ch;
    text-align: center;
}

.timer-bar {
    width: 100px;
    height: 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    overflow: hidden;
}

.timer-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--orange), var(--cyan));
    transition: width 1s linear;
    border-radius: 4px;
}

.challenge-question {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
}

.challenge-question p {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.5;
}

.challenge-letters-zone {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    min-height: 50px;
    padding: 1rem;
    margin-bottom: 1rem;
    border: 2px dashed var(--border-color);
    border-radius: 12px;
}

.shuffled-letter {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--cyan);
    background: var(--bg-secondary);
    padding: 0.35rem 0.5rem;
    border-radius: 6px;
    border: 1px solid var(--cyan-dim);
    animation: pop-in 0.3s ease backwards;
    transition: all 0.3s ease;
    display: inline-block;
}

.shuffled-letter.locked {
    opacity: 0.25;
    transform: scale(0.7) !important;
    background: transparent;
    border-color: transparent;
}

@keyframes pop-in {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
}

.challenge-answer-zone {
    margin-bottom: 1rem;
}

.answer-slots {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    justify-content: center;
    font-family: monospace;
}

.answer-slot {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-secondary);
    min-width: 1.2ch;
    text-align: center;
    border-bottom: 2px solid var(--border-color);
    padding: 0.25rem 0.1rem;
    transition: all 0.2s ease;
}

.answer-slot.filled {
    color: var(--cyan);
    border-bottom-color: var(--cyan);
}

.answer-slot.revealed {
    color: var(--orange);
    border-bottom-color: var(--orange);
    animation: reveal-pop 0.3s ease;
}

@keyframes reveal-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.answer-slot.wrong {
    animation: wrong-shake 0.2s ease;
    color: var(--orange);
    border-bottom-color: var(--orange);
}

@keyframes wrong-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}

.challenge-input-zone {
    margin-top: 1rem;
}

.challenge-input {
    width: 100%;
    padding: 1rem;
    font-size: 1.2rem;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-primary);
    text-align: center;
    font-family: monospace;
    letter-spacing: 0.1em;
}

.challenge-input:focus {
    outline: none;
    border-color: var(--cyan);
    box-shadow: 0 0 20px var(--cyan-dim);
}

/* Explosion screen */
.challenge-explosion {
    text-align: center;
    padding: 3rem 2rem;
    animation: fade-in 0.3s ease;
}

@keyframes fade-in {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.explosion-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: explosion-pop 0.5s ease;
}

@keyframes explosion-pop {
    0% { transform: scale(0); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.challenge-explosion h3 {
    font-size: 1.5rem;
    color: var(--orange);
    margin-bottom: 0.5rem;
}

.correct-answer-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.correct-answer-display {
    background: var(--bg-secondary);
    border: 2px solid var(--cyan-dim);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
    display: inline-block;
}

.correct-answer-display .answer-slots {
    gap: 0.2rem;
}

.correct-answer-display .answer-slot {
    font-size: 1.2rem;
    padding: 0.1rem;
    border-bottom: none;
    background: var(--bg-card);
    border-radius: 4px;
    animation: letter-reveal 0.3s ease backwards;
}

@keyframes letter-reveal {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
}

.explosion-buttons {
    margin-top: 1rem;
}

.retry-btn, .skip-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    margin: 0.5rem;
    transition: all 0.2s ease;
}

.retry-btn {
    background: var(--bg-secondary);
    border: 2px solid var(--orange);
    color: var(--orange);
}

.retry-btn:hover {
    background: var(--orange);
    color: var(--bg-primary);
}

.skip-btn {
    background: var(--gradient-primary);
    border: none;
    color: var(--bg-primary);
}

.skip-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px var(--cyan-dim);
}

/* Challenge complete */
.challenge-complete {
    text-align: center;
    padding: 3rem 2rem;
    animation: fade-in 0.5s ease;
}

.challenge-complete-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.challenge-complete h3 {
    font-size: 1.8rem;
    color: var(--cyan);
    margin-bottom: 0.5rem;
}

.challenge-complete p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Challenge responsive */
@media (max-width: 600px) {
    .challenge-card {
        padding: 1rem;
    }

    .challenge-letters-zone {
        gap: 0.3rem;
        padding: 0.75rem;
    }

    .shuffled-letter {
        font-size: 1.1rem;
        padding: 0.25rem 0.4rem;
    }

    .answer-slot {
        font-size: 1rem;
    }

    .challenge-input {
        font-size: 1rem;
    }

    .timer-bar {
        width: 60px;
    }
}

/* Sub-Hero / Value Proposition Section */
@scope (.sub-hero) {
    :scope {
        padding-block: 60px;
        background: linear-gradient(
            180deg,
            var(--bg-primary) 0%,
            var(--bg-secondary) 50%,
            var(--bg-primary) 100%
        );
        border-top: 2px solid var(--cyan-dim);
        border-bottom: 2px solid var(--cyan-dim);
        position: relative;
        overflow: hidden;
    }

    /* Animated gradient background */
    :scope::before {
        content: '';
        position: absolute;
        inset: 0;
        background:
            radial-gradient(circle at 20% 50%, var(--cyan-dim) 0%, transparent 50%),
            radial-gradient(circle at 80% 50%, var(--magenta-dim) 0%, transparent 50%);
        opacity: 0.4;
        animation: bgShift 10s ease-in-out infinite;
        pointer-events: none;
    }

    @keyframes bgShift {
        0%, 100% {
            transform: translateX(0) scale(1);
        }
        50% {
            transform: translateX(20px) scale(1.1);
        }
    }

    .sub-hero-text {
        max-width: 900px;
        margin-inline: auto;
        text-align: center;
        font-size: 1.35rem;
        line-height: 2;
        color: var(--text-primary);
        font-weight: 500;
        position: relative;
        z-index: 1;
        text-shadow: 0 2px 20px oklch(0 0 0 / 0.3);
        padding-inline: 2rem;
    }
}

/* Theme-specific enhancements */
[data-theme="dark"] .sub-hero {
    border-color: var(--cyan-bright);
}

[data-theme="dark"] .sub-hero::before {
    opacity: 0.5;
}

[data-theme="dark"] .sub-hero-text {
    text-shadow: 0 2px 30px oklch(0.7 0.15 195 / 0.4);
}

[data-theme="light"] .sub-hero {
    background: linear-gradient(
        180deg,
        oklch(0.97 0.01 250) 0%,
        oklch(0.99 0.005 220) 50%,
        oklch(0.97 0.01 250) 100%
    );
    border-color: oklch(0.7 0.15 195 / 0.3);
}

[data-theme="light"] .sub-hero::before {
    opacity: 0.3;
}

[data-theme="light"] .sub-hero-text {
    text-shadow: 0 1px 10px oklch(1 0 0 / 0.2);
    color: oklch(0.2 0.02 250);
}

/* Features Section */
@scope (.features) {
    :scope {
        padding-block: 100px;
        background: var(--bg-primary);
        transition: background 0.3s ease;
    }

    .section-header {
        text-align: center;
        margin-block-end: 4rem;

        & h2 {
            font-size: 2.5rem;
            font-weight: 700;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            font-size: 1.2rem;
            color: var(--text-secondary);
            max-width: 600px;
            margin: 0 auto;
            transition: color 0.3s ease;
        }
    }

    .features-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 3rem;
    }

    .feature-card {
        padding: 2rem;
        border-radius: 20px;
        background: var(--bg-card);
        backdrop-filter: blur(20px);
        border: 1px solid var(--border-color);
        transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s, background 0.3s;

        &:hover {
            transform: translateY(-10px);
            border-color: var(--border-hover);
        }

        &:nth-child(1) .feature-icon {
            background: var(--gradient-secondary);
        }

        &:nth-child(2) .feature-icon {
            background: linear-gradient(135deg, var(--magenta) 0%, oklch(0.65 0.28 350) 100%);
        }

        &:nth-child(3) .feature-icon {
            background: linear-gradient(135deg, oklch(0.6 0.25 290) 0%, var(--magenta) 100%);
        }

        &:nth-child(4) .feature-icon {
            background: linear-gradient(135deg, var(--green) 0%, var(--cyan) 100%);
        }

        &:nth-child(5) .feature-icon {
            background: linear-gradient(135deg, var(--orange) 0%, var(--yellow) 100%);
        }

        &:nth-child(6) .feature-icon {
            background: var(--gradient-primary);
        }

        & h3 {
            font-size: 1.5rem;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            color: var(--text-secondary);
            line-height: 1.8;
            transition: color 0.3s ease;
        }
    }

    .feature-icon {
        width: 60px;
        height: 60px;
        border-radius: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2rem;
        margin-block-end: 1.5rem;
        box-shadow: 0 0 20px oklch(0.9 0.15 195 / 0.3);
    }
}

/* Theme overrides for features */
[data-theme="dark"] .features .feature-card:hover {
    box-shadow: 0 20px 40px oklch(0.9 0.15 195 / 0.3);
}

[data-theme="light"] .features .feature-card:hover {
    box-shadow: 0 20px 40px oklch(0.7 0.12 210 / 0.2);
}

/* Use Cases Section */
@scope (.use-cases) {
    :scope {
        padding-block: 100px;
        background: var(--bg-secondary);
        position: relative;
        transition: background 0.3s ease;
    }

    .section-header {
        text-align: center;
        margin-block-end: 4rem;

        & h2 {
            font-size: 2.5rem;
            font-weight: 700;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            font-size: 1.2rem;
            color: var(--text-secondary);
            max-width: 600px;
            margin: 0 auto;
            transition: color 0.3s ease;
        }
    }

    .use-cases-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 2rem;
    }

    .use-case-card {
        padding: 2rem;
        border-radius: 20px;
        background: var(--bg-card);
        backdrop-filter: blur(20px);
        border: 1px solid var(--border-color);
        transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s, background 0.3s;

        &:hover {
            transform: translateY(-5px);
            border-color: var(--border-hover);
        }

        & h3 {
            font-size: 1.4rem;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            color: var(--text-secondary);
            line-height: 1.8;
            transition: color 0.3s ease;
        }

        & strong {
            color: var(--cyan);
            font-weight: 600;
        }
    }
}

/* Theme overrides for use cases */
[data-theme="dark"] .use-cases .use-case-card:hover {
    box-shadow: 0 15px 35px oklch(0.9 0.15 195 / 0.25);
}

[data-theme="light"] .use-cases .use-case-card:hover {
    box-shadow: 0 15px 35px oklch(0.7 0.12 210 / 0.18);
}

/* How It Works */
@scope (.how-it-works) {
    :scope {
        padding-block: 100px;
        background: var(--bg-secondary);
        position: relative;
        transition: background 0.3s ease;

        &::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-image:
                radial-gradient(circle at 20% 50%, var(--radial-glow) 0%, transparent 50%),
                radial-gradient(circle at 80% 50%, var(--radial-glow) 0%, transparent 50%);
            opacity: 0.5;
        }
    }

    .section-header {
        text-align: center;
        margin-block-end: 4rem;

        & h2 {
            font-size: 2.5rem;
            font-weight: 700;
            margin-block-end: 1rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            font-size: 1.2rem;
            color: var(--text-secondary);
            max-width: 600px;
            margin: 0 auto;
            transition: color 0.3s ease;
        }
    }

    .steps {
        display: flex;
        flex-direction: column;
        gap: 4rem;
        margin-top: 4rem;
        position: relative;
        z-index: 1;
        max-width: 900px;
        margin-inline: auto;
    }

    .step {
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-rows: auto auto auto;
        column-gap: 2rem;
        row-gap: 0.75rem;
        align-items: start;
        text-align: left;
        position: relative;

        & h3 {
            font-size: 1.5rem;
            margin-block-end: 0.5rem;
            color: var(--text-primary);
            transition: color 0.3s ease;
        }

        & p {
            color: var(--text-secondary);
            line-height: 1.8;
            transition: color 0.3s ease;
        }
    }

    .step-number {
        width: 50px;
        height: 50px;
        border-radius: 50%;
        background: var(--gradient-primary);
        color: var(--bg-primary);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.25rem;
        font-weight: 700;
        grid-row: 1 / 4;
        grid-column: 1;
        align-self: start;
        margin-top: 0.5rem;
        transition: box-shadow 0.3s ease;
    }

    .step-image-container {
        grid-column: 2;
        grid-row: 1;
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 16 / 10;
        border-radius: 16px;
        overflow: hidden;
        background: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    }

    .step-image {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border-radius: 14px;
    }

    .step h3 {
        grid-column: 2;
        grid-row: 2;
    }

    .step p {
        grid-column: 2;
        grid-row: 3;
    }

    /* Placeholder style when image fails to load */
    .step-image-container:has(img[src=""]),
    .step-image-container:has(img:not([src])) {
        &::after {
            content: '📷';
            font-size: 3rem;
            opacity: 0.5;
        }
    }
}

/* Theme overrides for How It Works */
[data-theme="dark"] .how-it-works .step-number {
    box-shadow: 0 0 30px oklch(0.9 0.15 195 / 0.5), 0 0 60px oklch(0.7 0.3 330 / 0.3);
}

[data-theme="light"] .how-it-works .step-number {
    box-shadow: 0 10px 30px oklch(0.7 0.12 210 / 0.3);
}

/* Step image click hint */
.step-image-container {
    cursor: zoom-in;
}

/* Image zoom modal */
.image-zoom-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 2rem;
    cursor: zoom-out;
    animation: fadeIn 0.2s ease;
}

.image-zoom-modal.active {
    display: flex;
}

.image-zoom-modal img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.2s ease;
}

.image-zoom-modal .close-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.image-zoom-modal .close-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes zoomIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Login Provider Dialog */
.login-dialog-overlay {
    position: fixed;
    inset: 0;
    background: oklch(0 0 0 / 0.7);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.login-dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.login-dialog {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    max-width: 400px;
    width: 90%;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px oklch(0 0 0 / 0.3);
}

.login-dialog-overlay.active .login-dialog {
    transform: scale(1) translateY(0);
}

.login-dialog-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-dialog-header h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.login-dialog-header p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.login-dialog-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.login-provider-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.875rem 1.5rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    border: none;
}

.login-provider-btn:hover {
    transform: translateY(-2px);
}

.login-provider-btn.google {
    background: #fff;
    color: #333;
    border: 1px solid #ddd;
}

.login-provider-btn.google:hover {
    box-shadow: 0 4px 12px oklch(0 0 0 / 0.15);
}

.login-provider-btn.microsoft {
    background: #2f2f2f;
    color: #fff;
}

.login-provider-btn.microsoft:hover {
    background: #1a1a1a;
    box-shadow: 0 4px 12px oklch(0 0 0 / 0.3);
}

.login-provider-btn svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.login-dialog-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
    transition: color 0.2s ease;
}

.login-dialog-close:hover {
    color: var(--text-primary);
}

.login-dialog {
    position: relative;
}

/* Stats Section */
@scope (.stats) {
    :scope {
        padding-block: 80px;
        background: var(--gradient-primary);
        color: var(--bg-primary);
        position: relative;
        overflow: hidden;

        &::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background:
                radial-gradient(circle at 20% 80%, oklch(1 0 0 / 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, oklch(1 0 0 / 0.1) 0%, transparent 50%);
        }
    }

    .stats-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 3rem;
        text-align: center;
        position: relative;
        z-index: 1;
    }

    .stat {
        & h3 {
            font-size: 3rem;
            font-weight: 700;
            margin-block-end: 0.5rem;
            text-shadow: 2px 2px 4px oklch(0 0 0 / 0.2);
        }

        & p {
            font-size: 1.1rem;
            opacity: 0.9;
            font-weight: 600;
        }
    }
}

/* CTA Section */
@scope (.final-cta) {
    :scope {
        padding-block: 100px;
        background: var(--bg-primary);
        text-align: center;
        transition: background 0.3s ease;
    }

    h2 {
        font-size: 3rem;
        font-weight: 700;
        margin-block-end: 1.5rem;
        color: var(--text-primary);
        transition: color 0.3s ease;
    }

    p {
        font-size: 1.25rem;
        color: var(--text-secondary);
        margin-block-end: 2rem;
        max-width: 600px;
        margin-left: auto;
        margin-right: auto;
        transition: color 0.3s ease;
    }

    .cta-button {
        background: var(--gradient-primary);
        color: var(--bg-primary);
        padding-block: 0.75rem;
        padding-inline: 1.5rem;
        border-radius: 50px;
        text-decoration: none;
        font-weight: 600;
        transition: transform 0.3s, box-shadow 0.3s;
        border: none;
        cursor: pointer;

        &:hover {
            transform: translateZ(0) translateY(-2px);
        }
    }
}

/* Theme overrides for final CTA */
[data-theme="dark"] .final-cta .cta-button {
    box-shadow: 0 0 20px oklch(0.9 0.15 195 / 0.5), 0 0 40px oklch(0.7 0.3 330 / 0.3);

    &:hover {
        box-shadow: 0 0 30px oklch(0.9 0.15 195 / 0.8), 0 0 60px oklch(0.7 0.3 330 / 0.5);
    }
}

[data-theme="light"] .final-cta .cta-button {
    box-shadow: 0 4px 15px oklch(0.7 0.12 210 / 0.3);

    &:hover {
        box-shadow: 0 8px 25px oklch(0.7 0.12 210 / 0.4);
    }
}

/* FAQ Section */
@scope (.faq-section) {
    :scope {
        padding-block: 80px;
        background: var(--bg-secondary);
        transition: background 0.3s ease;
    }

    h2 {
        font-size: 2.5rem;
        font-weight: 700;
        text-align: center;
        margin-block-end: 3rem;
        color: var(--text-primary);
        transition: color 0.3s ease;
    }

    .faq-item {
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        border-radius: 12px;
        margin-block-end: 1rem;
        transition: all 0.3s ease;

        &:hover {
            border-color: var(--border-hover);
        }

        & summary {
            font-size: 1.1rem;
            font-weight: 600;
            color: var(--text-primary);
            padding: 1.25rem 1.5rem;
            cursor: pointer;
            list-style: none;
            display: flex;
            justify-content: space-between;
            align-items: center;
            transition: color 0.3s ease;

            &::after {
                content: "+";
                font-size: 1.5rem;
                font-weight: 300;
                color: var(--cyan);
                transition: transform 0.2s ease;
            }

            &::-webkit-details-marker {
                display: none;
            }
        }

        &[open] summary::after {
            content: "−";
        }

        & > div {
            padding: 0 1.5rem 1.25rem;
        }

        & p {
            color: var(--text-secondary);
            line-height: 1.6;
            font-size: 0.95rem;
            margin: 0;
            transition: color 0.3s ease;
        }
    }
}

/* Categories Section */
@scope (.categories-section) {
    :scope {
        padding-block: 80px;
        background: var(--bg-primary);
    }

    h2 {
        font-size: 2rem;
        font-weight: 700;
        text-align: center;
        margin-block-end: 3rem;
        color: var(--text-primary);
    }

    .categories-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
        max-width: 1000px;
        margin: 0 auto;
    }

    .category-card {
        background: var(--bg-card);
        border: 2px solid var(--border-color);
        border-radius: 16px;
        padding: 2rem 1.5rem;
        text-align: center;
        text-decoration: none;
        transition: all 0.3s ease;

        &:hover {
            border-color: var(--cyan);
            transform: translateY(-4px);
            box-shadow: 0 12px 40px oklch(0.7 0.15 195 / 0.2);
        }
    }

    .category-icon {
        font-size: 3rem;
        display: block;
        margin-block-end: 1rem;
    }

    .category-card h3 {
        font-size: 1.2rem;
        font-weight: 700;
        color: var(--text-primary);
        margin-block-end: 0.5rem;
    }

    .category-card p {
        font-size: 0.85rem;
        color: var(--text-secondary);
        margin: 0;
        line-height: 1.4;
    }

    @media (max-width: 768px) {
        .categories-grid {
            grid-template-columns: repeat(2, 1fr);
            gap: 1rem;
        }

        .category-card {
            padding: 1.5rem 1rem;
        }

        .category-icon {
            font-size: 2.5rem;
        }
    }
}

/* Footer */
@scope (footer) {
    :scope {
        background: var(--bg-primary);
        color: var(--text-secondary);
        padding-block: 3rem;
        text-align: center;
        border-top: 1px solid var(--border-color);
        transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    }

    p {
        opacity: 0.7;
    }

    .footer-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem 1.5rem;
        margin-bottom: 1rem;
    }

    .footer-links a {
        color: var(--text-secondary);
        text-decoration: none;
        font-size: 0.85rem;
        transition: color 0.2s ease;
    }

    .footer-links a:hover {
        color: var(--cyan);
    }
}

/* Mobile sign-in button - hidden by default on desktop */
.mobile-signin {
    display: none;
}

/* Responsive */
/* Ensure hamburger and mobile menu are hidden on desktop */
@media (min-width: 769px) {
    @scope (nav) {
        .hamburger {
            display: none !important;
        }
    }

    .mobile-menu-container {
        display: none !important;
    }

    .mobile-menu-overlay {
        display: none !important;
    }
}

@media (max-width: 768px) {
    @scope (.hero) {
        .container {
            grid-template-columns: 1fr;
            text-align: center;
        }

        .hero-content h1 {
            font-size: 2.5rem;
        }

        .hero-visual {
            height: auto;
            min-height: 0;
        }

        .hero-demo-cards {
            display: none;
        }

        .hero-visual .try-results,
        .hero-visual .try-loading,
        .hero-visual .try-error {
            height: auto;
            min-height: 300px;
        }

        .hero-buttons {
            justify-content: center;
        }

        .try-input-group {
            flex-direction: column;
        }

        .try-input-group button {
            width: 100%;
        }

        .hero-topics .topic-pills {
            justify-content: center;
        }
    }

    @scope (.sub-hero) {
        :scope {
            padding-block: 40px;
        }

        .sub-hero-text {
            font-size: 1.1rem;
            padding-inline: 1.5rem;
            line-height: 1.8;
        }
    }

    @scope (nav) {
        :scope {
            z-index: 1002;
        }

        .container {
            position: relative;
            z-index: 1002;
        }

        .hamburger {
            display: flex;
            position: relative;
            z-index: 1003;
        }

        /* Mobile sign-in button */
        .mobile-signin {
            display: inline-flex;
            align-items: center;
            margin-left: auto;
            margin-right: 0.75rem;
            padding: 0.5rem 1rem;
            font-size: 0.875rem;
            font-weight: 500;
            color: var(--cyan);
            background: transparent;
            border: 1px solid var(--cyan);
            border-radius: 50px;
            text-decoration: none;
            white-space: nowrap;
            transition: all 0.2s ease;

            &:hover {
                background: var(--cyan);
                color: var(--bg-primary);
            }
        }

        /* Hide desktop nav items on mobile */
        .container > .nav-links {
            display: none !important;
        }

        .container > .nav-actions {
            display: none !important;
        }
    }

    /* Mobile menu (outside nav scope since it's appended to body) */
    .mobile-menu-container {
        position: fixed !important;
        top: 0 !important;
        right: -100% !important;
        height: 100vh !important;
        width: 280px !important;
        background: var(--nav-bg) !important;
        backdrop-filter: blur(20px) !important;
        border-left: 1px solid var(--border-color) !important;
        transition: right 0.3s ease !important;
        z-index: 1000 !important;
        box-shadow: -4px 0 30px oklch(0 0 0 / 0.3) !important;
        overflow-y: auto !important;
        display: flex !important;
        flex-direction: column !important;

        &.active {
            right: 0 !important;
        }
    }

    .mobile-menu-container .nav-links {
        flex-direction: column !important;
        padding: 80px 2rem 1.5rem 2rem !important;
        gap: 0.5rem !important;
        position: static !important;
        width: 100% !important;
        height: auto !important;
        display: flex !important;
        list-style: none !important;
        margin: 0 !important;

        & li {
            opacity: 1 !important;
            transform: translateX(0) !important;
            transition: all 0.3s ease;
            display: block !important;
            width: 100% !important;
            margin: 0 !important;
        }

        & a {
            font-size: 1.1rem !important;
            padding: 1rem !important;
            border-bottom: 1px solid var(--border-color) !important;
            display: block !important;
            color: var(--text-primary) !important;
            text-decoration: none !important;
            width: 100% !important;
            background: transparent !important;
            transition: background 0.2s ease !important;

            &:hover {
                background: var(--bg-card) !important;
            }

            &.active {
                color: var(--cyan) !important;
                background: var(--bg-card) !important;
            }
        }
    }

    .mobile-menu-container.active .nav-links li:nth-child(1) {
        transition-delay: 0.1s;
    }

    .mobile-menu-container.active .nav-links li:nth-child(2) {
        transition-delay: 0.15s;
    }

    .mobile-menu-container.active .nav-links li:nth-child(3) {
        transition-delay: 0.2s;
    }

    .mobile-menu-container .nav-actions {
        flex-direction: column !important;
        padding: 1.5rem 2rem 2rem 2rem !important;
        gap: 1rem !important;
        margin-top: 1rem !important;
        position: static !important;
        width: 100% !important;
        display: flex !important;
        box-sizing: border-box !important;

        &::before {
            content: '';
            display: block;
            width: 100%;
            height: 1px;
            background: var(--border-color);
            margin-bottom: 1rem;
            opacity: 1 !important;
        }

        & > * {
            opacity: 1 !important;
            transform: translateX(0) !important;
            transition: all 0.3s ease;
            box-sizing: border-box !important;
        }
    }

    .mobile-menu-container.active .nav-actions > :nth-child(1) {
        transition-delay: 0.3s;
    }

    .mobile-menu-container.active .nav-actions > :nth-child(2) {
        transition-delay: 0.35s;
    }

    .mobile-menu-container.active .nav-actions > :nth-child(3) {
        transition-delay: 0.4s;
    }

    .mobile-menu-container .theme-toggle {
        width: 100% !important;
        justify-content: center !important;
        padding: 0.75rem 1rem !important;
        background: var(--bg-card) !important;
        border: 1px solid var(--border-color) !important;
        border-radius: 50px !important;
        color: var(--text-secondary) !important;
        font-size: 0.9rem !important;
        display: flex !important;
        align-items: center !important;
        gap: 0.5rem !important;
        cursor: pointer !important;
    }

    .mobile-menu-container .theme-toggle-text,
    .mobile-menu-container .language-text {
        display: inline !important;
    }

    .mobile-menu-container .user-menu {
        width: 100% !important;

        & .user-button {
            width: 100% !important;
            justify-content: center !important;
            padding: 0.75rem 1rem !important;
            background: var(--bg-card) !important;
            border: 1px solid var(--border-color) !important;
            border-radius: 50px !important;
            color: var(--text-primary) !important;
            display: flex !important;
            align-items: center !important;
            gap: 0.5rem !important;
            cursor: pointer !important;
        }

        & .user-name {
            display: inline !important;
        }

        & .user-avatar {
            width: 32px !important;
            height: 32px !important;
            border-radius: 50% !important;
            background: var(--cyan) !important;
            color: var(--bg-primary) !important;
            display: flex !important;
            align-items: center !important;
            justify-content: center !important;
            font-weight: 600 !important;
        }

        & .user-dropdown {
            position: static !important;
            width: 100% !important;
            box-shadow: none !important;
            margin-top: 0.5rem !important;
            border: 1px solid var(--border-color) !important;
            background: var(--bg-card) !important;
            border-radius: 8px !important;
            opacity: 0 !important;
            max-height: 0 !important;
            overflow: hidden !important;
            transition: all 0.3s ease !important;

            &.show {
                opacity: 1 !important;
                max-height: 300px !important;
            }

            & a {
                display: block !important;
                padding: 0.75rem 1rem !important;
                color: var(--text-primary) !important;
                text-decoration: none !important;
                transition: background 0.2s ease !important;

                &:hover {
                    background: var(--bg-secondary) !important;
                }
            }

            & hr {
                border: none !important;
                border-top: 1px solid var(--border-color) !important;
                margin: 0.5rem 0 !important;
            }
        }
    }

    .mobile-menu-container .cta-button {
        width: 100% !important;
        text-align: center !important;
        display: block !important;
        padding: 0.75rem 1.5rem !important;
        background: var(--gradient-primary) !important;
        border: none !important;
        border-radius: 50px !important;
        color: white !important;
        font-weight: 600 !important;
        text-decoration: none !important;
    }

    /* Mobile language menu dropdown */
    .mobile-menu-container #mobileLanguageMenu {
        position: static !important;
        width: 100% !important;
        margin: 0.5rem 0 0 0 !important;
        padding: 0 !important;
        background: var(--bg-card) !important;
        border: 1px solid var(--border-color) !important;
        border-radius: 8px !important;
        max-height: 300px !important;
        overflow-y: auto !important;
        box-sizing: border-box !important;
    }

    .mobile-menu-container #mobileLanguageMenu .language-option {
        display: block !important;
        width: 100% !important;
        padding: 12px 16px !important;
        text-align: left !important;
        background: transparent !important;
        border: none !important;
        cursor: pointer !important;
        color: var(--text-primary) !important;
        font-size: 14px !important;
        transition: background-color 0.2s !important;
    }

    .mobile-menu-container #mobileLanguageMenu .language-option:hover {
        background: var(--bg-secondary) !important;
    }

    /* Mobile menu overlay */
    .mobile-menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: oklch(0 0 0 / 0.5);
        z-index: 999;
        opacity: 0;
        transition: opacity 0.3s ease;

        &.active {
            display: block;
            opacity: 1;
        }
    }

    @scope (.features) {
        .features-grid {
            grid-template-columns: 1fr;
        }
    }

    @scope (.use-cases) {
        .use-cases-grid {
            grid-template-columns: 1fr;
        }
    }
}
} /* End overrides layer */
