/* site.css — Swiftly Workspace web surface (WEB01 Phase 01).
   Hand-authored, no framework, no external origins (WEB01 §4). Custom
   properties are the single source of color truth; components read
   tokens, never literals. System-UI face stack — no external fonts. */

:root {
    /* Palette — swiftly-developed.com language */
    --bg: #060b14;
    --bg-raised: #0d1526;
    --bg-card: #162038;
    --border: #1e2e4a;
    --text: #f0f4ff;
    --text-muted: #8b9ec7;
    --accent: #0a84ff;
    --accent-bright: #64d2ff;
    --tone-ok: #2e7d5b;
    --tone-warn: #a3742a;
    --tone-error: #7d2e2e;

    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas,
        monospace;

    --content-width: 46rem;
    --content-width-wide: 68rem; /* marketing pages (Phase 02) */
    --gutter: 1.25rem;

    --motion-dur-quick: 0.2s;
    --motion-dur-reveal: 0.6s;
    --motion-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --reveal-distance: 24px;
    --orb-blue: var(--accent);
    --orb-cyan: var(--accent-bright);
    --orb-violet: #7c3aed; /* the one allowed literal-in-token — no violet in the palette */

    color-scheme: dark;
}

* {
    box-sizing: border-box;
}

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

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

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 1rem;
    line-height: 1.65;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    /* Clip the hero breakout's 50vw scrollbar spill (`hidden` is the
       older-engine fallback). */
    overflow-x: hidden;
    overflow-x: clip;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid var(--border);
    background: rgba(13, 21, 38, 0.88); /* --bg-raised, translucent */
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}

.site-header .inner {
    max-width: var(--content-width-wide);
    margin: 0 auto;
    padding: 0.9rem var(--gutter);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.site-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.25rem 1.2rem;
}

.site-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
}

.site-nav a:hover {
    color: var(--text);
}

.site-nav .nav-login {
    color: var(--text);
    background: var(--accent);
    padding: 0.35rem 0.95rem;
    border-radius: 999px;
    font-weight: 600;
}

.site-nav .nav-login:hover {
    background: var(--accent-bright);
    color: var(--bg);
}

/* Anchor targets scroll clear of the sticky header. */
section[id] {
    scroll-margin-top: 4.5rem;
}

.wordmark {
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.01em;
    color: var(--text);
    text-decoration: none;
}

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

main {
    flex: 1;
    width: 100%;
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 2.5rem var(--gutter) 4rem;
}

main.wide {
    max-width: var(--content-width-wide);
}

h1 {
    font-size: 2rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin: 0 0 0.5rem;
}

h2 {
    font-size: 1.35rem;
    line-height: 1.3;
    margin: 2.2rem 0 0.6rem;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.05rem;
    margin: 1.6rem 0 0.4rem;
    color: var(--accent-bright);
}

p {
    margin: 0.7rem 0;
}

ul,
ol {
    margin: 0.7rem 0;
    padding-left: 1.4rem;
}

li {
    margin: 0.35rem 0;
}

a {
    color: var(--accent-bright);
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

a:hover {
    color: var(--text);
}

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

.doc-meta {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

article.legal h2 {
    border-top: 1px solid var(--border);
    padding-top: 1.4rem;
}

article.legal li,
article.legal p {
    color: var(--text);
}

.notice {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    border-radius: 8px;
    padding: 0.9rem 1.1rem;
    margin: 1.2rem 0;
    color: var(--text);
}

.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.4rem 1.5rem;
    margin: 1.5rem 0;
}

.contact-card p {
    margin: 0.4rem 0;
}

.error-page {
    padding: 2.5rem 0 3.5rem;
}

.error-page .error-code {
    font-family: var(--font-mono);
    font-size: 3rem;
    line-height: 1;
    color: var(--accent);
    margin: 0 0 0.5rem;
}

.error-page h1 {
    margin: 0 0 0.75rem;
}

.error-page .error-reference {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 2rem;
}

.error-page .error-reference code {
    font-family: var(--font-mono);
    word-break: break-all;
}

.section-sub {
    color: var(--text-muted);
    max-width: 38rem;
}

.hero {
    /* Full-bleed breakout: negative inline margins cancel the column,
       the top margin cancels main's 2.5rem padding (flush under the
       header), the gutter padding keeps content off the edges. */
    margin: -2.5rem calc(50% - 50vw) 0;
    padding: 6rem var(--gutter) 4rem;
    text-align: center;
    /* WEB02 Phase 01: containment for the absolutely-positioned orbs. */
    position: relative;
    overflow: hidden;
}

.hero h1 {
    font-size: 2.8rem;
    letter-spacing: -0.03em;
    margin: 0 auto 1rem;
    max-width: 46rem;
}

.hero h1 .dot {
    color: var(--accent);
}

.hero-sub {
    color: var(--text-muted);
    font-size: 1.15rem;
    max-width: 40rem;
    margin: 0 auto 2rem;
}

.hero-note {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 1.6rem;
}

/* Download badges (vendored Apple artwork) */

.badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.9rem;
    margin: 1.2rem 0;
}

.badges img.badge {
    height: 50px;
    width: auto;
    display: block;
}

.features {
    padding: 3rem 0;
    border-top: 1px solid var(--border);
}

.features .section-sub {
    margin-bottom: 2rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
    gap: 1.1rem;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.3rem 1.4rem;
}

.feature-card h3 {
    margin: 0.6rem 0 0.3rem;
    color: var(--text);
}

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

/* Inline Lucide strokes inherit the accent via currentColor. */
.feature-icon {
    width: 40px;
    height: 40px;
    color: var(--accent);
}

.feature-icon svg {
    width: 100%;
    height: 100%;
}

.pricing {
    padding: 3rem 0;
    border-top: 1px solid var(--border);
}

.pricing .section-sub {
    margin-bottom: 2rem;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
    gap: 1.1rem;
    max-width: 70rem;
}

/* Glass chrome; highlighted accent border composes on top. Each card
   is a 5-row subgrid (name/tagline/toggle/price/bullets) so those rows
   align across all cards; no-subgrid engines fall back to auto rows. */
.price-card {
    background: rgba(22, 32, 56, 0.65); /* --bg-card, translucent */
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.5rem 1.6rem;
    box-shadow: 0 12px 40px -18px rgba(10, 132, 255, 0.35); /* --accent, soft glow */
    display: grid;
    grid-row: span 5;
    grid-template-rows: subgrid;
    align-items: start;
}

.price-card.highlighted {
    border-color: var(--accent);
}

.price-card h3 {
    margin: 0 0 0.2rem;
    color: var(--text);
    font-size: 1.2rem;
}

.tier-tagline {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0 0 1.1rem;
}

/* CSS-only monthly/annual toggle: radios before labels/panels, the
   general-sibling combinator drives everything. Works with JS off. */

.price-card input.bill-monthly,
.price-card input.bill-annual {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.billing-toggle {
    display: inline-flex;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.2rem;
    margin-bottom: 1.1rem;
    background: var(--bg-raised);
    /* Subgrid items stretch by default — keep the pill content-width. */
    justify-self: start;
}

.billing-toggle label {
    padding: 0.3rem 0.95rem;
    border-radius: 999px;
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
}

input.bill-monthly:checked ~ .billing-toggle .label-monthly,
input.bill-annual:checked ~ .billing-toggle .label-annual {
    background: var(--accent);
    color: #fff;
}

input.bill-monthly:focus-visible ~ .billing-toggle .label-monthly,
input.bill-annual:focus-visible ~ .billing-toggle .label-annual {
    outline: 2px solid var(--accent-bright);
    outline-offset: 2px;
}

.price {
    display: none;
}

input.bill-monthly:checked ~ .price.price-monthly,
input.bill-annual:checked ~ .price.price-annual {
    display: block;
}

.price .amount {
    font-size: 2.3rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
}

.price .period {
    color: var(--text-muted);
    font-size: 1rem;
    margin-left: 0.15rem;
}

.price-basis {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0.2rem 0 0;
}

.tier-bullets {
    list-style: none;
    padding: 0;
    margin: 1.2rem 0 0;
}

.tier-bullets li {
    padding-left: 1.5rem;
    position: relative;
    color: var(--text);
    font-size: 0.95rem;
}

.tier-bullets li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--accent-bright);
}

.card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    margin-bottom: 0.2rem;
}

.card-head h3 {
    margin: 0;
}

.card-badge {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background: rgba(10, 132, 255, 0.15); /* --accent, tinted pill */
    border: 1px solid rgba(10, 132, 255, 0.4); /* --accent */
    color: var(--accent-bright);
    white-space: nowrap;
}

/* The unpriced teaser card: dashed border; badge fills the toggle
   row's slot; muted em-dash in the always-visible price slot (the base
   `.price` hide targets the toggle-driven pair only). */

.price-card.coming-soon {
    border-style: dashed;
}

/* The static "Coming soon" pill mirrors a toggle label's metrics so
   the pill's height matches the real toggles exactly. */
.billing-toggle .label-static {
    padding: 0.3rem 0.95rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.price.price-coming-soon {
    display: block;
}

.price.price-coming-soon .amount {
    color: var(--text-muted);
}

.tier-bullets-tbd li {
    padding-left: 0;
    color: var(--text-muted);
    font-style: italic;
}

.tier-bullets-tbd li::before {
    content: none;
}

.partners {
    margin-top: 1.8rem;
    color: var(--text-muted);
}

.pricing-footnote {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.closing-cta {
    padding: 3rem 0 1.5rem;
    border-top: 1px solid var(--border);
    text-align: center;
}

.closing-cta .section-sub {
    margin: 0 auto 1.5rem;
}

.cta-contact {
    color: var(--text-muted);
    margin-top: 1.4rem;
}

.site-footer {
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.site-footer .inner {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 1.4rem var(--gutter);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 1.4rem;
}

.site-footer a {
    color: var(--text-muted);
    text-decoration: none;
}

.site-footer a:hover {
    color: var(--text);
    text-decoration: underline;
}

.site-footer .copyright {
    margin-left: auto;
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.6rem;
    }

    main {
        padding-top: 1.6rem;
    }

    .hero {
        /* main's mobile padding-top is 1.6rem — keep the bleed flush. */
        margin-top: -1.6rem;
        padding-top: 3.4rem;
        text-align: left;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .badges,
    .hero .badges {
        justify-content: flex-start;
    }

    .closing-cta {
        text-align: left;
    }

    .closing-cta .badges {
        justify-content: flex-start;
    }

    .site-nav {
        gap: 0.25rem 0.85rem;
    }

    .site-footer .inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-footer .copyright {
        margin-left: 0;
    }

    /* WEB02 §9 — fewer orbs; orb-1's shrink lives in the Phase 01
       mobile block (cascade order, not specificity). */
    .orb-2,
    .orb-3 {
        display: none;
    }
}

.auth {
    padding: 3rem 0 4rem;
    display: flex;
    justify-content: center;
}

.auth-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem 2rem 1.75rem;
    width: 100%;
    max-width: 26rem;
}

.auth-card h1 {
    margin: 0 0 0.35rem;
    font-size: 1.6rem;
}

.auth-sub {
    margin: 0 0 1.5rem;
    color: var(--text-muted);
}

.auth-form .field {
    margin-bottom: 1.1rem;
}

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

.auth-form input {
    width: 100%;
    padding: 0.7rem 0.85rem;
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-family: inherit;
    font-size: 1rem;
    line-height: 1.4;
}

/* Visible focus for pointer users too — both pseudo-classes styled. */
.auth-form input:focus,
.auth-form input:focus-visible {
    outline: 2px solid var(--accent-bright);
    outline-offset: 1px;
    border-color: var(--accent);
}

.auth-form .btn-primary {
    width: 100%;
    margin-top: 0.4rem;
    padding: 0.75rem 1rem;
    background: var(--accent);
    border: 1px solid var(--accent);
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
}

.auth-form .btn-primary:hover {
    background: var(--accent-bright);
    border-color: var(--accent-bright);
    color: var(--bg);
}

.auth-form .btn-primary:focus-visible {
    outline: 2px solid var(--accent-bright);
    outline-offset: 2px;
}

/* Empty swap target occupies nothing; styling lives on .form-error. */
.form-error-region:empty {
    display: none;
}

/* WCAG 1.4.1 — text + glyph + colour; never colour alone. */
.form-error {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    margin: 0 0 1.1rem;
    padding: 0.7rem 0.85rem;
    background: rgba(255, 69, 58, 0.12);
    border: 1px solid #ff453a;
    border-left-width: 3px;
    border-radius: 8px;
    color: var(--text);
    font-size: 0.95rem;
    line-height: 1.5;
}

.form-error-icon {
    flex: 0 0 1.25rem;
    height: 1.25rem;
    margin-top: 0.1rem;
    border-radius: 50%;
    background: #ff453a;
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    line-height: 1.25rem;
    text-align: center;
}

.auth-note {
    margin: 1.4rem 0 0;
    padding-top: 1.2rem;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ===== PARTNER01 Phase 09 — portal vocabulary (§2.8b) ===== */

.auth-card:has(> .portal) {
    max-width: 56rem;
    width: 100%;
}

.auth .auth-card:has(> .portal) {
    margin-inline: auto;
}

.portal h1 {
    margin-top: 0;
}

.portal-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
    margin: 1.1rem 0;
}

.portal-card h2 {
    margin: 0 0 0.7rem;
    font-size: 1.1rem;
}

.portal-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.portal-table th {
    text-align: left;
    color: var(--text-muted);
    font-weight: 600;
    padding: 0.45rem 0.6rem;
    border-bottom: 1px solid var(--border);
}

.portal-table td {
    padding: 0.5rem 0.6rem;
    border-bottom: 1px solid var(--border);
}

.portal-table a {
    color: var(--accent-bright);
}

/* Status badges — always paired with their text label; the tone
   class is never the sole signal. */

.portal-badge {
    display: inline-block;
    padding: 0.1rem 0.6rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    font-size: 0.82rem;
    background: var(--bg-raised);
    color: var(--text);
}

.portal-badge.ok { border-color: var(--tone-ok); }
.portal-badge.warn { border-color: var(--tone-warn); }
.portal-badge.pending { border-color: var(--accent); }
.portal-badge.ended { border-color: var(--tone-error); }
.portal-badge.muted { color: var(--text-muted); }

.portal-notice {
    border: 1px solid var(--border);
    border-left-width: 4px;
    border-radius: 8px;
    padding: 0.6rem 0.85rem;
    background: var(--bg-raised);
    font-size: 0.95rem;
}

.portal-notice.ok { border-left-color: var(--tone-ok); }
.portal-notice.warn { border-left-color: var(--tone-warn); }
.portal-notice.error { border-left-color: var(--tone-error); }
.portal-notice.muted { color: var(--text-muted); }

/* The dashboard's client list (defined since Phase 09 — the class
   shipped in Phase 08 with no definition) */

.portal-client-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.portal-client-list li {
    padding: 0.4rem 0;
    border-bottom: 1px solid var(--border);
}

.portal-price-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.portal-price-block {
    flex: 1 1 18rem;
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.8rem 1rem;
}

.portal-price-block h3 {
    margin: 0 0 0.5rem;
    font-size: 0.95rem;
}

.portal-price-block p {
    margin: 0 0 0.45rem;
    font-size: 0.9rem;
}

.portal-licence-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2rem;
    align-items: flex-end;
}

.portal-licence-form .field-row {
    display: flex;
    gap: 0.8rem;
}

.portal-action {
    display: inline-block;
    text-decoration: none;
}

.portal-danger {
    background: var(--tone-error);
}

/* CSS-only add-client tabs — the .billing-toggle mechanics; works
   with JavaScript disabled. */

.portal-tabs input.tab-create,
.portal-tabs input.tab-link {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.portal-tab-toggle {
    display: inline-flex;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.2rem;
    margin-bottom: 1.1rem;
    background: var(--bg-raised);
}

.portal-tab-toggle label {
    padding: 0.3rem 0.95rem;
    border-radius: 999px;
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
}

input.tab-create:checked ~ .portal-tab-toggle .label-tab-create,
input.tab-link:checked ~ .portal-tab-toggle .label-tab-link {
    background: var(--accent);
    color: #fff;
}

input.tab-create:focus-visible ~ .portal-tab-toggle .label-tab-create,
input.tab-link:focus-visible ~ .portal-tab-toggle .label-tab-link {
    outline: 2px solid var(--accent-bright);
    outline-offset: 2px;
}

.portal-tab-panel {
    display: none;
}

input.tab-create:checked ~ .portal-tab-panel.panel-create,
input.tab-link:checked ~ .portal-tab-panel.panel-link {
    display: block;
}

/* ===== WEB02 Phase 00 — motion foundation ===== */

/* Scroll reveal — hiding lives ONLY under the marker scope site.js
   stamps (§9 no-JS safety), never for reduced-motion visitors. */

html.js-reveal .reveal {
    opacity: 0;
    transform: translateY(var(--reveal-distance));
    transition:
        opacity var(--motion-dur-reveal) var(--motion-ease),
        transform var(--motion-dur-reveal) var(--motion-ease);
}

html.js-reveal .reveal.revealed {
    opacity: 1;
    transform: none;
}

.reveal-stagger > * {
    transition-delay: calc(var(--stagger-index, 0) * 100ms);
}

/* CSP has no unsafe-inline, so stagger indices are assigned
   structurally; children past the eighth share its delay. */
.reveal-stagger > *:nth-child(1) { --stagger-index: 0; }
.reveal-stagger > *:nth-child(2) { --stagger-index: 1; }
.reveal-stagger > *:nth-child(3) { --stagger-index: 2; }
.reveal-stagger > *:nth-child(4) { --stagger-index: 3; }
.reveal-stagger > *:nth-child(5) { --stagger-index: 4; }
.reveal-stagger > *:nth-child(6) { --stagger-index: 5; }
.reveal-stagger > *:nth-child(7) { --stagger-index: 6; }
.reveal-stagger > *:nth-child(n + 8) { --stagger-index: 7; }

.orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.orb-1 {
    width: 640px;
    height: 640px;
    background: radial-gradient(circle at center, var(--orb-blue), transparent 70%);
    filter: blur(90px);
    opacity: 0.22;
    top: -220px;
    left: -80px;
    animation: float-orb-1 22s ease-in-out infinite;
}

.orb-2 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle at center, var(--orb-cyan), transparent 70%);
    filter: blur(70px);
    opacity: 0.18;
    top: -80px;
    right: -40px;
    animation: float-orb-2 17s ease-in-out infinite;
}

.orb-3 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle at center, var(--orb-violet), transparent 70%);
    filter: blur(80px);
    opacity: 0.14;
    bottom: -120px;
    left: calc(50% - 260px);
    animation: float-orb-3 28s ease-in-out infinite;
}

@keyframes float-orb-1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    30% { transform: translate(35px, -45px) scale(1.06); }
    65% { transform: translate(-25px, 25px) scale(0.94); }
}

@keyframes float-orb-2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    45% { transform: translate(-45px, 35px) scale(1.09); }
}

@keyframes float-orb-3 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    35% { transform: translate(25px, -35px) scale(1.04); }
    75% { transform: translate(-35px, 15px) scale(0.96); }
}

/* Glass-card vocabulary — the .site-header treatment, boxed. */

.glass-card {
    background: rgba(22, 32, 56, 0.65); /* --bg-card, translucent */
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: 0 12px 40px -18px rgba(10, 132, 255, 0.35); /* --accent, soft glow */
}

.lift-hover {
    transition:
        transform var(--motion-dur-quick) var(--motion-ease),
        box-shadow var(--motion-dur-quick) var(--motion-ease);
}

.lift-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px -5px rgba(10, 132, 255, 0.3); /* --accent, hover glow */
}

/* Consolidated reduced-motion guard: keyframe consumers nulled,
   reveal forced visible, hover lift static. */

@media (prefers-reduced-motion: reduce) {
    .orb { animation: none !important; }

    html.js-reveal .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .lift-hover,
    .lift-hover:hover {
        transform: none;
        transition: none;
    }
}

/* ===== WEB02 Phase 01 — nav + hero ===== */

/* Nav logo mark: margin, not flex gap (a gap would also split the
   wordmark from its .dot span). */

.wordmark {
    display: inline-flex;
    align-items: center;
}

.nav-logo {
    height: 28px;
    width: 28px;
    border-radius: 7px;
    display: block;
    margin-right: 0.55rem;
}

/* Hero content lifts above the absolutely-positioned orbs. */

.hero > :not(.orb) {
    position: relative;
    z-index: 1;
}

.hero-logo {
    width: 320px;
    max-width: 60vw;
    height: auto;
    margin: 0 auto 1.5rem;
    display: block;
    filter: drop-shadow(0 12px 40px rgba(10, 132, 255, 0.35)); /* --accent, soft glow */
}

.hero-media {
    margin: 3rem auto 0;
    max-width: 56rem;
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 12px 40px -18px rgba(10, 132, 255, 0.35); /* --accent, soft glow */
    overflow: hidden;
}

.hero-media video {
    display: block;
    width: 100%;
    border-radius: inherit;
}

/* Two-treatment reduced-motion video switch (WEB02 Phase 01 §5.1),
   pure CSS, guarded by WEB-63. Selectors stay `.hero-media .hero-*`
   (0-2-0): `.hero-media video` (0-1-1) would outrank a bare-class
   hide, leaving both videos visible. */

.hero-media .hero-video-fallback {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .hero-media .hero-video {
        display: none;
    }

    .hero-media .hero-video-fallback {
        display: block;
    }
}

/* ≤480 px overrides — must sit AFTER the base rules they outrank:
   same specificity, file order decides. */

@media (max-width: 480px) {
    .hero-logo {
        width: 200px;
        margin: 0 0 1rem;
    }

    .orb-1 {
        width: 420px;
        height: 420px;
    }
}

/* ===== WEB02 Phase 02 — homepage static sections ===== */

/* AI-provider strip — every logo flattened to a white silhouette
   (brightness/invert; flattens the ai-google PNG too). No hover:
   nothing in the strip is a link. */

.provider-strip {
    padding: 2.4rem 0 0.6rem;
    text-align: center;
}

.provider-strip-line {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0 0 1.3rem;
}

.provider-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1.4rem 2.4rem;
}

.provider-logo {
    height: 28px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: 0.55;
}

/* Founders teaser — the circular crop is CSS; photos ship uncropped. */

.founders-teaser {
    padding: 3rem 0 1rem;
    border-top: 1px solid var(--border);
    text-align: center;
}

.founders-photos {
    display: flex;
    justify-content: center;
    gap: 0.9rem;
    margin-bottom: 1.1rem;
}

.founder-photo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--border);
}

.founders-headline {
    color: var(--text);
    font-size: 1.35rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 0 0 0.4rem;
}

.founders-line {
    color: var(--text-muted);
    max-width: 38rem;
    margin: 0 auto;
}

/* Merged rule for elements carrying BOTH .reveal + .lift-hover: the
   later transition SHORTHAND would otherwise reset the reveal fade +
   stagger (cascade order). Reveal owns opacity; lift owns
   transform/box-shadow. */

html.js-reveal .reveal.lift-hover {
    transform: none;
    transition:
        opacity var(--motion-dur-reveal) var(--motion-ease),
        transform var(--motion-dur-quick) var(--motion-ease),
        box-shadow var(--motion-dur-quick) var(--motion-ease);
    transition-delay: calc(var(--stagger-index, 0) * 100ms), 0s, 0s;
}

/* Outranks (0-3-1) the Phase 00 nulls, so it needs its own null. */

@media (prefers-reduced-motion: reduce) {
    html.js-reveal .reveal.lift-hover {
        transform: none;
        transition: none;
    }
}

/* ≤480 px — after the base rules it outranks; file order decides. */

@media (max-width: 480px) {
    .provider-logo {
        height: 22px;
    }

    .provider-logos {
        gap: 1rem 1.6rem;
    }

    .founders-teaser {
        text-align: left;
    }

    .founders-photos {
        justify-content: flex-start;
    }
}

/* ===== WEB02 Phase 03 — interactive sections ===== */

/* Visually-hidden utility (D5) — clip-rect: read by AT, never painted. */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ---- AI-chat demo (§6 item 5) — one shared --chat-cycle phase per
   element. Per-element start delays are BANNED (a delay applies only
   before iteration 1); the two typing-dot offsets are the sole
   sanctioned delays. */

.ai-demo-section,
.showcase-section {
    padding: 3rem 0 1rem;
    border-top: 1px solid var(--border);
}

.ai-demo-section .section-sub {
    margin-bottom: 2rem;
}

.ai-demo {
    --chat-cycle: 14s;
    max-width: 40rem;
    margin: 0 auto;
    padding: 1.4rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.chat-user {
    display: flex;
    justify-content: flex-end;
    opacity: 0;
    animation: chat-user-cycle var(--chat-cycle) var(--motion-ease) infinite;
}

.chat-bubble {
    border-radius: 16px;
    padding: 0.55rem 1rem;
    max-width: 80%;
}

.chat-bubble p {
    margin: 0;
    font-size: 0.95rem;
}

.chat-bubble-user {
    background: rgba(10, 132, 255, 0.18); /* --accent, tinted pill */
    border: 1px solid rgba(10, 132, 255, 0.35); /* --accent */
    border-bottom-right-radius: 4px;
}

.chat-bubble-ai {
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-bottom-left-radius: 4px;
}

.chat-avatar {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: var(--text);
    /* --accent → --accent-bright */
    background: linear-gradient(135deg, rgba(10, 132, 255, 0.35), rgba(100, 210, 255, 0.25));
    border: 1px solid var(--border);
}

/* Typing indicator and AI reply stack in one grid cell: the reply
   (always in layout) fixes the height, so nothing below ever jumps. */

.chat-exchange {
    display: grid;
}

.chat-exchange > * {
    grid-area: 1 / 1;
}

.chat-typing,
.chat-ai {
    display: flex;
    gap: 0.6rem;
    opacity: 0;
}

.chat-typing {
    align-items: center;
    align-self: start;
    animation: chat-typing-cycle var(--chat-cycle) var(--motion-ease) infinite;
}

.typing-dots {
    display: flex;
    align-items: center;
    gap: 4px;
}

.typing-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-muted);
    animation: chat-dot-bounce 1.2s ease-in-out infinite;
}

.typing-dot:nth-child(2) { animation-delay: 0.15s; }
.typing-dot:nth-child(3) { animation-delay: 0.3s; }

.chat-ai {
    align-items: flex-start;
    animation: chat-ai-cycle var(--chat-cycle) var(--motion-ease) infinite;
}

.chat-results {
    margin-top: 0.7rem;
    padding-top: 0.7rem;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.chat-result {
    font-size: 0.8rem;
    color: var(--text-muted);
    opacity: 0;
}

.chat-result:nth-child(1) {
    animation: chat-result-1-cycle var(--chat-cycle) var(--motion-ease) infinite;
}

.chat-result:nth-child(2) {
    animation: chat-result-2-cycle var(--chat-cycle) var(--motion-ease) infinite;
}

/* 14 s phase map: in 2–5%, typing 6–17%, reply 17–20%, rows 22–28%,
   HOLD to 92% (the ratified long pause), fade out 92–96%. */

@keyframes chat-user-cycle {
    0%, 2% { opacity: 0; transform: translateX(20px); }
    5% { opacity: 1; transform: translateX(0); }
    92% { opacity: 1; transform: translateX(0); }
    96%, 100% { opacity: 0; transform: translateX(20px); }
}

@keyframes chat-typing-cycle {
    0%, 6% { opacity: 0; }
    8%, 15% { opacity: 1; }
    17%, 100% { opacity: 0; }
}

@keyframes chat-ai-cycle {
    0%, 17% { opacity: 0; transform: translateY(10px); }
    20% { opacity: 1; transform: translateY(0); }
    92% { opacity: 1; transform: translateY(0); }
    96%, 100% { opacity: 0; transform: translateY(10px); }
}

@keyframes chat-result-1-cycle {
    0%, 22% { opacity: 0; }
    24%, 92% { opacity: 1; }
    96%, 100% { opacity: 0; }
}

@keyframes chat-result-2-cycle {
    0%, 26% { opacity: 0; }
    28%, 92% { opacity: 1; }
    96%, 100% { opacity: 0; }
}

@keyframes chat-dot-bounce {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
    30% { transform: translateY(-4px); opacity: 1; }
}

/* Reduced-motion final frame (§9); the display:none rule stays
   single-line (WEB-66/G6). */
@media (prefers-reduced-motion: reduce) {
    .chat-user,
    .chat-typing,
    .chat-ai,
    .chat-result,
    .typing-dot {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        max-height: none !important;
    }

    .chat-typing { display: none; }
}

/* ---- Product showcase (§6 item 6) — no keyframes; rotation is DOM
   state owned by site.js. */

.showcase-section {
    text-align: center;
}

.showcase-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.6rem 0 1.4rem;
}

/* Pill tabs; transitions touch color/background/border only. */
.showcase-tab {
    font: inherit;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    background: transparent;
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.4rem 0.95rem;
    cursor: pointer;
    transition:
        color var(--motion-dur-quick) var(--motion-ease),
        background-color var(--motion-dur-quick) var(--motion-ease),
        border-color var(--motion-dur-quick) var(--motion-ease);
}

.showcase-tab:hover:not(.is-active) {
    color: var(--text);
}

.showcase-tab.is-active {
    color: var(--text);
    background: rgba(240, 244, 255, 0.08); /* --text, subtle fill */
    border-color: var(--border);
}

.showcase-panel {
    margin: 0 auto;
    max-width: 56rem;
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 12px 40px -18px rgba(10, 132, 255, 0.35); /* --accent, soft glow */
}

/* No-JS: panels render stacked in tab order (lazy imgs bound the cost). */
.showcase-panel + .showcase-panel {
    margin-top: 1.2rem;
}

.showcase-panel img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: inherit;
}

/* THE marker gate (§5.5): hiding only under the is-live class
   site.js stamps — no JS, no hiding. Single-line (WEB-67/G8). */
.showcase.is-live .showcase-panel:not(.is-active) { display: none; }

/* ≤480 px — after the base rules it outranks; file order decides. */
@media (max-width: 480px) {
    .ai-demo {
        padding: 1rem;
    }

    .chat-bubble {
        max-width: 88%;
    }

    .showcase-section {
        text-align: left;
    }

    .showcase-tabs {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
    }

    .showcase-tab {
        flex-shrink: 0;
    }
}

/* ===== WEB02 Phase 04 — about page ===== */

/* Eyebrow — the letter-spaced section kicker (generic — reusable). */

.eyebrow {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin: 0 0 0.9rem;
}

/* About + roadmap hero — centered band (.hero-sub is standalone). */

.about-hero,
.roadmap-hero {
    padding: 3.5rem 0 2.5rem;
    text-align: center;
}

.about-hero h1,
.roadmap-hero h1 {
    font-size: 2.6rem;
    letter-spacing: -0.03em;
    margin: 0 auto 1rem;
    max-width: 46rem;
}

/* Founding story — reading measure inside the wide main. */

/* 46 rem measure in a 68 rem main. Keep OUT of the border-top group:
   a divider here paints inset while every sibling spans full width. */
.about-story,
.roadmap-upcoming {
    max-width: 46rem;
    margin: 0 auto;
    padding: 1.5rem 0 2.5rem;
}

.story-p {
    color: var(--text-muted);
    line-height: 1.7;
    margin: 0 0 1.5rem;
}

.timeline {
    border-left: 2px solid var(--border);
    padding-left: 1.5rem;
    margin-top: 2.5rem;
}

.timeline-row {
    position: relative;
    margin-bottom: 2rem;
}

.timeline-row::before {
    content: "";
    position: absolute;
    left: calc(-1.5rem - 5px);
    top: 0.35rem;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
}

.timeline-date {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    margin: 0 0 0.15rem;
}

.timeline-title {
    color: var(--text);
    font-weight: 500;
    margin: 0 0 0.25rem;
}

.timeline-detail {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0;
}

.about-mission,
.about-values,
.about-team,
.roadmap-shipped {
    padding: 2rem 0;
    text-align: center;
}

.about-mission,
.about-team,
.roadmap-shipped {
    border-top: 1px solid var(--border);
}

.about-mission h2 {
    font-size: 1.9rem;
    letter-spacing: -0.02em;
    margin: 0 auto 1rem;
    max-width: 44rem;
}

.mission-body {
    color: var(--text-muted);
    line-height: 1.7;
    max-width: 44rem;
    margin: 0 auto;
}

.values-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.2rem;
    margin-top: 1.8rem;
    text-align: left;
}

@media (min-width: 768px) {
    .values-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.value-card {
    border-left: 3px solid var(--accent);
    padding: 1.4rem;
}

.value-glyph {
    font-size: 1.75rem;
    display: block;
    margin-bottom: 0.75rem;
}

.value-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* Team — two centered cards; the circular crop is CSS, not an asset. */

.team-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.4rem;
    margin-top: 1.8rem;
}

.team-card {
    width: 20rem;
    max-width: 100%;
    padding: 1.6rem;
    text-align: center;
}

.team-photo {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 1rem;
    border: 1px solid var(--border);
    display: block;
}

.team-role {
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0 0 0.8rem;
}

.team-bio {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.6;
    margin: 0 0 1rem;
}

.team-linkedin,
.founders-link {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}

.team-linkedin:hover,
.founders-link:hover {
    color: var(--accent-bright);
    text-decoration: underline;
}

.founders-link {
    display: inline-block;
    margin-top: 0.9rem;
}

/* ≤480 px — after the base rules it outranks; file order decides. */

@media (max-width: 480px) {
    .about-hero,
    .about-mission,
    .about-values,
    .about-team,
    .roadmap-hero,
    .roadmap-shipped {
        text-align: left;
    }

    .team-grid {
        justify-content: flex-start;
    }

    .team-card {
        width: 100%;
    }
}

/* ===== WEB03 Phase 00 — roadmap page. Everything else reuses the
   about-page + portal-badge vocabularies above. ===== */

.roadmap-disclaimer {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0.6rem 0 0;
}

.roadmap-pill {
    margin-left: 0.6rem;
}

/* Phase 01 homepage teaser. The reading measure is NOT optional: `/` sets
   main.wide (68 rem), and without it the left rail stretches the full
   width and reads as broken. Not centred — a centred band fights a rail. */
.roadmap-teaser {
    padding: 3rem 0 1rem;
    max-width: 46rem;
    margin: 0 auto;
}

/* Author display rules outrank the UA [hidden] default, so assert
   it once with !important (scripts toggle el.hidden, never style). */
[hidden] {
    display: none !important;
}
