/* ════════════════════════════════════════════════════════════════════════
   猜赛马 — keiba.rosist.uk

   Design system, in one place.

   Colour comes from the racetrack, not from a chart library: 夺冠的金 for a
   match, 泥地的土 for a near miss, 墨 for nothing. Feedback is carried first
   by the 印 glyph (◎ ○ ×) that every Japanese racing paper uses, with the tint
   as a second channel — so the grid still reads correctly without colour.

   Type: system gothic stacks for CJK (fast, and reachable from mainland China,
   unlike a webfont CDN), plus one self-hosted condensed Latin for figures so
   the numeric columns read like a printed race card.
   ════════════════════════════════════════════════════════════════════════ */

@font-face {
  font-family: 'Barlow Condensed';
  src: url('/fonts/barlow-condensed-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url('/fonts/barlow-condensed-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}

:root {
  --ink:      #0d100f;
  --ink-2:    #151a18;
  --ink-3:    #1e2523;
  --turf:     #15281e;
  --paper:    #eae4d6;
  --paper-2:  #cfc6b1;
  --paper-3:  #a89f8b;
  --gold:     #c9a227;
  --gold-lit: #eccb56;
  --dirt:     #a86b32;
  --dirt-lit: #d99552;
  --sumi:     #4a514d;
  --jra-red:  #c8202c;

  --hit-bg:   #4a3c0c;
  --hit-fg:   var(--gold-lit);
  --near-bg:  #3d2712;
  --near-fg:  var(--dirt-lit);
  --miss-bg:  #1a1f1d;
  --miss-fg:  #6d746f;

  --font-cjk: -apple-system, BlinkMacSystemFont, 'Hiragino Sans', 'Hiragino Kaku Gothic ProN',
              'Yu Gothic', 'Noto Sans JP', 'PingFang SC', 'Microsoft YaHei',
              'Noto Sans SC', 'Source Han Sans SC', sans-serif;
  --font-num: 'Barlow Condensed', 'Hiragino Sans', 'Yu Gothic', sans-serif;

  --rule: 1px solid #2a322e;
  --gap: clamp(0.9rem, 3vw, 1.5rem);
  --pad: clamp(1rem, 4vw, 2rem);
  --maxw: 1180px;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-cjk);
  font-size: 16px;
  line-height: 1.65;
  font-feature-settings: 'palt' 1;
  display: flex;
  flex-direction: column;
  /* faint turf texture: two very low-contrast diagonal bands, nothing more */
  background-image:
    repeating-linear-gradient(115deg, rgba(255,255,255,.014) 0 2px, transparent 2px 9px);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

a { color: var(--gold-lit); }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--gold-lit);
  outline-offset: 2px;
}

/* ─────────────────────────── masthead ─────────────────────────── */

.masthead {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: stretch; justify-content: space-between; gap: 1rem;
  padding: 0 var(--pad);
  background: color-mix(in srgb, var(--ink) 92%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: var(--rule);
}

.wordmark {
  display: flex; align-items: center; gap: .55rem;
  padding: .7rem 0; text-decoration: none; color: inherit;
}
.wordmark__kanji {
  display: grid; place-items: center;
  width: 2.1rem; height: 2.1rem;
  background: var(--jra-red); color: #fff;
  font-size: 1.35rem; font-weight: 900; line-height: 1;
  /* a 枠番 chip is a hard-edged square; no rounding anywhere on this mark */
}
.wordmark__stack { display: flex; flex-direction: column; line-height: 1.05; }
.wordmark__latin {
  font-family: var(--font-num); font-weight: 700; font-size: .78rem;
  letter-spacing: .16em; color: var(--paper-3);
}
.wordmark__zh { font-style: normal; font-weight: 800; font-size: 1.05rem; letter-spacing: .06em; }

/* mode switch as two ticket stubs; the active one is "punched" */
.tickets { display: flex; align-items: flex-end; gap: .4rem; }
.ticket {
  position: relative;
  border: var(--rule); border-bottom: 0;
  background: var(--ink-2); color: var(--paper-3);
  padding: .45rem .85rem .5rem;
  font: inherit; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; line-height: 1.15;
  transition: color .15s, background .15s, transform .15s;
}
.ticket__ja { font-size: .82rem; font-weight: 700; letter-spacing: .04em; }
.ticket__zh { font-size: .66rem; letter-spacing: .1em; color: var(--paper-3); }
.ticket:hover { color: var(--paper); background: var(--ink-3); }
.ticket.is-on {
  background: var(--paper); color: var(--ink); border-color: var(--paper);
  transform: translateY(1px);
}
.ticket.is-on .ticket__zh { color: #5a5347; }
/* the punch hole */
.ticket.is-on::after {
  content: ''; position: absolute; top: .35rem; right: .3rem;
  width: 5px; height: 5px; border-radius: 50%; background: var(--jra-red);
}

/* ─────────────────────────── views ─────────────────────────── */

main { flex: 1; width: 100%; max-width: var(--maxw); margin: 0 auto; padding: var(--pad); }

.view { display: none; }
body[data-view='start']    #view-start,
body[data-view='classic']  #view-classic,
body[data-view='dialogue'] #view-dialogue { display: block; }

/* ─────────────────────────── hero ─────────────────────────── */

.hero { padding: clamp(1.5rem, 6vw, 4rem) 0 clamp(1.5rem, 5vw, 3rem); max-width: 46ch; }

.eyebrow {
  margin: 0 0 1rem;
  font-family: var(--font-num); font-weight: 600; font-size: .82rem;
  letter-spacing: .22em; text-transform: uppercase; color: var(--paper-3);
}
.eyebrow::before {
  content: ''; display: inline-block; vertical-align: .28em;
  width: 2.2rem; height: 2px; margin-right: .7rem; background: var(--jra-red);
}

.hero__title {
  margin: 0 0 1.1rem;
  font-size: clamp(2.3rem, 10vw, 4.4rem);
  font-weight: 900; line-height: 1.08; letter-spacing: -.02em;
}
.hero__title .mark { font-size: .92em; vertical-align: -.04em; margin-left: .1em; }

.hero__lede { margin: 0 0 1.8rem; color: var(--paper-2); font-size: 1.02rem; }
.hero__lede b { color: var(--gold-lit); font-weight: 700; }

.tally { display: flex; gap: clamp(1.2rem, 5vw, 2.6rem); margin: 0; flex-wrap: wrap; }
.tally dt {
  font-size: .72rem; letter-spacing: .16em; color: var(--paper-3);
  font-family: var(--font-num); font-weight: 600; text-transform: uppercase;
}
.tally dd {
  margin: 0; font-family: var(--font-num); font-weight: 700;
  font-size: clamp(1.7rem, 6vw, 2.4rem); line-height: 1;
  font-variant-numeric: tabular-nums;
}

/* ─────────────────────────── mode picks ─────────────────────────── */

.picks {
  display: grid; gap: var(--gap);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  padding-bottom: 1rem;
}

.pick {
  display: grid; gap: .85rem; align-content: start;
  padding: 1.35rem 1.3rem 1.2rem;
  text-align: left; cursor: pointer; font: inherit;
  border: var(--rule);
  background: var(--ink-2); color: var(--paper);
  transition: border-color .18s, background .18s, transform .18s;
}
.pick:hover { border-color: var(--gold); background: var(--ink-3); transform: translateY(-2px); }

.pick__label { font-size: .78rem; letter-spacing: .14em; color: var(--paper-3); }
.pick__label b {
  display: block; font-size: 1.5rem; letter-spacing: .02em;
  color: var(--paper); font-weight: 800; line-height: 1.2;
}
.pick__demo { display: flex; gap: .3rem; }
.pick__demo--say {
  display: block; font-size: 1.15rem; color: var(--gold-lit);
  font-weight: 600; letter-spacing: .03em;
}
.pick__body { color: var(--paper-2); font-size: .93rem; line-height: 1.6; }
.pick__go {
  font-family: var(--font-num); font-weight: 700; font-size: .95rem;
  letter-spacing: .1em; color: var(--gold-lit);
}
.pick--dark { background: var(--turf); }
.pick--dark:hover { background: #1a3126; }

/* ─────────────────────────── 印 marks ─────────────────────────── */

.mark {
  display: inline-grid; place-items: center;
  width: 1.55em; height: 1.55em;
  font-style: normal; font-weight: 700; line-height: 1;
}
.mark--hit  { background: var(--hit-bg);  color: var(--hit-fg); }
.mark--near { background: var(--near-bg); color: var(--near-fg); }
.mark--miss { background: var(--miss-bg); color: var(--miss-fg); }

/* ─────────────────────────── race card (setup) ─────────────────────────── */

.racecard { border: var(--rule); background: var(--ink-2); }
.racecard__row {
  display: flex; align-items: center; gap: .8rem; flex-wrap: wrap;
  padding: .85rem 1rem; border-bottom: var(--rule);
}
.racecard__row:last-child { border-bottom: 0; }
.racecard__key {
  flex: 0 0 3.5rem;
  font-size: .74rem; letter-spacing: .14em; color: var(--paper-3);
  font-weight: 700;
}
.racecard__row--go { justify-content: space-between; }
.racecard__buttons { display: flex; gap: .5rem; flex-wrap: wrap; }

.segbar { display: flex; flex-wrap: wrap; gap: .3rem; }
.seg {
  border: var(--rule); background: transparent; color: var(--paper-2);
  font: inherit; font-size: .88rem; padding: .3rem .7rem; cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.seg:hover { border-color: var(--paper-3); color: var(--paper); }
.seg.is-on { background: var(--paper); border-color: var(--paper); color: var(--ink); font-weight: 700; }
.seg--uma.is-on { background: #ff9fc0; border-color: #ff9fc0; }

.poolnote { margin: 0; font-size: .82rem; color: var(--paper-3); }

/* ─────────────────────────── buttons ─────────────────────────── */

.btn {
  border: var(--rule); background: transparent; color: var(--paper);
  font: inherit; font-weight: 700; font-size: .95rem;
  padding: .5rem 1.1rem; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s, border-color .15s, opacity .15s;
}
.btn--gold { background: var(--gold); border-color: var(--gold); color: #1a1403; }
.btn--gold:hover { background: var(--gold-lit); border-color: var(--gold-lit); }
.btn--paper { background: var(--paper); border-color: var(--paper); color: var(--ink); }
.btn--paper:hover { background: #fff; }
.btn--ghost:hover { border-color: var(--paper); }
.btn--quiet { border-color: transparent; color: var(--paper-3); font-weight: 500; font-size: .85rem; }
.btn--quiet:hover { color: var(--jra-red); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ═════════════════════ classic: 属性表 (newsprint) ═════════════════════ */

.board { margin-top: var(--gap); }

.board__head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
  padding-bottom: .7rem; border-bottom: 2px solid var(--paper);
}
.board__meta { margin: 0; display: flex; align-items: center; gap: .6rem; font-size: .9rem; color: var(--paper-2); }
.chip--race {
  font-family: var(--font-num); font-weight: 700; letter-spacing: .06em;
  background: var(--jra-red); color: #fff; padding: .1rem .45rem;
}
.board__left { margin: 0; font-size: .85rem; color: var(--paper-3); letter-spacing: .1em; }
.board__left b {
  font-family: var(--font-num); font-size: 1.5rem; color: var(--paper);
  font-variant-numeric: tabular-nums;
}

.guessbar { display: flex; gap: .5rem; margin: .9rem 0 .35rem; }
.guessbar__field { position: relative; flex: 1; min-width: 0; }

.input {
  width: 100%; border: var(--rule); background: var(--ink-2); color: var(--paper);
  font: inherit; font-size: 1rem; padding: .62rem .8rem;
}
.input::placeholder { color: #6b726d; }
.input:focus { border-color: var(--gold); }

.ac {
  position: absolute; left: 0; right: 0; top: calc(100% + 2px); z-index: 30;
  margin: 0; padding: 0; list-style: none; max-height: 15rem; overflow: auto;
  background: var(--ink-3); border: 1px solid var(--gold);
  box-shadow: 0 12px 32px rgba(0,0,0,.55);
}
.ac li {
  padding: .45rem .8rem; cursor: pointer;
  display: flex; align-items: baseline; gap: .6rem;
  border-bottom: 1px solid #262e2a;
}
.ac li:last-child { border-bottom: 0; }
.ac li:hover, .ac li[aria-selected='true'] { background: var(--gold); color: #1a1403; }
.ac small { color: var(--paper-3); font-size: .76rem; }
.ac li:hover small, .ac li[aria-selected='true'] small { color: #5a4a10; }

.formnote { margin: .1rem 0 0; min-height: 1.3em; font-size: .83rem; color: var(--jra-red); }
.formnote.is-ok { color: var(--paper-3); }

.legend {
  display: flex; flex-wrap: wrap; gap: .35rem 1rem; margin: .8rem 0 .6rem;
  font-size: .76rem; color: var(--paper-3);
}
.legend span { display: inline-flex; align-items: center; gap: .3rem; }
.legend .mark { width: 1.35em; height: 1.35em; font-size: .8rem; }
.arrow { font-style: normal; color: var(--gold-lit); font-weight: 700; }

.gridwrap { overflow-x: auto; margin: 0 calc(var(--pad) * -1); padding: 0 var(--pad); }

.grid { width: 100%; border-collapse: collapse; font-size: .85rem; }
.grid thead th {
  position: sticky; top: 0; z-index: 5;
  background: var(--ink); color: var(--paper-3);
  font-size: .7rem; font-weight: 700; letter-spacing: .06em;
  text-align: center; padding: .5rem .35rem; white-space: nowrap;
  border-bottom: 1px solid var(--sumi);
}
.grid thead th:first-child { text-align: left; }
.grid tbody tr { border-bottom: 1px solid #212825; }
.grid tbody tr.is-correct { background: rgba(201,162,39,.09); }

.grid .cell-name {
  padding: .5rem .4rem; white-space: nowrap;
  position: sticky; left: 0; z-index: 4; background: var(--ink);
  border-right: 1px solid var(--sumi);
}
.grid tbody tr.is-correct .cell-name { background: #241d08; }
.namebox { display: flex; align-items: center; gap: .5rem; }
.gate {
  flex: 0 0 auto; display: grid; place-items: center;
  width: 1.45rem; height: 1.45rem;
  font-family: var(--font-num); font-weight: 700; font-size: .95rem; line-height: 1;
}
.namebox b { font-weight: 700; font-size: .93rem; }
.namebox small { display: block; color: var(--paper-3); font-size: .7rem; font-weight: 400; }

.grid td.cell {
  padding: .35rem .3rem; text-align: center; vertical-align: middle;
  border-left: 1px solid #1c2320;
}
.cellbox {
  display: flex; flex-direction: column; align-items: center; gap: .1rem;
  min-width: 4.2rem; padding: .28rem .3rem;
}
.cell[data-state='hit']  .cellbox { background: var(--hit-bg);  color: var(--hit-fg); }
.cell[data-state='near'] .cellbox { background: var(--near-bg); color: var(--near-fg); }
.cell[data-state='miss'] .cellbox { background: var(--miss-bg); color: var(--miss-fg); }
.cellbox i {
  font-style: normal; font-weight: 700; font-size: .95rem; line-height: 1;
}
.cellbox span {
  font-size: .74rem; line-height: 1.25; max-width: 8rem;
  overflow-wrap: anywhere; color: var(--paper-2);
}
.cell[data-state='miss'] .cellbox span { color: #838a85; }
.cellbox span.num { font-family: var(--font-num); font-size: .92rem; font-weight: 600; }
.cellbox em { font-style: normal; color: var(--gold-lit); font-weight: 700; }

/* one row lands at a time */
@keyframes settle {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}
.grid tbody tr { animation: settle .26s ease-out both; }

.tail { display: flex; justify-content: flex-end; padding: .8rem 0 1.5rem; }

/* mobile: the table becomes one card per guess. A 13-column scroll is hostile
   on a phone; the same data reads fine as a labelled chip grid. */
@media (max-width: 860px) {
  .gridwrap { overflow: visible; margin: 0; padding: 0; }
  .grid, .grid tbody, .grid tr, .grid td { display: block; width: auto; }
  .grid thead { display: none; }
  .grid tbody tr {
    border: var(--rule); margin-bottom: .7rem; padding: .55rem .6rem .6rem;
    background: var(--ink-2);
  }
  .grid tbody tr.is-correct { border-color: var(--gold); }
  .grid .cell-name {
    position: static; border-right: 0; padding: 0 0 .5rem;
    border-bottom: 1px solid #262e2a; margin-bottom: .5rem; background: transparent;
  }
  .grid tbody tr.is-correct .cell-name { background: transparent; }
  .grid tbody { display: block; }
  .grid tbody tr {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(5.3rem, 1fr));
    gap: .35rem;
  }
  .grid .cell-name { grid-column: 1 / -1; }
  .grid td.cell { border-left: 0; padding: 0; }
  .cellbox { min-width: 0; align-items: flex-start; height: 100%; }
  .cellbox::before {
    content: attr(data-label);
    font-size: .62rem; letter-spacing: .08em; color: var(--paper-3);
    line-height: 1.2;
  }
  .cellbox { flex-direction: column; }
  .cellbox i { order: 2; }
  .cellbox span { order: 3; }
}

/* ═════════════════════ dialogue: 对话 ═════════════════════ */

.paddock {
  margin-top: var(--gap);
  border: var(--rule);
  background:
    radial-gradient(120% 70% at 50% -10%, rgba(201,162,39,.13), transparent 60%),
    var(--turf);
}

.paddock__head {
  display: flex; align-items: center; gap: .9rem; flex-wrap: wrap;
  padding: .85rem 1rem; border-bottom: var(--rule);
}
.paddock__who { margin: 0; display: flex; align-items: center; gap: .6rem; flex: 1 1 auto; }
.silhouette {
  display: grid; place-items: center; flex: 0 0 auto;
  width: 2.3rem; height: 2.3rem;
  background: #0d1a13; border: 1px solid var(--gold);
  color: var(--gold-lit); font-family: var(--font-num); font-weight: 700; font-size: 1.2rem;
}
.paddock__who b { display: block; font-size: .98rem; line-height: 1.25; }
.paddock__who small { display: block; font-size: .7rem; color: var(--paper-3); letter-spacing: .08em; }
.paddock__count { margin: 0; font-size: .78rem; color: var(--paper-3); letter-spacing: .08em; }
.paddock__count b { font-family: var(--font-num); font-size: 1.25rem; color: var(--paper); }

/* signature element: how much the character is currently willing to say */
.meter { display: flex; gap: 2px; flex: 0 0 auto; }
.meter__seg {
  position: relative; width: 3.4rem; height: 1.5rem;
  background: #0d1a13; border: 1px solid #2b3d33;
  display: grid; place-items: center; overflow: hidden;
}
.meter__seg i {
  font-style: normal; font-size: .6rem; letter-spacing: .04em; color: #5d6b63;
  position: relative; z-index: 2;
}
.meter__seg.is-lit { background: var(--gold); border-color: var(--gold); }
.meter__seg.is-lit i { color: #1a1403; font-weight: 700; }
.meter__seg.is-now::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: var(--gold-lit);
  animation: pulse 1.9s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: .25; } 50% { opacity: .75; } }

.log {
  display: flex; flex-direction: column; gap: .7rem;
  padding: 1.1rem 1rem; min-height: 16rem; max-height: 52vh; overflow-y: auto;
}

.bubble {
  max-width: min(85%, 34rem); padding: .6rem .85rem;
  font-size: .95rem; line-height: 1.7; white-space: pre-wrap;
  animation: settle .3s ease-out both;
}
.bubble--them {
  align-self: flex-start; background: var(--paper); color: #17201b;
  border-left: 3px solid var(--gold);
}
.bubble--me {
  align-self: flex-end; background: #0e1c15; color: var(--paper);
  border: 1px solid #2b3d33; border-right: 3px solid var(--paper-3);
}
.bubble--sys {
  align-self: center; max-width: 100%; background: transparent; color: var(--paper-3);
  font-size: .8rem; letter-spacing: .06em; padding: .1rem;
}
.bubble--sys b { color: var(--jra-red); }
.bubble--typing { color: var(--paper-3); font-style: italic; }

.saybar { display: flex; gap: .5rem; padding: 0 1rem .5rem; }
.saybar--answer { padding-bottom: .3rem; }
.saybar .input { background: #0d1a13; }
.input--answer { border-color: var(--gold); }
.saybar--answer .guessbar__field { flex: 1; position: relative; min-width: 0; }
.paddock .formnote { padding: 0 1rem; }
.paddock .tail { padding: .3rem 1rem 1rem; }

/* The HTML `hidden` attribute is only a *default* of display:none, so any rule
   that sets display on the same element silently wins and the element stays on
   screen. .sheet, .paddock and .ac are all display:grid/flex, so without this
   the result sheet renders over the page the moment it loads — before a round
   has even been played — and nothing can dismiss it. !important because the
   attribute is the app's one switch for "not on screen right now". */
[hidden] { display: none !important; }

/* ═════════════════════ result sheet ═════════════════════ */

.sheet {
  position: fixed; inset: 0; z-index: 60;
  display: grid; place-items: end center;
  background: rgba(6,9,8,.72); backdrop-filter: blur(4px);
  padding: 0;
}
@media (min-width: 640px) { .sheet { place-items: center; padding: var(--pad); } }

.sheet__panel {
  position: relative;
  width: 100%; max-width: 34rem; max-height: 92dvh; overflow-y: auto;
  background: var(--ink-2); border: 1px solid var(--gold);
  padding: 1.4rem 1.3rem 1.2rem;
  animation: rise .3s cubic-bezier(.2,.9,.3,1) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

.sheet__close {
  position: absolute; top: .5rem; right: .6rem;
  background: none; border: 0; color: var(--paper-3);
  font-size: 1.6rem; line-height: 1; padding: .3rem .5rem; cursor: pointer;
}
.sheet__close:hover, .sheet__close:focus-visible { color: var(--paper-1); }

.sheet__verdict {
  margin: 0 0 .3rem;
  font-family: var(--font-num); font-weight: 700; font-size: 1rem;
  letter-spacing: .24em; text-transform: uppercase; color: var(--gold-lit);
}
.sheet__verdict.is-lost { color: var(--jra-red); }
.sheet__name { margin: 0; font-size: clamp(1.6rem, 7vw, 2.3rem); font-weight: 900; line-height: 1.2; }
.sheet__sub { margin: .2rem 0 1.1rem; color: var(--paper-3); font-size: .9rem; }

.facts { margin: 0 0 1rem; display: grid; gap: 0; }
.facts > div {
  display: grid; grid-template-columns: 6.5rem 1fr; gap: .6rem;
  padding: .4rem 0; border-bottom: 1px solid #242b28;
}
.facts dt { font-size: .76rem; color: var(--paper-3); letter-spacing: .06em; padding-top: .15rem; }
.facts dd { margin: 0; font-size: .9rem; overflow-wrap: anywhere; }

.umacard {
  border: 1px solid #4a3a44; background: #1d1419; padding: .85rem 1rem; margin-bottom: 1rem;
}
.umacard h4 {
  margin: 0 0 .45rem; font-size: .74rem; letter-spacing: .18em; color: #ff9fc0;
  font-weight: 700;
}
.umacard p { margin: .2rem 0; font-size: .88rem; color: var(--paper-2); }
.umacard q { color: var(--paper); font-style: italic; }

.sheet__share {
  font-family: var(--font-num); font-size: 1rem; letter-spacing: .1em;
  background: var(--ink); border: var(--rule); padding: .6rem .8rem;
  white-space: pre-wrap; margin: 0 0 1rem; color: var(--paper-2);
}
.sheet__buttons { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: flex-end; }

/* ─────────────────────────── colophon ─────────────────────────── */

.colophon {
  padding: 1.6rem var(--pad) 2.2rem;
  border-top: var(--rule);
  font-size: .76rem; color: #6d746f; line-height: 1.7;
}
.colophon p { margin: 0 auto; max-width: var(--maxw); }
.colophon a { color: #8a9089; }

/* ─────────────────────────── motion ─────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
