/* Subpages (docs, open source, pricing, early access, privacy, terms, 404).
   Loaded after site.css; reuses its tokens, frame, nav, footer, .label, .btn, .lede,
   .ticket and .pane, and adds only what the landing page does not have. */

.nav nav a[aria-current="page"] { color: var(--ink); }
.nav nav a.cta[aria-current="page"] { border-color: var(--muted); }
.foot nav a[aria-current="page"] { color: var(--ink); }

/* ---------- page head ---------- */
.ph { border-bottom: 1px solid var(--hair); }
.ph-in { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); column-gap: 64px; align-items: end; padding: 88px var(--pad) 64px; }
.ph h1 { font-size: clamp(36px, 4.4vw, 62px); line-height: 1.04; margin: 22px 0 0; text-wrap: balance; }
.ph .lede { font-size: 16px; }
.ph .lede a, .prose a, .sec-copy a, .faq a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--faint); }
.ph .lede a:hover, .prose a:hover, .sec-copy a:hover, .faq a:hover { border-color: var(--ink); }
.ph-side { display: grid; gap: 22px; align-content: end; }
.status-line { display: flex; align-items: center; gap: 10px; }
.sq { display: inline-block; width: 6px; height: 6px; background: var(--signal); flex: none; }

/* ---------- index strip (readout-style jump links) ---------- */
.idx { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); }
.idx a { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; border-right: 1px solid var(--hair); text-decoration: none; transition: background .15s; }
.idx a:first-child { padding-left: var(--pad); }
.idx a:last-child { border-right: 0; }
.idx a:hover { background: #0c1010; }
.idx a:hover b { color: #fff; }
.idx span { font: 400 10px/1.3 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); font-variant-numeric: tabular-nums; }
.idx b { font: 500 15px/1.3 var(--display); letter-spacing: -0.01em; color: var(--ink); }

/* ---------- section rows: copy left, instrument right ---------- */
.sec { border-bottom: 1px solid var(--hair); scroll-margin-top: 56px; }
.sec-in { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; padding: 72px var(--pad); align-items: start; }
.sec h2 { font-size: clamp(24px, 2.5vw, 32px); line-height: 1.12; margin: 18px 0 16px; text-wrap: balance; }
.sec-copy p { margin: 0 0 14px; max-width: 32em; color: var(--muted); }
.sec-copy p:last-child { margin-bottom: 0; }
.sec-copy code, .prose code { font: 400 .88em var(--mono); color: var(--ink); }
.sec-copy .aside-note { font: 400 12px/1.6 var(--mono); color: var(--dim); }

/* panes: site.css animates .pane.out, so the static "result" variant lives here */
.pane.result { border-color: var(--faint); box-shadow: inset 0 1px 0 var(--signal); }
.pane.result .io { color: var(--bg); background: var(--signal); border-color: var(--signal); }
.pane .prompt { color: var(--faint); user-select: none; }
.ticket-foot { margin: 0; padding: 12px 18px; border-top: 1px solid var(--hair); font-size: 13px; color: var(--dim); }

/* ---------- spec sheet (key / value) ---------- */
.sheet { border: 1px solid var(--line); background: var(--bg2); }
.sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; padding: 12px 20px; border-bottom: 1px solid var(--hair); }
.spec { display: grid; grid-template-columns: max-content minmax(0, 1fr); margin: 0; }
.spec > div { display: contents; }
.spec dt, .spec dd { padding: 14px 20px; border-bottom: 1px solid var(--hair); }
.spec > div:last-child dt, .spec > div:last-child dd { border-bottom: 0; }
.spec dt { font: 400 10.5px/1.75 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); white-space: nowrap; min-width: 9.5em; }
.spec dd { margin: 0; color: var(--text); font-size: 14.5px; line-height: 1.55; }
.spec dd b { font-weight: 500; color: var(--ink); }
.sheet-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px 18px; flex-wrap: wrap; padding: 18px 20px; border-top: 1px solid var(--hair); }
.sheet-foot p { margin: 0; color: var(--muted); font-size: 13.5px; }
.stack { display: grid; gap: 28px; }

/* ---------- pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(6, auto); border: 1px solid var(--line); background: var(--bg2); }
.plan { display: grid; grid-row: span 6; grid-template-rows: subgrid; row-gap: 0; border-left: 1px solid var(--line); min-width: 0; }
.plan:first-child { border-left: 0; }
.plan > * { margin: 0; padding: 0 24px; }
.plan.main { box-shadow: inset 0 1px 0 var(--signal); }
.p-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 14px !important; padding-bottom: 14px !important; border-bottom: 1px solid var(--hair); }
.plan.main .p-head .label:first-child { color: var(--ink); }
.p-price { padding-top: 30px !important; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.p-price b { font: 400 40px/1.1 var(--mono); color: var(--ink); letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.p-price b.word { font: 500 34px/1.15 var(--display); letter-spacing: -0.02em; }
.p-size { padding-top: 10px !important; font: 400 13px/1.5 var(--mono); color: var(--ink); letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.p-hours { padding-top: 22px !important; }
.meter { position: relative; height: 15px; margin-bottom: 10px; }
.meter::before { content: ""; position: absolute; left: 0; right: 0; top: 7px; height: 1px; background: var(--line); }
.meter i { position: absolute; left: 0; top: 0; height: 15px; width: max(2px, calc(var(--p) * 100%)); border-left: 1px solid var(--ink); border-right: 1px solid var(--ink); }
.meter i::after { content: ""; position: absolute; left: 0; right: 0; top: 7px; height: 1px; background: var(--ink); }
.p-hours p { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--dim); }
.p-hours p b { font: 400 12.5px var(--mono); color: var(--muted); font-variant-numeric: tabular-nums; }
.p-blurb { padding-top: 22px !important; padding-bottom: 26px !important; color: var(--text); font-size: 15px; line-height: 1.55; }
.p-act { display: flex; align-items: center; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; padding-top: 18px !important; padding-bottom: 20px !important; border-top: 1px solid var(--hair); align-self: end; }
.p-act small { font: 400 10.5px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.plans-note { margin: 16px 0 0; font: 400 12px/1.6 var(--mono); color: var(--dim); }

/* questions: a numbered ledger of disclosures */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--hair); }
.faq summary { display: grid; grid-template-columns: 56px minmax(0, 1fr) 20px; gap: 16px; align-items: baseline; padding: 20px 0; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .q { font: 400 11px/1.5 var(--mono); letter-spacing: .1em; color: var(--dim); font-variant-numeric: tabular-nums; }
.faq summary .t { font: 500 17px/1.4 var(--display); letter-spacing: -0.01em; color: var(--ink); }
.faq summary::after { content: "+"; font: 400 15px/1 var(--mono); color: var(--dim); text-align: right; }
.faq details[open] summary::after { content: "−"; color: var(--signal); }
.faq summary:hover .t { color: #fff; }
.faq summary:hover::after { color: var(--ink); }
.faq details p { margin: -6px 36px 22px 72px; max-width: 36em; color: var(--muted); font-size: 15px; line-height: 1.65; }

/* ---------- early access form ---------- */
.form-pane { border: 1px solid var(--line); background: var(--bg2); }
.form-body { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 20px; padding: 24px 20px 26px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field > span { display: flex; justify-content: space-between; gap: 10px; font: 400 10.5px/1.4 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.field > span em { font-style: normal; color: var(--faint); letter-spacing: .1em; }
.field input, .field select, .field textarea { width: 100%; margin: 0; padding: 12px 14px; background: var(--bg); border: 1px solid var(--line); border-radius: 0;
  color: var(--ink); font: 400 15px/1.4 var(--sans); transition: border-color .15s; -webkit-appearance: none; appearance: none; }
.field textarea { resize: vertical; min-height: 116px; line-height: 1.55; }
.field select { padding-right: 40px; cursor: pointer; font: 400 13px/1.4 var(--mono); letter-spacing: .02em;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(-45deg, transparent 50%, var(--muted) 50%);
  background-position: calc(100% - 20px) 52%, calc(100% - 15px) 52%; background-size: 5px 5px; background-repeat: no-repeat; }
.field select option { background: var(--bg2); color: var(--ink); }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--faint); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--signal); }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px 20px; flex-wrap: wrap; padding: 18px 20px; border-top: 1px solid var(--hair); }
.form-foot p { margin: 0; font-size: 13px; color: var(--dim); }
.form-foot p a { color: var(--muted); text-decoration: none; border-bottom: 1px solid var(--faint); }
.form-foot p a:hover { color: var(--ink); border-color: var(--ink); }
.form-status { margin: 0; padding: 0 20px; font: 400 11px/1.5 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--signal); }
.form-status:not(:empty) { padding: 14px 20px; border-top: 1px solid var(--hair); }
.form-pane.sent { border-color: var(--faint); }

/* ---------- legal: narrow measure with a mono contents column ---------- */
.legal-in { display: grid; grid-template-columns: 220px minmax(0, 38em); gap: 72px; padding: 64px var(--pad) 104px; }
.toc { position: sticky; top: 88px; align-self: start; }
.toc ol { list-style: none; margin: 14px 0 0; padding: 0; border-top: 1px solid var(--line); counter-reset: toc; }
.toc li { counter-increment: toc; border-bottom: 1px solid var(--hair); }
.toc a { display: grid; grid-template-columns: 30px minmax(0, 1fr); padding: 10px 0; text-decoration: none; color: var(--muted); font: 400 11px/1.5 var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.toc a::before { content: counter(toc, decimal-leading-zero); color: var(--faint); }
.toc a:hover { color: var(--ink); }
.prose { counter-reset: sec; font-size: 16.5px; line-height: 1.75; color: var(--text); }
.prose h2 { counter-increment: sec; font-size: 22px; line-height: 1.25; margin: 56px 0 14px; padding-top: 18px; border-top: 1px solid var(--hair); scroll-margin-top: 72px; }
.prose h2:first-child { margin-top: 0; }
.prose h2::before { content: counter(sec, decimal-leading-zero); display: block; margin-bottom: 12px; font: 400 11px/1 var(--mono); letter-spacing: .14em; color: var(--dim); }
.prose p { margin: 0 0 18px; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- 404 ---------- */
.nf .readout { border-top: 1px solid var(--hair); border-bottom: 0; }
.nf .readout > div { padding: 14px 18px; }
.nf .readout > div:first-child { padding-left: var(--pad); }
.nf .ro-path { flex: 1 1 auto; min-width: 0; }
.nf .ro-path b { overflow: hidden; text-overflow: ellipsis; }
.nf .readout b.sig { color: var(--signal); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .ph-in { grid-template-columns: 1fr; row-gap: 28px; padding: 64px var(--pad) 48px; }
  .ph .lede { max-width: 36em; }
  .sec-in { grid-template-columns: 1fr; gap: 36px; padding: 64px var(--pad); }
  .legal-in { grid-template-columns: 180px minmax(0, 1fr); gap: 48px; }
}
@media (max-width: 900px) {
  .plans { grid-template-columns: 1fr; grid-template-rows: none; }
  .plan { grid-row: auto; grid-template-rows: none; border-left: 0; border-top: 1px solid var(--line); }
  .plan:first-child { border-top: 0; }
  .p-act { align-self: auto; }
  .p-hours:empty { display: none; }
}
@media (max-width: 760px) {
  .legal-in { grid-template-columns: 1fr; gap: 40px; padding: 40px var(--pad) 80px; }
  .toc { position: static; }
}
@media (max-width: 720px) {
  .ph-in { padding: 40px var(--pad) 36px; }
  .ph h1 { font-size: 34px; margin-top: 16px; letter-spacing: -0.025em; }
  .ph .lede { font-size: 15px; }
  .idx { grid-template-columns: 1fr 1fr; }
  .idx a { padding: 14px var(--pad); border-bottom: 1px solid var(--hair); }
  .idx a:nth-child(2n) { border-right: 0; padding-left: 16px; }
  .idx a:nth-last-child(-n+2) { border-bottom: 0; }
  .sec-in { padding: 48px var(--pad); gap: 28px; }
  .spec { grid-template-columns: 1fr; }
  .spec dt { border-bottom: 0; padding-bottom: 2px; }
  .spec dd { padding-top: 0; }
  .spec > div:last-child dt { padding-bottom: 2px; }
  .form-body { grid-template-columns: 1fr; padding: 20px 16px 22px; gap: 20px; }
  .form-foot, .sheet-foot { padding: 16px; }
  .plan > * { padding-left: 20px; padding-right: 20px; }
  .p-price b { font-size: 34px; }
  .faq summary { grid-template-columns: 36px minmax(0, 1fr) 16px; gap: 12px; }
  .faq summary .t { font-size: 16px; }
  .faq details p { margin: -6px 0 20px 48px; }
  .prose { font-size: 16px; line-height: 1.7; }
  .nf .readout { flex-wrap: wrap; }
  .nf .ro-path { flex-basis: 100%; order: 3; border-top: 1px solid var(--hair); padding-left: var(--pad) !important; border-right: 0 !important; }
  .nf .readout > div:nth-child(2) { border-right: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .idx a, .field input, .field select, .field textarea { transition: none; }
}
.sec-in.wide { grid-template-columns: minmax(0, 1fr); gap: 0; }
.plans-label { margin-bottom: 20px; }

/* early access: the page head and the form share one row */
.ea .sec-in { padding-top: 88px; padding-bottom: 96px; }
.ea h1 { font-size: clamp(36px, 4.4vw, 62px); line-height: 1.04; margin: 22px 0 24px; text-wrap: balance; }
.ea .lede { font-size: 16px; }
@media (max-width: 720px) {
  .ea .sec-in { padding-top: 40px; padding-bottom: 56px; }
  .ea h1 { font-size: 34px; margin: 16px 0 14px; letter-spacing: -0.025em; }
  .ea .lede { font-size: 15px; }
}
.ph-side p { margin: 0; }
.idx { border-top: 1px solid var(--hair); }
/* site.css positions the hero ticket on phones; reset it for in-page tickets */
.sec .ticket { margin: 0; max-width: none; order: 0; }
.p-act { align-self: stretch; align-content: flex-start; }
/* one key column width for every spec sheet, so stacked sheets line up */
.spec { grid-template-columns: 168px minmax(0, 1fr); }
.spec dt { min-width: 0; }
@media (max-width: 720px) { .spec { grid-template-columns: 1fr; } }
@media (max-width: 720px) {
  .sheet-head, .spec dt, .spec dd, .form-status:not(:empty) { padding-left: 16px; padding-right: 16px; }
}
/* 404: the head fills the viewport so the footer sits at the bottom */
body.fill { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; }
body.fill main { flex: 1; display: flex; flex-direction: column; }
body.fill .nf { flex: 1; display: flex; flex-direction: column; }
body.fill .nf .ph-in { flex: 1; width: 100%; }
body.fill .nf > .frame:last-child { width: 100%; }
.nf-act { margin: 36px 0 0; }
body.fill .nf .ph-in { align-content: center; }
.foot-in > span { white-space: nowrap; }
.ph .lede, .sec-copy p, .faq details p { text-wrap: pretty; }
@media (max-width: 720px) {
  .nf .readout > div.ro-path { flex: 1 1 100%; order: 3; border-top: 1px solid var(--hair); border-bottom: 0; border-right: 0; padding-left: var(--pad); }
  .nf .readout > div:not(.ro-path) { flex: 1 1 50%; border-bottom: 0; }
  .nf .readout > div:nth-child(2) { padding-left: 18px; border-right: 0; }
}

/* production form */
.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.verify:empty { display: none; }
