/* The inner pages. tokens.css, base.css and site.css are linked before this file; it adds the page hero, the
   dust figure and the section kinds the pages are built from. Colour is the same flat palette: a black page,
   near-black frames, white ink, one blue and one green. */

/* ---------- Page hero ---------- */

.phero { position: relative; padding-top: calc(var(--nav-clear) + var(--space-3xl)); padding-bottom: var(--space-3xl); }
.phero__inner { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xl); align-items: center; }
.phero__copy { grid-column: 1 / span 6; min-width: 0; position: relative; z-index: 1; }
.phero__title { font-size: clamp(2.5rem, 4.2vw, 3.5rem); line-height: var(--leading-display); letter-spacing: var(--tracking-display); }
.phero__lead { margin-top: var(--space-lg); max-width: 34em; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
.phero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-sm) var(--space-lg); margin-top: var(--space-xl); }
.phero .figure { grid-column: 7 / -1; margin-right: calc(-1 * var(--gutter)); aspect-ratio: 1 / 1; }
.phero__title { --i: 0; }
.phero__lead { --i: 1; }
.phero__actions { --i: 2; }
/* The settle: visible by default, hidden only under html.js until pages.js runs it; a 2s net if it never does. */
html.js:not(.rm) .phero:not(.is-settled) [data-settle] { animation: show 0s 2s forwards; }
html.js:not(.rm) .phero.is-settled [data-settle] {
  opacity: 1; transform: none;
  transition: opacity var(--dur-settle-fade) var(--ease-reveal-fade), transform var(--dur-settle) var(--ease-reveal);
  transition-delay: calc(var(--i) * var(--stagger-settle));
}
@media (max-width: 59.99rem) {
  .phero { padding-top: calc(var(--nav-clear) + var(--space-xl)); padding-bottom: var(--space-2xl); }
  .phero__copy, .phero .figure { grid-column: 1 / -1; }
  .phero .figure { margin-inline: calc(-1 * var(--gutter)); aspect-ratio: 1 / 1; }
}

/* The contact page opens on the home hero's flat blue field. */
.page--contact .phero { min-height: 100svh; padding-top: calc(var(--nav-clear) + var(--space-lg)); background: var(--color-field-hero); color: var(--color-ink); }
.page--contact .phero__lead { color: var(--color-ink); }

/* ---------- The dust figure (figure.js draws it; hidden without JS, where it would stay blank) ---------- */

.figure { position: relative; min-width: 0; aspect-ratio: 4 / 3; pointer-events: auto; }
.figure > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
html:not(.js) .figure { display: none; }
/* Without the figure, the words beside it take its room. */
html:not(.js) .steps__side { grid-column: 1 / -1; }
@media (min-width: 60rem) {
  html:not(.js) :is(.phero__copy, .pframe__copy) { grid-column: 1 / span 8; }
}

/* ---------- Sections ---------- */

/* Every frame has a 1px inner edge, so it reads as a surface on the black page. */
.statement, .pframe, .picker, .steps, .pcard, .contact__card { box-shadow: inset 0 0 0 1px var(--color-frame-edge); }
@media (hover: hover) and (pointer: fine) {
  .pcard:hover { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-ink) 28%, transparent); }
  .row:has(.row__go:hover) .row__name { transform: translateX(var(--space-xs)); }
}
html.js:not(.rm) .pcard { transition: box-shadow var(--dur-short) var(--ease-out); }
html.js:not(.rm) .row__name { transition: transform 350ms var(--ease-quint); }

.psection { padding-block: var(--section-gap-s); }
.psection__head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-lg); align-items: end; margin-bottom: var(--space-2xl); }
.psection__head > h2 { grid-column: 1 / span 6; }
.psection__lede { grid-column: 8 / -1; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
/* Under a view: the one link on from it. Under a run of cards: one line of small print. */
.view__more { margin-top: var(--space-lg); }
.psection__note { margin-top: var(--space-xl); color: var(--color-ink-3); }
@media (max-width: 59.99rem) {
  .psection__head > h2, .psection__lede { grid-column: 1 / -1; }
}

/* Statements: one frame each, the head on the left and its sentences on the right. */
.statement { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-lg); align-items: center; min-width: 0; min-height: 20rem; padding: var(--space-2xl); border-radius: var(--radius-frame); background: var(--color-paper-2); color: var(--color-ink); }
.statement > h2 { grid-column: 1 / span 6; }
/* With a product view beside it, the words take four columns and the view takes the rest. */
.statement--viz { align-items: start; row-gap: var(--space-2xl); }
.statement--viz > h2 { grid-column: 1 / span 4; }
.statement--viz > .statement__body { grid-column: 1 / span 4; grid-row: 2; }
.statement--viz > .visual { grid-column: 6 / -1; grid-row: 1 / span 2; }
.statement__body { grid-column: 8 / -1; display: grid; gap: var(--space-md); font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
@media (max-width: 59.99rem) {
  .statement { min-height: 0; padding: var(--space-xl) var(--space-lg); }
  .statement > h2, .statement__body { grid-column: 1 / -1; }
  .statement--viz > h2, .statement--viz > .statement__body, .statement--viz > .visual { grid-column: 1 / -1; grid-row: auto; }
}

/* Rows: a name and its sentence, parted by hairlines. A row with a link is one hit area, marked by an arrow. */
.rows { margin: 0; padding: 0; list-style: none; border-bottom: 1px solid var(--color-rule); }
.row { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xs); align-items: baseline; padding-block: var(--space-xl); border-top: 1px solid var(--color-rule); }
.row__name { grid-column: 1 / span 4; max-width: none; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.row__body { grid-column: 5 / span 6; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
.row__go { color: inherit; text-decoration: none; }
.row__go::after { content: ""; position: absolute; inset: 0; }
.row__arrow { grid-column: 12; justify-self: end; align-self: center; color: var(--color-ink-3); }
.row:has(.row__go) { padding-inline: var(--space-md); margin-inline: calc(-1 * var(--space-md)); border-radius: var(--radius-card); }
@media (hover: hover) and (pointer: fine) {
  .row:has(.row__go:hover) { background: color-mix(in srgb, var(--color-ink) 6%, transparent); }
  .row:has(.row__go:hover) .row__arrow { color: var(--color-ink); transform: translateX(4px); }
}
.row__go:focus-visible { outline: none; }
.row:has(.row__go:focus-visible) { outline: 2px solid var(--color-focus); outline-offset: 2px; }
html.js:not(.rm) .row { transition: background-color var(--dur-short) var(--ease-out); }
html.js:not(.rm) .row__arrow { transition: transform var(--dur-short) var(--ease-out), color var(--dur-short) var(--ease-out); }
@media (max-width: 59.99rem) {
  .row__name, .row__body { grid-column: 1 / span 11; }
  .row__arrow { grid-row: 1; }
}

/* Cards: near-black panels in two to four columns. */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: var(--gap-columns); }
.pcard { display: grid; align-content: space-between; gap: var(--space-xl); min-width: 0; min-height: 15rem; padding: var(--space-xl); border-radius: var(--radius-view); background: var(--color-paper-2); color: var(--color-ink); }
.pcard__title { max-width: none; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.pcard__body { color: var(--color-ink-2); }
.pcard .fill { justify-self: start; }

/* Frames: one stage of a test each, the words beside its figure. They open as they scroll in (shell.js). */
/* Frames sit a screen apart, so one idea fills a screen. */
.frames { display: grid; gap: var(--space-4xl); }
.pframe { overflow: clip; min-height: 27rem; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-lg); align-items: center; min-width: 0; padding: var(--space-2xl); border-radius: var(--radius-frame); background: var(--color-paper-2); color: var(--color-ink); }
.pframe__copy { grid-column: 1 / span 5; min-width: 0; }
.pframe__title { max-width: none; font-size: var(--text-card); line-height: var(--leading-card); letter-spacing: var(--tracking-card); }
/* The pain line: a truth about the reader's world, set against the promise above it. */
.pframe__pain { margin-top: var(--space-md); font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-3); }
.pframe__body { margin-top: var(--space-sm); font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
.pframe .figure { grid-column: 6 / -1; margin: calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) 0; aspect-ratio: 4 / 3; }
@media (max-width: 59.99rem) {
  .pframe { min-height: 0; padding: var(--space-xl) var(--space-lg); }
  .pframe__copy, .pframe .figure { grid-column: 1 / -1; }
  .pframe .figure { margin: 0 calc(-1 * var(--space-md)); }
}

/* A picker: the control, then one panel at a time inside a frame. Without JS the panels stack. */
.picker { overflow: clip; display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-2xl); min-width: 0; padding: var(--space-2xl); border-radius: var(--radius-frame); background: var(--color-paper-2); color: var(--color-ink); }
.picker__top { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-lg); align-items: center; }
.picker__control { grid-column: 1 / span 4; min-width: 0; }
.picker__top .figure { grid-column: 5 / -1; margin: calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) 0 0; aspect-ratio: 16 / 10; }
.picker__control--row { grid-column: 1 / -1; }
.picker__panels { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-2xl); min-width: 0; }
.panel { min-width: 0; }
.panel__name { max-width: none; font-size: var(--text-card); line-height: var(--leading-card); letter-spacing: var(--tracking-card); }
.panel__line { margin-top: var(--space-sm); max-width: 44em; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
.panel__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: var(--space-xl) var(--gap-columns); margin-top: var(--space-xl); }
.panel__col > h4 { margin: 0 0 var(--space-sm); font-size: var(--text-md); font-weight: var(--weight-text); line-height: var(--leading-body); color: var(--color-ink-3); }
.panel__list { margin: 0; padding: 0; list-style: none; }
.panel__list > li { padding-block: var(--space-md); border-top: 1px solid var(--color-rule); }
.panel__col > p { padding-top: var(--space-md); border-top: 1px solid var(--color-rule); }
html.js .picker.is-ready [data-panel].is-entering { opacity: 0; transform: translateY(8px); }
html.js:not(.rm) .picker.is-ready [data-panel].is-in { transition: opacity 400ms var(--ease-std), transform 400ms var(--ease-std); }
/* Until pages.js builds the control, only the first panel shows, so the frame does not jump. */
html.js .picker:not(.is-ready) [data-panel] ~ [data-panel] { display: none; }
@media (max-width: 59.99rem) {
  .picker { padding: var(--space-xl) var(--space-lg); }
  .picker__control, .picker__top .figure { grid-column: 1 / -1; }
  .picker__top .figure { margin: 0 calc(-1 * var(--space-md)); aspect-ratio: 4 / 3; }
}

/* The requirements of the compliance page: a table with room in it. Under 60rem each row stacks, and each cell
   carries its column's name. */
.reqs { width: 100%; margin-top: var(--space-xl); border-collapse: collapse; text-align: left; }
.reqs th, .reqs td { padding: var(--space-xl) var(--space-lg) var(--space-xl) 0; border-top: 1px solid var(--color-rule); vertical-align: top; font-weight: var(--weight-text); }
.reqs thead th { padding-block: var(--space-md); border-top: 0; color: var(--color-ink-3); }
.reqs tbody th { width: 26%; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); color: var(--color-ink); }
.reqs td { width: 37%; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink-2); }
.reqs td:last-child { padding-right: 0; color: var(--color-ink); }
@media (max-width: 59.99rem) {
  .reqs, .reqs tbody, .reqs tr, .reqs th, .reqs td { display: block; }
  .reqs tbody th, .reqs td { width: auto; }
  .reqs thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .reqs tr { padding-block: var(--space-lg); border-top: 1px solid var(--color-rule); }
  .reqs th, .reqs td { padding: 0; border: 0; }
  .reqs td { margin-top: var(--space-sm); }
  .reqs td::before { content: attr(data-label); display: block; font-size: var(--text-md); line-height: var(--leading-body); color: var(--color-ink-3); }
}

/* The sample report: the figure, the six steps as buttons, the lines under them. */
.steps { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xl); align-items: start; min-width: 0; padding: var(--space-2xl); border-radius: var(--radius-frame); background: var(--color-paper-2); color: var(--color-ink); }
.steps .figure { grid-column: 1 / span 7; position: sticky; top: var(--nav-clear); }
.steps__side { grid-column: 8 / -1; min-width: 0; }
.steps__list { display: grid; gap: var(--space-2xs); margin: 0; padding: 0; list-style: none; counter-reset: step; }
/* Each step: its number, then its sentence. Without JS the number is a counter; with JS it is a button. */
.steps__item { counter-increment: step; display: grid; grid-template-columns: var(--control-hit) minmax(0, 1fr); column-gap: var(--space-sm); align-items: center; min-height: var(--control); padding: var(--space-xs) var(--space-sm); border-radius: var(--radius-input); color: var(--color-ink-2); }
.steps:not(.is-ready) .steps__item::before { content: counter(step); justify-self: center; color: var(--color-ink-3); }
.steps.is-ready .steps__item { cursor: pointer; }
.steps__item.is-current { background: color-mix(in srgb, var(--color-ink) 10%, transparent); color: var(--color-ink); }
.steps__num {
  font-variant-numeric: tabular-nums;
  display: grid; place-items: center; width: var(--control-hit); height: var(--control-hit); padding: 0;
  border: 1px solid var(--color-rule); border-radius: 50%; background: none; color: var(--color-ink-2);
  font-size: var(--text-md); line-height: 1; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.steps__num[aria-current="step"] { border-color: var(--color-ink); background: var(--color-ink); color: var(--color-paper); }
@media (hover: hover) and (pointer: fine) {
  .steps.is-ready .steps__item:hover { color: var(--color-ink); }
  .steps__item:hover .steps__num:not([aria-current="step"]) { border-color: var(--color-ink-3); }
}
.steps__num:active { transform: scale(0.95); }
html.js:not(.rm) .steps__item { transition: background-color var(--dur-short) var(--ease-out), color var(--dur-short) var(--ease-out); }
html.js:not(.rm) .steps__num { transition: transform var(--dur-micro) var(--ease-out), border-color var(--dur-short) var(--ease-out); }
.steps__after { display: grid; justify-items: start; gap: var(--space-md); margin-top: var(--space-xl); padding-top: var(--space-xl); border-top: 1px solid var(--color-rule); color: var(--color-ink-2); }
.steps__after .btn[aria-pressed="true"] { border-color: var(--color-defense); }
.steps__line { min-height: 1lh; color: var(--color-ink); }
/* How a step was produced (run, stand-in, reach shown): a small grey tag after its sentence. */
.steps__way { display: inline-block; margin-left: var(--space-2xs); padding: 0 var(--space-xs); border-radius: var(--radius-pill); box-shadow: inset 0 0 0 1px var(--color-rule); color: var(--color-ink-3); white-space: nowrap; }
.steps__item.is-current .steps__way { box-shadow: inset 0 0 0 1px var(--color-ink-3); color: var(--color-ink-2); }
.steps__whatif { color: var(--color-ink-3); }
@media (max-width: 59.99rem) {
  .steps { padding: var(--space-xl) var(--space-lg); }
  .steps .figure, .steps__side { grid-column: 1 / -1; }
  .steps .figure { position: relative; top: auto; }
}

/* The stop control of the safety page, under its figure. */
.stop { display: grid; justify-items: start; gap: var(--space-md); }
.stop__line { min-height: 1lh; margin-top: var(--space-md); color: var(--color-ink); }

/* The contact form sits on a near-black card over the blue field. */
.contact { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xl); align-items: start; }
.contact .phero__copy { grid-column: 1 / span 5; }
.contact__card { grid-column: 7 / -1; min-width: 0; padding: var(--space-xl); border-radius: var(--radius-frame); background: var(--color-paper-2); color: var(--color-ink); }
.contact__card .form { margin-top: 0; gap: var(--space-md); }
.form__input--area { min-height: 5.5rem; padding-block: var(--space-sm); resize: vertical; }
@media (max-width: 59.99rem) {
  .contact .phero__copy, .contact__card { grid-column: 1 / -1; }
}

/* The closing frame: one flat blue field. The question and the one action on the left; on the right a sample
   attack runs across white dust and stops at a green ring. */
.cta { padding-block: var(--section-gap-s) var(--space-2xl); }
.cta__frame { overflow: clip; --color-dust-internal: var(--color-ink); display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap-columns); row-gap: var(--space-xl); align-items: center; width: calc(100% - 2 * var(--gutter)); max-width: var(--container); margin-inline: auto; padding: var(--space-2xl); border-radius: var(--radius-frame); background: var(--color-field-hero); color: var(--color-ink); }
.cta__copy { grid-column: 1 / span 6; display: grid; justify-items: start; gap: var(--space-lg); min-width: 0; }
.cta__copy > h2 { max-width: 18ch; }
.cta__frame .h2__second { color: var(--color-ink-2); }
.cta__line { max-width: 34em; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--color-ink); }
.cta__frame .figure { grid-column: 6 / -1; margin: calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)) 0; aspect-ratio: 4 / 3; }
@media (max-width: 59.99rem) {
  .cta__frame { padding: var(--space-2xl) var(--space-lg); }
  .cta__copy, .cta__frame .figure { grid-column: 1 / -1; }
  .cta__frame .figure { margin: 0 calc(-1 * var(--space-md)); }
}

/* What happens next, on the contact page; and, ahead of its fields, the line that says the form is not
   connected, with two things to do instead. */
.contact__next { display: grid; gap: var(--space-sm); margin: var(--space-xl) 0 0; padding-left: 1.4em; --i: 2; }
.contact__next > li { padding-left: var(--space-xs); }
.form__state { margin-bottom: var(--space-lg); padding-bottom: var(--space-sm); border-bottom: 1px solid var(--color-rule); color: var(--color-ink); }
.form__next { display: flex; flex-wrap: wrap; gap: 0 var(--space-lg); margin-top: var(--space-2xs); color: var(--color-ink-2); }

/* ---------- Visuals other than the estate: figures from named reports, a scoreboard, strips, a dial ---------- */

.visual { min-width: 0; margin: 0; }
.phero .visual { grid-column: 8 / -1; }
.pframe .visual { grid-column: 7 / -1; }
.statement .visual { color: var(--color-ink); font-size: var(--text-md); line-height: var(--leading-body); }
@media (max-width: 59.99rem) {
  .phero .visual, .pframe .visual { grid-column: 1 / -1; }
}

/* Figures from named reports: a large value, what it measures, a bar true to scale, the source. */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr)); gap: var(--gap-columns); }
.stat { display: grid; grid-template-rows: auto 1fr auto; gap: var(--space-xl); min-width: 0; padding: var(--space-xl); border-radius: var(--radius-view); background: var(--color-paper-2); box-shadow: inset 0 0 0 1px var(--color-frame-edge); color: var(--color-ink); }
.stat__label { max-width: none; font-size: var(--text-md); line-height: var(--leading-body); letter-spacing: 0; color: var(--color-ink-3); }
.stat__rows { display: grid; align-content: start; gap: var(--space-lg); margin: 0; }
.stat__row { display: grid; gap: var(--space-2xs); }
.stat__value { order: -1; margin: 0; font-size: clamp(2.25rem, 3.6vw, 3.25rem); line-height: 1; letter-spacing: var(--tracking-display); font-variant-numeric: tabular-nums; color: var(--color-ink); }
.stat__row + .stat__row .stat__value { color: var(--color-ink-3); }
.stat__name { color: var(--color-ink-2); }
.stat__track { position: relative; display: block; height: 6px; margin-top: var(--space-sm); }
.stat__track::before { content: ""; position: absolute; left: 0; right: 0; top: 2.5px; height: 1px; background: var(--color-rule); }
.stat__track::after { content: ""; position: absolute; left: 0; top: 0; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.stat__bar { position: absolute; inset: 0; border-radius: 3px; background: currentColor; transform: scaleX(var(--v)); transform-origin: left center; }
.stat__source { color: var(--color-ink-3); }
html.js:not(.rm) [data-viz]:not(.is-live) .stat__bar { transform: scaleX(0); }
html.js:not(.rm) [data-viz].is-live .stat__bar { transition: transform 1200ms var(--ease-quint) 150ms; }
.now__rows { margin-top: var(--space-xl); }

/* The scoreboard: a mark where the attack met each defense. */
.board__table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.board__table th, .board__table td { padding: var(--space-sm) 0; border-top: 1px solid var(--color-rule); text-align: center; font-weight: var(--weight-text); }
.board__table thead th, .board__table thead td { border-top: 0; color: var(--color-ink-3); }
.board__table tbody th { padding-right: var(--space-md); text-align: left; color: var(--color-ink); }
/* A fixed table sizes its columns from its first row: the empty corner cell gives the names their room. */
.board__table thead tr > :first-child { width: 42%; }
.mark { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--color-rule); vertical-align: middle; }
.mark--failed { width: 16px; height: 16px; background: var(--color-ink); }
.mark--held { position: relative; width: 16px; height: 16px; background: none; box-shadow: inset 0 0 0 2px var(--color-defense); }
.mark--held::after { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: var(--color-defense); }
.board__legend { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-xs) var(--space-lg); margin-top: var(--space-lg); color: var(--color-ink-2); }
.board__key { display: inline-flex; align-items: center; gap: var(--space-xs); }
.board__note { color: var(--color-ink-3); }
html.js:not(.rm) [data-viz]:not(.is-live) .board__table .mark { transform: scale(0); }
html.js:not(.rm) [data-viz].is-live .board__table .mark { transition: transform 500ms var(--ease-quint); transition-delay: calc(var(--c) * 90ms); }

/* Strips: the steps an attack got through, and the ring where it stopped. */
.strips { display: grid; gap: var(--space-lg); }
.strip { display: grid; gap: var(--space-xs); }
.strip__name { color: var(--color-ink-2); }
.strip__track { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); align-items: center; gap: 6px; height: 16px; }
.seg { height: 6px; border-radius: 3px; background: var(--color-rule); }
.seg--on { background: var(--color-ink); }
.seg--stop { position: relative; }
.seg--stop::before { content: ""; position: absolute; left: 0; top: 50%; width: 16px; height: 16px; border-radius: 50%; background: var(--color-paper-2); box-shadow: inset 0 0 0 2px var(--color-defense); transform: translateY(-50%); }
.strip__end { color: var(--color-ink); }
.strips__note { color: var(--color-ink-3); }
html.js:not(.rm) [data-viz]:not(.is-live) :is(.seg--on, .seg--stop) { opacity: 0.12; }
html.js:not(.rm) [data-viz].is-live :is(.seg--on, .seg--stop) { transition: opacity 400ms var(--ease-out); transition-delay: calc(var(--i) * 160ms); }

/* The dial: 24 hours, midnight at the top, the test window drawn on the ring. */
.dial { display: grid; justify-items: start; gap: var(--space-md); }
.dial__face { position: relative; width: min(100%, 20rem); aspect-ratio: 1 / 1; }
.dial__face > svg { width: 100%; height: 100%; }
.dial__ring { fill: none; stroke: var(--color-rule); stroke-width: 10; }
.dial__ticks { fill: none; stroke: var(--color-ink-3); stroke-width: 1; }
.dial__arc { fill: none; stroke: var(--color-ink); stroke-width: 10; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.dial__text { position: absolute; inset: 0; display: grid; place-items: center; padding: 26%; text-align: center; font-size: var(--text-title); line-height: var(--leading-title); color: var(--color-ink); }
.dial__note { color: var(--color-ink-3); }
html.js:not(.rm) [data-viz]:not(.is-live) .dial__arc { stroke-dashoffset: 1; }
html.js:not(.rm) [data-viz].is-live .dial__arc { transition: stroke-dashoffset 1400ms var(--ease-quint) 150ms; }

/* ---------- Icons: one line glyph per starting point, on a 24px grid at one stroke weight ---------- */

.icon { flex: none; width: 24px; height: 24px; color: var(--color-ink-3); }
.icon--lead { width: 40px; height: 40px; margin-bottom: var(--space-lg); color: var(--color-ink); }
.stat__top { display: flex; align-items: center; gap: var(--space-sm); }
.row--icon { grid-template-areas: "icon name name name body body body body body body body arrow"; }
.row--icon > .icon { grid-area: icon; align-self: center; }
.row--icon > .row__name { grid-area: name; }
.row--icon > .row__body { grid-area: body; }
.row--icon > .row__arrow { grid-area: arrow; }
@media (max-width: 59.99rem) {
  .row--icon { grid-template-areas: "icon name name name name name name name name name name arrow" "body body body body body body body body body body body body"; }
}

/* ---------- Product views: a framed panel of the product, with sample data ---------- */

.pv { display: grid; align-content: start; min-width: 0; border-radius: var(--radius-view); background: var(--color-paper-2); box-shadow: inset 0 0 0 1px var(--color-frame-edge); color: var(--color-ink); overflow: clip; }
/* The bar is a step lighter than the body, so the panel reads as a surface with a head. */
.pv__bar { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-xs) var(--space-md); padding: var(--space-md) var(--space-lg); border-bottom: 1px solid var(--color-rule); background: var(--color-paper-3); }
.pv__title { color: var(--color-ink); }
.pv__state { color: var(--color-ink-3); }
.pv__body { display: grid; padding: var(--space-2xs) var(--space-lg) var(--space-md); }
.pv__row { display: grid; gap: var(--space-2xs) var(--space-md); padding-block: var(--space-lg); border-bottom: 1px solid var(--color-rule); }
.pv__row:last-child { border-bottom: 0; }
.pv__head { margin: var(--space-lg) 0 0; padding-top: var(--space-md); border-top: 1px solid var(--color-rule); color: var(--color-ink-3); }
.pv__head + .pv__row { border-top: 0; }
.pv__row--pair { grid-template-columns: minmax(0, 9rem) minmax(0, 1fr); align-items: baseline; }
.pv__label { color: var(--color-ink-3); }
.pv__value, .pv__text { color: var(--color-ink); min-width: 0; overflow-wrap: break-word; }
.pv__row--step { grid-template-columns: 1.75rem minmax(0, 1fr) auto; align-items: center; }
.pv__n { color: var(--color-ink-3); font-variant-numeric: tabular-nums; }
.pv__mark { display: inline-flex; }
.pv__row--fix { grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; }
.pv__closes { color: var(--color-ink-3); white-space: nowrap; }
.pv__row--line { grid-template-columns: minmax(0, 6rem) minmax(0, 1fr); align-items: baseline; }
.pv__time { color: var(--color-ink-3); font-variant-numeric: tabular-nums; }
.pv__foot { padding: var(--space-md) var(--space-lg); border-top: 1px solid var(--color-rule); color: var(--color-ink-3); }
html.js:not(.rm) [data-viz]:not(.is-live) .pv__row { opacity: 0; transform: translateY(6px); }
html.js:not(.rm) [data-viz].is-live .pv__row { transition: opacity 400ms var(--ease-out), transform 400ms var(--ease-quint); transition-delay: calc(var(--r, 0) * 70ms); }
@media (max-width: 39.99rem) {
  .pv__bar, .pv__foot { padding-inline: var(--space-md); }
  .pv__body { padding-inline: var(--space-md); }
  .pv__row--pair, .pv__row--line { grid-template-columns: minmax(0, 1fr); }
  .pv__row--fix { grid-template-columns: minmax(0, 1fr); }
  .pv__closes { white-space: normal; }
}

/* ---------- The comparison: the same estate before and after one fix, with a divider you drag ---------- */

.compare { display: grid; gap: var(--space-md); }
.compare__stage { --split: 50%; position: relative; isolation: isolate; overflow: clip; border-radius: var(--radius-view); background: var(--color-paper); box-shadow: inset 0 0 0 1px var(--color-frame-edge); aspect-ratio: 4 / 3; touch-action: pan-y; }
.compare.is-ready .compare__stage { cursor: ew-resize; }
.compare__layer { position: absolute; inset: 0; }
.compare__layer > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
/* The top layer is cut at the divider, so one estate turns into the other across the line. */
.compare.is-ready .compare__layer--before { clip-path: inset(0 calc(100% - var(--split)) 0 0); }
.compare__tag { position: absolute; left: var(--space-md); bottom: var(--space-md); margin: 0; padding: var(--space-2xs) var(--space-sm); border-radius: var(--radius-nav-btn); background: var(--color-glass-solid); color: var(--color-ink); }
.compare__layer--after .compare__tag { left: auto; right: var(--space-md); }
.compare__divider { position: absolute; top: 0; bottom: 0; left: var(--split); width: 1px; margin-left: -0.5px; background: var(--color-ink); }
.compare:not(.is-ready) .compare__divider, .compare:not(.is-ready) .compare__range { display: none; }
.compare__grip { position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border: 1px solid var(--color-ink); border-radius: 50%; background: var(--color-paper); }
.compare__grip::before, .compare__grip::after { content: ""; position: absolute; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-top: 1px solid var(--color-ink); border-right: 1px solid var(--color-ink); }
.compare__grip::before { left: 13px; transform: rotate(-135deg); }
.compare__grip::after { right: 13px; transform: rotate(45deg); }
.compare__stage.is-dragging .compare__grip { background: var(--color-paper-3); }
/* The range carries the divider for the keyboard: it lies over the foot of the stage, unseen until focused. */
.compare__range { position: absolute; left: 0; bottom: 0; width: 100%; height: 44px; margin: 0; opacity: 0; cursor: ew-resize; }
/* The keyboard's focus shows on the grip, not on the control itself. */
.compare__stage:has(.compare__range:focus-visible) .compare__grip { outline: 2px solid var(--color-focus); outline-offset: 3px; }
.compare__note { color: var(--color-ink-3); }
html.js:not(.rm) .compare__grip { transition: background-color var(--dur-short) var(--ease-out); }
/* Without JS the two states sit side by side, each with its own tag. */
html:not(.js) .compare__stage { display: grid; grid-template-columns: 1fr 1fr; aspect-ratio: 8 / 3; }
html:not(.js) .compare__layer { position: relative; }
@media (max-width: 59.99rem) {
  .compare__stage { aspect-ratio: 1 / 1; }
}

/* ---------- Rhythm: alternation, so a run of the same block never scrolls past as one long sameness ---------- */

/* Platform's stage frames swap sides, the visual right, then left, then right. */
@media (min-width: 60rem) {
  .frames > .pframe:nth-child(even) > .pframe__copy { grid-column: 8 / -1; grid-row: 1; }
  .frames > .pframe:nth-child(even) > .figure { grid-column: 1 / span 6; grid-row: 1; margin: calc(-1 * var(--space-xl)) 0 calc(-1 * var(--space-xl)) calc(-1 * var(--space-xl)); }
  .frames > .pframe:nth-child(even) > .visual { grid-column: 1 / span 6; grid-row: 1; }
  .frames > .statement--viz:nth-child(even) > h2,
  .frames > .statement--viz:nth-child(even) > .statement__body { grid-column: 9 / -1; }
  .frames > .statement--viz:nth-child(even) > .visual { grid-column: 1 / span 7; }
}
/* In a run of statements every second one is open: no frame, a hairline above, so the run reads as a beat. */
.frames > .statement:nth-child(even) { background: none; box-shadow: none; border-top: 1px solid var(--color-rule); border-radius: 0; padding-inline: 0; }

/* Read next: three linked cards side by side, each one a whole hit area. */
.next { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: var(--gap-columns); margin: 0; padding: 0; list-style: none; }
.next__item { min-width: 0; }
.next__link { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); align-content: space-between; gap: var(--space-xl); height: 100%; min-height: 13rem; padding: var(--space-xl); border-radius: var(--radius-view); background: var(--color-paper-2); box-shadow: inset 0 0 0 1px var(--color-frame-edge); color: var(--color-ink); text-decoration: none; }
.next__name { font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.next__body { color: var(--color-ink-2); }
.next__link .row__arrow { grid-column: auto; grid-row: auto; justify-self: end; align-self: end; color: var(--color-ink-3); }
@media (hover: hover) and (pointer: fine) {
  .next__link:hover { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-ink) 28%, transparent); }
  .next__link:hover .row__arrow { color: var(--color-ink); transform: translateX(4px); }
}
.next__link:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
html.js:not(.rm) .next__link { transition: box-shadow var(--dur-short) var(--ease-out); }
html.js:not(.rm) .next__link .row__arrow { transition: transform 400ms var(--ease-expo), color var(--dur-short) var(--ease-out); }
