/* ===== CSS RESET & BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Screen reader only - visually hidden but accessible */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

:root {
    /* Color Palette - Light Mode (default) */
    --dark-bg: #1E293B;
    --darker-bg: #0F172A;
    --dark-text: #475569;
    --light-gray: #CBD5E1;
    --off-white: #F8FAFC;
    --primary: #06B6D4;
    --primary-light: #22D3EE;
    --primary-dark: #0891B2;
    --accent: #F97316;
    --accent-light: #FB923C;
    --accent-dark: #EA580C;
    --purple: #8B5CF6;
    --purple-light: #A78BFA;
    --text-main: #0F172A;
    --text-muted: #566373;
    --border: #E2E8F0;

    /* Status/Feedback colors */
    --success: #4ADE80;
    --success-bg: #ECFDF5;
    --success-text: #065F46;
    --error: #F87171;
    --error-bg: #FEF2F2;
    --error-text: #991B1B;
    --warning: #FBBF24;
    --warning-bg: #FEF3C7;
    --warning-text: #92400E;
    --info-bg: #E0F2FE;
    --info-text: #0369A1;

    /* Code syntax colors */
    --code-tag: #F472B6;
    --code-attr: #22D3EE;
    --code-string: #A3E635;
    --code-comment: #64748B;

    /* Window control (traffic light) colors */
    --window-close: #FF5F57;
    --window-minimize: #FFBD2E;
    --window-maximize: #28CA41;

    /* Info/feature highlight gradient */
    --info-gradient-start: #F0F9FF;
    --info-gradient-end: #E0F2FE;

    /* Deepest dark (for dark mode gradients) */
    --darkest-bg: #020617;

    /* Semantic colors - will be overridden in dark mode */
    --bg-page: #F8FAFC;
    --bg-surface: #FFFFFF;
    --bg-elevated: #F8FAFC;
    --text-heading: #0F172A;
    --text-body: #566373;
    --text-subtle: #94A3B8;
    --border-default: #E2E8F0;
    --border-subtle: #F1F5F9;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;
    --space-32: 8rem;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px; /* Account for sticky nav */
    height: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--off-white);
    color: var(--text-main);
    line-height: 1.7;
    font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
    overflow-x: hidden;
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

/* Push footer to bottom on short pages */
footer {
    margin-top: auto;
}

/* Anchor offset for sticky nav */
section[id] {
    scroll-margin-top: 80px;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -0.03em;
}

h1 {
    font-size: 3.5rem;
    margin-bottom: var(--space-8);
}

h2 {
    font-size: 2.5rem;
    margin-bottom: var(--space-12);
    font-weight: 700;
}

h3 {
    font-size: 1.75rem;
    margin-bottom: var(--space-4);
    font-weight: 700;
}

p {
    color: var(--text-muted);
    line-height: 1.8;
    max-width: 65ch;
}

/* DESIGN-007: Body text links with sliding underline */
main a:not(.btn):not(.logo):not(.new-badge):not(.tool-card),
section a:not(.btn):not(.logo):not(.new-badge):not(.tool-card) {
    color: var(--accent);
    text-decoration: none;
    position: relative;
    font-weight: 500;
}

main a:not(.btn):not(.logo):not(.new-badge):not(.tool-card)::after,
section a:not(.btn):not(.logo):not(.new-badge):not(.tool-card)::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 300ms ease;
}

main a:not(.btn):not(.logo):not(.new-badge):not(.tool-card):hover::after,
section a:not(.btn):not(.logo):not(.new-badge):not(.tool-card):hover::after {
    width: 100%;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary) 50%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;
    position: relative;
}

.accent-text {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;
}

/* ===== LAYOUT ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--space-6);
}

section {
    padding: var(--space-12) 0;
}

@media (min-width: 768px) {
    section {
        padding: var(--space-20) 0;
    }
}

@media (min-width: 1024px) {
    section {
        padding: var(--space-24) 0;
    }
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: 0.875rem 1.5rem;
    font-weight: 600;
    font-size: 1rem;
    border-radius: 9999px;
    text-decoration: none;
    transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    font-family: inherit;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

@media (min-width: 480px) {
    .btn {
        gap: var(--space-3);
        padding: 1rem 2rem;
        font-size: 1.0625rem;
    }
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background: var(--primary-dark);
    transition: width 350ms cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
}

.btn-primary::before {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary) 100%);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.btn-primary:hover::before {
    width: 100%;
}

.btn-secondary {
    background: var(--bg-surface);
    color: var(--text-main);
    border: 2px solid var(--border);
}

.btn-secondary::before {
    background: var(--accent);
}

.btn-secondary:hover {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.btn-secondary:hover::before {
    width: 100%;
}

.btn-secondary-dark {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary-dark::before {
    background: rgba(255, 255, 255, 0.2);
}

.btn-secondary-dark:hover::before {
    width: 100%;
}

.btn-accent {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
    color: white;
}

.btn-accent::before {
    background: linear-gradient(135deg, var(--accent-light) 0%, var(--accent) 100%);
}

.btn-accent:hover::before {
    width: 100%;
}

/* ===== CARDS ===== */
.card {
    background: var(--bg-surface);
    border-radius: 16px;
    border: 1px solid var(--border);
    padding: var(--space-10);
    box-shadow: 0 4px 20px -2px rgba(13, 148, 136, 0.08);
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px -4px rgba(13, 148, 136, 0.15);
    border-color: var(--primary-light);
}

/* ===== NAVIGATION ===== */
nav {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: var(--space-3) 0;
    z-index: 1000;
    transition: all 200ms ease;
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* DESIGN-001: Logo sizing */
.logo {
    font-size: 1.75rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

nav .logo {
    font-size: 1.875rem;
}

.logo img {
    height: 22px;
    width: auto;
}

/* Nav logo */
.logo .nav-logo {
    display: block;
}

.logo .rotated-e {
    display: inline-block;
    transform: rotate(-35deg);
    top: 0.05rem;
    left: -0.09rem;
    position: relative;
    color: var(--primary-dark);
    transition: transform 300ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 0.875rem;
    border-radius: 8px;
    transition: all 150ms ease;
    position: relative;
}

.nav-links a::after {
    display: none;
}

.nav-links a:hover {
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.04);
}

.nav-links a.active {
    color: var(--accent);
    background: rgba(249, 115, 22, 0.08);
}

.nav-links a.active:hover {
    background: rgba(249, 115, 22, 0.12);
}

/* Nav auth group (Register | Login or Dashboard | Log Out) */
.nav-auth-group {
    display: inline-flex;
    align-items: center;
    margin-left: var(--space-3);
    padding-left: var(--space-3);
    border-left: 1px solid var(--border);
    gap: var(--space-1);
}

/* Auth links - use .nav-links prefix for specificity over .nav-links a */
.nav-links .nav-auth-link {
    padding: 0.375rem 0.625rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 6px;
    transition: all 150ms ease;
}

.nav-links .nav-auth-link:hover {
    color: var(--primary);
    background: transparent;
}

.nav-links .nav-auth-link.active {
    color: var(--accent);
    background: transparent;
}

.nav-links .nav-auth-link.nav-logout:hover {
    color: var(--error);
}

.nav-links .nav-auth-link::after {
    display: none;
}

/* Icon-based auth links */
.nav-auth-icon-link {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.nav-auth-icon-link svg {
    flex-shrink: 0;
}

.nav-auth-label {
    font-size: 0.875rem;
}

/* Nav auth: icons only by default, show labels on large screens */
.nav-auth-label {
    display: none;
}

.nav-links .nav-auth-icon-link {
    padding: 0.5rem;
    border-radius: 8px;
}

@media (min-width: 1024px) {
    .nav-auth-label {
        display: inline;
    }

    .nav-links .nav-auth-icon-link {
        padding: 0.5rem 0.75rem;
    }
}

/* Mobile logout link */
.mobile-menu .mobile-logout {
    color: var(--error);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: var(--space-1);
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--space-2);
    width: 44px;
    height: 44px;
    justify-content: center;
    align-items: center;
}

.menu-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-main);
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

/* Hamburger to X animation */
.menu-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 57px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: var(--space-4) var(--space-6);
    flex-direction: column;
    gap: var(--space-1);
    transform: translateY(-100%);
    transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
}

.mobile-menu.active {
    transform: translateY(0);
}

.mobile-menu a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.9375rem;
    font-weight: 500;
    padding: 0.875rem 1rem;
    min-height: 44px;
    display: flex;
    align-items: center;
    border-radius: 8px;
    transition: all 150ms ease;
}

.mobile-menu a:hover,
.mobile-menu a.active {
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.04);
}

.mobile-menu a.active {
    color: var(--primary);
    background: rgba(79, 70, 229, 0.08);
}

/* Mobile menu account actions */
.mobile-menu-divider {
    height: 1px;
    background: rgba(0, 0, 0, 0.06);
    margin: var(--space-2) 0;
}

/* ===== HERO ===== */
/* Mobile-first: base styles are for mobile */
.hero {
    padding: var(--space-16) 0;
    position: relative;
    overflow: hidden;
}

.hero-content {
    display: grid;
    gap: var(--space-8);
    align-items: center;
}

.hero h1 {
    font-size: 1.75rem;
    line-height: 1.1;
}

.hero-description {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: var(--space-6);
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    margin-bottom: var(--space-6);
    width: 100%;
}

.hero-buttons .btn {
    width: 100%;
    justify-content: center;
}

.hero-meta {
    font-size: 0.875rem;
    color: var(--dark-text);
}

/* Hero with Visual Demo - mobile first */
.hero-with-visual {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-8);
    align-items: center;
    text-align: center;
}

.hero-text {
    display: flex;
    flex-direction: column;
}

.hero-text h1 {
    margin-bottom: var(--space-4);
}

.hero-text .hero-description {
    font-size: 1rem;
    margin-bottom: var(--space-6);
}

.hero-text .hero-buttons {
    margin: 0 0 var(--space-4) 0;
    justify-content: center;
}

.hero-text .hero-meta {
    margin: 0;
}

.hero-visual {
    display: flex;
    justify-content: center;
    perspective: 1000px;
    order: -1;
    margin-bottom: var(--space-4);
}

/* Hero GIF demo */
.hero-demo-gif {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    border: 1px solid var(--border);
    max-width: 100%;
}

.hero-gif {
    display: block;
    width: 100%;
    height: auto;
    max-width: 600px;
}

/* Mobile: no animation, static display */
.hero-demo {
    opacity: 1;
}

.hero-demo .demo-page {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    width: min(85vw, 340px);
    min-width: 260px;
    margin: 0 auto;
    border: 1px solid var(--border);
    position: relative;
}

.demo-nav-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: var(--off-white);
    border-bottom: 1px solid var(--border);
}

.demo-nav-logo {
    width: 50px;
    height: 10px;
    background: var(--dark-bg);
    border-radius: 4px;
}

.demo-nav-links-mock {
    display: flex;
    gap: 8px;
}

.demo-nav-links-mock span {
    width: 30px;
    height: 6px;
    background: var(--border);
    border-radius: 4px;
}

.hero-demo .demo-content {
    padding: 20px;
    min-height: 160px;
}

.demo-headline {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-bottom: 12px;
}

.demo-headline.pebble-active {
    outline: 2px dashed var(--primary);
    outline-offset: 6px;
    border-radius: 4px;
}

.demo-headline.pebble-active .pebble-indicator {
    opacity: 1;
    transform: scale(1);
}

.demo-headline.pebble-active .pebble-cursor {
    opacity: 1;
}

/* Text container - fixed width to prevent shrinking during animation */
.demo-text-content {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-main);
    display: inline-block;
    /* Width based on "Welcome to our site" - prevents cursor jumping */
    min-width: 11em;
}

.pebble-cursor {
    width: 2px;
    height: 1.3em;
    background: var(--primary);
    margin-left: 2px;
    opacity: 0;
    transition: opacity 200ms ease;
}

.pebble-cursor.blinking {
    animation: blink 1s step-end infinite;
}

.pebble-indicator {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 22px;
    height: 22px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 2px 8px rgba(6, 182, 212, 0.4);
    opacity: 0;
    transform: scale(0.5);
    transition: all 300ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.demo-paragraph {
    margin-bottom: 16px;
}

.demo-line {
    height: 8px;
    background: linear-gradient(90deg, var(--border) 0%, var(--border-default) 100%);
    border-radius: 4px;
    margin-bottom: 6px;
}

.demo-line.short {
    width: 60%;
}

.demo-image-row {
    display: flex;
    gap: 8px;
}

.demo-img {
    flex: 1;
    height: 48px;
    background: linear-gradient(135deg, var(--border) 0%, var(--light-gray) 100%);
    border-radius: 6px;
}

.demo-mouse {
    position: absolute;
    top: 80px;
    left: 60px;
    pointer-events: none;
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    transition: all 600ms cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--dark-bg);
}

.demo-mouse.clicking {
    transform: scale(0.9);
}

.demo-save-toast {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: var(--dark-bg);
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 300ms ease;
}

.demo-save-toast svg {
    color: var(--success);
}

.demo-save-toast.visible {
    opacity: 1;
    transform: translateY(0);
}

.demo-click-ripple {
    position: absolute;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(6, 182, 212, 0.3);
    transform: scale(0);
    pointer-events: none;
    z-index: 5;
}

.demo-click-ripple.animate {
    animation: clickRipple 400ms ease-out forwards;
}

@keyframes clickRipple {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

@keyframes demoEntrance {
    0% {
        opacity: 0;
        transform: rotateY(-15deg) rotateX(8deg) translateX(60px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: rotateY(-5deg) rotateX(3deg) translateX(0) scale(1);
    }
}

/* Tablet and up: sm breakpoint (480px) */
@media (min-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }

    .hero-buttons {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        width: auto;
    }

    .hero-buttons .btn {
        width: auto;
    }

    .hero-demo .demo-page {
        max-width: 380px;
    }
}

/* Tablet: md breakpoint (768px) */
@media (min-width: 768px) {
    .hero {
        padding: var(--space-24) 0;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-description {
        font-size: 1.125rem;
    }

    .hero-meta {
        font-size: 0.9375rem;
    }

    .hero-demo-gif {
        border-radius: 14px;
    }

    .hero-gif {
        max-width: 480px;
    }

    .hero-demo .demo-page {
        max-width: 420px;
        border-radius: 14px;
    }

    .hero-demo .demo-content {
        padding: 24px;
        min-height: 200px;
    }

    .demo-text-content {
        font-size: 1.25rem;
    }

    .demo-line {
        height: 10px;
        margin-bottom: 8px;
    }

    .demo-img {
        height: 56px;
    }
}

/* Desktop: lg breakpoint (1024px) - full experience */
@media (min-width: 1024px) {
    .hero {
        padding: var(--space-32) 0;
    }

    .hero-content {
        gap: var(--space-16);
    }

    .hero h1 {
        font-size: 3.5rem;
    }

    .hero-description {
        font-size: 1.375rem;
        margin-bottom: var(--space-10);
    }

    .hero-buttons {
        gap: var(--space-6);
        margin-bottom: var(--space-10);
    }

    .hero-with-visual {
        grid-template-columns: 0.9fr 1.5fr;
        gap: var(--space-16);
        text-align: left;
    }

    .hero-text .hero-description {
        font-size: 1.1875rem;
        margin-bottom: var(--space-8);
    }

    .hero-text .hero-buttons {
        justify-content: flex-start;
        margin: 0 0 var(--space-6) 0;
    }

    .hero-visual {
        order: 0;
        margin-bottom: 0;
    }

    .hero-demo-gif {
        border-radius: 16px;
        box-shadow: 0 40px 120px rgba(0, 0, 0, 0.22);
    }

    .hero-gif {
        max-width: 600px;
    }

    /* Desktop: enable 3D animation */
    .hero-demo {
        transform: rotateY(-5deg) rotateX(3deg);
        opacity: 0;
        animation: demoEntrance 800ms cubic-bezier(0.34, 1.56, 0.64, 1) 500ms forwards;
    }

    .hero-demo .demo-page {
        width: 560px;
        max-width: 100%;
        border-radius: 16px;
        box-shadow: 0 40px 120px rgba(0, 0, 0, 0.22);
    }

    .demo-nav-bar {
        padding: 12px 16px;
    }

    .demo-nav-logo {
        width: 60px;
        height: 12px;
    }

    .demo-nav-links-mock {
        gap: 12px;
    }

    .demo-nav-links-mock span {
        width: 40px;
        height: 8px;
    }

    .hero-demo .demo-content {
        padding: 28px;
        min-height: 220px;
    }

    .demo-headline {
        margin-bottom: 16px;
    }

    .demo-text-content {
        font-size: 1.375rem;
        min-width: 220px;
    }

    .demo-paragraph {
        margin-bottom: 20px;
    }

    .demo-image-row {
        gap: 12px;
    }

    .demo-img {
        height: 60px;
        border-radius: 8px;
    }

    .demo-save-toast {
        bottom: 16px;
        right: 16px;
        padding: 8px 14px;
        border-radius: 8px;
        font-size: 0.8125rem;
        gap: 6px;
    }
}

/* ===== PERSONA TOGGLE SECTION ===== */
/* Mobile-first */
.persona-section {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.persona-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    margin-bottom: var(--space-8);
    background: var(--off-white);
    padding: 6px;
    border-radius: 16px;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    position: relative;
}

.persona-tab {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: 0.75rem 1rem;
    border: none;
    background: transparent;
    border-radius: 12px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 2;
    flex: 1;
    justify-content: center;
    font-family: inherit;
}

.persona-tab svg {
    width: 16px;
    height: 16px;
    transition: transform 300ms ease;
}

.persona-tab:hover {
    color: var(--text-main);
}

.persona-tab:hover svg {
    transform: scale(1.1);
}

.persona-tab.active {
    color: white;
}

/* Mobile: vertical toggle indicator */
.toggle-indicator {
    position: absolute;
    top: 6px;
    left: 6px;
    width: calc(100% - 12px);
    height: calc(50% - 6px);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 12px;
    transition: transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1;
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.persona-toggle[data-active="designer"] .toggle-indicator {
    transform: translateY(100%);
}

.persona-content {
    position: relative;
    min-height: auto;
}

.persona-panel {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    transition: all 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

.persona-panel.active {
    position: relative;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Mobile: single column, stacked layout */
.persona-hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    align-items: start;
}

/* Mobile: hide visual demo on small screens to reduce scrolling */
.persona-visual {
    display: none;
    order: 0;
}

.persona-text h3 {
    font-size: 1.25rem;
    margin-bottom: var(--space-3);
    color: var(--text-main);
}

.persona-lead {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin-bottom: var(--space-4);
    line-height: 1.7;
}

.persona-benefits {
    list-style: none;
    padding: 0;
    margin: 0;
}

.persona-benefits li {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) 0;
    font-size: 0.9375rem;
    color: var(--text-main);
    border-bottom: 1px solid var(--border);
}

.persona-benefits li:last-child {
    border-bottom: none;
}

.persona-benefits svg {
    width: 18px;
    height: 18px;
    color: var(--primary);
    flex-shrink: 0;
}

/* Persona demo - reuses hero-demo styles */
.persona-demo {
    opacity: 1;
}

.persona-demo .demo-page {
    width: 100%;
    max-width: 400px;
}

/* Editor Demo Visual - mobile: no 3D transform */
.editor-demo {
    perspective: 1000px;
}

.demo-browser {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

.browser-dots {
    display: flex;
    gap: 6px;
    padding: 10px 12px;
    background: var(--off-white);
    border-bottom: 1px solid var(--border);
}

.browser-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border);
}

.browser-dots span:first-child { background: var(--window-close); }
.browser-dots span:nth-child(2) { background: var(--window-minimize); }
.browser-dots span:nth-child(3) { background: var(--window-maximize); }

.browser-content {
    padding: var(--space-4);
}

.demo-heading {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: var(--space-3);
    position: relative;
    display: inline-block;
}

.demo-heading.editing {
    outline: 2px dashed var(--primary);
    outline-offset: 4px;
    border-radius: 4px;
    animation: pulse-outline 2s ease-in-out infinite;
}

@keyframes pulse-outline {
    0%, 100% { outline-color: var(--primary); }
    50% { outline-color: var(--primary-light); }
}

.demo-cursor-blink {
    display: inline-block;
    width: 2px;
    height: 1.5em;
    background: var(--primary);
    margin-left: 2px;
    vertical-align: text-bottom;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.demo-text-preview {
    color: var(--text-muted);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* Code Demo Visual - mobile: no 3D transform */
.code-demo {
    perspective: 1000px;
}

.code-window {
    background: var(--dark-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.code-header {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    background: var(--darker-bg);
}

.code-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.code-dot.red { background: var(--window-close); }
.code-dot.yellow { background: var(--window-minimize); }
.code-dot.green { background: var(--window-maximize); }

.code-filename {
    margin-left: auto;
    font-size: 0.6875rem;
    color: var(--code-comment);
    font-family: 'Monaco', 'Courier New', monospace;
}

.code-content {
    padding: var(--space-4);
    margin: 0;
    overflow-x: auto;
}

.code-content code {
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.75rem;
    line-height: 1.8;
    color: var(--border);
}

.code-tag { color: var(--code-tag); }
.code-attr { color: var(--code-attr); }
.code-string { color: var(--code-string); }
.code-comment { color: var(--code-comment); }

/* Tablet: sm breakpoint (480px) */
@media (min-width: 480px) {
    .persona-tab {
        padding: 0.875rem 1.25rem;
        font-size: 0.875rem;
    }

    .persona-tab svg {
        width: 18px;
        height: 18px;
    }

    .persona-text h3 {
        font-size: 1.5rem;
    }

    .persona-lead {
        font-size: 1rem;
        margin-bottom: var(--space-6);
    }
}

/* Mobile landscape: show 2-column layout with visual for better horizontal use */
@media (min-width: 480px) and (max-height: 500px) and (orientation: landscape) {
    .persona-hero {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-4);
    }

    .persona-visual {
        display: block;
    }

    .persona-toggle {
        flex-direction: row;
        border-radius: 9999px;
        max-width: 400px;
    }

    .toggle-indicator {
        width: calc(50% - 6px);
        height: calc(100% - 12px);
        border-radius: 9999px;
    }

    .persona-toggle[data-active="designer"] .toggle-indicator {
        transform: translateX(100%);
    }
}

/* Tablet: md breakpoint (768px) - horizontal toggle */
@media (min-width: 768px) {
    .persona-toggle {
        flex-direction: row;
        border-radius: 9999px;
        max-width: 480px;
        gap: var(--space-2);
        margin-bottom: var(--space-12);
    }

    .persona-tab {
        padding: 0.875rem 1.5rem;
        font-size: 0.9375rem;
        border-radius: 9999px;
    }

    .persona-tab svg {
        width: 20px;
        height: 20px;
    }

    /* Horizontal toggle indicator */
    .toggle-indicator {
        width: calc(50% - 6px);
        height: calc(100% - 12px);
        border-radius: 9999px;
    }

    .persona-toggle[data-active="designer"] .toggle-indicator {
        transform: translateX(100%);
    }

    /* Tablet: switch to 2-column layout with visual */
    .persona-hero {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-8);
    }

    .persona-visual {
        display: block; /* Show visual at tablet+ */
        order: 1; /* Visual on right at tablet+ */
    }

    .persona-text h3 {
        font-size: 1.75rem;
        margin-bottom: var(--space-4);
    }

    .persona-lead {
        font-size: 1.0625rem;
        margin-bottom: var(--space-8);
    }

    .persona-benefits li {
        gap: var(--space-3);
        font-size: 1rem;
    }

    .persona-benefits svg {
        width: 20px;
        height: 20px;
    }

    .browser-dots {
        padding: 12px 16px;
    }

    .browser-dots span {
        width: 10px;
        height: 10px;
    }

    .browser-content {
        padding: var(--space-6);
    }

    .demo-heading {
        font-size: 1.5rem;
        margin-bottom: var(--space-4);
    }

    .demo-text-preview {
        font-size: 1rem;
    }

    .code-header {
        gap: 8px;
        padding: 12px 16px;
    }

    .code-dot {
        width: 10px;
        height: 10px;
    }

    .code-filename {
        font-size: 0.75rem;
    }

    .code-content {
        padding: var(--space-6);
    }

    .code-content code {
        font-size: 0.875rem;
    }
}

/* Desktop: lg breakpoint (1024px) - 3D effects */
@media (min-width: 1024px) {
    .persona-content {
        min-height: 400px;
    }

    .persona-hero {
        gap: var(--space-12);
    }

    .persona-text h3 {
        font-size: 2rem;
    }

    .persona-lead {
        font-size: 1.125rem;
    }

    /* Desktop: enable 3D transforms */
    .demo-browser {
        transform: rotateY(-5deg) rotateX(5deg);
        transition: transform 400ms ease;
    }

    .demo-browser:hover {
        transform: rotateY(0) rotateX(0);
    }

    .code-window {
        transform: rotateY(5deg) rotateX(5deg);
        transition: transform 400ms ease;
    }

    .code-window:hover {
        transform: rotateY(0) rotateX(0);
    }

    .browser-content {
        padding: var(--space-8);
    }

    .demo-heading {
        font-size: 1.75rem;
    }
}

/* DESIGN-004: New badge in accent orange */
.new-badge {
    display: inline-flex;
    position: relative;
    top: -60px;
    gap: 0.625rem;
    align-items: center;
    background: white;
    border: 2px solid var(--border);
    border-radius: 9999px;
    padding: 0.5rem 1rem;
    margin-bottom: var(--space-6);
    font-size: 0.800rem;
    font-weight: 600;
    box-shadow: 0 2px 12px rgba(249, 115, 22, 0.08);
    text-decoration: none;
    color: inherit;
    transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.new-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(249, 115, 22, 0.2);
    border-color: var(--accent);
}

.new-badge .badge-new {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
    background-size: 200% 200%;
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: 9999px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.65rem;
    letter-spacing: 0.05em;
    position: relative;
    overflow: hidden;
}

.new-badge .badge-new::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.5) 50%, transparent 100%);
    transform: translateX(-100%);
    animation: shimmer 2.5s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.new-badge .badge-text {
    color: var(--text-main);
}

/* ===== VIDEO SECTION ===== */
.video-section {
    background: var(--bg-surface);
    position: relative;
    overflow: hidden;
}

.video-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.05), transparent);
    border-radius: 50%;
}

.video-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto var(--space-12);
}

.video-content h2 {
    color: var(--text-main);
    font-size: 2.5rem;
    margin-bottom: var(--space-6);
}

.video-content p {
    color: var(--text-muted);
    font-size: 1.125rem;
    max-width: 100%;
}

.video-wrapper {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
    background: var(--border-subtle);
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
}

.video-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    background: linear-gradient(135deg, var(--info-gradient-start) 0%, var(--info-gradient-end) 100%);
}

.play-button {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 300ms ease;
    box-shadow: 0 4px 20px rgba(6, 182, 212, 0.2);
}

.play-button:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 28px rgba(6, 182, 212, 0.3);
}

.play-button::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 20px solid var(--primary);
    border-top: 12px solid transparent;
    border-bottom: 12px solid transparent;
    margin-left: 4px;
}

.video-placeholder p {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 1rem;
}

/* ===== SECTION HEADERS ===== */
.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto var(--space-20);
}

.section-header p {
    font-size: 1.1875rem;
    margin: 0 auto;
}

/* ===== VALUE PROPS ===== */
.value-props {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-8);
    margin-top: var(--space-16);
}

/* DESIGN-010: Value cards - no hover, blue headings */
.value-card {
    background: var(--bg-surface);
    padding: var(--space-10);
    border-radius: 16px;
    border: 1px solid var(--border);
}

.value-card h3 {
    color: var(--primary);
    margin-bottom: var(--space-4);
}

.value-card code {
    background: var(--off-white);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    color: var(--primary-dark);
    font-family: 'Monaco', 'Courier New', monospace;
}

.value-card-content p {
    color: var(--text-muted);
    line-height: 1.8;
}

/* Section CTA button */
.section-cta {
    text-align: center;
    margin-top: var(--space-12);
}

/* ===== HOW IT WORKS ===== */
.how-it-works {
    background: var(--off-white);
}

.steps {
    display: grid;
    gap: var(--space-12);
    max-width: 900px;
    margin: 0 auto;
}

.step {
    display: flex;
    gap: var(--space-8);
    align-items: flex-start;
}

.step-number {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
}

.step-content h3 {
    color: var(--text-main);
    margin-bottom: var(--space-4);
}

.code-block {
    position: relative;
    background: var(--dark-bg);
    padding: var(--space-6);
    border-radius: 12px;
    margin-top: var(--space-6);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* DESIGN-002: Code blocks in accent orange */
.code-block code {
    color: var(--accent-light);
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.9375rem;
}

/* Code block wrapper for pre code blocks */
.code-block-wrapper {
    position: relative;
}

/* Copy button for code blocks */
.copy-button {
    position: absolute;
    top: var(--space-2);
    right: var(--space-2);
    padding: var(--space-1) var(--space-3);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--border-default);
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-subtle);
    cursor: pointer;
    opacity: 0;
    transition: all 0.15s ease;
    font-family: inherit;
    z-index: 1;
}

.code-block:hover .copy-button,
.code-block-wrapper:hover .copy-button {
    opacity: 1;
}

.copy-button:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.copy-button.copied {
    background: var(--success);
    color: white;
    border-color: var(--success);
    opacity: 1;
}

/* ===== FEATURES ===== */
.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-4);
}

@media (min-width: 480px) {
    .features-grid {
        gap: var(--space-6);
    }
}

@media (min-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-8);
    }
}

.feature {
    display: flex;
    gap: var(--space-4);
    background: var(--bg-surface);
    padding: var(--space-6);
    border-radius: 12px;
    border: 1px solid var(--border);
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 768px) {
    .feature {
        gap: var(--space-6);
        padding: var(--space-8);
    }
}

/* DESIGN-008: Feature hover shadow in accent orange */
.feature:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px -4px rgba(249, 115, 22, 0.15);
    border-color: var(--accent-light);
}

/* DESIGN-006: Feature icons in accent orange */
.feature-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.1) 0%, rgba(251, 146, 60, 0.1) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.feature-content h3 {
    color: var(--text-main);
    font-size: 1.25rem;
    margin-bottom: var(--space-3);
}

.feature-content p {
    font-size: 1rem;
    color: var(--text-muted);
}

/* ===== CTA SECTION ===== */
.cta-section {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    color: white;
    border-bottom: 5px solid var(--primary);
}

.cta-content {
    max-width: 750px;
    margin: 0 auto;
    text-align: center;
}

.cta-content h2 {
    color: white;
    margin-bottom: var(--space-8);
}

.cta-content p {
    color: var(--light-gray);
    margin: 0 auto var(--space-10);
    font-size: 1.1875rem;
}

.cta-buttons {
    display: flex;
    gap: var(--space-6);
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== NEWSLETTER ===== */
.newsletter-section {
    background: linear-gradient(135deg, var(--info-gradient-start) 0%, var(--info-gradient-end) 100%);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.newsletter-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.newsletter-content h2 {
    color: var(--text-main);
    margin-bottom: var(--space-4);
}

.newsletter-content > p {
    color: var(--text-muted);
    margin-bottom: var(--space-8);
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    max-width: 480px;
    margin: 0 auto var(--space-4);
}

@media (min-width: 480px) {
    .newsletter-form {
        flex-direction: row;
    }
}

.newsletter-form input[type="email"] {
    flex: 1;
    padding: 0.875rem 1.25rem;
    border: 2px solid var(--border);
    border-radius: 9999px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 200ms ease;
}

.newsletter-form input[type="email"]:focus {
    outline: none;
    border-color: var(--accent);
}

.newsletter-form .btn {
    flex-shrink: 0;
}

.newsletter-privacy {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.newsletter-coming-soon {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-4);
}

.coming-soon-badge {
    display: inline-block;
    padding: 0.375rem 1rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.coming-soon-text {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin: 0;
}

/* ===== FOOTER ===== */
/* Mobile-first: DESIGN-003 Footer tightening */
footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    padding: var(--space-8) 0 var(--space-4);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    margin-bottom: var(--space-8);
}

/* DESIGN-001: Footer logo sizing */
.footer-brand .logo {
    display: inline-block;
    margin-bottom: var(--space-4);
    font-size: 1.5rem;
}

.footer-logo-img {
    margin-bottom: var(--space-3);
    width: 80px;
    height: auto;
}

/* Footer logo */

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.8125rem;
    max-width: 280px;
}

.footer-links h4 {
    font-size: 0.8125rem;
    font-weight: 700;
    margin-bottom: var(--space-2);
    color: var(--text-main);
}

.footer-links a {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8125rem;
    margin-bottom: var(--space-2);
    transition: color 200ms ease;
}

/* DESIGN-002: Footer links orange on hover */
.footer-links a:hover {
    color: var(--accent);
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    padding-top: var(--space-4);
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.footer-legal {
    font-size: 0.6875rem;
}

.footer-legal a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 200ms ease;
}

.footer-legal a:hover {
    color: var(--primary);
}

.footer-logo {
    margin-bottom: var(--space-4);
}

/* Footer: tablet (768px) */
@media (min-width: 768px) {
    footer {
        padding: var(--space-12) 0 var(--space-6);
    }

    .footer-content {
        grid-template-columns: 2fr 1fr 1fr;
        gap: var(--space-8);
        margin-bottom: var(--space-10);
    }

    .footer-logo-img {
        width: 100px;
        margin-bottom: var(--space-4);
    }

    .footer-brand p {
        font-size: 0.875rem;
    }

    .footer-links h4 {
        font-size: 0.875rem;
        margin-bottom: var(--space-3);
    }

    .footer-links a {
        font-size: 0.875rem;
    }

    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        gap: var(--space-4);
        padding-top: var(--space-6);
        text-align: left;
    }

    .footer-bottom p {
        font-size: 0.875rem;
    }

    .footer-legal {
        font-size: 0.75rem;
    }
}

/* ===== ANIMATIONS ===== */
.fade-in,
.fade-in-left,
.fade-in-right,
.scale-in {
    opacity: 0;
    transition: all 600ms cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in {
    transform: translateY(30px);
}

.fade-in-left {
    transform: translateX(-30px);
}

.fade-in-right {
    transform: translateX(30px);
}

.scale-in {
    transform: scale(0.9);
}

.fade-in.visible,
.fade-in-left.visible,
.fade-in-right.visible,
.scale-in.visible {
    opacity: 1;
    transform: translateY(0) translateX(0) scale(1);
}

/* ===== GLOBAL RESPONSIVE - Mobile First ===== */
/* Mobile nav: hide desktop links, show mobile menu */
.nav-links {
    display: none;
}

.menu-toggle,
.mobile-menu {
    display: flex;
}

/* Steps: mobile = stacked */
.step {
    flex-direction: column;
    gap: var(--space-4);
}

/* Tablet: md breakpoint (768px) */
@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }

    .menu-toggle,
    .mobile-menu {
        display: none;
    }

    .step {
        flex-direction: row;
        gap: var(--space-6);
    }
}

/* ===== DEMO MODE ===== */
.demo-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: white;
    padding: var(--space-3) var(--space-6);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-6);
    font-weight: 600;
    font-size: 0.9375rem;
    z-index: 1001;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}

.demo-banner[hidden] {
    display: none;
}

.demo-exit {
    background: white;
    color: var(--accent-dark);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.8125rem;
    cursor: pointer;
    transition: transform 150ms ease;
}

.demo-exit:hover {
    transform: scale(1.05);
}

.demo-active nav {
    top: 44px;
}

.pebble-editable {
    outline: 2px dashed var(--accent);
    outline-offset: 4px;
    cursor: text;
    transition: outline-color 200ms ease;
}

.pebble-editable:focus {
    outline-color: var(--primary);
}

#demo-toggle.demo-on {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

/* ===== FEATURES CTA ===== */
/* DESIGN-009: Features CTA with sliding underline */
.features-cta {
    text-align: center;
    margin-top: var(--space-12);
}

.features-cta a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    position: relative;
    padding-bottom: 4px;
    transition: gap 200ms ease;
}

.features-cta a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 300ms ease;
}

.features-cta a:hover::before {
    width: 100%;
}

/* ===== DEMO PLAYGROUND ===== */
/* DESIGN-011: Demo playground light blue background, hidden until demo active */
.demo-playground {
    background: linear-gradient(135deg, var(--info-gradient-start) 0%, var(--info-gradient-end) 100%);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    display: none;
}

.demo-active .demo-playground {
    display: block;
}

.demo-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
}

@media (min-width: 768px) {
    .demo-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.demo-card {
    background: var(--bg-surface);
    border-radius: 12px;
    padding: var(--space-6);
    border: 1px solid var(--border);
}

.demo-card h3 {
    font-size: 1.125rem;
    margin-bottom: var(--space-2);
    color: var(--text-main);
}

.demo-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: var(--space-4);
}

.demo-zone {
    background: var(--off-white);
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: var(--space-4);
    min-height: 80px;
}

.demo-list {
    list-style: none;
    background: var(--off-white);
    border-radius: 8px;
    padding: var(--space-4);
}

.demo-list li {
    padding: var(--space-2) 0;
    border-bottom: 1px solid var(--border);
}

.demo-list li:last-child {
    border-bottom: none;
}

.demo-image {
    width: 100%;
    max-width: 120px;
    height: auto;
    border-radius: 8px;
    border: 2px dashed var(--border);
    padding: var(--space-2);
    background: var(--off-white);
}

.demo-link {
    display: inline-block;
    padding: var(--space-3) var(--space-4);
    background: var(--off-white);
    border: 2px dashed var(--border);
    border-radius: 8px;
    color: var(--accent);
    font-weight: 500;
}

/* Demo card wide variant (spans 2 columns) */
.demo-card-wide {
    grid-column: 1 / -1;
}

/* Demo navigation */
.demo-nav {
    display: flex;
    gap: var(--space-4);
    flex-wrap: wrap;
    background: var(--off-white);
    padding: var(--space-4);
    border-radius: 8px;
    border: 2px dashed var(--border);
}

.demo-nav-link {
    padding: var(--space-2) var(--space-4);
    background: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    transition: all 200ms ease;
}

.demo-nav-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* ===== DEMO TOAST ===== */
.demo-toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--dark-bg);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    opacity: 0;
    transition: all 300ms ease;
    z-index: 1002;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.demo-toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ===== DEMO EDIT COUNTER ===== */
.demo-edit-count {
    background: rgba(255,255,255,0.2);
    padding: 4px 12px;
    border-radius: 9999px;
    font-size: 0.8125rem;
}

/* ===== DARK MODE (prefers-color-scheme) ===== */
@media (prefers-color-scheme: dark) {
    /* Override semantic variables for dark mode */
    :root {
        --bg-page: #0F172A;
        --bg-surface: #1E293B;
        --bg-elevated: #334155;
        --text-heading: #F1F5F9;
        --text-body: #CBD5E1;
        --text-subtle: #94A3B8;
        --border-default: #334155;
        --border-subtle: #1E293B;
        /* Override light-theme specific variables */
        --off-white: #1E293B;
        --border: #334155;
        --text-main: #F1F5F9;
        --text-muted: #94A3B8;
        /* Override info gradient for dark mode */
        --info-gradient-start: #0F172A;
        --info-gradient-end: #1E293B;
        /* Override status colors for dark mode */
        --warning-bg: rgba(251, 191, 36, 0.15);
        --info-bg: rgba(6, 182, 212, 0.15);
    }

    body {
        background: var(--bg-page);
        color: var(--text-body);
    }

    /* Navigation */
    nav {
        background: rgba(15, 23, 42, 0.9);
        border-color: rgba(255, 255, 255, 0.06);
    }

    .nav-links a {
        color: var(--text-subtle);
    }

    .nav-links a:hover {
        color: var(--text-heading);
        background: rgba(255, 255, 255, 0.06);
    }

    .nav-links a.active {
        color: var(--accent-light);
        background: rgba(251, 146, 60, 0.15);
    }

    .nav-links a.active:hover {
        background: rgba(251, 146, 60, 0.2);
    }

    /* Nav auth group dark mode */
    .nav-auth-group {
        border-left-color: var(--border-default);
    }

    .nav-links .nav-auth-link {
        color: var(--text-subtle);
    }

    .nav-links .nav-auth-link:hover {
        color: var(--primary-light);
    }

    .nav-links .nav-auth-link.active {
        color: var(--accent-light);
    }

    .nav-links .nav-auth-link.nav-logout:hover {
        color: var(--error);
    }

    /* Hamburger menu icon - better contrast for dark mode */
    .menu-toggle span {
        background: #F1F5F9;
    }

    .mobile-menu {
        background: rgba(15, 23, 42, 0.98);
        border-color: rgba(255, 255, 255, 0.06);
    }

    .mobile-menu a {
        color: var(--text-subtle);
    }

    .mobile-menu a:hover,
    .mobile-menu a.active {
        color: var(--text-heading);
        background: rgba(255, 255, 255, 0.06);
    }

    .mobile-menu a.active {
        color: var(--primary-light);
        background: rgba(99, 102, 241, 0.15);
    }

    .mobile-menu-divider {
        background: rgba(255, 255, 255, 0.06);
    }

    /* Typography */
    h1, h2, h3, h4, h5, h6 {
        color: var(--text-heading);
    }

    p {
        color: var(--text-body);
    }

    /* Hero section */
    .hero-description {
        color: var(--text-body);
    }

    .hero-meta {
        color: var(--text-subtle);
    }

    /* Buttons - primary stays the same (colored), secondary needs dark treatment */
    .btn-secondary {
        background: var(--bg-elevated);
        color: var(--text-heading);
        border-color: var(--border-default);
    }

    .btn-secondary:hover {
        background: var(--bg-elevated);
        border-color: var(--bg-elevated);
    }

    /* Cards and surfaces */
    .value-card,
    .step-card,
    .feature,
    .demo-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    /* Demo elements in hero */
    .hero-demo .demo-page {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .demo-nav-bar {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .demo-text-content {
        color: var(--text-heading);
    }

    /* Persona section */
    .persona-section {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .persona-toggle {
        background: var(--bg-page);
    }

    .persona-tab {
        color: var(--text-subtle);
    }

    .persona-tab:hover {
        color: var(--text-body);
    }

    .persona-text h3 {
        color: var(--text-heading);
    }

    .persona-lead {
        color: var(--text-body);
    }

    .persona-benefits li {
        color: var(--text-body);
        border-color: var(--border-default);
    }

    /* Demo browser in persona */
    .demo-browser {
        background: var(--bg-surface);
        border: 1px solid var(--border-default);
    }

    .browser-dots {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .demo-heading {
        color: var(--text-heading);
    }

    .demo-text-preview {
        color: var(--text-body);
    }

    /* How It Works / Steps section */
    .how-it-works {
        background: var(--bg-surface);
    }

    .step-content h3 {
        color: var(--text-heading);
    }

    .step-content p {
        color: var(--text-body);
    }

    /* Code blocks in steps - darker background in dark mode */
    .code-block {
        background: var(--darker-bg);
        border-color: var(--border-default);
    }

    /* Features section */
    .feature {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .feature:hover {
        border-color: var(--accent);
    }

    .feature-content h3 {
        color: var(--text-heading);
    }

    .feature-content p {
        color: var(--text-body);
    }

    /* Footer */
    footer {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .footer-brand p,
    .footer-links a,
    .footer-bottom p,
    .footer-legal a {
        color: var(--text-subtle);
    }

    .footer-links a:hover,
    .footer-legal a:hover {
        color: var(--text-body);
    }

    .footer-links h4 {
        color: var(--text-heading);
    }

    /* Newsletter section */
    .newsletter-section {
        background: linear-gradient(135deg, var(--bg-surface) 0%, var(--bg-page) 100%);
    }

    .newsletter-content h2 {
        color: var(--text-heading);
    }

    .newsletter-content p {
        color: var(--text-body);
    }

    .newsletter-privacy,
    .newsletter-privacy a {
        color: var(--text-subtle);
    }

    /* CTA section */
    .cta-section {
        background: var(--bg-surface);
    }

    .cta-content p {
        color: var(--text-body);
    }

    /* Gradient text adjustments for dark mode */
    .gradient-text {
        background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary) 100%);
        -webkit-background-clip: text;
        background-clip: text;
    }

    /* Form inputs */
    input[type="text"],
    input[type="email"],
    textarea {
        background: var(--bg-elevated);
        border-color: var(--border-default);
        color: var(--text-heading);
    }

    input[type="text"]::placeholder,
    input[type="email"]::placeholder,
    textarea::placeholder {
        color: var(--text-subtle);
    }

    /* Section borders */
    section {
        border-color: var(--border-default);
    }

    /* Code blocks */
    .code-content code {
        color: var(--text-heading);
    }

    /* Download page cards */
    .download-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .download-card h3 {
        color: var(--text-heading);
    }

    .download-features li {
        color: var(--text-body);
    }

    .license-note,
    .notify-text {
        color: var(--text-subtle);
    }

    /* Page hero (internal pages) */
    .page-hero {
        background: linear-gradient(135deg, var(--darker-bg) 0%, var(--darkest-bg) 100%);
    }

    /* Contact form */
    .contact-form input,
    .contact-form textarea {
        background: var(--bg-elevated);
        border-color: var(--border-default);
        color: var(--text-heading);
    }

    .contact-form label {
        color: var(--text-body);
    }

    /* Tools page */
    .tool-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .tool-card-coming {
        background: var(--bg-page);
    }

    .tool-card h2 {
        color: var(--text-heading);
    }

    .tool-card p {
        color: var(--text-body);
    }

    .tool-card code {
        background: var(--bg-elevated);
        color: var(--primary-light);
    }

    /* Scanner page */
    .scanner-panel {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .panel-header {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .panel-header h2 {
        color: var(--text-subtle);
    }

    #html-input {
        background: var(--bg-page);
        color: var(--text-heading);
    }

    #html-input::placeholder {
        color: var(--text-subtle);
    }

    #html-input:focus {
        background: var(--bg-surface);
    }

    .panel-actions {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    /* In dark mode, results placeholder should have dark background to match results-output */
    #results-output.results-placeholder {
        background: var(--darker-bg);
        color: var(--light-gray);
    }

    #results-output.results-placeholder code {
        background: var(--dark-bg);
        color: var(--primary-light);
    }

    .scanner-stats {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .scanner-stats .stat-value {
        color: var(--primary-light);
    }

    .scanner-stats .stat-label {
        color: var(--text-subtle);
    }

    .scanner-info {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .scanner-info h3 {
        color: var(--text-heading);
    }

    .scanner-info p {
        color: var(--text-body);
    }

    .scanner-info code {
        background: var(--bg-elevated);
        color: var(--primary-light);
    }

    /* Scanner CTA */
    .scanner-cta {
        background: var(--bg-surface);
    }

    .scanner-cta h3 {
        color: var(--text-heading);
    }

    .scanner-cta p {
        color: var(--text-body);
    }

    /* Preview Modal */
    .preview-modal-content {
        background: var(--bg-surface);
    }

    .preview-header {
        border-color: var(--border-default);
    }

    .preview-header h3 {
        color: var(--text-heading);
    }

    .preview-header p {
        color: var(--text-body);
    }

    .preview-close {
        color: var(--text-subtle);
    }

    .preview-close:hover {
        background: var(--bg-elevated);
        color: var(--text-heading);
    }

    .preview-footer {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .preview-edit-count {
        color: var(--text-subtle);
    }

    /* CSS Modal */
    #css-input {
        background: var(--bg-page);
        border-color: var(--border-default);
        color: var(--text-heading);
    }

    #css-input::placeholder {
        color: var(--text-subtle);
    }

    .css-status {
        color: var(--text-body);
    }

    /* Contact cards */
    .contact-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .contact-card:hover {
        border-color: var(--primary-light);
        box-shadow: 0 4px 20px rgba(6, 182, 212, 0.15);
    }

    .contact-card h3 {
        color: var(--text-heading);
    }

    .contact-card p {
        color: var(--text-body);
    }

    .contact-highlight {
        color: var(--primary-light);
    }

    /* FAQ section */
    .faq-section {
        background: var(--bg-page);
    }

    .faq-section h2 {
        color: var(--text-heading);
    }

    .faq-item {
        background: var(--bg-surface);
    }

    .faq-item h3 {
        color: var(--text-heading);
    }

    .faq-item p {
        color: var(--text-body);
    }

    /* Contact form wrapper */
    .contact-form-wrapper h2 {
        color: var(--text-heading);
    }

    .contact-form select {
        background: var(--bg-elevated);
        border-color: var(--border-default);
        color: var(--text-heading);
    }

    .contact-form select option {
        background: var(--bg-surface);
        color: var(--text-heading);
    }

    /* Form messages */
    .form-message.success {
        background: rgba(6, 182, 212, 0.1);
        border-color: var(--primary-light);
    }

    .form-message.error {
        background: rgba(239, 68, 68, 0.1);
    }
}

/* ===== COOKIE CONSENT BANNER ===== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--dark-bg);
    color: white;
    padding: var(--space-4) var(--space-6);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 300ms ease;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
}

.cookie-banner.visible {
    transform: translateY(0);
}

.cookie-content {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    text-align: center;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
}

.cookie-content p {
    color: var(--light-gray);
    font-size: 0.875rem;
    margin: 0;
    flex: 1;
    min-width: 100%;
}

@media (min-width: 768px) {
    .cookie-content {
        flex-direction: row;
        text-align: left;
        gap: var(--space-6);
        flex-wrap: wrap;
    }

    .cookie-content p {
        min-width: 200px;
    }
}

.cookie-actions {
    display: flex;
    align-items: center;
    gap: var(--space-4);
}

.cookie-link {
    color: var(--primary-light);
    font-size: 0.875rem;
    text-decoration: none;
}

.cookie-link:hover {
    text-decoration: underline;
}

.cookie-accept {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 200ms ease;
}

.cookie-accept:hover {
    background: var(--primary-light);
}

.cookie-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: var(--text-subtle);
    cursor: pointer;
    transition: all 200ms ease;
    flex-shrink: 0;
}

.cookie-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* ===== DEMO LINK MODAL ===== */
.demo-link-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 200ms ease;
    backdrop-filter: blur(4px);
}

.demo-link-modal.visible {
    opacity: 1;
}

.demo-link-modal-content {
    background: var(--bg-surface);
    border-radius: 12px;
    padding: var(--space-8);
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.demo-link-modal-content h3 {
    margin-bottom: var(--space-6);
    font-size: 1.25rem;
}

.demo-link-modal-content label {
    display: block;
    margin-bottom: var(--space-4);
}

.demo-link-modal-content label span {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: var(--space-2);
}

.demo-link-modal-content input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 200ms ease;
}

.demo-link-modal-content input:focus {
    outline: none;
    border-color: var(--primary);
}

.demo-link-actions {
    display: flex;
    gap: var(--space-3);
    justify-content: flex-end;
    margin-top: var(--space-6);
}

.demo-link-cancel {
    padding: 0.5rem 1rem;
    border: 2px solid var(--border);
    background: var(--bg-surface);
    border-radius: 8px;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 200ms ease;
}

.demo-link-cancel:hover {
    border-color: var(--text-muted);
}

.demo-link-save {
    padding: 0.5rem 1.25rem;
    border: none;
    background: var(--primary);
    color: white;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 200ms ease;
}

.demo-link-save:hover {
    background: var(--primary-dark);
}

/* ===== DEMO INTRO MODAL ===== */
.demo-intro-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    opacity: 0;
    transition: opacity 200ms ease;
    backdrop-filter: blur(4px);
}

.demo-intro-modal.visible {
    opacity: 1;
}

.demo-intro-content {
    background: var(--bg-surface);
    border-radius: 16px;
    padding: var(--space-8);
    width: 90%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.demo-intro-content h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-4);
    color: var(--text-main);
}

.demo-intro-content > p {
    color: var(--text-muted);
    margin-bottom: var(--space-4);
}

.demo-intro-content ul {
    text-align: left;
    list-style: none;
    margin: 0 0 var(--space-6);
    padding: 0;
}

.demo-intro-content li {
    padding: var(--space-3) var(--space-4);
    background: var(--off-white);
    border-radius: 8px;
    margin-bottom: var(--space-2);
    font-size: 0.9375rem;
    color: var(--text-main);
}

.demo-intro-content li strong {
    color: var(--primary);
}

.demo-intro-note {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: var(--space-6);
}

.demo-intro-start {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 9999px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 200ms ease;
}

.demo-intro-start:hover {
    background: var(--primary-dark);
}

/* ===== ERROR PAGES ===== */
.error-page {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-8) var(--space-4);
    background: linear-gradient(180deg, var(--off-white) 0%, var(--border-subtle) 100%);
}

@media (min-width: 768px) {
    .error-page {
        padding: var(--space-12) var(--space-6);
    }
}

.error-content {
    text-align: center;
    max-width: 540px;
    padding: var(--space-8) var(--space-6);
    background: var(--bg-surface);
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
}

@media (min-width: 768px) {
    .error-content {
        padding: var(--space-12);
        border-radius: 24px;
    }
}

.error-icon {
    margin-bottom: var(--space-4);
    color: var(--primary);
}

.error-icon svg {
    width: 64px;
    height: 64px;
    stroke-width: 1.25;
}

.error-code {
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--space-4);
}

@media (min-width: 768px) {
    .error-code {
        font-size: 7rem;
    }
}

.error-page h1 {
    font-size: 1.375rem;
    font-weight: 700;
    margin-bottom: var(--space-4);
    color: var(--text-main);
    letter-spacing: -0.02em;
}

@media (min-width: 768px) {
    .error-page h1 {
        font-size: 1.75rem;
    }
}

.error-message {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: var(--space-8);
    line-height: 1.7;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}

@media (min-width: 768px) {
    .error-message {
        font-size: 1.0625rem;
    }
}

.error-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-4);
    justify-content: center;
    margin-bottom: var(--space-8);
}

.error-actions .btn {
    width: 100%;
    padding: 0.875rem 1.75rem;
}

@media (min-width: 768px) {
    .error-actions {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
    }

    .error-actions .btn {
        width: auto;
        min-width: 140px;
    }
}

.error-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    opacity: 0.75;
    padding-top: var(--space-6);
    border-top: 1px solid var(--border);
}

/* ===== PAGE HERO (shared style for internal pages) ===== */
.page-hero {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    color: white;
    padding: var(--space-20) var(--space-4);
    text-align: center;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-hero .container {
    width: 100%;
}

.page-hero h1 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: var(--space-4);
}

@media (min-width: 768px) {
    .page-hero h1 {
        font-size: 2.5rem;
    }
}

.page-hero p {
    font-size: 1.125rem;
    color: var(--light-gray);
    max-width: 600px;
    margin: 0 auto;
}

/* ===== CONTACT PAGE ===== */

.contact-section {
    padding: var(--space-16) var(--space-4);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-10);
    max-width: 1100px;
    margin: 0 auto;
}

@media (min-width: 1024px) {
    .contact-grid {
        grid-template-columns: 1fr 400px;
        gap: var(--space-12);
    }
}

.contact-form-wrapper h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--space-2);
    color: var(--text-main);
}

.form-required-note {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: var(--space-4);
}

.form-group label .required {
    color: var(--error);
    font-weight: 400;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-main);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.875rem 1rem;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--bg-surface);
    transition: border-color 200ms ease, box-shadow 200ms ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--light-gray);
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1rem;
    padding-right: 2.5rem;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-submit-row {
    display: flex;
    flex-direction: column-reverse;
    align-items: stretch;
    gap: var(--space-4);
    margin-top: var(--space-2);
}

.contact-form .btn {
    width: 100%;
    padding: 0.875rem 2rem;
}

@media (min-width: 768px) {
    .form-submit-row {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .contact-form .btn {
        width: auto;
    }
}

.form-message {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4);
    border-radius: 10px;
    margin-top: var(--space-4);
}

.form-message[hidden] {
    display: none;
}

.form-message.success {
    background: var(--success-bg);
    color: var(--success-text);
}

.form-message.error {
    background: var(--error-bg);
    color: var(--error-text);
}

.form-message svg {
    flex-shrink: 0;
}

.form-message p {
    margin: 0;
    font-weight: 500;
}

/* Contact Info Cards */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.contact-card {
    background: var(--bg-surface);
    border: 2px solid var(--border);
    border-radius: 16px;
    padding: var(--space-6);
    transition: all 200ms ease;
}

.contact-card:hover {
    border-color: var(--primary);
    box-shadow: 0 8px 24px rgba(6, 182, 212, 0.15);
    transform: translateY(-2px);
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-4);
}

.contact-icon svg {
    color: white;
}

.contact-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: var(--space-2);
    color: var(--text-main);
}

.contact-card p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: var(--space-3);
}

.contact-link {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
    transition: color 200ms ease;
}

.contact-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.contact-highlight {
    display: inline-block;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

/* FAQ Section */
.faq-section {
    background: var(--bg-surface);
    padding: var(--space-16) var(--space-4);
}

.faq-section h2 {
    font-size: 1.75rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: var(--space-10);
    color: var(--text-main);
}

.faq-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    max-width: 900px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .faq-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.faq-item {
    padding: var(--space-6);
    background: var(--off-white);
    border-radius: 12px;
    transition: background-color 200ms ease, box-shadow 200ms ease;
}

.faq-item:hover {
    background: var(--bg-surface);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.faq-item h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: var(--space-3);
    color: var(--text-main);
}

.faq-item p {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.faq-item a {
    color: var(--primary);
    text-decoration: none;
}

.faq-item a:hover {
    text-decoration: underline;
}

/* ===== DOWNLOAD PAGE ===== */

.download-section {
    padding: var(--space-16) 0 var(--space-20);
}

.download-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--space-8);
    max-width: 800px;
    margin: 0 auto;
}

.download-card {
    background: var(--bg-surface);
    border-radius: 16px;
    border: 2px solid var(--border);
    padding: var(--space-10);
    position: relative;
    transition: all 300ms ease;
    display: flex;
    flex-direction: column;
}

.download-card:hover {
    border-color: var(--primary-light);
    box-shadow: 0 12px 32px -4px rgba(6, 182, 212, 0.15);
}

.download-card-pro {
    border-color: var(--accent);
}

.download-card-pro:hover {
    border-color: var(--accent);
    box-shadow: 0 12px 32px -4px rgba(249, 115, 22, 0.2);
}

.download-badge {
    position: absolute;
    top: -12px;
    right: 24px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
    color: white;
    padding: 0.375rem 1rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.download-header {
    text-align: center;
    margin-bottom: var(--space-8);
    padding-bottom: var(--space-8);
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.download-header h2 {
    font-size: 1.5rem;
    margin-bottom: var(--space-4);
}

.download-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: var(--space-2);
    margin-bottom: var(--space-4);
}

.download-amount .amount {
    font-size: 3rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
}

.download-amount .period {
    font-size: 1rem;
    color: var(--text-muted);
}

.download-header p {
    font-size: 0.9375rem;
    margin: 0 auto;
    flex: 1;
    display: flex;
    align-items: flex-start;
}

.download-features {
    list-style: none;
    margin-bottom: var(--space-8);
    flex: 1;
}

.download-features li {
    padding: var(--space-3) 0;
    color: var(--text-muted);
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.download-features li::before {
    content: '';
    width: 20px;
    height: 20px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2306B6D4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center;
    flex-shrink: 0;
}

.download-card-pro .download-features li::before {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23F97316' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center;
}

.download-features li.features-divider {
    font-weight: 600;
    color: var(--text-main);
}

.download-features li.features-divider::before {
    background: none;
    width: 20px;
}

.download-action {
    text-align: center;
    margin-top: auto;
}

.download-action .btn {
    width: 100%;
    justify-content: center;
}

.license-note,
.notify-text {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: var(--space-4);
}

.license-note a,
.notify-text a {
    color: var(--accent);
    text-decoration: none;
    transition: color 200ms ease;
}

.license-note a:hover,
.notify-text a:hover {
    color: var(--accent-dark);
    text-decoration: underline;
}

/* Legacy Section */
.legacy-section {
    background: var(--off-white);
    border-top: 1px solid var(--border);
}

.legacy-section h2 {
    font-size: 1.5rem;
    margin-bottom: var(--space-4);
    text-align: center;
}

.legacy-section > .container > p {
    margin: 0 auto var(--space-8);
    text-align: center;
}

.legacy-list {
    max-width: 600px;
    margin: 0 auto;
}

.legacy-item {
    display: flex;
    align-items: center;
    gap: var(--space-6);
    padding: var(--space-4) 0;
    border-bottom: 1px solid var(--border);
}

.legacy-item .version {
    font-weight: 600;
    color: var(--text-main);
    min-width: 80px;
}

.legacy-item .date {
    color: var(--text-muted);
    font-size: 0.875rem;
    flex: 1;
}

.legacy-item .status {
    background: var(--primary);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.legacy-download {
    color: var(--accent);
    font-weight: 500;
    font-size: 0.875rem;
}

/* Comparison Section */
.comparison-section {
    padding: var(--space-16) 0;
    background: var(--off-white);
    border-top: 1px solid var(--border);
}

.comparison-section h2 {
    text-align: center;
    margin-bottom: var(--space-4);
}

.comparison-section > .container > p {
    text-align: center;
    margin: 0 auto var(--space-10);
}

.comparison-table-wrapper {
    max-width: 700px;
    margin: 0 auto;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Wider table for competitor comparison (5 columns) */
.competitor-section .comparison-table-wrapper {
    max-width: 900px;
}

@media (min-width: 1024px) {
    .competitor-section .comparison-table-wrapper {
        max-width: 1000px;
    }
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-surface);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px -2px rgba(0,0,0,0.08);
}

.comparison-table th,
.comparison-table td {
    padding: var(--space-3) var(--space-4);
    text-align: left;
    border-bottom: 1px solid var(--border);
}

@media (min-width: 768px) {
    .comparison-table th,
    .comparison-table td {
        padding: var(--space-4) var(--space-6);
    }
}

.comparison-table th {
    background: var(--primary);
    color: white;
    font-weight: 600;
    font-size: 0.9375rem;
}

.comparison-table th:nth-child(2),
.comparison-table th:nth-child(3) {
    text-align: center;
    width: 70px;
}

@media (min-width: 768px) {
    .comparison-table th:nth-child(2),
    .comparison-table th:nth-child(3) {
        width: 100px;
    }
}

.comparison-table td {
    font-size: 0.9375rem;
    color: var(--text-main);
}

.comparison-table td:nth-child(2),
.comparison-table td:nth-child(3) {
    text-align: center;
}

.comparison-table .check {
    color: var(--primary);
    font-weight: 700;
    font-size: 1.25rem;
}

.comparison-table .check.pro {
    color: var(--accent);
}

.comparison-table .dash {
    color: var(--text-muted);
    font-size: 1.25rem;
}

.comparison-table .pro-feature td:first-child {
    font-weight: 500;
}

.comparison-table tbody tr:last-child td {
    border-bottom: none;
}

.comparison-table tbody tr:hover {
    background: var(--off-white);
}

/* Competitor comparison table */
.competitor-section {
    padding: var(--space-16) 0;
    background: var(--bg-page);
}

.competitor-section h2 {
    text-align: center;
    margin-bottom: var(--space-2);
}

.competitor-section > .container > p {
    text-align: center;
    color: var(--text-body);
    margin: 0 auto var(--space-8);
}

/* Competitor table - mobile optimizations */
.competitor-table {
    table-layout: fixed;
    width: 100%;
}

/* Column widths: Feature 28%, Pebble 20%, others 17.33% each */
.competitor-table th:nth-child(1),
.competitor-table td:nth-child(1) {
    width: 28%;
}

.competitor-table th:nth-child(2),
.competitor-table td:nth-child(2) {
    width: 20%;
}

.competitor-table th:nth-child(3),
.competitor-table td:nth-child(3),
.competitor-table th:nth-child(4),
.competitor-table td:nth-child(4),
.competitor-table th:nth-child(5),
.competitor-table td:nth-child(5) {
    width: 17.33%;
}

.competitor-table th,
.competitor-table td {
    padding: var(--space-2) var(--space-2);
    font-size: 0.8125rem;
    white-space: nowrap;
}

.competitor-table th:first-child,
.competitor-table td:first-child {
    white-space: normal;
}

@media (min-width: 480px) {
    .competitor-table th,
    .competitor-table td {
        padding: var(--space-3) var(--space-3);
        font-size: 0.875rem;
    }
}

@media (min-width: 768px) {
    .competitor-table th,
    .competitor-table td {
        padding: var(--space-4) var(--space-6);
        font-size: 0.9375rem;
        white-space: normal;
    }
}

@media (min-width: 1024px) {
    .competitor-table th,
    .competitor-table td {
        padding: var(--space-4) var(--space-8);
        font-size: 1rem;
    }
}

.competitor-table th.highlight,
.competitor-table td.highlight {
    background: rgba(6, 182, 212, 0.08);
}

.competitor-table th.highlight {
    background: var(--primary);
    color: white;
}

.table-footnote {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--text-subtle);
    margin-top: var(--space-4);
    max-width: 65ch;
    margin-left: auto;
    margin-right: auto;
}

@media (min-width: 768px) {
    .table-footnote {
        font-size: 0.875rem;
    }
}

/* ===== TOOLS PAGE ===== */

.tools-section {
    padding: var(--space-16) 0 var(--space-20);
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-8);
    max-width: 900px;
    margin: 0 auto;
}

.tool-card {
    background: var(--bg-surface);
    border-radius: 16px;
    border: 2px solid var(--border);
    padding: var(--space-8);
    transition: all 300ms ease;
    text-decoration: none;
    display: block;
}

a.tool-card:hover {
    border-color: var(--primary-light);
    box-shadow: 0 12px 32px -4px rgba(6, 182, 212, 0.15);
    transform: translateY(-2px);
}

.tool-card-coming {
    opacity: 0.7;
    background: var(--off-white);
}

.tool-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-6);
    color: white;
}

.tool-card-coming .tool-icon {
    background: var(--text-muted);
}

.tool-card h2 {
    font-size: 1.25rem;
    margin-bottom: var(--space-3);
    color: var(--text-main);
}

.tool-card p {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin-bottom: var(--space-6);
    line-height: 1.6;
}

.tool-card code {
    background: var(--off-white);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.875em;
    color: var(--primary-dark);
}

.tool-cta {
    display: inline-block;
    font-weight: 600;
    color: var(--primary);
    font-size: 0.9375rem;
}

a.tool-card:hover .tool-cta {
    color: var(--primary-dark);
}

.tool-cta-muted {
    display: inline-block;
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ===== SCANNER TOOL ===== */

.scanner-section {
    padding: var(--space-12) 0 var(--space-20);
}

.scanner-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-8);
    margin-bottom: var(--space-10);
}

@media (min-width: 1024px) {
    .scanner-layout {
        grid-template-columns: 1fr 1fr;
    }
}

.scanner-panel {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.2s, border-color 0.2s;
}

.scanner-panel:focus-within {
    border-color: var(--primary);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05), 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.panel-header {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
    align-items: flex-start;
    padding: var(--space-4) var(--space-6);
    background: var(--off-white);
    border-bottom: 1px solid var(--border);
}

@media (min-width: 768px) {
    .panel-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 0;
    }
}

.panel-header h2 {
    font-size: 0.875rem;
    font-weight: 600;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.css-status-indicator {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    background: var(--primary);
    color: white;
    border-radius: 4px;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    border-radius: 8px;
}

#html-input {
    flex: 1;
    min-height: 400px;
    max-height: 500px;
    padding: var(--space-5);
    border: none;
    resize: none;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 0.8125rem;
    line-height: 1.7;
    background: var(--bg-page);
}

#html-input::placeholder {
    color: var(--text-subtle);
}

#html-input:focus {
    outline: none;
    background: var(--bg-surface);
}

.panel-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--border);
    background: var(--off-white);
}

#results-output {
    flex: 1;
    min-height: 400px;
    max-height: 500px;
    padding: var(--space-5);
    overflow: auto;
    background: var(--darker-bg);
    color: var(--border);
}

#results-output.results-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: var(--bg-page);
    color: var(--text-muted);
}

#results-output.results-placeholder p {
    margin: 0;
    max-width: 280px;
    line-height: 1.6;
}

#results-output.results-placeholder code {
    background: var(--bg-surface);
    color: var(--primary-dark);
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8125rem;
}

#results-output pre {
    margin: 0;
    white-space: pre-wrap;
    word-wrap: break-word;
}

#results-output code {
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 0.8125rem;
    line-height: 1.8;
    color: var(--light-gray);
}

#results-output mark {
    background: rgba(6, 182, 212, 0.3);
    color: var(--primary-light);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-weight: 500;
}

#results-output .error {
    color: var(--error);
    background: transparent;
}

#results-output .security-notice {
    background: var(--warning-bg);
    border: none;
    border-bottom: 1px solid var(--warning);
    color: var(--warning-text);
    padding: 0.75rem 1rem;
    border-radius: 0;
    margin: calc(-1 * var(--space-5)) calc(-1 * var(--space-5)) var(--space-5);
    font-size: 0.8125rem;
}

.external-css-notice {
    background: var(--info-bg);
    border: none;
    border-bottom: 1px solid var(--primary);
    color: var(--info-text);
    padding: 0.75rem 1rem;
    border-radius: 0;
    margin: 0;
    font-size: 0.8125rem;
}

.css-status-indicator {
    display: none;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    color: var(--primary);
    background: rgba(6, 182, 212, 0.1);
    padding: 0.25rem 0.625rem;
    border-radius: 4px;
    margin-left: var(--space-2);
}

.css-status-indicator:not([hidden]) {
    display: inline-flex;
}

.css-status-indicator::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
}

.content-type-notice {
    background: var(--warning-bg);
    border: none;
    border-bottom: 1px solid var(--warning);
    color: var(--warning-text);
    padding: 0.75rem 1rem;
    border-radius: 0;
    margin: 0;
    font-size: 0.8125rem;
}

#preview-btn:disabled,
#copy-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.scanner-stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-6);
    padding: var(--space-6) 0;
    margin-top: var(--space-8);
    margin-bottom: var(--space-10);
    border-bottom: 1px solid var(--border);
}

.scanner-stats .stat {
    text-align: center;
    flex: 0 0 45%;
}

@media (min-width: 768px) {
    .scanner-stats {
        gap: var(--space-10);
        flex-wrap: nowrap;
    }

    .scanner-stats .stat {
        flex: 0 0 auto;
    }
}

.scanner-stats .stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.scanner-stats .stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.scanner-info {
    max-width: 800px;
    margin: 0 auto;
    padding-top: var(--space-16);
    padding-bottom: var(--space-10);
}

.scanner-info h3 {
    text-align: center;
    margin-bottom: var(--space-10);
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-8);
}

@media (min-width: 768px) {
    .info-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.info-item {
    background: var(--off-white);
    padding: var(--space-6);
    border-radius: 8px;
}

.info-item strong {
    display: block;
    margin-bottom: var(--space-2);
    color: var(--text-main);
}

.info-item p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin: 0;
}

.info-item code {
    background: var(--bg-surface);
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-size: 0.8125rem;
    color: var(--primary-dark);
}

.scanner-cta {
    text-align: center;
    padding: var(--space-14) var(--space-6);
    margin-top: var(--space-12);
    background: var(--off-white);
    border-radius: 16px;
}

.scanner-cta h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-4);
}

.scanner-cta p {
    color: var(--text-muted);
    margin-bottom: var(--space-6);
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.panel-header-actions {
    display: flex;
    gap: var(--space-2);
    align-items: center;
    width: 100%;
}

.panel-header-actions .btn-small {
    flex: 1;
    text-align: center;
}

@media (min-width: 768px) {
    .panel-header-actions {
        width: auto;
    }

    .panel-header-actions .btn-small {
        flex: none;
    }
}

/* Preview Modal */
.preview-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: var(--space-4);
}

.preview-modal[hidden] {
    display: none;
}

.preview-modal-content {
    background: var(--bg-surface);
    border-radius: 16px;
    width: 100%;
    max-width: 900px;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

@media (min-width: 768px) {
    .preview-modal-content {
        max-height: 90vh;
    }
}

.preview-header {
    padding: var(--space-4) var(--space-6);
    padding-right: calc(var(--space-6) + 48px);
    border-bottom: 1px solid var(--border);
    position: relative;
    background: var(--bg-surface);
}

.preview-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 var(--space-2) 0;
}

.preview-header p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.5;
}

.preview-close {
    position: absolute;
    top: var(--space-4);
    right: var(--space-4);
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
}

.preview-close:hover {
    background: var(--off-white);
    color: var(--text-main);
}

.preview-frame-wrapper {
    flex: 1;
    min-height: 300px;
    overflow: hidden;
}

.preview-frame-wrapper iframe {
    width: 100%;
    height: 100%;
    min-height: 300px;
    border: none;
}

@media (min-width: 768px) {
    .preview-frame-wrapper {
        min-height: 400px;
    }

    .preview-frame-wrapper iframe {
        min-height: 400px;
    }
}

.preview-footer {
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--off-white);
}

.preview-edit-count {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* CSS Modal */
.css-modal-content {
    max-width: 600px;
}

.css-modal-body {
    padding: var(--space-4) var(--space-6);
}

#css-input {
    width: 100%;
    min-height: 200px;
    padding: var(--space-4);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 0.8125rem;
    line-height: 1.6;
    resize: vertical;
}

#css-input:focus {
    outline: none;
    border-color: var(--primary);
}

.css-modal-actions {
    display: flex;
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.css-status {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ============================================
   ACCOUNT SYSTEM STYLES
   Mobile-first, with dark mode support
   ============================================ */

/* Account CSS Variables */
:root {
    --account-card-bg: #ffffff;
    --account-card-border: var(--border);
    --account-card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --account-input-bg: #ffffff;
    --account-input-border: var(--border);
    --account-input-focus: var(--primary);
    --account-label-color: var(--text-main);
    --account-text-color: var(--dark-text);
    --account-muted-color: var(--text-muted);
    --alert-error-bg: var(--error-bg);
    --alert-error-border: #fecaca;
    --alert-error-text: var(--error-text);
    --alert-success-bg: var(--success-bg);
    --alert-success-border: #bbf7d0;
    --alert-success-text: var(--success-text);
    --alert-info-bg: var(--info-bg);
    --alert-info-border: #bfdbfe;
    --alert-info-text: var(--info-text);
    --license-key-bg: #f1f5f9;
    --license-key-border: var(--border);
}

/* Dark Mode Account Variables: MOVED TO CONSOLIDATED BLOCK AT END */

/* Page Hero (smaller variant for account pages) */
.page-hero-small {
    padding: var(--space-8) 0;
    text-align: center;
}

.page-hero-small h1 {
    font-size: 1.75rem;
    margin-bottom: var(--space-2);
}

.page-hero-small p {
    color: var(--account-muted-color);
    margin: 0;
}

@media (min-width: 768px) {
    .page-hero-small {
        padding: var(--space-12) 0;
    }

    .page-hero-small h1 {
        font-size: 2.25rem;
    }
}

/* Account Section & Card */
.account-section {
    padding: var(--space-6) 0 var(--space-12);
}

.account-card {
    background: var(--account-card-bg);
    border: 1px solid var(--account-card-border);
    border-radius: 12px;
    box-shadow: var(--account-card-shadow);
    padding: var(--space-6);
    max-width: 420px;
    margin: 0 auto;
}

@media (min-width: 480px) {
    .account-section {
        padding: var(--space-8) 0 var(--space-12);
    }

    .account-card {
        padding: var(--space-8);
    }
}

@media (min-width: 768px) {
    .account-section {
        padding: var(--space-10) 0 var(--space-16);
    }
}

/* Account Forms */
.account-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.form-group label {
    font-weight: 500;
    color: var(--account-label-color);
    font-size: 0.875rem;
}

.form-group input {
    padding: var(--space-3);
    border: 1px solid var(--account-input-border);
    border-radius: 8px;
    background: var(--account-input-bg);
    color: var(--account-text-color);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--account-input-focus);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.form-group input::placeholder {
    color: var(--account-muted-color);
}

.form-group small {
    color: var(--account-muted-color);
    font-size: 0.75rem;
}

/* Account Buttons */
.btn-full {
    width: 100%;
    justify-content: center;
}

.account-form .btn {
    margin-top: var(--space-2);
}

/* Account Card Modifiers */
.account-card--wide {
    max-width: 500px;
}

/* Purchase Page Styles */
.purchase-subtitle {
    margin: var(--space-1) 0 0;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9375rem;
}

.purchase-summary {
    text-align: center;
}

.purchase-summary__title {
    font-size: 1.5rem;
    margin: 0 0 var(--space-2) 0;
}

.purchase-summary__tagline {
    color: var(--account-muted-color);
    margin: 0 0 var(--space-4) 0;
}

.purchase-price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: var(--space-4);
}

.purchase-price__currency {
    font-size: 1rem;
    font-weight: 400;
    color: var(--account-muted-color);
}

.purchase-features {
    list-style: none;
    padding: 0;
    margin: 0 0 var(--space-6) 0;
    text-align: left;
}

.purchase-features__item {
    padding: var(--space-2) 0;
    border-bottom: 1px solid var(--account-card-border);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.purchase-features__item:last-child {
    border-bottom: none;
}

.purchase-features__icon {
    flex-shrink: 0;
    color: var(--success);
}

.purchase-btn {
    font-size: 1.125rem;
    padding: var(--space-4);
}

.purchase-note {
    margin: var(--space-4) 0 0;
    font-size: 0.75rem;
    color: var(--account-muted-color);
    text-align: center;
}

/* Alerts */
.alert {
    padding: var(--space-3) var(--space-4);
    border-radius: 8px;
    margin-bottom: var(--space-4);
    font-size: 0.875rem;
}

.alert-error {
    background: var(--alert-error-bg);
    border: 1px solid var(--alert-error-border);
    color: var(--alert-error-text);
}

.alert-success {
    background: var(--alert-success-bg);
    border: 1px solid var(--alert-success-border);
    color: var(--alert-success-text);
}

.alert-info {
    background: var(--alert-info-bg);
    border: 1px solid var(--alert-info-border);
    color: var(--alert-info-text);
}

/* Account Footer (links below form) */
.account-footer {
    margin-top: var(--space-6);
    padding-top: var(--space-4);
    border-top: 1px solid var(--account-card-border);
    text-align: center;
}

.account-footer p {
    margin: 0;
    color: var(--account-muted-color);
    font-size: 0.875rem;
}

.account-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.account-footer a:hover {
    text-decoration: underline;
}

/* Dashboard Layout */
.dashboard-section {
    padding: var(--space-4) 0 var(--space-12);
}

.dashboard-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
    max-width: 900px;
    margin: 0 auto;
}

.dashboard-card {
    background: var(--account-card-bg);
    border: 1px solid var(--account-card-border);
    border-radius: 12px;
    padding: var(--space-4);
}

@media (min-width: 480px) {
    .dashboard-card {
        padding: var(--space-5);
    }
}

.dashboard-card h2 {
    font-size: 1.125rem;
    margin: 0 0 var(--space-4) 0;
    color: var(--account-label-color);
}

.dashboard-card-wide {
    grid-column: 1 / -1;
}

/* Upgrade Card - Professional gradient with subtle highlight */
.upgrade-card {
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
    border: 1px solid rgba(6, 182, 212, 0.3);
    grid-column: 1 / -1;
    position: relative;
    overflow: hidden;
}

.upgrade-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
}

.upgrade-card-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    align-items: flex-start;
}

.upgrade-card-icon {
    background: rgba(6, 182, 212, 0.15);
    padding: var(--space-3);
    border-radius: 12px;
    color: var(--primary-light);
}

.upgrade-card-icon svg {
    display: block;
}

.upgrade-card-text h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 var(--space-1) 0;
    color: #F8FAFC;
}

.upgrade-card-text p {
    font-size: 0.875rem;
    color: #94A3B8;
    margin: 0;
    line-height: 1.5;
}

.upgrade-card .btn-primary {
    background: var(--accent);
    color: white;
    border: none;
}

.upgrade-card .btn-primary:hover {
    background: var(--accent-dark);
}

@media (min-width: 480px) {
    .upgrade-card-content {
        flex-direction: row;
        align-items: center;
    }

    .upgrade-card-text {
        flex: 1;
    }

    .upgrade-card .btn-primary {
        flex-shrink: 0;
        width: auto;
        max-width: 160px;
    }
}

@media (min-width: 768px) {
    .dashboard-section {
        padding: var(--space-8) 0 var(--space-16);
    }

    .dashboard-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-6);
    }

    .dashboard-card {
        padding: var(--space-6);
    }
}

/* License Display */
.license-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.license-item {
    padding: var(--space-4);
    background: var(--license-key-bg);
    border: 1px solid var(--license-key-border);
    border-radius: 8px;
}

.license-key {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: var(--account-label-color);
    word-break: break-all;
}

.license-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin-top: var(--space-2);
    font-size: 0.75rem;
    color: var(--account-muted-color);
}

.license-status {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: 2px 8px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.license-status-pending {
    background: var(--alert-info-bg);
    color: var(--alert-info-text);
}

.license-status-active {
    background: var(--alert-success-bg);
    color: var(--alert-success-text);
}

.license-status-revoked {
    background: var(--alert-error-bg);
    color: var(--alert-error-text);
}

.license-refunded {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    color: var(--account-muted-color);
    font-style: italic;
}

.license-refunded svg {
    width: 14px;
    height: 14px;
}

.license-actions {
    margin-top: var(--space-3);
    padding-top: var(--space-3);
    border-top: 1px solid var(--license-key-border);
}

.license-actions .btn {
    font-size: 0.75rem;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: var(--space-8) var(--space-4);
    color: var(--account-muted-color);
}

.empty-state svg {
    width: 48px;
    height: 48px;
    margin-bottom: var(--space-4);
    opacity: 0.5;
}

.empty-state p {
    margin: 0 0 var(--space-4) 0;
}

/* User Info */
.user-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.user-info-row {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.user-info-label {
    font-size: 0.75rem;
    color: var(--account-muted-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.user-info-value {
    color: var(--account-text-color);
}

@media (min-width: 480px) {
    .user-info-row {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

/* Pro Purchase CTA */
.pro-cta {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border-radius: 12px;
    padding: var(--space-6);
    text-align: center;
}

.pro-cta h3 {
    font-size: 1.25rem;
    margin: 0 0 var(--space-2) 0;
}

.pro-cta p {
    margin: 0 0 var(--space-4) 0;
    opacity: 0.9;
}

.pro-cta .btn {
    background: white;
    color: var(--primary-dark);
}

.pro-cta .btn:hover {
    background: var(--off-white);
}

/* Dark Mode Pro CTA: MOVED TO CONSOLIDATED BLOCK AT END */

/* Account Actions */
.account-actions {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    margin-top: var(--space-4);
}

@media (min-width: 480px) {
    .account-actions {
        flex-direction: row;
    }
}
/* ============================================
   AUTH PAGES (Login/Register)
   Two-column layout with card + promo
   ============================================ */

/* Auth Page Variables */
:root {
    --auth-promo-bg: linear-gradient(135deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
    --auth-icon-bg: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    --auth-icon-accent-bg: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
}

/* Auth Page Layout - Mobile first */
.auth-page {
    min-height: calc(100vh - 60px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-6) var(--space-4);
    background: var(--bg-page);
}

.auth-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 960px;
    gap: var(--space-6);
}

/* Auth Card - Mobile first */
.auth-card {
    background: var(--account-card-bg);
    border: 1px solid var(--account-card-border);
    border-radius: 12px;
    box-shadow: var(--account-card-shadow);
    padding: var(--space-6);
    width: 100%;
}

.auth-header {
    text-align: center;
    margin-bottom: var(--space-4);
}

.auth-header h1 {
    font-size: 1.5rem;
    margin-bottom: var(--space-2);
    color: var(--account-label-color);
}

.auth-header p {
    color: var(--account-muted-color);
    margin: 0 auto;
    font-size: 0.9375rem;
}

/* Auth Icon - Mobile first */
.auth-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-3);
    background: var(--auth-icon-bg);
    color: white;
}

.auth-icon svg {
    width: 28px;
    height: 28px;
}

.auth-icon-accent {
    background: var(--auth-icon-accent-bg);
}

/* Auth Form */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.auth-form .form-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.auth-form .form-group label {
    font-weight: 500;
    color: var(--account-label-color);
    font-size: 0.875rem;
}

.auth-form .form-group input {
    padding: var(--space-3) var(--space-4);
    border: 1px solid var(--account-input-border);
    border-radius: 8px;
    background: var(--account-input-bg);
    color: var(--account-text-color);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-form .form-group input:focus {
    outline: none;
    border-color: var(--account-input-focus);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.15);
}

.auth-form .form-group input::placeholder {
    color: var(--account-muted-color);
}

.auth-form .form-group small {
    color: var(--account-muted-color);
    font-size: 0.75rem;
}

/* Form Label Row (for forgot password link) */
.form-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-link {
    font-size: 0.8125rem;
    color: var(--primary);
    text-decoration: none;
}

.form-link:hover {
    text-decoration: underline;
}

/* Form Errors */
.form-group.has-error input {
    border-color: var(--error);
}

.form-group.has-error input:focus {
    box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.15);
}

.form-error {
    color: var(--error-text);
    font-size: 0.8125rem;
    margin-top: var(--space-1);
}

/* Button Large Variant */
.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.0625rem;
}

/* Auth Terms */
.auth-terms {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--account-muted-color);
    margin: 0;
}

.auth-terms a {
    color: var(--primary);
    text-decoration: none;
}

.auth-terms a:hover {
    text-decoration: underline;
}

/* Auth Footer */
.auth-footer {
    margin-top: var(--space-6);
    padding-top: var(--space-4);
    border-top: 1px solid var(--account-card-border);
    text-align: center;
}

.auth-footer p {
    margin: 0;
    color: var(--account-muted-color);
    font-size: 0.9375rem;
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Auth Promo Panel */
.auth-promo {
    display: none;
    background: var(--auth-promo-bg);
    border-radius: 16px;
    padding: var(--space-8);
    color: white;
}

.auth-promo-content h2 {
    font-size: 1.5rem;
    margin-bottom: var(--space-6);
    color: white;
}

.auth-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.auth-features li {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    font-size: 1rem;
}

.auth-features li svg {
    flex-shrink: 0;
    color: var(--primary-light);
}

.auth-features li span {
    color: rgba(255, 255, 255, 0.9);
}

/* Auth Promo Enhancements */
.auth-promo-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.375rem 0.875rem;
    border-radius: 9999px;
    margin-bottom: var(--space-4);
}

.auth-promo-subtitle {
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: var(--space-6);
    line-height: 1.5;
}

.auth-promo-price {
    margin-top: var(--space-6);
    padding-top: var(--space-6);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.8);
}

.auth-promo-price strong {
    color: var(--primary-light);
    font-size: 1.5rem;
    font-weight: 700;
}

.auth-promo-note {
    margin-top: var(--space-6);
    padding-top: var(--space-6);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-promo-note p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin: 0;
}

.auth-promo-note p + p {
    margin-top: var(--space-2);
}

.auth-promo-note strong {
    color: white;
}

/* Auth Single-column Layout (forgot/reset password) */
.auth-container-single {
    max-width: 440px;
}

/* Auth Icon Variants */
.auth-icon-success {
    background: linear-gradient(135deg, var(--success) 0%, #22c55e 100%);
}

.auth-icon-error {
    background: linear-gradient(135deg, var(--error) 0%, #dc2626 100%);
}

/* Auth Success Actions */
.auth-success-actions {
    margin-top: var(--space-6);
}

/* Alerts with icons */
.alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
}

.alert svg {
    flex-shrink: 0;
    margin-top: 1px;
}

.alert__message {
    margin: var(--space-1) 0 0 0;
    font-size: 0.875rem;
}

/* Small tablets (480px) */
@media (min-width: 480px) {
    .auth-page {
        padding: var(--space-8) var(--space-6);
    }

    .auth-card {
        padding: var(--space-8);
        border-radius: 14px;
    }

    .auth-header {
        margin-bottom: var(--space-5);
    }

    .auth-header h1 {
        font-size: 1.625rem;
    }
}

/* Desktop Layout */
@media (min-width: 768px) {
    .auth-container {
        flex-direction: row;
        align-items: stretch;
    }

    .auth-card {
        flex: 1;
        max-width: 440px;
    }

    .auth-promo {
        display: flex;
        flex-direction: column;
        justify-content: center;
        flex: 1;
    }

    .auth-header h1 {
        font-size: 2rem;
    }
}

/* Dark Mode Overrides - Auth: MOVED TO CONSOLIDATED BLOCK AT END */

/* ============================================
   DASHBOARD PAGE ENHANCEMENTS
   ============================================ */

/* Dashboard Header - Mobile first */
.dashboard-header {
    background: var(--auth-promo-bg);
    padding: var(--space-6) 0;
    color: white;
}

.dashboard-header-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.dashboard-welcome {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.user-avatar svg {
    width: 20px;
    height: 20px;
    color: white;
    opacity: 0.9;
}

.dashboard-welcome h1 {
    font-size: 1.25rem;
    margin: 0 0 var(--space-1) 0;
    color: white;
}

.dashboard-welcome p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
}

.dashboard-actions {
    display: flex;
    width: 100%;
    gap: var(--space-2);
    flex-wrap: wrap;
    align-items: center;
}

.dashboard-actions .btn {
    flex: 1;
    justify-content: center;
    min-width: 0;
}

.dashboard-actions .btn {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    border-radius: 8px;
    gap: var(--space-2);
    transition: all 0.2s ease;
}

.dashboard-actions .btn svg {
    width: 16px;
    height: 16px;
}

.dashboard-actions .btn-primary {
    background: var(--primary);
    color: white;
    border: none;
}

.dashboard-actions .btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.dashboard-actions .btn-secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.9);
}

.dashboard-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
}

@media (min-width: 768px) {
    .dashboard-header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .dashboard-welcome h1 {
        font-size: 1.75rem;
    }
}

/* Dashboard Alerts */
.dashboard-alert {
    max-width: 900px;
    margin: 0 auto var(--space-6);
}

/* Dashboard Card Headers */
.dashboard-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-4);
    padding-bottom: var(--space-3);
    border-bottom: 1px solid var(--account-card-border);
}

.dashboard-card-header h2 {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: 1rem;
    margin: 0;
    color: var(--account-label-color);
}

.dashboard-card-header h2 svg {
    color: var(--primary);
}

.license-count {
    font-size: 0.8125rem;
    color: var(--account-muted-color);
    background: var(--license-key-bg);
    padding: var(--space-1) var(--space-2);
    border-radius: 9999px;
}

/* License Key Wrapper */
.license-key-wrapper {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

@media (min-width: 480px) {
    .license-key-wrapper {
        flex-direction: row;
        align-items: center;
        gap: var(--space-3);
    }
}

/* License Meta with Icons */
.license-domain,
.license-date {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
}

.license-domain svg,
.license-date svg {
    opacity: 0.6;
}

/* Empty State Enhancements */
.empty-state-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--license-key-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-4);
}

.empty-state-icon svg {
    color: var(--account-muted-color);
}

.empty-state h3 {
    font-size: 1.125rem;
    margin: 0 0 var(--space-2) 0;
    color: var(--account-label-color);
}

.empty-state p {
    margin: 0 auto var(--space-4);
    max-width: 300px;
}

/* Quick Links */
.quick-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.quick-links li a {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-3);
    border-radius: 8px;
    color: var(--account-text-color);
    text-decoration: none;
    transition: background-color 0.2s;
}

.quick-links li a:hover {
    background: var(--license-key-bg);
}

.quick-links li a svg {
    color: var(--primary);
    flex-shrink: 0;
}

/* Card Actions */
.card-actions {
    margin-top: var(--space-4);
    padding-top: var(--space-4);
    border-top: 1px solid var(--account-card-border);
    display: flex;
    justify-content: center;
}

/* Button Small Variant */
.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* Dashboard Compact Header */
.dashboard-header-compact {
    padding: var(--space-6) 0;
}

.dashboard-header-compact h1 {
    font-size: 1.5rem;
    margin: 0;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: var(--space-2);
    transition: color 0.2s;
}

.back-link:hover {
    color: white;
}

/* Back Link Inline (below header, above content) */
.back-link-inline {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    color: var(--text-subtle);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: var(--space-4);
    transition: color 0.2s;
}

.back-link-inline:hover {
    color: var(--primary);
}

.back-link-inline svg {
    flex-shrink: 0;
}

/* Settings Card */
.settings-card {
    background: var(--account-card-bg);
    border: 1px solid var(--account-card-border);
    border-radius: 16px;
    box-shadow: var(--account-card-shadow);
    padding: var(--space-8);
    max-width: 500px;
    margin: 0 auto;
}

/* Settings Form */
.settings-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.settings-form .form-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.settings-form .form-group label {
    font-weight: 500;
    color: var(--account-label-color);
    font-size: 0.875rem;
}

.settings-form .form-group input {
    padding: var(--space-3) var(--space-4);
    border: 1px solid var(--account-input-border);
    border-radius: 8px;
    background: var(--account-input-bg);
    color: var(--account-text-color);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.settings-form .form-group input:focus {
    outline: none;
    border-color: var(--account-input-focus);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.15);
}

.settings-form .form-group input::placeholder {
    color: var(--account-muted-color);
}

.settings-form .form-group small {
    color: var(--account-muted-color);
    font-size: 0.75rem;
}

/* Form Divider */
.form-divider {
    height: 1px;
    background: var(--account-card-border);
    margin: var(--space-2) 0;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: var(--space-3);
    margin-top: var(--space-4);
}

/* Dark Mode Dashboard: MOVED TO CONSOLIDATED BLOCK AT END */

/* Desktop enhancements for Account Section */
@media (min-width: 768px) {
    .auth-page {
        padding: var(--space-6) var(--space-4);
        min-height: calc(100vh - 80px);
    }

    .auth-card {
        padding: var(--space-8);
        border-radius: 16px;
    }

    .auth-header {
        margin-bottom: var(--space-6);
    }

    .auth-header h1 {
        font-size: 1.75rem;
    }

    .auth-header p {
        font-size: 1rem;
    }

    .auth-icon {
        width: 64px;
        height: 64px;
        border-radius: 16px;
        margin-bottom: var(--space-4);
    }

    .auth-icon svg {
        width: 32px;
        height: 32px;
    }

    .dashboard-header {
        padding: var(--space-8) 0;
    }

    .dashboard-header-content {
        gap: var(--space-6);
    }

    .dashboard-welcome {
        gap: var(--space-4);
    }

    .user-avatar {
        width: 56px;
        height: 56px;
    }

    .user-avatar svg {
        width: 24px;
        height: 24px;
    }

    .dashboard-welcome h1 {
        font-size: 1.5rem;
    }

    .dashboard-welcome p {
        font-size: 0.9375rem;
    }

    .dashboard-actions {
        width: auto;
    }

    .dashboard-actions .btn {
        flex: none;
    }

    .dashboard-section {
        padding: var(--space-6) 0 var(--space-12);
    }

    .dashboard-card {
        padding: var(--space-6);
        border-radius: 12px;
    }

    .dashboard-card-header {
        flex-direction: row;
        align-items: center;
        gap: var(--space-4);
        margin-bottom: var(--space-4);
        padding-bottom: var(--space-3);
    }

    .dashboard-card-header h2 {
        font-size: 1rem;
    }

    .license-count {
        font-size: 0.8125rem;
    }

    .license-item {
        padding: var(--space-4);
    }

    .license-key {
        font-size: 0.8125rem;
        letter-spacing: 0.05em;
    }

    .license-status {
        font-size: 0.75rem;
        padding: 3px 8px;
    }

    .license-meta {
        font-size: 0.75rem;
        gap: var(--space-4);
    }

    .quick-links li a {
        padding: var(--space-3) var(--space-4);
        font-size: 1rem;
    }

    .quick-links li a svg {
        width: 18px;
        height: 18px;
    }

    .card-actions {
        margin-top: var(--space-4);
        padding-top: var(--space-4);
    }

    .empty-state-icon {
        width: 80px;
        height: 80px;
        margin-bottom: var(--space-4);
    }

    .empty-state-icon svg {
        width: 40px;
        height: 40px;
    }

    .empty-state h3 {
        font-size: 1.125rem;
    }

    .empty-state p {
        font-size: 1rem;
    }

    .upgrade-card {
        padding: var(--space-6);
    }

    .upgrade-card-icon {
        padding: var(--space-3);
    }

    .upgrade-card-icon svg {
        width: 32px;
        height: 32px;
    }

    .upgrade-card-text h3 {
        font-size: 1.125rem;
    }

    .upgrade-card-text p {
        font-size: 0.9375rem;
    }

    .upgrade-card .btn-primary {
        width: auto;
    }

    .settings-card {
        padding: var(--space-6);
        border-radius: 16px;
    }

    .form-actions {
        flex-direction: row;
    }

    .form-actions .btn {
        width: auto;
    }

    .account-section {
        padding: var(--space-4) 0 var(--space-12);
    }

    .account-card {
        padding: var(--space-6);
        border-radius: 12px;
    }

    .alert {
        padding: var(--space-4);
        font-size: 0.9375rem;
    }

    .alert svg {
        width: 18px;
        height: 18px;
    }

    .dashboard-header-compact {
        padding: var(--space-6) 0;
    }

    .dashboard-header-compact h1 {
        font-size: 1.5rem;
    }

    .back-link {
        font-size: 0.9375rem;
    }
}

/* ===== FEATURES PAGE - SPOTLIGHT SECTIONS ===== */

.spotlight {
    padding: var(--space-12) 0;
    background: var(--bg-surface);
}

.spotlight:nth-child(odd) {
    background: var(--bg-page);
}

.spotlight-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-12);
    align-items: center;
}

@media (min-width: 768px) {
    .spotlight {
        padding: var(--space-16) 0;
    }

    .spotlight-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-16);
    }

    .spotlight-reverse .spotlight-content {
        direction: rtl;
    }

    .spotlight-reverse .spotlight-content > * {
        direction: ltr;
    }

    .spotlight-text h2 {
        font-size: 2rem;
    }

    .spotlight-icon-display {
        width: 160px;
        height: 160px;
    }

    .spotlight-icon-display svg {
        width: 64px;
        height: 64px;
    }

    .features-divider-section {
        padding: var(--space-16) 0;
    }

    .section-cta {
        padding: var(--space-16) 0;
    }

    .cta-buttons {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .cta-buttons .btn {
        width: auto;
        max-width: none;
    }
}

.spotlight-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary);
    background: rgba(6, 182, 212, 0.1);
    padding: var(--space-1) var(--space-3);
    border-radius: 100px;
    margin-bottom: var(--space-4);
}

.spotlight-label-pro {
    color: var(--accent);
    background: rgba(249, 115, 22, 0.1);
}

.spotlight-text h2 {
    font-size: 1.5rem;
    margin-bottom: var(--space-4);
    color: var(--text-heading);
}

.spotlight-text > p {
    font-size: 1.125rem;
    line-height: 1.7;
    color: var(--text-body);
    margin-bottom: var(--space-6);
}

.spotlight-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.spotlight-features li {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    color: var(--text-body);
    font-size: 1rem;
}

.spotlight-features li svg {
    color: var(--success);
    flex-shrink: 0;
}

.spotlight-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.spotlight-demo {
    width: 100%;
    max-width: 400px;
}

.spotlight-demo .demo-browser {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.spotlight-demo .browser-dots {
    display: flex;
    gap: 6px;
    padding: 12px 16px;
    background: var(--bg-elevated);
}

.spotlight-demo .browser-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.spotlight-demo .browser-dots span:nth-child(1) { background: var(--window-close); }
.spotlight-demo .browser-dots span:nth-child(2) { background: var(--window-minimize); }
.spotlight-demo .browser-dots span:nth-child(3) { background: var(--window-maximize); }

.spotlight-demo .browser-content {
    padding: var(--space-6);
}

.spotlight-demo .demo-heading {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--space-3);
    color: var(--text-heading);
}

.spotlight-demo .demo-heading.editing {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
    border-radius: 4px;
    display: inline-block;
}

.spotlight-demo .demo-text-preview {
    color: var(--text-muted);
    margin: 0;
    font-size: 0.9375rem;
}

.spotlight-icon-display {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.1) 0%, rgba(6, 182, 212, 0.05) 100%);
    border: 1px solid rgba(6, 182, 212, 0.2);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.spotlight-icon-display svg {
    width: 48px;
    height: 48px;
}

.spotlight-icon-pro {
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.1) 0%, rgba(249, 115, 22, 0.05) 100%);
    border-color: rgba(249, 115, 22, 0.2);
    color: var(--accent);
}

/* Pro Features Divider */
.features-divider-section {
    padding: var(--space-12) 0;
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.features-divider-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
}

.features-divider-content {
    position: relative;
    z-index: 1;
}

.features-divider-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    background: rgba(249, 115, 22, 0.15);
    padding: var(--space-2) var(--space-4);
    border-radius: 100px;
    margin-bottom: var(--space-4);
}

.features-divider-section h2 {
    color: #F8FAFC;
    margin-bottom: var(--space-4);
}

.features-divider-section p {
    color: #94A3B8;
    max-width: 500px;
    margin: 0 auto;
}

/* Pro Spotlight Sections */
.spotlight-pro {
    background: linear-gradient(180deg, rgba(249, 115, 22, 0.02) 0%, transparent 100%);
}

.spotlight-pro:nth-child(odd) {
    background: linear-gradient(180deg, rgba(249, 115, 22, 0.04) 0%, rgba(249, 115, 22, 0.01) 100%);
}

/* Section CTA - Reusable CTA section */
.section-cta {
    padding: var(--space-10) 0;
    background: var(--bg-surface);
    text-align: center;
}

.section-cta h2 {
    margin-bottom: var(--space-3);
}

.section-cta > .container > p {
    max-width: 500px;
    margin: 0 auto var(--space-6);
    color: var(--text-body);
}

/* Dark Mode - Features Page: MOVED TO CONSOLIDATED BLOCK AT END */

/* ===== FEATURES PAGE ALTERNATIVE - CARD EXPLORER ===== */

.feature-explorer {
    padding: var(--space-12) 0;
}

/* Feature Tabs - Mobile first (horizontal scroll) */
.feature-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: var(--space-2);
    justify-content: flex-start;
    padding-bottom: var(--space-2);
    margin-left: calc(-1 * var(--space-4));
    margin-right: calc(-1 * var(--space-4));
    padding-left: var(--space-4);
    padding-right: var(--space-4);
    margin-bottom: var(--space-10);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.feature-tabs::-webkit-scrollbar {
    display: none;
}

.feature-tab {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-body);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    white-space: nowrap;
}

.feature-tab:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.feature-tab.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.feature-tab[data-category="pro"].active {
    background: var(--accent);
    border-color: var(--accent);
}

.feature-tab svg {
    display: none;
}

/* Feature Cards Grid - Mobile first (single column) */
.feature-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    margin-bottom: var(--space-8);
}

.feature-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 16px;
    padding: var(--space-5);
    position: relative;
    transition: all 0.3s ease;
    opacity: 0; /* Initially hidden, shown by JS animation */
}

/* When JS is disabled, show cards immediately */
.no-js .feature-card {
    opacity: 1;
}

.feature-card:hover {
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(6, 182, 212, 0.1);
    transform: translateY(-4px);
}

.feature-card-pro {
    border-color: rgba(249, 115, 22, 0.3);
}

.feature-card-pro:hover {
    border-color: var(--accent);
    box-shadow: 0 10px 30px rgba(249, 115, 22, 0.1);
}

.feature-card-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.1) 0%, rgba(6, 182, 212, 0.05) 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    margin-bottom: var(--space-4);
}

.feature-card-icon svg {
    width: 20px;
    height: 20px;
}

.feature-card-pro .feature-card-icon {
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.1) 0%, rgba(249, 115, 22, 0.05) 100%);
    color: var(--accent);
}

.feature-card h3 {
    font-size: 1.125rem;
    margin-bottom: var(--space-2);
    color: var(--text-heading);
}

.feature-card p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-body);
    margin: 0;
}

.feature-badge {
    position: absolute;
    top: var(--space-4);
    right: var(--space-4);
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: var(--space-1) var(--space-2);
    border-radius: 4px;
    background: rgba(6, 182, 212, 0.1);
    color: var(--primary);
}

.feature-badge-pro {
    background: rgba(249, 115, 22, 0.1);
    color: var(--accent);
}

/* Feature Count */
.feature-count {
    text-align: center;
    font-size: 1rem;
    color: var(--text-subtle);
}

.feature-count .count-number {
    font-weight: 700;
    color: var(--primary);
}

/* Fade-in animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Workflow Section - Mobile first */
.workflow-section {
    padding: var(--space-12) 0;
    background: var(--bg-page);
}

.workflow-section .section-header {
    text-align: center;
    margin-bottom: var(--space-12);
}

.workflow-section .section-header h2 {
    margin-bottom: var(--space-3);
}

.workflow-section .section-header p {
    max-width: 400px;
    margin: 0 auto;
}

.workflow-timeline {
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

/* Timeline line removed - positioning was inconsistent across browsers */

.workflow-step {
    display: flex;
    flex-direction: column;
    text-align: center;
    gap: var(--space-4);
    align-items: center;
    position: relative;
}

.workflow-number {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.workflow-content {
    flex: 1;
    text-align: center;
}

.workflow-code {
    text-align: left;
}

.workflow-content h3 {
    font-size: 1.25rem;
    margin-bottom: var(--space-2);
}

.workflow-content p {
    margin-bottom: var(--space-4);
}

.workflow-code {
    background: var(--darker-bg);
    padding: var(--space-4);
    border-radius: 8px;
    overflow-x: auto;
}

.workflow-code code {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.875rem;
    color: #E2E8F0;
}

.workflow-code .highlight {
    color: var(--primary-light);
}

/* Workflow Visual - Step 3 illustration */
.workflow-visual {
    margin-top: var(--space-4);
}

.workflow-visual-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: var(--space-2);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.workflow-visual-edit {
    background: var(--off-white);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: var(--space-2) var(--space-3);
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.workflow-visual-text {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-heading);
    background: linear-gradient(180deg, rgba(6, 182, 212, 0.15) 0%, rgba(6, 182, 212, 0.1) 100%);
    border-radius: 2px;
    padding: 0 2px;
}

.workflow-visual-cursor {
    width: 2px;
    height: 1.25em;
    background: var(--primary);
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* Dark Mode - Features 2 Page: MOVED TO CONSOLIDATED BLOCK AT END */

/* Desktop - Features 2 Page Enhancements */
@media (min-width: 768px) {
    .feature-explorer {
        padding: var(--space-16) 0;
    }

    .feature-tabs {
        flex-wrap: wrap;
        overflow-x: visible;
        justify-content: center;
        margin-left: 0;
        margin-right: 0;
        padding-left: 0;
        padding-right: 0;
        padding-bottom: 0;
    }

    .feature-tab {
        padding: var(--space-3) var(--space-6);
        font-size: 0.9375rem;
    }

    .feature-tab svg {
        display: block;
        width: 18px;
        height: 18px;
    }

    .feature-cards {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .feature-card {
        padding: var(--space-6);
    }

    .feature-card-icon {
        width: 56px;
        height: 56px;
    }

    .feature-card-icon svg {
        width: 28px;
        height: 28px;
    }

    .workflow-section {
        padding: var(--space-16) 0;
    }

    .workflow-timeline {
        gap: var(--space-8);
    }

    .workflow-step {
        flex-direction: row;
        text-align: left;
        gap: var(--space-6);
        align-items: flex-start;
    }

    .workflow-number {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }

    .workflow-content {
        text-align: left;
        padding-top: var(--space-2);
    }
}

/* ============================================
   ADMIN DASHBOARD STYLES
   Owner-only admin interface
   ============================================ */

.admin-page {
    background: var(--bg-page);
    min-height: 100vh;
}

.admin-header {
    background: linear-gradient(135deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
    padding: var(--space-8) 0;
    color: white;
}

.admin-header-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-4);
}

.admin-welcome {
    display: flex;
    align-items: center;
    gap: var(--space-4);
}

.admin-badge {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.admin-welcome h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

.admin-welcome p {
    color: var(--light-gray);
    margin: 0;
    font-size: 0.875rem;
}

.admin-actions {
    display: flex;
    gap: var(--space-3);
    width: 100%;
}

.admin-actions .btn {
    flex: 1;
    justify-content: center;
}

.admin-alert-section {
    padding: var(--space-4) 0 0;
}

/* Metrics Grid */
.admin-metrics {
    padding: var(--space-8) 0;
}

.metrics-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
}

.metric-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    padding: var(--space-4);
    display: flex;
    align-items: flex-start;
    gap: var(--space-4);
    transition: transform 0.2s, box-shadow 0.2s;
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.metric-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.metric-icon--users {
    background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
    color: white;
}

.metric-icon--licenses {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}

.metric-icon--revenue {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.metric-icon--downloads {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: white;
}

.metric-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.metric-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-heading);
    line-height: 1.2;
}

.metric-label {
    font-size: 0.875rem;
    color: var(--text-subtle);
    font-weight: 500;
}

.metric-delta,
.metric-detail {
    font-size: 0.75rem;
    color: var(--text-subtle);
}

.metric-delta--positive {
    color: var(--success);
}

/* Admin Section & Tabs */
.admin-section {
    padding: 0 0 var(--space-12);
}

.admin-tabs {
    display: flex;
    gap: var(--space-2);
    border-bottom: 1px solid var(--border-default);
    margin-bottom: var(--space-6);
    overflow-x: auto;
    padding: 0 var(--space-2);
}

.admin-tab {
    padding: var(--space-3) var(--space-6);
    background: none;
    border: none;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-subtle);
    cursor: pointer;
    position: relative;
    white-space: nowrap;
    transition: color 0.2s;
}

.admin-tab:hover {
    color: var(--text-heading);
}

.admin-tab.active {
    color: var(--primary);
}

.admin-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 2px 2px 0 0;
}

/* Admin Panel */
.admin-panel {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    overflow: hidden;
}

.admin-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--border-default);
    background: var(--bg-elevated);
}

.admin-panel-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-heading);
    margin: 0;
}

.admin-panel-count {
    font-size: 0.875rem;
    color: var(--text-subtle);
}

/* Admin Table */
.admin-table-wrapper {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.admin-table th {
    text-align: left;
    padding: var(--space-2) var(--space-3);
    font-weight: 600;
    color: var(--text-subtle);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border-default);
    background: var(--bg-elevated);
    white-space: nowrap;
}

.admin-table td {
    padding: var(--space-2) var(--space-3);
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-body);
    vertical-align: middle;
}

.admin-table tr:last-child td {
    border-bottom: none;
}

.admin-table tr:hover td {
    background: var(--bg-elevated);
}

/* Table cell components */
.license-key-small {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
    font-size: 0.75rem;
    background: var(--bg-elevated);
    padding: var(--space-1) var(--space-2);
    border-radius: 4px;
    color: var(--text-heading);
    word-break: break-all;
}

.user-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-email {
    color: var(--text-heading);
    font-weight: 500;
}

.user-name {
    font-size: 0.75rem;
    color: var(--text-subtle);
}

.domain-badge {
    display: inline-block;
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8125rem;
    color: var(--text-heading);
}

.status-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: capitalize;
}

.status-badge--pending {
    background: var(--warning-bg);
    color: var(--warning-text);
}

.status-badge--active {
    background: var(--success-bg);
    color: var(--success-text);
}

.status-badge--revoked {
    background: var(--error-bg);
    color: var(--error-text);
}

.status-badge--test {
    background: var(--warning-bg);
    color: var(--warning-text);
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge--refunded {
    background: var(--error-bg);
    color: var(--error-text);
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-action--refund {
    color: var(--error);
    background: transparent;
    border: 1px solid var(--error);
}

.btn-action--refund:hover {
    background: var(--error);
    color: white;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-body);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-sm);
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
}

.checkbox-label input[type="checkbox"] {
    margin: 0;
}

.checkbox-label:hover {
    border-color: var(--primary);
}

.date-cell {
    color: var(--text-subtle);
    white-space: nowrap;
}

.version-badge {
    display: inline-block;
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-heading);
}

.tier-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.tier-badge--free {
    background: var(--bg-elevated);
    color: var(--text-subtle);
}

.tier-badge--pro {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}

.tier-badge--core {
    background: var(--bg-elevated);
    color: var(--text-body);
    border: 1px solid var(--border-default);
}

/* Installs Tab Metrics */
.installs-metric {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: var(--space-3);
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-default);
}

.installs-metric__value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-heading);
    line-height: 1;
}

.installs-metric__value--pro {
    color: var(--accent);
}

.installs-metric__value--core {
    color: var(--primary);
}

.installs-metric__value--warning {
    color: var(--warning-text);
}

.installs-metric__label {
    font-size: 0.75rem;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: var(--space-1);
}

.check-count {
    display: inline-block;
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-body);
}

.license-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    background: var(--primary);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 6px;
}

.verified-badge {
    display: inline-flex;
    color: var(--success);
    margin-left: var(--space-1);
    vertical-align: middle;
}

.owner-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 2px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.text-muted {
    color: var(--text-subtle);
}

/* Action buttons */
.action-buttons {
    display: flex;
    gap: var(--space-2);
    flex-wrap: wrap;
}

.inline-form {
    display: inline;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border-default);
    border-radius: 6px;
    background: var(--bg-surface);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-action:hover {
    background: var(--bg-elevated);
}

.btn-action--danger {
    color: var(--error);
}

.btn-action--danger:hover {
    background: var(--error-bg);
    border-color: var(--error);
}

.btn-action--success {
    color: var(--success);
}

.btn-action--success:hover {
    background: var(--success-bg);
    border-color: var(--success);
}

.btn-action--warning {
    color: var(--warning-text);
}

.btn-action--warning:hover {
    background: var(--warning-bg);
    border-color: var(--warning);
}

/* Empty state */
.empty-state {
    padding: var(--space-12) var(--space-6);
    text-align: center;
    color: var(--text-subtle);
}

/* Admin Create Form */
.admin-create-form {
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--border-default);
    background: var(--bg-elevated);
}

.create-license-form .form-row {
    display: flex;
    gap: var(--space-3);
    align-items: center;
}

.create-license-form .form-input {
    flex: 1;
    max-width: 320px;
    padding: var(--space-2) var(--space-3);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    font-size: 0.875rem;
    background: var(--bg-surface);
    color: var(--text-heading);
}

.create-license-form .form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.create-license-form .form-input::placeholder {
    color: var(--text-subtle);
}

/* ============================================
   ADMIN DASHBOARD ENHANCEMENT - Charts, Maps, Filters
   ============================================ */

/* Chart Container */
.chart-container {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    padding: var(--space-6);
    margin-bottom: var(--space-6);
}

.chart-container__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-4);
    flex-wrap: wrap;
    gap: var(--space-3);
}

.chart-container__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-heading);
    margin: 0;
}

.chart-container__canvas {
    position: relative;
    width: 100%;
    height: 200px;
}

/* Charts Grid - Mobile first (single column) */
.charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    margin-bottom: var(--space-6);
}

.charts-grid--full {
    grid-template-columns: 1fr;
}

/* Date Range Picker - Mobile first */
.date-range-picker {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-1);
    background: var(--bg-elevated);
    padding: var(--space-1);
    border-radius: 8px;
}

.date-range-picker__btn {
    padding: var(--space-2) var(--space-3);
    background: transparent;
    border: none;
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-subtle);
    cursor: pointer;
    transition: all 0.2s;
}

.date-range-picker__btn:hover {
    color: var(--text-heading);
}

.date-range-picker__btn.active {
    background: var(--bg-surface);
    color: var(--primary);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Map Container */
.map-container {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: var(--space-6);
}

.map-container__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--border-default);
}

.map-container__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-heading);
    margin: 0;
}

.map-toggle {
    display: flex;
    gap: 2px;
    background: var(--bg-elevated);
    border-radius: 6px;
    padding: 2px;
}

.map-toggle__btn {
    padding: var(--space-2) var(--space-3);
    font-size: 0.8125rem;
    font-weight: 500;
    border: none;
    background: transparent;
    color: var(--text-body);
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
}

.map-toggle__btn:hover {
    background: var(--bg-surface);
}

.map-toggle__btn--active {
    background: var(--primary);
    color: white;
}

.map-toggle__btn--active:hover {
    background: var(--primary-dark);
}

.map-container__map {
    height: 280px;
    width: 100%;
}

.map-legend {
    display: flex;
    gap: var(--space-4);
    padding: var(--space-3) var(--space-6);
    background: var(--bg-elevated);
    border-top: 1px solid var(--border-default);
}

.map-legend__item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: 0.8125rem;
    color: var(--text-body);
}

.map-legend__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.map-legend__dot--core {
    background: var(--primary);
}

.map-legend__dot--pro {
    background: var(--accent);
}

/* Filter Bar - Mobile first */
.filter-bar {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-default);
    flex-wrap: wrap;
}

.filter-bar__search {
    flex: 1;
    min-width: 100%;
    max-width: 100%;
    position: relative;
}

.filter-bar__search-input {
    width: 100%;
    padding: var(--space-2) var(--space-3) var(--space-2) var(--space-8);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    font-size: 0.875rem;
    background: var(--bg-surface);
    color: var(--text-heading);
}

.filter-bar__search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.filter-bar__search-icon {
    position: absolute;
    left: var(--space-3);
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-subtle);
    pointer-events: none;
}

.filter-bar__select {
    padding: var(--space-2) var(--space-3);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    font-size: 0.875rem;
    background: var(--bg-surface);
    color: var(--text-heading);
    cursor: pointer;
}

.filter-bar__select:focus {
    outline: none;
    border-color: var(--primary);
}

.filter-bar__actions {
    display: flex;
    gap: var(--space-2);
    width: 100%;
    margin-left: 0;
    margin-top: var(--space-2);
}

/* Export Button */
.btn-export {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-body);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-export:hover {
    background: var(--bg-elevated);
    border-color: var(--primary);
    color: var(--primary);
}

/* Bulk Actions Bar - Mobile first */
.bulk-actions {
    display: none;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}

.bulk-actions.active {
    display: flex;
}

.bulk-actions__count {
    font-size: 0.875rem;
    font-weight: 500;
}

.bulk-actions__buttons {
    display: flex;
    gap: var(--space-2);
}

.bulk-actions__btn {
    padding: var(--space-1) var(--space-3);
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: white;
    cursor: pointer;
    transition: background 0.2s;
}

.bulk-actions__btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.bulk-actions__btn--danger {
    background: rgba(248, 113, 113, 0.3);
}

.bulk-actions__btn--danger:hover {
    background: rgba(248, 113, 113, 0.5);
}

/* Sortable Table Headers */
.admin-table th.sortable {
    cursor: pointer;
    user-select: none;
}

.admin-table th.sortable:hover {
    background: var(--bg-surface);
}

.admin-table th.sortable::after {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: var(--space-2);
    vertical-align: middle;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid var(--text-subtle);
    opacity: 0;
    transition: opacity 0.2s;
}

.admin-table th.sortable:hover::after {
    opacity: 0.5;
}

.admin-table th.sorted::after {
    opacity: 1;
}

.admin-table th.sorted--asc::after {
    border-top: none;
    border-bottom: 4px solid var(--primary);
}

.admin-table th.sorted--desc::after {
    border-top: 4px solid var(--primary);
}

/* Checkbox Cell */
.checkbox-cell {
    width: 40px;
    text-align: center;
}

.checkbox-cell input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
    cursor: pointer;
}

/* Analytics Grid - Mobile first */
.analytics-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-6);
    margin-bottom: var(--space-6);
}

.analytics-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    padding: var(--space-6);
}

.analytics-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-4);
}

.analytics-card__title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
}

.analytics-card__value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-heading);
    line-height: 1.2;
}

.analytics-card__change {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    font-size: 0.8125rem;
    font-weight: 500;
    margin-top: var(--space-2);
}

.analytics-card__change--up {
    color: var(--success);
}

.analytics-card__change--down {
    color: var(--error);
}

/* Cohort Table */
.cohort-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.cohort-table th,
.cohort-table td {
    padding: var(--space-2) var(--space-3);
    text-align: center;
    border: 1px solid var(--border-default);
}

.cohort-table th {
    background: var(--bg-elevated);
    font-weight: 600;
    color: var(--text-subtle);
}

.cohort-table td {
    background: var(--bg-surface);
}

.cohort-table td.cohort-high {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success-text);
}

.cohort-table td.cohort-medium {
    background: rgba(251, 191, 36, 0.2);
    color: var(--warning-text);
}

.cohort-table td.cohort-low {
    background: rgba(248, 113, 113, 0.2);
    color: var(--error-text);
}

/* Admin Settings Card */
.admin-settings-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-default);
    border-radius: 12px;
    overflow: hidden;
}

.admin-settings-card__section {
    padding: var(--space-6);
    border-bottom: 1px solid var(--border-default);
}

.admin-settings-card__section:last-child {
    border-bottom: none;
}

.admin-settings-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-heading);
    margin: 0 0 var(--space-4);
}

.admin-settings-card__description {
    font-size: 0.875rem;
    color: var(--text-subtle);
    margin: 0 0 var(--space-4);
}

/* Settings Form in Admin */
.admin-settings-form .form-group {
    margin-bottom: var(--space-4);
}

.admin-settings-form .form-group:last-child {
    margin-bottom: 0;
}

.admin-settings-form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-heading);
    margin-bottom: var(--space-2);
}

.admin-settings-form input[type="text"],
.admin-settings-form input[type="email"],
.admin-settings-form input[type="password"] {
    width: 100%;
    max-width: 400px;
    padding: var(--space-3);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    font-size: 0.9375rem;
    background: var(--bg-surface);
    color: var(--text-heading);
}

.admin-settings-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.admin-settings-form .form-row {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.admin-settings-form .form-row .form-group {
    flex: 1;
}

/* Session Info - Mobile first */
.session-info {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-4);
}

.session-info__item {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.session-info__label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.session-info__value {
    font-size: 0.9375rem;
    color: var(--text-heading);
}

/* License Detail Modal */
.license-modal {
    max-width: 600px;
}

.license-modal__header {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-4);
}

.license-modal__key {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
    font-size: 1rem;
    background: var(--bg-elevated);
    padding: var(--space-2) var(--space-3);
    border-radius: 6px;
    color: var(--text-heading);
    flex: 1;
}

.license-modal__copy {
    padding: var(--space-2);
    background: transparent;
    border: 1px solid var(--border-default);
    border-radius: 6px;
    cursor: pointer;
    color: var(--text-subtle);
    transition: all 0.2s;
}

.license-modal__copy:hover {
    background: var(--bg-elevated);
    color: var(--primary);
    border-color: var(--primary);
}

.license-modal__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-4);
    margin-bottom: var(--space-6);
}

.license-modal__field {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.license-modal__field--full {
    grid-column: 1 / -1;
}

.license-modal__label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.license-modal__value {
    font-size: 0.9375rem;
    color: var(--text-heading);
}

.license-modal__actions {
    display: flex;
    gap: var(--space-3);
    padding-top: var(--space-4);
    border-top: 1px solid var(--border-default);
    flex-wrap: wrap;
}

/* Sparkline */
.sparkline {
    display: inline-block;
    width: 60px;
    height: 20px;
    vertical-align: middle;
}

/* Metric Card with Sparkline */
.metric-card--sparkline {
    position: relative;
}

.metric-card--sparkline .sparkline {
    position: absolute;
    bottom: var(--space-4);
    right: var(--space-4);
}

/* Top Domains List */
.top-domains {
    list-style: none;
    padding: 0;
    margin: 0;
}

.top-domains__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-3) 0;
    border-bottom: 1px solid var(--border-subtle);
}

.top-domains__item:last-child {
    border-bottom: none;
}

.top-domains__rank {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-elevated);
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-subtle);
    margin-right: var(--space-3);
}

.top-domains__domain {
    flex: 1;
    font-size: 0.875rem;
    color: var(--text-heading);
}

.top-domains__count {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary);
}

/* Copy Toast Notification */
.copy-toast {
    position: fixed;
    bottom: var(--space-6);
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--dark-bg);
    color: white;
    padding: var(--space-3) var(--space-6);
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 9999;
}

.copy-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Desktop enhancements for Admin Dashboard */
@media (min-width: 768px) {
    .admin-header {
        padding: var(--space-12) 0;
    }

    .admin-header-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: var(--space-6);
        flex-wrap: wrap;
    }

    .admin-actions {
        width: auto;
    }

    .admin-actions .btn {
        flex: none;
    }

    .metrics-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }

    .metric-card {
        padding: var(--space-6);
    }

    .admin-tabs {
        padding: 0;
    }

    .admin-table th,
    .admin-table td {
        padding: var(--space-3) var(--space-4);
    }

    .charts-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .chart-container__canvas {
        height: 280px;
    }

    .map-container__map {
        height: 400px;
    }

    .filter-bar {
        padding: var(--space-4) var(--space-6);
    }

    .filter-bar__search {
        min-width: 200px;
        max-width: 320px;
    }

    .filter-bar__actions {
        width: auto;
        margin-left: auto;
        margin-top: 0;
    }

    .bulk-actions {
        gap: var(--space-4);
    }

    .analytics-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }

    .license-modal__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .session-info {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .admin-settings-form .form-row {
        flex-direction: row;
    }
}

/* ============================================
   DARK MODE - SUPPLEMENTARY OVERRIDES
   Additional dark mode styles consolidated here
   Main dark mode block is at line ~2412
   ============================================ */
@media (prefers-color-scheme: dark) {
    /* Account page CSS variables */
    :root {
        --account-card-bg: #1e293b;
        --account-card-border: #334155;
        --account-card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
        --account-input-bg: #0f172a;
        --account-input-border: #475569;
        --account-input-focus: var(--primary-light);
        --account-label-color: #f1f5f9;
        --account-text-color: #cbd5e1;
        --account-muted-color: #94a3b8;
        --alert-error-bg: #450a0a;
        --alert-error-border: #7f1d1d;
        --alert-error-text: #fecaca;
        --alert-success-bg: #052e16;
        --alert-success-border: #166534;
        --alert-success-text: #bbf7d0;
        --alert-info-bg: #1e3a5f;
        --alert-info-border: #1e40af;
        --alert-info-text: #bfdbfe;
        --license-key-bg: #0f172a;
        --license-key-border: #334155;
        --auth-promo-bg: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    }

    /* Pro CTA gradient */
    .pro-cta {
        background: linear-gradient(135deg, #0e7490 0%, #155e75 100%);
    }

    /* Auth form focus states */
    .auth-form .form-group input:focus {
        box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.2);
    }

    .form-group.has-error input:focus {
        box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.2);
    }

    /* Dashboard dark mode */
    .dashboard-header {
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    }

    .dashboard-actions .btn-primary {
        background: var(--primary);
        color: white;
    }

    .dashboard-actions .btn-primary:hover {
        background: var(--primary-dark);
    }

    .dashboard-actions .btn-secondary {
        background: transparent;
        border-color: rgba(255, 255, 255, 0.15);
    }

    .dashboard-actions .btn-secondary:hover {
        background: rgba(255, 255, 255, 0.08);
        border-color: rgba(255, 255, 255, 0.25);
    }

    .settings-form .form-group input:focus {
        box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.2);
    }

    .settings-form .form-group.has-error input:focus {
        box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.2);
    }

    /* Features page dark mode */
    .spotlight-demo .demo-browser {
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    }

    .spotlight-icon-display {
        background: linear-gradient(135deg, rgba(6, 182, 212, 0.15) 0%, rgba(6, 182, 212, 0.08) 100%);
    }

    .spotlight-icon-pro {
        background: linear-gradient(135deg, rgba(249, 115, 22, 0.15) 0%, rgba(249, 115, 22, 0.08) 100%);
    }

    .features-divider-section {
        background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
    }

    /* Feature cards dark mode */
    .feature-card {
        box-shadow: none;
    }

    .feature-card:hover {
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    }

    .workflow-code {
        background: var(--darkest-bg);
    }

    /* Admin Dashboard dark mode */
    .admin-page {
        background: var(--bg-page);
    }

    .metric-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .metric-card:hover {
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    }

    .admin-panel {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .admin-panel-header {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .admin-table th {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .admin-table td {
        border-color: var(--border-subtle);
    }

    .admin-table tr:hover td {
        background: var(--bg-elevated);
    }

    .license-key-small {
        background: var(--bg-elevated);
    }

    .domain-badge,
    .version-badge {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .btn-action {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .btn-action:hover {
        background: var(--bg-elevated);
    }

    .tier-badge--free {
        background: var(--bg-elevated);
    }

    /* Dashboard Enhancement dark mode */
    .chart-container {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .date-range-picker {
        background: var(--bg-page);
    }

    .date-range-picker__btn.active {
        background: var(--bg-surface);
    }

    .map-container {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .map-legend {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .filter-bar {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .filter-bar__search-input,
    .filter-bar__select {
        background: var(--bg-surface);
        border-color: var(--border-default);
        color: var(--text-heading);
    }

    .btn-export {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .btn-export:hover {
        background: var(--bg-elevated);
    }

    .analytics-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .cohort-table th {
        background: var(--bg-elevated);
        border-color: var(--border-default);
    }

    .cohort-table td {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .admin-settings-card {
        background: var(--bg-surface);
        border-color: var(--border-default);
    }

    .admin-settings-card__section {
        border-color: var(--border-default);
    }

    .admin-settings-form input {
        background: var(--bg-page);
        border-color: var(--border-default);
    }

    .license-modal__key {
        background: var(--bg-elevated);
    }

    .license-modal__copy {
        border-color: var(--border-default);
    }

    .license-modal__actions {
        border-color: var(--border-default);
    }

    .top-domains__item {
        border-color: var(--border-subtle);
    }

    .top-domains__rank {
        background: var(--bg-elevated);
    }

    .copy-toast {
        background: var(--bg-elevated);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    }
}
