/* =========================================================================
   Chaosware — design system
   Dark-only. Monochrome. Right angles only. JetBrains Mono throughout.
   All theming flows through the custom properties below.
   ========================================================================= */

/* ---------- Tokens ---------- */
:root {
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

    --container: 1200px;

    /* No curves: every radius collapses to a right angle. */
    --radius-sm: 0;
    --radius: 0;
    --radius-lg: 0;
    --radius-xl: 0;

    --header-h: 64px;

    /* A solid light tone where a gradient used to be. */
    --grad: #ededed;

    --ease: cubic-bezier(.22, .61, .36, 1);
    --dur: .2s;

    /* Single dark, grayscale palette. A soft dark grey rather than pure black,
       which is easier on the eye. */
    --bg: #16181d;
    --bg-1: #1c1f25;
    --bg-2: #24272e;
    --bg-3: #2c3038;
    --border: rgba(255, 255, 255, .12);
    --border-strong: rgba(255, 255, 255, .24);
    --text: #e9ebef;
    --muted: #a6abb6;
    --faint: #7a808c;
    --brand: #d4d4d4;
    --brand-2: #c9c9c9;
    --brand-3: #8f8f8f;
    --brand-soft: rgba(255, 255, 255, .07);
    --ring: rgba(255, 255, 255, .38);
    --code-bg: #101216;
    --code-gutter: rgba(255, 255, 255, .07);
    --shadow: 0 24px 70px -28px rgba(0, 0, 0, .7);
    --grid-line: rgba(255, 255, 255, .05);
    --topnav-scroll: rgba(22, 24, 29, .85);
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }

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

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.7;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

h1, h2, h3, h4, h5 {
    margin: 0 0 .5em;
    line-height: 1.18;
    letter-spacing: -.03em;
    font-weight: 700;
}
p { margin: 0 0 1rem; }

::selection { background: #ededed; color: #000; }

:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 0;
}

/* Blazor's FocusOnNavigate focuses the h1; do not draw a ring around it. */
[tabindex="-1"]:focus,
[tabindex="-1"]:focus-visible { outline: none; }

/* Scrollbar */
* { scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb { background: var(--border-strong); }

/* ---------- Layout ---------- */
.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 24px;
}
.container-wide { max-width: 1400px; }

.section { padding: clamp(56px, 8vw, 112px) 0; position: relative; }
.section-tight { padding: clamp(40px, 5vw, 72px) 0; }
.section-alt { background: var(--bg-1); border-block: 1px solid var(--border); }

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

/* ---------- Typography helpers ---------- */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--brand-2);
}
.gradient-text { color: #fff; }
.lead { font-size: clamp(1rem, 1.5vw, 1.2rem); color: var(--muted); line-height: 1.7; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.mono { font-family: var(--font-mono); }
.center { text-align: center; }
.section-head { max-width: 720px; margin-bottom: clamp(32px, 4vw, 56px); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.5rem); }
.section-head p { font-size: 1.02rem; color: var(--muted); margin-bottom: 0; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    padding: .7rem 1.2rem;
    border-radius: 0;
    border: 1px solid transparent;
    font-size: .9rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    white-space: nowrap;
    transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
        border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 1.1em; height: 1.1em; }

.btn-primary {
    background: #ededed;
    color: #0a0a0a;
    border-color: #ededed;
    font-weight: 700;
}
.btn-primary:hover { background: #fff; border-color: #fff; }

.btn-secondary {
    background: var(--bg-2);
    border-color: var(--border-strong);
    color: var(--text);
}
.btn-secondary:hover { background: var(--bg-3); border-color: #9a9a9a; }

.btn-ghost { background: transparent; color: var(--text); }
.btn-ghost:hover { background: var(--bg-2); }

.btn-outline { background: transparent; border-color: var(--border-strong); color: var(--text); }
.btn-outline:hover { border-color: #d4d4d4; background: var(--bg-2); }

.btn-lg { padding: .9rem 1.6rem; font-size: .98rem; }
.btn-sm { padding: .5rem .9rem; font-size: .82rem; }
.btn-block { width: 100%; }

.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }

/* ---------- Pills / badges ---------- */
.pill {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .32rem .7rem;
    border-radius: 0;
    border: 1px solid var(--border-strong);
    background: var(--bg-2);
    font-size: .74rem;
    font-weight: 600;
    color: var(--muted);
    line-height: 1;
}
.pill .dot { width: 7px; height: 7px; background: var(--brand-2); }
.pill-brand { color: var(--text); border-color: var(--border-strong); background: var(--bg-2); }
.pill-amber { color: var(--text); border-color: var(--border-strong); background: var(--bg-2); }

.tag {
    display: inline-block;
    padding: .18rem .5rem;
    background: var(--bg-3);
    border: 1px solid var(--border);
    font-size: .7rem;
    font-weight: 500;
    color: var(--muted);
    font-family: var(--font-mono);
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    display: flex;
    align-items: center;
    border-bottom: 1px solid transparent;
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease), backdrop-filter var(--dur) var(--ease);
}
.site-header.is-scrolled {
    background: var(--topnav-scroll);
    backdrop-filter: saturate(120%) blur(14px);
    -webkit-backdrop-filter: saturate(120%) blur(14px);
    border-bottom-color: var(--border);
}
.nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 24px;
}
.brand { display: flex; align-items: center; gap: .6rem; font-weight: 700; font-size: 1.05rem; letter-spacing: -.03em; }
.brand svg, .brand img { width: 30px; height: 30px; }
.brand .brand-dot { color: var(--brand-2); }

.nav-links { display: flex; align-items: center; gap: .25rem; margin-left: 1rem; }
.nav-links a {
    padding: .5rem .8rem;
    font-size: .88rem;
    font-weight: 500;
    color: var(--muted);
    transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.nav-links a:hover { color: var(--text); background: var(--bg-2); }
.nav-links a.active { color: var(--text); }

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

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 0;
    border: 1px solid var(--border);
    background: var(--bg-2);
    cursor: pointer;
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.icon-btn:hover { background: var(--bg-3); border-color: var(--border-strong); }
.icon-btn svg { width: 18px; height: 18px; }

.nav-toggle { display: none; }

/* Mobile nav */
.mobile-nav {
    display: none;
    position: fixed;
    inset: var(--header-h) 0 0 0;
    z-index: 99;
    background: var(--bg);
    padding: 1.5rem 24px;
    overflow-y: auto;
    border-top: 1px solid var(--border);
}
.mobile-nav.open { display: block; animation: fade-in .2s var(--ease); }
.mobile-nav a {
    display: block;
    padding: .9rem .4rem;
    border-bottom: 1px solid var(--border);
    font-size: 1rem;
    font-weight: 600;
}
.mobile-nav .btn-row { margin-top: 1.5rem; }
.mobile-nav .btn { width: 100%; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(56px, 9vw, 120px) 0 clamp(48px, 7vw, 96px); overflow: hidden; }
.hero-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: radial-gradient(60% 55% at 50% -5%, rgba(255, 255, 255, .05), transparent 70%);
}
.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 20%, #000 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 20%, #000 30%, transparent 75%);
}
.hero-inner { max-width: 860px; margin-inline: auto; text-align: center; }
.hero h1 {
    font-size: clamp(2.1rem, 5.6vw, 4rem);
    font-weight: 700;
    letter-spacing: -.05em;
    margin-bottom: 1.1rem;
}
.hero .lead { max-width: 660px; margin-inline: auto; font-size: clamp(1rem, 1.8vw, 1.25rem); }
.hero .btn-row { justify-content: center; margin-top: 2rem; }
.hero-note { margin-top: 1.25rem; font-size: .84rem; color: var(--faint); }
.hero-note code { font-family: var(--font-mono); color: var(--muted); }

.hero-split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.hero-split > * { min-width: 0; }
.hero-split h1 { font-size: clamp(1.8rem, 3.6vw, 2.7rem); }
.hero-split .nowrap { white-space: nowrap; }
.hero-split .hero-inner { text-align: left; max-width: none; }
.hero-split .hero-inner .lead { margin-inline: 0; }
.hero-split .btn-row { justify-content: flex-start; }

/* ---------- Cards & grids ---------- */
.grid { display: grid; gap: 20px; }
/* Let grid children shrink below their content width so wide children scroll instead. */
.grid > * { min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.grid-auto-sm { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

.card {
    position: relative;
    padding: 1.5rem;
    border-radius: 0;
    border: 1px solid var(--border);
    background: var(--bg-1);
    transition: transform var(--dur) var(--ease), border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.card:hover { transform: translateY(-2px); border-color: var(--border-strong); background: var(--bg-2); }
.card h3 { font-size: 1.05rem; margin-bottom: .5rem; }
.card p { color: var(--muted); font-size: .9rem; margin-bottom: 0; }
.card-link { display: block; }

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: var(--bg-2);
    border: 1px solid var(--border);
    color: var(--text);
    margin-bottom: 1rem;
}
.feature-icon svg { width: 22px; height: 22px; }

/* Border highlight card */
.card-gradient::before {
    content: "";
    position: absolute;
    inset: 0;
    padding: 1px;
    background: var(--grad);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity var(--dur) var(--ease);
    pointer-events: none;
}
.card-gradient:hover::before { opacity: .7; }

/* Project card */
.project-card { display: flex; flex-direction: column; gap: .35rem; }
.project-card .project-top { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .4rem; }
.project-card h3 { font-family: var(--font-mono); font-size: .95rem; letter-spacing: -.02em; margin: 0; }
.project-card .stars { display: inline-flex; align-items: center; gap: .3rem; font-size: .78rem; color: var(--muted); }
.project-card .lang { display: inline-flex; align-items: center; gap: .4rem; font-size: .74rem; color: var(--faint); }
.project-card .lang .dot { width: 8px; height: 8px; background: var(--brand-2); }
.project-card p { font-size: .86rem; flex: 1; }
.project-card .tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .5rem; }

/* ---------- Code ---------- */
.code {
    border-radius: 0;
    border: 1px solid var(--border);
    background: var(--code-bg);
    overflow: hidden;
    box-shadow: var(--shadow);
    color: #abb2bf;
    font-family: var(--font-mono);
}
.code-tabs {
    display: flex;
    align-items: center;
    gap: .25rem;
    padding: .5rem .6rem;
    border-bottom: 1px solid var(--code-gutter);
    background: rgba(255, 255, 255, .02);
    overflow-x: auto;
}
.code-tab {
    padding: .4rem .8rem;
    border-radius: 0;
    border: 1px solid transparent;
    background: transparent;
    color: #8f8f8f;
    font-family: var(--font-sans);
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.code-tab:hover { color: #e8e8e8; }
.code-tab.active { color: #fff; background: rgba(255, 255, 255, .07); border-color: rgba(255, 255, 255, .12); }
.code-copy {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .7rem;
    border-radius: 0;
    border: 1px solid rgba(255, 255, 255, .12);
    background: transparent;
    color: #8f8f8f;
    font-size: .74rem;
    font-weight: 600;
    cursor: pointer;
    transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.code-copy:hover { color: #fff; background: rgba(255, 255, 255, .07); }
.code-copy svg { width: 14px; height: 14px; }
.code pre {
    margin: 0;
    padding: 1.15rem 1.3rem;
    overflow-x: auto;
    font-size: .84rem;
    line-height: 1.75;
    tab-size: 4;
}
.code pre code { font-family: inherit; }

/* Inline code */
.code-inline, code:not([class]) {
    font-family: var(--font-mono);
    font-size: .88em;
    padding: .14em .4em;
    border-radius: 0;
    background: var(--bg-2);
    border: 1px solid var(--border);
    color: #56b6c2;
}

/* Syntax tokens — a dark-theme palette (One Dark). Only the code blocks are
   coloured; the rest of the site stays monochrome. */
.tok-com { color: #7f848e; font-style: italic; }
.tok-str { color: #98c379; }
.tok-key { color: #c678dd; }
.tok-num { color: #d19a66; }
.tok-fn { color: #61afef; }
.tok-type { color: #e5c07b; }
.tok-op { color: #56b6c2; }
.tok-attr { color: #e06c75; }

/* Terminal / install line */
.install {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .8rem 1rem;
    border-radius: 0;
    border: 1px solid var(--border);
    background: var(--code-bg);
    color: #c8ccd4;
    font-family: var(--font-mono);
    font-size: .86rem;
}
.install .prompt { color: #98c379; user-select: none; }
.install-cmd {
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    white-space: nowrap;
    background: none;
    border: none;
    padding: 0;
    color: inherit;
    font-family: inherit;
    font-size: inherit;
}
.install-copy { flex: none; margin-left: 0; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 0; }
table.data { width: 100%; border-collapse: collapse; font-size: .86rem; }
table.data th, table.data td { padding: .8rem 1.05rem; text-align: left; border-bottom: 1px solid var(--border); }
table.data thead th { background: var(--bg-2); font-weight: 700; font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
table.data tbody tr:last-child td { border-bottom: none; }
table.data tbody tr:hover { background: var(--bg-1); }
table.data code { font-family: var(--font-mono); font-size: .86em; color: var(--text); }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 0; overflow: hidden; }
.stat { background: var(--bg-1); padding: 1.6rem 1.4rem; text-align: center; }
.stat .value { font-size: clamp(1.5rem, 2.8vw, 2.1rem); font-weight: 700; letter-spacing: -.04em; color: #fff; }
.stat .label { font-size: .8rem; color: var(--muted); margin-top: .2rem; }

/* ---------- Support tiers ---------- */
.tier { display: flex; flex-direction: column; }
.tier.featured { border-color: var(--border-strong); background: var(--bg-2); }
.tier .tier-price { font-size: 2rem; font-weight: 700; letter-spacing: -.04em; }
.tier .tier-price span { font-size: .85rem; font-weight: 500; color: var(--muted); }
.tier ul { list-style: none; margin: 1.25rem 0 1.5rem; padding: 0; display: grid; gap: .6rem; }
.tier li { display: flex; gap: .6rem; align-items: flex-start; font-size: .87rem; color: var(--muted); }
.tier li svg { width: 18px; height: 18px; flex: none; color: var(--text); margin-top: .2rem; }
.tier .btn { margin-top: auto; }

/* ---------- Logos / marquee ---------- */
.logo-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 1.5rem 2.75rem; justify-content: center; opacity: .85; }
.logo-strip .logo-item { font-weight: 600; font-size: 1rem; color: var(--faint); letter-spacing: -.02em; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; gap: 1.25rem; }
.step { position: relative; padding-left: 3.25rem; }
.step::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 2.25rem;
    height: 2.25rem;
    display: grid;
    place-items: center;
    font-weight: 700;
    font-size: .9rem;
    color: #0a0a0a;
    background: #ededed;
}
.step h3 { font-size: 1rem; margin-bottom: .3rem; }
.step p { color: var(--muted); margin-bottom: .6rem; }

/* ---------- CTA banner ---------- */
.cta {
    position: relative;
    overflow: hidden;
    border-radius: 0;
    border: 1px solid var(--border);
    background: var(--bg-1);
    padding: clamp(2.5rem, 5vw, 4rem);
    text-align: center;
}
.cta::before {
    content: "";
    position: absolute;
    inset: -40% 20% auto;
    height: 70%;
    background: radial-gradient(50% 100% at 50% 0%, rgba(255, 255, 255, .05), transparent 70%);
    pointer-events: none;
}
.cta h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); position: relative; }
.cta p { color: var(--muted); max-width: 560px; margin-inline: auto; margin-bottom: 1.5rem; position: relative; }
.cta .btn-row { justify-content: center; position: relative; }

/* ---------- Prose (docs / blog) ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.5rem; margin-top: 2.5rem; }
.prose h3 { font-size: 1.15rem; margin-top: 1.9rem; }
.prose p, .prose li { color: var(--muted); }
.prose a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li { margin-bottom: .4rem; }
.prose blockquote { margin: 1.5rem 0; padding: .75rem 1.25rem; border-left: 2px solid var(--border-strong); background: var(--bg-1); color: var(--muted); }
.prose hr { border: none; border-top: 1px solid var(--border); margin: 2.5rem 0; }
.prose img { border-radius: 0; border: 1px solid var(--border); }

/* ---------- Forms ---------- */
.form { display: grid; gap: 1.1rem; }
.field { display: grid; gap: .4rem; }
.field label { font-size: .82rem; font-weight: 600; }
.field input, .field textarea, .field select {
    width: 100%;
    padding: .7rem .85rem;
    border-radius: 0;
    border: 1px solid var(--border-strong);
    background: var(--bg-1);
    color: var(--text);
    font: inherit;
    transition: border-color var(--dur) var(--ease);
}
.field input:focus, .field textarea:focus, .field select:focus {
    outline: none;
    border-color: #fff;
}
.field textarea { min-height: 140px; resize: vertical; }
.form-status { font-size: .86rem; color: var(--text); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg-1); padding: clamp(48px, 6vw, 72px) 0 2rem; }
.footer-top { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 2.5rem 2rem; }
.footer-brand p { color: var(--muted); font-size: .87rem; max-width: 320px; margin-top: 1rem; }
.footer-col h4 { font-size: .74rem; text-transform: uppercase; letter-spacing: .14em; color: var(--faint); margin-bottom: 1rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.footer-col a { color: var(--muted); font-size: .87rem; transition: color var(--dur) var(--ease); }
.footer-col a:hover { color: #fff; }
.footer-bottom {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    color: var(--faint);
    font-size: .8rem;
}
.social { display: flex; gap: .6rem; }
.social a { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 0; border: 1px solid var(--border); color: var(--muted); transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease), background var(--dur) var(--ease); }
.social a:hover { color: #fff; border-color: var(--border-strong); background: var(--bg-2); }
.social svg { width: 17px; height: 17px; }

/* ---------- Page hero (subpages) ---------- */
.page-hero { position: relative; padding: clamp(48px, 7vw, 88px) 0 clamp(28px, 4vw, 48px); border-bottom: 1px solid var(--border); overflow: hidden; }
.page-hero::before {
    content: "";
    position: absolute;
    inset: -60% 40% auto;
    height: 80%;
    background: radial-gradient(50% 100% at 50% 0%, rgba(255, 255, 255, .05), transparent 70%);
    pointer-events: none;
}
.page-hero .breadcrumb { font-size: .8rem; color: var(--faint); margin-bottom: 1rem; position: relative; }
.page-hero .breadcrumb a { color: var(--muted); }
.page-hero .breadcrumb a:hover { color: #fff; }
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.9rem); position: relative; margin-bottom: .75rem; }
.page-hero p { font-size: 1.02rem; color: var(--muted); max-width: 720px; position: relative; margin-bottom: 0; }

/* ---------- Misc ---------- */
.divider { height: 1px; background: var(--border); border: none; margin: 0; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.split > * { min-width: 0; }
.split.reverse .split-media { order: 2; }
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: .7rem; }
.checklist li { display: flex; gap: .65rem; align-items: flex-start; color: var(--muted); }
.checklist svg { width: 18px; height: 18px; flex: none; color: #fff; margin-top: .22rem; }

.callout {
    display: flex;
    gap: .9rem;
    padding: 1.1rem 1.25rem;
    border: 1px solid var(--border);
    background: var(--bg-1);
}
.callout h4 { margin-bottom: .25rem; font-size: .95rem; }
.callout p { margin-bottom: 0; color: var(--muted); font-size: .88rem; }

.anchor-offset { scroll-margin-top: calc(var(--header-h) + 20px); }

/* ---------- FAQ / details ---------- */
.faq {
    border: 1px solid var(--border);
    background: var(--bg-1);
    padding: 1rem 1.25rem;
    margin-bottom: .75rem;
}
.faq summary {
    cursor: pointer;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--text); font-weight: 700; font-size: 1.2rem; line-height: 1; }
.faq[open] summary::after { content: "−"; }
.faq p { margin: .9rem 0 0; color: var(--muted); }
.faq a { color: #fff; }

/* ---------- Color swatches ---------- */
.swatch { height: 84px; border: 1px solid var(--border); margin-bottom: 1rem; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .55s var(--ease), transform .55s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Boot / loading ---------- */
.boot { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 1.4rem; color: var(--muted); }
.boot-mark { animation: float 3s var(--ease) infinite; }
.boot-bar { width: 200px; height: 4px; background: var(--bg-3); overflow: hidden; }
.boot-bar span { display: block; height: 100%; width: 40%; background: #ededed; animation: slide 1.2s var(--ease) infinite; }
.boot-text { font-size: .86rem; }
@keyframes slide { 0% { transform: translateX(-120%); } 100% { transform: translateX(320%); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ---------- Error UI ---------- */
#blazor-error-ui {
    display: none;
    position: fixed;
    inset: auto 0 0 0;
    z-index: 1000;
    padding: .85rem 1.25rem;
    background: #1a1a1a;
    color: #ededed;
    border-top: 1px solid var(--border-strong);
    box-shadow: 0 -8px 30px -12px rgba(0, 0, 0, .8);
    font-size: .88rem;
    align-items: center;
    gap: 1rem;
}
#blazor-error-ui .reload { color: #fff; text-decoration: underline; }
#blazor-error-ui .dismiss { background: none; border: none; cursor: pointer; margin-left: auto; }
.error-boundary { padding: 2rem; text-align: center; }

/* Utilities */
.mt-0 { margin-top: 0; } .mt-2 { margin-top: .75rem; } .mt-4 { margin-top: 1.5rem; } .mt-6 { margin-top: 2.25rem; }
.mb-0 { margin-bottom: 0; } .mb-2 { margin-bottom: .75rem; } .mb-4 { margin-bottom: 1.5rem; } .mb-6 { margin-bottom: 2.25rem; }
.flex { display: flex; } .items-center { align-items: center; } .justify-between { justify-content: space-between; }
.gap-2 { gap: .5rem; } .gap-3 { gap: .75rem; } .gap-4 { gap: 1rem; }
.wrap { flex-wrap: wrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.max-w-prose { max-width: 720px; }

/* ---------- Docs ---------- */
.docs {
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    gap: clamp(2rem, 4vw, 4rem);
    padding-block: clamp(2rem, 4vw, 3.5rem) clamp(3rem, 6vw, 5rem);
}
.docs-sidebar {
    position: sticky;
    top: calc(var(--header-h) + 24px);
    align-self: start;
    max-height: calc(100vh - var(--header-h) - 48px);
    overflow-y: auto;
}
.docs-badge { margin-bottom: 1.25rem; }
.docs-mobile-select { display: none; }
.docs-nav-group { margin-bottom: 1.5rem; }
.docs-nav-group h4 {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--faint);
    margin: 0 0 .6rem;
}
.docs-nav-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; }
.docs-nav-group a {
    display: block;
    padding: .38rem .7rem;
    font-size: .86rem;
    color: var(--muted);
    border-left: 2px solid transparent;
    transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.docs-nav-group a:hover { color: var(--text); background: var(--bg-2); }
.docs-nav-group a.active { color: #fff; border-left-color: #ededed; background: var(--bg-2); }

.docs-main { min-width: 0; }
.docs-article { max-width: 780px; }
.docs-article > h1:first-child { margin-top: 0; }
.docs-article section { margin-bottom: 2.5rem; }
.docs-article .code { margin-block: 1rem 1.75rem; }
.docs-article .table-wrap { margin-block: 1rem 1.75rem; }
.docs-article h2 { font-size: 1.45rem; margin-top: 2.4rem; }
.docs-article h3 { font-size: 1.1rem; margin-top: 1.8rem; }

.docs-pager {
    display: flex;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    max-width: 780px;
}
.docs-pager-link {
    display: grid;
    gap: .2rem;
    padding: .75rem 1rem;
    border: 1px solid var(--border);
    background: var(--bg-1);
    min-width: 0;
    transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.docs-pager-link:hover { border-color: var(--border-strong); background: var(--bg-2); }
.docs-pager-link span:last-child { font-weight: 600; color: var(--text); }
.docs-pager-link.next { text-align: right; margin-left: auto; }

@media (max-width: 980px) {
    .docs { grid-template-columns: 1fr; gap: 1.5rem; }
    .docs-sidebar { position: static; max-height: none; overflow: visible; }
    .docs-nav { display: none; }
    .docs-mobile-select {
        display: block;
        width: 100%;
        padding: .7rem .85rem;
        background: var(--bg-1);
        border: 1px solid var(--border-strong);
        color: var(--text);
        font: inherit;
    }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .hero-split { grid-template-columns: 1fr; }
    .stats { grid-template-columns: repeat(2, 1fr); }
    .footer-top { grid-template-columns: 1fr 1fr; }
    .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
    .nav-links { display: none; }
    .nav-toggle { display: inline-flex; }
    .nav-actions .hide-sm { display: none; }
    .split { grid-template-columns: 1fr; }
    .split.reverse .split-media { order: 0; }
}
@media (max-width: 640px) {
    .container, .nav { padding-inline: 18px; }
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
    .stats { grid-template-columns: 1fr 1fr; }
    .footer-top { grid-template-columns: 1fr; }
    .card { padding: 1.25rem; }
}
