/* MAP
 * Direction [directii 50297-A, adapted]: cold blue-black base (light: cold near-white), accent family fixed by the brief
 *   (violet to cyan gradient, used only on the hero word, primary buttons and step numbers), geometric system sans,
 *   large title scale, visible precise grid with cells of different sizes, the order form owns the first screen.
 *   Why: an engineering studio that sells "evidence first" should look measured: rulers, coordinates, thin borders.
 *   Own graphic element: the measured grid (hairline background grid plus mono coordinates on every section).
 * §1 tokens: dark base, light by system or toggle
 * §2 base elements, type, links, focus
 * §3 layout: container, sections, grid backdrop
 * §4 header, navigation, theme toggle
 * §5 buttons, fields, forms (order form, lead form, states)
 * §6 cards, bento, lists, tags, steps, ladder
 * §7 page parts: hero, page head, FAQ, CTA band, prose, footer
 * §8 motion and reduced motion
 * §9 responsive
 */

/* §1 Tokens. Dark is the base; light comes from the system or from the stored choice. */
:root {
  --bg: #0c1020;
  --surface: #141a2e;
  --surface-2: #10152a;
  --border: #5f6a8e;
  --border-soft: #2b3352;
  --border-strong: #8b94ae;
  --text: #e6e9f4;
  --text-2: #a9b1c9;
  --text-3: #8b94ae;
  --accent: #b9a3ff;
  --accent-2: #67e3f5;
  --grad: linear-gradient(100deg, #a78bfa 0%, #67e3f5 100%);
  --grad-text: linear-gradient(100deg, #c4b5fd 0%, #67e3f5 90%);
  --on-accent: #0c1020;
  --accent-soft: rgba(167, 139, 250, 0.12);
  --grid-line: rgba(139, 148, 174, 0.09);
  --ok: #4ade80;
  --ok-soft: rgba(74, 222, 128, 0.12);
  --danger: #fb7185;
  --danger-soft: rgba(251, 113, 133, 0.12);
  --band: #070a16;
  --on-band: #e6e9f4;
  --shadow: 0 1px 0 rgba(0, 0, 0, 0.4), 0 12px 32px -18px rgba(0, 0, 0, 0.7);
  --font-display: "Avenir Next", Avenir, "Futura PT", Futura, "Century Gothic", "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --font-body: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "Cascadia Mono", "SF Mono", Consolas, "Liberation Mono", monospace;
  --radius: 6px;
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --fast: 160ms;
  --slow: 420ms;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { color-scheme: dark; }
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #eef1f7;
    --surface: #f8f9fc;
    --surface-2: #e3e7f0;
    --border: #7c86a2;
    --border-soft: #c9cfdd;
    --border-strong: #454d66;
    --text: #161b2e;
    --text-2: #454d66;
    --text-3: #5b6480;
    --accent: #5b21b6;
    --accent-2: #0e7490;
    --grad: linear-gradient(100deg, #6d28d9 0%, #0e7490 100%);
    --grad-text: linear-gradient(100deg, #6d28d9 0%, #0e7490 90%);
    --on-accent: #f6f7fb;
    --accent-soft: rgba(109, 40, 217, 0.08);
    --grid-line: rgba(69, 77, 102, 0.08);
    --ok: #15803d;
    --ok-soft: rgba(21, 128, 61, 0.1);
    --danger: #be123c;
    --danger-soft: rgba(190, 18, 60, 0.08);
    --band: #161b2e;
    --on-band: #eef1f7;
    --shadow: 0 1px 0 rgba(22, 27, 46, 0.06), 0 12px 32px -20px rgba(22, 27, 46, 0.35);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #eef1f7;
  --surface: #f8f9fc;
  --surface-2: #e3e7f0;
  --border: #7c86a2;
  --border-soft: #c9cfdd;
  --border-strong: #454d66;
  --text: #161b2e;
  --text-2: #454d66;
  --text-3: #5b6480;
  --accent: #5b21b6;
  --accent-2: #0e7490;
  --grad: linear-gradient(100deg, #6d28d9 0%, #0e7490 100%);
  --grad-text: linear-gradient(100deg, #6d28d9 0%, #0e7490 90%);
  --on-accent: #f6f7fb;
  --accent-soft: rgba(109, 40, 217, 0.08);
  --grid-line: rgba(69, 77, 102, 0.08);
  --ok: #15803d;
  --ok-soft: rgba(21, 128, 61, 0.1);
  --danger: #be123c;
  --danger-soft: rgba(190, 18, 60, 0.08);
  --band: #161b2e;
  --on-band: #eef1f7;
  --shadow: 0 1px 0 rgba(22, 27, 46, 0.06), 0 12px 32px -20px rgba(22, 27, 46, 0.35);
  color-scheme: light;
}
:root[data-theme="dark"] { color-scheme: dark; }

/* §2 Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1.0625rem/1.6 var(--font-body);
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--text); margin: 0 0 0.5em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.375rem, 6.2vw, 5.25rem); line-height: 1.02; font-weight: 700; letter-spacing: -0.035em; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.75rem); line-height: 1.1; font-weight: 700; }
h3 { font-size: 1.25rem; line-height: 1.25; font-weight: 650; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.25em; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--accent); color: var(--on-accent); }
.grad-text {
  color: var(--accent);
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.mono { font-family: var(--font-mono); font-size: 0.875em; letter-spacing: 0; }
.muted { color: var(--text-2); }
.small { font-size: 0.9375rem; }
.skip {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  background: var(--surface); color: var(--text); border: 1px solid var(--border);
  padding: 12px 16px; border-radius: var(--radius);
}
.skip:focus { top: 16px; }
.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; }

/* §3 Layout */
.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; border-top: 1px solid var(--border-soft); position: relative; }
.section--alt { background: var(--surface-2); }
.section-head { display: grid; grid-template-columns: 200px 1fr; gap: 24px 48px; margin-bottom: 48px; align-items: start; }
.section-head h2 { max-width: 22ch; }
.section-head p { color: var(--text-2); max-width: 62ch; font-size: 1.125rem; margin: 0; }
.coord {
  font-family: var(--font-mono); font-size: 0.8125rem; color: var(--text-3);
  text-transform: uppercase; letter-spacing: 0.08em; padding-top: 10px;
  border-top: 1px solid var(--border); display: block;
}
.coord b { color: var(--accent); font-weight: 600; }
.gridded {
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 64px 64px;
  background-position: -1px -1px;
}

/* §4 Header and navigation */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-soft);
}
.bar { display: flex; align-items: center; gap: 24px; min-height: 72px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font: 700 1.1875rem/1 var(--font-display); letter-spacing: -0.02em; }
.logo svg { width: 30px; height: 30px; flex: none; }
.logo .s1 { stop-color: #a78bfa; }
.logo .s2 { stop-color: #67e3f5; }
.logo .dot { fill: #67e3f5; }
:root[data-theme="light"] .logo .s1 { stop-color: #6d28d9; }
:root[data-theme="light"] .logo .s2, :root[data-theme="light"] .logo .dot { stop-color: #0e7490; fill: #0e7490; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .logo .s1 { stop-color: #6d28d9; }
  :root:not([data-theme="dark"]) .logo .s2, :root:not([data-theme="dark"]) .logo .dot { stop-color: #0e7490; fill: #0e7490; }
}
.logo:hover { text-decoration: none; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a {
  color: var(--text-2); text-decoration: none; padding: 10px 12px; border-radius: var(--radius);
  font-size: 0.9375rem; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center;
}
.nav a:hover { color: var(--text); background: var(--accent-soft); }
.nav a[aria-current="page"], .nav a.is-parent { color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.bar-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 44px; height: 44px; display: inline-grid; place-items: center; flex: none;
  background: transparent; color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius); cursor: pointer; padding: 0;
}
.icon-btn:hover { background: var(--accent-soft); }
.icon-btn svg { width: 20px; height: 20px; }
/* The script writes the active theme into data-mode; the icon shows where a click leads. */
.theme-toggle { display: none; }
.js .theme-toggle { display: inline-grid; }
.theme-toggle .i-moon, .theme-toggle[data-mode="dark"] .i-sun { display: block; }
.theme-toggle .i-sun, .theme-toggle[data-mode="dark"] .i-moon { display: none; }
.nav-toggle { display: none; }
.login-link { color: var(--text-2); font-size: 0.9375rem; text-decoration: none; padding: 10px 8px; min-height: 44px; display: inline-flex; align-items: center; }
.login-link:hover { color: var(--text); }

/* §5 Buttons and forms */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 22px; border-radius: var(--radius);
  font: 650 1rem/1.2 var(--font-body); text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: transform var(--fast) var(--ease-out), box-shadow var(--fast) var(--ease-out);
  text-align: center;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn-primary { background: var(--grad); color: var(--on-accent); box-shadow: var(--shadow); }
.btn-primary:hover { box-shadow: 0 0 0 3px var(--accent-soft), var(--shadow); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--accent-soft); border-color: var(--border-strong); }
.btn-sm { min-height: 44px; padding: 10px 16px; font-size: 0.9375rem; }
.btn[disabled] { opacity: 0.6; cursor: progress; }
.btn .arrow { transition: transform var(--fast) var(--ease-out); }
.btn:hover .arrow { transform: translateX(3px); }

.field { display: grid; gap: 6px; }
.field label, .label { font-size: 0.875rem; font-weight: 600; color: var(--text); }
.field .hint { font-size: 0.8125rem; color: var(--text-3); }
input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%; min-height: 48px; padding: 12px 14px;
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius);
  font: 400 1rem/1.4 var(--font-body);
}
select { appearance: none; -webkit-appearance: none; padding-right: 40px;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-2) 50%), linear-gradient(135deg, var(--text-2) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
textarea { min-height: 150px; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--text-3); opacity: 1; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 1px; border-color: var(--accent-2); }
input[aria-invalid="true"] { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 0.875rem; margin: 0; }
.field-error[hidden] { display: none; }
.req { color: var(--danger); }

.order {
  background: var(--surface); border: 1px solid var(--border); border-radius: calc(var(--radius) + 2px);
  padding: 28px; box-shadow: var(--shadow); display: grid; gap: 16px; position: relative;
}
.order-top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.order-title { font: 700 1.25rem/1.2 var(--font-display); margin: 0; }
.price { font-family: var(--font-mono); color: var(--text); font-size: 0.9375rem; white-space: nowrap; }
.price s { color: var(--text-3); margin-right: 6px; }
.price b { font-size: 1.125rem; }
.order .btn { width: 100%; padding-left: 14px; padding-right: 14px; }
.order-note { margin: 0; font-size: 0.875rem; color: var(--text-2); }
.order-checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: 0.875rem; color: var(--text-2); }
.order-checks li { display: flex; gap: 8px; align-items: flex-start; }
.order-checks svg { width: 16px; height: 16px; flex: none; margin-top: 3px; color: var(--ok); }
.order-inline { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; }
.order-inline .btn { width: auto; white-space: nowrap; }
.order-inline .field-error { grid-column: 1 / -1; }

.lead { display: grid; gap: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: calc(var(--radius) + 2px); padding: 32px; box-shadow: var(--shadow); }
.lead .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 0.9375rem; color: var(--text-2); }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: #8b5cf6; }
.hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
[data-lead-status] { margin: 0; padding: 12px 16px; border-radius: var(--radius); border: 1px solid var(--border); font-weight: 500; }
[data-lead-status][hidden] { display: none; }
[data-lead-status][data-state="ok"] { border-color: var(--ok); background: var(--ok-soft); color: var(--text); }
[data-lead-status][data-state="fail"] { border-color: var(--danger); background: var(--danger-soft); color: var(--text); }
[data-lead-status][data-state="wait"] { border-color: var(--border); background: var(--surface-2); color: var(--text-2); }

/* §6 Cards, bento, lists, steps, ladder */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; display: flex; flex-direction: column; gap: 12px; position: relative;
}
.card h3 { margin: 0; }
.card p { margin: 0; color: var(--text-2); }
.card .more { margin-top: auto; padding-top: 8px; font-weight: 600; text-decoration: none; display: inline-flex; gap: 8px; align-items: center; min-height: 44px; }
.card .more:hover { text-decoration: underline; }
.card-link { transition: border-color var(--fast) var(--ease-out), transform var(--fast) var(--ease-out); }
.card-link:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.card-link .stretch::after { content: ""; position: absolute; inset: 0; }
.card .ico { width: 40px; height: 40px; color: var(--accent); }
.card .ico svg { width: 40px; height: 40px; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.ticks li { position: relative; padding-left: 24px; color: var(--text-2); }
.ticks li::before { content: ""; position: absolute; left: 2px; top: 0.6em; width: 10px; height: 2px; background: var(--accent-2); }
.ticks li strong { color: var(--text); font-weight: 600; }

.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
ul.bento { list-style: none; padding: 0; margin: 0; }
.bento > * { grid-column: span 2; }
.bento > .w3 { grid-column: span 3; }
.bento > .w4 { grid-column: span 4; }

.tag {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 0.75rem;
  text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-2);
  border: 1px solid var(--border); border-radius: 3px; padding: 3px 8px; width: fit-content;
}
.tag--accent { color: var(--accent); border-color: var(--accent); }

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.steps > li { padding: 32px 28px; border-left: 1px solid var(--border); display: flex; flex-direction: column; gap: 10px; }
.steps > li:first-child { border-left: 0; }
.steps .num { font: 700 3rem/1 var(--font-display); letter-spacing: -0.04em; }
.steps h3 { margin: 0; }
.steps p { margin: 0; color: var(--text-2); }
.steps .meta { margin-top: auto; padding-top: 12px; font-family: var(--font-mono); font-size: 0.8125rem; color: var(--text-3); border-top: 1px dashed var(--border-soft); }

.timeline { list-style: none; padding: 0; margin: 0; counter-reset: step; display: grid; gap: 0; border-left: 1px solid var(--border); }
.timeline > li { position: relative; padding: 0 0 36px 40px; counter-increment: step; }
.timeline > li:last-child { padding-bottom: 0; }
.timeline > li::before {
  content: counter(step, decimal-leading-zero); position: absolute; left: -17px; top: -2px;
  width: 34px; height: 34px; display: grid; place-items: center;
  background: var(--bg); border: 1px solid var(--border); border-radius: 50%;
  font: 600 0.75rem/1 var(--font-mono); color: var(--accent);
}
.section--alt .timeline > li::before { background: var(--surface-2); }
.timeline h3 { margin-bottom: 6px; }
.timeline p { color: var(--text-2); margin: 0; max-width: 64ch; }
.timeline .meta { display: block; margin-top: 8px; font-family: var(--font-mono); font-size: 0.8125rem; color: var(--text-3); }

.ladder { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.rung { padding: 32px 28px; display: flex; flex-direction: column; gap: 14px; border-left: 1px solid var(--border); position: relative; }
.rung:first-child { border-left: 0; }
.rung .tag { margin-bottom: 4px; }
.rung h3 { font-size: 1.5rem; margin: 0; }
.amount { font: 700 clamp(2.5rem, 4vw, 3.25rem)/1 var(--font-display); letter-spacing: -0.03em; margin: 0; }
.amount small { font: 500 0.9375rem/1.4 var(--font-body); color: var(--text-2); letter-spacing: 0; margin-left: 6px; }
.rung p { color: var(--text-2); margin: 0; }
.rung .calc { font-family: var(--font-mono); font-size: 0.875rem; color: var(--text); background: var(--surface-2); border: 1px solid var(--border-soft); border-radius: 4px; padding: 10px 12px; }
.rung .btn { margin-top: auto; }
.rung:first-child { background: linear-gradient(180deg, var(--accent-soft), transparent 60%); }
.bundles { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.bundle { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }

.audit-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.audit-cell { padding: 22px 20px; border-right: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--text); position: relative; min-height: 190px; transition: background var(--fast) var(--ease-out); }
.audit-cell:nth-child(5n) { border-right: 0; }
.audit-cell:nth-last-child(-n+5) { border-bottom: 0; }
.audit-cell:hover { background: var(--accent-soft); text-decoration: none; }
.audit-cell .code { font-family: var(--font-mono); font-size: 0.75rem; color: var(--accent); text-transform: uppercase; letter-spacing: 0.08em; }
.audit-cell h3 { font-size: 1.0625rem; margin: 0; }
.audit-cell p { font-size: 0.9375rem; color: var(--text-2); margin: 0; }
.audit-cell .go { margin-top: auto; font-size: 0.875rem; font-weight: 600; color: var(--accent); }
.audit-facts { display: flex; flex-wrap: wrap; gap: 8px 32px; margin-top: 24px; font-family: var(--font-mono); font-size: 0.875rem; color: var(--text-2); }
.audit-facts b { color: var(--text); font-weight: 600; }

.audit-list { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.audit-card { scroll-margin-top: 96px; }
.audit-card .head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.audit-card form { margin-top: auto; padding-top: 16px; border-top: 1px dashed var(--border-soft); }
.audit-card:target { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.choice { display: grid; gap: 8px; border: 0; padding: 0; margin: 0; }
.choice legend { font-size: 0.875rem; font-weight: 600; margin-bottom: 6px; padding: 0; }
.choice label { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius); cursor: pointer; font-size: 0.9375rem; color: var(--text-2); min-height: 44px; }
.choice label b { color: var(--text); font-weight: 600; }
.choice input { margin-top: 3px; accent-color: #8b5cf6; width: 18px; height: 18px; flex: none; }
.choice label:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }

.two-col { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: start; }
.aside-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; display: grid; gap: 12px; }
.aside-box h2, .aside-box h3 { margin: 0; font-size: 1.25rem; }
.aside-box p { margin: 0; color: var(--text-2); }
.stack { display: grid; gap: 16px; }
.related { display: flex; flex-wrap: wrap; gap: 8px; }
.related a { text-decoration: none; }

/* §7 Page parts */
.hero { padding: 72px 0 96px; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 160px; background: linear-gradient(transparent, var(--bg)); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr); gap: 56px; align-items: center; position: relative; z-index: 1; }
.hero-areas { grid-template-areas: "copy form" "facts form"; row-gap: 0; }
.hero-copy { grid-area: copy; align-self: end; }
.hero-form { grid-area: form; }
.hero-areas .hero-facts { grid-area: facts; align-self: start; }
.kicker { display: inline-flex; gap: 10px; align-items: center; font-family: var(--font-mono); font-size: 0.8125rem; color: var(--text-2); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 24px; }
.kicker::before { content: ""; width: 8px; height: 8px; border-radius: 1px; background: var(--grad); }
.lede { font-size: 1.25rem; line-height: 1.55; color: var(--text-2); max-width: 56ch; margin: 24px 0 0; }
.lede strong { color: var(--text); font-weight: 600; }
.hero-facts { display: grid; grid-template-columns: repeat(3, auto); gap: 0; margin-top: 40px; border-top: 1px solid var(--border); width: fit-content; max-width: 100%; }
.hero-facts div { padding: 14px 28px 0 0; margin-right: 28px; border-right: 1px solid var(--border-soft); }
.hero-facts div:last-child { border-right: 0; margin-right: 0; }
.hero-facts dt { font-family: var(--font-mono); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-3); }
.hero-facts dd { margin: 4px 0 0; font: 700 1.5rem/1.2 var(--font-display); letter-spacing: -0.02em; }

.page-head { padding: 64px 0 56px; border-bottom: 1px solid var(--border-soft); }
.page-head h1 { font-size: clamp(2.25rem, 5vw, 4rem); max-width: 18ch; }
.page-head .lede { margin-top: 16px; }
.crumbs { font-family: var(--font-mono); font-size: 0.8125rem; color: var(--text-3); margin-bottom: 20px; }
.crumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--text-3); }
.crumbs a { color: var(--text-2); }
.page-head-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr); gap: 48px; align-items: end; }

.faq { border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 48px 22px 0; position: relative;
  font: 650 1.125rem/1.35 var(--font-display); color: var(--text); min-height: 44px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 8px; top: 18px; font: 400 1.5rem/1 var(--font-mono); color: var(--accent); transition: transform var(--fast) var(--ease-out); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding: 0 48px 24px 0; color: var(--text-2); max-width: 72ch; }
.faq .answer p:last-child { margin: 0; }

.cta-band { padding: 96px 0; background: var(--band); color: var(--on-band); border-top: 1px solid var(--border-soft); }
.cta-band h2 { color: var(--on-band); }
/* The form card keeps the page surface inside the dark band, so its text must follow the page, not the band. */
.cta-band .order { color: var(--text); }
.cta-band .muted { color: #a9b1c9; }
:root[data-theme="light"] .cta-band .muted { color: #c3c9da; }
.cta-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 440px); gap: 56px; align-items: center; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.cta-band .btn-ghost { color: var(--on-band); border-color: #8b94ae; }
.cta-band .btn-ghost:hover { background: rgba(167, 139, 250, 0.14); }
.cta-band a:not(.btn) { color: #c4b5fd; }

.prose { max-width: 74ch; }
.prose h2 { font-size: 1.5rem; margin-top: 48px; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--text-2); }
.prose strong { color: var(--text); }
.prose .version { font-family: var(--font-mono); font-size: 0.875rem; color: var(--text-3); }
.legal-grid { display: grid; grid-template-columns: 240px 1fr; gap: 56px; align-items: start; }
.toc { position: sticky; top: 96px; font-size: 0.9375rem; border-left: 1px solid var(--border); padding-left: 16px; max-height: calc(100vh - 120px); overflow-y: auto; }
.toc ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.toc a { color: var(--text-2); text-decoration: none; display: block; padding: 6px 0; }
.toc a:hover { color: var(--text); }

.site-footer { border-top: 1px solid var(--border); padding: 64px 0 40px; background: var(--surface-2); font-size: 0.9375rem; }
.foot-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 40px; }
.site-footer h2 { font-size: 0.8125rem; font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-3); font-weight: 500; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.site-footer ul a { color: var(--text-2); text-decoration: none; display: inline-block; padding: 6px 0; }
.site-footer ul a:hover { color: var(--text); text-decoration: underline; }
.site-footer p { color: var(--text-2); margin: 0 0 8px; }
.legal-line { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border-soft); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--text-3); font-size: 0.875rem; }
.legal-line p { color: var(--text-3); margin: 0; }
.legal-line:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.site-footer:has(> .wrap > .legal-line:first-child) { padding: 32px 0; }
body { min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1 0 auto; }

.notice { border: 1px solid var(--border); border-left: 3px solid var(--accent-2); background: var(--surface); border-radius: var(--radius); padding: 16px 20px; color: var(--text-2); }
.notice strong { color: var(--text); }

/* §8 Motion. The script marks what is already on screen as shown, then sets .reveal-ready:
   only content below the first screen fades in, and nothing stays hidden if the script fails. */
.reveal-ready .reveal:not(.in), .reveal-ready .reveal-group:not(.in) > * { opacity: 0; transform: translateY(12px); }
.reveal-ready .reveal, .reveal-ready .reveal-group > * { transition: opacity var(--slow) var(--ease-out), transform var(--slow) var(--ease-out); }
.reveal-ready .reveal-group.in > *:nth-child(2) { transition-delay: 50ms; }
.reveal-ready .reveal-group.in > *:nth-child(3) { transition-delay: 100ms; }
.reveal-ready .reveal-group.in > *:nth-child(4) { transition-delay: 150ms; }
.reveal-ready .reveal-group.in > *:nth-child(5) { transition-delay: 200ms; }
.reveal-ready .reveal-group.in > *:nth-child(n+6) { transition-delay: 240ms; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; transition-delay: 0ms !important; }
  .reveal-ready .reveal:not(.in), .reveal-ready .reveal-group:not(.in) > * { opacity: 1; transform: none; }
}

/* §9 Responsive */
@media (max-width: 1100px) {
  .audit-grid { grid-template-columns: repeat(2, 1fr); }
  .audit-cell, .audit-cell:nth-child(5n) { border-right: 1px solid var(--border-soft); min-height: 0; }
  .audit-cell:nth-child(2n) { border-right: 0; }
  .audit-cell:nth-last-child(-n+5) { border-bottom: 1px solid var(--border-soft); }
  .audit-cell:nth-last-child(-n+2) { border-bottom: 0; }
  .nav a { padding: 10px 8px; }
}
@media (max-width: 1023px) {
  .hero-grid, .two-col, .cta-grid, .page-head-grid, .legal-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-areas { grid-template-areas: "copy" "form" "facts"; gap: 28px; }
  .hero-areas .hero-facts { margin-top: 0; }
  .section-head { grid-template-columns: 1fr; gap: 16px; }
  .bento > *, .bento > .w3, .bento > .w4 { grid-column: span 3; }
  .ladder, .steps { grid-template-columns: 1fr; }
  .rung, .steps > li { border-left: 0; border-top: 1px solid var(--border); }
  .rung:first-child, .steps > li:first-child { border-top: 0; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .toc { position: static; max-height: none; }
  .js .nav-toggle { display: inline-grid; }
  .js .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px 16px 16px;
    background: var(--bg); border-bottom: 1px solid var(--border);
  }
  .js .nav.open { display: flex; }
  .js .nav a { padding: 12px 8px; border-bottom: 1px solid var(--border-soft); }
  .js .nav a[aria-current="page"], .js .nav a.is-parent { box-shadow: inset 3px 0 0 var(--accent); padding-left: 14px; }
  .nav { flex-wrap: wrap; }
  .bar { position: relative; flex-wrap: wrap; }
  .js .bar { flex-wrap: nowrap; }
  .js .bar-actions { margin-left: auto; }
}
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .hero { padding: 32px 0 56px; }
  .bento > *, .bento > .w3, .bento > .w4 { grid-column: 1 / -1; }
  .audit-list, .bundles, .lead .row { grid-template-columns: 1fr; }
  .audit-grid { grid-template-columns: 1fr; }
  .audit-cell, .audit-cell:nth-child(2n), .audit-cell:nth-child(5n) { border-right: 0; border-bottom: 1px solid var(--border-soft); }
  .audit-cell:last-child { border-bottom: 0; }
  .hero-facts { grid-template-columns: 1fr 1fr 1fr; width: 100%; }
  .hero-facts div { padding-right: 12px; margin-right: 12px; }
  .hero-facts dd { font-size: 1.125rem; }
  .lede { font-size: 1.0625rem; }
  .order, .lead { padding: 20px; }
  .login-link { display: none; }
  .page-head { padding: 40px 0 40px; }
  .cta-band { padding: 64px 0; }
  .foot-grid { grid-template-columns: 1fr; gap: 28px; }
  .faq summary { font-size: 1.0625rem; }
}
@media (max-width: 420px) {
  .wrap { padding: 0 16px; }
  .order-inline { grid-template-columns: 1fr; }
  .order-inline .btn { width: 100%; }
  .hero-facts dt { font-size: 0.6875rem; letter-spacing: 0.04em; }
  .bar { gap: 12px; }
  .logo { font-size: 1.0625rem; }
}
