/* Hallmark · shape: Narrative Workflow (custom order: road, two sides, steps, rules, film, close) · genre: atmospheric · theme: Refract (deal manual pick from a re-deal, seed corvamed-bridge-between-patients-f571·989ca8e9·2026-11-14·r0; Vantage and Dose cleared, both too close to earlier sites) · job: enquire (write to us) · draw: manual
 * hero: Corridor over a road (the head centred, the six-stage road across the foot of the screen, lit by the glass light) · nav: three-part bar, centred key-like links, language and the one action at the right; two rows under 75rem · footer: colophon block · imagery: none, the road, the criteria lens and the film carry it · signature: the road of six stages as one continuous line in the light, the current stage marked · refract: glass/noon (ink as the accent, the spectrum only in the light and the logo hangers)
 * axes: light/geometric-sans/neutral · posture: restrained · contrast: pass · fold: pass · v2.0.0 */
/* Hallmark · pre-emit critique: P4 H5 E4 S4 R4 V5 · weakest: S, a trial-matching page could drift to a generic health look; tied every picture to the brand's one idea (a bridge) and built the criteria lens from a real kind of trial rule */
/* Hallmark · answered F15 · the site brief asks for every heading centred across the full width, so head blocks are centred by request */
/* Hallmark · dismissed 58 · privacy and legal pages are long documents the visitor reads on purpose; the brief sets no word limit */
/* Hallmark · waive 44c · inner pages open with a Banner header (.phead), the content starts under it · Corvamed's inner pages are reading pages for older visitors, a full-screen header would push the facts down */
/* Hallmark · waive 77 · .phead is a Banner header of one head and one line · every inner Corvamed page has its body directly beneath this header */
/* Hallmark · waive 59 · the 104px gap sits only between .phead and its first section · the Corvamed page header and its first section read as one opening */
/* Hallmark · waive 78 · Long Document shape on privacy, legal and the film transcript · legal headings stay modest so the Corvamed notices read as documents */
/* Hallmark · waive 23 · the dark area is the film's poster frame inside a video element · the Corvamed film page shows the film itself as its subject */
@import url("./fonts.css");
@import url("./tokens.css");
@import url("./base.css");

:root { --hh: 76px; --radius-key: 12px; --nav-row: 52px; }
body { font-size: var(--text-md); line-height: 1.6; }
p, li { color: var(--color-ink-2); }
h1, h2, h3 { color: var(--color-ink); }
h2 { margin-inline: auto; text-align: center; }
a { text-decoration-color: color-mix(in oklab, var(--color-ink) 45%, transparent); }
a:hover { text-decoration-color: var(--color-ink); }
.skip { position: absolute; left: var(--space-md); top: calc(-1 * var(--space-4xl)); z-index: var(--z-toast); padding: var(--space-sm) var(--space-md); background: var(--color-ink); color: var(--color-accent-ink); border-radius: var(--radius-inner); }
.skip:focus-visible { top: var(--space-md); }

/* ---------- header ---------- */
.hdr { position: sticky; top: 0; z-index: var(--z-sticky-nav); background: color-mix(in oklab, var(--color-paper) 94%, transparent); border-bottom: var(--rule-hair) solid var(--color-rule); }
.hdr__in { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); grid-template-areas: "brand nav tools"; align-items: center; gap: var(--space-md); padding-block: var(--space-sm); }
.brand { grid-area: brand; display: inline-flex; align-items: center; justify-self: start; border-radius: var(--radius-inner); }
.brand svg { height: 40px; width: auto; }
.brand .brand__mark { display: none; }
.nav { grid-area: nav; }
.nav ul { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-xs); margin: 0; padding: 0; list-style: none; }
.nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 var(--space-md); border: 1px solid var(--color-rule); border-radius: var(--radius-key); background: var(--color-light); color: var(--color-ink); font-size: var(--text-sm); font-weight: 500; text-decoration: none; white-space: nowrap; box-shadow: var(--edge-light); transition: background-color var(--dur-short) var(--ease-out), border-color var(--dur-short) var(--ease-out), transform var(--dur-micro) var(--ease-out); }
.nav a:hover { background: var(--color-paper-3); border-color: var(--color-shade-2); }
.nav a:active { transform: translateY(1px); }
.nav a[aria-current="page"] { background: var(--color-ink); border-color: var(--color-ink); color: var(--color-accent-ink); box-shadow: none; }
.tools { grid-area: tools; display: flex; align-items: center; justify-content: flex-end; gap: var(--space-xs); }

.lang { position: relative; }
.lang__btn { display: inline-flex; align-items: center; gap: var(--space-xs); min-height: 44px; padding: 0 var(--space-sm) 0 var(--space-md); border: 1px solid var(--color-rule); border-radius: var(--radius-key); background: var(--color-light); color: var(--color-ink); font-size: var(--text-sm); font-weight: 600; cursor: pointer; box-shadow: var(--edge-light); transition: background-color var(--dur-short) var(--ease-out); }
.lang__btn:hover { background: var(--color-paper-3); }
.lang__btn:active { transform: translateY(1px); }
.lang__btn svg { width: 14px; height: 14px; transition: transform var(--dur-short) var(--ease-out); }
.lang__btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.lang__menu { position: absolute; right: 0; top: calc(100% + var(--space-xs)); z-index: var(--z-dropdown); min-width: 12rem; margin: 0; padding: var(--space-xs); list-style: none; background: var(--color-light); border: 1px solid var(--color-rule); border-radius: var(--radius-inner); box-shadow: var(--shadow-card); }
.lang__menu a { display: flex; justify-content: space-between; gap: var(--space-md); align-items: center; min-height: 44px; padding: 0 var(--space-sm); border-radius: var(--radius-key); color: var(--color-ink); font-size: var(--text-sm); text-decoration: none; }
.lang__menu a:hover { background: var(--color-paper-2); }
.lang__menu a[aria-current="true"] { font-weight: 600; background: var(--color-paper-3); }
.lang__menu span { color: var(--color-muted); font-weight: 400; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-xs); min-height: 52px; padding: 0 var(--space-lg); border: 1px solid var(--color-accent); border-radius: var(--radius-pill); background: var(--color-accent); color: var(--color-accent-ink); font: 600 var(--text-md)/1 var(--font-body); white-space: nowrap; text-decoration: none; cursor: pointer; box-shadow: inset 0 1px 0 color-mix(in oklab, var(--color-light) 22%, transparent); transition: background-color var(--dur-short) var(--ease-out), transform var(--dur-micro) var(--ease-out); }
.btn:hover { background: var(--color-accent-hi); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn--sm { min-height: 44px; padding: 0 var(--space-md); font-size: var(--text-sm); }
.btn--quiet { background: color-mix(in oklab, var(--color-light) 82%, transparent); color: var(--color-ink); border-color: var(--color-rule); box-shadow: var(--edge-light); }
.btn--quiet:hover { background: var(--color-paper-3); }
.btn svg { width: 18px; height: 18px; flex: none; }

@media (max-width: 75rem) {
  .hdr__in { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand tools" "nav nav"; row-gap: var(--space-sm); }
  .nav ul { gap: var(--space-xs); }
}
@media (max-width: 40rem) {
  .brand svg { height: 32px; }
  .nav a { min-height: 40px; padding: 0 var(--space-sm); font-size: var(--text-xs); }
  .lang__btn, .btn--sm { min-height: 40px; font-size: var(--text-xs); }
  .btn--sm { padding: 0 var(--space-sm); }
  .lang__btn { padding: 0 var(--space-xs) 0 var(--space-sm); }
}
@media (max-width: 26rem) { .brand svg { height: 28px; } .btn--sm { padding: 0 var(--space-xs); } }
@media (max-width: 22.5rem) {
  .brand .brand__full { display: none; }
  .brand .brand__mark { display: block; }
}

/* ---------- light ---------- */
.light { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
.pause { position: absolute; right: var(--space-md); bottom: var(--space-md); z-index: var(--z-raised); display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--color-rule); border-radius: var(--radius-pill); background: color-mix(in oklab, var(--color-light) 86%, transparent); color: var(--color-ink); cursor: pointer; box-shadow: var(--edge-light); }
.pause:hover { background: var(--color-paper-3); }
.pause:active { transform: translateY(1px); }
.pause svg { width: 16px; height: 16px; }
.pause .i-play { display: none; }
.pause[aria-pressed="true"] .i-play { display: block; }
.pause[aria-pressed="true"] .i-pause { display: none; }
.no-motion .pause { display: none; }

/* ---------- hero: the road ---------- */
.hero { position: relative; isolation: isolate; display: grid; align-content: center; min-height: calc(100svh - var(--hh)); padding-block: var(--space-xl); overflow: clip; }
.hero__in { position: relative; z-index: var(--z-base); display: grid; gap: clamp(var(--space-xl), 6svh, var(--space-3xl)); }
.hero__text { display: grid; justify-items: center; gap: var(--space-lg); text-align: center; }
.hero h1 { max-width: 16ch; margin-inline: auto; }
.hero .lead { max-width: 46ch; margin-inline: auto; color: var(--color-ink-2); }
.road__label { margin: 0 0 var(--space-lg); text-align: center; font-size: var(--text-sm); font-weight: 500; color: var(--color-muted); }
.road { position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--space-md); margin: 0; padding: 0; list-style: none; }
.road::before { content: ""; position: absolute; top: 11px; left: calc(100% / 12); right: calc(100% / 12); height: 3px; border-radius: 2px; background: var(--color-ink-2); }
.road li { position: relative; display: grid; justify-items: center; align-content: start; gap: var(--space-xs); text-align: center; }
.road .stop { position: relative; display: block; width: 24px; height: 24px; border-radius: 50%; background: var(--color-paper); border: 3px solid var(--color-ink-2); }
.road li[aria-current="step"] .stop { background: var(--mark-4); border-color: var(--mark-4); box-shadow: 0 0 0 6px color-mix(in oklab, var(--mark-4) 22%, transparent); }
.road h3, .road .road__t { margin: var(--space-xs) 0 0; font-family: var(--font-display); font-weight: 500; font-size: var(--text-title); line-height: 1.15; letter-spacing: var(--tracking-display); color: var(--color-ink); }
.road p { max-width: 22ch; font-size: var(--text-sm); line-height: 1.45; color: var(--color-ink-2); }
.road li[aria-current="step"] .road__t { color: var(--mark-4-ink); }
@media (max-width: 60rem) {
  .hero { align-content: start; }
  .road { grid-template-columns: minmax(0, 1fr); gap: var(--space-lg); max-width: 34rem; margin-inline: auto; }
  .road::before { top: 12px; bottom: 12px; left: 10.5px; right: auto; width: 3px; height: auto; }
  .road li { grid-template-columns: 24px minmax(0, 1fr); justify-items: start; column-gap: var(--space-md); text-align: left; }
  .road .stop { grid-row: 1 / span 2; }
  .road .road__t { margin: 0; }
  .road p { grid-column: 2; max-width: 40ch; }
  .road__label { text-align: left; max-width: 34rem; margin-inline: auto; }
}
@media (max-height: 760px) and (min-width: 60rem) {
  .hero h1 { font-size: clamp(2.25rem, 2.6vw + 1rem, 3.5rem); }
  .hero .lead { font-size: var(--text-md); }
  .hero__in { gap: var(--space-xl); }
}

/* ---------- sections ---------- */
.sec { position: relative; padding-block: var(--section-gap); }
.sec--s { padding-block: var(--section-gap-s); }
.sec--alt { background: var(--color-paper-2); }
.head { display: grid; justify-items: center; gap: var(--space-md); margin-bottom: var(--space-2xl); text-align: center; }
.head .lead { margin-inline: auto; color: var(--color-muted); }
.panel { position: relative; padding: var(--space-xl); border-radius: var(--radius-card); background: color-mix(in oklab, var(--color-light) 84%, transparent); box-shadow: var(--edge-light), var(--shadow-card); }
.panel h3 { margin-bottom: var(--space-md); }
.panel p + p { margin-top: var(--space-md); }
.more { display: flex; justify-content: center; margin-top: var(--space-2xl); }

.sides { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap-columns); }
.stage-note { max-width: 48rem; margin: var(--space-2xl) auto 0; padding: var(--space-lg) var(--space-xl); border: 1px solid var(--color-rule); border-radius: var(--radius-card); background: var(--color-light); text-align: center; font-size: var(--text-lead); line-height: 1.45; color: var(--color-ink); }

.fig { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-2xl); align-items: center; max-width: 72rem; margin: var(--space-4xl) auto 0; }
.fig__n { margin: 0; font-family: var(--font-display); font-weight: 500; font-size: clamp(4.5rem, 8vw + 1rem, 9rem); line-height: 0.95; letter-spacing: -0.03em; color: var(--color-ink); text-align: center; font-variant-numeric: tabular-nums; white-space: nowrap; }
.fig__t { font-size: var(--text-lead); line-height: 1.45; color: var(--color-ink); }
.fig__src { margin-top: var(--space-md); font-size: var(--text-sm); color: var(--color-muted); }

.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-2xl) var(--gap-columns); margin: 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { counter-increment: step; display: grid; align-content: start; gap: var(--space-sm); }
.steps li::before { content: counter(step); font-family: var(--font-display); font-weight: 500; font-size: var(--text-3xl); line-height: 1; color: var(--color-ink); padding-bottom: var(--space-sm); border-bottom: 4px solid var(--mark-1); justify-self: start; min-width: 3.5rem; }
.steps li:nth-child(4n + 2)::before { border-color: var(--mark-2); }
.steps li:nth-child(4n + 3)::before { border-color: var(--mark-3); }
.steps li:nth-child(4n + 4)::before { border-color: var(--mark-4); }
.steps h3 { margin-top: var(--space-xs); }

.rows { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--color-rule); }
.rows li { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--gap-columns); align-items: baseline; padding-block: var(--space-xl); border-bottom: 1px solid var(--color-rule); }
.rows h3 { max-width: none; }
.rows p a { overflow-wrap: anywhere; }

.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap-columns); }
.grid2 .panel { min-height: 0; }

.film { max-width: 70rem; margin-inline: auto; }
.film video { width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius-card); background: var(--color-ink); box-shadow: var(--shadow-cast); }
.film figcaption { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-xs) var(--space-lg); margin-top: var(--space-lg); font-size: var(--text-sm); color: var(--color-muted); text-align: center; }
.transcript { max-width: 46rem; margin: var(--space-2xl) auto 0; }
.transcript h2 { font-size: var(--text-2xl); margin-bottom: var(--space-lg); }
.transcript p + p { margin-top: var(--space-md); }

.close { position: relative; isolation: isolate; overflow: clip; padding-block: var(--section-gap-l); background: var(--color-paper); border-top: 1px solid var(--color-rule); }
.close__in { position: relative; z-index: var(--z-base); display: grid; justify-items: center; gap: var(--space-lg); text-align: center; }
.close .lead { margin-inline: auto; color: var(--color-ink-2); }
.close h2 { font-size: var(--text-display-s); }

/* inner page header */
.phead { padding-block: var(--space-3xl) var(--space-xl); text-align: center; }
.phead__in { display: grid; justify-items: center; gap: var(--space-lg); }
.phead h1 { font-size: var(--text-display-s); max-width: 22ch; margin-inline: auto; }
.phead .lead { margin-inline: auto; color: var(--color-ink-2); }
.phead + .sec { padding-top: var(--space-2xl); }

/* the criteria lens (technology) */
.lens { display: grid; grid-template-columns: minmax(0, 5fr) auto minmax(0, 6fr); gap: var(--space-xl); align-items: center; }
.lens__src { font-size: var(--text-lead); line-height: 1.6; color: var(--color-ink); }
.lens__src mark { background: none; color: inherit; text-decoration: underline; text-decoration-thickness: 4px; text-underline-offset: 0.22em; text-decoration-skip-ink: none; }
.lens .k1 { text-decoration-color: var(--mark-1); } .lens .k2 { text-decoration-color: var(--mark-2); } .lens .k3 { text-decoration-color: var(--mark-3); } .lens .k4 { text-decoration-color: var(--mark-4); }
.lens__arrow { width: 96px; color: var(--color-ink); }
.lens__arrow svg { width: 96px; height: auto; }
.facts { margin: 0; }
.facts div { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: var(--space-md); align-items: baseline; padding-block: var(--space-md); border-bottom: 1px solid var(--color-rule); }
.facts div:first-child { border-top: 1px solid var(--color-rule); }
.facts dt { display: flex; align-items: baseline; gap: var(--space-sm); font-size: var(--text-sm); color: var(--color-muted); }
.facts dt i { flex: none; width: 18px; height: 4px; border-radius: 2px; transform: translateY(-3px); }
.facts dt .k1 { background: var(--mark-1); } .facts dt .k2 { background: var(--mark-2); } .facts dt .k3 { background: var(--mark-3); } .facts dt .k4 { background: var(--mark-4); }
.facts dd { margin: 0; font-weight: 600; color: var(--color-ink); }
.lens__cap { margin-top: var(--space-lg); text-align: center; font-size: var(--text-sm); color: var(--color-muted); }
.lens .lens__h { margin: 0 0 var(--space-md); max-width: none; text-align: left; font-size: var(--text-md); font-family: var(--font-body); font-weight: 600; letter-spacing: 0; line-height: 1.3; color: var(--color-muted); }

/* founder */
.person { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--space-xl); align-items: center; max-width: 52rem; margin-inline: auto; }
.person__photo { display: block; width: 260px; height: auto; aspect-ratio: 3 / 4; object-fit: cover; object-position: 50% 30%; border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.person__mono { display: grid; place-items: center; width: 132px; height: 132px; border-radius: 50%; background: var(--color-ink); color: var(--color-accent-ink); font-family: var(--font-display); font-weight: 500; font-size: var(--text-2xl); letter-spacing: 0.02em; }
.person h3 { margin-bottom: var(--space-2xs); }
.person .role { font-size: var(--text-sm); color: var(--color-muted); margin-bottom: var(--space-md); }
.person .btn { margin-top: var(--space-lg); }
.linkrow { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-sm); margin-top: var(--space-xl); }

/* contact form */
.contact { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--space-2xl); align-items: start; }
.form { display: grid; gap: var(--space-sm); }
.field { display: grid; gap: var(--space-xs); }
.field label, .field .lbl { font-size: var(--text-sm); font-weight: 600; color: var(--color-ink); }
.field .opt { font-weight: 400; color: var(--color-muted); }
.input, .select__btn, textarea.input { width: 100%; min-height: 52px; padding: 0 var(--space-md); border: 1px solid var(--color-muted); border-radius: var(--radius-inner); background: var(--color-light); color: var(--color-ink); font-size: var(--text-md); outline: 2px solid transparent; outline-offset: 1px; transition: border-color var(--dur-short) var(--ease-out); }
textarea.input { min-height: 172px; padding-block: var(--space-sm); line-height: 1.5; resize: vertical; }
.input::placeholder { color: var(--color-muted); }
.input:hover, .select__btn:hover { border-color: var(--color-ink-2); }
.input:focus-visible, .select__btn:focus-visible { outline-color: var(--color-focus); }
.input[aria-invalid="true"], .select__btn[aria-invalid="true"] { border-color: var(--color-error); }
.err { min-height: 1.4em; font-size: var(--text-sm); color: var(--color-error); }
.select { position: relative; }
.select__btn { display: flex; align-items: center; justify-content: space-between; gap: var(--space-sm); text-align: left; cursor: pointer; }
.select__btn span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.select__btn .ph { color: var(--color-muted); }
.select__btn svg { flex: none; width: 16px; height: 16px; transition: transform var(--dur-short) var(--ease-out); }
.select__btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.select__list { position: absolute; left: 0; right: 0; top: calc(100% + var(--space-2xs)); z-index: var(--z-dropdown); max-height: 18rem; overflow-y: auto; margin: 0; padding: var(--space-2xs); list-style: none; background: var(--color-light); border: 1px solid var(--color-rule); border-radius: var(--radius-inner); box-shadow: var(--shadow-card); }
.select__list li { display: flex; align-items: center; min-height: 44px; padding: var(--space-xs) var(--space-sm); border-radius: var(--radius-key); cursor: pointer; color: var(--color-ink); }
.select__list li[aria-selected="true"] { font-weight: 600; }
.select__list li.is-active { background: var(--color-paper-3); }
.check { position: relative; }
.check label { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: var(--space-sm); align-items: start; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check .box { display: grid; place-items: center; width: 28px; height: 28px; margin-top: var(--space-3xs); border: 2px solid var(--color-muted); border-radius: 7px; background: var(--color-light); cursor: pointer; outline: 2px solid transparent; outline-offset: 2px; }
.check .box svg { width: 16px; height: 16px; color: var(--color-accent-ink); opacity: 0; }
.check input:checked + label .box { background: var(--color-ink); border-color: var(--color-ink); }
.check input:checked + label .box svg { opacity: 1; }
.check input:focus-visible + label .box { outline-color: var(--color-focus); }
.check input[aria-invalid="true"] + label .box { border-color: var(--color-error); }
.check label { font-size: var(--text-sm); font-weight: 400; line-height: 1.5; color: var(--color-ink-2); cursor: pointer; }
.form .btn { justify-self: start; }
.aside { display: grid; gap: var(--space-md); }
.aside .aside__h { font-size: var(--text-title); text-align: left; margin: 0; max-width: none; }
.mail { display: flex; flex-wrap: wrap; gap: var(--space-sm); align-items: center; }
.mail a { font-weight: 600; color: var(--color-ink); overflow-wrap: anywhere; }
.hint { font-size: var(--text-sm); color: var(--color-muted); }
.ready { display: grid; gap: var(--space-md); }
.ready h2 { font-size: var(--text-2xl); text-align: left; margin: 0; }
.ready__actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); }
.ready pre { margin: 0; max-height: 14rem; overflow: auto; padding: var(--space-md); border-radius: var(--radius-inner); background: var(--color-paper-2); font: var(--text-sm)/1.5 var(--font-body); color: var(--color-ink-2); white-space: pre-wrap; overflow-wrap: anywhere; }
.ready ol { margin: 0; padding-left: var(--space-lg); display: grid; gap: var(--space-xs); }
.ready h3 { font-size: var(--text-md); font-family: var(--font-body); font-weight: 600; letter-spacing: 0; }
.status { min-height: 1lh; font-size: var(--text-sm); font-weight: 600; color: var(--color-success); }

/* long documents */
.doc { max-width: 46rem; margin-inline: auto; }
.doc h2 { font-size: var(--text-2xl); text-align: left; margin: var(--space-2xl) 0 var(--space-md); max-width: none; }
.doc h2:first-child { margin-top: 0; }
.doc p + p, .doc ul + p, .doc p + ul { margin-top: var(--space-md); }
.doc ul { padding-left: var(--space-lg); display: grid; gap: var(--space-xs); }
.doc a { overflow-wrap: anywhere; }
.doc .updated { margin-top: var(--space-2xl); font-size: var(--text-sm); color: var(--color-muted); }

/* footer */
.ftr { padding-block: var(--space-2xl) var(--space-xl); background: var(--color-paper-2); border-top: 1px solid var(--color-rule); font-size: var(--text-xs); }
.ftr__in { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-lg) var(--space-2xl); align-items: start; }
.ftr p, .ftr li { color: var(--color-muted); }
.ftr__brand svg { height: 30px; width: auto; margin-bottom: var(--space-sm); }
.ftr ul { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-xs) var(--space-lg); margin: 0; padding: 0; list-style: none; }
.ftr a { color: var(--color-ink-2); }
.ftr__legal { grid-column: 1 / -1; padding-top: var(--space-md); border-top: 1px solid var(--color-rule); }

/* 404 */
.lost { min-height: calc(100svh - var(--hh) - 12rem); display: grid; align-content: center; justify-items: center; gap: var(--space-lg); padding-block: var(--space-3xl); text-align: center; }

@media (max-width: 60rem) {
  .sides, .grid2, .contact { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fig { grid-template-columns: minmax(0, 1fr); gap: var(--space-lg); text-align: center; }
  .rows li { grid-template-columns: minmax(0, 1fr); gap: var(--space-sm); padding-block: var(--space-lg); }
  .lens { grid-template-columns: minmax(0, 1fr); }
  .lens__arrow { justify-self: center; transform: rotate(90deg); }
  .ftr__in { grid-template-columns: minmax(0, 1fr); }
  .ftr ul { justify-content: flex-start; }
}
@media (max-width: 40rem) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .panel { padding: var(--space-lg); }
  .person { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
  .person__photo { display: block; width: 260px; height: auto; aspect-ratio: 3 / 4; object-fit: cover; object-position: 50% 30%; border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.person__mono { width: 104px; height: 104px; }
  .stage-note { padding: var(--space-md) var(--space-lg); font-size: var(--text-md); }
  .facts div { grid-template-columns: minmax(0, 1fr); gap: var(--space-2xs); }
}

/* one reveal */
.js [data-reveal] { opacity: 0; transform: translateY(8px); transition: opacity var(--dur-long) var(--ease-out), transform var(--dur-long) var(--ease-out); }
.js [data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .nav a, .btn, .lang__btn, .lang__btn svg, .select__btn svg { transition: none; }
}
@media print { .hdr, .light, .pause, .close { display: none; } }

/* logo colours */
.logo .s-ink { stroke: var(--color-ink); } .logo .f-ink { fill: var(--color-ink); }
.logo .s-v { stroke: var(--mark-1); } .logo .s-a { stroke: var(--mark-2); } .logo .s-g { stroke: var(--mark-3); } .logo .f-u { fill: var(--mark-4); }
.lens__arrow .s-ink-c { stroke: var(--color-ink); } .lens__arrow .s-v-c { stroke: var(--mark-1); } .lens__arrow .s-a-c { stroke: var(--mark-2); } .lens__arrow .s-g-c { stroke: var(--mark-3); } .lens__arrow .s-u-c { stroke: var(--mark-4); }
.lens-fig { margin: 0; }
@media (max-width: 40rem) { h1, h2, h3 { hyphens: manual; } }
@media (max-width: 22.5rem) { .nav a { padding: 0 var(--space-xs); font-size: 0.875rem; } .nav ul { gap: var(--space-2xs); } }
h1, h2, h3, .road__t { text-wrap: pretty; }
@media (max-width: 40rem) { :root { --text-section: 1.75rem; --text-display-s: 2rem; --text-title: 1.25rem; } }
/* Ukrainian: Jost's Cyrillic uses Greek-like letter forms; headings switch to the body family for easier reading */
:lang(uk) { --font-display: "Commissioner", ui-sans-serif, system-ui, sans-serif; --display-weight: 600; --tracking-display: -0.015em; }
:lang(uk) .road__t, :lang(uk) .fig__n, :lang(uk) .steps li::before { font-weight: 600; }
.hero + .sec { padding-top: var(--section-gap-l); }

@media (max-width: 60rem) { .contact .aside { order: -1; } }
@media (max-width: 26rem) { :lang(uk) .hero h1 { font-size: 1.875rem; } }
@media (max-width: 22.5rem) { :lang(uk) .hero h1, :lang(de) .hero h1 { font-size: 1.75rem; } }
.road li.done .stop { background: var(--color-ink-2); border-color: var(--color-ink-2); }
.road li.done .road__t { color: var(--color-ink-2); }
