/* Evolving shorter tours.
   The hero and the demo sit on a permanently dark ground - they are the
   instrument, and instruments read better lit from behind. The article below
   follows the reader's theme. Cyan is reserved for whatever the algorithm is
   doing right now; amber for the reference it is measured against. */

:root {
  /* Article palette - light by default. */
  --ground: #f7f8fa;
  --surface: #ffffff;
  --raised: #eef1f5;
  --ink: #0b1219;
  --muted: #5a6b7c;
  --rule: #dce3ea;
  --accent: #0c7c8e;
  --accent-2: #96600a;
  --accent-wash: rgba(12, 124, 142, 0.1);
  --accent-2-wash: rgba(150, 96, 10, 0.12);

  /* The night palette, used by the hero and the demo in both themes. */
  --night-ground: #080c11;
  --night-surface: #101821;
  --night-raised: #17212c;
  --night-ink: #eaf1f7;
  --night-muted: #7e92a6;
  --night-rule: #1e2b38;
  --night-accent: #4fd8e8;
  --night-accent-2: #f5a93c;

  --display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --body: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --shell: 1140px;
  --rail: 230px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #0a0f14;
    --surface: #111820;
    --raised: #161e28;
    --ink: #e9eff5;
    --muted: #8194a6;
    --rule: #1e2833;
    --accent: #4fd8e8;
    --accent-2: #f5a93c;
    --accent-wash: rgba(79, 216, 232, 0.12);
    --accent-2-wash: rgba(245, 169, 60, 0.14);
  }
}

:root[data-theme="dark"] {
  --ground: #0a0f14;
  --surface: #111820;
  --raised: #161e28;
  --ink: #e9eff5;
  --muted: #8194a6;
  --rule: #1e2833;
  --accent: #4fd8e8;
  --accent-2: #f5a93c;
  --accent-wash: rgba(79, 216, 232, 0.12);
  --accent-2-wash: rgba(245, 169, 60, 0.14);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.shell {
  width: min(var(--shell), 100% - 2.5rem);
  margin-inline: auto;
}

.nowrap {
  white-space: nowrap;
}

.mono,
.numeral {
  font-family: var(--mono);
  font-size: 0.88em;
}

.numeral {
  white-space: nowrap;
}

sup {
  font-size: 0.62em;
  vertical-align: super;
  line-height: 0;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

strong {
  font-weight: 600;
}

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

.hero {
  /* Its own ground in both themes, so the opening frame never washes out. */
  --ground: var(--night-ground);
  --surface: var(--night-surface);
  --raised: var(--night-raised);
  --ink: var(--night-ink);
  --muted: var(--night-muted);
  --rule: var(--night-rule);
  --accent: var(--night-accent);
  --accent-2: var(--night-accent-2);

  background: var(--night-ground);
  color: var(--night-ink);
  padding: clamp(3.5rem, 9vw, 7rem) 0 clamp(9rem, 16vw, 13rem);
  background-image: radial-gradient(circle at 1px 1px, rgba(126, 146, 166, 0.16) 1px, transparent 0);
  background-size: 28px 28px;
}

.eyebrow {
  margin: 0 0 1.5rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--night-accent);
}

h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(3rem, 9.5vw, 6.5rem);
  line-height: 0.92;
  letter-spacing: -0.04em;
  color: var(--night-ink);
}

.standfirst {
  margin: 1.75rem 0 0;
  max-width: 46ch;
  font-size: clamp(1.05rem, 1.9vw, 1.35rem);
  line-height: 1.5;
  color: var(--night-muted);
  text-wrap: pretty;
}

.byline {
  margin: 2.25rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--night-rule);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--night-muted);
}

.byline strong {
  color: var(--night-ink);
  font-weight: 500;
}

.byline a {
  color: var(--night-accent);
}

/* ------------------------------------------------------------------- demo */

.demo-section {
  margin-top: clamp(-11rem, -13vw, -7.5rem);
  margin-bottom: clamp(4rem, 8vw, 6.5rem);
  position: relative;
  z-index: 1;
}

.panel {
  --ground: var(--night-ground);
  --surface: var(--night-surface);
  --raised: var(--night-raised);
  --ink: var(--night-ink);
  --muted: var(--night-muted);
  --rule: var(--night-rule);
  --accent: var(--night-accent);
  --accent-2: var(--night-accent-2);

  background: var(--night-surface);
  border: 1px solid var(--night-rule);
  border-radius: 6px;
  padding: clamp(1rem, 2.2vw, 1.6rem);
  color: var(--night-ink);
  box-shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.75);
}

.panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.15rem;
}

.panel-head h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: -0.015em;
  color: var(--night-ink);
}

.panel-status {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--night-muted);
  font-variant-numeric: tabular-nums;
}

.demo {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 5fr);
  gap: 0.9rem;
}

.screen {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.screen canvas {
  display: block;
  width: 100%;
  height: 310px;
  background: var(--night-ground);
  border: 1px solid var(--night-rule);
  border-radius: 4px;
}

.screen figcaption {
  font-family: var(--mono);
  font-size: 0.7rem;
  line-height: 1.45;
  color: var(--night-muted);
}

.stats {
  margin: 0.9rem 0 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--night-rule);
  border: 1px solid var(--night-rule);
  border-radius: 4px;
  overflow: hidden;
}

.stat {
  padding: 0.8rem 1rem;
  background: var(--night-ground);
}

.stat dt {
  font-family: var(--mono);
  font-size: 0.63rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--night-muted);
}

.stat dd {
  margin: 0.3rem 0 0;
  font-family: var(--display);
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--night-ink);
}

.stat dd.is-live {
  color: var(--night-accent);
}

.stat dd.is-reference {
  color: var(--night-accent-2);
}

.controls {
  margin-top: 0.9rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr));
  gap: 0.9rem 1.1rem;
  padding: 1.15rem;
  background: var(--night-raised);
  border: 1px solid var(--night-rule);
  border-radius: 4px;
}

.control {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.control > label {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--night-muted);
}

.control output {
  color: var(--night-ink);
  font-variant-numeric: tabular-nums;
}

.panel select,
.panel input[type="number"] {
  width: 100%;
  padding: 0.45rem 0.55rem;
  background: var(--night-ground);
  color: var(--night-ink);
  border: 1px solid var(--night-rule);
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 0.78rem;
}

.panel input[type="range"] {
  width: 100%;
  margin: 0.5rem 0 0;
  accent-color: var(--night-accent);
}

.control-check {
  flex-direction: row;
  align-items: center;
  gap: 0.55rem;
}

.control-check label {
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--night-muted);
}

.control-check input {
  width: 1rem;
  height: 1rem;
  flex: none;
  accent-color: var(--night-accent);
}

.control-buttons {
  flex-direction: row;
  align-items: flex-end;
  gap: 0.55rem;
}

.button {
  flex: 1;
  padding: 0.55rem 1rem;
  background: var(--night-ground);
  color: var(--night-ink);
  border: 1px solid var(--night-rule);
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 0.76rem;
  cursor: pointer;
  transition: border-color 120ms ease, background 120ms ease;
}

.button:hover {
  border-color: var(--night-accent);
}

.button.is-primary {
  background: var(--night-accent);
  border-color: var(--night-accent);
  color: #04141a;
  font-weight: 500;
}

.button.is-primary:hover {
  background: #6ee3f0;
}

.panel-note {
  margin: 1rem 0 0;
  max-width: 76ch;
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--night-muted);
}

/* ---------------------------------------------------------------- article */

.band {
  display: grid;
  grid-template-columns: minmax(0, var(--rail)) minmax(0, 1fr);
  gap: 1.25rem 3.5rem;
  align-items: start;
  padding-bottom: clamp(3.5rem, 7vw, 5.5rem);
}

.rail h2 {
  position: sticky;
  top: 2.5rem;
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.column {
  max-width: 68ch;
}

.column.is-wide {
  max-width: none;
}

.column > p {
  margin: 0 0 1.2rem;
  text-wrap: pretty;
}

.column > p:last-child {
  margin-bottom: 0;
}

.lede {
  font-size: 1.15rem;
  line-height: 1.55;
}

h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.08rem;
  letter-spacing: -0.01em;
}

h3.sub {
  margin: 2.5rem 0 0.9rem;
  font-size: 1.2rem;
}

.code {
  margin: 0 0 1.2rem;
  padding: 1rem 1.15rem;
  background: var(--raised);
  border: 1px solid var(--rule);
  border-radius: 4px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.75;
}

.code code {
  font: inherit;
}

.findings {
  margin: 0 0 1.2rem;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 1.1rem;
}

.findings li {
  padding-left: 1.2rem;
  border-left: 2px solid var(--rule);
}

.callout {
  margin: 1.75rem 0 0;
  padding: 1.05rem 1.25rem;
  background: var(--accent-wash);
  border-radius: 4px;
  font-size: 0.98rem;
}

/* ---------------------------------------------------------------- figures */

.figure-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(400px, 100%), 1fr));
  gap: 2rem 2.5rem;
}

.figure-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 5px;
}

.figure-card p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--muted);
}

.figure-body {
  margin-top: 0.35rem;
  overflow-x: auto;
}

.figure-svg {
  display: block;
  width: 100%;
  min-width: 400px;
  height: auto;
}

.figure-cell {
  fill: var(--raised);
  stroke: var(--rule);
  stroke-width: 1;
}

.figure-cell.is-kept {
  fill: var(--accent-wash);
  stroke: var(--accent);
}

/* Dashed edge marks a city carried in from the other parent. */
.figure-cell.is-filled {
  fill: transparent;
  stroke: var(--muted);
  stroke-dasharray: 2.5 2.5;
}

.figure-cell.is-moved {
  fill: var(--accent-2-wash);
  stroke: var(--accent-2);
}

.figure-value {
  font-family: var(--mono);
  font-size: 13px;
  fill: var(--ink);
}

.figure-value.is-kept {
  fill: var(--accent);
}

.figure-value.is-moved {
  fill: var(--accent-2);
}

.figure-label {
  font-family: var(--mono);
  font-size: 11px;
  fill: var(--muted);
}

.figure-rule {
  stroke: var(--rule);
  stroke-width: 1;
}

.figure-note {
  margin: 1.5rem 0 0;
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.6;
  color: var(--muted);
}

/* ----------------------------------------------------------------- tables */

.table-wrap {
  margin: 0 0 1.2rem;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th,
td {
  padding: 0.6rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--rule);
}

thead th {
  font-family: var(--mono);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom-color: var(--muted);
}

tbody th {
  font-weight: 400;
}

td {
  font-family: var(--mono);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

td.is-best {
  color: var(--accent);
  font-weight: 500;
}

tbody tr:last-child th,
tbody tr:last-child td {
  border-bottom: none;
}

.mark {
  color: var(--accent-2);
}

.table-note {
  margin: 0.7rem 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

/* -------------------------------------------------------------- hindsight */

.hindsight {
  margin: 0 0 1.2rem;
  display: grid;
  gap: 1.4rem;
}

.hindsight > div {
  display: grid;
  gap: 0.3rem;
}

.hindsight dt {
  font-family: var(--display);
  font-size: 1.02rem;
  font-weight: 600;
}

.hindsight dd {
  margin: 0;
  color: var(--muted);
}

/* ----------------------------------------------------------------- footer */

.site-footer {
  padding: 2.25rem 0 4rem;
  border-top: 1px solid var(--rule);
  display: grid;
  gap: 1.1rem;
}

.footer-lead {
  margin: 0;
  max-width: 62ch;
  color: var(--muted);
}

.footer-links {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  font-family: var(--mono);
  font-size: 0.8rem;
}

.footer-note {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.7rem;
  line-height: 1.6;
  color: var(--muted);
}

/* -------------------------------------------------------------------- nav */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--night-ground);
  border-bottom: 1px solid var(--night-rule);
}

.nav-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  padding: 0.8rem 0;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--night-ink);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.015em;
  white-space: nowrap;
}

.nav-mark {
  width: 26px;
  height: 26px;
  flex: none;
  display: block;
}

.standfirst-tight {
  margin-top: 1rem;
}

.standfirst-tight strong {
  color: var(--night-accent);
  font-weight: 600;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--mono);
  font-size: 0.76rem;
}

.nav-links a {
  display: inline-block;
  padding: 0.3rem 0;
  color: var(--night-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.nav-links a:hover {
  color: var(--night-ink);
}

.nav-links a[aria-current="page"] {
  color: var(--night-accent);
  border-bottom-color: var(--night-accent);
}

.nav-cta {
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--night-rule);
  border-radius: 3px;
  color: var(--night-ink);
  text-decoration: none;
  font-family: var(--mono);
  font-size: 0.76rem;
  white-space: nowrap;
}

.nav-cta:hover {
  border-color: var(--night-accent);
  color: var(--night-accent);
}

/* -------------------------------------------------------- inner page hero */

.page-hero {
  --ground: var(--night-ground);
  --surface: var(--night-surface);
  --ink: var(--night-ink);
  --muted: var(--night-muted);
  --rule: var(--night-rule);
  --accent: var(--night-accent);
  --accent-2: var(--night-accent-2);

  background: var(--night-ground);
  color: var(--night-ink);
  padding: clamp(2.75rem, 6vw, 4.5rem) 0 clamp(3rem, 7vw, 5rem);
  background-image: radial-gradient(circle at 1px 1px, rgba(126, 146, 166, 0.14) 1px, transparent 0);
  background-size: 28px 28px;
}

.page-hero h1 {
  font-size: clamp(2.4rem, 6.5vw, 4.25rem);
}

.page-hero .standfirst {
  margin-top: 1.25rem;
  max-width: 52ch;
}

/* Only the demo page needs room for the panel to overlap upward. */
.page-hero:has(+ .demo-section) {
  padding-bottom: clamp(9rem, 15vw, 12rem);
}

/* --------------------------------------------------------------- buttons */

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

.btn {
  display: inline-block;
  padding: 0.72rem 1.4rem;
  border: 1px solid var(--night-rule);
  border-radius: 4px;
  color: var(--night-ink);
  background: transparent;
  text-decoration: none;
  font-family: var(--mono);
  font-size: 0.8rem;
  transition: border-color 120ms ease, background 120ms ease;
}

.btn:hover {
  border-color: var(--night-accent);
}

.btn.is-primary {
  background: var(--night-accent);
  border-color: var(--night-accent);
  color: #04141a;
  font-weight: 500;
}

.btn.is-primary:hover {
  background: #6ee3f0;
}

/* --------------------------------------------------------------- preview */

.preview-section {
  margin-top: clamp(-9rem, -12vw, -6rem);
  margin-bottom: clamp(3.5rem, 7vw, 5.5rem);
  position: relative;
  z-index: 1;
}

.preview-link {
  display: block;
  position: relative;
  line-height: 0;
  border: 1px solid var(--night-rule);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.75);
}

.preview-link img {
  width: 100%;
  height: auto;
}

.preview-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  padding: 0.4rem 0.7rem;
  background: rgba(8, 12, 17, 0.88);
  border: 1px solid var(--night-rule);
  border-radius: 3px;
  color: var(--night-accent);
  font-family: var(--mono);
  font-size: 0.7rem;
  line-height: 1.4;
}

/* ----------------------------------------------------------------- facts */

.facts {
  margin: 0;
  display: grid;
}

.fact {
  display: grid;
  grid-template-columns: minmax(0, 150px) minmax(0, 1fr);
  gap: 0.35rem 1.5rem;
  padding: 0.95rem 0;
  border-bottom: 1px solid var(--rule);
}

.fact:first-child {
  border-top: 1px solid var(--rule);
}

.fact dt {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 0.2rem;
}

.fact dd {
  margin: 0;
}

/* ----------------------------------------------------------------- cards */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(255px, 100%), 1fr));
  gap: 1rem;
}

.card {
  margin: 0;
  padding: 1.3rem;
  display: grid;
  gap: 0.5rem;
  align-content: start;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 5px;
}

.card p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--muted);
}

/* --------------------------------------------------------------- explore */

.explore {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
}

.explore a {
  display: grid;
  gap: 0.2rem;
  padding: 1.05rem 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  color: inherit;
}

.explore li:first-child a {
  border-top: 1px solid var(--rule);
}

.explore-title {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.06rem;
}

.explore a:hover .explore-title {
  color: var(--accent);
}

.explore-note {
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--muted);
}

/* ------------------------------------------------------------- big facts */

.figures-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.75rem;
}

.big-fact {
  flex: 1 1 190px;
  padding: 1.2rem 1.3rem;
  display: grid;
  gap: 0.4rem;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 5px;
}

.big-fact-value {
  font-family: var(--display);
  font-weight: 800;
  font-size: 2.5rem;
  line-height: 1;
  letter-spacing: -0.035em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.big-fact.is-reference .big-fact-value {
  color: var(--accent-2);
}

.big-fact-label {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.4;
  color: var(--muted);
}

/* ---------------------------------------------------------------- legend */

.key {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
}

.key::before {
  content: "";
  width: 14px;
  height: 14px;
  border-radius: 2px;
  flex: none;
}

.key-kept::before {
  background: var(--accent-wash);
  border: 1px solid var(--accent);
}

.key-filled::before {
  border: 1px dashed var(--muted);
}

.column-intro {
  margin-bottom: 1.9rem;
  max-width: 68ch;
}

.panel-note-inline {
  margin: 1.9rem 0 0;
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--muted);
}

/* ---------------------------------------------------- footer (multi-page) */

.site-footer {
  padding: 0;
  border-top: 1px solid var(--rule);
  display: block;
}

.footer-inner {
  padding: 2.4rem 0 4rem;
  display: grid;
  gap: 1.1rem;
}

@media (max-width: 720px) {
  .nav-links {
    order: 3;
    width: 100%;
    gap: 0 1.1rem;
    padding-top: 0.2rem;
  }

  .fact {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.2rem;
  }

  .big-fact-value {
    font-size: 2.1rem;
  }
}

/* ------------------------------------------------------------- responsive */

@media (max-width: 900px) {
  .band {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.85rem;
  }

  .rail h2 {
    position: static;
  }

  .demo {
    grid-template-columns: minmax(0, 1fr);
  }

  .screen canvas {
    height: 265px;
  }

  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-section {
    margin-top: clamp(-8rem, -14vw, -5rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
