/* Parallel 8 Studio: shared tokens and base components.
   Monochrome zinc ramp + one "on-air" accent. Radius system: pills for
   interactive elements, 16px for panels. Theme follows the OS setting. */

:root {
    --bg: #fafafa;
    --bg-sunk: #f1f1f3;
    --surface: #ffffff;
    --ink: #111113;
    --ink-2: #3f3f46;
    --ink-3: #6b6b74;
    --line: #e4e4e7;
    --line-strong: #d0d0d6;
    --accent: #c93a25;
    --accent-ink: #fff8f6;
    --accent-soft: #fbe9e5;
    --inv-bg: #111113;
    --inv-fg: #fafafa;
    --shadow: 0 1px 0 rgb(17 17 19 / .04), 0 18px 40px -24px rgb(17 17 19 / .18);

    --radius: 16px;
    --pill: 999px;
    --wrap: 1240px;
    --gutter: clamp(1rem, 4vw, 2.5rem);
    --ease: cubic-bezier(.16, 1, .3, 1);

    --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

    color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0c0c0e;
        --bg-sunk: #131316;
        --surface: #17171a;
        --ink: #ededef;
        --ink-2: #b4b4bc;
        --ink-3: #8a8a94;
        --line: #26262b;
        --line-strong: #34343a;
        --accent: #ff6a52;
        --accent-ink: #1a0906;
        --accent-soft: #2a1410;
        --inv-bg: #1c1c20;
        --inv-fg: #ededef;
        --shadow: 0 1px 0 rgb(255 255 255 / .03), 0 24px 48px -28px rgb(0 0 0 / .7);
    }
}

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

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

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--ink);
    line-height: 1.6;
    font-size: 1rem;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img,
svg {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

::selection {
    background: var(--accent);
    color: var(--accent-ink);
}

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

.wrap {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding-inline: var(--gutter);
}

.mono {
    font-family: var(--mono);
    font-feature-settings: "tnum";
}

/* ─── Type ─────────────────────────────────────────────── */

.display {
    font-size: clamp(2.5rem, 6.2vw, 4.75rem);
    font-weight: 600;
    letter-spacing: -0.045em;
    line-height: 1.02;
}

.h2 {
    font-size: clamp(2rem, 4.2vw, 3.25rem);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1.06;
}

.h3 {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.25;
}

.lede {
    font-size: clamp(1.05rem, 1.4vw, 1.2rem);
    color: var(--ink-2);
    line-height: 1.55;
    max-width: 46ch;
}

.body {
    color: var(--ink-2);
    max-width: 62ch;
}

.eyebrow {
    font-family: var(--mono);
    font-size: .75rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-3);
}

.accent {
    color: var(--accent);
}

/* ─── Buttons ──────────────────────────────────────────── */

.btn {
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    height: 48px;
    padding: 0 1.4rem;
    border-radius: var(--pill);
    font: 500 .95rem/1 var(--font);
    text-decoration: none;
    white-space: nowrap;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform .35s var(--ease), background-color .25s, border-color .25s, color .25s;
}

.btn:active {
    transform: scale(.98);
}

.btn i {
    font-size: 1.1rem;
    transition: transform .35s var(--ease);
}

.btn:hover i {
    transform: translateX(3px);
}

.btn-primary {
    background: var(--ink);
    color: var(--bg);
}

.btn-primary:hover {
    background: var(--accent);
    color: var(--accent-ink);
}

.btn-accent {
    background: var(--accent);
    color: var(--accent-ink);
}

.btn-accent:hover {
    background: var(--ink);
    color: var(--bg);
}

.btn-ghost {
    border-color: var(--line-strong);
    color: var(--ink);
}

.btn-ghost:hover {
    border-color: var(--ink);
}

.btn-sm {
    height: 40px;
    padding: 0 1.1rem;
    font-size: .875rem;
}

/* ─── Nav ──────────────────────────────────────────────── */

.nav {
    position: sticky;
    top: 0;
    z-index: 20;
    background: color-mix(in srgb, var(--bg) 82%, transparent);
    backdrop-filter: saturate(160%) blur(14px);
    -webkit-backdrop-filter: saturate(160%) blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color .3s;
}

.nav.is-stuck {
    border-bottom-color: var(--line);
}

.nav-inner {
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.nav-links a:not(.btn) {
    font-size: .9rem;
    color: var(--ink-2);
    text-decoration: none;
    transition: color .2s;
}

.nav-links a:not(.btn):hover {
    color: var(--ink);
}

.logo {
    display: flex;
    align-items: center;
    color: var(--ink);
    text-decoration: none;
}

.logo svg {
    height: 34px;
    width: auto;
}

/* Hamburger: site.js builds the button and panel from the .hide-sm links. */
.nav-toggle,
.nav-menu {
    display: none;
}

@media (max-width: 767px) {
    .nav-links .hide-sm {
        display: none;
    }

    .nav-links {
        gap: 1rem;
    }

    .nav-toggle {
        display: grid;
        place-items: center;
        width: 40px;
        height: 40px;
        margin-left: -.5rem;
        border: 1px solid var(--line);
        border-radius: var(--pill);
        background: var(--surface);
        color: var(--ink);
        cursor: pointer;
    }

    .nav-toggle span,
    .nav-toggle span::before,
    .nav-toggle span::after {
        display: block;
        width: 16px;
        height: 1.5px;
        border-radius: 2px;
        background: currentColor;
        transition: transform .3s var(--ease), background-color .2s;
    }

    .nav-toggle span {
        position: relative;
    }

    .nav-toggle span::before,
    .nav-toggle span::after {
        content: "";
        position: absolute;
        left: 0;
    }

    .nav-toggle span::before { transform: translateY(-5px); }
    .nav-toggle span::after { transform: translateY(5px); }
    .nav.is-open .nav-toggle span { background: transparent; }
    .nav.is-open .nav-toggle span::before { transform: rotate(45deg); }
    .nav.is-open .nav-toggle span::after { transform: rotate(-45deg); }

    .nav.is-open {
        border-bottom-color: var(--line);
        background: var(--bg);
    }

    .nav.is-open .nav-menu {
        display: block;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow);
        padding: .5rem var(--gutter) 1.25rem;
        list-style: none;
    }

    .nav-menu a {
        display: block;
        padding: .9rem 0;
        border-bottom: 1px solid var(--line);
        color: var(--ink);
        font-size: 1.05rem;
        text-decoration: none;
    }

    .nav-menu li:last-child a {
        border-bottom: 0;
    }
}

/* ─── Sections ─────────────────────────────────────────── */

.section {
    padding-block: clamp(4.5rem, 10vw, 8rem);
}

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* ─── Footer ───────────────────────────────────────────── */

.footer {
    border-top: 1px solid var(--line);
    padding-block: 2.5rem 3rem;
    color: var(--ink-3);
    font-size: .875rem;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

.footer a {
    text-decoration: none;
    color: var(--ink-2);
}

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

@media (min-width: 768px) {
    .footer-inner {
        grid-template-columns: 1fr auto auto;
        align-items: center;
        gap: 2.5rem;
    }
}

/* ─── Motion ───────────────────────────────────────────── */

/* Content is visible by default; JS opts in to reveals so nothing hides
   if scripts fail. */
.js .reveal {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity .9s var(--ease), transform .9s var(--ease);
    transition-delay: calc(var(--i, 0) * 80ms);
}

.js .reveal.is-in {
    opacity: 1;
    transform: none;
}

.rise {
    animation: rise 1s var(--ease) both;
    animation-delay: calc(var(--i, 0) * 90ms + 80ms);
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(18px);
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }

    .js .reveal {
        opacity: 1;
        transform: none;
    }
}
