/* Airmail 84: the screen of the agency's dispatch terminal.
   Read off art/ref/reference-crt.jpg: a framed CRT, a hairline bezel inset 3.3% of the side,
   five bands on black with a lot of air, two type registers (light tracked geometric / heavy
   grotesque) at a 3.1:1 scale contrast, phosphor mint for every line, four flat inks inside the
   rastered pictures. No mono anywhere, because the reference has none. */

@font-face {
  font-family: "Miedinger";
  src: url("/fonts/Miedinger-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("/fonts/Jost-Light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("/fonts/Jost-Book.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("/fonts/Jost-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  /* measured off the reference */
  --black: #000000;
  --field: #000a04;
  --mint: #00f0b0;
  --mint-2: #19c494;
  --mint-3: #0b7256;
  --ink-yellow: #f0f010;
  --ink-red: #d81808;
  --ink-cyan: #00e0d0;
  --ink-blue: #0080d0;

  --bezel: clamp(14px, 3.3vh, 38px);
  --gutter: clamp(18px, 3.4vw, 54px);
  --band: clamp(16px, 2.7vh, 30px);

  --display: clamp(42px, 14.5vh, 172px);
  --lockup: clamp(22px, 4.4vh, 52px);
  --title: clamp(30px, 4.4vh, 50px);
  --station: clamp(18px, 2.8vh, 31px);
  --body: clamp(17px, 1.9vh, 21px);
  --label: clamp(16px, 1.65vh, 19px);
  --numeral: clamp(30px, 4vh, 46px);

  color-scheme: dark;
  font-synthesis: none;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--black);
  color: var(--mint);
  font-family: Jost, "Century Gothic", system-ui, sans-serif;
  font-weight: 300;
  font-size: var(--body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  /* clip, not hidden: hidden would make the page a scroll container and kill the sticky key rail */
  overflow-x: clip;
}

body {
  /* the phosphor field: black with a faint green cast, brighter in the middle */
  background:
    radial-gradient(130% 95% at 50% 42%, #00140c 0%, #000905 52%, #000000 100%);
}

/* ---------- the bezel: the reference's own hairline frame, whole on all four sides ----- */
.bezel { position: fixed; inset: var(--bezel) calc(var(--bezel) * 1.6); pointer-events: none; z-index: 40; }
.bezel i {
  position: absolute;
  background: var(--mint);
  box-shadow: 0 0 6px rgba(0, 240, 176, 0.55);
}
.bezel .t, .bezel .b { height: 2px; left: 0; right: 0; }
.bezel .t { top: 0; }
.bezel .b { bottom: 0; }
.bezel .l, .bezel .r { width: 2px; top: 0; bottom: 0; }
.bezel .l { left: 0; }
.bezel .r { right: 0; }

/* ---------- the glass: scanlines, bloom, chromatic split ------------------------------ */
.glass {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  background:
    repeating-linear-gradient(to bottom,
      rgba(0, 0, 0, 0) 0px,
      rgba(0, 0, 0, 0) 2px,
      rgba(0, 0, 0, 0.22) 3px,
      rgba(0, 0, 0, 0.22) 4px),
    radial-gradient(120% 90% at 50% 50%, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, 0.72) 100%);
  mix-blend-mode: normal;
}
.glass::after {
  /* the slow roll of a tube that is not quite in sync */
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 28vh;
  background: linear-gradient(to bottom, rgba(0, 240, 176, 0) 0%, rgba(0, 240, 176, 0.045) 50%, rgba(0, 240, 176, 0) 100%);
  animation: roll 7.5s linear infinite;
}
@keyframes roll { from { top: -30vh; } to { top: 100vh; } }

/* ---------- the world behind the terminal ------------------------------------------- */
#world { position: fixed; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; opacity: 0.055; transition: opacity 0.6s ease; }
#world.bright { opacity: 0.13; }
#world canvas { position: absolute; display: block; }
.world-dots { z-index: 2; }

/* ---------- the shell ---------------------------------------------------------------- */
.screen {
  position: relative;
  z-index: 10;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: calc(var(--bezel) + 22px) calc(var(--bezel) * 1.6 + var(--gutter)) calc(var(--bezel) + 16px);
  overflow: hidden;
}

.station {
  flex: none;
  max-width: none;
  margin: 0 0 var(--band);
  font-size: var(--station);
  font-weight: 300;
  letter-spacing: 0.085em;
  color: var(--mint);
  text-shadow: 1.5px 0 rgba(216, 24, 8, 0.5), -1.5px 0 rgba(0, 128, 208, 0.5), 0 0 14px rgba(0, 240, 176, 0.35);
  display: flex;
  gap: 1em;
  align-items: flex-start;
  flex-wrap: nowrap;
  width: 100%;
}
.station .fill { min-width: 0; }
.station .right { margin-left: auto; }
.station .right { flex: none; white-space: nowrap; }
.station .caret { color: var(--mint); }
.station .fill { flex: 1 1 auto; }
.station .right { color: var(--mint-2); letter-spacing: 0.12em; }

main { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: center; min-height: 0; }
main:focus { outline: none; }
main.scrolls, main > .sheet { overflow: visible; }
main > .sheet { display: grid; gap: var(--band); align-content: start; overflow-y: auto; overscroll-behavior: contain; padding-right: 6px; scrollbar-width: thin; scrollbar-color: var(--mint-3) transparent; }
main > .sheet::-webkit-scrollbar { width: 10px; }
main > .sheet::-webkit-scrollbar-button { display: none; }
main > .sheet::-webkit-scrollbar-track { background: transparent; }
main > .sheet::-webkit-scrollbar-thumb { background: var(--mint-3); }

/* ---------- type ---------------------------------------------------------------------- */
.display {
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: var(--display);
  line-height: 0.86;
  letter-spacing: -0.015em;
  margin: 0;
  color: var(--mint);
  text-shadow: 3px 0 rgba(216, 24, 8, 0.45), -3px 0 rgba(0, 128, 208, 0.45), 0 0 28px rgba(0, 240, 176, 0.4);
}
.lockup-small {
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: var(--lockup);
  line-height: 1;
  letter-spacing: -0.01em;
  margin: 0 0 0.12em;
  color: var(--mint-2);
}
.legend {
  font-size: var(--station);
  font-weight: 300;
  letter-spacing: 0.14em;
  color: var(--mint-2);
  margin: 0.5em 0 0;
}
.title {
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: var(--title);
  line-height: 1;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
  color: var(--mint);
}
.label {
  font-size: var(--label);
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--mint-2);
  margin: 0 0 0.5em;
  display: block;
}
p { margin: 0 0 0.9em; max-width: 62ch; }
a { color: var(--mint); }

/* ---------- the bar: the reference's own hollow rectangle ----------------------------- */
.bar {
  position: relative;
  border: 2px solid var(--mint);
  height: 46px;
  box-shadow: 0 0 10px rgba(0, 240, 176, 0.3);
}
.bar > i {
  position: absolute;
  left: 3px; top: 3px; bottom: 3px;
  background: var(--mint);
  transition: width 0.7s ease;
}
.bar-row {
  display: grid;
  justify-items: center;
  gap: 0.6em;
  width: 71%;
  margin: 0 auto;
}
.bar-row .bar { width: 100%; }
.bar-row .read { order: -1; }
.bar-row .read {
  flex: none;
  font-size: var(--station);
  letter-spacing: 0.1em;
  font-weight: 400;
}

/* ---------- the keys: the same hollow rectangle cut into cells ------------------------ */
.keys {
  flex: none;
  margin-top: var(--band);
  display: grid;
  grid-template-columns: repeat(6, 1fr) auto;
  border: 2px solid var(--mint);
  box-shadow: 0 0 10px rgba(0, 240, 176, 0.3);
}
.keys button {
  appearance: none;
  background: transparent;
  border: 0;
  border-left: 2px solid var(--mint);
  color: var(--mint);
  font-family: Jost, sans-serif;
  font-size: var(--label);
  font-weight: 500;
  letter-spacing: 0.1em;
  min-height: 60px;
  padding: 14px 26px;
  cursor: pointer;
  transition: background 0.12s linear, color 0.12s linear;
}
.keys button:first-child { border-left: 0; }
.keys button:hover { background: rgba(0, 240, 176, 0.18); }
.keys button[aria-current="page"] { background: var(--mint); color: #001209; }
.keys button:focus-visible { outline: 3px solid var(--ink-yellow); outline-offset: -5px; }

/* ---------- the counter screen -------------------------------------------------------- */
.counter {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto auto;
  gap: var(--band);
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
}
.stage {
  display: grid;
  /* both flanking columns keep a real width: the IDENT window never has to spill out of itself */
  grid-template-columns: minmax(min(280px, 25vw), 1fr) minmax(min(300px, 26vw), auto) minmax(min(280px, 25vw), 1fr);
  grid-template-rows: minmax(0, 1fr);
  align-items: center;
  gap: clamp(16px, 2.4vw, 56px);
  min-height: 0;
}
.sheet-strip {
  appearance: none;
  background: transparent;
  border: 0;
  padding: 0;
  margin: 0 auto;
  cursor: pointer;
  /* the sheet is as tall as the row lets it be and never wider than its column: when the column is
     the tighter of the two, the three stamps come down together instead of one bursting out */
  height: 100%;
  aspect-ratio: 15 / 7;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5.2%;
  transition: transform 0.18s ease, filter 0.18s ease;
}
.sheet-strip span { position: relative; display: block; width: 35%; aspect-ratio: 3 / 4; }
.sheet-strip .flank { width: 27.3%; opacity: 0.34; }
.sheet-strip canvas { position: absolute; inset: 0; display: block; }
.sheet-strip:hover { transform: scale(1.02); filter: drop-shadow(0 0 24px rgba(0, 240, 176, 0.5)); }
.sheet-strip:focus-visible { outline: 3px solid var(--ink-yellow); outline-offset: 12px; }
.counters { display: grid; gap: calc(var(--band) * 0.9); justify-self: start; }
.counters .n {
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: var(--numeral);
  line-height: 1;
  display: block;
  color: var(--mint);
}
.counters .k {
  font-size: var(--label);
  letter-spacing: 0.16em;
  color: var(--mint-2);
  display: block;
  margin-top: 0.3em;
}
.lockup { margin: 0; width: fit-content; max-width: 100%; }
.lockup .legend { text-align: right; margin-top: 0.25em; }
.counter .ident { justify-self: end; align-self: center; width: min(100%, 420px); }
.counter .ident > header { min-height: 44px; padding: 10px 24px; }
.counter .ident > .body { padding: 22px 24px; gap: 14px; }
.counter .ident .addr { padding: 14px 20px; }
.counter .ident .key { min-height: 52px; }

/* ---------- windows: the terminal's own OS ------------------------------------------- */
.win {
  border: 2px solid var(--mint);
  background: rgba(0, 20, 12, 0.92);
  box-shadow: 0 0 22px rgba(0, 240, 176, 0.22);
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.win > header {
  display: flex;
  align-items: center;
  gap: 1em;
  min-height: 48px;
  padding: 12px 28px;
  background: var(--mint);
  color: #001209;
  font-weight: 500;
  font-size: var(--label);
  letter-spacing: 0.17em;
  cursor: grab;
  user-select: none;
}
.win > header .dots { margin-left: auto; display: flex; gap: 7px; }
.win > header .dots b { width: 11px; height: 11px; background: #001209; display: block; }
.win > .body { padding: 32px; }

/* ---------- controls ------------------------------------------------------------------ */
.key {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.7em;
  min-height: 56px;
  padding: 14px 26px;
  background: transparent;
  border: 2px solid var(--mint);
  color: var(--mint);
  font-family: Jost, sans-serif;
  font-size: var(--label);
  font-weight: 500;
  letter-spacing: 0.14em;
  cursor: pointer;
  transition: background 0.12s linear, color 0.12s linear;
}
.key:hover:not(:disabled) { background: rgba(0, 240, 176, 0.2); }
.key:active:not(:disabled) { background: var(--mint); color: #001209; }
.key:disabled { color: var(--mint-3); border-color: var(--mint-3); cursor: not-allowed; }
.key:focus-visible { outline: 3px solid var(--ink-yellow); outline-offset: 3px; }
.key.solid { background: var(--mint); color: #001209; }
.key.solid:hover { background: #4affd0; }
.key img { height: 20px; width: auto; display: block; }
.key.solid img { filter: invert(1); }

input[type="text"], input[type="search"], textarea, select {
  width: 100%;
  background: #00180e;
  border: 2px solid var(--mint-3);
  color: var(--mint);
  font-family: Jost, sans-serif;
  font-size: var(--body);
  font-weight: 400;
  letter-spacing: 0.03em;
  padding: 14px 18px;
  min-height: 56px;
}
textarea { min-height: 140px; resize: vertical; line-height: 1.55; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--mint); }
input::placeholder, textarea::placeholder { color: var(--mint-3); }

.rows { display: grid; gap: 22px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }

.addr {
  font-family: Jost, sans-serif;
  font-weight: 400;
  font-size: clamp(16px, 1.7vh, 20px);
  letter-spacing: 0.04em;
  word-break: break-all;
  overflow-wrap: anywhere;
  min-width: 0;
  background: #001b10;
  border: 2px solid var(--mint-3);
  padding: 16px 20px;
  color: var(--mint);
}
.muted { color: var(--mint-2); }
.warn { color: var(--ink-yellow); }
.bad { color: #ff6a52; }

/* ---------- a scrolling screen (wall, stamps, mail) ----------------------------------- */
.sheet { display: grid; gap: var(--band); }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gutter); align-items: stretch; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gutter); align-items: stretch; }
.grid3 > *, .grid4 > * { min-width: 0; }

.card-raster { display: block; width: 100%; height: auto; background: #000; }

.pick {
  border: 2px solid var(--mint-3);
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: block;
  width: 100%;
  text-align: left;
  transition: border-color 0.12s linear, transform 0.12s ease;
}
.pick:hover { border-color: var(--mint); transform: translateY(-2px); }
.pick[aria-pressed="true"] { border-color: var(--mint); box-shadow: 0 0 18px rgba(0, 240, 176, 0.35); }
.pick figcaption, .pick .cap {
  display: block;
  padding: 14px 18px;
  font-size: var(--label);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--mint);
  overflow-wrap: anywhere;
}
.pick:focus-visible { outline: 3px solid var(--ink-yellow); outline-offset: 3px; }

/* ---------- the $AIR plate in the corner ---------------------------------------------- */
.plate {
  background: var(--mint);
  color: #001209;
  border: 0;
  border-left: 2px solid var(--mint);
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.04em;
  min-height: 60px;
  padding: 14px 26px;
  cursor: pointer;
}
.plate:hover { background: #5effd6; }
.plate:focus-visible { outline: 3px solid var(--ink-yellow); outline-offset: 3px; }
.plate[hidden] { display: none; }

/* ---------- the ident window, dragged by its title strip ------------------------------- */
.ident { max-width: 640px; }
.ident .body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.ident .links { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.key.mark-only { padding: 14px 10px; min-width: 0; }
.key.mark-only img { height: 24px; }
.ident .links > .solid { grid-column: 1 / -1; }

/* ---------- toast -------------------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--bezel) + 110px);
  transform: translateX(-50%);
  z-index: 70;
  background: var(--mint);
  color: #001209;
  font-weight: 500;
  letter-spacing: 0.1em;
  padding: 16px 28px;
  font-size: var(--label);
  box-shadow: 0 0 22px rgba(0, 240, 176, 0.5);
}
.toast[hidden] { display: none; }

/* ---------- modal -------------------------------------------------------------------- */
dialog {
  border: 2px solid var(--mint);
  background: #00140c;
  color: var(--mint);
  padding: 0;
  max-width: min(860px, 92vw);
  box-shadow: 0 0 40px rgba(0, 240, 176, 0.3);
}
dialog::backdrop { background: rgba(0, 0, 0, 0.82); }
dialog .body { padding: 32px; }

/* ---------- phone --------------------------------------------------------------------- */
/* ---------- a short window: a laptop at 1366x695 still has to show the object ------------ */
@media (min-width: 901px) and (max-height: 820px) {
  :root {
    --display: clamp(38px, 11vh, 96px);
    --lockup: clamp(19px, 3.6vh, 32px);
    --station: clamp(16px, 2.4vh, 22px);
    --band: clamp(12px, 1.8vh, 18px);
  }
  .screen { padding-top: calc(var(--bezel) + 12px); padding-bottom: calc(var(--bezel) + 10px); }
  .counter { grid-template-rows: minmax(150px, 1fr) auto auto; }
  .bar { height: 36px; }
  .keys button, .plate { min-height: 50px; padding: 10px 18px; }
  .counter .ident > header { min-height: 40px; padding: 8px 20px; }
  .counter .ident > .body { padding: 16px 20px; gap: 10px; }
  .counter .ident .key { min-height: 44px; }
  .counter .ident .addr { padding: 10px 18px; }
}

/* ---------- phone: the terminal becomes a roll of paper, and the keys ride with it ----- */
@media (max-width: 900px) {
  :root {
    --display: clamp(40px, 13vw, 76px);
    --lockup: clamp(21px, 6vw, 32px);
    --station: clamp(17px, 4.3vw, 21px);
    --title: clamp(26px, 7vw, 34px);
    --numeral: clamp(28px, 8vw, 38px);
    --band: 24px;
  }
  /* the roll of paper is longer than the screen, so the document itself has to grow */
  html, body { height: auto; min-height: 100%; }
  .screen { height: auto; min-height: 100dvh; overflow: visible; padding-bottom: calc(var(--bezel) + 40px); }
  main { justify-content: flex-start; }
  main > .sheet { overflow: visible; padding-right: 0; }
  .station { display: block; }
  .station .caret { margin-right: 0.5em; }
  .station .fill { display: inline; }
  .station .right { display: block; margin: 8px 0 0; }
  .counter { height: auto; grid-template-rows: auto auto auto; }
  .stage { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; gap: var(--band); }
  .sheet-strip { height: auto; aspect-ratio: auto; max-width: none; }
  .sheet-strip .today { width: min(58vw, 250px); }
  .sheet-strip .flank { display: none; }
  .counters { grid-template-columns: repeat(3, 1fr); justify-self: stretch; gap: 14px; }
  .counter .ident { justify-self: stretch; width: 100%; }
  .lockup { width: 100%; }
  .lockup .legend { text-align: left; }
  .bar-row { width: 100%; }
  .two { grid-template-columns: 1fr; }
  .grid3, .grid4 { grid-template-columns: 1fr 1fr; }
  .keys { grid-template-columns: repeat(3, 1fr); }
  .plate { grid-column: 1 / -1; border-left: 0; border-top: 2px solid var(--mint); }
  .keys {
    position: sticky;
    bottom: var(--bezel);
    z-index: 30;
    grid-template-columns: repeat(3, 1fr);
    background: #000704;
    margin-top: var(--band);
  }
  .keys button:nth-child(4) { border-left: 0; }
  .keys button:nth-child(n + 4) { border-top: 2px solid var(--mint); }
  .keys button { letter-spacing: 0.05em; padding: 12px 10px; min-height: 54px; }
}
@media (max-width: 560px) {
  .grid3, .grid4 { grid-template-columns: 1fr; }
  .counters { grid-template-columns: repeat(3, 1fr); text-align: left; gap: 10px; }
  .counters .k { letter-spacing: 0.08em; }
  .win > .body { padding: 22px 20px; }
  .ident .links { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* the smallest phones: the command bar cannot hold three cells without crowding the words */
@media (max-width: 360px) {
  .keys { grid-template-columns: repeat(2, 1fr); }
  .keys button:nth-child(3) { border-left: 0; }
  .keys button:nth-child(5) { border-left: 0; }
  .keys button:nth-child(n + 3) { border-top: 2px solid var(--mint); }
}

@media (prefers-reduced-motion: reduce) {
  .glass::after { animation: none; display: none; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---------- send: the card on the left, the agency's form on the right ------------------ */
.send { display: grid; grid-template-columns: minmax(0, 0.82fr) minmax(0, 1fr); gap: calc(var(--gutter) * 1.6); align-items: start; }
.preview { position: sticky; top: 0; display: grid; gap: var(--band); }
.card-flip { position: relative; perspective: 1400px; aspect-ratio: 3 / 2; }
.card-side { position: absolute; inset: 0; backface-visibility: hidden; transition: transform 0.6s ease; }
.card-side canvas { display: block; width: 100%; height: 100%; }
.card-side.front { transform: rotateY(0deg); }
.card-side.back { transform: rotateY(180deg); }
.card-flip.turned .card-side.front { transform: rotateY(-180deg); }
.card-flip.turned .card-side.back { transform: rotateY(0deg); }
.preview-foot { display: flex; align-items: center; gap: var(--gutter); flex-wrap: wrap; }

.sendform { display: grid; gap: calc(var(--band) * 1.6); }
.fieldset { padding-top: 4px; }
.fieldset > .label { color: var(--mint); letter-spacing: 0.18em; }
.fieldset > .label { margin-bottom: 16px; }
.row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.row > input[type="text"] { flex: 1 1 240px; }
.row.between { justify-content: space-between; }
.presses { gap: 14px; }
.pick-art { display: block; position: relative; }
.pick-art canvas { display: block; width: 100%; height: auto; }
.check { display: flex; align-items: center; gap: 14px; font-size: var(--label); color: var(--mint-2); min-height: 48px; }
.check input { width: 24px; height: 24px; accent-color: var(--mint); }
.price { font-size: var(--station); color: var(--mint); margin: 0 0 4px; }
.status { min-height: 1.6em; margin: 0; }
.small { font-size: var(--label); }

@media (max-width: 900px) {
  .send { grid-template-columns: 1fr; }
  .preview { position: static; }
  .presses { grid-template-columns: 1fr 1fr; }
}

/* ---------- tiles: a card, a stamp, a photograph, a step -------------------------------- */
.tile { display: flex; flex-direction: column; min-width: 0; }
.tile-art { position: relative; }
.tile-art canvas { display: block; width: 100%; height: auto; }
.stamp-art { width: 78%; margin: 0 auto; }
.tile-body { padding: 18px 0 0; display: grid; gap: 10px; }
.tile-body p { margin: 0; }
.step-n {
  font-family: Miedinger, Jost, sans-serif;
  font-weight: 700;
  font-size: var(--numeral);
  line-height: 1;
  color: var(--mint-2);
}
.rows-dl { margin: 0; display: grid; gap: 8px; }
.rows-dl > div { display: flex; gap: 1em; align-items: baseline; justify-content: space-between; border-bottom: 1px solid rgba(11, 114, 86, 0.5); padding-bottom: 8px; }
.rows-dl dt { color: var(--mint-2); font-size: var(--label); letter-spacing: 0.1em; margin: 0; }
.rows-dl dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.rule { border: 0; border-top: 2px solid var(--mint-3); margin: 10px 0; }

/* ---------- a card's own page ----------------------------------------------------------- */
.card-page { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr); gap: calc(var(--gutter) * 1.6); align-items: start; }
.card-page-art canvas { display: block; width: 100%; height: auto; }
.card-page-body { display: grid; gap: var(--band); }

@media (max-width: 900px) {
  .card-page { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
}
