/* kit.css — THE KIT: every component of torpak lite and every state it has, on the tokens (tokens.css), the type
   scale (type.css) and the motion table (motion.css). A screen composes these and adds no style of its own; a new
   part is a new block here, rendered on the kit sheet before it is used (docs/project/research/web/style/kit_sheet.png). */

/* ---- the page and the frame */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink); overflow: hidden; }
.grain { position: fixed; inset: 0; pointer-events: none; opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E"); }
.app { display: grid; grid-template-rows: var(--top-h) 1fr var(--hand-h); height: 100%; min-width: 1280px; }
.top { display: grid; grid-template-columns: var(--rail-w) minmax(0, 1fr) var(--rail-w); align-items: center; gap: var(--sp-4); padding: 0 var(--sp-4); }
.table { display: grid; grid-template-columns: var(--rail-w) 1fr var(--rail-w); gap: var(--sp-4); padding: 0 var(--sp-4); min-height: 0; }
.hand { display: flex; justify-content: center; align-items: flex-end; gap: var(--sp-4); padding: 0 var(--sp-4) var(--sp-3); }

/* ---- a panel: card stock with a printed rule */
.panel { background: var(--panel); background-image: var(--stock); border: var(--ink-w) solid var(--panel-border); border-radius: var(--radius-2); box-shadow: var(--shadow); padding: var(--sp-4); }
.rail { display: flex; flex-direction: column; gap: var(--sp-3); min-height: 0; overflow: hidden; }
.rail-title { display: flex; justify-content: space-between; gap: var(--sp-3); border-bottom: 2px solid var(--ink); padding-bottom: var(--sp-1); color: var(--ink); }
.rail-title > :last-child:not(:first-child) { text-align: right; }   /* a long right side (who stands, W4's tags) wraps flush right, apart from the left */
.rail-title .people > span { white-space: nowrap; }   /* the room's standing: a person and its tag never broken (W4) */

/* ---- the swatch: a seat's colour as a small hex */
.swatch { display: inline-block; width: 12px; height: 12px; clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); background: var(--seat); }

/* ---- a seat row (the world rail): standing · swatch · name · score / the land line */
.seat { display: grid; grid-template-columns: 18px 14px 1fr auto; column-gap: var(--sp-2); align-items: center; padding: 6px var(--sp-2); border-radius: var(--radius-2); transition: background var(--dur-base) var(--ease-out); }
.seat .standing { color: var(--muted); font-family: var(--font-num); font-size: 12px; }
.seat .name { color: var(--seat); }
.seat .line2 { grid-column: 3 / span 2; color: var(--muted); font-size: 13px; }
.seat .line2 b { color: var(--ink); font-weight: 500; }
.seat .cut { color: var(--danger); }
.seat.is-acting { background: var(--lit); }
.seat.is-acting.is-new { animation: light-in var(--dur-base) var(--ease-out) both; animation-delay: var(--since, 0ms); }   /* the acting seat's row lights in with the plate (B7) */
.seat.is-out { opacity: .45; }
.seat.is-out .name { text-decoration: line-through; }
.seat.is-you .name::after { content: " · YOU"; font-size: 11px; letter-spacing: .12em; color: var(--muted); }
.seat .presence { color: var(--muted); font-size: 11px; letter-spacing: .12em; }   /* PRESENCE (w43, B14): "· away" / "· AI plays" after a human's name */
.seat .income { color: var(--muted); cursor: default; }   /* GOLD SAID (B14): "+5 at the shop", the receipt its browser tip */
/* a human seat's NAME TIP (W4): the pointer on its name shows the name as it was given with its TAG — a tip in the
   plate's look standing over the name, its words where the name's begin, so the rail never reflows and the row keeps
   its score; never wider than the rail */
.seat .name { position: relative; }
.seat .nametip { display: none; position: absolute; z-index: 2; left: calc(-1 * var(--sp-2) - 1px); bottom: calc(100% + var(--sp-1)); width: max-content; max-width: calc(var(--rail-w) - 80px); padding: var(--sp-1) var(--sp-2); background: var(--plate); color: var(--seat); border: 1px solid var(--plate-border); border-radius: var(--radius-2); box-shadow: var(--shadow); pointer-events: none; }
.seat .nametip .nametag { color: var(--plate-muted); }
.seat .name:hover > .nametip, .seat .name.is-hover > .nametip { display: block; }

/* ---- the turn plate: one dark box for what changes together */
.plate { display: flex; align-items: center; gap: var(--sp-4); height: 44px; padding: var(--sp-2) var(--sp-4); background: var(--plate); color: var(--plate-ink); border: 1px solid var(--plate-border); border-radius: var(--radius-1); }
/* THE PLATE'S ROOM (B16, w46): the seat's word keeps its line at every width and, squeezed, is the last thing to give (its
   overflow hidden, it may shrink to nothing); the phase and the clock never shrink or wrap; the ask takes the room left.
   The ladder's rungs (`table.js` `_fit`, each taken only while the ask is still cut): `is-tight` — the clock's label
   gone and its bar the narrow one; `is-tighter` — the seat's word capped at 11em */
.plate .turn { color: var(--seat); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plate.is-tighter .turn { max-width: 11em; }
.plate .phase { color: var(--accent); letter-spacing: .12em; flex-shrink: 0; white-space: nowrap; }
.plate .ask { flex: 1; min-width: 0; color: var(--plate-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plate .ask .who { color: var(--seat); font-weight: 700; }   /* a won war's loser, named in his colour (w31) */
/* the plate changing seat (B7): the name fades in in the new seat's colour, the ask rises 8px into place */
.plate.is-new .turn { animation: fade-in var(--dur-base) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.plate.is-new .ask { animation: ask-rise var(--dur-base) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.plate .clock { display: flex; align-items: center; gap: var(--sp-2); flex-shrink: 0; white-space: nowrap; }
.plate .clock .bar { width: 90px; height: 4px; background: var(--plate-muted); opacity: .5; border-radius: 2px; overflow: hidden; }
.plate .clock .bar i { display: block; height: 100%; background: var(--accent); transition: width 1s linear; }
.plate .clock .t.is-danger { color: var(--danger); animation: pulse-danger 1s ease-in-out infinite; }
.plate .clock .label { color: var(--plate-muted); }
.plate.is-tight .clock .label { display: none; }
.plate.is-tight .clock .bar { width: 48px; }

/* ---- the round pips and the order chips (the top bar's left: the round's word, then its pips) */
.round { display: flex; align-items: center; gap: var(--sp-3); }
.round .is-last { color: var(--danger); }   /* THE LAST ROUND (B12, w32): the whole round reads LAST ROUND, the pips kept */
.pips { display: flex; gap: var(--sp-1); }
.pip { width: 10px; height: 10px; border-radius: 50%; background: var(--pip); }
.pip.is-on { background: var(--accent); }
.order { display: flex; justify-content: flex-end; gap: var(--sp-2); min-width: 0; }   /* six seats at 1280: the chips shrink, their names cut */
.chip { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; padding: 4px var(--sp-2); border-radius: var(--radius-pill); border: 1px solid var(--line); color: var(--seat); opacity: .55; font-size: 12px; letter-spacing: .08em; }
.chip.is-on { opacity: 1; border-color: currentColor; }
.chip.is-out { text-decoration: line-through; }
/* THE TOP BAR'S ORDER (w67, backlog w65.2): the room shared out EVENLY, no chip past its own width, and YOURS never
   squeezed — each chip had shrunk by its own width, so under six long names YOU was a sliver and the others one width */
.top .order > .chip { flex: 1 1 0; max-width: max-content; }
.top .order > .chip.is-you { flex: none; }

/* ---- buttons: a printed block with a hard shadow; PRIMARY is the one gold action */
.btn { display: flex; justify-content: space-between; align-items: center; gap: var(--sp-3); padding: 10px 14px; background: var(--btn); color: var(--ink); border: var(--ink-w) solid var(--ink); border-radius: var(--radius-2); box-shadow: 2px 2px 0 var(--hard); cursor: pointer; user-select: none; transition: background var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-in), box-shadow var(--dur-fast) var(--ease-in); }
.btn > .t-name { white-space: nowrap; }
.btn .hint { text-align: right; font-family: var(--font-body); font-weight: 400; letter-spacing: 0; font-size: 12px; color: var(--muted); }
.btn:hover, .btn.is-hover { background: var(--panel); }
.btn:active, .btn.is-pressed { transform: translate(2px, 2px); box-shadow: 0 0 0 var(--hard); }
.btn.primary { background: var(--accent); color: var(--on-accent); border-color: var(--hard); }
.btn.primary .hint { color: inherit; opacity: .85; }
.btn.primary:hover, .btn.primary.is-hover { filter: brightness(1.06); }
/* an OFF button (w28, lite.md B11): shown, and it takes the click only to REFUSE it — never its action (`ui.js` attaches
   none); hover and press leave it as it is */
.btn.is-off { opacity: .45; box-shadow: none; cursor: not-allowed; }
.btn.is-off:hover, .btn.is-off.is-hover { background: var(--btn); }
.btn.primary.is-off:hover, .btn.primary.is-off.is-hover { background: var(--accent); filter: none; }
.btn.is-off:active, .btn.is-off.is-pressed { transform: none; box-shadow: none; }
.btn.small { padding: 6px 12px; }

/* ---- a coin (a price), a pill (a kind), a tag (a mark on the board), a tip (a hover's words) */
.coin { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--coin); color: var(--coin-ink); border: 1px solid var(--coin-edge); font-family: var(--font-num); font-weight: 700; font-size: 13px; }
.coin.big { width: 46px; height: 46px; font-size: 22px; }
.pill { display: inline-block; padding: 3px 7px; border-radius: 2px; background: var(--kind); color: #fff; }
.tag { display: inline-block; padding: 2px 6px; border-radius: var(--radius-1); background: var(--seat); color: #fff; }
/* THE NAME TAG (M12 W4, swap.md N3): a name's server-given tag, `#0042` — right after a human's name with a small gap,
   in the scale's smallest size and the muted ink, its figures tabular; in a room's seats and standing, the games playing
   now, the title's YOU and a seat's name tip at the table — never in the table's lines, the chat, a banner or a notice */
.nametag { margin-left: var(--sp-1); font-family: var(--font-num); font-size: var(--t-label); font-weight: 600; font-style: normal; letter-spacing: var(--track-num); text-transform: none; font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; }
.tip { display: inline-block; padding: 6px 10px; background: var(--plate); color: var(--plate-ink); border: 1px solid var(--plate-border); border-radius: var(--radius-2); box-shadow: var(--shadow); white-space: nowrap; }
.tip b { color: var(--accent); font-weight: 700; }

/* ---- a card: the face's order is fixed — kind pill, coin, art, name, text, the rare rule at the foot */
.card { position: relative; width: 148px; height: 160px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; overflow: hidden; background: var(--card); background-image: var(--stock); border: 1px solid var(--card-border); border-radius: var(--radius-2); box-shadow: var(--card-shadow); color: var(--ink); }   /* no card moves or fades in (the owner's, w14: "I don't want card animations") */
.card .pill { align-self: flex-start; }
.card .coin { position: absolute; right: 10px; top: 10px; }
.card .art { height: 42px; border-radius: var(--radius-2); background: var(--card-art); display: grid; place-items: center; color: var(--ink); }
.card .art svg { width: 30px; height: 30px; }
.card .name { line-height: 1.1; }
.card .text { font-size: 12.5px; color: var(--card-muted); flex: 1; min-height: 0; overflow: hidden; }   /* a long text is cut, never the commit bar under it */
/* a text its box cannot hold ends on its last WHOLE line with an ellipsis (w54): the screen counts the lines the box holds
   as drawn (`table.js` `_clamp`) and sets `--lines`; 0 leaves no line at all, never part of one */
.card .text.is-clamped { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: var(--lines); line-clamp: var(--lines); max-height: calc(var(--lines) * 1lh); }
.card .rare { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--rare); }
/* a card's states (w14, the Steam hand's): it never moves; one you can play NOW glows the playable mint and takes the
   finger; the card a pick began glows gold; one you cannot play while you could act is darkened */
.card.is-playable { box-shadow: 0 0 0 2px var(--playable), 0 0 14px 3px var(--playable-glow); cursor: pointer; }
.card.is-chosen { box-shadow: 0 0 0 2px var(--accent), 0 0 14px 3px var(--chosen-glow); cursor: pointer; }
.card.is-kept::after { content: "KEPT"; position: absolute; right: -22px; top: 12px; transform: rotate(45deg); background: var(--accent); color: var(--on-accent); font-family: var(--font-display); font-size: 9px; letter-spacing: .1em; padding: 2px 26px; }
.card.is-off { opacity: .5; filter: saturate(.4) brightness(.85); }
.card.is-back { background: var(--plate); color: var(--plate-ink); border-color: var(--plate-border); background-image: repeating-linear-gradient(45deg, transparent 0 6px, #ffffff0c 6px 8px); }
.card.is-back > * { visibility: hidden; }
.card.is-back::before { content: ""; position: absolute; inset: 10px; border: 1px solid var(--plate-muted); border-radius: var(--radius-1); opacity: .6; }
.card.closeup { width: 300px; height: 420px; padding: 22px 24px; gap: 12px; border-radius: calc(var(--radius-2) * 2); }
.card.closeup .pill { font-size: 13px; padding: 5px 12px; }
.card.closeup .name { font-size: 32px; }
.card.closeup .text { font-size: 19px; }
.card.closeup .coin { width: 46px; height: 46px; font-size: 22px; right: 20px; top: 20px; }
.card.closeup .art { height: 150px; border-radius: 12px; }
.card.closeup .art svg { width: 96px; height: 96px; }
.card.closeup .rare { height: 8px; }
.card.closeup .foot { display: flex; justify-content: space-between; color: var(--card-muted); font-size: 13px; letter-spacing: .08em; }
.card .commit { margin-top: auto; text-align: center; padding: 6px; border-radius: var(--radius-2); background: var(--accent); color: var(--on-accent); }
.card.is-off .commit { background: var(--btn); color: var(--muted); }
.hand-label { writing-mode: vertical-rl; transform: rotate(180deg); text-align: center; color: var(--muted); }
/* THE HAND (w54, the owner's): a face at rest is its PICTURE — the kind, the price, the art taking the room the text left,
   the name — and the pointer on it shows THE WHOLE CARD on the plate above it (IN PLAY's pop), its line saying why it
   waits or when its kind plays; a refused click says its why there in the plate's danger */
.hand > .slot { position: relative; }
.hand > .slot > .card .text { display: none; }
.hand > .slot > .card .art { flex: 1; min-height: 0; }
.hand > .slot > .card .art svg { width: 44px; height: 44px; }
.hand > .slot > .pop { display: none; position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); z-index: 4; flex-direction: column; gap: 6px; padding: 10px; background: var(--plate); color: var(--plate-ink); border-radius: var(--radius-2); box-shadow: var(--shadow-stage); pointer-events: none; }
.hand > .slot:hover > .pop { display: flex; }
.hand > .slot > .pop > .line { width: 148px; color: var(--plate-muted); }
.hand > .slot > .pop > .line:empty { display: none; }
.hand > .slot > .pop > .line.is-danger { color: var(--plate-danger); }
.hand > .slot > .pop > .card { height: auto; min-height: 160px; }   /* the whole card: its text never cut */

/* ---- your rail's parts: the YOU line, the stats, the readout, the actions, the table's settings, the foot */
.you-line { display: grid; grid-template-columns: 14px 1fr auto; gap: var(--sp-2); align-items: center; }
.you-line .name { color: var(--seat); }   /* the row carries the player's seat: `--seat` */
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; font-size: 13px; color: var(--muted); }
.stats b { color: var(--ink); font-family: var(--font-num); font-weight: 600; font-size: 15px; }
.readout { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 10px 0; display: flex; flex-direction: column; gap: var(--sp-1); }
.readout .row { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
.readout .row.big { color: var(--ink); }
.readout .row.big .n { color: var(--accent-ink); }
.readout .row.is-changed { animation: row-light var(--dur-slow) var(--ease-out) both; animation-delay: var(--since, 0ms); }   /* a number counted: the row lights once (B7) */
/* the readout is the ACTING seat's (B8): its head names the seat in its colour and the count; a card's row in its kind's
   colour; a rule over the total entering the multiply */
.readout .head { display: flex; align-items: center; gap: 6px; color: var(--seat); }
.readout .head .what { margin-left: auto; color: var(--muted); }
.readout .row.mod > span:first-child { color: var(--kind); font-weight: 700; }
.readout .rule { border-top: 1px dashed var(--line); margin: 2px 0; }
.actions { display: flex; flex-direction: column; gap: var(--sp-2); }
.table-info { margin-top: auto; border-top: 1px solid var(--line); padding-top: 10px; }
.table-share { margin-top: auto; }   /* the table's link for a friend to watch (w16), at the foot over the settings */
.rail.you > * { flex-shrink: 0; }   /* your rail's parts never squash: a count too long for it folds instead (w24, B8) */
.table-share + .table-info { margin-top: 0; }
.foot { display: flex; justify-content: space-between; color: var(--muted); }
.foot-links { display: flex; align-items: center; gap: var(--sp-4); white-space: nowrap; }   /* the title's foot: settings · privacy, the version at its right (w20) */
.foot-links a { color: var(--muted); text-decoration: none; }
.foot-links a:hover, .foot-links a:focus-visible { color: var(--ink); text-decoration: underline; }
/* SIGN IN on the title (w19; ONE SECTION since w42, the owner's D1 from renders): its rail, ONE ROW — Google's own
   button in its host at the left, filling what Valve's leaves, and VALVE'S OWN "Sign in through Steam" button (`.sits`:
   Valve's 114×43 image at its pixels, never resized, recoloured or framed — Valve's terms) at the right —, one line
   under both. The host's height kept while GIS draws it (none while hidden); its frame LIGHT in either palette, as
   Google's page is (a frame whose scheme differs from the page's gets an opaque white backdrop on slate). An OFF Steam
   button (seated) is faded and takes no click; the line says why. A standing CARRY offer — a guest's games that may join
   the account — a line with its button beside it. On the title the sections keep their height and WATCH's list gives
   way (the row made it tall). */
.signin-row { display: flex; align-items: center; gap: var(--sp-3); }
.gis { flex: 1; min-width: 0; min-height: 40px; color-scheme: light; }
.signin-row > .steam { line-height: 0; }
.signin-row > .steam:empty { display: none; }
.sits { display: block; margin: 0; padding: 0; border: 0; background: none; line-height: 0; border-radius: 3px; cursor: pointer; }
.sits > img { display: block; }
.sits.is-off { opacity: .45; cursor: not-allowed; }
/* SETTINGS (w20): the window's two columns over the title (YOU | THE LOOK and YOUR DATA; a narrow sheet holds THE LOOK
   alone over the room and the table), a SETTING's row — its label at the left, its toggle at the right —, YOUR DATA's
   links one under another, DELETE in danger */
.settings { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--sp-8); align-items: start; }
.settings > .column { gap: var(--sp-3); }
.settings > .column > .rail-title:not(:first-child) { margin-top: var(--sp-4); }
.setting { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); min-height: 32px; }
.setting > .label { color: var(--muted); }
.data-links { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.data-links a { color: var(--muted); text-decoration: none; }
.data-links a:hover, .data-links a:focus-visible { color: var(--ink); text-decoration: underline; }
.data-links a.is-danger { color: var(--danger); }
.title-col > * { flex-shrink: 0; }
.title-col > .games { flex-shrink: 1; }
.carry { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }

/* ---- the history (the world rail, under its own rail title): who · what; older lines dim; the wheel scrolls it */
.history { display: flex; flex-direction: column; gap: var(--sp-1); font-size: 13px; color: var(--muted); flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; -webkit-mask-image: linear-gradient(transparent, #000 1.6em); mask-image: linear-gradient(transparent, #000 1.6em); }   /* the newest line at the foot; the oldest fade out at the top; the wheel scrolls it (w23) */
.history::-webkit-scrollbar { display: none; }
.history > :first-child { margin-top: auto; }   /* few lines stand at the foot, as `flex-end` stood them, and many still scroll */
.history .row { display: flex; gap: var(--sp-2); }
.history .who { color: var(--seat); font-weight: 700; }
.history .row.is-dim { opacity: .6; }
.history .row.is-danger > span:last-child { color: var(--danger); }   /* land taken from you (B10): "took 3 of your cells" */
.history .row.is-accent > span:last-child { color: var(--accent-ink); }   /* an objective taken (B12): its worth, in gold */
.history .row.is-muted > span:last-child { color: var(--muted); }   /* another seat's points left unspent (B12) */

/* ---- the board (an inline SVG): the ink is the gap, a holding is a hatch, a frontier is a stroke */
.board { position: relative; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; min-height: 0; min-width: 0; }
.board > svg { width: calc(100% - var(--board-inset, 0px)); height: 100%; margin-left: var(--board-inset, 0px); display: block; overflow: visible; }   /* `--board-inset` (w44): the map right of the played chips where a hex centre would stand under one */
.hex { stroke: var(--hex-ink); stroke-width: var(--hex-ink-w); stroke-linejoin: round; }
.hex.t-plain { fill: var(--terrain-plain); } .hex.t-farm { fill: var(--terrain-farm); } .hex.t-hills { fill: var(--terrain-hills); }
.hex.t-river { fill: var(--terrain-river); } .hex.t-mountain { fill: var(--terrain-mountain); } .hex.t-ruins { fill: var(--terrain-ruins); }
.hex.t-shrine { fill: var(--terrain-shrine); } .hex.t-gate { fill: var(--terrain-gate); }
.own { stroke: none; }                       /* fill: url(#hatch-N) — the pattern per seat, built by the board */
.own.is-cut { opacity: .5; }
.frontier { fill: none; stroke: var(--seat); stroke-width: var(--frontier-w); stroke-linejoin: round; stroke-linecap: round; }
/* under a moment that took cells, only the changed edges move: the old fade out, the new fade in, as the hatch grows (B7) */
.frontier.is-old { animation: fade-out var(--dur-slow) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.frontier.is-fresh { animation: fade-in var(--dur-slow) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.mark { fill: var(--mark); stroke: none; color: var(--mark); }   /* a line mark's symbol strokes in currentColor */
.mark.line { fill: none; stroke: var(--mark); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.river { fill: none; stroke: var(--river-line); stroke-width: 1.3; stroke-linecap: round; }
/* THE BUILDINGS (w14, the owner's pick: B on G4 — `app/buildings.js`, drawn inline by the board): a bold body — ink
   with a cream edge on paper, cream with a black edge on slate — its details in the edge's colour, a flag or a band in
   the OWNER's colour (`--seat`), standing on a PLINTH painted as its terrain: the terrain's colour unhatched, an ink
   edge, a little of its mark */
.bldg .k { fill: var(--bldg); stroke: var(--bldg-edge); stroke-width: 2.4; paint-order: stroke; stroke-linejoin: round; }
.bldg .c { fill: var(--bldg-edge); }
.bldg .a { fill: var(--seat); stroke: var(--struct-ink); stroke-width: .8; stroke-linejoin: round; }
.bldg .pole, .bldg .kx, .bldg .k0 { fill: none; stroke: var(--bldg); stroke-linecap: round; }
.bldg .pole, .bldg .kx { stroke-width: 1.3; } .bldg .k0 { stroke-width: 1.2; }
.bldg .coin { fill: var(--coin); stroke: var(--coin-edge); stroke-width: .8; }
.bldg .plinth { stroke: var(--struct-ink); stroke-width: 1.1; }
.bldg .plinth.t-plain { fill: var(--terrain-plain); } .bldg .plinth.t-farm { fill: var(--terrain-farm); } .bldg .plinth.t-hills { fill: var(--terrain-hills); }
.bldg .plinth.t-river { fill: var(--terrain-river); } .bldg .plinth.t-mountain { fill: var(--terrain-mountain); } .bldg .plinth.t-ruins { fill: var(--terrain-ruins); }
.bldg .plinth.t-shrine { fill: var(--terrain-shrine); } .bldg .plinth.t-gate { fill: var(--terrain-gate); }
.bldg .gm { fill: none; stroke: var(--mark); stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.wall { fill: none; stroke: var(--mark); stroke-width: 1.2; opacity: .8; }
.plan-under { fill: none; stroke: var(--panel); stroke-width: 6; stroke-linejoin: round; }
.plan { fill: none; stroke: var(--plan); stroke-width: 3; stroke-linejoin: round; }

/* ---- a die, on the stage or small in a row: the outline is the roller's seat colour */
.die { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); }
.die .face { width: 120px; height: 120px; display: grid; place-items: center; }
.die .face svg { width: 100%; height: 100%; }
.die .face use { fill: var(--die); stroke: var(--seat); stroke-width: 5; stroke-linejoin: round; }   /* the symbol inherits both */
.die .face .n { fill: var(--die-ink); }
.die .label { color: var(--seat); }
.die .sub { color: var(--muted); font-size: 12px; }
.die.small .face { width: 44px; height: 44px; }
.die.is-rolling .face { animation: tumble var(--dur-die) var(--ease-out); }

/* ---- the stage (a war, a capital's fall) over a dimmed table, and a window inside it */
.stage { position: fixed; inset: 0; display: grid; place-items: center; transition: opacity var(--dur-base) var(--ease-in); }
.stage::before { content: ""; position: absolute; inset: 0; background: var(--dim); }
.stage .sheet { position: relative; width: 760px; padding: 26px 30px; display: flex; flex-direction: column; gap: 18px; border-radius: calc(var(--radius-2) * 1.5); box-shadow: var(--shadow-stage); animation: rise-in var(--dur-base) var(--ease-out); }
.stage .who { text-align: center; color: var(--muted); }
.dice { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--sp-5); }
.vs { color: var(--muted); }
/* ---- THE WAR'S STAGE IN BEATS (B9, the owner's A1): the head; two columns — the seat, its die and its BIG TOTAL, its rows
   (a card's in its kind's colour; a die change named over them while the dice wait); the foot, where each beat's words
   stand and THE BAND rises — the lead from this player's side, a tie, the verdict — solid, its words in `--on-accent`
   (light on paper, dark on slate: legible on both palettes' green, red and gold). Every beat is a `.beat` (motion.css) */
.war { display: flex; flex-direction: column; gap: 14px; }
.war-head { display: flex; align-items: baseline; gap: var(--sp-3); border-bottom: 2px solid var(--ink); padding-bottom: 8px; }
.war-head .t-muted { margin-left: auto; font-size: 13px; }
.war-cols { display: grid; grid-template-columns: 1fr 1fr; }
.war-col { display: flex; flex-direction: column; gap: 10px; padding: 0 var(--sp-4); min-width: 0; }
.war-col + .war-col { border-left: 1px solid var(--line); }
.war-col .side .name { color: var(--seat); }
.war-col .side .role { color: var(--muted); }
.war-col .count { display: flex; align-items: center; justify-content: space-between; min-height: 88px; }
.war-die { display: grid; }
.war-die > .face { grid-area: 1 / 1; width: 84px; height: 84px; }
.war-die .face.is-waiting use { fill: none; stroke-dasharray: 9 7; }
.war-col .total { display: flex; align-items: baseline; gap: 6px; }
.war-col .total .n { font-family: var(--font-num); font-size: var(--t-face); font-weight: 800; font-variant-numeric: tabular-nums; min-width: 1.2em; text-align: right; color: var(--ink); }
.war-col .total .prev { color: var(--muted); }
.war-col .rows { position: relative; display: flex; flex-direction: column; gap: 4px; border-top: 1px solid var(--line); padding-top: 8px; min-height: 56px; }
.war-col .row { display: flex; justify-content: space-between; gap: var(--sp-2); font-size: 13px; color: var(--ink); }
.war-col .row.mod .label { color: var(--kind); font-weight: 700; }
.war-col .row .whose { color: var(--muted); font-weight: 400; font-size: 12px; }
.war-col .called { position: absolute; inset: 8px 0 auto 0; padding: 8px 10px; border-left: 3px solid var(--kind, var(--accent)); background: var(--lit); border-radius: 0 var(--radius-2) var(--radius-2) 0; }
.war-col .called .row { font-size: 15px; }
.war-col .called .row .label { color: var(--kind); }
.war-foot { display: grid; min-height: 46px; align-items: center; }
.war-foot > * { grid-area: 1 / 1; }
.war-foot .say { text-align: center; color: var(--muted); }
.war-band { display: flex; flex-direction: column; justify-content: center; gap: 2px; min-height: 46px; padding: 6px 18px; border-radius: var(--radius-2); background: var(--muted); color: var(--on-accent); }
.war-band.is-good { background: var(--good); }
.war-band.is-danger { background: var(--danger); }
.war-band.is-accent { background: var(--accent); }
.war-band .line { display: flex; align-items: baseline; gap: var(--sp-3); }
.war-band .left { font-size: var(--t-title); letter-spacing: .04em; }
.war-band .spacer { flex: 1; }
.war-band .sub, .war-band .right, .war-band .mid { font-size: 13px; color: var(--on-accent); }
.war-band.is-compact { min-height: 22px; padding: 2px 12px; }
.war-band.is-compact .left { font-size: 13px; }
.war-result .right-rows { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; margin-top: 6px; font-size: 13px; color: var(--muted); }
.war-result .right-rows .rr.mod { color: var(--kind); font-weight: 700; }
.war-result .right-rows b { color: var(--ink); font-weight: 700; }
/* the COMPACT COUNT: both seats, their dice and totals on one line, the band under it — a war window's head, and over the
   board's top (`.warlive`, no click: the board takes none in a window) for every viewer not answering the window */
.warcount { display: flex; flex-direction: column; gap: 6px; }
.warcount .sides { display: flex; align-items: center; justify-content: center; gap: var(--sp-3); }
.warcount .side { display: flex; align-items: center; gap: 6px; }
.warcount .side .name { color: var(--seat); }
.warcount .vs { color: var(--muted); }
/* THE EXPAND'S COUNT (B9): a panel over the board's middle — the roller's die, POINTS counting in gold, the receipt's rows
   landing a beat apart (a card's in its kind's colour) */
.board > .moment.is-count { place-items: center; }
/* THE ROUND DARK POOL (w54, the Steam game's m66 at parity, the owner's pick there): an Expand roll's die and its count
   stand in one soft dark disc — a core of `--pool-core` (the screen's measure of the content: its half-diagonal and 10,
   130 at least) in `--pool`, then a 60-unit rim fading to nothing — growing from its centre as the moment opens and
   shrinking back into it as the moment goes (the motion table's row); one shadow over the board, under the die. A war's
   dice keep the war count's own panel */
.board > .moment.is-roll { isolation: isolate; }   /* the pool under the die and the panel: a positioned ::before paints over unpositioned content */
.board > .moment.is-roll::before { content: ""; position: absolute; z-index: -1; left: 50%; top: 50%; width: calc(2 * (var(--pool-core, 130px) + 60px)); aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle closest-side, var(--pool) var(--pool-core, 130px), transparent 100%); transform: translate(-50%, -50%); animation: pool-in var(--dur-base) var(--ease-out) backwards; transition: transform var(--dur-base) var(--ease-in); pointer-events: none; }
.board > .moment.is-roll.is-gone::before { transform: translate(-50%, -50%) scale(0); }
.count-panel { width: 300px; padding: 14px 18px; display: flex; flex-direction: column; gap: 8px; box-shadow: var(--shadow-stage); }
.count-panel .count { display: flex; align-items: center; justify-content: space-between; }
.count-panel .war-die > .face { width: 64px; height: 64px; }
.count-panel .total { display: flex; flex-direction: column; align-items: flex-end; }
.count-panel .total .n { font-family: var(--font-num); font-size: var(--t-face); font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1; color: var(--accent-ink); min-height: 1em; }
.count-panel .total .what { color: var(--muted); }
.count-panel .rows { display: flex; flex-direction: column; gap: 4px; border-top: 1px solid var(--line); padding-top: 8px; }
.count-panel .row { display: flex; justify-content: space-between; gap: var(--sp-2); font-size: 13px; color: var(--ink); }
.count-panel .row.mod .label { color: var(--kind); font-weight: 700; }
.count-panel .rule { border-top: 1px dashed var(--line); }
/* THE ROLL-OFF (w60, `lite.md` B24, the owner's "Full roll-off"; the Steam game's `rolloff` stage at its shape): a game's
   start plays its play-order roll over the board — the board under a DEEPER DIM of its own (`--dim-deep`: the owner's pick
   e of five renders on a real table, w61; on the stage's `--dim` the words were lost on paper), NO PANEL AND NO POOL, the
   words straight on it: `ROLL-OFF` in the plate's muted ink over a row of dice centred at 42% of the board's height; ONE DIE
   PER SEAT in rank order, the game's die with the seat's outline, each its seat's LAST face, tumbling from the start and
   landing one after another (`--k`: the motion table's row); under each its RANK AND NAME in the seat's colour, capped at
   its die's column with an ellipsis; from the last landing (a `.beat`) the verdict split as the fall's banner is — the
   name on a small line over `GOES FIRST` in the stage type, in gold (`YOU GO FIRST` one line). Where N full dice and their
   gaps would not fit the board's width the screen sets `is-small` and every die is the kit's `small` */
.board > .moment.is-rolloff { display: block; background: var(--dim-deep); }
.rolloff { position: absolute; left: var(--sp-4); right: var(--sp-4); top: 42%; transform: translateY(-50%); display: flex; flex-direction: column; align-items: center; gap: var(--sp-3); text-align: center; }
.rolloff > .cap { color: var(--plate-muted); }
.rolloff > .rolls { display: grid; grid-template-columns: repeat(var(--n, 2), minmax(0, 136px)); gap: var(--sp-4); max-width: 100%; }
.rolloff.is-small > .rolls { grid-template-columns: repeat(var(--n, 2), minmax(0, 120px)); gap: var(--sp-2); }
.rolloff .roller { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); min-width: 0; }
.rolloff .roller > .rank { max-width: 100%; color: var(--seat); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rolloff .face.is-tumbling { animation: tumble calc(var(--dur-die) * var(--k, 1)) var(--ease-out) both; animation-delay: calc(0ms - var(--since, 0ms)); }
.rolloff > .first { display: flex; flex-direction: column; align-items: center; max-width: 100%; color: var(--accent); }
.rolloff > .first .whose { font-family: var(--font-display); font-size: var(--t-name); font-weight: 800; letter-spacing: var(--track-label); line-height: 1.3; text-transform: uppercase; text-wrap: balance; overflow-wrap: anywhere; }
.rolloff > .first .what { text-wrap: balance; }
.board > .warlive { position: absolute; top: 8px; left: 0; right: 0; margin-inline: auto; width: 360px; padding: 8px 10px; background: var(--panel); border: 1px solid var(--panel-border); border-radius: var(--radius-2); box-shadow: var(--shadow); pointer-events: none; z-index: 1; animation: rise-in var(--dur-base) var(--ease-out); }
.window { border-top: 1px solid var(--line); padding-top: var(--sp-4); display: flex; flex-direction: column; gap: var(--sp-3); }
.window .head { display: flex; justify-content: space-between; align-items: baseline; }
.window .head .title { color: var(--accent-ink); }
.window .head .clock { color: var(--danger); }
.window .head .clock .label { color: var(--muted); margin-right: var(--sp-2); }
.window .cards { display: flex; gap: var(--sp-3); justify-content: center; }
.window .cards .card { height: 234px; }   /* the COMMIT bar under FIVE lines of text — a full hand of five squeezes each face to 130 px, where RAID takes five: a window's choice is read WHOLE under its clock (w54, the owner's; at 168 a face kept one line) */

/* ---- a chat bubble beside a seat */
.bubble { display: inline-block; max-width: 220px; padding: 6px 10px; background: var(--panel); border: var(--ink-w) solid var(--ink); border-radius: var(--radius-3); box-shadow: 2px 2px 0 var(--hard); position: relative; }
.bubble::after { content: ""; position: absolute; left: -7px; top: 10px; border: 6px solid transparent; border-right-color: var(--ink); border-left: 0; }

/* ---- the theme toggle: paper | slate, a two-state stamp */
.toggle { display: inline-flex; border: var(--ink-w) solid var(--ink); border-radius: var(--radius-pill); overflow: hidden; }
.toggle span { padding: 4px 10px; color: var(--muted); cursor: pointer; }
.toggle span.is-on { background: var(--ink); color: var(--bg); }

/* ==== M11's SCREENS (w8): the title, the room, the game over. A screen is one grid of kit parts and adds no style of
   its own; every part below was rendered on the kit sheet before a screen used it. ==== */

/* ---- a screen's frame. The title: its column on the left, the board beside it. The room: the top bar, then the
   table's column on the left, the board over the chat on the right. The game over: the board under its verdict on the
   left, the standings on the right. */
.screen { height: 100%; min-width: 1280px; min-height: 720px; display: grid; grid-template-rows: minmax(0, 1fr); }
.screen-title { grid-template-columns: var(--col-w) minmax(0, 1fr); }
.screen-title > .board { padding: var(--sp-6) var(--sp-8); }
.screen-room { grid-template-columns: var(--col-w) minmax(0, 1fr); grid-template-rows: var(--top-h) minmax(0, 1fr) auto; column-gap: var(--sp-4); row-gap: var(--sp-3); padding: 0 var(--sp-4) var(--sp-4); }
.screen-room > .top { grid-column: 1 / -1; padding: 0; }
.screen-room > .column { grid-column: 1; grid-row: 2 / span 2; }
.screen-room > .board { grid-column: 2; grid-row: 2; }
.screen-room > .chat { grid-column: 2; grid-row: 3; height: var(--chat-h); }
.screen-over { grid-template-columns: minmax(0, 1fr) var(--over-w); grid-template-rows: auto minmax(0, 1fr) auto; column-gap: var(--sp-6); row-gap: var(--sp-3); padding: var(--sp-6) var(--sp-6) var(--sp-5); }
.screen-over > .standings { grid-column: 2; grid-row: 1 / span 3; }
.column { display: flex; flex-direction: column; gap: var(--sp-3); min-height: 0; overflow: hidden; }
.title-col { padding: var(--sp-8) var(--sp-6) var(--sp-5); background: var(--panel); background-image: var(--stock); border-right: var(--ink-w) solid var(--panel-border); gap: var(--sp-4); }
.title-col .rule { border-top: 1px solid var(--line); }
/* THE GAMES PLAYING NOW (w16): the title column's remaining height, its rows scrolling inside it; a row is the people
   over the round, the size and the watchers, WATCH beside both */
.title-col .games { flex: 1 1 auto; min-height: 0; }
.title-col .games > .list { min-height: 0; overflow-y: auto; }
.game-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: var(--sp-3); align-items: center; padding: 6px var(--sp-2); border-bottom: 1px solid var(--line); }
/* the people: each name with its tag (W4) wraps onto a second line, never past it (its end cut with an ellipsis), so
   "+ N AI" stays in view for a table of two people whose names are long; a person, and "+ N AI", never breaks inside */
.game-row .who { min-width: 0; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.game-row .who > span { white-space: nowrap; }
.game-row .about { grid-column: 1; font-size: 13px; }
.game-row > .btn { grid-column: 2; grid-row: 1 / span 2; }
.at-foot { margin-top: auto; }                 /* a column's last group, pushed to its foot */
.at-end { justify-self: end; }                  /* the top bar's right group */
.list { display: flex; flex-direction: column; }  /* rows that rule their own lines: seats, steppers, standings */
.verdict { display: flex; flex-direction: column; gap: 6px; }
.caption { position: absolute; right: var(--sp-4); bottom: var(--sp-3); color: var(--muted); font-size: 13px; }
/* THE TITLE'S REEL (w57, `research/web/lite.md` B23, the owner's B — the Steam title's diorama): the board edge to edge,
   drawn into a REEL its redraws never replace (`drawBoard` puts its SVG there), zoomed (`--zoom`) and swept across and
   back (`--sweep`, the screen's measure: half of what the zoomed board overhangs the reel; the motion table's `the title's
   sweep`), under a vignette of the ground, the caption over it. LESS: the sweep stops, the board centred */
.board.is-reel { overflow: hidden; padding: 0; }
.reel { position: absolute; inset: 0; scale: var(--zoom, 1); animation: sweep 45s var(--ease-both) infinite alternate; }
.reel > svg { width: 100%; height: 100%; display: block; overflow: visible; }
.board.is-reel::after { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 75% 70% at 50% 50%, transparent 55%, var(--bg) 100%); }
.board.is-reel > .caption { z-index: 1; }

/* ---- the wordmark: the game's name, in the display face at the scale's largest size */
.wordmark { font-family: var(--font-display); font-size: var(--t-face); font-weight: 800; line-height: 1; letter-spacing: .01em; color: var(--accent-ink); }
.wordmark.small { font-size: var(--t-title); }

/* ---- a row of buttons; a primary in it takes the room left */
.btns { display: flex; align-items: center; gap: var(--sp-3); }
.btns > .btn.primary, .btns > .spacer { flex: 1; }

/* ---- a field: a label over a box; the box is the printed rule around a well of paper. Its states: focused (the gold
   rule), wrong (the danger rule and a line under it), read-only (the panel's stock: a link to copy). A button may
   sit inside the box's right end. */
.field { display: flex; flex-direction: column; gap: var(--sp-1); min-width: 0; }
.field .label { color: var(--muted); }
.field .box { display: flex; align-items: center; gap: var(--sp-2); height: 40px; padding: 0 4px 0 var(--sp-3); background: var(--field); border: var(--ink-w) solid var(--panel-border); border-radius: var(--radius-2); box-shadow: var(--field-inset); transition: border-color var(--dur-fast) var(--ease-out); }
.field .box .value { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.field .box .value.is-empty { color: var(--muted); }
.field .box .caret { width: 1.5px; height: 18px; background: var(--ink); margin-left: -6px; }
.field.is-focus .box { border-color: var(--accent); box-shadow: var(--field-inset), 0 0 0 1px var(--accent); }
.field.is-wrong .box { border-color: var(--danger); }
.field .why { color: var(--danger); font-size: 13px; }
.field.is-read .box { background: var(--panel); box-shadow: none; }
.field .box .nametag { flex: none; margin: 0 var(--sp-2) 0 0; }   /* the YOU field's own tag (W4), at the box's right end */
.field .box .btn.small { padding: 4px 10px; box-shadow: 1px 1px 0 var(--hard); }

/* ---- a stepper (a setting the opener moves): the label, then ‹ value › */
.stepper { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: var(--sp-3); min-height: 30px; border-bottom: 1px solid var(--line); }
.stepper .btn.small { padding: 1px 10px; }
.stepper .label { color: var(--muted); }
.stepper .ctl { display: inline-flex; align-items: center; gap: var(--sp-2); }
.stepper .arrow { width: 24px; height: 24px; display: grid; place-items: center; background: var(--btn); color: var(--ink); border: var(--ink-w) solid var(--ink); border-radius: var(--radius-1); box-shadow: 2px 2px 0 var(--hard); font-family: var(--font-display); font-weight: 800; line-height: 1; cursor: pointer; }
.stepper .arrow.is-off { opacity: .35; box-shadow: none; }
.stepper .value { min-width: 150px; text-align: center; }
.stepper .value .t-muted { font-family: var(--font-body); font-weight: 400; letter-spacing: 0; }

/* ---- a seat in the room: swatch · the colour's name · who holds it · READY · its control (SIT, STAND, or the
   opener's open | AI) */
.room-seat { display: grid; grid-template-columns: 14px 54px 1fr auto auto; column-gap: var(--sp-3); align-items: center; min-height: 40px; padding: 0 var(--sp-2); border-bottom: 1px solid var(--line); border-radius: var(--radius-1); }
.room-seat .colour { color: var(--seat); }
.room-seat .who.is-open { color: var(--muted); font-family: var(--font-body); font-weight: 400; letter-spacing: 0; font-style: italic; }
.room-seat .who .t-muted { font-family: var(--font-body); font-weight: 400; letter-spacing: 0; font-size: 13px; white-space: nowrap; }   /* "· you" stays with the name's tag (W4) */
.room-seat.is-you { background: var(--lit); }
.room-seat .btn.small { padding: 3px 12px; }
.tag.is-ready { background: var(--good); }
.tag.is-host { background: var(--accent); color: var(--on-accent); }

/* ---- the chat: its lines (the newest at the foot), the free line with SEND, the quick lines */
.chat { display: flex; flex-direction: column; gap: var(--sp-2); min-height: 0; }
.chat .lines { flex: 1; min-height: 0; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; -webkit-mask-image: linear-gradient(transparent, #000 1.6em); mask-image: linear-gradient(transparent, #000 1.6em); }   /* the older lines fade out at the top */
.chat .lines .who { color: var(--seat); font-weight: 700; }
.chat .lines .is-note { color: var(--muted); font-style: italic; }
.chat .send { display: grid; grid-template-columns: 1fr auto; gap: var(--sp-2); }
.chat .quick { display: flex; flex-wrap: wrap; gap: 6px; }
.chat .quick .btn.small { padding: 3px 10px; }

/* ---- the game over: the verdict in GOLD (never the winner's colour), a RESULT row per seat, the score's bar */
.headline { display: flex; align-items: center; gap: var(--sp-3); color: var(--accent-ink); }
.headline .swatch { width: 22px; height: 22px; }
.result { display: grid; grid-template-columns: 30px 1fr auto; grid-template-rows: auto auto auto; column-gap: var(--sp-3); row-gap: 6px; align-items: center; padding: var(--sp-3); border-radius: var(--radius-2); }
.result .rank { grid-row: 1 / span 3; color: var(--muted); }
.result .who { display: flex; align-items: baseline; gap: var(--sp-2); }
.result .who .name { color: var(--seat); }
.result .score { grid-column: 3; grid-row: 1 / span 3; font-family: var(--font-num); font-size: var(--t-stage); font-weight: 800; font-variant-numeric: tabular-nums; }
.result .words { color: var(--muted); font-size: 13px; }
.result .words .cut { color: var(--danger); }
.result .words .obj { color: var(--accent-ink); }
.result.is-won { background: var(--lit); }
.result.is-out .name { text-decoration: line-through; }
.scorebar { display: flex; height: 10px; background: var(--line); border-radius: 2px; overflow: hidden; }
.scorebar i { display: block; height: 100%; }
.scorebar .joined { background: var(--seat); }
.scorebar .cut { background: repeating-linear-gradient(45deg, var(--seat) 0 2.2px, transparent 2.2px 6px); }
.scorebar .obj { background: var(--accent); }

/* ---- a tag ON THE BOARD (an SVG group over a capital: the room names every seat's, the game over YOURS) */
.btag { pointer-events: none; }   /* a word on the board takes no click: the cell under it keeps its pick (w55) */
.btag rect { fill: var(--seat); stroke: var(--hard); stroke-width: .8; }
.btag text { fill: #fff; font-family: var(--font-display); font-size: 9px; font-weight: 800; letter-spacing: .1em; }

/* ---- a narrow sheet on the stage (a password asked; one question, one answer) */
.stage .sheet.narrow { width: 460px; }
/* a narrow sheet whose answer is THREE buttons (THE PASS SHEET: CLOSE · GET IT ON STEAM · SIGN IN WITH STEAM, 565 px of
   buttons and gaps): wide enough to hold its row, never a button past its edge (w76) */
.stage .sheet.narrow.is-wide { width: 640px; }
.stage.is-back .sheet { animation: none; }   /* a sheet back from under THE PAUSE stands where it stood: no second rise (w54) */
.stage .sheet .title { color: var(--accent-ink); }

/* ---- LIVE CONTROLS (M11's client, w10): a real <button> is the kit's button and a real <input> is a field's value;
   the browser's own look is cleared and the kit's drawn; keyboard focus shows as the field's gold rule or a gold ring.
   A NOTE is a line under a group of buttons (a refusal in danger). */
button.btn { margin: 0; font: inherit; text-align: left; appearance: none; }
.btn:focus-visible, .sits:focus-visible, .toggle span:focus-visible, .stepper .arrow:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.field .box input.value { height: 100%; margin: 0; padding: 0; border: 0; background: transparent; outline: none; }
.field .box input.value::placeholder { color: var(--muted); opacity: 1; }
.field:focus-within .box { border-color: var(--accent); box-shadow: var(--field-inset), 0 0 0 1px var(--accent); }
.field.is-wrong:focus-within .box { border-color: var(--danger); }
.note { color: var(--muted); }
.note.is-wrong { color: var(--danger); }

/* ---- THE TABLE'S LIVE PARTS (M11's client, w11). A PICK is a cell a click takes now — drawn only where the server
   listed a command for it: at rest a thin dashed rule inside the hex (plan orange to take or build, ink to wall), under
   the pointer the outline whole (the motion table's "a hex under the pointer": no fill change). An OFFER is a card with
   its buttons under it (the shop: BUY and HOLD on the row, SELL on the hand). */
.pick { fill: transparent; stroke: var(--plan); stroke-width: 2; stroke-dasharray: 4 3; stroke-linejoin: round; cursor: pointer; transition: stroke-width var(--dur-fast) var(--ease-out); }
.pick.is-wall { stroke: var(--ink); }
.pick.is-war { stroke: transparent; }   /* WAR's pick: the land you may declare on (w14) — its ring and sword say it at rest (w55, B22) */
.pick.is-war:hover, .pick.is-war.is-hover { stroke: var(--danger); }   /* … the whole outline in danger under the pointer */
.pick.is-right { stroke: var(--accent); stroke-width: 2.8; stroke-dasharray: none; }   /* a won war's right (w31) */
.pick:hover, .pick.is-hover { stroke-width: 3.6; stroke-dasharray: none; }
.offer { display: flex; flex-direction: column; gap: var(--sp-2); }
/* THE MOMENTS (w11): a cell taken grows in from the edge it was taken across (the motion table's "a cell taken"; its
   transform-origin is the board's, set per cell); a roll's die stands over the board, never taking a click; the war's
   word and its lines centred on the stage. */
.own.is-new { transform-box: fill-box; animation: take var(--dur-slow) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.board > .moment { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; transition: opacity var(--dur-base) var(--ease-in); }
.board > .moment.is-gone, .stage.is-gone { opacity: 0; pointer-events: none; }   /* a moment's die and a stage fade as they go (w14) */
/* A CAPITAL'S FALL (B7, the owner's C): the banner over the board's upper third for its moment, the old keep dimmed, the ring.
   A CARD THAT ACTS (B8): the same banner in a layer of its own laid over the board ABOVE a stage, the card's name in its
   kind's colour, whose and what it does under it (a card's text wraps); never taking a click.
   THE FALL'S BANNER FITS (w51, B20, the owner's C): the BOARD's banners (the fall, THE LAST ROUND) stand at `--banner-top`,
   under IN PLAY's row where they would meet, wrapping inside the rails (16 px each side); the fall's head is SPLIT — the
   seat's name on a small line of its own (`.whose`: the name size at the label's tracking, balanced, breaking anywhere: 24
   W's are one word) over the event in the stage type (`.what`) — so the banner keeps one shape whatever the name. The
   card banners keep 16% (moved down they would stand over the Expand's count, which does not end one) */
.board > .banner, .card-banners > .banner { position: absolute; top: 16%; left: 0; right: 0; margin-inline: auto; width: max-content; max-width: 100%; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 28px; background: var(--plate); color: var(--plate-ink); border-radius: var(--radius-2); box-shadow: var(--shadow-stage); white-space: nowrap; pointer-events: none; animation: rise-in var(--dur-base) var(--ease-out); transition: opacity var(--dur-base) var(--ease-in); }
.board > .banner { top: var(--banner-top); white-space: normal; text-align: center; max-width: calc(100% - 2 * var(--sp-4)); }
.board > .banner .t-body { overflow-wrap: anywhere; }   /* the taker's name breaks as the loser's does */
.banner .head { color: var(--seat); }
.banner .head.is-split { display: flex; flex-direction: column; align-items: center; }
.banner .whose { font-family: var(--font-display); font-size: var(--t-name); font-weight: 800; letter-spacing: var(--track-label); line-height: 1.3; text-transform: uppercase; text-wrap: balance; overflow-wrap: anywhere; }
.banner .what { text-wrap: balance; }
.banner .by { color: var(--seat); font-weight: 700; }
.board > .banner.is-gone, .card-banners > .banner.is-gone { opacity: 0; }
.card-banners { position: fixed; z-index: 5; pointer-events: none; }
.card-banners > .banner { white-space: normal; max-width: min(560px, 92%); text-align: center; }
/* THE CARD BANNERS CLEAR IN PLAY (w54, the owner's A2): the layer's banners start right of IN PLAY's faces (`--clear-left`,
   the screen's measure; 0 with none), centred in what is left; WHILE YOU WERE AWAY stepped down under a board banner
   (B2) is centred on the whole board again (its own `--clear-left: 0px`) */
.card-banners > .banner { left: var(--clear-left, 0px); max-width: min(560px, 92%, calc(100% - var(--clear-left, 0px) - 2 * var(--sp-2))); }
.banner.is-card .name { color: var(--kind); }
.flash { fill: var(--kind); opacity: 0; pointer-events: none; animation: cell-flash calc(var(--dur-slow) * 2.4) var(--ease-out) both; animation-delay: var(--since, 0ms); }   /* its cell, for its first second */
/* THE AI'S SPEND, SEEN (B10, the owner's W): the cell an AI PICKED — its outline heavy in the seat's colour, its tag NEXT
   over it — until its capture lands; another seat's TAKE flashing in its colour (700 ms: the slow duration × 5/3, so LESS
   stops it); the land YOU LOST — your old border dashed in your colour inside the taker's frontier, LOST under the newest */
/* ---- THE REFUSED CLICK (w28, lite.md B11, the owner's: a red flash and a line saying why; no sound): the flash is a
   STATE the screen holds 420 ms — a static danger fill, never an animation, so LESS keeps it — on a cell, a button or a
   card (a ring: no card moves) */
.refused { fill: var(--danger); fill-opacity: .45; stroke: var(--danger); stroke-width: 2.5; stroke-linejoin: round; pointer-events: none; }
.btn.is-refused, .btn.is-off.is-refused { opacity: 1; border-color: var(--danger); box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--danger) 45%, transparent); }
.card.is-refused, .card.is-off.is-refused { opacity: 1; filter: none; box-shadow: 0 0 0 3px var(--danger), var(--card-shadow); }
/* THE CELL'S BOX under the pointer (C1: a price and its receipt, or why not) and THE REFUSAL LINE (its danger line alone,
   under a button, above a card): the plate's look, taking no click, rising over --dur-fast */
.cellbox { position: absolute; z-index: 6; min-width: 190px; max-width: 300px; padding: 8px 12px; background: var(--plate); color: var(--plate-ink); border: 1px solid var(--plate-border); border-radius: var(--radius-2); box-shadow: var(--shadow); pointer-events: none; animation: fade-in var(--dur-fast) var(--ease-out) both; }
.cellbox.is-line { position: fixed; z-index: 40; min-width: 0; max-width: 340px; padding: 6px 10px; }
.cellbox .head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.cellbox .head .price { color: var(--accent); white-space: nowrap; }
.cellbox .rows { display: grid; grid-template-columns: 1fr auto; column-gap: 14px; margin-top: 6px; font-size: 12px; color: var(--plate-muted); }
.cellbox .rows .mod { color: var(--kind); font-weight: 700; }
.cellbox .rows .v { text-align: right; font-variant-numeric: tabular-nums; }
.cellbox .foot { margin-top: 6px; padding-top: 6px; border-top: 1px solid color-mix(in srgb, var(--plate-ink) 18%, transparent); font-size: 12px; color: var(--plate-muted); }
.cellbox .why { margin-top: 4px; font-size: 13px; color: var(--plate-ink); }
.cellbox .is-danger, .cellbox .why.is-danger { color: var(--plate-danger); }
.cellbox.is-line .why { margin-top: 0; }
.aipick { fill: none; stroke: var(--seat); stroke-width: calc(var(--frontier-w) * 2); stroke-linejoin: round; pointer-events: none; }
.take-flash { fill: var(--seat); opacity: 0; pointer-events: none; animation: take-flash calc(var(--dur-slow) * 5 / 3) var(--ease-out) both; animation-delay: var(--since, 0ms); }
.lost { fill: none; stroke: var(--seat); stroke-width: var(--frontier-w); stroke-dasharray: 3.2 2.6; stroke-linejoin: round; pointer-events: none; }
/* THE LOSER LOOK — A WON WAR'S SPEND (w31, the owner's pick A): the loser's cells the right may take, ringed in his colour, a
   sword each; WAR'S PICK (w55, B22, the owner's A): every cell WAR may be declared on, ringed in its owner's colour, a sword each */
.loser { fill: none; stroke: var(--seat); stroke-width: var(--frontier-w); stroke-linejoin: round; pointer-events: none; }
.sword { pointer-events: none; }
.sword circle { fill: var(--panel); stroke: var(--accent); stroke-width: 2; }
.sword use { color: var(--ink); }
.beside { fill: none; stroke: var(--panel); stroke-width: 2.2; stroke-linejoin: round; pointer-events: none; }   /* WAR's pick: your cell beside a target (w55, B22) */
.bldg.is-fallen { opacity: .38; filter: grayscale(.6); }
.risen { fill: none; stroke: var(--seat); stroke-width: 4; stroke-linejoin: round; pointer-events: none; animation: ring-pulse var(--dur-slow) var(--ease-out) infinite alternate both; animation-delay: calc(var(--since, 0ms) + var(--at, 0ms)); }   /* in the fall's SECOND beat (B12: `--at`), pulsing for its length */
/* A FALL'S TWO BEATS (B12, w32): both `.beat`s stacked in one place, the fall's going at `--until` as the second lands at
   `--at` — where the capital moves (a structure razed there), or the seat OUT (yours in the plate's danger) */
.board > .banner.is-two { display: grid; }   /* both beats in one cell: the box the larger's, so the second lands in place */
.banner.is-two > .beat { grid-area: 1 / 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.banner .beat.is-out.is-mine .head { color: var(--plate-danger); }
.banner.is-last .head { color: var(--accent); }   /* THE LAST ROUND (B12): its banner in gold while the Shop waits */
/* AN OBJECTIVE TAKEN (B12): its gold tag rises over the cell and goes after a second — the rise travel, the going a
   STATE at its time (LESS: held still, then gone) */
.btag.is-objective rect { fill: var(--accent); }
.btag.is-objective text { fill: var(--on-accent); }
.btag.is-objective { animation: tag-gone var(--dur-base) var(--ease-in) both; animation-delay: calc(1000ms - var(--dur-base) + var(--since, 0ms)); }
.btag.is-objective > * { animation: tag-rise var(--dur-base) var(--ease-out) both; animation-delay: var(--since, 0ms); }
/* THE END OF A SPEND (B12, the Steam game's m63): END TURN LIT — a gold ring breathing; LESS: the ring held still */
.btn.is-lit { outline: 3px solid var(--accent); outline-offset: 2px; animation: lit-breathe var(--dur-slow) var(--ease-both) infinite alternate; }
/* GOLD SAID (w43, B14): a FLOAT under a cell — a seat's income `+5` in gold, its upkeep `−2` in danger — a board tag on
   card stock rising 8px and gone at 1.2 s, each at its own age (LESS: held still, then gone) */
.btag.is-float rect { fill: var(--panel); stroke: var(--panel-border); }
.btag.is-float text { font-family: var(--font-num); font-size: 10px; letter-spacing: 0; }
.btag.is-float.is-gold text { fill: var(--accent-ink); }
.btag.is-float.is-danger text { fill: var(--danger); }
.btag.is-float { animation: tag-gone var(--dur-base) var(--ease-in) both; animation-delay: calc(1200ms - var(--dur-base) + var(--since, 0ms)); }
.btag.is-float > * { animation: tag-rise var(--dur-base) var(--ease-out) both; animation-delay: var(--since, 0ms); }
/* WHILE YOU WERE AWAY (w43, B14): ONE banner of its own in the card banners' layer — the plate's look, the head muted, a
   line each under it (yours lost in the plate's danger, the ask in gold); 8 s or a click; never cut by a card banner */
.card-banners > .banner.is-away { gap: 2px; }
.banner.is-away .head { color: var(--plate-muted); letter-spacing: .12em; }
.banner.is-away .line { color: var(--plate-ink); }
.banner.is-away .line.is-danger { color: var(--plate-danger); }
.banner.is-away .line.is-muted { color: var(--plate-muted); }
.banner.is-away .line.is-accent { color: var(--accent); }
/* THE CARD HISTORY PILE (w43, B14; provisional until multi's m77 FYI): over the board's top-right corner, IN PLAY's mirror —
   a label line with its +N chip, and a row of MINI FACES newest nearest the corner: the kind's band, the glyph, the owner's
   mark; the newest lit; a hover's whole card with who and when opening LEFTWARD; the chip's pop THE TRAY */
/* THE PLAYED CHIPS (w44, B15; the Steam game's m77 at parity): the cards played at the table as a COLUMN at the board's
   left under IN PLAY, the newest at the top — each chip the card's glyph in a dark disc ringed in its seat's colour, the
   newest one step larger (`is-new`), the oldest shown faded (`is-old`), a dark track down the axis, PLAYED above; a
   hover's whole card opens to the RIGHT (`--pop-up` raises a low chip's pop inside the board); the newest lands lit 2 s
   (`.disc.is-lit`, its kind); the chip under the pointer glows gold. The screen places the column (`top`) and the track;
   `is-hidden` while a WAR TABLE stands — a war moment playing, or a war's window open with its dice on the table, the
   Steam game's `war_up` (B17) —
   and `is-under` under every other stage: in sight under the dim (UNDER THE DIM, w47, below). The mini faces of w43 are
   RETIRED. */
.board > .pile { position: absolute; left: var(--sp-2); top: 0; z-index: 1; width: 48px; padding-top: 22px; display: flex; flex-direction: column; align-items: center; pointer-events: none; }   /* 48: the newest chip; the label above in its 22 */
.pile.is-hidden { display: none; }
.pile .label { position: absolute; top: 0; left: 50%; transform: translateX(-50%); height: 16px; line-height: 16px; color: var(--muted); white-space: nowrap; }   /* centred on the axis, overhanging the column: never widening it */
.pile .track { position: absolute; left: 50%; width: 4px; margin-left: -2px; border-radius: 2px; background: color-mix(in srgb, var(--disc) 60%, transparent); }
.pile .slot { position: relative; pointer-events: auto; display: grid; place-items: center; padding: 3px 0; }   /* half the gap above and below: the pointer runs down the column */
.pile .disc { position: relative; box-sizing: border-box; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--disc); border: 2px solid var(--seat); color: var(--disc-ink); box-shadow: 0 1px 0 var(--plate-border); }
.pile .disc svg { width: 22px; height: 22px; }
.pile .slot.is-new .disc { width: 48px; height: 48px; }
.pile .slot.is-new .disc svg { width: 26px; height: 26px; }
.pile .slot.is-old .disc { opacity: .5; }
.pile .disc.is-lit { box-shadow: 0 0 0 2px var(--kind), 0 0 10px 2px color-mix(in srgb, var(--kind) 60%, transparent); }
.pile .slot:hover .disc { opacity: 1; box-shadow: 0 0 0 2px var(--accent), 0 0 12px 3px color-mix(in srgb, var(--accent) 55%, transparent); }
.pile .pop { display: none; position: absolute; top: var(--pop-up, 0px); left: calc(100% + 8px); z-index: 4; flex-direction: column; gap: 6px; padding: 10px; background: var(--plate); color: var(--plate-ink); border-radius: var(--radius-2); box-shadow: var(--shadow-stage); pointer-events: none; }
.pile .slot:hover > .pop { display: flex; }
.pile .pop .who { color: var(--seat); max-width: 260px; white-space: nowrap; }
.pile .pop .card { height: auto; min-height: 160px; }
/* IN PLAY (B8, the owner's m58 pick): every card whose effect stands, as a SHORT FACE over the board's top-left — the
   card's top (its kind's band, the glyph, the name, the coin with its price) and its owner's seat mark; no text. The
   newest is LIT (a glow, no motion: no card moves); a hover shows the whole card over the board; past what fits, +N. The
   row takes no click but on its faces. */
.board > .inplay { position: absolute; top: var(--sp-2); left: var(--sp-2); z-index: 2; display: flex; flex-direction: column; gap: var(--sp-1); pointer-events: none; }   /* over the played chips' column under it (w44): its pops and its tray win; lowered under a stage and banded under the war's band (B17, below) */
.inplay .label { display: flex; align-items: center; gap: 8px; height: var(--inplay-label-h); color: var(--muted); }   /* a HEIGHT (w51): the board's banners stand under this row by its numbers */
.inplay .faces { display: flex; gap: 8px; align-items: flex-start; }
.inplay .slot { position: relative; pointer-events: auto; }
.inplay .more .chip { opacity: 1; padding: 1px var(--sp-2); color: var(--ink); background: var(--panel); cursor: default; }
.inplay .more .pop .row { display: flex; align-items: center; gap: 8px; }
.card.is-short { width: 116px; height: var(--short-h); padding: 6px 8px 6px 8px; flex-direction: row; align-items: center; gap: 6px; border-top: 4px solid var(--kind); }
.card.is-short .art { width: 30px; height: 30px; flex: none; }
.card.is-short .art svg { width: 22px; height: 22px; }
.card.is-short .name { font-size: 13px; line-height: 1.1; min-width: 0; }
.card.is-short .coin { width: 16px; height: 16px; font-size: 9px; left: 2px; top: 2px; right: auto; }   /* a badge on the glyph's corner: the name keeps the width */
.card.is-short .mark { position: absolute; right: 5px; bottom: 5px; width: 11px; height: 12px; background: var(--seat); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.card.is-lit { box-shadow: 0 0 0 2px var(--kind), 0 0 14px 3px color-mix(in srgb, var(--kind) 60%, transparent); }   /* a face landed IN PLAY; since w43 (B14) the shop's row too: a redraw's and the deal's glow */
.inplay .pop { display: none; position: absolute; top: calc(100% + 6px); left: 0; z-index: 4; flex-direction: column; gap: 6px; padding: 10px; background: var(--plate); color: var(--plate-ink); border-radius: var(--radius-2); box-shadow: var(--shadow-stage); pointer-events: none; }
.inplay .slot:hover > .pop { display: flex; }
.inplay .pop .who { color: var(--seat); max-width: 240px; }
.inplay .pop .card { height: auto; min-height: 160px; }   /* the whole card: its text never cut */
.stage .sheet > .word { text-align: center; }
/* THE SEEK BAR (a replay, w11): the record's length as a track, the place reached in gold; a click seeks there. */
.seek { position: relative; height: 12px; background: var(--line); border: 1px solid var(--panel-border); border-radius: var(--radius-1); cursor: pointer; overflow: hidden; }
.seek i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); transition: width var(--dur-base) var(--ease-out); }
.rail .order { flex-wrap: wrap; justify-content: flex-start; }
/* THE TABLE'S CHAT (w12): the CHOOSER over the board's lower-left corner (the room's chat parts, the board seen past it),
   and a line's BUBBLE level with its seat's row, just right of the world rail, while it stands. */
/* UNDER THE DIM (w47, B17): the stage has NO z-index, so a board part with one must DECLARE its state under a stage — the
   part is LOWERED, never the stage raised (the chooser, the bubbles, the handle and a line's tip stand over the dim on
   purpose; a fall's banner and the card banners keep their layers over the Shop's and a window's, the Steam game's
   order — under SETTINGS' and LEAVE's since w48: THE PAUSE'S DIM, below).
   `is-under`: `z-index: auto` paints the part in tree order, under the stage appended after the board and under every
   peer with a z-index; `isolation: isolate` keeps it a stacking context, so its pops (4) stay inside, under the dim.
   IN PLAY under the war's band is BANDED instead: the faces under the band (the band wins where they meet), the label's
   line — IN PLAY, the +N chip, its tray — and every pop at a 2 of their own over the band, as the Steam game's deferred
   tip; under a stage too, `is-under`'s isolation keeps that 2 inside the row. The pile: `is-hidden` for a war table,
   `is-under` under any other stage; the band `is-under` under SETTINGS and LEAVE. */
.board > .inplay.is-under, .board > .pile.is-under, .board > .warlive.is-under { z-index: auto; isolation: isolate; }
.board > .inplay.is-banded { z-index: auto; }
.inplay.is-banded > .label { position: relative; z-index: 2; }
.inplay.is-banded .faces .pop { z-index: 2; }
/* THE PAUSE'S DIM (w48, B18): SETTINGS and LEAVE are lite's pause — the Steam game's `draw_pause` runs last and dims every
   banner — so under them (`.app.is-paused`, the screen's one class) the moment's banner and the card banners' LAYER go
   under the dim too: `z-index: auto` paints each in tree order under the stage (the layer is appended to `.app` before
   any stage; `position: fixed` keeps its banners' own 1 inside it). Over the Shop's, a window's and the war's dim they
   keep their layers (the Steam order; B8). */
.app.is-paused .board > .banner, .app.is-paused > .card-banners { z-index: auto; }
.board > .chooser { position: absolute; z-index: 3; left: 0; bottom: 0; width: var(--chooser-w); height: var(--chooser-h); padding: var(--sp-3); box-shadow: var(--shadow-stage); animation: rise-in var(--dur-base) var(--ease-out); }
.board > .bubbles { position: absolute; inset: 0; z-index: 2; pointer-events: none; }   /* over a banner (B7) */
.bubbles .bubble { position: absolute; left: var(--sp-2); animation: bubble-in var(--dur-base) var(--ease-out); transition: opacity var(--dur-base) var(--ease-in); }
.bubbles .bubble.is-gone { opacity: 0; }
.offer .btns { gap: var(--sp-2); justify-content: center; }
/* THE SHOP'S BUTTONS (w14, the Steam shop's m51): the coin and the price BUYS ("+1" SELLS), the lock HOLDS and is lit
   gold while it holds — no word on either; a price past the purse in danger */
.btn.ico-btn { justify-content: center; gap: 6px; min-width: 44px; }
.btn .ico { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.coin.tiny { width: 16px; height: 16px; font-size: 0; }
.btn.is-on { border-color: var(--accent-ink); color: var(--accent-ink); }
.btn.is-on .ico { fill: var(--accent); }
.btn .price.is-short { color: var(--danger); }
/* a CUT-OFF cell's padlock (w14, the Steam board's m18): its body in the owner's colour, so a board of cut land says
   whose each cell is */
.lock { fill: var(--seat); stroke: var(--lock); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }

/* ---- the smallest window: 1280×720 CSS px holds the three columns. Narrower (w30), the WORLD rail — the seats and the
   history — folds into a DRAWER over the board's left edge, opened by its HANDLE in a gutter of its own and shut by the
   handle or Esc; YOUR rail stays a column, for it holds what you act with; the top bar keeps its row (the round, the
   plate, the order of play over your rail). The title, the room and the game over keep their columns, the right one
   narrower. Under 960 the window cuts every screen at the right: there is no phone layout. */
/* THE DRAWER HANDLE: a tab of card stock at the window's left edge under the top bar — SEATS read upward and a chevron
   pointing in — that rides on the drawer's edge while it is open, its chevron turned to point out; hidden where the
   rail is a column */
.drawer-handle { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); position: fixed; z-index: 4; left: 0; top: calc(var(--top-h) + var(--sp-3));
  width: var(--handle-w); padding: var(--sp-3) 0; background: var(--panel); background-image: var(--stock); color: var(--ink); border: var(--ink-w) solid var(--ink); border-left: 0;
  border-radius: 0 var(--radius-2) var(--radius-2) 0; box-shadow: 2px 2px 0 var(--hard); cursor: pointer; user-select: none; transition: transform var(--dur-base) var(--ease-out); }
.drawer-handle:hover { background-color: var(--btn); }
.drawer-handle .word { writing-mode: vertical-rl; transform: rotate(180deg); }
.drawer-handle svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform var(--dur-base) var(--ease-out); }
.drawer-handle.is-open { transform: translateX(calc(var(--rail-w) + var(--sp-2))); }
.drawer-handle.is-open svg { transform: rotate(180deg); }
@media (width >= 1280px) { .drawer-handle { display: none; } }
@media (width < 1280px) {
  .app, .screen { min-width: 960px; }
  .top { grid-template-columns: max-content minmax(0, 1fr) var(--rail-w); }
  /* the plate's words keep their line (the kit's rule at every width since B16): here the seat's word is capped always
     and the bar is the narrow one, and the ladder climbs over them — the ask gives way last; the round's pips a step
     smaller */
  .plate { gap: var(--sp-3); }
  .plate .turn { max-width: 11em; }
  .plate .clock .bar { width: 48px; }
  .round { gap: var(--sp-2); }
  .pips { gap: 3px; }
  .pip { width: 8px; height: 8px; }
  .table { grid-template-columns: minmax(0, 1fr) var(--rail-w); padding-left: calc(var(--handle-w) + var(--sp-2)); }
  .rail.world { position: fixed; z-index: 4; left: var(--sp-2); top: var(--top-h); bottom: var(--hand-h); width: var(--rail-w); box-shadow: var(--shadow-stage);
    transform: translateX(calc(-100% - var(--sp-4))); visibility: hidden; transition: transform var(--dur-base) var(--ease-out), visibility 0s linear var(--dur-base); }
  .rail.world.is-open { transform: none; visibility: visible; transition: transform var(--dur-base) var(--ease-out), visibility 0s; }
  /* a chat line's bubble stands just right of the drawer while it is open (the rows it is level with are in it) */
  .table.is-drawer .bubbles .bubble { left: calc(var(--rail-w) - var(--handle-w) + var(--sp-2)); }
}
