/* css/table.css — the in-game table (table agent): SPEC §9.2 phone layout (360 × 640: top bar 44, ticket 56, wall 468, bottom bar 72 + safe
   area), the Request, Order, Reveal, Scoreboard, Final, ledger, handoff, face-off and Double Shift screens, setups and the Chip Book.
   PILLAR 1: nothing here touches a chip or the mat (.wall-mat is the wall agent's). While a wall is on screen (body.wall-on) the chrome is
   ink / paper / white only; states are glyph + text, never colour alone. Every motion is a look `fx-*` class or a transform; no filters. */

/* ---------- the fixed game frame ---------- */
.tb-host{ min-height:100dvh; }
.tb-screen{ position:relative; display:flex; flex-direction:column; height:100dvh; min-height:480px; width:100%; max-width:520px; margin:0 auto;
  background:var(--paper); overflow:hidden; -webkit-user-select:none; user-select:none; -webkit-touch-callout:none; }
.tb-scroll{ display:flex; flex-direction:column; gap:10px; width:100%; max-width:520px; margin:0 auto; min-height:100dvh; padding:0 0 calc(var(--sab) + 8px); }
.tb-scroll > :not(.tb-top):not(.rq-banner):not(.rq-wall):not(.sticky-bottom){ margin-left:calc(var(--sal) + 12px); margin-right:calc(var(--sar) + 12px); }
.tb-wait .card{ margin-top:24px; }

.tb-top{ flex:0 0 auto; display:flex; align-items:stretch; min-height:calc(44px + var(--sat)); padding-top:var(--sat); background:var(--card);
  box-shadow:inset 0 -1px 0 var(--rule); }   /* a hairline that adds no height: 44 px exactly (§9.2) */
.tb-icon{ flex:0 0 44px; width:44px; min-height:44px; display:grid; place-items:center; padding:0; margin:0; border:0; background:transparent; color:var(--ink);
  border-radius:4px; -webkit-tap-highlight-color:transparent; }
.tb-icon.pressed{ background:var(--rule); }
.tb-icon[aria-pressed="true"]{ outline:2px solid var(--ink); outline-offset:-4px; }
.tb-icon48{ flex:0 0 48px; width:48px; height:48px; min-height:48px; border:2px solid var(--ink); background:var(--card); }
.tb-icon48[aria-disabled="true"]{ border-style:dashed; color:var(--ink-2); }
.tb-icon48[data-on="1"]{ background:var(--ink); color:var(--paper); }
.tb-mid{ flex:1 1 auto; min-width:0; display:flex; flex-direction:column; justify-content:center; gap:2px; padding:2px 2px; }
.tb-line{ font-size:var(--fs-s); line-height:1.2; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tb-t1{ font-weight:800; } .tb-sub, .tb-status{ color:var(--ink-2); }
.tb-cust svg{ vertical-align:-2px; margin:0 3px 0 2px; }
.tb-glyphs{ display:flex; flex-wrap:nowrap; gap:3px; min-height:16px; overflow:hidden; }
.tb-g{ position:relative; display:inline-flex; width:16px; height:16px; }
.tb-g svg{ width:14px; height:14px; }
.tb-gm{ position:absolute; right:-3px; bottom:-3px; min-width:9px; font:900 9px/9px var(--font-ui); background:var(--ink); color:var(--paper); border-radius:2px; text-align:center; }
.tb-gm:empty{ display:none; }
.tb-g[data-m="off"]{ outline:1px dashed var(--ink-2); outline-offset:1px; }

.tb-ticket{ flex:0 0 auto; display:flex; align-items:center; gap:8px; min-height:56px; padding:4px calc(var(--sar) + 10px) 4px calc(var(--sal) + 12px);
  background:var(--card); border-bottom:1px solid var(--rule); }
.tb-words{ flex:1 1 auto; min-width:0; }
.tb-req{ font:900 var(--fs-ticket)/1.02 var(--font-sign); text-transform:uppercase; letter-spacing:-.01em; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tb-req.ph{ color:var(--ink-2); font-size:calc(20px * var(--tx)); }
.tb-act{ font:700 calc(18px * var(--tx))/1.15 var(--font-ui); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tb-act.note{ font-size:var(--fs-s); font-weight:600; color:var(--ink-2); white-space:normal; }
.tb-timer{ flex:0 0 auto; display:flex; flex-direction:column; align-items:flex-end; gap:3px; min-width:52px; }
.tb-digits{ font:900 calc(22px * var(--tx))/1 var(--font-ui); font-variant-numeric:tabular-nums; }
.tb-timer[data-low="1"] .tb-digits::before{ content:"! "; font-size:.7em; vertical-align:2px; }
.tb-bar{ display:block; width:52px; height:7px; border:2px solid var(--ink); border-radius:2px; overflow:hidden; background:var(--card); }
.tb-barfill{ display:block; height:100%; width:100%; background:var(--ink); transform-origin:left center; }

.tb-wallbox{ position:relative; flex:1 1 auto; min-height:0; }
.tb-bottom{ flex:0 0 auto; display:flex; align-items:center; gap:8px; min-height:calc(72px + var(--sab)); padding:8px calc(var(--sar) + 8px) calc(var(--sab) + 8px) calc(var(--sal) + 8px);
  background:var(--card); box-shadow:inset 0 1px 0 var(--rule); }
.tb-main{ flex:1 1 auto; min-height:56px; flex-direction:column; gap:1px; padding:6px 10px; }
.tb-lab{ display:block; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:100%; }
.tb-bottom .tb-main, .fo-ctl .tb-main, .ho-downrow .tb-main{ font-size:calc(17px * var(--tx)); }
.tb-sublab{ display:block; font:600 var(--fs-xs)/1.2 var(--font-ui); text-transform:none; letter-spacing:0; }
.tb-sublab:empty{ display:none; }
.tb-menu-list .btn{ justify-content:flex-start; }

/* ---------- S05 Request ---------- */
.rq-banner{ display:flex; align-items:center; gap:8px; position:relative; padding:6px calc(var(--sar) + 12px) 6px calc(var(--sal) + 12px); background:var(--card); border-bottom:1px solid var(--rule); min-height:56px; }
.rq-btext{ flex:1; display:flex; flex-direction:column; min-width:0; }
.rq-btext b{ font-size:calc(20px * var(--tx)); }
.rq-bsub{ font-size:var(--fs-s); color:var(--ink-2); font-weight:600; }
.rq-banner.rq-last{ border-bottom:3px double var(--ink); }
.rq-twist{ font-size:var(--fs-s); padding:8px 10px; border:2px dashed var(--ink); border-radius:4px; background:var(--card); }
.rq-wall{ position:relative; height:min(44dvh, 330px); min-height:230px; }
.rq-slips{ display:flex; gap:8px; justify-content:center; }
.rq-slip{ flex:1 1 0; max-width:110px; min-height:64px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:0; padding:6px 4px;
  border:2px solid var(--ink); border-radius:4px; background:var(--card); color:var(--ink); box-shadow:0 3px 0 var(--ink); }
.rq-slip > .fx-face-up{ display:flex; flex-direction:column; align-items:center; }
.rq-slip[data-face="down"] > .fx-face-up{ display:none; }
.rq-slip[data-face="up"] > .fx-face-down{ display:none; }
.rq-slip[aria-pressed="true"]{ background:var(--ink); color:var(--paper); }
.rq-slip[aria-pressed="true"] .rq-sl::after{ content:" ✓"; }
.rq-slip.pressed{ transform:translateY(3px); box-shadow:none; }
.rq-sn{ font:900 22px/1 var(--font-sign); }
.rq-sl{ font-size:var(--fs-xs); font-weight:800; text-transform:uppercase; }
.rq-sp{ font:600 var(--fs-xs)/1.2 var(--font-code); }
.rq-back svg{ display:block; width:44px; height:58px; }
.rq-free{ border-style:dashed; }
.rq-aisles{ display:flex; gap:6px; overflow-x:auto; padding:2px 0 4px; scrollbar-width:none; }
.rq-aisle{ flex:0 0 auto; min-height:44px; padding:6px 12px; border:1.5px solid var(--ink); border-radius:999px; background:var(--card); color:var(--ink);
  font-size:var(--fs-s); font-weight:700; white-space:nowrap; }
.rq-aisle[aria-pressed="true"]{ background:var(--ink); color:var(--paper); }
.rq-aisle[aria-pressed="true"]::before{ content:"✓ "; }
.rq-hint{ font-size:var(--fs-s); padding:6px 10px; border-left:3px solid var(--ink); background:var(--card); }
.rq .field label{ font-size:var(--fs-m); }
.rq-in{ font-size:calc(20px * var(--tx)) !important; scroll-margin-bottom:150px; scroll-margin-top:12px; }
.rq-in[readonly]{ border-style:dashed; color:var(--ink-2); }
.rq-note{ font-size:var(--fs-s); font-weight:600; padding-left:2px; }
.rq-note:empty{ display:none; }
.rq-note::before{ content:"ⓘ "; }
.rq-bottom{ display:flex; flex-direction:column; gap:6px; padding-left:calc(var(--sal) + 12px); padding-right:calc(var(--sar) + 12px); }
.rq-bottom .row > .btn{ flex:1; }
.rq-status{ font-size:var(--fs-s); font-weight:700; min-height:1.2em; }
.tb-scroll > .rq-status{ margin-top:6px; margin-bottom:8px; }
.rq-stamphost{ position:relative; height:0; }
.rq-stamphost .fx-stamp-abs{ top:-34px; }
.rq-waitcard{ margin-top:8px; }

/* ---------- S07 Order ---------- */
.od-mainwrap{ flex:1 1 auto; min-width:0; display:flex; gap:6px; align-items:center; position:relative; }
.od-mainwrap .tb-main{ flex:1 1 auto; }
.od-alt{ flex:0 0 auto; min-height:56px; padding:6px 12px; }
.od-locked{ position:absolute; right:6px; top:-14px; font:800 var(--fs-xs)/1 var(--font-ui); background:var(--ink); color:var(--paper); padding:3px 6px; border-radius:3px; }
.od-locked:empty{ display:none; }
.od-spacer{ visibility:hidden; border:0; }
.od-custbar{ flex-wrap:nowrap; }
.od-stepper{ display:flex; align-items:center; gap:4px; flex:0 0 auto; }
.od-step{ min-width:48px; min-height:48px; padding:0; font-size:24px; }
.od-callv{ min-width:38px; text-align:center; font:900 calc(28px * var(--tx))/1 var(--font-sign); }
.od-bands{ display:grid; grid-template-columns:repeat(4, minmax(0, 1fr)); gap:4px; flex:1 1 auto; min-width:0; }
.od-band{ min-height:48px; padding:4px 2px; font-size:var(--fs-xs); min-width:0; }
.od-band[aria-pressed="true"]{ --bg:var(--ink); --fg:var(--paper); }
.od-band[aria-pressed="true"]::before{ content:"✓"; margin-right:2px; }
.od-custbar .tb-main{ flex:1 1 auto; }
.od-custbar .od-bands + .tb-main{ flex:0 0 112px; }
.od-counts{ position:absolute; left:0; right:0; bottom:calc(72px + var(--sab)); padding:4px 12px; background:var(--card); border-top:1px solid var(--rule);
  font-size:var(--fs-s); font-weight:700; text-align:center; }
.od-counts:empty{ display:none; }
.od-cn{ font-weight:900; }
.od-watch{ flex:1; text-align:center; font-weight:700; color:var(--ink-2); }
.od[data-variant="customer"] .tb-wallbox{ margin-bottom:28px; }

/* ---------- S08 Reveal ---------- */
.rv-ticket{ min-height:52px; }
.rv-req{ font-size:calc(24px * var(--tx)); }
.rv-panel{ flex:0 0 auto; position:relative; display:flex; flex-direction:column; gap:4px; padding:6px calc(var(--sar) + 10px) 4px calc(var(--sal) + 10px); background:var(--paper);
  border-top:1px solid var(--rule); min-height:136px; }
.rv-result{ position:relative; min-height:26px; font-weight:800; font-size:var(--fs-m); }
.rv-linebox{ position:relative; min-height:24px; display:flex; align-items:center; gap:8px; }
.rv-line{ font-size:var(--fs-s); font-weight:700; }
.rv-line[data-kind="returned"], .rv-line[data-kind="voided"]{ font-weight:900; }
.rv-exact{ flex:0 0 auto; font:900 var(--fs-xs)/1 var(--font-code); border:1.5px solid var(--ink); padding:3px 6px; background:var(--card); }
.rv-card{ display:block; padding:22px 12px 8px 12px; margin:0; }
.rv-card[data-face="down"]{ min-height:70px; }
.rv-code{ font:800 var(--fs-m)/1.1 var(--font-code); }
.rv-name{ font:900 calc(18px * var(--tx))/1.15 var(--font-sign); text-transform:uppercase; letter-spacing:-.01em; }
.rv-words{ font-size:var(--fs-s); }
.rv-back{ display:grid; place-items:center; min-height:44px; font:900 var(--fs-s)/1 var(--font-sign); letter-spacing:.1em; }
.rv-strip{ flex:0 0 auto; }
.rv-bottom{ gap:6px; overflow-x:auto; }
.rv-act{ flex:0 0 auto; min-height:48px; padding:6px 10px; font-size:var(--fs-s); }
.rv-act[aria-pressed="true"]{ --bg:var(--ink); --fg:var(--paper); }
.rv-rxn{ flex:0 0 auto; font-size:var(--fs-xs); font-weight:700; }
.rv-next{ flex:1 1 auto; min-height:56px; min-width:96px; white-space:nowrap; padding:6px 10px; }
.rv-pops{ position:absolute; inset:0; pointer-events:none; z-index:4; }
.rv-pop{ position:absolute; padding:1px 4px; border-radius:3px; background:#16171a; color:#ffffff; border:1px solid #ffffff; font:800 11px/14px system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  white-space:nowrap; font-variant-numeric:tabular-nums; }
.rv-pop[data-z="1"]{ background:#ffffff; color:#16171a; border-color:#16171a; }
.rv-pop.crowd{ border-style:dashed; }
.rv-pointer{ position:absolute; left:0; top:0; pointer-events:none; z-index:6; overflow:visible; }

/* ---------- S09 Scoreboard ---------- */
.sc-strip{ display:flex; gap:6px; overflow-x:auto; padding:4px 10px; background:var(--card); border-top:1px solid var(--rule); scrollbar-width:none; }
.sc-chip{ flex:0 0 auto; display:inline-flex; align-items:center; gap:2px; font-size:var(--fs-xs); padding:2px 6px; border:1px solid var(--rule); border-radius:3px; white-space:nowrap; }
.sc-chip[data-me="true"]{ border:2px solid var(--ink); }
.sc-pl{ font-weight:900; margin-right:2px; }
.sc-d{ font-weight:800; }
.sc-team{ font-weight:800; border-color:var(--ink); }
.sc-list{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:6px; }
.sc-row{ display:flex; align-items:center; gap:10px; min-height:52px; padding:6px 10px; background:var(--card); border:1px solid var(--rule); border-radius:6px; font-size:var(--fs-l); }
.sc-row[data-me="true"]{ border:2px solid var(--ink); }
.sc-place{ flex:0 0 48px; font:900 calc(18px * var(--tx))/1 var(--font-sign); }
.sc-name{ flex:1 1 auto; min-width:0; font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.sc-tm{ font-size:var(--fs-xs); color:var(--ink-2); }
.sc-total{ flex:0 0 auto; font:900 calc(20px * var(--tx))/1 var(--font-ui); font-variant-numeric:tabular-nums; }
.sc-delta{ flex:0 0 40px; text-align:right; font-weight:800; font-size:var(--fs-s); }
.sc-teams{ display:grid; gap:6px; padding:10px; border:2px solid var(--ink); border-radius:6px; background:var(--card); }
.sc-teamrow{ display:flex; gap:8px; align-items:baseline; font-size:var(--fs-l); }
.sc-teamrow b{ font-size:calc(24px * var(--tx)); }
.sc-teamrow.gloss{ background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8'%3E%3Cpath d='M-2 2L2 -2M0 8L8 0M6 10L10 6' stroke='%23d8d5ce' stroke-width='2'/%3E%3C/svg%3E"); }

/* ---------- S10 Final / S15 Double Shift result ---------- */
.fn-head{ font-size:calc(24px * var(--tx)); text-align:center; }
.fn-stamps{ position:relative; min-height:8px; display:flex; justify-content:center; }
.fn-stamps .fx-stamp-abs{ position:relative; left:auto; top:auto; translate:none; }
.fn-xp .xpbar{ margin:8px 0 4px; }
.xpfill{ display:block; height:100%; background:var(--ink); }
.fn-foot:empty{ display:none; }
.ds-card{ display:flex; flex-direction:column; align-items:center; gap:8px; }
.ds-big{ font:900 calc(56px * var(--tx))/1 var(--font-sign); }
.ds-max{ font-size:.45em; color:var(--ink-2); }
.ds-list{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:4px; }
.ds-row{ display:grid; grid-template-columns:36px 1fr auto; grid-template-areas:"n who tot" "n ring call"; gap:0 8px; padding:6px 10px; background:var(--card); border:1px solid var(--rule); border-radius:4px; font-size:var(--fs-s); }
.ds-n{ grid-area:n; font-weight:900; } .ds-who{ grid-area:who; font-weight:700; } .ds-ring{ grid-area:ring; } .ds-call{ grid-area:call; text-align:right; } .ds-tot{ grid-area:tot; text-align:right; font-size:var(--fs-l); }

/* ---------- S12 ledger ---------- */
.lg{ display:flex; flex-direction:column; gap:10px; }
.lg-head b{ font-size:var(--fs-l); }
.lg-flag{ font-weight:900; }
.lg-table{ width:100%; border-collapse:collapse; font-size:var(--fs-s); }
.lg-table th, .lg-table td{ padding:6px 4px; border-bottom:1px solid var(--rule); text-align:left; vertical-align:middle; }
.lg-table thead th{ font-size:var(--fs-xs); text-transform:uppercase; color:var(--ink-2); }
.lg-table th[scope="row"]{ font-weight:700; white-space:nowrap; }
.lg-table th[scope="row"] svg{ vertical-align:-3px; margin-right:4px; }
.lg-name{ display:inline-block; max-width:7.5em; overflow:hidden; text-overflow:ellipsis; vertical-align:bottom; }
.lg-tot{ font-weight:900; }
.lg-cust{ display:flex; flex-direction:column; gap:3px; padding:10px; border:1.5px solid var(--ink); border-radius:4px; background:var(--card); font-size:var(--fs-s); }

/* ---------- S13 handoff ---------- */
.ho{ min-height:100dvh; }
.ho-card{ min-height:auto; justify-content:center; align-items:center; text-align:center; gap:14px; padding-top:28px; }
.ho-pass{ display:flex; flex-direction:column; align-items:center; gap:6px; }
.ho-to{ font:800 var(--fs-l)/1 var(--font-ui); color:var(--ink-2); }
.ho-name{ font-size:calc(40px * var(--tx)); line-height:1; }
.ho-tri{ display:none; }
.ho-sub{ max-width:30em; }
.ho-hold{ min-height:72px; gap:12px; touch-action:none; }
.ho-ring{ width:40px; height:40px; flex:0 0 40px; }
.ho-rules p{ margin:0; }
.ho-say{ font-size:calc(22px * var(--tx)); }
.tb-ticket[data-waiting="1"] .ho-waiting{ font-weight:900; color:var(--ink); }
.tb-ticket[data-waiting="1"] .ho-waiting::before{ content:"🔔 "; }
.ho-ctl{ flex:0 0 auto; display:flex; flex-direction:column; gap:6px; padding:6px calc(var(--sar) + 8px) calc(var(--sab) + 8px) calc(var(--sal) + 8px); background:var(--card); border-top:1px solid var(--rule); }
.ho-sliprow, .ho-downrow, .ho-callrow{ display:flex; gap:6px; align-items:center; }
.ho-slip{ flex:1 1 0; min-height:48px; padding:4px 6px; font-size:var(--fs-s); }
.ho-slip[aria-pressed="true"]{ --bg:var(--ink); --fg:var(--paper); }
.ho-slip[aria-pressed="true"]::after{ content:" ✓"; }
.ho-said{ flex:0 0 auto; min-height:48px; padding:4px 10px; font-size:var(--fs-s); }
.ho-cl{ flex:0 0 auto; font-size:var(--fs-xs); font-weight:800; text-transform:uppercase; max-width:4.5em; line-height:1.1; }
.ho-callrow .od-stepper{ flex:1 1 auto; justify-content:center; }
.ho-callit{ flex:0 0 auto; min-height:48px; padding:4px 10px; font-size:var(--fs-s); }
.ho-downrow .tb-main{ flex:1 1 auto; }

/* ---------- S14 face-off ---------- */
.fo{ min-height:100dvh; }
.fo-pair{ display:grid; grid-template-rows:minmax(0, 1fr) auto minmax(0, 1fr); height:100dvh; max-width:520px; margin:0 auto; background:var(--paper); -webkit-user-select:none; user-select:none; }
.fo-slot{ min-height:0; display:flex; }
.fo-half{ flex:1 1 auto; min-height:0; display:flex; flex-direction:column; }
.fo-top{ padding-top:var(--sat); }
.fo-bottom{ padding-bottom:var(--sab); }
.fo-top .fo-near{ transform:rotate(180deg); }
.fo-near{ flex:0 0 auto; display:flex; flex-direction:row; align-items:center; gap:6px; padding:4px 6px; background:var(--card); }
.fo-banner{ flex:0 0 104px; min-width:0; display:flex; flex-wrap:wrap; align-items:center; gap:2px 4px; font-size:var(--fs-s); }
.fo-name{ font-size:var(--fs-m); max-width:72px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.fo-hint{ display:none; }
.fo-banner .tb-timer{ flex-direction:row; align-items:center; gap:4px; min-width:0; }
.fo-banner .tb-bar{ width:40px; }
.fo-ctl{ flex:1 1 auto; min-width:0; display:flex; gap:6px; }
.fo-ctl .tb-main{ flex:1 1 auto; min-height:52px; min-width:0; }
.fo-alt{ flex:0 0 auto; min-height:52px; padding:6px 10px; }
.fo-wallwrap{ position:relative; flex:1 1 auto; min-height:0; }
.fo-wall{ position:absolute; inset:0; }
.fo-cover{ position:absolute; inset:0; z-index:8; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:6px; background:var(--paper);
  border:2px solid var(--ink); font-size:var(--fs-m); text-align:center; padding:12px; }
.fo-cover b{ font:900 calc(28px * var(--tx))/1 var(--font-sign); text-transform:uppercase; }
.fo-top .fo-cover{ transform:rotate(180deg); }
.fo-mid{ display:flex; align-items:center; gap:6px; min-height:48px; padding:0 6px; background:var(--ink); color:var(--paper); }
.fo-mid .tb-icon{ color:var(--paper); }
.fo-mid .tb-icon48{ background:var(--ink); color:var(--paper); border-color:var(--paper); width:44px; height:44px; min-height:44px; flex-basis:44px; }
.fo-eyes{ flex:1 1 auto; text-align:center; font-weight:800; font-size:var(--fs-s); line-height:1.15; }
.fo-single-note{ flex:0 0 auto; padding:6px 12px; background:var(--card); border-bottom:1px solid var(--rule); font-weight:700; font-size:var(--fs-s); }
.fo-singlehost{ flex:1 1 auto; min-height:0; display:flex; }
.fo-singlefoul{ position:absolute; right:calc(var(--sar) + 8px); top:calc(var(--sat) + 52px); z-index:9; }
.fo-single .fo-singlefoul .tb-icon48{ width:44px; height:44px; min-height:44px; }
.fo-recall{ padding:6px 12px; background:var(--card); border-bottom:1px solid var(--rule); gap:6px; align-items:center; }
.fo-recall .od-bands{ flex:1; }
.fo-speak .fo-speakcard{ min-height:auto; flex:1; justify-content:center; }
.fo-big{ font-size:calc(22px * var(--tx)); font-weight:800; }
.fo-speakrow{ gap:10px; } .fo-speakrow .tb-main{ flex:1; }

/* ---------- S11 setups ---------- */
.ps-names{ display:flex; flex-direction:column; gap:6px; }
.ps-row{ display:flex; gap:8px; align-items:flex-start; }
.ps-glyph{ flex:0 0 44px; height:48px; display:grid; place-items:center; border:1.5px solid var(--ink); border-radius:4px; background:var(--card); }
.ps-del{ flex:0 0 48px; font-size:22px; }
.ps-rules p{ margin:0; }

/* ---------- S18 Chip Book ---------- */
.cb-tabs{ max-width:none; width:100%; justify-content:stretch; }
.cb-tabs .btn{ flex:1 1 0; }
.cb-fams{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:8px; }
.cb-fam{ justify-content:space-between; text-align:left; gap:8px; }
.cb-fn{ font-weight:900; } .cb-fc{ margin-left:auto; font-weight:700; font-variant-numeric:tabular-nums; }
.cb-grid{ display:grid; grid-template-columns:repeat(auto-fill, minmax(150px, 1fr)); gap:10px; }
.cb-card{ display:flex; flex-direction:column; gap:3px; padding:24px 10px 10px; }
.cb-mini{ position:relative; width:100%; height:86px; margin-bottom:6px; }
.cb-code{ font:800 var(--fs-s)/1.1 var(--font-code); }
.cb-name{ font:900 var(--fs-m)/1.15 var(--font-sign); text-transform:uppercase; }
.cb-words{ font-size:var(--fs-s); }
.cb-badge{ font-weight:900; padding:8px 10px; border:3px double var(--ink); border-radius:4px; background:var(--card); }

/* ---------- larger screens: landscape tablets move the ticket and buttons to a right-hand column (§9.2) ---------- */
@media (orientation:landscape) and (min-width:900px){
  .tb-screen{ max-width:1180px; display:grid; grid-template-columns:minmax(0, 1fr) 360px; grid-template-rows:auto auto minmax(0, 1fr) auto auto auto; }
  .tb-screen > *{ grid-column:2; min-width:0; }
  .tb-screen > .tb-top{ grid-column:1 / -1; grid-row:1; }
  .tb-screen > .tb-wallbox{ grid-column:1; grid-row:2 / -1; }
  .tb-screen > .tb-ticket{ grid-row:2; }
  .tb-screen > .rv-panel, .tb-screen > .ho-ctl, .tb-screen > .fo-single-note, .tb-screen > .fo-recall{ grid-row:3; align-self:start; }
  .tb-screen > .rv-strip{ grid-row:4; }
  .tb-screen > .od-counts{ grid-row:5; position:static; }
  .tb-screen > .tb-bottom{ grid-row:6; flex-wrap:wrap; align-content:flex-end; }
  .tb-screen > .ho-ctl{ grid-row:6; }
  .od[data-variant="customer"] .tb-wallbox{ margin-bottom:0; }
  .fo-pair{ max-width:760px; }
  .tb-screen.fo-single, .tb-screen.fo-speak{ display:flex; max-width:640px; }
  .tb-screen.fo-single > *, .tb-screen.fo-speak > *{ grid-column:auto; grid-row:auto; }
}

/* in-game toasts sit over the ticket banner, never over the bottom bar's buttons or the middle of the wall */
.tb-screen > .toasts.in-host{ position:absolute; z-index:30; left:0; right:0; top:calc(var(--sat) + 46px); bottom:auto; display:flex; flex-direction:column; align-items:center; gap:4px; pointer-events:none; padding:0 12px; }
/* larger text (115 / 130 %): the reveal's action row wraps so Next always stays on screen */
html[data-text="115"] .rv-bottom, html[data-text="130"] .rv-bottom{ flex-wrap:wrap; overflow-x:visible; }
html[data-text="115"] .rv-next, html[data-text="130"] .rv-next{ flex:1 1 100%; }
