/* ==========================================================================
   Design G, The Poll: the home page as a 1960s control-room console.
   Grey-green painted steel, engraved legends, CRTs, amber and red lamps,
   typed paper and a line printer. Every station reports; one never answers.
   ========================================================================== */

:root {
  color-scheme: light;
  --ink: var(--g-ink);
  --ink-2: var(--g-ink-2);
  --paper: var(--g-paper);
  --gutter: var(--g-gutter);
  --max: var(--g-max);
  --ease: var(--g-ease);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: var(--paint-deep) var(--paint-lo); }
body {
  margin: 0;
  overflow-wrap: break-word;
  background: var(--paint);
  color: var(--ink);
  font-family: var(--f-set);
  font-size: 1rem;
  line-height: 1.5;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--amber); color: var(--ink); }
img, svg, canvas { display: block; max-width: 100%; }
p, h1, h2, ol, ul, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 30;
  padding: 0.6rem 1rem;
  background: var(--ink);
  color: var(--paint-hi);
  font-weight: 600;
}
.skip:focus { top: 1rem; }

/* ---------- the panel language ---------- */
/* a bay of the console: painted steel, a screw in each corner, a groove to the next bay */
.wall, .poll, .voice, .rise-head, .rest {
  position: relative;
  padding-inline: max(var(--gutter), calc((100% - var(--max)) / 2));
  background:
    var(--screw) left 0.55rem top 0.55rem / 0.72rem no-repeat,
    var(--screw) right 0.55rem top 0.55rem / 0.72rem no-repeat,
    var(--screw) left 0.55rem bottom 0.55rem / 0.72rem no-repeat,
    var(--screw) right 0.55rem bottom 0.55rem / 0.72rem no-repeat,
    var(--paint);
  border-top: 2px solid var(--seam);
  box-shadow: inset 0 1px 0 var(--hi);
}

/* engraved legend */
.key-when, .readout-k, .board-bar, .rise-sub, .subtitle, .transcript-title {
  font-family: var(--f-set);
  font-stretch: 75%;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

/* a CRT: bezel, curved glass, scan lines */
.crt {
  position: relative;
  padding: clamp(0.45rem, 1vw, 0.85rem);
  border-radius: 1.3rem;
  background: linear-gradient(180deg, #232823, var(--bezel) 40%, #0c0e0c);
  box-shadow: 0 1px 0 var(--hi), 0 -1px 0 rgba(0, 0, 0, 0.25), 0 14px 26px -16px rgba(0, 0, 0, 0.55);
}
.crt::after {
  content: "";
  position: absolute;
  inset: clamp(0.45rem, 1vw, 0.85rem);
  border-radius: 1rem / 1.6rem;
  pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(0, 0, 0, 0.22) 0 1px, transparent 1px 3px);
  box-shadow: inset 0 0 3.5rem 0.4rem rgba(0, 0, 0, 0.75), inset 0 0 0 1px rgba(205, 243, 218, 0.06);
}

/* typed paper */
.sheet {
  background: var(--paper);
  color: var(--type);
  font-family: var(--f-type);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.18), 0 10px 22px -12px rgba(20, 26, 20, 0.5);
}

/* ---------- the front wall ---------- */
.wall {
  display: grid;
  gap: clamp(1.25rem, 3vw, 2.25rem);
  padding-block: clamp(1rem, 2.5vw, 2rem) clamp(2rem, 5vw, 3.5rem);
}
.crt--wall { height: clamp(17rem, 48svh, 40rem); }
.wall-sky {
  width: 100%;
  height: 100%;
  border-radius: 1rem / 1.6rem;
  background:
    linear-gradient(180deg, #030906 0%, #07130d 60%, #0b1c13 74%, #050b08 74.3%, #030705 100%);
}
html.js .wall-sky { animation: power-on 900ms var(--ease) both; }
@keyframes power-on {
  0% { transform: scaleY(0.006) scaleX(0.3); filter: brightness(3); }
  45% { transform: scaleY(0.006) scaleX(1); filter: brightness(2.4); }
  100% { transform: none; filter: none; }
}
.crt-read {
  position: absolute;
  z-index: 1;
  left: calc(clamp(0.45rem, 1vw, 0.85rem) + clamp(1rem, 2.5vw, 1.8rem));
  top: calc(clamp(0.45rem, 1vw, 0.85rem) + clamp(0.9rem, 2vw, 1.5rem));
  font-stretch: 80%;
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--phos-2);
}

.wall-plate {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: stretch;
  gap: clamp(1.5rem, 4vw, 4rem);
}
.title {
  font-stretch: 70%;
  font-weight: 760;
  font-size: min(clamp(3rem, 1.4rem + 6.4vw, 6rem), 14.5vw);
  line-height: 0.88;
  letter-spacing: 0.005em;
  text-transform: uppercase;
}
.nameplate {
  padding: clamp(0.9rem, 2vw, 1.3rem) clamp(1.3rem, 3vw, 2.2rem);
  border-radius: 0.3rem;
  background:
    var(--screw) left 0.5rem top 0.5rem / 0.62rem no-repeat,
    var(--screw) right 0.5rem top 0.5rem / 0.62rem no-repeat,
    var(--screw) left 0.5rem bottom 0.5rem / 0.62rem no-repeat,
    var(--screw) right 0.5rem bottom 0.5rem / 0.62rem no-repeat,
    var(--paint-hi);
  box-shadow: inset 0 0 0 1px var(--seam), inset 0 2px 0 var(--hi), 0 1px 0 var(--hi);
}
.subtitle { margin-top: 1.1rem; font-size: clamp(0.8rem, 0.75rem + 0.3vw, 0.95rem); color: var(--ink-2); }
.subtitle i { font-style: italic; font-stretch: 80%; letter-spacing: 0.06em; }

.card {
  display: grid;
  align-content: center;
  gap: 1.1rem;
  padding: clamp(1.2rem, 2.6vw, 1.8rem) clamp(1.2rem, 2.6vw, 2rem);
  font-size: clamp(0.98rem, 0.94rem + 0.2vw, 1.08rem);
  line-height: 1.55;
}
.card-by { color: var(--type-2); }
.card-by a { color: var(--type); }
.card-by a:hover { text-decoration-thickness: 2px; }

@media (max-width: 52rem) {
  .wall-plate { grid-template-columns: minmax(0, 1fr); }
  .crt--wall { height: clamp(15rem, 46svh, 26rem); }
}

/* ---------- the poll ---------- */
.poll {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(2rem, 5vw, 4.5rem);
  padding-block: clamp(3rem, 7vw, 6rem);
}
.memo { padding: clamp(1.4rem, 4vw, 3.2rem); }
.memo-title {
  max-width: 17ch;
  font-family: var(--f-set);
  font-stretch: 72%;
  font-weight: 760;
  font-size: clamp(2rem, 1.2rem + 3vw, 3.6rem);
  line-height: 0.98;
  letter-spacing: 0.005em;
  text-transform: uppercase;
  text-wrap: balance;
}
.memo-sub {
  margin-top: 1.1rem;
  padding-bottom: 1.3rem;
  border-bottom: 1px solid var(--type);
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem);
}
.typed {
  display: grid;
  gap: 1.1em;
  margin-top: 1.5rem;
  max-width: 64ch;
  font-size: clamp(0.98rem, 0.94rem + 0.2vw, 1.08rem);
  line-height: 1.62;
}
.typed em { font-style: italic; }
.memo-ref { margin-top: 1.8rem; }
.memo-ref a { display: inline-flex; align-items: center; gap: 0.6rem; text-decoration: none; }
.memo-ref b { font-weight: 400; text-transform: uppercase; letter-spacing: 0.04em; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.22em; }
.memo-ref a:hover b { text-decoration-thickness: 2px; }

.board { display: grid; gap: 1rem; padding-top: 0.4rem; }
@media (min-width: 60.01rem) {
  .board { position: sticky; top: 1.5rem; }
}
.board-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--ink);
}
.board-rows {
  position: relative;
  margin-left: 2.6rem;
  padding: 0.8rem clamp(0.9rem, 2vw, 1.3rem);
  border-radius: 0.6rem / 0.9rem;
  background: var(--glass);
  box-shadow: 0 0 0 0.55rem var(--bezel), 0 1px 0 0.55rem var(--hi), inset 0 0 2rem rgba(0, 0, 0, 0.8);
  background-image: repeating-linear-gradient(180deg, rgba(0, 0, 0, 0.25) 0 1px, transparent 1px 3px);
}
.board-rows > div {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, auto);
  align-items: baseline;
  gap: 1rem;
  padding: 0.52rem 0;
  border-bottom: 1px dashed rgba(134, 201, 161, 0.2);
}
.board-rows > div:last-child { border-bottom: 0; }
/* each station's lamp sits on the panel, left of the screen */
.board-rows > div::before {
  content: "";
  position: absolute;
  left: calc(-2.6rem - clamp(0.9rem, 2vw, 1.3rem) + 0.15rem);
  top: 50%;
  width: 0.78rem;
  height: 0.78rem;
  margin-top: -0.39rem;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 2px var(--bezel), inset 0 2px 3px var(--amber-hot), 0 1px 8px 0 var(--lamp-glow);
  transition: background-color 70ms linear, box-shadow 70ms linear;
  transition-delay: calc(var(--i, 0) * 130ms);
}
/* red, but steady and throwing no light: it reports, it does not alarm */
.board-rows > .is-red::before { background: var(--red); box-shadow: 0 0 0 2px var(--bezel), inset 0 2px 3px #ffb9a8; }
/* no faults, so that lamp is dark; the supervisor never answers, so that one never lights */
.board-rows > .is-dark::before,
.board-rows > .is-wait::before,
html.js .board-rows:not(.is-polled) > div::before { background: var(--amber-off); box-shadow: 0 0 0 2px var(--bezel), inset 0 -2px 3px rgba(0, 0, 0, 0.45); }
.board-rows dt {
  font-stretch: 78%;
  font-weight: 600;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--phos-2);
}
.board-rows dd {
  font-stretch: 80%;
  font-weight: 560;
  font-size: clamp(0.86rem, 0.82rem + 0.2vw, 0.96rem);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  text-align: right;
  color: var(--phos);
  text-shadow: 0 0 0.45em rgba(205, 243, 218, 0.35);
  font-variant-numeric: tabular-nums;
}
.board-rows .is-wait dd { color: var(--amber); }
.cursor {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  margin-left: 0.3em;
  vertical-align: -0.12em;
  background: currentColor;
  animation: blink-text 1s steps(1, end) calc(12 * 130ms) 5;
  animation-play-state: paused;
}
@keyframes blink-text { 50% { opacity: 0; } }
.is-polled .cursor { animation-play-state: running; }
.board-cap { margin-left: 2.6rem; padding-top: 0.6rem; font-size: 0.9rem; line-height: 1.45; color: var(--ink-2); max-width: 36ch; }

@media (max-width: 60rem) {
  .poll { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 26rem) {
  .board-rows > div { grid-template-columns: minmax(0, 1fr); gap: 0.15rem; }
  .board-rows dd { text-align: left; }
}

/* ---------- the voice ---------- */
.voice {
  display: grid;
  justify-items: start;
  gap: 1.6rem;
  padding-block: clamp(3rem, 7vw, 5.5rem);
  background-color: var(--paint-lo);
}
.transcript {
  display: grid;
  grid-template-columns: minmax(9rem, 13rem) minmax(0, 1fr);
  gap: 1rem clamp(1.5rem, 4vw, 3rem);
  width: min(100%, 64rem);
  padding: clamp(1.4rem, 4vw, 3rem);
}
.transcript-title { font-size: 0.8rem; color: var(--type-2); padding-top: 0.45rem; }
.transcript-body p {
  font-size: clamp(1.2rem, 1rem + 1vw, 1.7rem);
  line-height: 1.45;
  max-width: 40ch;
}
.transcript-body footer { margin-top: 1.2rem; color: var(--type-2); }

.key-link {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.7rem;
  padding: 0.75rem 1.05rem;
  border-radius: 0.25rem;
  background: var(--milk);
  text-decoration: none;
  font-stretch: 85%;
  font-size: 0.98rem;
  box-shadow: 0 0 0 3px var(--bezel), inset 0 -3px 0 rgba(0, 0, 0, 0.1);
}
.key-link b { font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; font-stretch: 75%; }
.key-link-sep { color: var(--ink-2); }
.key-link .arw { display: inline-block; margin-left: 0.35rem; vertical-align: 0.05em; }
.key-link:hover .lamp, .key-link:focus-visible .lamp, .key:hover .lamp, .key:focus-visible .lamp {
  background: var(--amber);
  box-shadow: 0 0 0 2px var(--bezel), inset 0 2px 3px var(--amber-hot), 0 1px 10px 1px var(--lamp-glow);
}

@media (max-width: 44rem) {
  .transcript { grid-template-columns: minmax(0, 1fr); }
  .key-link-sep { display: none; }
  .key-link > span:not(.lamp) { flex-basis: 100%; }
}

/* ---------- the Rise ---------- */
.rise-head {
  display: grid;
  grid-template-columns: minmax(0, auto) minmax(0, 32rem);
  justify-content: space-between;
  align-items: end;
  gap: 0.8rem 3rem;
  padding-block: clamp(3rem, 7vw, 5.5rem) clamp(1.5rem, 3vw, 2.25rem);
}
.rise-title {
  grid-row: 1;
  font-stretch: 70%;
  font-weight: 760;
  font-size: clamp(2.8rem, 1.6rem + 5vw, 5.5rem);
  line-height: 0.9;
  text-transform: uppercase;
}
.rise-sub { grid-row: 2; font-size: 0.8rem; color: var(--ink-2); }
.rise-lede { grid-column: 2; grid-row: 1 / span 2; font-size: clamp(1rem, 0.96rem + 0.2vw, 1.1rem); line-height: 1.55; color: var(--ink-2); max-width: 44ch; }
@media (max-width: 48rem) {
  .rise-head { grid-template-columns: minmax(0, 1fr); }
  .rise-lede { grid-column: 1; grid-row: 3; }
}

.rise-track { position: relative; background: var(--paint); }
html.js .rise-track { height: 560vh; }
.rise-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(17rem, 25vw, 23rem);
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 0.9rem clamp(1rem, 2vw, 1.75rem);
  padding: clamp(0.75rem, 2vw, 1.5rem) max(var(--gutter), calc((100% - var(--max)) / 2));
  background: var(--paint);
}
html.js .rise-stage { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: min(34rem, 100svh); }
html:not(.js) .crt--rise { aspect-ratio: 16 / 10; }
.crt--rise { min-height: 20rem; }
.crt--rise > .rise-scene, .crt--rise > .rise-rain, .crt--rise > .rise-labels, .crt--rise > .rise-dim {
  position: absolute;
  inset: clamp(0.45rem, 1vw, 0.85rem);
  width: calc(100% - 2 * clamp(0.45rem, 1vw, 0.85rem));
  height: calc(100% - 2 * clamp(0.45rem, 1vw, 0.85rem));
  border-radius: 1rem / 1.6rem;
}
.rise-scene { background: var(--glass); overflow: hidden; }
.rise-rain, .rise-labels, .rise-dim { pointer-events: none; }
.rise-dim { background: #000; opacity: 0; }
.rise-labels { overflow: hidden; }
.rise-land { fill: #0d1c14; }
.rise-ridge { fill: none; stroke: var(--phos); stroke-opacity: 0.85; stroke-width: 1.3; }
.rise-water { fill: rgba(76, 125, 97, 0.34); }
.rise-datum { stroke: var(--phos-2); stroke-opacity: 0.5; stroke-width: 1; stroke-dasharray: 5 6; }
.rise-surface { fill: none; stroke: var(--phos); stroke-width: 1.6; }

/* the sun, half risen on the new horizon, drawn in phosphor */
.rise-sun {
  position: absolute;
  left: 31%;
  width: clamp(3.2rem, 6vw, 5.5rem);
  aspect-ratio: 2 / 1;
  transform: translate(-50%, -100%);
  border: 1.5px solid var(--phos);
  border-bottom: 0;
  border-radius: 999px 999px 0 0;
  pointer-events: none;
}

.rise-place {
  position: absolute;
  transform: translate(-50%, -100%);
  padding-bottom: 0.75rem;
  font-stretch: 78%;
  font-weight: 600;
  font-size: clamp(0.62rem, 0.58rem + 0.2vw, 0.74rem);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--phos);
  transition: opacity 0.4s var(--ease), color 0.4s var(--ease);
}
.rise-place::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 1px;
  height: 0.6rem;
  background: currentColor;
}
.rise-place.is-summit { color: var(--amber); }
/* the first and last places sit against the frame: hang them off their marks inward */
.rise-place--1 { transform: translate(-12%, -100%); }
.rise-place--1::after { left: 12%; }
/* the plateau is named inside its own mass, below the ridge, clear of the scale */
.rise-place--6 { left: 85% !important; top: 62.7% !important; transform: translate(-50%, 0); padding-bottom: 0; }
.rise-place--6::after { display: none; }
.rise-place.is-under { color: var(--phos-2); text-decoration: line-through; text-decoration-thickness: 1px; }
.rise-tick {
  position: absolute;
  right: 1.1rem;
  transform: translateY(-50%);
  padding-right: 1.2rem;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--phos-2);
  font-variant-numeric: tabular-nums;
}
.rise-tick::after { content: ""; position: absolute; right: 0; top: 50%; width: 0.8rem; height: 1px; background: currentColor; }
.rise-datum-label {
  position: absolute;
  left: 1.3rem;
  transform: translateY(0.4rem);
  font-stretch: 80%;
  font-weight: 600;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--phos-2);
}

.rise-desk {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 1rem;
  min-height: 0;
}
.readouts { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem 0.9rem; }
.readout { display: grid; gap: 0.35rem; }
.readout-k { font-size: 0.7rem; color: var(--ink-2); }
.readout-v {
  display: block;
  padding: 0.3rem 0.5rem 0.2rem;
  border-radius: 0.2rem;
  background: var(--readout-glass);
  box-shadow: 0 0 0 3px var(--bezel), 0 1px 0 3px var(--hi), inset 0 2px 6px rgba(0, 0, 0, 0.8);
  font-stretch: 70%;
  font-weight: 600;
  font-size: clamp(1.6rem, 1.1rem + 1.4vw, 2.5rem);
  line-height: 1;
  color: var(--amber);
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.readout-era {
  grid-column: 1 / -1;
  padding: 0.55rem 0.7rem;
  border-radius: 0.2rem;
  background: var(--amber);
  box-shadow: 0 0 0 3px var(--bezel), inset 0 2px 4px var(--amber-hot);
  font-stretch: 75%;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
}

.reels { display: flex; justify-content: space-between; gap: 0.8rem; padding: 0.2rem 0.4rem; }
.reel { width: min(46%, 7.5rem); height: auto; }
.reel-pack { fill: #3b2a1f; }
.reel-spin { transform-origin: 60px 60px; transform-box: view-box; transform: rotate(var(--turn, 0deg)); }
.reel-flange { fill: #c9cfc4; stroke: #6c7466; stroke-width: 1; fill-rule: evenodd; }
.reel-hub { fill: #2a2f29; stroke: #c9cfc4; stroke-width: 3; }

.printer {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 0;
  overflow: hidden;
  padding: 0 0.7rem;
  border-radius: 0.25rem;
  background: var(--printer);
  box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.7), 0 1px 0 var(--hi);
}
/* fanfold paper: green bars two lines deep, tractor holes down both edges, fed up from the platen */
.printout {
  --line: 1.5rem;
  display: flex;
  flex: 1 0 auto;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 1.1rem;
  background:
    radial-gradient(circle, var(--printer) 0 0.2rem, transparent 0.23rem) left 0.2rem bottom 0 / 0.5rem var(--line) repeat-y,
    radial-gradient(circle, var(--printer) 0 0.2rem, transparent 0.23rem) right 0.2rem bottom 0 / 0.5rem var(--line) repeat-y,
    var(--paper);
  color: var(--type);
  font-family: var(--f-type);
  font-size: 0.78rem;
}
.printout li {
  display: grid;
  grid-template-columns: 3.4rem 4.6rem minmax(0, 1fr);
  gap: 0.4rem;
  min-height: var(--line);
  padding-block: 0.22rem;
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}
.printout li > :nth-child(2) { text-align: right; padding-right: 0.5rem; }
/* green bars follow the entries, so a wrapped entry keeps one band */
.printout li:nth-child(odd) { background: var(--paper-bar); box-shadow: -0.35rem 0 0 var(--paper-bar), 0.35rem 0 0 var(--paper-bar); }
/* a line not yet printed stays in the document for screen readers; only the paper does not show it */
html.js .printout li:not([data-state]) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
html.js .printout li[data-state="old"] { color: var(--type-3); }
html.js .printout li[data-state="now"] { animation: strike 180ms steps(3, end); }
@keyframes strike { 0% { color: transparent; } 60% { color: var(--type-2); } }

.rise-note {
  grid-column: 1 / -1;
  font-stretch: 80%;
  font-weight: 600;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}

@media (max-width: 60rem) {
  html.js .rise-track { height: 440vh; }
  .rise-stage { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto auto; }
  .crt--rise { min-height: 0; }
  .rise-desk { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: auto auto; grid-template-areas: "read print" "reels print"; align-items: stretch; }
  .readouts { grid-area: read; grid-template-columns: minmax(0, 1fr); align-content: start; }
  .reels { grid-area: reels; justify-content: flex-start; align-self: start; gap: 0.8rem; padding: 0; }
  .reel { width: 4.4rem; }
  .printer { grid-area: print; }
  /* the printer takes the height its row gives it, not the height of everything it has printed */
  .printer { height: auto; min-height: 9.5rem; contain: size; }
  .printout li { grid-template-columns: 3rem minmax(0, 1fr); }
  .printout li > :nth-child(2) { display: none; }
  .rise-place:not(.is-summit) { font-size: 0.65rem; }
  /* the delta drops below the old coast, its mark pointing up, so it keeps clear of the bay */
  .rise-place--2 { top: 92% !important; transform: translate(-50%, 0); padding: 0.75rem 0 0; }
  .rise-place--2::after { top: 0; bottom: auto; }
  /* on a narrow screen the scale moves to the open sky on the left, clear of the plateau */
  .rise-tick { right: auto; left: 0.6rem; padding: 0 0 0 1.1rem; }
  .rise-tick::after { right: auto; left: 0; }
  .rise-tick--zero { display: none; }
}
@media (max-width: 34rem) {
  .rise-desk { grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "read read" "reels print"; }
  .readouts { grid-template-columns: 1fr 1fr; }
  .reels { flex-direction: column; justify-content: flex-start; align-self: start; gap: 0.35rem; }
  .reel { width: 3.5rem; }
  .printer { height: 7.6rem; min-height: 0; contain: none; }
  .readout-v { font-size: 1.5rem; }
  html:not(.js) .crt--rise { aspect-ratio: 4 / 5; }
}
/* a phone on its side: the desk moves beside the screen so the readouts stay in view */
@media (max-width: 60rem) and (max-height: 32rem) and (orientation: landscape) {
  .rise-stage { grid-template-columns: minmax(0, 1fr) minmax(0, 15rem); grid-template-rows: minmax(0, 1fr) auto; }
  .rise-desk { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); grid-template-areas: "read read" "reels print"; }
  .reels { flex-direction: column; justify-content: flex-start; align-self: start; gap: 0.3rem; }
  .reel { width: 3rem; }
  .readouts { grid-template-columns: 1fr 1fr; gap: 0.6rem; }
  .readout-v { font-size: 1.25rem; }
  .readout-era { font-size: 0.7rem; padding: 0.35rem 0.5rem; }
  .printer { height: auto; }
}
html:not(.js) .printer { height: auto; contain: none; }

@media (max-width: 48rem), (pointer: coarse) {
  .memo-ref a { display: inline-flex; align-items: center; min-height: 2.75rem; }
}

/* ---------- the rest of it ---------- */
.rest { padding-block: clamp(3rem, 7vw, 5.5rem); }
.rest-title {
  font-stretch: 72%;
  font-weight: 760;
  font-size: clamp(2rem, 1.4rem + 2.4vw, 3.2rem);
  line-height: 0.95;
  text-transform: uppercase;
}
.keys {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14.5rem), 1fr));
  gap: 1.6rem clamp(1.1rem, 2.4vw, 2rem);
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
}
.keys > li { display: grid; }
.key {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 0.6rem;
  padding: 0.3rem 0.2rem 0.4rem;
  text-decoration: none;
}
.key-when { margin-top: 0.35rem; font-size: 0.72rem; color: var(--ink-2); }
.key-cap {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 3.6rem;
  padding: 0.7rem 0.8rem;
  border-radius: 0.2rem;
  background: var(--milk);
  box-shadow: 0 0 0 3px var(--bezel), inset 0 -3px 0 rgba(0, 0, 0, 0.1);
}
.key-name { font-stretch: 75%; font-weight: 720; font-size: 1.12rem; line-height: 1.05; letter-spacing: 0.04em; text-transform: uppercase; }
.key-blurb { font-size: 0.95rem; line-height: 1.45; color: var(--ink-2); }
.key .arw { justify-self: end; width: 1.4rem; height: 0.8rem; color: var(--ink-2); transition: transform 160ms var(--ease); }
.key:hover .arw, .key:focus-visible .arw { transform: translateX(0.25rem); color: var(--ink); }
.key:hover .key-cap, .key:focus-visible .key-cap { background: var(--milk-hi); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
