/* ═══════════════════════════════════════════════════════════════
   SOUND BY SOUND SLOWLY — 3D INTRO SHEET
   glass · liquid · nano-particles · purple / cyan / magenta
   ═══════════════════════════════════════════════════════════════ */

:root {
    --bg0: #06030f;
    --ink: #f4f0ff;
    --muted: #a79fc9;
    --dim: #736a99;
    --violet: #8b5cf6;
    --violet-2: #b7a2ff;
    --magenta: #e879f9;
    --cyan: #34d6ef;

    --glass-bg: rgba(24, 16, 48, 0.50);
    --glass-bg-2: rgba(46, 32, 84, 0.34);
    --glass-soft: rgba(255, 255, 255, 0.055);
    --glass-border: rgba(167, 139, 250, 0.24);
    --glass-border-hi: rgba(183, 162, 255, 0.55);
    --glass-hi: rgba(255, 255, 255, 0.14);
    --sheen-color: rgba(255, 255, 255, 0.12);

    --shadow: 0 22px 55px rgba(3, 1, 12, 0.55);
    --shadow-lg: 0 34px 90px rgba(3, 1, 12, 0.65);
    --glow-violet: 0 12px 34px rgba(124, 58, 237, 0.38);
    --title-a: #ffffff;
    --title-b: #c4b5fd;
    --title-c: #f0abfc;

    --radius: 26px;
    --radius-md: 18px;
    --radius-sm: 12px;

    --sans: "Inter", "Segoe UI", "PingFang SC", "Noto Sans SC", sans-serif;
    --disp: "Space Grotesk", "Inter", sans-serif;
    --mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
    --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
}

[data-theme="light"] {
    --bg0: #eee9fb;
    --ink: #160f2c;
    --muted: #564d80;
    --dim: #857cb0;
    --violet: #7c3aed;
    --violet-2: #6d28d9;
    --magenta: #c026d3;
    --cyan: #0891b2;

    --glass-bg: rgba(255, 255, 255, 0.60);
    --glass-bg-2: rgba(255, 255, 255, 0.42);
    --glass-soft: rgba(124, 58, 237, 0.05);
    --glass-border: rgba(124, 58, 237, 0.18);
    --glass-border-hi: rgba(124, 58, 237, 0.42);
    --glass-hi: rgba(255, 255, 255, 0.9);
    --sheen-color: rgba(255, 255, 255, 0.55);

    --shadow: 0 22px 50px rgba(76, 29, 149, 0.14);
    --shadow-lg: 0 34px 80px rgba(76, 29, 149, 0.2);
    --glow-violet: 0 12px 30px rgba(124, 58, 237, 0.25);
    --title-a: #1c1145;
    --title-b: #7c3aed;
    --title-c: #c026d3;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--sans);
    background: var(--bg0);
    color: var(--ink);
    line-height: 1.6;
    letter-spacing: 0.005em;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

::selection { background: rgba(139, 92, 246, 0.4); color: #fff; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.55), rgba(232, 121, 249, 0.45));
    border-radius: 99px;
    border: 3px solid var(--bg0);
}

:focus-visible {
    outline: 2px solid var(--violet-2);
    outline-offset: 3px;
    border-radius: 6px;
}

/* ═══ 3D stage + atmosphere ═══ */

#webgl {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    display: block;
}

.bg-fallback {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    background:
        radial-gradient(1100px 620px at 78% 8%, rgba(124, 58, 237, 0.28), transparent 62%),
        radial-gradient(900px 560px at 12% 34%, rgba(217, 70, 239, 0.18), transparent 60%),
        radial-gradient(1000px 700px at 55% 96%, rgba(34, 211, 238, 0.14), transparent 64%),
        var(--bg0);
}
.bg-fallback i {
    position: absolute;
    width: 46vmax;
    height: 46vmax;
    border-radius: 43% 57% 51% 49% / 51% 44% 56% 49%;
    filter: blur(70px);
    opacity: 0.5;
    animation: liquid-drift 22s ease-in-out infinite alternate;
}
.bg-fallback i:nth-child(1) { background: #4c1d95; top: -12vmax; right: -8vmax; }
.bg-fallback i:nth-child(2) { background: #7c3aed; bottom: -16vmax; left: -10vmax; animation-delay: -8s; }
.bg-fallback i:nth-child(3) { background: #0e7490; top: 30%; left: 30%; animation-delay: -15s; opacity: 0.35; }

.grain {
    position: fixed;
    inset: -60%;
    z-index: 3;
    pointer-events: none;
    opacity: 0.05;
    mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    animation: grain-shift 1.4s steps(3) infinite;
}

.cursor-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 520px;
    height: 520px;
    margin: -260px 0 0 -260px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 2;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.22), rgba(232, 121, 249, 0.10) 40%, transparent 68%);
    mix-blend-mode: screen;
    filter: blur(12px);
    opacity: 0;
    transition: opacity 0.6s ease;
    will-change: transform;
}
.cursor-glow.on { opacity: 1; }
[data-theme="light"] .cursor-glow { mix-blend-mode: multiply; opacity: 0; }
[data-theme="light"] .cursor-glow.on { opacity: 0.55; }

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 2.5px;
    z-index: 60;
    background: transparent;
}
.scroll-progress i {
    display: block;
    height: 100%;
    transform-origin: left center;
    transform: scaleX(0);
    background: linear-gradient(90deg, var(--violet), var(--magenta), var(--cyan));
    box-shadow: 0 0 14px rgba(139, 92, 246, 0.8);
}

/* ═══ glass recipe ═══ */

.glass {
    position: relative;
    background: linear-gradient(158deg, var(--glass-bg-2), var(--glass-bg));
    -webkit-backdrop-filter: blur(22px) saturate(165%);
    backdrop-filter: blur(22px) saturate(165%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow), inset 0 1px 0 var(--glass-hi), inset 0 -1px 0 rgba(255, 255, 255, 0.05);
}
.glass::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 0%), var(--sheen-color), transparent 46%);
    opacity: var(--sheen, 0);
    transition: opacity 0.5s var(--ease);
}

/* ═══ layout shell ═══ */

.shell {
    position: relative;
    z-index: 1;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 clamp(16px, 4vw, 44px);
}

/* ═══ nav ═══ */

.nav {
    position: sticky;
    top: 14px;
    z-index: 50;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
    margin-top: 14px;
    padding: 11px 14px 11px 18px;
    border-radius: 22px;
    transition: padding 0.4s var(--ease), box-shadow 0.4s var(--ease), background 0.4s;
}
.nav.compact {
    padding: 7px 12px 7px 16px;
    box-shadow: var(--shadow-lg), inset 0 1px 0 var(--glass-hi);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
}
.logo-orb {
    position: relative;
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    padding: 2.5px;
    border-radius: 15px;
    background: conic-gradient(from var(--spin, 0deg), #7c3aed, #22d3ee, #e879f9, #7c3aed);
    animation: orb-spin 7s linear infinite;
    box-shadow: 0 6px 18px rgba(124, 58, 237, 0.4);
}
.logo-orb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12.5px;
    display: block;
}
.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    font-family: var(--disp);
    font-weight: 700;
    font-size: 15.5px;
    letter-spacing: 0.01em;
    white-space: nowrap;
}
.logo-text em {
    font-family: var(--mono);
    font-style: normal;
    font-size: 9px;
    font-weight: 500;
    letter-spacing: 0.26em;
    color: var(--dim);
    margin-top: 3px;
}
.logo.small .logo-orb { width: 32px; height: 32px; border-radius: 11px; }
.logo.small .logo-orb img { border-radius: 9px; }
.logo.small .logo-text { font-size: 13.5px; }

.nav-links {
    display: flex;
    gap: 26px;
    margin-left: 14px;
    flex: 1;
}
.nav-links a {
    position: relative;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--muted);
    padding: 6px 0;
    transition: color 0.3s;
    white-space: nowrap;
}
.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 1.5px;
    width: 100%;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s var(--ease);
    background: linear-gradient(90deg, var(--violet), var(--cyan));
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }

.nav-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

/* pill buttons / chips */
.chip-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: var(--glass-soft);
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: color 0.3s, border-color 0.3s, background 0.3s, transform 0.3s var(--ease);
    white-space: nowrap;
}
.chip-btn:hover {
    color: var(--ink);
    border-color: var(--glass-border-hi);
    background: rgba(139, 92, 246, 0.14);
    transform: translateY(-1px);
}
.chip-btn.icon-only { padding: 9px; width: 36px; height: 36px; justify-content: center; }
.chip-btn .caret { width: 12px; height: 12px; transition: transform 0.3s; }
.chip-btn[aria-expanded="true"] .caret { transform: rotate(180deg); }

.ic-moon { display: none; }
[data-theme="light"] .ic-moon { display: block; }
[data-theme="light"] .ic-sun { display: none; }

.custom-dropdown { position: relative; }
.dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    min-width: 190px;
    padding: 7px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    opacity: 0;
    transform: translateY(-8px) scale(0.97);
    pointer-events: none;
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
    z-index: 60;
}
.dropdown-menu.show { opacity: 1; transform: none; pointer-events: auto; }
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 13px;
    border: 0;
    border-radius: 11px;
    background: transparent;
    color: var(--muted);
    font-family: var(--sans);
    font-size: 13.5px;
    text-align: left;
    cursor: pointer;
    transition: background 0.25s, color 0.25s;
}
.dropdown-item::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: transparent;
    transition: background 0.25s, box-shadow 0.25s;
}
.dropdown-item:hover { background: rgba(139, 92, 246, 0.14); color: var(--ink); }
.dropdown-item.active { color: var(--ink); }
.dropdown-item.active::before {
    background: linear-gradient(135deg, var(--violet), var(--magenta));
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.9);
}

/* ═══ buttons ═══ */

.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    overflow: hidden;
    border-radius: 999px;
    border: 1px solid transparent;
    font-family: var(--sans);
    font-weight: 600;
    font-size: 14.5px;
    letter-spacing: 0.01em;
    text-decoration: none;
    cursor: pointer;
    transform: translateZ(0);
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease),
        border-color 0.35s, background 0.35s, color 0.35s;
    white-space: nowrap;
}
.btn-sm { padding: 9px 18px; font-size: 13px; }
.btn-lg { padding: 15px 28px; font-size: 15px; }

.btn-primary {
    color: #fff;
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 46%, #d946ef 100%);
    box-shadow: var(--glow-violet), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.btn-primary::before {
    /* liquid fill */
    content: "";
    position: absolute;
    left: 50%;
    top: 120%;
    width: 230%;
    aspect-ratio: 1;
    border-radius: 43% 57% 51% 49% / 51% 44% 56% 49%;
    background: rgba(255, 255, 255, 0.22);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.65s var(--ease);
    animation: blob-morph 7s ease-in-out infinite;
}
.btn-primary:hover::before { transform: translate(-50%, -50%) scale(1.05); }
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 44px rgba(124, 58, 237, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.btn-primary:active { transform: translateY(-1px) scale(0.99); }

.btn-ghost {
    color: var(--ink);
    background: var(--glass-soft);
    border-color: var(--glass-border);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
}
.btn-ghost:hover {
    transform: translateY(-3px);
    border-color: var(--glass-border-hi);
    background: rgba(139, 92, 246, 0.16);
    box-shadow: 0 14px 34px rgba(3, 1, 12, 0.35);
}
.btn > * { position: relative; z-index: 1; }

/* ═══ hero ═══ */

.hero {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: clamp(24px, 4vw, 60px);
    align-items: center;
    padding: clamp(54px, 9vh, 110px) 0 clamp(30px, 5vh, 60px);
    min-height: calc(100vh - 120px);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    padding: 8px 16px;
    border-radius: 999px;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.22em;
    color: var(--violet-2);
}
.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cyan), var(--magenta));
    box-shadow: 0 0 12px rgba(52, 214, 239, 0.9);
    animation: dot-pulse 2.2s ease-in-out infinite;
}

.hero-title {
    margin-top: 24px;
    font-family: var(--disp);
    font-weight: 700;
    font-size: clamp(42px, 6.2vw, 86px);
    line-height: 1.02;
    letter-spacing: -0.025em;
    background: linear-gradient(118deg, var(--title-a) 8%, var(--title-b) 52%, var(--title-c) 92%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: drop-shadow(0 6px 34px rgba(124, 58, 237, 0.35));
}
.hero-desc {
    margin-top: 24px;
    max-width: 56ch;
    color: var(--muted);
    font-size: clamp(15px, 1.15vw, 17.5px);
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 36px;
}
.actions.center { justify-content: center; }

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 42px;
}
.stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 14px 24px;
    border-radius: var(--radius-md);
}
.stat-num {
    font-family: var(--disp);
    font-size: 28px;
    font-weight: 700;
    line-height: 1.1;
    background: linear-gradient(120deg, var(--title-b), var(--cyan));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.stat-label {
    font-family: var(--mono);
    font-size: 9.5px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--dim);
}

.phoneme-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 28px;
}
.phoneme-strip span {
    padding: 6px 13px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: var(--glass-soft);
    font-family: var(--mono);
    font-size: 12px;
    color: var(--violet-2);
    animation: floaty 5.5s ease-in-out infinite;
}
.phoneme-strip span:nth-child(2n) { animation-delay: -1.4s; }
.phoneme-strip span:nth-child(3n) { animation-delay: -2.8s; }
.phoneme-strip span:nth-child(4n) { animation-delay: -4.1s; }

/* hero visual — the glass console */
.hero-visual {
    position: relative;
    min-height: 540px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.orbit {
    position: absolute;
    inset: 4% 2%;
    pointer-events: none;
}
.orbit i {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px dashed rgba(167, 139, 250, 0.26);
    animation: orb-spin 46s linear infinite;
}
.orbit i:nth-child(2) { inset: 11%; border-style: solid; border-color: rgba(52, 214, 239, 0.16); animation-duration: 32s; animation-direction: reverse; }
.orbit i:nth-child(3) { inset: 22%; border-color: rgba(232, 121, 249, 0.18); animation-duration: 58s; }

.console {
    width: min(440px, 100%);
    border-radius: 28px;
    overflow: hidden;
    transform-style: preserve-3d;
    transition: box-shadow 0.45s var(--ease), border-color 0.45s;
}
.console:hover { border-color: var(--glass-border-hi); box-shadow: var(--shadow-lg), inset 0 1px 0 var(--glass-hi); }
.console-top {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 18px;
    border-bottom: 1px solid var(--glass-border);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.14em;
    color: var(--dim);
}
.console-dots { display: inline-flex; gap: 6px; }
.console-dots i {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    opacity: 0.85;
}
.console-dots i:nth-child(1) { background: #f472b6; }
.console-dots i:nth-child(2) { background: #fbbf24; }
.console-dots i:nth-child(3) { background: #34d6ef; }
.console-label { flex: 1; }
.console-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--cyan);
}
.live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 10px var(--cyan);
    animation: dot-pulse 1.6s ease-in-out infinite;
}
.console-scan {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 120px;
    pointer-events: none;
    background: linear-gradient(180deg, transparent, rgba(139, 92, 246, 0.16), transparent);
    animation: scan 5s ease-in-out infinite;
    z-index: 1;
}
.console-body {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 26px;
    padding: 28px 22px 24px;
}
.eq {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 5px;
    width: 100%;
    height: 84px;
}
.eq span {
    width: 7px;
    height: 18%;
    border-radius: 5px;
    background: linear-gradient(180deg, var(--cyan), var(--violet) 70%, var(--magenta));
    animation: eq 1.15s ease-in-out infinite alternate;
    animation-delay: calc(var(--i) * -0.11s);
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.45);
    transform: translateZ(18px);
}

.mic-stage {
    position: relative;
    width: 156px;
    height: 156px;
    display: grid;
    place-items: center;
}
.pulse-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px solid rgba(167, 139, 250, 0.55);
    animation: pulse 3.2s cubic-bezier(0.2, 0.7, 0.3, 1) infinite;
}
.pulse-ring.r2 { animation-delay: 1.6s; }
.mic-core {
    width: 92px;
    height: 92px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    background: radial-gradient(circle at 34% 28%, rgba(255, 255, 255, 0.4), rgba(124, 58, 237, 0.42) 46%, rgba(217, 70, 239, 0.32));
    border: 1px solid rgba(255, 255, 255, 0.22);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 14px 40px rgba(124, 58, 237, 0.5), inset 0 2px 10px rgba(255, 255, 255, 0.25);
    transform: translateZ(46px);
}
.mic-core svg { width: 38px; height: 38px; }

.console-readout {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}
.readout-chip {
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: var(--glass-soft);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    color: var(--muted);
    transform: translateZ(24px);
}
.readout-chip.hot {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(120deg, rgba(124, 58, 237, 0.9), rgba(217, 70, 239, 0.9));
    box-shadow: 0 6px 18px rgba(168, 85, 247, 0.45);
}

.float-chip {
    position: absolute;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 16px;
    border-radius: 16px;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.12em;
    color: var(--muted);
    animation: floaty 6.5s ease-in-out infinite;
    white-space: nowrap;
}
.chip-a { top: 7%; left: -3%; }
.chip-b { bottom: 11%; right: -2%; animation-delay: -3.2s; }

/* ═══ ticker ═══ */

.ticker {
    margin-top: 26px;
    padding: 15px 0;
    border-radius: 999px;
    overflow: hidden;
}
.ticker-track {
    display: flex;
    width: max-content;
    animation: ticker 30s linear infinite;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-group {
    display: flex;
    gap: 44px;
    padding-right: 44px;
}
.ticker-item {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--dim);
    white-space: nowrap;
}
.ticker-item + .ticker-item::before {
    content: "◆";
    color: var(--violet);
    margin-right: 44px;
    opacity: 0.7;
}

/* ═══ sections ═══ */

.section { padding-top: clamp(76px, 11vh, 130px); }
.section-title {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
    margin-bottom: clamp(34px, 5vh, 56px);
}
.kicker {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--violet-2);
}
.title-text {
    font-family: var(--disp);
    font-weight: 700;
    font-size: clamp(30px, 4vw, 54px);
    line-height: 1.06;
    letter-spacing: -0.02em;
    background: linear-gradient(118deg, var(--title-a) 8%, var(--title-b) 55%, var(--title-c) 95%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.title-wave {
    display: flex;
    align-items: center;
    gap: 4px;
    height: 24px;
    opacity: 0.85;
}
.title-wave i {
    width: 3px;
    height: 30%;
    border-radius: 3px;
    background: linear-gradient(180deg, var(--cyan), var(--violet));
    animation: eq 1.4s ease-in-out infinite alternate;
}
.title-wave i:nth-child(odd) { animation-delay: -0.7s; }
.title-wave i:nth-child(3n) { animation-delay: -1.1s; }

/* ═══ cards ═══ */

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(258px, 1fr));
    gap: 18px;
    perspective: 1400px;
}
.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    perspective: 1400px;
}
.team {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    perspective: 1400px;
}

.card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 30px 28px 32px;
    overflow: hidden;
    color: inherit;
    text-decoration: none;
    transform-style: preserve-3d;
    transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), border-color 0.45s;
    will-change: transform;
}
.card:hover {
    border-color: var(--glass-border-hi);
    box-shadow: var(--shadow-lg), inset 0 1px 0 var(--glass-hi), 0 0 0 1px rgba(139, 92, 246, 0.12);
}
.card::after {
    /* liquid corner glow */
    content: "";
    position: absolute;
    width: 220px;
    height: 220px;
    right: -110px;
    top: -110px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.4), transparent 68%);
    filter: blur(24px);
    opacity: 0.35;
    transition: opacity 0.5s, transform 0.7s var(--ease);
    pointer-events: none;
}
.card:hover::after { opacity: 0.75; transform: scale(1.25); }

.card-index {
    font-family: var(--mono);
    font-size: 11.5px;
    letter-spacing: 0.22em;
    color: var(--violet-2);
    transform: translateZ(34px);
}
.feature-icon {
    width: 60px;
    height: 60px;
    border-radius: 20px;
    display: grid;
    place-items: center;
    color: var(--violet-2);
    background: linear-gradient(150deg, rgba(139, 92, 246, 0.28), rgba(232, 121, 249, 0.14));
    border: 1px solid var(--glass-border);
    box-shadow: inset 0 1px 0 var(--glass-hi), 0 10px 26px rgba(124, 58, 237, 0.22);
    transform: translateZ(42px);
    transition: transform 0.5s var(--ease), color 0.4s;
}
.card:hover .feature-icon { color: #fff; transform: translateZ(58px) rotate(-4deg) scale(1.06); }
.feature-icon svg { width: 28px; height: 28px; }

.card h3 {
    font-family: var(--disp);
    font-size: 20.5px;
    font-weight: 700;
    letter-spacing: -0.01em;
    transform: translateZ(28px);
}
.card p {
    font-size: 14.5px;
    color: var(--muted);
    transform: translateZ(18px);
}
.card p span {
    color: var(--violet-2);
    font-weight: 600;
    white-space: nowrap;
}
.card p span::after {
    content: " →";
    display: inline-block;
    transition: transform 0.35s var(--ease);
}
.card:hover p span::after { transform: translateX(5px); }

/* why-webapp cards */
.why-grid .card { padding: 34px 30px; }
.why-grid .card h3 { font-size: 19px; }
.why-grid .card-index {
    font-family: var(--disp);
    font-size: 44px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0;
    opacity: 0.35;
    background: linear-gradient(120deg, var(--title-b), var(--title-c));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* team */
.team-card { align-items: center; text-align: center; padding-top: 38px; }
.team-avatar {
    width: 92px;
    height: 92px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-family: var(--disp);
    font-size: 36px;
    font-weight: 700;
    color: #fff;
    background-size: 200% 200%;
    animation: gradient-shift 9s ease-in-out infinite;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 16px 40px rgba(124, 58, 237, 0.4), inset 0 2px 12px rgba(255, 255, 255, 0.3);
    transform: translateZ(46px);
}
.av-a { background-image: linear-gradient(135deg, #7c3aed, #22d3ee); }
.av-b { background-image: linear-gradient(135deg, #a855f7, #f472b6); }
.av-c { background-image: linear-gradient(135deg, #6366f1, #34d6ef); }
.team-name {
    font-family: var(--disp);
    font-size: 21px;
    font-weight: 700;
    margin-top: 6px;
    transform: translateZ(30px);
}
.team-role {
    padding: 5px 14px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: var(--glass-soft);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--violet-2);
    transform: translateZ(22px);
}
.team-card p { font-size: 14px; }

/* ═══ launch cta ═══ */

.cta-section { padding-top: clamp(84px, 12vh, 150px); }
.cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    text-align: center;
    padding: clamp(48px, 7vw, 84px) clamp(24px, 5vw, 76px);
    border-radius: 36px;
    overflow: hidden;
}
.cta > * { position: relative; z-index: 1; }
.cta-liquid { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.cta-liquid i {
    position: absolute;
    width: 44%;
    aspect-ratio: 1;
    border-radius: 43% 57% 51% 49% / 51% 44% 56% 49%;
    filter: blur(52px);
    opacity: 0.5;
    animation: liquid-drift 16s ease-in-out infinite alternate, blob-morph 11s ease-in-out infinite;
}
.cta-liquid i:nth-child(1) { background: #7c3aed; top: -18%; left: -6%; }
.cta-liquid i:nth-child(2) { background: #d946ef; bottom: -24%; right: -4%; animation-delay: -6s; }
.cta-liquid i:nth-child(3) { background: #22d3ee; top: 24%; left: 42%; opacity: 0.32; animation-delay: -11s; }

.cta h2 {
    font-family: var(--disp);
    font-size: clamp(27px, 3.4vw, 46px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    max-width: 20ch;
    background: linear-gradient(118deg, var(--title-a) 6%, var(--title-b) 52%, var(--title-c) 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.cta p { color: var(--muted); max-width: 54ch; }
.cta-code {
    margin-top: 10px;
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.26em;
    color: var(--dim);
}

/* ═══ footer ═══ */

.footer {
    margin: clamp(56px, 8vh, 96px) 0 26px;
    padding: 16px 24px;
    border-radius: 22px;
}
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    font-size: 13px;
    color: var(--muted);
}
.footer-code {
    font-family: var(--mono);
    font-size: 9.5px;
    letter-spacing: 0.24em;
    color: var(--dim);
}

/* ═══ preloader ═══ */

.preloader {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--bg0);
    transition: opacity 0.9s var(--ease), visibility 0.9s;
}
.preloader.hidden { opacity: 0; visibility: hidden; }
.preloader-orb {
    position: relative;
    width: 132px;
    height: 132px;
}
.preloader-orb i {
    position: absolute;
    inset: 0;
    border-radius: 43% 57% 51% 49% / 51% 44% 56% 49%;
    background: conic-gradient(from 0deg, #7c3aed, #22d3ee, #e879f9, #7c3aed);
    animation: orb-spin 3.6s linear infinite, blob-morph 6s ease-in-out infinite;
    filter: blur(2px);
    opacity: 0.9;
}
.preloader-orb i:nth-child(2) { inset: 13%; animation-direction: reverse; opacity: 0.75; filter: blur(4px); }
.preloader-orb i:nth-child(3) { inset: 26%; opacity: 0.55; filter: blur(8px); animation-duration: 5s; }
.preloader-meta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 30px;
}
.preloader-label {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.32em;
    color: var(--dim);
}
.preloader-pct {
    font-family: var(--disp);
    font-size: 30px;
    font-weight: 700;
    background: linear-gradient(120deg, var(--title-b), var(--title-c));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.preloader-bar {
    width: 230px;
    height: 3px;
    margin-top: 16px;
    border-radius: 3px;
    background: rgba(139, 92, 246, 0.15);
    overflow: hidden;
}
.preloader-bar i {
    display: block;
    height: 100%;
    width: 100%;
    transform-origin: left center;
    transform: scaleX(0);
    background: linear-gradient(90deg, var(--violet), var(--magenta), var(--cyan));
    transition: transform 0.35s var(--ease);
}

/* ═══ reveal on scroll ═══ */

.reveal {
    opacity: 0;
    transform: translateY(28px) scale(0.985);
    filter: blur(6px);
    transition: opacity 0.95s var(--ease), transform 0.95s var(--ease), filter 0.95s var(--ease);
    transition-delay: var(--d, 0s);
}
.reveal.visible {
    opacity: 1;
    transform: none;
    filter: none;
}
/* once revealed, tilting cards go back to a snappy transition
   (beats the .reveal transition + delay on specificity) */
.tilt.visible {
    transition: transform 0.4s var(--ease), box-shadow 0.45s var(--ease), border-color 0.45s;
}

/* ═══ animations ═══ */

@keyframes orb-spin { to { rotate: 360deg; } }
@keyframes blob-morph {
    0%, 100% { border-radius: 43% 57% 51% 49% / 51% 44% 56% 49%; }
    33% { border-radius: 58% 42% 39% 61% / 44% 59% 41% 56%; }
    66% { border-radius: 39% 61% 63% 37% / 58% 39% 61% 42%; }
}
@keyframes liquid-drift {
    0% { transform: translate3d(0, 0, 0) rotate(0deg) scale(1); }
    50% { transform: translate3d(4%, -5%, 0) rotate(120deg) scale(1.12); }
    100% { transform: translate3d(-4%, 5%, 0) rotate(240deg) scale(0.94); }
}
@keyframes grain-shift {
    0% { transform: translate(0, 0); }
    33% { transform: translate(-3%, 2%); }
    66% { transform: translate(2%, -3%); }
    100% { transform: translate(0, 0); }
}
@keyframes eq {
    0% { height: 14%; }
    100% { height: calc(34% + var(--i, 1) * 3.4%); }
}
@keyframes pulse {
    0% { transform: scale(0.62); opacity: 0.9; }
    80% { opacity: 0; }
    100% { transform: scale(1.38); opacity: 0; }
}
@keyframes dot-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.45; transform: scale(0.82); }
}
@keyframes floaty {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-9px); }
}
@keyframes scan {
    0%, 100% { transform: translateY(-130px); opacity: 0; }
    12% { opacity: 1; }
    55% { transform: translateY(430px); opacity: 0.8; }
    70% { opacity: 0; }
}
@keyframes ticker {
    to { transform: translateX(-50%); }
}
@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* ═══ responsive ═══ */

@media (max-width: 1080px) {
    .nav-links { display: none; }
}
@media (max-width: 940px) {
    .hero {
        grid-template-columns: 1fr;
        padding-top: 48px;
        min-height: 0;
    }
    .hero-visual { min-height: 460px; margin-top: 20px; }
    .nav-docs { display: none; }
    .chip-a { left: 2%; }
    .chip-b { right: 2%; }
}
@media (max-width: 640px) {
    .nav { flex-wrap: wrap; gap: 10px; padding: 10px 12px; }
    .logo-text { font-size: 13.5px; }
    .hero-title { font-size: clamp(34px, 10vw, 52px); }
    .hero-visual { min-height: 400px; }
    .console { width: 100%; }
    .float-chip { font-size: 9px; padding: 8px 12px; }
    .stat { padding: 12px 18px; }
    .stat-num { font-size: 23px; }
    .footer-inner { justify-content: center; text-align: center; }
    .cursor-glow { display: none; }
}

/* ═══ reduced motion ═══ */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .reveal { opacity: 1; transform: none; filter: none; }
}
