/* =====================================================
   DATAIQ LABS — DESIGN SYSTEM v1.0
   White primary · Dark navy for depth · Red as signal
   Poppins (display) · Inter (text) · JetBrains Mono (labels)
   ===================================================== */

:root {
    /* Brand */
    --red: #FF0042;
    --red-600: #D6003A;
    --red-700: #B8002F;
    --red-800: #A3002A;
    --red-50: #FFE5EC;
    --red-tint: rgba(255, 0, 66, 0.06);
    --red-glow: rgba(255, 0, 66, 0.7);

    --teal-700: #003554;
    --teal-800: #002E45;
    --navy-900: #0F1821;

    /* Surfaces */
    --white: #FFFFFF;
    --grey-50: #F3F6F9;
    --grey-100: #E7EDF2;
    --grey-200: #DDE4EA;
    --grey-300: #CBD5E1;

    /* Text */
    --text: #0F1821;
    --text-strong: #0F1821;
    --slate-500: #64748B;  /* muted on white */
    --slate-600: #475569;  /* muted on grey-50 */
    --slate-400: #94A3B8;

    /* Default (light theme) */
    --bg: var(--white);
    --bg-alt: var(--grey-50);
    --bg-card: var(--white);
    --border: var(--grey-100);
    --border-strong: var(--grey-300);
    --text-color: var(--text);
    --text-muted: var(--slate-500);

    /* Neumorphism */
    --neu-light: #FFFFFF;
    --neu-dark: #D5DDE6;
    --neu-base: #F3F6F9;
    --neu-inset-bg: #EEF2F6;

    /* Shadows */
    --e1: 0 1px 2px rgba(15,24,33,0.06), 0 0 0 1px var(--grey-100);
    --e2: 0 24px 48px -20px rgba(15,24,33,0.28);
    --e3: 0 32px 64px -24px rgba(15,24,33,0.28), 0 0 0 1px var(--grey-100);
    --focus-ring: 0 0 0 2px var(--white), 0 0 0 4px var(--red);

    /* Radii */
    --r-xs: 6px;    /* chip */
    --r-sm: 10px;   /* btn */
    --r-md: 16px;   /* panel */
    --r-lg: 20px;   /* card */
    --r-xl: 24px;   /* flagship card */
    --r-2xl: 28px;  /* hero card */
    --r-pill: 999px;

    /* Spacing (4px base) */
    --s-1: 4px;  --s-2: 8px;  --s-3: 12px; --s-4: 16px;
    --s-5: 20px; --s-6: 24px; --s-7: 32px; --s-8: 40px;
    --s-9: 56px; --s-10: 72px; --s-11: 96px; --s-12: 128px;

    /* Motion */
    --ease-out: cubic-bezier(.2, .7, .2, 1);
    --ease-sheet: cubic-bezier(.32, .72, 0, 1);
    --dur-fast: 160ms;
    --dur-base: 240ms;
    --dur-slow: 350ms;
    --dur-reveal: 700ms;

    /* Layout */
    --max-width: 1280px;
    --gutter: 40px;
    --header-h: 76px;
    --mobile-nav-h: 68px;
    --mobile-top-h: 60px;

    /* Z-layers */
    --z-nav: 50;
    --z-dropdown: 60;
    --z-mobile-nav: 90;
    --z-float: 70;
    --z-backdrop: 100;
    --z-modal: 110;
    --z-toast: 120;

    /* Fonts */
    --font-display: 'Poppins', Inter, system-ui, -apple-system, sans-serif;
    --font-text: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Dark theme */
:root[data-theme="dark"] {
    --bg: var(--navy-900);
    --bg-alt: var(--teal-800);
    --bg-card: var(--teal-800);
    --border: rgba(255,255,255,0.08);
    --border-strong: rgba(255,255,255,0.18);
    --text-color: #FFFFFF;
    --text-muted: #A7B4C2;
    --neu-base: var(--teal-800);
    --neu-inset-bg: #012233;
    --e1: 0 0 0 1px rgba(255,255,255,0.08);
    --e2: 0 24px 48px -20px rgba(0,0,0,0.7);
    --e3: 0 30px 60px -24px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.08);
}

* , *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font-text);
    font-size: 16px;
    line-height: 1.65;
    color: var(--text-color);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
    transition: background var(--dur-base) var(--ease-out), color var(--dur-base) var(--ease-out);
}

section { scroll-margin-top: calc(var(--header-h) + 16px); }

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--text-color);
    margin: 0 0 var(--s-4);
    text-wrap: balance;
}
h1 { font-size: 56px; line-height: 1.08; }
h2 { font-size: 48px; line-height: 1.1; }
h3 { font-size: 32px; line-height: 1.15; }
h4 { font-size: 20px; line-height: 1.3; }
h5 { font-size: 18px; }
h6 { font-size: 16px; }

@media (max-width: 767px) {
    h1 { font-size: 32px; line-height: 1.12; }
    h2 { font-size: 28px; line-height: 1.15; }
    h3 { font-size: 24px; line-height: 1.2; }
    h4 { font-size: 17px; }
}

p { margin: 0 0 1em; color: var(--text-muted); text-wrap: pretty; }
p.lead { font-size: 18px; line-height: 1.7; color: #334155; max-width: 62ch; }
:root[data-theme="dark"] p.lead { color: rgba(255,255,255,0.78); }

a { color: var(--red-600); text-decoration: none; transition: color var(--dur-fast) var(--ease-out); }
a:hover { color: var(--red-700); }

.mono { font-family: var(--font-mono); }
.eyebrow {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--red-600);
    display: inline-flex;
    align-items: center;
    gap: var(--s-3);
}
.eyebrow--muted { color: var(--slate-500); }
.eyebrow--light { color: rgba(255,255,255,0.72); }
.eyebrow--bar::before {
    content: '';
    width: 28px; height: 2px;
    background: var(--red);
}

/* Containers */
.wrap {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding-left: var(--gutter);
    padding-right: var(--gutter);
    position: relative;
}

.sec { padding: 128px 0; position: relative; }
.sec--sm { padding: 72px 0; }
.sec--lg { padding: 136px 0; }

/* Grid background pattern */
.grid-bg {
    background-image:
        linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px);
    background-size: 56px 56px;
}
.grid-bg-dark {
    background-image:
        linear-gradient(rgba(15,24,33,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15,24,33,0.04) 1px, transparent 1px);
    background-size: 56px 56px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    height: 52px;
    padding: 0 24px;
    font-family: var(--font-text);
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: -0.005em;
    border: 0;
    border-radius: var(--r-sm);
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    transition:
        transform var(--dur-fast) var(--ease-out),
        box-shadow var(--dur-base) var(--ease-out),
        background-color var(--dur-base) var(--ease-out),
        color var(--dur-base) var(--ease-out);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:focus-visible { outline: 0; box-shadow: var(--focus-ring); }
.btn:active { transform: translateY(1px) scale(.99); }
.btn:disabled, .btn.is-disabled {
    background: var(--grey-100) !important;
    color: var(--slate-500) !important;
    box-shadow: none !important;
    cursor: not-allowed;
    pointer-events: none;
}

.btn--primary { background: var(--red-600); color: #FFFFFF; }
.btn--primary:hover {
    background: var(--red-700);
    color: #FFFFFF;
    box-shadow: 0 12px 28px -12px var(--red-glow);
}

.btn--outline {
    background: var(--white);
    color: var(--navy-900);
    box-shadow: inset 0 0 0 1px var(--grey-300);
}
.btn--outline:hover {
    color: var(--navy-900);
    background: var(--white);
    box-shadow: inset 0 0 0 1px var(--navy-900);
}

.btn--light {
    background: var(--white);
    color: var(--navy-900);
}
.btn--light:hover { color: var(--navy-900); box-shadow: 0 10px 24px -12px rgba(0,0,0,0.5); }

.btn--ghost {
    background: transparent;
    color: #FFFFFF;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.32);
}
.btn--ghost:hover {
    color: #FFFFFF;
    box-shadow: inset 0 0 0 1px #FFFFFF;
}

.btn--sm { height: 44px; padding: 0 18px; font-size: 14px; }
.btn--block { width: 100%; display: flex; }

.btn.is-loading {
    color: transparent !important;
    pointer-events: none;
    position: relative;
}
.btn.is-loading::after {
    content: '';
    position: absolute; inset: 0; margin: auto;
    width: 18px; height: 18px;
    border: 2px solid currentColor; border-right-color: transparent;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    color: #fff;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Neumorphism */
.neu {
    background: var(--neu-base);
    border-radius: var(--r-lg);
    box-shadow: 12px 12px 28px var(--neu-dark), -12px -12px 28px var(--neu-light);
}
.neu-sm {
    background: var(--neu-base);
    border-radius: 12px;
    box-shadow: 5px 5px 12px var(--neu-dark), -5px -5px 12px var(--neu-light);
}
.neu-in {
    background: var(--neu-inset-bg);
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light);
}
:root[data-theme="dark"] .neu,
:root[data-theme="dark"] .neu-sm { box-shadow: var(--e1); background: var(--teal-800); }
:root[data-theme="dark"] .neu-in { box-shadow: var(--e1); background: var(--teal-700); }

/* Lift */
.lift {
    transition: transform var(--dur-slow) var(--ease-out), box-shadow var(--dur-slow) var(--ease-out);
}
.lift:hover { transform: translateY(-4px); }

/* Chip */
.chip {
    display: inline-flex;
    align-items: center;
    height: 28px;
    padding: 0 10px;
    border-radius: var(--r-xs);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.02em;
}

/* Pill filter */
.pill {
    height: 40px;
    padding: 0 18px;
    border-radius: 999px;
    border: 0;
    background: transparent;
    color: var(--slate-600);
    font-family: var(--font-text);
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all var(--dur-base) var(--ease-out);
}
.pill:hover { color: var(--navy-900); }
.pill--on, .pill.is-active {
    background: var(--white);
    color: var(--navy-900);
    box-shadow: 4px 4px 10px var(--neu-dark), -4px -4px 10px var(--neu-light);
}
.pill--on::before, .pill.is-active::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--red);
}

/* Reveal */
.reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity var(--dur-reveal) var(--ease-out), transform var(--dur-reveal) var(--ease-out);
    will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }
.reveal--d1 { transition-delay: 80ms; }
.reveal--d2 { transition-delay: 160ms; }
.reveal--d3 { transition-delay: 240ms; }
.reveal--d4 { transition-delay: 320ms; }
.reveal--d5 { transition-delay: 400ms; }

/* Live dot */
.live-dot {
    display: inline-block;
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--red);
    animation: blink 1.6s ease-in-out infinite;
}
@keyframes blink { 50% { opacity: 0.35; } }

/* Flash */
.flash {
    padding: 14px 18px;
    border-radius: var(--r-sm);
    margin-bottom: 16px;
    font-size: 14px;
    display: flex; align-items: center; gap: 10px;
    border: 1px solid;
}
.flash--success { background: #ECFDF5; color: #065F46; border-color: #A7F3D0; }
.flash--error { background: #FEF2F2; color: #991B1B; border-color: #FECACA; }
.flash--warning { background: #FFFBEB; color: #92400E; border-color: #FDE68A; }
.flash--info { background: #EFF6FF; color: #1E3A8A; border-color: #BFDBFE; }

/* Toasts */
.toast-container {
    position: fixed;
    top: calc(var(--header-h) + 16px); right: 16px;
    display: flex; flex-direction: column; gap: 10px;
    z-index: var(--z-toast);
    pointer-events: none;
    max-width: 380px; width: calc(100% - 32px);
}
.toast {
    background: var(--white);
    border: 1px solid var(--grey-100);
    color: var(--navy-900);
    padding: 14px 16px;
    border-radius: var(--r-md);
    box-shadow: var(--e2);
    display: flex; align-items: flex-start; gap: 12px;
    pointer-events: auto;
    animation: toastIn var(--dur-base) var(--ease-out);
    font-size: 14px;
    position: relative;
}
.toast::before {
    content: '';
    position: absolute;
    left: 0; top: 12px; bottom: 12px;
    width: 3px;
    background: var(--red);
    border-radius: 3px;
}
.toast--success::before { background: #10B981; }
.toast--error::before { background: var(--red-600); }
.toast--warning::before { background: #F59E0B; }
.toast__icon { width: 18px; height: 18px; flex-shrink: 0; margin-top: 1px; color: var(--red); }
.toast--success .toast__icon { color: #10B981; }
.toast--error .toast__icon { color: var(--red-600); }
.toast--warning .toast__icon { color: #F59E0B; }
.toast__content { flex: 1; line-height: 1.5; }
.toast__close { background: transparent; border: none; color: var(--slate-500); cursor: pointer; padding: 0; }
.toast.is-leaving { animation: toastOut var(--dur-base) var(--ease-out) forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateX(16px); } }
@keyframes toastOut { to { opacity: 0; transform: translateX(16px); } }

/* Forms */
.form-row { display: flex; flex-direction: column; gap: 16px; margin-bottom: 16px; }
@media (min-width: 640px) {
    .form-row--2col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
}
.form-field { position: relative; }
.form-field > label {
    display: block;
    font-family: var(--font-text);
    font-size: 13px;
    font-weight: 600;
    color: var(--navy-900);
    margin-bottom: 8px;
}
.form-field > label .required { color: var(--red-600); margin-left: 2px; }

.form-input, .form-textarea, .form-select {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    font-family: var(--font-text);
    font-size: 15px;
    color: var(--navy-900);
    background: var(--neu-inset-bg);
    border: 0;
    border-radius: 12px;
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light);
    transition: box-shadow var(--dur-fast) var(--ease-out);
}
.form-textarea { height: auto; min-height: 120px; padding: 14px 16px; resize: vertical; line-height: 1.55; }
.form-input::placeholder, .form-textarea::placeholder { color: var(--slate-500); }
.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: 0;
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 2px var(--red);
}
.form-input.is-invalid, .form-textarea.is-invalid, .form-select.is-invalid {
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 1.5px var(--red-600);
}
.form-input.is-valid, .form-textarea.is-valid, .form-select.is-valid {
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 1.5px #10B981;
}
.form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2364748B' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 44px;
    appearance: none;
    -webkit-appearance: none;
}
.form-help { font-size: 13px; color: var(--slate-500); margin-top: 6px; }
.form-error {
    display: flex; align-items: center; gap: 6px;
    font-size: 12.5px; color: var(--red-700);
    margin-top: 6px;
    opacity: 0; max-height: 0; overflow: hidden;
    transition: opacity var(--dur-fast) var(--ease-out), max-height var(--dur-fast) var(--ease-out);
}
.form-field.has-error .form-error { opacity: 1; max-height: 40px; }

.form-check { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; font-size: 14px; }
.form-check input[type="checkbox"] {
    appearance: none;
    width: 24px; height: 24px;
    border-radius: 7px;
    background: var(--neu-inset-bg);
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light);
    cursor: pointer;
    transition: all var(--dur-fast) var(--ease-out);
    flex-shrink: 0;
    margin-top: 1px;
    position: relative;
}
.form-check input[type="checkbox"]:checked {
    background: var(--red-600);
    box-shadow: none;
}
.form-check input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    top: 5px; left: 7px;
    width: 7px; height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Toggle switch — neumorphic */
.toggle { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; }
.toggle__track {
    position: relative;
    width: 56px; height: 32px;
    background: var(--neu-inset-bg);
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light);
    border-radius: 999px;
    transition: background var(--dur-base) var(--ease-out);
}
.toggle__track::after {
    content: '';
    position: absolute;
    top: 4px; left: 4px;
    width: 24px; height: 24px;
    background: var(--grey-50);
    border-radius: 50%;
    box-shadow: 2px 2px 6px var(--neu-dark), -2px -2px 6px var(--neu-light);
    transition: transform 260ms var(--ease-out), background var(--dur-base) var(--ease-out);
}
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle input:checked ~ .toggle__track {
    background: var(--red);
    box-shadow: inset 2px 2px 6px rgba(0,0,0,0.18);
}
.toggle input:checked ~ .toggle__track::after {
    transform: translateX(24px);
    background: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
    .reveal { opacity: 1; transform: none; }
}

/* Floating WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: calc(var(--mobile-nav-h) + 16px);
    right: 20px;
    width: 54px; height: 54px;
    border-radius: 50%;
    background: #25D366;
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 20px -4px rgba(37, 211, 102, 0.5);
    z-index: var(--z-float);
    transition: transform var(--dur-base) var(--ease-out);
}
.whatsapp-float:hover { transform: translateY(-3px); color: #fff; }
.whatsapp-float svg { width: 26px; height: 26px; }
@media (min-width: 768px) { .whatsapp-float { bottom: 24px; } }

/* Back to top */
.back-to-top {
    position: fixed;
    bottom: calc(var(--mobile-nav-h) + 88px);
    right: 20px;
    width: 44px; height: 44px;
    border-radius: 50%;
    background: var(--white);
    border: 1px solid var(--grey-300);
    color: var(--navy-900);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    opacity: 0; pointer-events: none;
    transform: translateY(8px);
    transition: all var(--dur-base) var(--ease-out);
    z-index: var(--z-float);
    box-shadow: var(--e1);
}
.back-to-top:hover { background: var(--navy-900); color: #fff; border-color: var(--navy-900); }
.back-to-top.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
@media (min-width: 768px) { .back-to-top { bottom: 94px; } }

/* Utilities */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-accent { color: var(--red-600); }
.text-muted { color: var(--slate-500); }
.text-dim { color: var(--slate-600); }
.d-flex { display: flex; }
.d-grid { display: grid; }
.flex-wrap { flex-wrap: wrap; }
.gap-2 { gap: 8px; } .gap-3 { gap: 12px; } .gap-4 { gap: 16px; } .gap-5 { gap: 20px; } .gap-6 { gap: 24px; }
.justify-center { justify-content: center; } .justify-between { justify-content: space-between; }
.align-center { align-items: center; }
.mt-6 { margin-top: 24px; } .mt-8 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; } .mb-6 { margin-bottom: 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--grey-300); border-radius: 100px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--slate-500); }

::selection { background: var(--red); color: #fff; }

/* ===== Custom select (theme dropdown) ===== */
.cs { position: relative; width: 100%; }
.cs--sm { width: auto; display: inline-block; }
.cs__native { position: absolute !important; inset: 0; width: 100%; height: 100%; opacity: 0; pointer-events: none; z-index: -1; }
.cs__trigger {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    width: 100%; height: 52px; padding: 0 14px 0 16px;
    font-family: var(--font-text); font-size: 15px; text-align: left;
    color: var(--navy-900);
    background: var(--neu-inset-bg);
    border: 0; border-radius: 12px; cursor: pointer;
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light);
    transition: box-shadow var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
    -webkit-tap-highlight-color: transparent;
}
.cs__trigger:hover { box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 1px var(--border-strong, #CBD5E1); }
.cs__trigger:focus-visible, .cs.is-open .cs__trigger {
    outline: 0;
    box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 2px var(--red);
}
.cs__trigger:disabled { opacity: .55; cursor: not-allowed; }
.cs.is-invalid .cs__trigger { box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 1.5px var(--red-600); }
.cs.is-valid .cs__trigger { box-shadow: inset 4px 4px 10px var(--neu-dark), inset -4px -4px 10px var(--neu-light), 0 0 0 1.5px #10B981; }
.cs__value { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs__value.is-placeholder { color: var(--slate-500); }
.cs__chev { display: inline-flex; color: var(--slate-500); transition: transform var(--dur-base, 240ms) var(--ease-out), color var(--dur-fast) var(--ease-out); }
.cs__chev svg { width: 16px; height: 16px; }
.cs.is-open .cs__chev { transform: rotate(180deg); color: var(--red); }

.cs--sm .cs__trigger { height: 34px; padding: 0 10px 0 12px; font-size: 12.5px; font-weight: 600; border-radius: 999px; gap: 8px; box-shadow: none; background: var(--grey-50, #F3F6F9); border: 1px solid var(--border, #E7EDF2); }
.cs--sm .cs__trigger:hover { border-color: var(--red); }
.cs--sm .cs__chev svg { width: 14px; height: 14px; }

.cs__panel {
    position: fixed; z-index: calc(var(--z-modal, 110) + 60);
    display: flex; flex-direction: column;
    max-width: calc(100vw - 16px);
    background: #FFFFFF; color: var(--navy-900, #0F1821);
    border: 1px solid var(--grey-100, #E7EDF2); border-radius: 14px;
    box-shadow: 0 18px 40px -12px rgba(15,24,33,.22), 0 4px 10px rgba(15,24,33,.06);
    padding: 6px; overflow: hidden;
    opacity: 0; visibility: hidden; pointer-events: none;
    transform: translateY(-6px) scale(.985); transform-origin: top center;
    transition: opacity 220ms var(--ease-out), transform 240ms var(--ease-out), visibility 0s linear 240ms;
}
.cs__panel--up { transform-origin: bottom center; transform: translateY(6px) scale(.985); }
.cs__panel.is-open { opacity: 1; visibility: visible; pointer-events: auto; transform: none; transition-delay: 0s; }
.cs__panel:focus { outline: 0; }
.cs__search {
    width: 100%; height: 40px; margin: 2px 0 6px; padding: 0 12px;
    font: inherit; font-size: 14px; color: inherit;
    background: var(--grey-50, #F3F6F9); border: 1px solid var(--grey-100, #E7EDF2); border-radius: 10px;
}
.cs__search:focus { outline: 0; border-color: var(--red); }
.cs__list { list-style: none; margin: 0; padding: 0; overflow-y: auto; overscroll-behavior: contain; scroll-behavior: smooth; scrollbar-width: thin; }
.cs__opt {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    min-height: 44px; padding: 10px 12px; border-radius: 10px;
    font-size: 14.5px; line-height: 1.35; cursor: pointer; position: relative;
    transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.cs__opt[hidden] { display: none; }
.cs__opt.is-active { background: rgba(255,0,66,.07); }
.cs__opt.is-selected { color: var(--red-600, #D6003A); font-weight: 600; background: rgba(255,0,66,.09); }
.cs__opt.is-selected::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--red); }
.cs__opt[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.cs__check { display: inline-flex; opacity: 0; transform: scale(.7); transition: opacity var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out); }
.cs__check svg { width: 16px; height: 16px; }
.cs__opt.is-selected .cs__check { opacity: 1; transform: none; }
.cs__empty { padding: 14px 12px; font-size: 13.5px; color: var(--slate-500); text-align: center; }

:root[data-theme="dark"] .cs__trigger { color: #FFFFFF; }
:root[data-theme="dark"] .cs--sm .cs__trigger { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.14); }
:root[data-theme="dark"] .cs__panel { background: #172533; color: #FFFFFF; border-color: rgba(255,255,255,.1); box-shadow: 0 24px 48px -16px rgba(0,0,0,.7); }
:root[data-theme="dark"] .cs__search { background: #0F1821; border-color: rgba(255,255,255,.1); }
:root[data-theme="dark"] .cs__opt.is-active { background: rgba(255,255,255,.06); }
:root[data-theme="dark"] .cs__opt.is-selected { color: #FF4D77; background: rgba(255,0,66,.14); }

@media (max-width: 767px) { .cs__opt { min-height: 48px; font-size: 15px; } }
@media (prefers-reduced-motion: reduce) { .cs__panel, .cs__chev, .cs__opt, .cs__check { transition-duration: 1ms; } .cs__list { scroll-behavior: auto; } }

/* Header is fixed so it stays frozen at the top while scrolling */
body:has(> .site-header) { padding-top: var(--header-h); }

/* ===== Extra motion ===== */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: calc(var(--z-nav, 100) + 5); background: var(--red); transform: scaleX(0); transform-origin: 0 50%; pointer-events: none; will-change: transform; }
.reveal--left  { transform: translateX(-28px); }
.reveal--right { transform: translateX(28px); }
.reveal--scale { transform: scale(.94); }
.reveal--left.is-visible, .reveal--right.is-visible, .reveal--scale.is-visible { transform: none; }
.reveal[style*="--i"]:not(.tech-item) { transition-delay: calc(var(--i, 0) * 70ms); }
.hero__panel { animation: hero-float 7s ease-in-out infinite; }
@keyframes hero-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.hero__visual { will-change: transform; }
.neu, .flagship-card, .live-card, .blog-card, .event-card, .stage-card, .layer-card { transition: transform 320ms var(--ease-out), box-shadow 320ms var(--ease-out); }
.neu:hover, .flagship-card:hover, .live-card:hover, .blog-card:hover, .event-card:hover, .stage-card:hover, .layer-card:hover { transform: translateY(-4px); }
@media (prefers-reduced-motion: reduce) {
    .hero__panel, .tech-grid::before { animation: none; }
    .scroll-progress { display: none; }
}
