/* Linth site — v2 graphic layer (heroes · ledger marks · stage diagram).
   Loaded after chrome.css on pages that use it. Tokens only.
   Color discipline: bramble appears exclusively on citation marks,
   rust exclusively on checkpoint marks (provenance roles, D31);
   everything else is ink on paper. Flat grammar — no shadows. */

/* ---------- Full-viewport hero ---------- */
.hero-full { display: flex; flex-direction: column; min-height: 100svh; padding-top: clamp(76px, 9vw, 128px); }
.hero-copy { display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-copy h1 { margin: 0; font-size: clamp(38px, 5.2vw, 58px); line-height: 1.06; letter-spacing: -0.028em; font-weight: 600; max-width: 820px; text-wrap: balance; }
.hero-sub { margin: 24px 0 0; font-size: clamp(15px, 1.3vw, 17px); line-height: 1.62; color: var(--ink-secondary); max-width: 640px; text-wrap: pretty; }
.hero-cta { margin-top: 30px; padding: 11px 20px; }
.hero-media { width: min(1360px, 100% - clamp(24px, 5vw, 72px)); margin: clamp(44px, 6vw, 72px) auto 0; }
.hero-frame { aspect-ratio: 16 / 10; background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); overflow: hidden; }
.hero-frame > img, .hero-frame > video { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; }
.hero-caption { text-align: center; margin: 20px auto 0; font-size: 14px; line-height: 1.6; color: var(--ink-secondary); max-width: 560px; text-wrap: pretty; }

@media (prefers-reduced-motion: no-preference) {
  .hero-copy { animation: rise-in 620ms var(--ease-swing) both; }
  .hero-media { animation: rise-in 760ms 90ms var(--ease-swing) both; }
  .hero-frame > img { animation: hero-drift 46s var(--ease-smooth) infinite alternate; }
}
@keyframes rise-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes hero-drift { from { transform: scale(1.012); } to { transform: scale(1.05); } }

/* ---------- Value cards (mark-led) ---------- */
.gcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: clamp(16px, 2vw, 24px); }
.gcard { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); padding: clamp(30px, 3.4vw, 44px) 28px clamp(30px, 3vw, 38px); display: flex; flex-direction: column; align-items: center; text-align: center; }
.gmark { height: 92px; display: flex; align-items: center; justify-content: center; color: var(--ink); }
.gcard h3 { margin: 24px 0 0; font-size: 16.5px; font-weight: 600; letter-spacing: -0.012em; }
.gcard p { margin: 10px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--ink-secondary); text-wrap: pretty; max-width: 36ch; }

/* ---------- Three-stage diagram (the ledger flow) ---------- */
.stageflow { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(28px, 4.5vw, 60px); margin-top: clamp(36px, 5vw, 56px); }
.stage-num { display: block; font-family: var(--font-mono); font-size: 12.5px; color: var(--ink-secondary); }
.stage-rail { position: relative; height: 9px; margin-top: 14px; }
.stage-rail::before { content: ''; position: absolute; left: 0; right: calc(-1 * clamp(28px, 4.5vw, 60px)); top: 50%; height: 1.25px; background: var(--ink); transform: translateY(-50%); }
.stage:last-child .stage-rail::before { right: 0; }
.stage-rail::after { content: ''; position: absolute; left: 0; top: 0; width: 9px; height: 9px; background: var(--ink); }
.stage:last-child .stage-rail i { position: absolute; right: 0; top: 1px; width: 7px; height: 7px; background: var(--ink); }
.stage h3 { margin: 20px 0 0; font-size: clamp(16px, 1.5vw, 18.5px); font-weight: 600; letter-spacing: -0.014em; text-wrap: balance; }
.stage-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.stage-chips span { font-family: var(--font-mono); font-size: 11.5px; line-height: 1; padding: 6px 10px 5px; border: 1px solid var(--hairline); border-radius: var(--radius-m); background: var(--surface); }
.stage p { margin: 16px 0 0; font-size: 13.5px; line-height: 1.62; color: var(--ink-secondary); text-wrap: pretty; }
@media (max-width: 760px) {
  .stageflow { grid-template-columns: 1fr; gap: 44px; }
  .stage-rail::before { right: 0; }
}

/* ---------- Workflow catalog cards ---------- */
.wf-features { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: clamp(16px, 2vw, 24px); }
.wf-feature { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); padding: clamp(28px, 3vw, 38px) 30px clamp(28px, 3vw, 34px); }
.wf-feature .wfmark { color: var(--ink); }
.wf-feature h3 { margin: 20px 0 0; font-family: var(--font-mono); font-size: 15px; font-weight: 500; }
.wf-feature p { margin: 9px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--ink-secondary); text-wrap: pretty; }
.wf-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: clamp(16px, 2vw, 24px); margin-top: clamp(16px, 2vw, 24px); }
.wf-card { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); padding: 24px 24px 26px; }
.wf-card .wfmark { color: var(--ink); }
.wf-card h3 { margin: 16px 0 0; font-family: var(--font-mono); font-size: 13.5px; font-weight: 500; }
.wf-card p { margin: 8px 0 0; font-size: 13px; line-height: 1.55; color: var(--ink-secondary); text-wrap: pretty; }

/* ============================================================
   v3 COMPOSITION LAYER (2026-07-22) — the beat-map system.
   Additive; nothing above changes. Grounding: version 3 study
   (Satori flow levels + LIFT) and the four benchmark reports.
   Devices: display kit · ink chapter bands (scoped token flip) ·
   the break set piece · the compression diagram · numbered-spec
   stages · figure plates · IO reveals (reduced-motion gated).
   ============================================================ */

/* ---------- Display kit ---------- */
.hero-copy h1.display-1 { font-size: clamp(2.6rem, 1.05rem + 4.8vw, 5rem); line-height: 1.02; letter-spacing: -0.034em; max-width: 1020px; }
.eyebrow-live { margin: 0 0 26px; font-family: var(--font-mono); font-size: clamp(10.5px, 1vw, 12.5px); font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-secondary); }
.eyebrow-live b { font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }
.t2 { color: color-mix(in srgb, var(--ink) 42%, transparent); }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; }
.sec-h { margin: 0; font-size: clamp(24px, 2.9vw, 34px); line-height: 1.12; letter-spacing: -0.024em; font-weight: 600; text-wrap: balance; }
.sec-index { font-family: var(--font-mono); font-size: 12px; letter-spacing: .1em; color: var(--ink-secondary); white-space: nowrap; }

/* ---------- Ink chapter band (scoped token flip; light-only site) ---------- */
.band-ink { --ink0: var(--ink); background: var(--ink); color: var(--text-on-ink); color-scheme: dark; }
.band-ink > * {
  --ink: var(--text-on-ink);
  --ink-secondary: color-mix(in srgb, var(--text-on-ink) 76%, transparent);
  --hairline: color-mix(in srgb, var(--text-on-ink) 24%, transparent);
  --surface: color-mix(in srgb, var(--text-on-ink) 7%, transparent);
  --ink-40: color-mix(in srgb, var(--text-on-ink) 46%, transparent);
}
.band-ink .btn-primary { background: var(--paper); color: var(--ink0); }
.band-ink .btn-primary:hover { background: color-mix(in srgb, var(--paper) 90%, black); }

/* ---------- Video hero (the Paces move — G1 2026-07-22; craft per the Paces teardown §6).
   Rides .band-ink for the token flip: the ink background doubles as the
   pre-load state, the video covers it, the flat scrim carries text contrast
   (the footage never protects the headline — by design). ---------- */
.hero-video { position: relative; display: flex; align-items: center; height: calc(100svh - 64px); min-height: 540px; max-height: 930px; overflow: hidden; }
.hero-video > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.4); /* no token exists for a scrim; Paces-parity value */ }
@media (max-width: 768px) { .hero-scrim { background: rgba(0, 0, 0, 0.5); } }
.hero-video .hero-copy { position: relative; align-items: flex-start; text-align: left; }
.hero-video .hero-copy h1.display-1 { max-width: 1020px; }
.hero-video .hero-sub { max-width: 560px; }

/* ---------- v3 stages: circle waypoints on a rail (no internal stage numbers — the
   04/6B/07 labels were removed 2026-07-23; the diagram is the marker, not the number) ---------- */
.stageflow-v3 .stage-rail { margin-top: 2px; height: 16px; }
.stageflow-v3 .stage-rail::after { width: 15px; height: 15px; border-radius: 50%; top: 0.5px; background: none; border: 1.5px solid var(--ink); }
.stageflow-v3 .stage:last-child .stage-rail i { width: 12px; height: 12px; border-radius: 50%; top: 2px; }

/* ---------- The compression diagram (two ruled chip-tracks; time-as-steps, never a claimed ratio) ---------- */
.compress { display: flex; flex-direction: column; gap: 26px; }
.ctrack-label { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 10px; font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-secondary); }
.ctrack-chips { display: flex; gap: 6px; }
.ctrack-chips span { flex: none; font-family: var(--font-mono); font-size: 11px; line-height: 1; padding: 8px 11px 7px; border: 1px solid var(--hairline); border-radius: var(--radius-m); white-space: nowrap; }
.ctrack--linth { display: flex; align-items: center; gap: 16px; }
.ctrack--linth .ctrack-chips span { background: var(--ink); color: var(--ink0, var(--paper)); border-color: var(--ink); }
.ctrack-tail { flex: 1; position: relative; border-top: 1px dashed var(--hairline); }
.ctrack-tail i { position: absolute; right: 0; bottom: 7px; font-style: normal; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-40); white-space: nowrap; }
@media (max-width: 860px) {
  .ctrack-chips { flex-wrap: wrap; gap: 5px; }
  .ctrack--linth { display: block; }
  .ctrack-tail { display: none; }
}

/* ---------- The break set piece (the tie-out exhibit; --prov-break is the provenance role) ---------- */
.breakpiece { text-align: center; }
.break-values { display: flex; align-items: baseline; justify-content: center; column-gap: clamp(20px, 4.5vw, 64px); row-gap: 8px; flex-wrap: wrap; }
.break-val { font-family: var(--font-mono); font-weight: 400; font-variant-numeric: tabular-nums; font-size: clamp(3.2rem, 0.9rem + 10vw, 8.5rem); line-height: 1; letter-spacing: -0.035em; }
.break-neq { font-family: var(--font-mono); font-weight: 400; font-size: clamp(2rem, 0.8rem + 5.2vw, 4.4rem); line-height: 1; color: var(--prov-break); transform: translateY(-0.28em); }
.break-pair { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.break-doc { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-secondary); }
@media (max-width: 560px) {
  .break-values { flex-direction: column; align-items: center; row-gap: 18px; }
  .break-neq { transform: none; }
}
.break-flag { display: inline-flex; align-items: center; gap: 8px; margin-top: 34px; padding: 9px 14px 8px; border: 1px solid color-mix(in srgb, var(--prov-break) 34%, transparent); border-radius: var(--radius-m); background: var(--prov-break-bg); font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--prov-break); }

/* ---------- Figure plate (the pause beat) ---------- */
.figure { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.figure img { width: min(780px, 100%); height: auto; border: 1px solid var(--hairline); border-radius: var(--radius-l); display: block; }
.figure img.fig-crop { aspect-ratio: 2.4 / 1; object-fit: cover; object-position: top; }
.figcap { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-secondary); text-align: center; }

/* ---------- v3 exhibit kit (inner-page sweep) ---------- */
/* vertical chain (cards on a rail with + nodes) */
.chain { display: flex; flex-direction: column; max-width: 560px; }
.chain-card { border: 1px solid var(--hairline); border-radius: var(--radius-l); background: var(--surface); padding: 18px 22px; }
.chain-card h4 { margin: 0; font-family: var(--font-mono); font-size: 13px; font-weight: 500; }
.chain-card p { margin: 6px 0 0; font-size: 13px; line-height: 1.55; color: var(--ink-secondary); text-wrap: pretty; }
.chain-link { align-self: center; width: 1px; height: 30px; background: var(--hairline); position: relative; }
.chain-link::after { content: '+'; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-family: var(--font-mono); font-size: 11px; line-height: 1; color: var(--ink-secondary); background: var(--paper); border: 1px solid var(--hairline); border-radius: 50%; width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; }

/* ghosted document + crisp extraction chips */
.ghostdoc { position: relative; max-width: 440px; border: 1px solid var(--hairline); border-radius: var(--radius-l); background: var(--surface); padding: 28px 30px 32px; }
.gd-line { height: 7px; border-radius: 2px; background: color-mix(in srgb, var(--ink) 7%, transparent); margin-top: 10px; }
.gd-chip { position: absolute; background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-m); box-shadow: var(--shadow-float); padding: 9px 12px 8px; font-family: var(--font-mono); font-size: 11.5px; line-height: 1; white-space: nowrap; }
.gd-chip sup { color: var(--prov-cited); font-weight: 500; }
@media (max-width: 700px) { .gd-chip { position: static; display: inline-flex; margin: 12px 8px 0 0; box-shadow: none; } }

/* machine-truth sequence rows (e.g. the export gate) */
.gateseq { display: flex; flex-direction: column; gap: 12px; max-width: 620px; font-family: var(--font-mono); font-size: 12.5px; }
.gateseq > div { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: baseline; padding: 13px 17px; border: 1px solid var(--hairline); border-radius: var(--radius-m); background: var(--surface); }
.gs-dim { color: var(--ink-secondary); }
.gs-block { color: var(--prov-checkpoint); font-weight: 500; }

/* engraved circular seals (true claims only) */
.stamps { display: flex; flex-wrap: wrap; gap: clamp(18px, 4vw, 44px); justify-content: center; }
.stamp { width: 122px; height: 122px; border: 1.25px solid var(--ink); border-radius: 50%; display: flex; align-items: center; justify-content: center; text-align: center; font-family: var(--font-mono); font-size: 9.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; line-height: 1.55; padding: 16px; }

/* the LOAD/GENERATION polarity swap */
.polarity { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: stretch; max-width: 760px; }
.pol-col { border: 1px solid var(--hairline); border-radius: var(--radius-l); background: var(--surface); padding: 20px 24px; }
.pol-col h4 { margin: 0 0 14px; font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-secondary); }
.pol-col ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; font-size: 13px; line-height: 1.5; }
.pol-swap { display: flex; flex-direction: column; justify-content: center; gap: 26px; font-family: var(--font-mono); font-size: 14px; color: var(--ink-40); }
@media (max-width: 700px) { .polarity { grid-template-columns: 1fr; } .pol-swap { flex-direction: row; justify-content: center; } }

/* ruled mono registry/taxonomy table */
.regtable { width: 100%; border-collapse: collapse; }
.regtable td, .regtable th { border-top: 1px solid var(--hairline); padding: 13px 14px 12px 0; text-align: left; vertical-align: baseline; }
.regtable tr:last-child td { border-bottom: 1px solid var(--hairline); }
.regtable .rt-key { font-family: var(--font-mono); font-size: 12px; font-weight: 500; white-space: nowrap; padding-right: 28px; }
.regtable .rt-val { font-size: 13px; color: var(--ink-secondary); line-height: 1.55; }

/* ---------- Chat composer exhibit (product/chat hero) — the "+" menu, token-rebuilt.
   Represents real shipped composer affordances (tools · connectors · skills ·
   templates · documents · model picker); no fake features. ---------- */
.cx { max-width: 760px; margin: 0 auto; }
.cx-bar { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); padding: 20px 22px 14px; }
.cx-ph { font-size: 15px; color: var(--ink-40); }
.cx-barrow { display: flex; align-items: center; justify-content: space-between; margin-top: 30px; }
.cx-plus { width: 30px; height: 30px; border-radius: var(--radius-m); display: inline-flex; align-items: center; justify-content: center; color: var(--ink); border: 1px solid var(--hairline); background: var(--paper); }
.cx-right { display: flex; align-items: center; gap: 12px; }
.cx-model { font-size: 13px; color: var(--ink-secondary); display: inline-flex; align-items: center; gap: 6px; }
.cx-send { width: 30px; height: 30px; border-radius: var(--radius-m); background: var(--paper); border: 1px solid var(--hairline); display: inline-flex; align-items: center; justify-content: center; color: var(--ink-secondary); }
.cx-menus { display: flex; gap: 14px; margin: 12px 0 0 14px; flex-wrap: wrap; align-items: flex-start; }
.cx-card { box-sizing: border-box; background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-l); box-shadow: var(--shadow-float); padding: 6px; }
.cx-bar { box-sizing: border-box; }
.cx-card--primary { width: 236px; flex: none; }
.cx-card--sub { width: 320px; flex: none; }
.cx-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 12px; border-radius: var(--radius-m); font-size: 13px; color: var(--ink); }
.cx-row.is-active { background: var(--active); }
.cx-lead { display: inline-flex; align-items: center; gap: 11px; }
.cx-lead svg { color: var(--ink-secondary); flex: none; }
.cx-chev { color: var(--ink-40); flex: none; }
.cx-check { color: var(--ink); flex: none; }
.cx-sub { display: block; font-size: 11.5px; color: var(--ink-secondary); margin-top: 1px; }
.cx-note { font-size: 11.5px; color: var(--ink-secondary); white-space: nowrap; }
.cx-grouplabel { font-family: var(--font-mono); font-size: 10px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-secondary); padding: 13px 12px 7px; }
.cx-divider { height: 1px; background: var(--hairline); margin: 6px 4px; }
.cx-manage { padding: 12px; font-size: 13px; color: var(--ink-secondary); border-top: 1px solid var(--hairline); margin-top: 4px; }
@media (max-width: 640px) { .cx-menus { margin-left: 0; } .cx-card--primary, .cx-card--sub { width: 100%; } }

/* ---------- Reveals (IO driver in /graphics.js; still page = the designed base state) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .rv { opacity: 0; translate: 0 16px; transition: opacity 680ms var(--ease-smooth), translate 680ms var(--ease-smooth); transition-delay: calc(var(--i, 0) * 90ms); }
  .js .rv.is-in { opacity: 1; translate: 0 0; }
}
