/* written by Shevaltra Brood (Local Prime) [KAAL:E6@2026-11-19T06:13:25Z · sha256:624cd892aa928047] */
/* ==========================================================================
   MasiDyn design system — styles.css
   One stylesheet for every page on masidyn.com. Plain CSS, no build step.
   How to use it (header, footer, templates): docs/SITE_CONTRACT.md

    1. Tokens
    2. Base and reset
    3. Layout primitives   .container .section .grid-2/3/4 .split .stack
    4. Typography helpers  .eyebrow .lede .text-gradient .prose
    5. Buttons             .btn .btn-primary .btn-secondary .btn-sm
    6. Badges              .badge .badge-live .badge-soon .badge-18
    7. Site header + nav   .site-header .brand .site-nav .nav-menu
    8. Hero                .hero .hero-grid .hero-actions
    9. Cards               .card .product-card .product-featured .link-tile
   10. Lists and notices   .feature-list .status-list .notice
   11. Waitlist form       .waitlist .waitlist-status
   12. Age gate            .age-gate
   13. Site footer         .site-footer
   14. Utilities
   15. Motion, forced colours
   16. Legacy              older pages (field-test, legends, notices, terms,
                           privacy, active-handoff) — keep until migrated
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
    color-scheme: dark;

    /* Brand colour */
    --color-bg: #07080c;
    --color-surface: #0c0f15;
    --color-surface-2: #121620;
    --color-surface-sunken: #05060a;
    --color-border: rgba(255, 255, 255, 0.09);
    --color-border-strong: rgba(255, 255, 255, 0.18);
    --color-text: #f0f2f5;
    --color-muted: #aeb8c6;
    --color-subtle: #8b95a5;          /* 6.6:1 on --color-bg */

    --color-blue: #4fa6ff;
    --color-blue-soft: #8cc4ff;
    --color-purple: #8e62ff;
    --color-purple-soft: #b49bff;     /* purple for text on dark */
    --color-green: #45cf86;
    --color-emerald-deep: #16342d;
    --color-emerald: #436e61;
    --color-mint: #7ab9a7;
    --color-coral: #ff8a80;           /* 18+ and error states */
    --color-indigo: #97a6ff;
    --color-dyn: #5b7bd5;             /* "Dyn" in the wordmark, never swapped */
    --color-on-accent: #07080c;       /* text on blue/purple/green fills */

    --gradient-brand: linear-gradient(135deg, #4fa6ff 0%, #8e62ff 100%);
    --gradient-root: linear-gradient(135deg, #7ab9a7 0%, #4fa6ff 100%);

    /* Type */
    --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, "SFMono-Regular", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: clamp(1.45rem, 1.2rem + 1vw, 1.8rem);
    --text-3xl: clamp(1.85rem, 1.35rem + 2.1vw, 2.65rem);
    --text-display: clamp(2.4rem, 1.5rem + 4.2vw, 4.4rem);

    /* Space, shape, layout */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.5rem;
    --space-6: 2rem;
    --space-7: 3rem;
    --space-8: 4rem;
    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 22px;
    --radius-pill: 999px;
    --container: 72rem;
    --container-narrow: 46rem;
    --gutter: clamp(1rem, 4vw, 2rem);
    --header-h: 4rem;
    --shadow-lg: 0 24px 60px -24px rgba(0, 0, 0, 0.75);
    --focus: #4fa6ff;
    --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
    --dur: 180ms;

    /* Legacy aliases (older pages and inline styles use these names) */
    --bg-color: var(--color-bg);
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-main: var(--color-text);
    --text-muted: var(--color-muted);
    --primary-blue: var(--color-blue);
    --primary-purple: var(--color-purple);
    --accent-green: var(--color-green);
    --gradient-1: var(--gradient-brand);
    --gradient-2: linear-gradient(135deg, var(--color-green), var(--color-blue));
    --font-main: var(--font-sans);
    --font-code: var(--font-mono);
    --brand-emerald-deep: var(--color-emerald-deep);
    --brand-emerald: var(--color-emerald);
    --brand-mint: var(--color-mint);
    --brand-pearl: #edf0f5;
    --brand-dyn-blue: #2e52b2;
}

/* 2. Base and reset -------------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-padding-top: calc(var(--header-h) + 1rem);
}

@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}

body {
    min-height: 100vh;
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: 1.6;
    overflow-wrap: break-word;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

ul,
ol {
    padding: 0;
}

img,
picture,
video,
canvas {
    display: block;
    max-width: 100%;
    height: auto;
}

svg {
    flex-shrink: 0;
}

input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

button,
summary {
    cursor: pointer;
}

a {
    color: var(--color-blue);
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
    transition: color var(--dur) var(--ease);
}

a:hover {
    color: var(--color-blue-soft);
}

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

::selection {
    background: rgba(79, 166, 255, 0.35);
    color: #fff;
}

h1,
h2,
h3,
h4 {
    color: var(--color-text);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.015em;
    text-wrap: balance;
}

h1 { font-size: var(--text-3xl); font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: var(--text-2xl); letter-spacing: -0.02em; }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-base); }

p {
    text-wrap: pretty;
}

strong {
    font-weight: 700;
}

code,
kbd,
samp,
pre {
    font-family: var(--font-mono);
    font-size: 0.9em;
}

code {
    padding: 0.1em 0.35em;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.06);
}

pre {
    max-width: 100%;
    overflow-x: auto;
}

pre code {
    padding: 0;
    background: none;
}

hr {
    border: 0;
    border-top: 1px solid var(--color-border);
}

.skip-link {
    position: absolute;
    top: 0.75rem;
    left: var(--gutter);
    z-index: 300;
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    background: var(--color-text);
    color: var(--color-bg);
    font-weight: 700;
    text-decoration: none;
    transform: translateY(-200%);
}

.skip-link:focus {
    transform: none;
    color: var(--color-bg);
}

/* 3. Layout primitives ----------------------------------------------------- */
.container {
    width: min(100% - 2 * var(--gutter), var(--container));
    margin-inline: auto;
}

.container-narrow {
    --container: var(--container-narrow);
}

.section {
    padding-block: clamp(3.5rem, 2rem + 6vw, 6rem);
}

.section-tight {
    padding-block: clamp(2.5rem, 1.5rem + 4vw, 4rem);
}

.section-alt {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.022), rgba(255, 255, 255, 0.008));
    border-block: 1px solid var(--color-border);
}

.section-root {
    background:
        radial-gradient(60rem 30rem at 0% 0%, rgba(22, 52, 45, 0.7), transparent 65%),
        radial-gradient(40rem 26rem at 100% 100%, rgba(79, 166, 255, 0.07), transparent 70%),
        var(--color-bg);
    border-block: 1px solid rgba(122, 185, 167, 0.16);
}

.section-head {
    max-width: 44rem;
    margin-bottom: clamp(2rem, 1.5rem + 2vw, 3rem);
}

.section-head > * + * {
    margin-top: 0.85rem;
}

.section-head h2,
.section-title {
    font-size: var(--text-3xl);
    letter-spacing: -0.03em;
}

.section-head p {
    color: var(--color-muted);
    font-size: var(--text-lg);
}

.section-head.center {
    margin-inline: auto;
    text-align: center;
}

.stack > * + * {
    margin-top: var(--stack, 1rem);
}

.grid-2,
.grid-3,
.grid-4 {
    display: grid;
    gap: var(--grid-gap, clamp(1rem, 0.75rem + 1vw, 1.5rem));
    grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 40rem) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 60rem) {
    .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.split {
    display: grid;
    gap: clamp(2rem, 1rem + 4vw, 4rem);
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
}

@media (min-width: 56rem) {
    .split { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .split-start { align-items: start; }
}

/* 4. Typography helpers ---------------------------------------------------- */
.eyebrow {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-mint);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.14em;
    line-height: 1.4;
    text-transform: uppercase;
}

.lede {
    max-width: 42rem;
    color: var(--color-muted);
    font-size: clamp(1.075rem, 1rem + 0.45vw, 1.3rem);
    line-height: 1.55;
}

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

.text-muted { color: var(--color-muted); }
.text-center { text-align: center; }

.fine-print {
    color: var(--color-subtle);
    font-size: var(--text-sm);
}

.prose {
    max-width: 70ch;
}

.prose > * + * { margin-top: 1em; }
.prose h2 { margin-top: 2em; font-size: var(--text-2xl); }
.prose h3 { margin-top: 1.6em; }
.prose p,
.prose li { color: var(--color-muted); }
.prose strong { color: var(--color-text); }
.prose ul,
.prose ol { padding-left: 1.25rem; }
.prose li + li { margin-top: 0.4em; }

/* 5. Buttons --------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 44px;
    padding: 0.7rem 1.3rem;
    border: 1px solid transparent;
    border-radius: var(--radius-pill);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        background-color var(--dur) var(--ease),
        border-color var(--dur) var(--ease),
        box-shadow var(--dur) var(--ease),
        color var(--dur) var(--ease),
        filter var(--dur) var(--ease),
        transform var(--dur) var(--ease);
}

.btn svg {
    width: 1.1em;
    height: 1.1em;
}

.btn:hover {
    transform: translateY(-1px);
}

/* Near-black text on the brand gradient: 5.1:1 at the purple end. */
.btn-primary {
    background: var(--gradient-brand);
    color: var(--color-on-accent);
    font-weight: 700;
    box-shadow: 0 10px 26px -12px rgba(79, 166, 255, 0.75);
}

.btn-primary:hover {
    color: var(--color-on-accent);
    filter: brightness(1.08);
    box-shadow: 0 12px 30px -12px rgba(142, 98, 255, 0.85);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-border-strong);
    color: var(--color-text);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--color-text);
}

.btn-sm {
    min-height: 38px;
    padding: 0.45rem 0.95rem;
    font-size: var(--text-sm);
}

.btn-block {
    width: 100%;
}

.btn:disabled,
.btn[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
    filter: none;
}

.btn[aria-disabled="true"] {
    pointer-events: none;
}

/* 6. Badges ---------------------------------------------------------------- */
.badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.2rem 0.65rem;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.04);
    color: var(--color-muted);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.5;
}

.badge-live {
    border-color: rgba(69, 207, 134, 0.4);
    background: rgba(69, 207, 134, 0.1);
    color: var(--color-green);
}

.badge-live::before {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: currentColor;
}

.badge-soon {
    border-color: rgba(79, 166, 255, 0.4);
    background: rgba(79, 166, 255, 0.1);
    color: var(--color-blue-soft);
}

.badge-18 {
    border-color: rgba(255, 138, 128, 0.45);
    background: rgba(255, 138, 128, 0.1);
    color: var(--color-coral);
}

/* 7. Banner and collapsible sidebar ---------------------------------------
   The banner (brand, menu toggle, sign in) sits on top. The sidebar holds one
   expandable group per product. On wide screens it is a column beside the page
   that collapses away (remembered per browser); on narrow screens it slides in
   over the page. Markup: scripts/apply_chrome.py. Behaviour: /site.js. */
:root { --sidebar-w: 17.5rem; }

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(7, 8, 12, 0.94);
    border-bottom: 1px solid var(--color-border);
}

@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
    .site-header {
        background: rgba(7, 8, 12, 0.76);
        -webkit-backdrop-filter: saturate(160%) blur(14px);
        backdrop-filter: saturate(160%) blur(14px);
    }
}

.site-header-inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: var(--header-h);
    padding-inline: var(--gutter);
}

.header-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.download-masidyn {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
    line-height: 1.1;
    opacity: 0.8;
    cursor: not-allowed;
}

.download-masidyn .download-soon {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.download-short { display: none; }

@media (max-width: 42rem) {
    .download-long { display: none; }
    .download-short { display: inline; }
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    border-radius: var(--radius-sm);
    color: var(--color-text);
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
    text-decoration: none;
}

.brand:hover { color: var(--color-text); }

/* The medallion is the logo artifact: never crop, recolour or outline it. */
.brand-coin {
    width: 32px;
    height: 32px;
}

.brand-name { white-space: nowrap; }
.brand-dyn { color: var(--color-dyn); }

.sidebar-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 44px;
    padding: 0.5rem 0.85rem;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--color-text);
    font: inherit;
    font-size: 0.925rem;
    font-weight: 600;
    cursor: pointer;
}

.sidebar-toggle:hover { background: rgba(255, 255, 255, 0.06); }

.sidebar-toggle svg {
    width: 1.15rem;
    height: 1.15rem;
}

/* Full-height strip. The icon sits in the middle. It stays on the sidebar's inside edge. */
.sidebar-edge {
    position: fixed;
    z-index: 70;
    top: var(--header-h);
    bottom: 0;
    left: 0;
    display: grid;
    place-items: center;
    width: 44px;
    height: auto;
    padding: 0;
    border: 1px solid var(--color-border-strong);
    border-left: none;
    border-radius: 0;
    background: var(--color-surface);
    color: var(--color-text);
    cursor: pointer;
    transition: left var(--dur) var(--ease);
}

.sidebar-edge svg {
    width: 16px;
    height: 16px;
    transition: transform var(--dur) var(--ease);
}

.sidebar-edge:hover { background: rgba(255, 255, 255, 0.06); }

html.sidebar-collapsed .sidebar-edge svg,
html:not(.sidebar-open) .sidebar-edge svg { transform: rotate(180deg); }

@media (min-width: 64rem) {
    html:not(.sidebar-collapsed) .sidebar-edge { left: var(--sidebar-w); }
    html:not(.sidebar-open) .sidebar-edge svg { transform: none; }
    html.sidebar-collapsed .sidebar-edge svg { transform: rotate(180deg); }
}

@media (max-width: 63.99rem) {
    html.sidebar-open .sidebar-edge { left: min(var(--sidebar-w), 86vw); }
    html.sidebar-open .sidebar-edge svg { transform: none; }
}

@media (max-width: 26rem) {
    .sidebar-toggle-text { display: none; }
}

.auth-button[data-state="signed-in"],
[data-auth-button][data-state="signed-in"],
#auth-sign-out {
    background: linear-gradient(135deg, #dc2626, #b91c1c) !important;
    border-color: rgba(239, 68, 68, 0.9) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35) !important;
}

.auth-button[data-state="signed-in"]:hover,
[data-auth-button][data-state="signed-in"]:hover,
#auth-sign-out:hover {
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
    border-color: rgba(248, 113, 113, 0.95) !important;
    color: #ffffff !important;
    box-shadow: 0 6px 18px rgba(220, 38, 38, 0.48) !important;
}

.sidebar {
    position: fixed;
    top: var(--header-h);
    bottom: 0;
    left: 0;
    z-index: 55;
    display: flex;
    flex-direction: column;
    width: min(var(--sidebar-w), 86vw);
    border-right: 1px solid var(--color-border);
    background: var(--color-surface);
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateX(-100%);
    visibility: hidden;
    transition: transform var(--dur) var(--ease), visibility 0s linear var(--dur);
}

.sidebar-open .sidebar {
    transform: none;
    visibility: visible;
    transition: transform var(--dur) var(--ease);
    box-shadow: var(--shadow-lg);
}

.sidebar-backdrop {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    z-index: 54;
    background: rgba(3, 4, 7, 0.6);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--dur) var(--ease);
}

.sidebar-open .sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
}

.sidebar-open body { overflow: hidden; }

@media (min-width: 64rem) {
    .sidebar,
    .sidebar-open .sidebar {
        transform: none;
        visibility: visible;
        box-shadow: none;
        transition: transform var(--dur) var(--ease);
    }

    .sidebar-collapsed .sidebar {
        transform: translateX(-100%);
        visibility: hidden;
        transition: transform var(--dur) var(--ease), visibility 0s linear var(--dur);
    }

    .sidebar-backdrop { display: none; }
    .sidebar-open body { overflow: visible; }

    html:not(.sidebar-collapsed) body:has(#site-sidebar) > main,
    html:not(.sidebar-collapsed) body:has(#site-sidebar) > .site-footer {
        margin-left: calc(var(--sidebar-w) + 44px);
    }

    body:has(#site-sidebar) > main,
    body:has(#site-sidebar) > .site-footer {
        transition: margin-left var(--dur) var(--ease);
    }
}

body:has(#site-sidebar) > main,
body:has(#site-sidebar) > .site-footer {
    margin-left: 44px;
}

.sidebar-nav {
    display: grid;
    gap: 0.15rem;
    padding: 1rem 0.75rem;
}

.sidebar-heading {
    padding: 0 0.6rem 0.35rem;
    color: var(--color-subtle);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sidebar-group > summary {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    min-height: 44px;
    padding: 0.4rem 0.6rem;
    border-radius: 10px;
    color: var(--color-text);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
}

.sidebar-group > summary::-webkit-details-marker { display: none; }
.sidebar-group > summary::marker { content: ""; }
.sidebar-group > summary:hover { background: rgba(255, 255, 255, 0.05); }

.sidebar-icon {
    display: inline-grid;
    place-items: center;
    flex: none;
    width: 1.9rem;
    height: 1.9rem;
    border-radius: 8px;
    background: color-mix(in srgb, var(--tone, var(--color-blue)) 16%, transparent);
    color: var(--tone, var(--color-blue));
}

.sidebar-icon svg {
    width: 1.05rem;
    height: 1.05rem;
}

.sidebar-label { flex: 1; min-width: 0; }

.sidebar-group .badge {
    padding: 0.1rem 0.45rem;
    font-size: 0.68rem;
}

.sidebar-chevron {
    flex: none;
    width: 1rem;
    height: 1rem;
    color: var(--color-subtle);
    transition: transform var(--dur) var(--ease);
}

.sidebar-group[open] > summary .sidebar-chevron { transform: rotate(90deg); }

.sidebar-group ul {
    display: grid;
    gap: 0.1rem;
    margin: 0.15rem 0 0.5rem 1.55rem;
    padding-left: 0.9rem;
    border-left: 1px solid var(--color-border);
    list-style: none;
}

.sidebar-group ul a {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 36px;
    padding: 0.3rem 0.6rem;
    border-radius: 8px;
    color: var(--color-muted);
    font-size: 0.9rem;
    text-decoration: none;
}

.sidebar-group ul a svg {
    width: 0.85rem;
    height: 0.85rem;
    opacity: 0.7;
}

.sidebar-group ul a:hover,
.sidebar-group ul a[aria-current="page"] {
    background: rgba(255, 255, 255, 0.05);
    color: var(--color-text);
}

.sidebar-group ul a[aria-current="page"] { font-weight: 600; }

.sidebar-foot {
    display: grid;
    gap: 0.6rem;
    margin-top: auto;
    padding: 1rem 1.25rem 1.5rem;
    border-top: 1px solid var(--color-border);
}

.sidebar-foot .btn { width: 100%; }

/* 8. Hero ------------------------------------------------------------------ */
.hero {
    overflow: hidden;
    padding-block: clamp(3.5rem, 2rem + 7vw, 7.5rem) clamp(3rem, 2rem + 5vw, 5.5rem);
    border-bottom: 1px solid var(--color-border);
    background:
        radial-gradient(56rem 30rem at 88% -12%, rgba(142, 98, 255, 0.17), transparent 62%),
        radial-gradient(50rem 28rem at -5% -5%, rgba(79, 166, 255, 0.15), transparent 60%),
        radial-gradient(44rem 24rem at 35% 115%, rgba(22, 52, 45, 0.75), transparent 70%),
        var(--color-bg);
}

.hero-grid {
    display: grid;
    gap: clamp(2.5rem, 1rem + 5vw, 4rem);
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
}

@media (min-width: 60rem) {
    .hero-grid { grid-template-columns: minmax(0, 1fr) auto; }
}

.hero-copy > * + * {
    margin-top: 1.25rem;
}

.hero h1 {
    font-size: var(--text-display);
    font-weight: 800;
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.hero-copy > .hero-actions {
    margin-top: 2rem;
}

.hero-wordmark img {
    width: clamp(10rem, 7rem + 12vw, 15rem);
    height: auto;
}

.hero-visual {
    display: none;
    justify-self: center;
    position: relative;
}

.hero-visual img {
    position: relative;
    width: clamp(13rem, 4rem + 13vw, 18rem);
    filter:
        drop-shadow(0 30px 60px rgba(67, 110, 97, 0.45))
        drop-shadow(0 0 70px rgba(79, 166, 255, 0.22));
}

/* Faint orbit rings behind the medallion. Decorative only. */
.hero-visual::before,
.hero-visual::after {
    content: "";
    position: absolute;
    inset: -12%;
    border: 1px solid rgba(122, 185, 167, 0.18);
    border-radius: 50%;
}

.hero-visual::after {
    inset: -26%;
    border-color: rgba(79, 166, 255, 0.1);
}

@media (min-width: 60rem) {
    .hero-visual { display: block; }
}

/* Video hero (home page): the MasiDyn video centred on top, a blurred copy
   of its poster filling the band behind it, and "Learn more" arrows below. */
.hero-stage {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: grid;
    place-items: center;
    min-height: calc(100svh - var(--header-h));
    padding-block: clamp(2rem, 1rem + 4vw, 4rem) clamp(1.5rem, 1rem + 2vw, 2.5rem);
    border-bottom: 1px solid var(--color-border);
    text-align: center;
}

.hero-stage::before {
    content: "";
    position: absolute;
    inset: -10%;
    z-index: -2;
    background: url("/assets/motion/prime-lobby-hero-poster.jpg") center / cover no-repeat;
    filter: blur(48px) saturate(140%);
    opacity: 0.5;
}

.hero-stage::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(40rem 26rem at 50% 38%, transparent, rgba(7, 8, 12, 0.72) 70%),
        linear-gradient(to bottom, rgba(7, 8, 12, 0.2), var(--color-bg) 96%);
}

.hero-stage-inner {
    display: grid;
    justify-items: center;
    gap: clamp(0.75rem, 2svh, 1.25rem);
    width: min(100% - 2 * var(--gutter), 60rem);
}

/* As wide as the column allows, but never so tall that the headline and the
   buttons below it leave the first screen. */
.hero-video {
    position: relative;
    width: min(100%, calc(50svh * 16 / 9));
    min-width: min(100%, 16rem);
    aspect-ratio: 16 / 9;
}

.hero-video video,
.hero-video img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius-lg);
    background: var(--color-surface-sunken);
    box-shadow:
        0 0 0 1px rgba(122, 185, 167, 0.35),
        0 30px 80px -20px rgba(79, 166, 255, 0.45),
        0 0 120px rgba(142, 98, 255, 0.3);
}

/* A second, fainter outline around the frame. Decorative only. */
.hero-video::after {
    content: "";
    position: absolute;
    inset: -0.6rem;
    border: 1px solid rgba(122, 185, 167, 0.18);
    border-radius: calc(var(--radius-lg) + 0.6rem);
    pointer-events: none;
}

/* Pause and sound, in the corner of the frame. /site.js shows them. */
.hero-controls {
    position: absolute;
    right: 0.6rem;
    bottom: 0.6rem;
    z-index: 1;
    display: flex;
    gap: 0.4rem;
}

.hero-controls[hidden] { display: none; }

.hero-control {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    min-height: 2.25rem;
    padding: 0.35rem 0.8rem;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-pill);
    background: rgba(7, 8, 12, 0.72);
    color: var(--color-text);
    font: inherit;
    font-size: var(--text-sm);
    font-weight: 600;
    cursor: pointer;
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.hero-control:hover {
    border-color: var(--color-mint);
    background: rgba(7, 8, 12, 0.9);
}

.hero-control svg {
    width: 1.1rem;
    height: 1.1rem;
    flex: none;
}

/* Each button carries both of its icons; show the one for what it will do. */
.hero-control[data-hero-play][aria-pressed="true"] [data-icon="play"],
.hero-control[data-hero-play][aria-pressed="false"] [data-icon="pause"],
.hero-control[data-hero-sound][aria-pressed="true"] [data-icon="sound"],
.hero-control[data-hero-sound][aria-pressed="false"] [data-icon="sound-off"] {
    display: none;
}

@media (max-width: 30rem) {
    .hero-control span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    .hero-control { padding: 0.35rem 0.6rem; }
}

.hero-stage h1 {
    font-size: var(--text-display);
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: -0.04em;
}

.hero-stage .lede {
    max-width: 40rem;
    color: var(--color-muted);
}

.hero-stage .hero-actions { justify-content: center; }

.learn-more {
    display: inline-grid;
    justify-items: center;
    gap: 0.1rem;
    margin-top: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    color: var(--color-muted);
    font-size: var(--text-sm);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-decoration: none;
    text-transform: uppercase;
}

.learn-more:hover { color: var(--color-text); }

.learn-more svg {
    width: 1.6rem;
    height: 1.6rem;
    margin-top: -0.55rem;
}

.learn-more svg:first-of-type { margin-top: 0.1rem; }
.learn-more svg:nth-of-type(2) { opacity: 0.6; }
.learn-more svg:nth-of-type(3) { opacity: 0.3; }

@media (prefers-reduced-motion: no-preference) {
    .learn-more svg { animation: learn-more-drop 1.8s var(--ease) infinite; }
    .learn-more svg:nth-of-type(2) { animation-delay: 0.15s; }
    .learn-more svg:nth-of-type(3) { animation-delay: 0.3s; }
}

@keyframes learn-more-drop {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

/* Account page ------------------------------------------------------------ */
.auth-card { display: grid; gap: 1.25rem; }
.auth-card[hidden] { display: none; }
.auth-card > h2 { font-size: var(--text-2xl); }

.auth-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    padding: 0.25rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-pill);
    background: var(--color-surface-sunken);
}

.auth-tab {
    flex: 1 1 auto;
    min-height: 40px;
    padding: 0.4rem 0.9rem;
    border: 0;
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--color-muted);
    font: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
}

.auth-tab:hover { color: var(--color-text); }

.auth-tab[aria-selected="true"] {
    background: var(--color-surface-2);
    color: var(--color-text);
    box-shadow: 0 0 0 1px var(--color-border-strong);
}

.auth-form { display: grid; gap: 1rem; }
.auth-form label { display: block; margin-bottom: 0.35rem; font-weight: 600; }
.auth-form input { width: 100%; }
.auth-form .btn { justify-self: start; }

.link-button {
    padding: 0;
    border: 0;
    background: none;
    color: var(--color-blue-soft);
    font: inherit;
    text-decoration: underline;
    cursor: pointer;
}

/* 9. Cards ----------------------------------------------------------------- */
.card,
.product-card {
    --tone: var(--color-blue);
    position: relative;
    padding: clamp(1.25rem, 1rem + 1vw, 1.75rem);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
        var(--color-surface);
}

.card > * + * {
    margin-top: 0.75rem;
}

.card p {
    color: var(--color-muted);
}

.card-icon,
.product-icon {
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    flex: none;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--tone);
}

@supports (background: color-mix(in srgb, red 10%, transparent)) {
    .card-icon,
    .product-icon {
        border-color: color-mix(in srgb, var(--tone) 34%, transparent);
        background: color-mix(in srgb, var(--tone) 13%, transparent);
    }
}

.card-icon svg,
.product-icon svg {
    width: 1.4rem;
    height: 1.4rem;
}

.card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 600;
}

.card-link svg {
    width: 1rem;
    height: 1rem;
}

/* Tones: set per card, used by the icon, link and featured glow. */
.tone-blue   { --tone: var(--color-blue); }
.tone-purple { --tone: var(--color-purple-soft); }
.tone-green  { --tone: var(--color-green); }
.tone-mint   { --tone: var(--color-mint); }
.tone-coral  { --tone: var(--color-coral); }
.tone-indigo { --tone: var(--color-indigo); }
.tone-slate  { --tone: var(--color-muted); }

.product-grid {
    display: grid;
    gap: clamp(1rem, 0.75rem + 1vw, 1.5rem);
    grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 40rem) {
    .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 60rem) {
    .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.product-card {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    transition:
        border-color var(--dur) var(--ease),
        background-color var(--dur) var(--ease),
        transform var(--dur) var(--ease);
}

.product-card:hover {
    border-color: var(--color-border-strong);
    transform: translateY(-2px);
}

.product-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.product-card-top .badges {
    justify-content: flex-end;
}

.product-name {
    font-size: var(--text-xl);
    letter-spacing: -0.015em;
}

.product-name a {
    color: inherit;
    text-decoration: none;
}

/* Stretched link: the whole card is the hit area for .product-link. */
.product-link::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
}

.product-desc {
    color: var(--color-muted);
}

.product-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin-top: auto;
    padding-top: 0.35rem;
    color: var(--color-subtle);
    font-size: var(--text-sm);
}

.product-go {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--tone);
    font-weight: 600;
}

.product-go svg {
    width: 1rem;
    height: 1rem;
    transition: transform var(--dur) var(--ease);
}

.product-card:hover .product-go svg {
    transform: translateX(3px);
}

@supports selector(:has(*)) {
    .product-card:has(.product-link:focus-visible) {
        outline: 2px solid var(--focus);
        outline-offset: 3px;
    }

    .product-card .product-link:focus-visible {
        outline: none;
    }
}

/* Featured product: spans the full row. */
.product-featured {
    grid-column: 1 / -1;
    padding: clamp(1.5rem, 1rem + 2vw, 2.5rem);
}

@supports (background: color-mix(in srgb, red 10%, transparent)) {
    .product-featured {
        border-color: color-mix(in srgb, var(--tone) 32%, transparent);
        background:
            radial-gradient(42rem 22rem at 100% 0%, color-mix(in srgb, var(--tone) 15%, transparent), transparent 70%),
            linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.012)),
            var(--color-surface);
    }
}

.product-featured:hover {
    transform: none;
}

.product-featured-grid {
    display: grid;
    gap: clamp(1.5rem, 1rem + 2vw, 2.5rem);
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
}

@media (min-width: 56rem) {
    .product-featured-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
}

.product-featured-copy > * + * {
    margin-top: 0.9rem;
}

.product-featured .product-name {
    font-size: var(--text-3xl);
    letter-spacing: -0.03em;
}

.product-featured .product-desc {
    max-width: 36rem;
    font-size: var(--text-lg);
}

.product-destinations {
    display: grid;
    gap: 0.75rem;
}

/* A large, full-width link with a title, a detail line and an arrow. */
.link-tile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 4.25rem;
    padding: 0.9rem 1.1rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.28);
    color: var(--color-text);
    text-decoration: none;
    transition:
        border-color var(--dur) var(--ease),
        background-color var(--dur) var(--ease);
}

.link-tile:hover {
    border-color: var(--tone, var(--color-blue));
    background: rgba(255, 255, 255, 0.04);
    color: var(--color-text);
}

.link-tile strong {
    display: block;
    font-weight: 700;
}

.link-tile small {
    display: block;
    color: var(--color-muted);
    font-size: var(--text-sm);
}

.link-tile svg {
    width: 1.15rem;
    height: 1.15rem;
    color: var(--tone, var(--color-blue));
    transition: transform var(--dur) var(--ease);
}

.link-tile:hover svg {
    transform: translateX(3px);
}

/* 9b. Game hub (/play) ------------------------------------------------------
   Swatch fills for wardrobe colors are the hexes in
   agnostic/governance/FACE_COLOR_WARDROBE_V1.json. Gold is party_board.py
   FOUNDER_HEX. Grey, brown, and unassigned have no hex, so those swatches
   stay empty. */
.hub-roster {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
    gap: 0.75rem;
    margin: 1.25rem 0 0;
    padding: 0;
    list-style: none;
}

.hub-card {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-areas:
        "swatch name"
        "swatch meta"
        "swatch note";
    column-gap: 0.75rem;
    row-gap: 0.15rem;
    width: 100%;
    min-height: 48px;
    padding: 0.9rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
    color: var(--color-text);
    font: inherit;
    text-align: left;
}

.hub-card:hover {
    border-color: var(--color-border-strong);
}

.hub-card[aria-pressed="true"] {
    border-color: var(--color-text);
}

.hub-swatch {
    grid-area: swatch;
    align-self: center;
    width: 1.25rem;
    height: 1.25rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 999px;
}

.hub-swatch[data-color="gold"] { background: #ffd700; }
.hub-swatch[data-color="white"] { background: #f4f1e8; }
.hub-swatch[data-color="black"] { background: #2a2438; }
.hub-swatch[data-color="green"] { background: #3ddc84; }
.hub-swatch[data-color="blue"] { background: #4f8bff; }
.hub-swatch[data-color="yellow"] { background: #ffd23f; }
.hub-swatch[data-color="orange"] { background: #ff9a3c; }
.hub-swatch[data-color="red"] { background: #ff4d3d; }
.hub-swatch[data-color="pink"] { background: #ff7ad9; }
.hub-swatch[data-color="silver"] { background: #c0c7d0; }
.hub-swatch[data-color="violet"] { background: #7c3aed; }

.hub-swatch[data-color="grey"],
.hub-swatch[data-color="brown"],
.hub-swatch[data-color="unassigned"] {
    background: transparent;
    border-style: dashed;
}

.hub-card-name {
    grid-area: name;
    font-weight: 700;
}

.hub-card-meta,
.hub-card-note {
    color: var(--color-muted);
    font-size: var(--text-sm);
}

.hub-card-meta { grid-area: meta; }
.hub-card-note { grid-area: note; }

.hub-forms {
    display: grid;
    gap: 1rem;
    margin-top: 1.5rem;
}

@media (min-width: 48rem) {
    .hub-forms {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }
}

.hub-form {
    display: grid;
    gap: 0.9rem;
    padding: clamp(1.25rem, 1rem + 1vw, 1.75rem);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-surface);
}

.hub-form h3 {
    margin: 0;
}

.hub-form p {
    margin: 0;
    color: var(--color-muted);
}

.hub-fields {
    display: grid;
    gap: 0.75rem;
}

.hub-form label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: var(--text-sm);
    font-weight: 600;
}

.hub-form select,
.hub-form input[type="text"],
.hub-color {
    width: 100%;
    min-width: 0;
    min-height: 48px;
    padding: 0.7rem 1rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: var(--color-surface-sunken);
    color: var(--color-text);
}

.hub-color {
    display: flex;
    align-items: center;
}

.hub-toon-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.hub-toon-row input[type="text"] {
    flex: 1 1 12rem;
}

.hub-toon-row .btn {
    flex: 0 0 auto;
    min-height: 48px;
}

@media (max-width: 30rem) {
    .hub-toon-row .btn { flex-basis: 100%; }
}

.hub-saved {
    margin-top: 1.5rem;
}

.hub-saved h3 {
    margin-bottom: 0.75rem;
}

.hub-list {
    display: grid;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hub-list li {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: var(--color-surface);
}

.hub-list p {
    margin: 0;
    min-width: 0;
}

.hub-status {
    min-height: 1.6em;
    margin-top: 1rem;
    color: var(--color-muted);
}

.hub-status[data-state="error"] {
    color: var(--color-coral);
}

/* 10. Lists and notices ---------------------------------------------------- */
.feature-list {
    display: grid;
    gap: 1rem;
    padding: 0;
    list-style: none;
}

.feature-list > li {
    position: relative;
    padding-left: 1.9rem;
    color: var(--color-text);
}

.feature-list > li::before {
    content: "";
    position: absolute;
    top: 0.3em;
    left: 0.4rem;
    width: 0.42rem;
    height: 0.78rem;
    border: solid var(--color-green);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.feature-list strong {
    display: block;
    font-weight: 600;
}

.feature-list span,
.feature-list p {
    color: var(--color-muted);
}

/* Label + badge rows, e.g. where the account works today. */
.status-list {
    padding: 0;
    list-style: none;
}

.status-list > li {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    padding-block: 0.85rem;
    border-bottom: 1px solid var(--color-border);
}

.status-list > li:last-child {
    border-bottom: 0;
}

.status-list > li > :first-child {
    flex: 1 1 auto;
    min-width: 0;
}

.status-list .badge {
    flex: none;
}

.notice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.2rem;
    border: 1px solid rgba(79, 166, 255, 0.35);
    border-radius: 12px;
    background: rgba(79, 166, 255, 0.07);
    color: var(--color-text);
}

.notice > svg {
    width: 1.25rem;
    height: 1.25rem;
    margin-top: 0.15rem;
    color: var(--color-blue);
}

.notice p {
    color: var(--color-muted);
}

.notice strong {
    color: var(--color-text);
}

.notice-18 {
    border-color: rgba(255, 138, 128, 0.4);
    background: rgba(255, 138, 128, 0.07);
}

.notice-18 > svg {
    color: var(--color-coral);
}

/* 11. Waitlist form -------------------------------------------------------- */
.waitlist {
    display: grid;
    gap: 1rem;
    max-width: 34rem;
}

.waitlist label:not(.waitlist-check) {
    display: block;
    margin-bottom: 0.45rem;
    font-size: var(--text-sm);
    font-weight: 600;
}

.waitlist-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.waitlist input[type="email"],
.waitlist input[type="password"],
.waitlist input[type="text"] {
    flex: 1 1 15rem;
    min-width: 0;
    min-height: 48px;
    padding: 0.7rem 1rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: var(--color-surface-sunken);
    color: var(--color-text);
    transition: border-color var(--dur) var(--ease);
}

.waitlist input[type="email"]::placeholder,
.waitlist input[type="password"]::placeholder,
.waitlist input[type="text"]::placeholder {
    color: var(--color-subtle);
    opacity: 1;
}

.waitlist input[type="email"]:hover,
.waitlist input[type="password"]:hover,
.waitlist input[type="text"]:hover {
    border-color: rgba(255, 255, 255, 0.3);
}

.waitlist input[type="email"]:focus-visible,
.waitlist input[type="password"]:focus-visible,
.waitlist input[type="text"]:focus-visible {
    border-color: var(--focus);
    outline-offset: 1px;
}

.waitlist button[type="submit"] {
    flex: 0 0 auto;
    min-height: 48px;
}

@media (max-width: 30rem) {
    .waitlist button[type="submit"] { flex-basis: 100%; }
}

.waitlist-check {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    color: var(--color-text);
    font-size: 0.95rem;
    cursor: pointer;
}

.waitlist-check input[type="checkbox"] {
    width: 1.15rem;
    height: 1.15rem;
    margin-top: 0.2rem;
    flex: none;
    accent-color: var(--color-blue);
    cursor: pointer;
}

.waitlist-fine {
    color: var(--color-subtle);
    font-size: var(--text-sm);
}

/* waitlist.js writes the message and sets data-state: pending | ok | error. */
.waitlist-status {
    min-height: 1.6em;
    color: var(--color-muted);
    font-size: 0.95rem;
    font-weight: 600;
}

.waitlist-status:empty {
    min-height: 0;
}

.waitlist-status[data-state="ok"],
.waitlist-status[data-state="success"] {
    color: var(--color-green);
}

.waitlist-status[data-state="error"] {
    color: var(--color-coral);
}

.waitlist button:disabled {
    cursor: progress;
    opacity: 0.7;
    transform: none;
}

/* After Dark stays out of the menu, footer, and product card until site.js
   sets data-afterdark="open": signed in, and the stated date of birth for
   that account is 18 or older. */
html:not([data-afterdark="open"]) :is(li, .product-card):has(a[href="/afterdark"], a[href^="/afterdark?"], a[href^="/afterdark#"], a[data-app*="window=dark"]) {
    display: none;
}

/* 12. Age gate -------------------------------------------------------------
   /afterdark/age-gate.js adds .age-ok only after a signed-in stated age of
   18 or older. Without that class the page behind the gate stays hidden. */
.age-gate {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: grid;
    place-items: center;
    padding: var(--gutter);
    overflow-y: auto;
    background:
        radial-gradient(40rem 30rem at 50% 30%, rgba(142, 98, 255, 0.14), transparent 70%),
        rgba(4, 5, 8, 0.96);
}

.age-gate[hidden],
#age-confirmed:target ~ .age-gate {
    display: none;
}

.age-gate-panel {
    width: 100%;
    max-width: 32rem;
    padding: clamp(1.5rem, 1rem + 3vw, 2.5rem);
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.age-gate-panel > * + * {
    margin-top: 1rem;
}

.age-gate-panel p {
    color: var(--color-muted);
}

.age-gate-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    padding-top: 0.5rem;
}

.age-gate-actions .btn {
    flex: 1 1 12rem;
}

html:has(.age-gate:not([hidden])):not(:has(#age-confirmed:target)) body {
    overflow: hidden;
}

/* 13. Site footer ---------------------------------------------------------- */
.site-footer {
    padding-block: clamp(3rem, 2rem + 4vw, 4.5rem) 2rem;
    border-top: 1px solid var(--color-border);
    background: var(--color-surface-sunken);
    color: var(--color-muted);
    font-size: 0.925rem;
}

.footer-grid {
    display: grid;
    gap: 2.25rem 2rem;
    grid-template-columns: minmax(0, 1fr);
}

.footer-nav {
    display: grid;
    gap: 2rem 1.5rem;
    grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
}

@media (min-width: 60rem) {
    .footer-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
}

.footer-about > * + * {
    margin-top: 0.9rem;
}

.footer-about p {
    max-width: 22rem;
}

.footer-heading {
    margin-bottom: 0.85rem;
    color: var(--color-text);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.footer-list {
    display: grid;
    gap: 0.15rem;
    list-style: none;
}

.footer-list a,
.footer-about a:not(.brand),
.footer-bottom a {
    color: var(--color-muted);
    text-decoration: none;
}

.footer-list a {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
}

.footer-list a:hover,
.footer-about a:not(.brand):hover,
.footer-bottom a:hover {
    color: var(--color-text);
    text-decoration: underline;
}

.footer-about a:not(.brand) {
    color: var(--color-text);
    font-weight: 600;
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem 1.5rem;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
    color: var(--color-subtle);
    font-size: var(--text-sm);
}

/* 14. Utilities ------------------------------------------------------------ */
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.icon {
    display: inline-block;
    width: 1.25em;
    height: 1.25em;
    vertical-align: -0.2em;
}

.mt-0 { margin-top: 0 !important; }
.mt-2 { margin-top: var(--space-2) !important; }
.mt-4 { margin-top: var(--space-4) !important; }
.mt-6 { margin-top: var(--space-6) !important; }

/* 15. Motion and forced colours ------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .btn:hover,
    .product-card:hover,
    .float-hover:hover {
        transform: none;
    }
}

@media (forced-colors: active) {
    .text-gradient,
    .gradient-text,
    .gradient-text-alt {
        background: none;
        color: CanvasText;
        -webkit-text-fill-color: currentColor;
    }

    .btn,
    .badge,
    .card,
    .product-card,
    .notice {
        border: 1px solid CanvasText;
    }
}

/* 16. Legacy ---------------------------------------------------------------
   Selectors used by the older pages (field-test, legends, notices, terms,
   privacy, active-handoff). New pages should use the components above.
   Remove a block once no page uses it. */

.logo,
.nav-links a,
.footer-links a,
.lab-link {
    text-decoration: none;
}

/* Ambient background orbs */
.ambient-background {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    animation: drift 20s infinite alternate ease-in-out;
}

.orb-1 { top: -200px; left: -100px; width: 600px; height: 600px; background: var(--color-blue); }
.orb-2 { right: -100px; bottom: -100px; width: 500px; height: 500px; background: var(--color-purple); animation-delay: -5s; }
.orb-3 { top: 40%; left: 30%; width: 400px; height: 400px; background: var(--color-green); opacity: 0.08; animation-delay: -10s; }

@keyframes drift {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Fixed glass navigation */
.glass-nav {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 100;
    border-bottom: 1px solid var(--card-border);
    background: rgba(7, 8, 12, 0.72);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.2rem 2rem;
}

.logo {
    display: flex;
    align-items: center;
    color: var(--color-text);
    font-size: 1.5rem;
    font-weight: 300;
    letter-spacing: -0.5px;
}

.logo:hover { color: var(--color-text); }
.logo-bold { font-weight: 800; }
.logo-text { white-space: nowrap; }
.logo-dyn { color: var(--color-dyn); font-weight: 800; }
.logo-coin { display: block; flex: none; width: 34px; height: 34px; margin-right: 0.55rem; }
.footer-brand .logo-coin { width: 28px; height: 28px; }

.nav-links a {
    margin: 0 1.1rem;
    color: var(--color-text);
    font-size: 0.95rem;
    font-weight: 600;
}

.nav-links a:hover { color: var(--color-blue); }

.btn-outline {
    padding: 0.6rem 1.4rem;
    border-color: var(--color-blue);
    background: transparent;
    color: var(--color-blue);
}

.btn-outline:hover {
    background: var(--color-blue);
    color: var(--color-on-accent);
}

/* Old home-page hero */
.hero-section { max-width: 900px; margin: 0 auto; padding: 12rem 2rem 6rem; text-align: center; }
.hero-title { margin-bottom: 1.5rem; font-size: clamp(2.6rem, 8vw, 4.5rem); font-weight: 800; line-height: 1.1; letter-spacing: -2px; }
.hero-subtitle { max-width: 700px; margin: 0 auto 3rem; color: var(--color-muted); font-size: 1.25rem; }

.gradient-text,
.gradient-text-alt {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.gradient-text-alt { background-image: var(--gradient-2); }

.glass-card {
    padding: 2.5rem;
    border: 1px solid var(--card-border);
    border-radius: 16px;
    background: var(--card-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

/* Sections: .container now carries the side gutter. */
.feature-section { padding: 6rem 0; }

.alt-bg {
    border-top: 1px solid var(--card-border);
    border-bottom: 1px solid var(--card-border);
    background: rgba(255, 255, 255, 0.01);
}

.section-header { margin-bottom: 4rem; text-align: center; }
.section-header h2 { margin-bottom: 1rem; font-size: clamp(1.9rem, 4vw, 2.5rem); font-weight: 800; }
.section-header h1 { margin-bottom: 1rem; }
.section-header p { color: var(--color-muted); font-size: 1.1rem; }

.feature-card .icon { margin-bottom: 1.5rem; font-size: 2.5rem; }
.feature-card h3 { margin-bottom: 1rem; font-size: 1.3rem; }
.feature-card p { color: var(--color-muted); font-size: 0.95rem; }
.feature-card p + p { margin-top: 0.75rem; }

.float-hover { transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.float-hover:hover { transform: translateY(-6px); }

.split-layout {
    display: grid;
    gap: 4rem;
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
}

@media (min-width: 58rem) {
    .split-layout { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.text-content h2 { margin-bottom: 1.5rem; font-size: clamp(1.9rem, 4vw, 2.5rem); font-weight: 800; }
.text-content p { margin-bottom: 2rem; color: var(--color-muted); font-size: 1.1rem; }

.code-font { font-family: var(--font-mono); font-size: 0.9rem; line-height: 1.5; }

/* Document pages (privacy, terms, notices) */
.privacy-container { max-width: 900px; margin: 0 auto; padding: 8rem 2rem 4rem; }
.doc-header { margin-bottom: 2rem; padding-bottom: 2rem; border-bottom: 1px solid var(--card-border); }
.doc-header h1 { margin-bottom: 0.5rem; font-size: clamp(1.9rem, 5vw, 2.5rem); }
.doc-header .subtitle { color: var(--color-muted); }
.doc-section { margin-bottom: 2.5rem; }
.doc-section h2 { margin-bottom: 1rem; color: var(--color-blue); font-size: 1.4rem; }
.doc-section p { margin-bottom: 1rem; color: var(--color-muted); }
.doc-section ul { margin-bottom: 1rem; margin-left: 1.5rem; color: var(--color-muted); }
.doc-section li { margin-bottom: 0.5rem; }
.doc-section strong { color: var(--color-text); }

/* Old footer (the new one is .site-footer) */
footer:not(.site-footer) {
    margin-top: 4rem;
    padding: 3rem 2rem;
    border-top: 1px solid var(--card-border);
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-brand .logo { margin-bottom: 0.5rem; }
.footer-brand p { color: var(--color-muted); font-size: 0.9rem; }
.lab-link { color: var(--color-text); font-weight: 600; }
.footer-links a { margin-left: 1.5rem; color: var(--color-muted); font-size: 0.9rem; }
.footer-links a:hover { color: var(--color-blue); }

/* Active Handoff */
.handoff-hero { padding: 11rem 0 5rem; text-align: left; }
.handoff-hero h1 { max-width: 980px; margin: 1.2rem 0 1.8rem; font-size: clamp(2.6rem, 7.5vw, 7.3rem); line-height: 0.98; letter-spacing: -0.055em; }
.handoff-lede { max-width: 840px; margin-bottom: 2.4rem; color: var(--color-muted); font-size: clamp(1.1rem, 2vw, 1.45rem); }
.handoff-hero .hero-actions { justify-content: flex-start; }

.truth-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin-top: 4rem; overflow: hidden; border: 1px solid var(--card-border); border-radius: 12px; background: var(--card-border); }
.truth-strip span { padding: 1.1rem 1.2rem; background: #0b0d13; color: var(--color-muted); }
.truth-strip strong { color: var(--color-text); }
.compact { max-width: 820px; margin-right: auto; margin-left: auto; }
.kicker { margin-bottom: 0.8rem; color: var(--color-green); font-size: 0.78rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; }

.protocol-line { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid var(--card-border); border-radius: 16px; background: var(--card-border); }
.protocol-line article { min-height: 270px; padding: 2rem; background: #0a0c11; }
.protocol-line span { color: var(--color-blue); font-family: var(--font-mono); }
.protocol-line h3 { margin: 4rem 0 0.8rem; font-size: 1.25rem; }
.protocol-line p { color: var(--color-muted); font-size: 0.93rem; }
.pitch-split { gap: 5rem; }
.evidence-card { padding: 1.6rem 2rem; }
.evidence-row { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--card-border); color: var(--color-muted); }
.evidence-row:last-child { border: 0; }
.evidence-row strong { color: var(--color-text); text-align: right; }

.comparison-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; }
.comparison-grid h3 { margin: 0.7rem 0 1.4rem; font-size: 1.6rem; }
.compare-label { display: inline-block; padding: 0.35rem 0.7rem; border: 1px solid rgba(69, 207, 134, 0.35); border-radius: 20px; color: var(--color-green); font-size: 0.75rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.compare-label.cloud { border-color: rgba(79, 166, 255, 0.35); color: var(--color-blue); }
.callout { display: grid; grid-template-columns: auto 1fr; gap: 1rem; margin-top: 1.4rem; padding: 1.2rem 1.4rem; border-left: 3px solid var(--color-green); background: rgba(69, 207, 134, 0.06); }
.callout span { color: var(--color-muted); }

.knob-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.knob-card { display: grid; gap: 1rem; padding: 1.4rem; border: 1px solid var(--card-border); border-radius: 12px; background: var(--card-bg); }
.knob-card > span { font-weight: 800; }
.knob-card small { color: var(--color-muted); }
.fake-slider { height: 7px; overflow: hidden; border-radius: 9px; background: rgba(255, 255, 255, 0.09); }
.fake-slider i { display: block; height: 100%; background: var(--gradient-2); }
.number-chip { color: var(--color-blue); font-size: 1.25rem; font-weight: 800; }
.partner-section { border-top: 1px solid var(--card-border); border-bottom: 1px solid var(--card-border); background: linear-gradient(180deg, rgba(79, 166, 255, 0.04), rgba(142, 98, 255, 0.03)); }
.partner-card h3 { margin-bottom: 1rem; }
.partner-card p { margin-bottom: 1.5rem; color: var(--color-muted); }
.code-sample pre { color: #b7dfc8; font-family: var(--font-mono); white-space: pre-wrap; }
.code-sample p { margin-top: 1rem; color: var(--color-muted); }

.status-table { overflow: hidden; border: 1px solid var(--card-border); border-radius: 14px; }
.status-table > div { display: grid; grid-template-columns: 1fr auto; gap: 1rem; padding: 1.1rem 1.3rem; border-bottom: 1px solid var(--card-border); }
.status-table > div:last-child { border: 0; }
.status-table strong { font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; }
.done { color: var(--color-green); }
.candidate { color: #ffbd2e; }
.not-done { color: #ff7f75; }
.source-note { max-width: 920px; margin: 1.5rem auto 0; color: var(--color-muted); font-size: 0.88rem; }
.cta-section { padding: 7rem 0; background: radial-gradient(circle at center, rgba(79, 166, 255, 0.12), transparent 58%); text-align: center; }
.cta-section h2 { margin-bottom: 1rem; font-size: clamp(2.2rem, 5vw, 5rem); }
.cta-section p:not(.kicker) { max-width: 700px; margin: 0 auto 2rem; color: var(--color-muted); }

/* Programmer field test */
.field-hero { max-width: 1120px; margin: 0 auto; padding: 10rem 2rem 4rem; }
.field-hero h1 { max-width: 900px; margin: 1rem 0 1.5rem; font-size: clamp(2.6rem, 7vw, 6.8rem); line-height: 0.98; letter-spacing: -0.055em; }
.field-lede { max-width: 790px; color: var(--color-muted); font-size: clamp(1.05rem, 2vw, 1.35rem); }
.runtime-panel { display: grid; grid-template-columns: auto 1fr auto; gap: 1rem; align-items: center; margin-top: 3rem; padding: 1.5rem; }
.status-light { width: 14px; height: 14px; border-radius: 50%; background: #ffbd2e; box-shadow: 0 0 18px rgba(255, 189, 46, 0.55); }
.status-light.ok { background: var(--color-green); box-shadow: 0 0 18px rgba(69, 207, 134, 0.55); }
.status-light.fail { background: #ff6d67; box-shadow: 0 0 18px rgba(255, 109, 103, 0.55); }
.runtime-copy strong { display: block; font-size: 1.05rem; }
.runtime-copy span { color: var(--color-muted); font-size: 0.9rem; }
.status-retry { border: 1px solid var(--card-border); background: transparent; color: var(--color-text); }

.field-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.field-card { display: flex; flex-direction: column; min-height: 320px; }
.field-card .card-index { color: var(--color-blue); font: 700 0.78rem var(--font-mono); letter-spacing: 0.12em; }
.field-card h2 { margin: 1.4rem 0 0.8rem; font-size: 1.55rem; }
.field-card p { margin-bottom: 1rem; color: var(--color-muted); }
.field-card .btn { margin-top: auto; text-align: center; }
.truth-note { margin-top: 1rem; color: var(--color-muted); font-size: 0.88rem; }

.field-proof { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.field-proof h2 { margin-bottom: 0.5rem; }
.proof-list { list-style: none; }
.proof-list li { padding: 1rem 0; border-bottom: 1px solid var(--card-border); }
.proof-list li:last-child { border-bottom: 0; }
.proof-list strong { display: block; }
.proof-list span { color: var(--color-muted); }

.fade-in-up { animation: fadeInUp 0.8s ease forwards; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 920px) {
    .nav-links { display: none; }
    .truth-strip,
    .protocol-line,
    .comparison-grid,
    .knob-grid,
    .field-grid,
    .field-proof { grid-template-columns: minmax(0, 1fr); }
    .protocol-line article { min-height: auto; }
    .protocol-line h3 { margin-top: 1.5rem; }
    .pitch-split { gap: 2rem; }
    .callout { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
    /* legends.html sets a fixed two-column grid inline; stack it on phones. */
    .grid-3[style*="1fr 1fr"] { grid-template-columns: minmax(0, 1fr) !important; }
}

@media (max-width: 640px) {
    .logo-coin { width: 28px; height: 28px; }
}

@media (max-width: 620px) {
    .nav-container { padding: 1rem; }
    .nav-container .nav-download-btn { display: none; }
    .handoff-hero { padding: 8rem 0 3rem; }
    .handoff-hero .hero-actions { flex-direction: column; }
    .feature-section { padding: 4rem 0; }
    .cta-section { padding: 5rem 0; }
    .glass-card { padding: 1.5rem; }
    .status-table > div { grid-template-columns: 1fr; }
    footer:not(.site-footer) { padding: 2.5rem 1.2rem; }
    .footer-container { flex-direction: column; align-items: flex-start; }
    .footer-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; }
    .footer-links a { margin: 0; }
    .privacy-container { padding: 7rem 1.2rem 3rem; }
    .field-hero { padding: 8rem 1.2rem 3rem; }
    .runtime-panel { grid-template-columns: auto 1fr; }
    .runtime-panel .status-retry { grid-column: 1 / -1; width: 100%; }
}

.auth-providers { display: grid; gap: 0.75rem; margin-top: 1rem; }
.auth-provider-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.auth-provider-row .btn { width: 100%; }

.social-hub-card { grid-column: 1 / -1; }
.social-hub-card > .btn { margin-top: 1rem; align-self: flex-start; }
.social-layers { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 1.5rem 0 1rem; }
.social-layers > a { display: grid; gap: .5rem; padding: 1rem; border: 1px solid var(--color-border); border-radius: 12px; color: inherit; text-decoration: none; background: rgba(255,255,255,.025); }
.social-layers > a > span { color: var(--color-muted); font-size: .9rem; line-height: 1.6; }
.social-layers > a:hover { border-color: #7fd8bd; }
.social-layers > a:focus-visible { outline: 3px solid #7fd8bd; outline-offset: 4px; }
@media (max-width: 40rem) { .social-layers { grid-template-columns: 1fr; } }

/* 17. Live Sovereign Airlock & Critical Operator Actions (/airlock) -------- */
.airlock-critical-band {
    border-top: 1px solid rgba(212, 175, 55, 0.38);
    border-bottom: 1px solid rgba(212, 175, 55, 0.28);
    background:
        radial-gradient(48rem 22rem at 15% 0%, rgba(212, 175, 55, 0.12), transparent 72%),
        radial-gradient(36rem 20rem at 90% 10%, rgba(127, 216, 189, 0.08), transparent 70%),
        var(--color-surface-sunken);
}

.airlock-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1.25rem;
    margin-bottom: 1.25rem;
    padding: 0.85rem 1.1rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: rgba(7, 8, 12, 0.72);
}

.airlock-bridge-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem 0.9rem;
    min-width: 0;
    font-size: var(--text-sm);
    color: var(--color-muted);
}

.airlock-pulse {
    display: inline-block;
    width: 0.65rem;
    height: 0.65rem;
    flex: none;
    border-radius: 999px;
    background: #d4af37;
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.75);
}

.airlock-pulse.is-local {
    background: var(--color-green);
    box-shadow: 0 0 12px rgba(69, 207, 134, 0.75);
}

.airlock-actions-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1fr);
}

.airlock-action-card {
    display: grid;
    gap: 0.9rem;
    padding: clamp(1.25rem, 1rem + 1.2vw, 1.75rem);
    border: 1px solid rgba(212, 175, 55, 0.48);
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(212, 175, 55, 0.08), rgba(255, 255, 255, 0.015)),
        var(--color-surface);
}

.airlock-action-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1rem;
}

.badge-critical {
    border-color: rgba(212, 175, 55, 0.55);
    background: rgba(212, 175, 55, 0.16);
    color: #f6dc86;
}

.airlock-action-id {
    color: var(--color-subtle);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    overflow-wrap: anywhere;
}

.airlock-action-title {
    font-size: var(--text-xl);
    letter-spacing: -0.015em;
}

.airlock-action-why {
    color: var(--color-muted);
    max-width: 68ch;
}

.airlock-action-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
    padding-top: 0.25rem;
}

.airlock-action-reply-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    padding-top: 0.65rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.airlock-action-reply-input {
    flex: 1 1 18rem;
    min-width: 14rem;
    padding: 0.55rem 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-sm, 0.5rem);
    background: rgba(7, 8, 12, 0.72);
    color: var(--color-text);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
}

.airlock-action-reply-input:focus {
    outline: none;
    border-color: rgba(212, 175, 55, 0.75);
}

.airlock-action-replies {
    display: grid;
    gap: 0.45rem;
}

.airlock-action-reply-turn {
    padding: 0.55rem 0.75rem;
    border-left: 2px solid rgba(69, 207, 134, 0.75);
    border-radius: 0 0.4rem 0.4rem 0;
    background: rgba(7, 8, 12, 0.55);
    font-size: var(--text-xs);
    color: var(--color-muted);
}

.airlock-action-reply-status {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--color-subtle);
}

.airlock-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    margin-bottom: 1.25rem;
}

.airlock-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.airlock-tab {
    min-height: 40px;
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 999px;
    background: var(--color-surface);
    color: var(--color-muted);
    font: inherit;
    font-size: var(--text-sm);
    font-weight: 600;
    cursor: pointer;
}

.airlock-tab:hover,
.airlock-tab[aria-pressed="true"] {
    border-color: var(--color-mint);
    background: rgba(127, 216, 189, 0.12);
    color: var(--color-text);
}

.airlock-search {
    flex: 1 1 14rem;
    max-width: 22rem;
    min-width: 0;
    min-height: 42px;
    padding: 0.55rem 0.9rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: var(--color-surface-sunken);
    color: var(--color-text);
    font: inherit;
}

@media (max-width: 40rem) {
    .airlock-search {
        max-width: none;
        flex-basis: 100%;
    }
}

.airlock-stage {
    margin-bottom: 1.5rem;
    overflow: hidden;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius);
    background: #05060a;
}

.airlock-stage-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem 1rem;
    padding: 0.75rem 1.1rem;
    border-bottom: 1px solid var(--color-border);
    background: var(--color-surface);
}

.airlock-stage-title {
    font-weight: 700;
    min-width: 0;
}

.airlock-frame {
    display: block;
    width: 100%;
    height: clamp(22rem, 58vh, 38rem);
    border: 0;
    background: #05060a;
}

.airlock-panel-grid {
    display: grid;
    gap: 0.85rem;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 16.5rem), 1fr));
}

.airlock-panel-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.65rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: var(--color-surface);
    transition: border-color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}

.airlock-panel-card:hover,
.airlock-panel-card.is-active {
    border-color: var(--color-mint);
    background: rgba(127, 216, 189, 0.06);
}

.airlock-panel-card h3 {
    font-size: 1rem;
    line-height: 1.35;
}

.airlock-panel-card p {
    color: var(--color-muted);
    font-size: var(--text-sm);
}

.airlock-panel-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 0.25rem;
}



/* --- ROOT LANDING & AGENTS STYLES --- */
:root {
    --bg-color: #07080c;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-main: #f0f2f5;
    --text-muted: #aeb8c6;
    
    --primary-blue: #4fa6ff;
    --primary-purple: #8e62ff;
    --accent-green: #45cf86;
    
    --gradient-1: linear-gradient(135deg, var(--primary-blue), var(--primary-purple));
    --gradient-2: linear-gradient(135deg, var(--accent-green), var(--primary-blue));
    
    --font-main: 'Inter', sans-serif;
    --font-code: 'Courier New', Courier, monospace;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-purple);
}

/* Ambient Background Orbs */
.ambient-background {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    animation: drift 20s infinite alternate ease-in-out;
}

.orb-1 {
    width: 600px; height: 600px;
    background: var(--primary-blue);
    top: -200px; left: -100px;
}

.orb-2 {
    width: 500px; height: 500px;
    background: var(--primary-purple);
    bottom: -100px; right: -100px;
    animation-delay: -5s;
}

.orb-3 {
    width: 400px; height: 400px;
    background: var(--accent-green);
    top: 40%; left: 30%;
    opacity: 0.08;
    animation-delay: -10s;
}

@keyframes drift {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Glassmorphism Navigation */
.glass-nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    background: rgba(7, 8, 12, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--card-border);
    z-index: 100;
}

.nav-container {
    max-width: 1380px;
    margin: 0 auto;
    padding: 0.95rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.logo {
    font-size: 1.45rem;
    font-weight: 300;
    letter-spacing: -0.5px;
    flex-shrink: 0;
    white-space: nowrap;
}

.logo-bold {
    font-weight: 800;
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem 1rem;
}

.nav-links a {
    color: var(--text-main);
    margin: 0;
    font-size: 0.86rem;
    font-weight: 600;
    white-space: nowrap;
}

.nav-cta-group {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-shrink: 0;
    white-space: nowrap;
}

.nav-cta-group .btn {
    white-space: nowrap;
}

.mobile-nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0.38rem 0.78rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
}

.mobile-nav-toggle:hover {
    border-color: var(--primary-blue);
    background: rgba(79, 166, 255, 0.14);
}

.nav-links a:hover {
    color: var(--primary-blue);
}

/* Buttons */
.btn {
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-primary {
    background: var(--gradient-1);
    color: #fff;
    border: none;
    box-shadow: 0 4px 15px rgba(79, 166, 255, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(79, 166, 255, 0.5);
    transform: translateY(-2px);
    color: #fff;
}

.btn-secondary {
    background: rgba(255,255,255,0.05);
    color: var(--text-main);
    border: 1px solid var(--card-border);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
    color: #fff;
}

.btn[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: 0.62;
    pointer-events: none;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--primary-blue);
    color: var(--primary-blue);
    padding: 0.6rem 1.4rem;
}

.btn-outline:hover {
    background: var(--primary-blue);
    color: #fff;
}

/* Hero Section */
.hero-section {
    padding: 12rem 2rem 6rem;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.badge {
    display: inline-block;
    padding: 0.4rem 1.2rem;
    background: rgba(79, 166, 255, 0.1);
    border: 1px solid rgba(79, 166, 255, 0.2);
    border-radius: 20px;
    color: var(--primary-blue);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -2px;
}

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

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

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

/* Glass Cards */
.glass-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 2.5rem;
}

/* Sections */
.feature-section {
    padding: 6rem 2rem;
}

.alt-bg {
    background: rgba(255, 255, 255, 0.01);
    border-top: 1px solid var(--card-border);
    border-bottom: 1px solid var(--card-border);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

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

.feature-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.float-hover {
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.float-hover:hover {
    transform: translateY(-10px);
}

/* Split Layout */
.split-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.text-content h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.text-content p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-main);
}

.feature-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--primary-blue);
}

/* Mockup Window */
.mockup-header {
    display: flex;
    align-items: center;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--card-border);
    margin-bottom: 1.5rem;
}

.dots {
    display: flex;
    gap: 6px;
}

.dots span {
    width: 12px; height: 12px;
    border-radius: 50%;
    background: #ff5f56;
}

.dots span:nth-child(2) { background: #ffbd2e; }
.dots span:nth-child(3) { background: #27c93f; }

.mockup-title {
    margin-left: auto;
    margin-right: auto;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.code-font {
    font-family: var(--font-code);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Privacy Document Styling */
.privacy-container {
    padding: 8rem 2rem 4rem;
    max-width: 900px;
    margin: 0 auto;
}

.doc-header {
    border-bottom: 1px solid var(--card-border);
    padding-bottom: 2rem;
    margin-bottom: 2rem;
}

.doc-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.doc-section {
    margin-bottom: 2.5rem;
}

.doc-section h2 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: var(--primary-blue);
}

.doc-section p {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.doc-section ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.doc-section li {
    margin-bottom: 0.5rem;
}

.doc-section strong {
    color: var(--text-main);
}

/* Footer */
footer {
    border-top: 1px solid var(--card-border);
    padding: 3rem 2rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-brand .logo {
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.lab-link {
    color: var(--text-main);
    font-weight: 600;
}

.footer-links a {
    color: var(--text-muted);
    margin-left: 1.5rem;
    font-size: 0.9rem;
}

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

/* Active Handoff */
.handoff-hero {
    padding: 11rem 2rem 5rem;
    text-align: left;
}

.handoff-hero h1 {
    max-width: 980px;
    font-size: clamp(3.3rem, 7.5vw, 7.3rem);
    line-height: 0.98;
    letter-spacing: -0.055em;
    margin: 1.2rem 0 1.8rem;
}

.handoff-lede {
    max-width: 840px;
    color: var(--text-muted);
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    margin-bottom: 2.4rem;
}

.handoff-hero .hero-actions { justify-content: flex-start; }

.truth-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    margin-top: 4rem;
    border: 1px solid var(--card-border);
    background: var(--card-border);
    border-radius: 12px;
    overflow: hidden;
}

.truth-strip span { background: #0b0d13; padding: 1.1rem 1.2rem; color: var(--text-muted); }
.truth-strip strong { color: var(--text-main); }
.compact { max-width: 820px; margin-left: auto; margin-right: auto; }
.kicker { color: var(--accent-green); text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.78rem; font-weight: 800; margin-bottom: 0.8rem; }

.protocol-line {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--card-border);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
}

.protocol-line article { background: #0a0c11; padding: 2rem; min-height: 270px; }
.protocol-line span { color: var(--primary-blue); font-family: var(--font-code); }
.protocol-line h3 { margin: 4rem 0 0.8rem; font-size: 1.25rem; }
.protocol-line p { color: var(--text-muted); font-size: 0.93rem; }
.pitch-split { gap: 5rem; }
.evidence-card { padding: 1.6rem 2rem; }
.evidence-row { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--card-border); color: var(--text-muted); }
.evidence-row:last-child { border: 0; }
.evidence-row strong { color: var(--text-main); text-align: right; }

.comparison-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; }
.comparison-grid h3 { font-size: 1.6rem; margin: 0.7rem 0 1.4rem; }
.compare-label { display: inline-block; color: var(--accent-green); border: 1px solid rgba(69,207,134,.35); padding: .35rem .7rem; border-radius: 20px; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.compare-label.cloud { color: var(--primary-blue); border-color: rgba(79,166,255,.35); }
.callout { margin-top: 1.4rem; border-left: 3px solid var(--accent-green); background: rgba(69,207,134,.06); padding: 1.2rem 1.4rem; display: grid; grid-template-columns: auto 1fr; gap: 1rem; }
.callout span { color: var(--text-muted); }

.knob-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.knob-card { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: 12px; padding: 1.4rem; display: grid; gap: 1rem; }
.knob-card > span { font-weight: 800; }
.knob-card small { color: var(--text-muted); }
.fake-slider { height: 7px; border-radius: 9px; background: rgba(255,255,255,.09); overflow: hidden; }
.fake-slider i { display: block; height: 100%; background: var(--gradient-2); }
.number-chip { color: var(--primary-blue); font-size: 1.25rem; font-weight: 800; }
.partner-section { background: linear-gradient(180deg, rgba(79,166,255,.04), rgba(142,98,255,.03)); border-top: 1px solid var(--card-border); border-bottom: 1px solid var(--card-border); }
.partner-card h3 { margin-bottom: 1rem; }
.partner-card p { color: var(--text-muted); margin-bottom: 1.5rem; }
.code-sample pre { white-space: pre-wrap; color: #b7dfc8; font-family: var(--font-code); }
.code-sample p { color: var(--text-muted); margin-top: 1rem; }

.status-table { border: 1px solid var(--card-border); border-radius: 14px; overflow: hidden; }
.status-table > div { display: grid; grid-template-columns: 1fr auto; gap: 1rem; padding: 1.1rem 1.3rem; border-bottom: 1px solid var(--card-border); }
.status-table > div:last-child { border: 0; }
.status-table strong { font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; }
.done { color: var(--accent-green); }.candidate { color: #ffbd2e; }.not-done { color: #ff7f75; }
.source-note { max-width: 920px; margin: 1.5rem auto 0; color: var(--text-muted); font-size: .88rem; }
.cta-section { padding: 7rem 2rem; text-align: center; background: radial-gradient(circle at center, rgba(79,166,255,.12), transparent 58%); }
.cta-section h2 { font-size: clamp(2.5rem, 5vw, 5rem); margin-bottom: 1rem; }
.cta-section p:not(.kicker) { color: var(--text-muted); margin: 0 auto 2rem; max-width: 700px; }

/* Programmer field test */
.field-hero {
    padding: 10rem 2rem 4rem;
    max-width: 1120px;
    margin: 0 auto;
}

.field-hero h1 {
    max-width: 900px;
    font-size: clamp(3.2rem, 7vw, 6.8rem);
    line-height: 0.98;
    letter-spacing: -0.055em;
    margin: 1rem 0 1.5rem;
}

.field-lede {
    max-width: 790px;
    color: var(--text-muted);
    font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.runtime-panel {
    margin-top: 3rem;
    padding: 1.5rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 1rem;
    align-items: center;
}

.status-light {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ffbd2e;
    box-shadow: 0 0 18px rgba(255, 189, 46, .55);
}

.status-light.ok { background: var(--accent-green); box-shadow: 0 0 18px rgba(69, 207, 134, .55); }
.status-light.fail { background: #ff6d67; box-shadow: 0 0 18px rgba(255, 109, 103, .55); }
.runtime-copy strong { display: block; font-size: 1.05rem; }
.runtime-copy span { color: var(--text-muted); font-size: .9rem; }
.status-retry { color: var(--text-main); background: transparent; border: 1px solid var(--card-border); }

.field-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.field-card { display: flex; flex-direction: column; min-height: 320px; }
.field-card .card-index { color: var(--primary-blue); font: 700 .78rem var(--font-code); letter-spacing: .12em; }
.field-card h2 { margin: 1.4rem 0 .8rem; font-size: 1.55rem; }
.field-card p { color: var(--text-muted); margin-bottom: 1rem; }
.field-card .btn { margin-top: auto; text-align: center; }
.truth-note { margin-top: 1rem; color: var(--text-muted); font-size: .88rem; }

.field-proof {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.proof-list { list-style: none; }
.proof-list li { padding: 1rem 0; border-bottom: 1px solid var(--card-border); }
.proof-list li:last-child { border-bottom: 0; }
.proof-list strong { display: block; }
.proof-list span { color: var(--text-muted); }

/* Animations */
.fade-in-up {
    animation: fadeInUp 0.8s ease forwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 920px) {
    .mobile-nav-toggle { display: inline-flex; }
    .header-inline-links { display: none !important; }
    .nav-links { display: none; }
    .glass-nav.nav-open .nav-container { flex-wrap: wrap; }
    .glass-nav.nav-open .nav-links {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 0.25rem;
        flex: 1 0 100%;
        order: 3;
        padding: 0.85rem 0 0.35rem;
        margin-top: 0.55rem;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
    .glass-nav.nav-open .nav-links a {
        padding: 0.55rem 0.45rem;
        border-radius: 8px;
        font-size: 0.94rem;
    }
    .glass-nav.nav-open .nav-links a:hover {
        background: rgba(255, 255, 255, 0.06);
    }
    .truth-strip, .protocol-line, .comparison-grid, .knob-grid { grid-template-columns: 1fr; }
    .protocol-line article { min-height: auto; }
    .protocol-line h3 { margin-top: 1.5rem; }
    .pitch-split { grid-template-columns: 1fr; gap: 2rem; }
    .callout { grid-template-columns: 1fr; }
    .field-grid, .field-proof { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
    .nav-container { padding: 0.65rem 0.75rem; gap: 0.4rem; }
    .logo { font-size: 1.1rem; gap: 0.4rem; }
    .logo-legal { display: none; }
    .nav-container .nav-download-btn { display: none; }
    .nav-cta-group { gap: 0.35rem; }
    .mobile-nav-toggle { padding: 0.34rem 0.62rem; font-size: 0.78rem; min-height: 34px; }
    .nav-cta-group .btn:not(.nav-download-btn) { display: inline-flex; align-items: center; min-height: 34px; padding: 0.36rem 0.65rem !important; font-size: 0.78rem !important; }
    .handoff-hero { padding: 8rem 1.2rem 3rem; }
    .handoff-hero .hero-actions { flex-direction: column; }
    .feature-section { padding: 4rem 1.2rem; }
    .glass-card { padding: 1.5rem; }
    .status-table > div { grid-template-columns: 1fr; }
    .footer-container { flex-direction: column; gap: 1.5rem; align-items: flex-start; }
    .footer-links a { margin: 0 1rem 0 0; }
    .field-hero { padding: 8rem 1.2rem 3rem; }
    .runtime-panel { grid-template-columns: auto 1fr; }
    .runtime-panel .status-retry { grid-column: 1 / -1; width: 100%; }
}

/* ---- MasiDyn brand suite (organ mbs; MasiDyn_Logo/BRAND_GUIDE.md) ---------- */
/* The medallion is the logo artifact and carries its own palette. These tokens
   are the exact measured values; the site's existing accent system is unchanged. */
:root {
    --brand-emerald-deep: #16342d;
    --brand-emerald: #436e61;
    --brand-mint: #7ab9a7;
    --brand-pearl: #edf0f5;
    --brand-dyn-blue: #2e52b2;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}

/* Clear space per BRAND_GUIDE: never crop, never recolor, never outline. */
.logo-coin {
    width: 34px;
    height: 34px;
    flex: none;
    display: block;
}

.footer-brand .logo-coin {
    width: 28px;
    height: 28px;
}

@media (max-width: 640px) {
    .logo-coin { width: 28px; height: 28px; }
}

/* Wordmark rendition: one flex child so the gap never splits Masi|Dyn.
   Two-tone is canonical per BRAND_GUIDE — Masi neutral, Dyn blue, never swapped. */
.logo-text {
    white-space: nowrap;
}

.logo-dyn {
    font-weight: 800;
    color: #5b7bd5;
}

/* ---- Fluent 2 Optical Crispness Layer (Non-Destructive: Zero Layout/Theme Changes) ---- */
:root {
    --fluent-specular-top: rgba(255, 255, 255, 0.13);
    --fluent-specular-hover: rgba(255, 255, 255, 0.20);
    --fluent-ease-decelerate: cubic-bezier(0.1, 0.9, 0.2, 1);
    --fluent-shadow-card:
        0 2px 4px rgba(0, 0, 0, 0.24),
        0 10px 24px rgba(0, 0, 0, 0.42),
        inset 0 1px 0 var(--fluent-specular-top);
    --fluent-shadow-card-hover:
        0 4px 8px rgba(0, 0, 0, 0.30),
        0 14px 32px rgba(0, 0, 0, 0.52),
        inset 0 1px 0 var(--fluent-specular-hover);
}

body {
    font-family: "Segoe UI Variable Text", "Segoe UI Variable Display", var(--font-main), -apple-system, BlinkMacSystemFont, sans-serif;
    font-variation-settings: "opsz" 14;
    font-variant-numeric: tabular-nums;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, .hero-title {
    font-family: "Segoe UI Variable Display", "Segoe UI Variable Text", var(--font-main), sans-serif;
    font-variation-settings: "opsz" 32;
}

.glass-nav {
    backdrop-filter: blur(20px) saturate(165%);
    -webkit-backdrop-filter: blur(20px) saturate(165%);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.32), inset 0 -1px 0 rgba(255, 255, 255, 0.08);
}

.glass-card {
    backdrop-filter: blur(20px) saturate(165%);
    -webkit-backdrop-filter: blur(20px) saturate(165%);
    box-shadow: var(--fluent-shadow-card);
    transition:
        transform 180ms var(--fluent-ease-decelerate),
        box-shadow 180ms var(--fluent-ease-decelerate),
        border-color 180ms var(--fluent-ease-decelerate),
        background-color 180ms var(--fluent-ease-decelerate);
}

.glass-card:hover,
.feature-card.float-hover:hover {
    box-shadow: var(--fluent-shadow-card-hover);
}

.btn {
    transition:
        transform 160ms var(--fluent-ease-decelerate),
        box-shadow 160ms var(--fluent-ease-decelerate),
        background-color 160ms var(--fluent-ease-decelerate),
        border-color 160ms var(--fluent-ease-decelerate),
        color 160ms var(--fluent-ease-decelerate);
}

.btn-primary {
    box-shadow:
        0 2px 4px rgba(0, 0, 0, 0.25),
        0 4px 16px rgba(79, 166, 255, 0.32),
        inset 0 1px 0 rgba(255, 255, 255, 0.26);
}

.btn-secondary,
.badge,
.code-font {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10);
}

/* ── 2-Column Hero Landing with Auth on Left & Video Loop on Right ── */
.landing-hero-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 2.5rem;
    align-items: center;
    max-width: 1280px;
    margin: 0 auto;
}

@media (max-width: 960px) {
    .landing-hero-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.auth-panel-card {
    background: rgba(13, 17, 26, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 16px;
    padding: 2.25rem 2rem;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(69, 207, 134, 0.08);
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(69, 207, 134, 0.12);
    border: 1px solid rgba(69, 207, 134, 0.3);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #45cf86;
    margin-bottom: 1rem;
}

.auth-pulse {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #45cf86;
    box-shadow: 0 0 8px #45cf86;
}

.hero-auth-title {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #ffffff;
    line-height: 1.15;
    margin-bottom: 0.5rem;
}

.hero-auth-desc {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

.oauth-buttons-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.oauth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 0.75rem 1.2rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    color: #f8fafc;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.04);
    transition: all 0.2s ease;
    cursor: pointer;
}

.oauth-btn:hover {
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
    color: #ffffff;
}

.oauth-btn-github:hover {
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.oauth-btn-google:hover {
    border-color: rgba(66, 133, 244, 0.4);
    box-shadow: 0 4px 14px rgba(66, 133, 244, 0.2);
}

.oauth-btn-ms:hover {
    border-color: rgba(0, 164, 239, 0.4);
    box-shadow: 0 4px 14px rgba(0, 164, 239, 0.2);
}

.oauth-btn-discord:hover {
    border-color: rgba(88, 101, 242, 0.4);
    box-shadow: 0 4px 14px rgba(88, 101, 242, 0.2);
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.2rem 0;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-divider span {
    padding: 0 10px;
}

.auth-footer-note {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.45;
}

.video-container-frame {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: #07090e;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(59, 130, 246, 0.12);
}

.video-container-frame video {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    object-position: center;
}

.video-audio-toggle {
    position: absolute;
    bottom: 16px;
    right: 16px;
    height: 42px;
    padding: 0 18px;
    border-radius: 8px;
    background: rgba(10, 12, 18, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 600;
    backdrop-filter: blur(8px);
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.5);
    display: inline-flex;
    align-items: center;
    transition: background 0.2s;
}

.video-audio-toggle:hover {
    background: rgba(20, 25, 38, 0.95);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Right workspace sidebar on signed-in home.html */
.sidebar-right {
    border-top: 1px solid var(--color-border);
    background: rgba(11, 13, 20, 0.92);
    padding: 1.25rem var(--gutter);
}

.sidebar-right-inner {
    display: grid;
    gap: 1rem;
}

.sidebar-right-card {
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.02);
}

.sidebar-right-card h3 {
    margin-top: 0.25rem;
    font-size: var(--text-base);
}

.sidebar-right-links {
    list-style: none;
    padding: 0;
    margin: 0.65rem 0 0;
    display: grid;
    gap: 0.35rem;
}

.sidebar-right-links a {
    display: block;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    color: var(--color-text);
    font-size: var(--text-sm);
    text-decoration: none;
}

.sidebar-right-links a:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--color-mint);
}

body:has(#site-sidebar) > .sidebar-right {
    margin-left: 44px;
}

@media (min-width: 78rem) {
    body:has(> .sidebar-right) {
        padding-right: 17rem;
    }
    body:has(#site-sidebar) > .sidebar-right {
        margin-left: 0;
    }
    .sidebar-right {
        position: fixed;
        top: var(--header-h, 4rem);
        right: 0;
        bottom: 0;
        width: 17rem;
        border-top: 0;
        border-left: 1px solid var(--color-border);
        overflow-y: auto;
        z-index: 90;
    }
}

/* Post-login home.html workspace classes (SITE_CONTRACT zero-inline-style compliant) */
.home-video-section {
    padding: 1.5rem 1rem 2.5rem;
}

.home-video-container {
    max-width: 1280px;
    margin: 0 auto;
}

.home-video-eyebrow {
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    color: var(--text-muted);
    margin-bottom: 0.65rem;
}

.home-video-frame {
    position: relative;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: #07090e;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75);
}

.home-video-player {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1280 / 720;
    object-fit: cover;
    object-position: 49.5% 25.7%;
}

.home-cta-block {
    max-width: 820px;
    margin: 2.2rem auto 0;
    text-align: left;
}

.home-cta-headline {
    font-size: clamp(2.2rem, 4.5vw, 3.3rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
    line-height: 1.1;
}

.home-cta-desc {
    margin-top: 0.65rem;
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.home-cta-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin-top: 1.4rem;
}

.home-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
}

.home-card-link {
    text-decoration: none;
    color: inherit;
}

.home-card-green {
    border-top: 3px solid #45cf86;
}

.home-card-blue {
    border-top: 3px solid #38bdf8;
}

.home-card-slate {
    border-top: 3px solid #64748b;
}

.home-card-purple {
    border-top: 3px solid var(--primary-purple);
}

.home-card-gold {
    border-top: 3px solid #eab308;
}

.home-card-orange {
    border-top: 3px solid #f97316;
}

.home-card-sovereign {
    border-top: 3px solid #d4af37;
}

.home-tag-green {
    color: #45cf86;
    font-weight: 700;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
}

.home-tag-blue {
    color: #38bdf8;
    font-weight: 700;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
}

.home-tag-slate {
    color: #94a3b8;
    font-weight: 700;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
}

.home-install-card {
    padding: 2rem;
    border-color: rgba(79, 166, 255, 0.25);
}

.home-install-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

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

.home-install-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.4rem;
    gap: 0.5rem;
}

.home-code-box {
    background: rgba(0, 0, 0, 0.5);
    padding: 0.9rem 1.2rem;
    border-radius: 8px;
    border: 1px solid var(--card-border);
    color: #7ee787;
    user-select: all;
}

.draft-sheet {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    margin: 0;
}






/* MasiDyn / Sovereign blue. Human Fifth Element Sanctuary only, retaining its gold identity. */
html:has(body > .card > section[aria-labelledby="fifth-element-heading"] > .fifth-core) body {
  background: radial-gradient(ellipse at 78% -12%, #203d78, transparent 52%), #071127;
  color: #edf4ff;
}
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) {
  background: linear-gradient(155deg, #142746, #101e38 45%, #0b172c);
  border-color: #354f77; box-sizing: border-box; padding: clamp(1rem, 4vw, 2rem);
  box-shadow: 0 22px 62px #020817a3;
}
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) .eyebrow { color: #f1ca72; }
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) :is(.pillar, .timeline, .box) {
  background: #0b172c; border-color: #354f77; overflow-wrap: anywhere;
}
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) .pill {
  color: #edf4ff; background: #172b4b; border-color: #354f77;
}
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) .fifth-core {
  background: linear-gradient(145deg, #23314a, #0b172c); border-color: #d4af37;
}
body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) a:focus-visible {
  outline: 2px solid #bde3ff; outline-offset: 2px;
}
@media (max-width: 420px) {
  body > .card:has(> section[aria-labelledby="fifth-element-heading"] > .fifth-core) :is(.pillars, .credits-list) { grid-template-columns: minmax(0, 1fr); }
}

/* 18. Consumer Tron Tiers (MiniTrons, UltraTrons, MegaTron Primus · Maximus) */
.tron-tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.35rem;
    margin-top: 1.5rem;
}

.tron-card-mini,
.tron-card-ultra,
.tron-card-mega {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1.65rem;
    border-radius: 14px;
    background: rgba(12, 16, 26, 0.85);
    border: 1px solid var(--color-border);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.tron-card-mini {
    border-top: 3px solid #45cf86;
}

.tron-card-ultra {
    border-top: 3px solid #38bdf8;
}

.tron-card-mega {
    border-top: 3px solid #A16207;
    border-color: rgba(212, 175, 55, 0.35);
    background: linear-gradient(155deg, rgba(92, 58, 33, 0.42), rgba(15, 13, 12, 0.92));
}

.tron-alert-preview {
    margin-top: auto;
    padding: 0.75rem 0.95rem;
    border-radius: 10px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    line-height: 1.5;
    color: #f8fafc;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.tron-card-mega .tron-alert-preview {
    border-color: #D4AF37;
    background: rgba(92, 58, 33, 0.45);
    color: #fef3c7;
}

.home-nav-usage-link {
    color: #fbbf24 !important;
    font-weight: 600 !important;
}

.home-btn-usage-gold {
    border-color: rgba(251, 191, 36, 0.4) !important;
    color: #fbbf24 !important;
}

/* 19. Public Ecosystem Grid & Free Website Hosting (/hosting) --------------- */
.ecosystem-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.35rem;
}

.ecosystem-card {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ecosystem-card .ecosystem-tag {
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--tone, var(--color-blue));
}

.ecosystem-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: auto;
    padding-top: 0.65rem;
}

.hosting-layout {
    display: grid;
    gap: 2rem;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
}

@media (min-width: 58rem) {
    .hosting-layout {
        grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    }
}

.hosting-form input,
.hosting-form select,
.hosting-form textarea {
    width: 100%;
    min-width: 0;
    padding: 0.7rem 0.95rem;
    border: 1px solid var(--color-border-strong);
    border-radius: 12px;
    background: var(--color-surface-sunken);
    color: var(--color-text);
}

.hosting-form select,
.hosting-form input {
    min-height: 46px;
}

.hosting-form textarea {
    min-height: 6.5rem;
    resize: vertical;
}

.hosting-preview-frame {
    width: 100%;
    min-height: 480px;
    border: 1px solid var(--color-border-strong);
    border-radius: 14px;
    background: #080b12;
}

.hosting-sites-list {
    display: grid;
    gap: 0.65rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.hosting-sites-list li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.025);
}

.hosting-site-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    align-items: center;
}

/* 20. Sovereign Remote Computers & Fleet (/nodes) --------------------------- */
.fleet-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
}

.fleet-card {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    padding: 1.35rem;
    border: 1px solid var(--color-border);
    border-radius: 14px;
    background: rgba(12, 16, 26, 0.78);
}

.fleet-card-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.fleet-stat-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    font-size: var(--text-sm);
    color: var(--color-muted);
}

.fleet-stat-row strong {
    color: var(--color-text);
    font-weight: 600;
}

.fleet-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 0.4rem;
}

.fleet-output {
    margin: 0;
    padding: 0.9rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: rgba(6, 9, 16, 0.9);
    color: #dbeafe;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    line-height: 1.5;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.badge-online {
    border-color: rgba(69, 207, 134, 0.45);
    background: rgba(69, 207, 134, 0.14);
    color: var(--color-green);
}

.badge-online::before {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: currentColor;
}

.badge-standby {
    border-color: rgba(251, 191, 36, 0.45);
    background: rgba(251, 191, 36, 0.12);
    color: #fbbf24;
}

.badge-standby::before {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: currentColor;
}



