/* COUP — one stylesheet for the phone client (and, later, the dev table's panels).
   Theme: the original Coup look — near-black steel, propaganda red, off-white
   type, condensed caps headings (Oswald). Body and Thai: Noto Sans Thai.
   Category colours (G54): --fin green, --com blue, --frc red, --spc purple;
   classic characters use --cls (steel). Every colour lives on :root. */

@font-face {
  font-family: "Oswald"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/fonts/oswald-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Noto Sans Thai"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/fonts/noto-sans-thai-thai.woff2) format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC;
}
@font-face {
  font-family: "Noto Sans Thai"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/fonts/noto-sans-thai-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0d0e10; --bg2: #16181c; --steel: #23272e; --steel2: #2e333b; --line: #353b45;
  --ink: #ece8e1; --mut: #9aa0a8; --red: #c8202f; --red2: #e43b47; --red-ink: #fff4f2; --redglow: rgba(200,32,47,.35);
  --ok: #6fbf73; --warn: #e3a33b;
  --fin: #3e9b5a; --com: #3b7fd0; --frc: #d0383f; --spc: #8f5bd0; --cls: #8a94a3;
  --display: "Oswald", "Noto Sans Thai", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "Noto Sans Thai", -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --r: 10px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--body); line-height: 1.45; font-size: 16px;
  background: radial-gradient(900px 520px at 50% -10%, #2a2025, var(--bg) 65%) fixed, var(--bg);
  color: var(--ink); -webkit-font-smoothing: antialiased; min-height: 100vh; overflow-x: hidden;
}
/* brushed-steel grain + vignette (decorative, never intercepts taps) */
body::before, body::after { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0; }
body::before { background: repeating-linear-gradient(0deg, rgba(255,255,255,.012) 0 1px, transparent 1px 3px); }
body::after { background: radial-gradient(ellipse at 50% 40%, transparent 55%, rgba(0,0,0,.7) 100%); }

.app { position: relative; z-index: 1; max-width: 560px; margin: 0 auto; padding: 14px 16px 56px; }
:lang(th) { line-height: 1.6; }
/* Thai script breaks apart under tracking: no letter-spacing on Thai display text */
:lang(th) .tag, :lang(th) .orr, :lang(th) button, :lang(th) .slotcat, :lang(th) .sheet h2 { letter-spacing: 0; }
.client { position: relative; }

button { font: inherit; font-family: var(--display); font-weight: 600; text-transform: uppercase; letter-spacing: .04em;
  border: 0; border-radius: var(--r); padding: 12px 18px; cursor: pointer; min-height: 44px;
  background: linear-gradient(180deg, var(--red2), var(--red)); color: var(--red-ink); font-size: 17px;
  box-shadow: 0 2px 0 #7a1019, 0 6px 16px rgba(0,0,0,.45); -webkit-tap-highlight-color: transparent; }
:lang(th) button { text-transform: none; font-family: var(--body); font-weight: 700; }
button:disabled { opacity: .4; cursor: not-allowed; box-shadow: none; }
button.big { width: 100%; font-size: 20px; padding: 14px; margin-top: 10px; }
button.sec { background: var(--steel); color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
button.small-btn { padding: 9px 14px; font-size: 15px; margin-top: 8px; }
button.mini { padding: 4px 6px; min-height: 44px; min-width: 44px; background: transparent; color: var(--mut); border: 1px solid var(--line); border-radius: 8px; box-shadow: none; display: inline-flex; align-items: center; justify-content: center; }
.linkish { background: transparent; color: var(--mut); padding: 6px 8px; font-family: var(--body); font-size: 14px; font-weight: 700; text-transform: none; letter-spacing: 0; min-height: 44px; box-shadow: none; }
.linkish.warnlink { color: var(--warn); }
.langbtn { color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 4px 14px; min-height: 44px; }
input { font: inherit; width: 100%; background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; font-size: 18px; }
input:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 3px var(--redglow); }
input.codein { text-transform: uppercase; letter-spacing: .3em; font-family: var(--display); font-weight: 700; }
button:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.mut { color: var(--mut); }
.small { font-size: 13px; }
.center { text-align: center; }
.panel { background: linear-gradient(180deg, rgba(35,39,46,.92), rgba(22,24,28,.94)); border: 1px solid var(--line); border-radius: 12px; padding: 14px 14px; margin: 12px 0; box-shadow: inset 0 1px 0 rgba(255,255,255,.04); }
.panel > p.small:last-child { margin-bottom: 0; }
.tag { font-family: var(--display); font-size: 13px; color: var(--red2); text-transform: uppercase; letter-spacing: .14em; font-weight: 600; margin-bottom: 8px; }
:lang(th) .tag { font-family: var(--body); font-weight: 700; }
label.tag { display: block; }
.tag.avtag { margin-top: 14px; }
.orr { text-align: center; color: var(--mut); font-family: var(--display); font-size: 14px; letter-spacing: .2em; text-transform: uppercase; margin: 20px 0 8px; }
.ic { width: 1.05em; height: 1.05em; vertical-align: -.16em; fill: currentColor; flex: none; }
.ic.tiny { width: .8em; height: .8em; }
.brand { display: flex; align-items: center; gap: 8px; }
.brand h1 { font-family: var(--display); font-size: 34px; letter-spacing: .14em; margin: 0; font-weight: 700; text-transform: uppercase; color: var(--ink); }
.brand .logo { width: 28px; height: 28px; color: var(--red2); filter: drop-shadow(0 0 6px var(--redglow)); }
.brand.small h1 { font-size: 22px; }
.brand.small .logo { width: 20px; height: 20px; }
.top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; gap: 8px; }
.top-r { display: flex; align-items: center; gap: 6px; }
.codechip { font-family: var(--display); font-weight: 600; letter-spacing: .2em; color: var(--ink); background: var(--steel); border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px; font-size: 14px; }
.code { font-family: var(--display); font-size: 46px; font-weight: 700; letter-spacing: .22em; color: var(--ink); background: var(--bg); border: 2px solid var(--red); border-radius: var(--r); padding: 2px 8px 2px 20px; display: inline-block; margin: 2px 0 10px; line-height: 1.2; }

.qr { display: block; margin: 6px auto; border-radius: 8px; background: #ece8e1; padding: 6px; }
.link { font-size: 13px; word-break: break-all; color: var(--mut); margin: 6px 0 10px; }
.share button.sec { width: 100%; }
.notice, .awaybar { background: rgba(227,163,59,.08); border: 1px solid var(--warn); color: var(--warn); border-radius: var(--r); padding: 10px 14px; font-weight: 700; font-size: 14px; margin: 10px 0; }
.awaybar { text-align: center; }
.awayslot, .nudgeslot { display: none; }
.notice.warn { display: flex; gap: 8px; align-items: flex-start; text-align: left; }
.notice.warn .ic { margin-top: 3px; }
.warns .notice { margin: 8px 0; }
.warns > p { margin: 2px 0 10px; }
.recbar { background: rgba(200,32,47,.08); border: 1px solid var(--line); border-left: 4px solid var(--red); border-radius: var(--r); padding: 8px 14px; margin: 10px 0; font-size: 14px; }
.recbar p { margin: 4px 0; }
.recbar b { color: var(--ink); }
.recbar .ic { color: var(--red2); }
.reason { color: var(--warn); font-weight: 700; font-size: 14px; margin: 8px 0 2px; }
.toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(12px); background: var(--steel); border: 1px solid var(--red); color: var(--ink); padding: 12px 18px; border-radius: var(--r); font-weight: 700; opacity: 0; pointer-events: none; transition: .25s; z-index: 90; box-shadow: 0 10px 28px rgba(0,0,0,.55); max-width: calc(100vw - 32px); text-align: center; font-family: var(--body); }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.foot { margin-top: 18px; display: flex; flex-wrap: wrap; justify-content: center; gap: 0 18px; }
.pulse { animation: pulse 2.4s infinite ease-in-out; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .55; } }
@media (prefers-reduced-motion: reduce) { .pulse { animation: none; } }

/* avatars: placeholder glyphs, desaturated (decoration only) */
.av { width: 46px; height: 46px; border-radius: 50%; background: radial-gradient(circle at 50% 38%, #6b727d, #343941 75%); border: 1px solid var(--line);
  display: inline-flex; align-items: center; justify-content: center; font-size: 26px; line-height: 1; flex: none; filter: grayscale(1) contrast(1.1); font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }
.av.sm { width: 38px; height: 38px; font-size: 21px; }
.av.xs { width: 26px; height: 26px; font-size: 14px; }

/* lobby: players */
.cnt { color: var(--ink); }
.cnt.low { color: var(--warn); }
.plist { display: flex; flex-direction: column; gap: 6px; }
.prow { display: flex; align-items: center; gap: 10px; background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r); padding: 4px 6px 4px 10px; min-height: 52px; }
.prow.away { opacity: .5; }
.prow.me { border-color: rgba(228,59,71,.6); }
.prow .nm { flex: 1; font-weight: 700; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prow .nm em { color: var(--mut); font-style: normal; font-size: 12px; font-weight: 400; }
.botlbl { border: 1px solid var(--line); border-radius: 6px; padding: 0 5px; }
.hostlbl { color: var(--warn); display: inline-flex; }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.dot.on { background: var(--ok); box-shadow: 0 0 7px var(--ok); }
.dot.off { background: var(--line); }
.avgrid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.avpick { background: var(--bg2); border: 1px solid var(--line); padding: 4px; border-radius: 12px; min-height: 44px; box-shadow: none; display: flex; justify-content: center; }
.avpick .av { width: 100%; height: auto; aspect-ratio: 1; border: 0; font-size: 24px; max-width: 52px; }
.avpick.on { border: 2px solid var(--red2); box-shadow: 0 0 10px var(--redglow); opacity: 1; cursor: default; }
.avpick.on .av { filter: none; }
.avpick.taken { opacity: .22; }

/* segmented controls (edition, dials) */
.dial { margin: 6px 0 12px; }
.dial:last-child { margin-bottom: 0; }
.dlabel { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.seg { display: flex; gap: 6px; flex-wrap: wrap; }
.seg.wide > * { flex: 1 1 0; justify-content: center; }
.seg button, .seg span { padding: 8px 16px; font-size: 15px; border-radius: var(--r); min-height: 44px; display: inline-flex; align-items: center; box-shadow: none; font-family: var(--display); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
:lang(th) .seg button, :lang(th) .seg span { font-family: var(--body); font-weight: 700; text-transform: none; letter-spacing: 0; }
.seg .on { background: linear-gradient(180deg, var(--red2), var(--red)); color: var(--red-ink); border: 1px solid var(--red); }
.seg button.on:disabled { opacity: 1; cursor: default; }
.seg .off { background: var(--bg2); color: var(--mut); border: 1px solid var(--line); }

/* presets */
.pgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.preset { background: var(--bg2); color: var(--ink); border: 1px solid var(--line); box-shadow: none; padding: 8px 10px; min-height: 52px; font-size: 15px;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: center; text-align: left; gap: 1px; }
.preset .pn { line-height: 1.2; }
.preset .pr { font-family: var(--body); font-size: 12px; font-weight: 400; color: var(--mut); text-transform: none; letter-spacing: 0; line-height: 1.3; }
.preset .pr.why { color: var(--warn); font-weight: 700; }
.preset.on { border: 2px solid var(--red2); background: rgba(200,32,47,.16); }
.preset.on:disabled { opacity: 1; cursor: default; }
.preset.out:disabled { opacity: .55; }
.preset.rnd { grid-column: 1 / -1; border-style: dashed; }

/* roles in play: 5 slots grouped by category */
.setname { margin: 0 0 8px; }
.setname b { font-family: var(--display); text-transform: uppercase; letter-spacing: .06em; font-size: 17px; }
:lang(th) .setname b { font-family: var(--body); letter-spacing: 0; }
.slots { display: flex; flex-direction: column; gap: 6px; }
.slotcat { font-family: var(--display); font-size: 12px; text-transform: uppercase; letter-spacing: .14em; margin: 6px 0 0; color: var(--cc, var(--mut)); }
:lang(th) .slotcat { font-family: var(--body); font-weight: 700; }
.c-finance { --cc: var(--fin); } .c-comms { --cc: var(--com); } .c-force { --cc: var(--frc); } .c-special { --cc: var(--spc); } .c-classic { --cc: var(--cls); }
.slot { background: var(--bg2); border: 1px solid var(--line); border-left: 5px solid var(--cc); border-radius: var(--r); }
.slotrow { display: flex; align-items: stretch; }
.slotbtn { flex: 1; display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 6px 10px; background: transparent; color: var(--ink); box-shadow: none; border-radius: var(--r) 0 0 var(--r);
  font-family: var(--display); font-size: 17px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; text-align: left; min-width: 0; }
:lang(th) .slotbtn { font-family: var(--body); font-weight: 700; text-transform: none; letter-spacing: 0; }
.slotbtn .rnw { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; }
.slotbtn .rn { line-height: 1.2; }
@media (max-width: 380px) { .slotbtn { font-size: 16px; gap: 8px; } }
.slot.swappable .slotbtn:active { background: var(--steel); }
.rg { color: var(--cc); width: 22px; height: 22px; }
.swapic { color: var(--mut); width: 18px; height: 18px; }
.advtag, .usedtag { font-family: var(--body); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--mut); border: 1px solid var(--line); border-radius: 6px; padding: 0 5px; flex: none; }
:lang(th) .advtag, :lang(th) .usedtag { text-transform: none; letter-spacing: 0; }
.infobtn { background: transparent; color: var(--mut); box-shadow: none; min-width: 48px; min-height: 48px; padding: 0; font-size: 20px; font-family: var(--body); text-transform: none; border-left: 1px solid var(--line); border-radius: 0 var(--r) var(--r) 0; }
.infobtn.on { color: var(--ink); background: var(--steel); }
.rtxt { margin: 0; padding: 0 12px 10px 42px; font-size: 14px; color: var(--ink); opacity: .9; }

/* sheets (swap menu; Task 14 reuses for prompts) */
/* the top 84 px (+ the safe area) stay clear of every sheet and prompt: the action announcer's banners slide in there */
.overlay { position: fixed; inset: 0; z-index: 50; background: rgba(5,6,8,.78); display: flex; align-items: flex-end; justify-content: center;
  padding: calc(84px + env(safe-area-inset-top, 0px)) 16px 16px; }
.sheet { width: 100%; max-width: 528px; max-height: 100%; overflow-y: auto; background: var(--bg2); border: 1px solid var(--line); border-top: 3px solid var(--red); border-radius: 14px; padding: 14px; box-shadow: 0 -10px 40px rgba(0,0,0,.6); }
.sheet-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.sheet h2 { font-family: var(--display); text-transform: uppercase; letter-spacing: .06em; font-size: 22px; margin: 0; }
:lang(th) .sheet h2 { font-family: var(--body); }
.sheet > p { margin: 4px 0 10px; }
.opts { display: flex; flex-direction: column; gap: 6px; }
.opt { background: var(--steel); color: var(--ink); border: 1px solid var(--line); border-left: 5px solid var(--cc); box-shadow: none; text-align: left; padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; min-height: 56px; text-transform: none; letter-spacing: 0; }
.opt .opth { display: flex; align-items: center; gap: 8px; font-family: var(--display); text-transform: uppercase; letter-spacing: .05em; font-size: 17px; font-weight: 600; }
:lang(th) .opt .opth { font-family: var(--body); text-transform: none; letter-spacing: 0; font-weight: 700; }
.opt .opth .rn { flex: 1; }
.opt .rtxt { padding: 0 0 0 30px; font-family: var(--body); font-weight: 400; font-size: 13px; }
.opt.on { border-color: var(--red2); border-left-color: var(--cc); }
.opt.on:disabled { opacity: 1; }
.okic { color: var(--ok); }

/* role chip (shared; Task 14 action sheet / cards) */
.rchip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 8px 2px 6px; border-radius: 999px; background: var(--bg2); border: 1px solid var(--cc); font-weight: 700; font-size: 14px; }
.rchip .rg { width: 16px; height: 16px; }

/* standings */
.lead-list { display: flex; flex-direction: column; }
.lead { display: flex; align-items: center; gap: 10px; padding: 7px 4px; border-bottom: 1px solid var(--line); font-size: 15px; }
.lead:last-child { border-bottom: 0; }
.lead.gone { opacity: .5; }
.lead .nm { flex: 1; }
.lead b { color: var(--ink); font-family: var(--display); }

/* ── the table ─────────────────────────────────────────────────────────── */
.c-gen { --cc: var(--ink); }
.who { color: var(--ink); font-weight: 700; }
.rl { display: inline; color: var(--cc); font-weight: 700; white-space: nowrap; }
.rl .rg { width: 1em; height: 1em; vertical-align: -.14em; margin: 0 2px 0 1px; }
.rl.c-classic, .rl.c-gen { color: var(--ink); }
.rl.c-classic .rg { color: #b9c2ce; }

/* player ring */
.seats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 8px 0; }
.seat { background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r); padding: 6px 8px; min-width: 0; position: relative; }
.seat.turn { border-color: var(--red2); box-shadow: 0 0 0 1px var(--red2), 0 0 14px var(--redglow); }
.seat.me { background: linear-gradient(180deg, rgba(200,32,47,.10), var(--bg2)); }
.seat.out { border-color: rgba(200,32,47,.45); }
.seat.out > :not(.seatstamp):not(.seat-d) { opacity: .5; filter: grayscale(1); }
.seat.away .seat-h .nm { color: var(--mut); }
.seat.wait::after { content: ""; position: absolute; top: 6px; right: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--warn); animation: pulse 1.2s infinite ease-in-out; }
.seat.tgt { border-style: dashed; border-color: var(--warn); }
.seat-h { display: flex; align-items: center; gap: 6px; min-width: 0; padding-right: 14px; }
.seat-h .nm { font-weight: 700; font-size: 14px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.youtag { font-style: normal; font-size: 11px; color: var(--mut); flex: none; }
.tgtic { color: var(--warn); width: 16px; height: 16px; }
.seat-b { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.coins { display: inline-flex; align-items: center; gap: 3px; color: #e8c15a; font-family: var(--display); font-size: 18px; min-width: 38px; }
.coins b { color: var(--ink); font-weight: 600; }
.cards { display: inline-flex; gap: 3px; flex-wrap: wrap; }
.cd { width: 18px; height: 26px; border-radius: 3px; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.cd.back { background: repeating-linear-gradient(45deg, #5a1219 0 3px, #7a1a24 3px 6px); border: 1px solid #a3333f; }
.cd.back.aside { opacity: .55; border-style: dashed; transform: rotate(8deg); }
.toks { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.tok { display: inline-flex; align-items: center; gap: 2px; font-size: 12px; font-weight: 700; padding: 1px 6px; border-radius: 999px; border: 1px solid var(--line); background: var(--steel); }
.tok .ic { width: 14px; height: 14px; }
.tok.peace { color: #8fd0ff; border-color: #3b7fd0; }
.tok.treaty { color: #f0d58a; border-color: #a88b3a; }
.tok.tax { color: var(--cc); border-color: var(--cc); max-width: 100%; }
.tok.tax .tn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tok.disp { color: #ff8a8f; border-color: var(--red); }
/* lost (dead) and out-of-play cards on a seat: one row, readable at 360 px */
.seat-d { display: flex; gap: 4px; margin-top: 6px; }
.dc { flex: 1 1 0; min-width: 0; max-width: 72px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.dci { position: relative; width: 34px; height: 46px; border-radius: 4px; background: var(--steel2); border: 1px solid var(--cc); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.dci .ic.rg { width: 20px; height: 20px; }
.dci.pic img.art { width: 100%; height: 100%; border-radius: 0; }
.dcn { font-size: 11px; font-weight: 700; line-height: 1.15; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--mut); }
.dc.dead .dci > :not(.strike) { filter: grayscale(1); opacity: .55; }
.dc.dead .dci { border-color: var(--line); }
.dc.dead .dcn { text-decoration: line-through; text-decoration-color: var(--red2); }
.strike { position: absolute; left: -6px; right: -6px; top: 50%; height: 3px; background: var(--red2); transform: rotate(-52deg); box-shadow: 0 0 4px rgba(0,0,0,.6); }
.dc.oop .dci { border-style: dashed; }
/* the ELIMINATED stamp: hand cards, eliminated seats */
.stamp { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(-24deg); z-index: 2; pointer-events: none;
  font-family: var(--display); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 14px; line-height: 1.1;
  color: var(--red2); border: 2px solid var(--red2); border-radius: 4px; padding: 2px 6px; background: rgba(13,14,16,.72); white-space: nowrap; box-shadow: 0 0 10px rgba(0,0,0,.6); }
:lang(th) .stamp { font-family: var(--body); letter-spacing: 0; text-transform: none; }
.seatstamp { font-size: 15px; top: 44%; transform: translate(-50%, -50%) rotate(-12deg); padding: 3px 10px; }

/* cards out: one chip per role in play (dead / total); the whole strip is one button */
.cobar { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; width: 100%; margin: 0 0 8px; padding: 4px; min-height: 52px;
  background: var(--bg2); border: 1px solid var(--line); box-shadow: none; color: var(--ink); text-transform: none; letter-spacing: 0; font-family: var(--body); font-weight: 400; }
.cochip { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 3px 2px; border-radius: 6px; border: 1px solid transparent; }
.coh { display: flex; align-items: center; gap: 3px; }
.cochip .ic.rg { width: 16px; height: 16px; }
.cochip img.art.rg { width: 15px; height: 20px; border-radius: 2px; }
.con { font-family: var(--display); font-size: 15px; font-weight: 600; color: var(--mut); }
.cochip.some .con { color: var(--ink); }
.cnm { font-size: 11px; font-weight: 700; color: var(--mut); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.2; }
.cochip.gone { background: var(--red); border-color: var(--red2); }
.cochip.gone .con, .cochip.gone .cnm, .cochip.gone .ic.rg { color: var(--red-ink); }
.colist { display: flex; flex-direction: column; gap: 6px; margin-bottom: 6px; }
.corow { display: flex; align-items: center; gap: 10px; background: var(--steel); border: 1px solid var(--line); border-left: 5px solid var(--cc); border-radius: var(--r); padding: 8px 12px; }
.corow .cot { display: flex; flex-direction: column; font-size: 14px; }
.corow .cot b { font-size: 16px; }
.corow.gone { border-color: var(--red2); background: rgba(200,32,47,.16); }
.cogone { color: var(--red-ink); background: var(--red); border-radius: 999px; padding: 0 7px; font-size: 12px; font-weight: 700; }

/* event area + window bar */
.event { background: linear-gradient(180deg, rgba(35,39,46,.95), rgba(22,24,28,.96)); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 10px 0; }
.ev-meta { display: flex; justify-content: space-between; font-size: 12px; color: var(--mut); font-family: var(--display); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 6px; }
:lang(th) .ev-meta { font-family: var(--body); letter-spacing: 0; }
.ev-act { margin: 0 0 6px; font-size: 14px; color: var(--mut); }
.ev-line { margin: 0; font-size: 16px; font-weight: 600; }
.eff { color: var(--mut); font-weight: 400; }
.waiting { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; font-size: 13px; color: var(--warn); }
.waiting > span { flex: 1 1 100%; }
.nudgebtn { padding: 4px 12px; font-size: 14px; min-height: 44px; }
.wbar { border-left: 4px solid var(--red); padding-left: 10px; }
.wbar.k-block { border-left-color: var(--warn); }
.wbar.k-claim, .wbar.k-join { border-left-color: var(--spc); }
.wtop { display: flex; align-items: center; gap: 10px; }
.wtxt { flex: 1; font-size: 16px; line-height: 1.4; }
.wq { color: var(--warn); font-weight: 700; }
.wnote { margin: 6px 0 0; font-size: 12px; color: var(--mut); }
.wbtns { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.wbtns > button { flex: 1 1 40%; padding: 10px 8px; font-size: 16px; }
.wbtns button.chal { background: linear-gradient(180deg, var(--red2), var(--red)); }
.wbtns button.blk { background: var(--steel); color: var(--ink); border: 1px solid var(--cc); border-left: 5px solid var(--cc); box-shadow: none; flex-basis: 100%; }
.wbtns button.blk .rg { color: var(--cc); }
.wdone, .wwait { margin: 0; color: var(--mut); font-weight: 700; font-size: 14px; }
.wdone { color: var(--ok); }
.wdots { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.wdot { position: relative; opacity: .35; }
.wdot.on { opacity: 1; }
.wdot .av { border-color: var(--line); }
.wdot.on .av { border-color: var(--ok); box-shadow: 0 0 6px rgba(111,191,115,.5); }
.wdot .dk { position: absolute; right: -4px; bottom: -3px; width: 13px; height: 13px; color: var(--ok); background: var(--bg); border-radius: 50%; }

/* countdown ring: registered properties animated per element from the window's local deadline (no timers) */
@property --f { syntax: "<number>"; inherits: false; initial-value: 1; }
@property --s { syntax: "<integer>"; inherits: true; initial-value: 10; }
.cring { width: 46px; height: 46px; flex: none; border-radius: 50%; position: relative; display: inline-flex; align-items: center; justify-content: center;
  background: conic-gradient(var(--red2) calc(var(--f) * 1turn), var(--steel2) 0); }   /* animated from app.js (armRings, Web Animations) */
.cring::before { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: var(--bg2); }
.cring::after { position: relative; counter-reset: s var(--s); content: counter(s); font-family: var(--display); font-weight: 700; font-size: 17px; color: var(--ink); }

/* last challenge */
.lcbar { border: 1px solid var(--line); border-radius: var(--r); padding: 8px 12px; margin: 8px 0; font-size: 14px; background: var(--bg2); }
.lcbar.lc_shown { border-left: 4px solid var(--ok); }
.lcbar.lc_no { border-left: 4px solid var(--red2); }
.lcbar.lc_pending { border-left: 4px solid var(--warn); }

/* your hand */
.hrow { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center; }
.hand .hcards { display: flex; gap: 10px; justify-content: center; background: transparent; box-shadow: none; padding: 4px; min-height: 120px; text-transform: none; letter-spacing: 0; }
.bcard.dead, .bcard.oop { position: relative; margin: 4px 0; }
.bcard.dead { border-color: var(--line); border-top-color: var(--line); }
.bcard.dead > :not(.stamp) { filter: grayscale(1); opacity: .62; }
.bcard.dead .stamp { top: 38%; }
.bcard.oop { border-style: dashed; }
.ootag { font-family: var(--body); font-size: 11px; font-weight: 700; color: var(--mut); border: 1px solid var(--line); border-radius: 999px; padding: 0 7px; background: var(--bg); position: relative; z-index: 1; }
.bclbl { font-family: var(--body); font-size: 11px; font-weight: 700; color: var(--ink); background: rgba(13,14,16,.75); border-radius: 999px; padding: 0 7px; position: relative; z-index: 1; }
@media (max-width: 400px) { .hrow.many .bcard { width: 84px; height: 116px; } .hrow.many { gap: 8px; } .hrow.many .hcards { gap: 8px; } }
/* your own cards are the showcase: big 3:4 cards (two side by side fill ~80% of a phone's width); more than two
   (a set-aside or out-of-play card in G54) shrink to fit one row. Only the hand panel — everywhere else keeps .bcard's size. */
.hand .hrow { gap: 12px; }
.hand .hrow .hcards { gap: 12px; min-height: 0; padding: 2px; }
/* width from the room actually left: viewport (max 560) − app padding 32 − panel padding+border 30 − gap and peek-button padding ≈ 86 */
.hand .hrow .bcard { width: clamp(112px, calc((min(100vw, 560px) - 86px) / 2), 176px); height: auto; aspect-ratio: 3 / 4; border-radius: 14px; }
.hand .hrow.many .bcard { width: clamp(84px, calc((min(100vw, 560px) - 104px) / 3), 118px); border-radius: 11px; }
.hand .hrow .bcard.back .ic { width: 52px; height: 52px; }
.hand .hrow.many .bcard.back .ic { width: 38px; height: 38px; }
.hand .hrow .bcard.face .rg { width: 52px; height: 52px; }
.hand .hrow .bcard .bn, .hand .hrow .bcard.face.pic .bn { font-size: 18px; }
.hand .hrow.many .bcard .bn, .hand .hrow.many .bcard.face.pic .bn { font-size: 14px; }
.hand .hrow .bcard.face.pic .bn { padding-top: 6px; }
.hand .hrow .bcard.face.pic .bc { padding-bottom: 6px; font-size: 12px; }
.hand .hrow .bcard .stamp { font-size: 20px; padding: 3px 9px; border-width: 3px; }
.hand .hrow.many .bcard .stamp { font-size: 14px; padding: 2px 6px; border-width: 2px; }
@media (max-width: 400px) { .hand .hrow.many .bcard { width: clamp(84px, calc((100vw - 104px) / 3), 110px); height: auto; } }
.bcard { width: 96px; height: 132px; border-radius: 10px; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; flex: none; }
.bcard.back { background: repeating-linear-gradient(45deg, #4a0f15 0 6px, #6e1720 6px 12px); border: 2px solid #a3333f; color: rgba(255,244,242,.35); }
.bcard.back .ic { width: 34px; height: 34px; }
.bcard.back.aside { opacity: .6; border-style: dashed; }
.bcard.face { background: linear-gradient(180deg, var(--steel2), var(--bg2)); border: 2px solid var(--cc); border-top-width: 8px; color: var(--ink); padding: 6px; }
.bcard.face .rg { width: 34px; height: 34px; }
.bcard .bn { font-family: var(--display); font-weight: 700; font-size: 15px; text-transform: uppercase; letter-spacing: .04em; text-align: center; line-height: 1.15; }
:lang(th) .bcard .bn { font-family: var(--body); text-transform: none; letter-spacing: 0; }
.bcard .bc { font-family: var(--body); font-size: 11px; color: var(--cc); font-weight: 700; }
.peekhint { margin: 4px 0 0; }

/* action sheet */
.aopts { display: flex; flex-direction: column; gap: 6px; }
.aopt { background: var(--steel); color: var(--ink); border: 1px solid var(--line); border-left: 5px solid var(--cc); box-shadow: none; text-align: left; padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; min-height: 56px; text-transform: none; letter-spacing: 0; }
.aopt .aoh { display: flex; align-items: center; gap: 8px; font-family: var(--display); text-transform: uppercase; letter-spacing: .05em; font-size: 17px; font-weight: 600; }
:lang(th) .aopt .aoh { font-family: var(--body); text-transform: none; letter-spacing: 0; font-weight: 700; }
.aopt .aoh .rn { flex: 1; }
.aopt .rtxt { padding: 0 0 0 30px; font-family: var(--body); font-weight: 400; font-size: 13px; }
.aopt .why, .popt .why { font-family: var(--body); font-size: 12px; font-weight: 700; color: var(--warn); padding-left: 30px; text-transform: none; letter-spacing: 0; }
.aopt:disabled { opacity: .45; }
.cost { font-family: var(--display); font-size: 15px; color: #e8c15a; flex: none; }
:lang(th) .cost { font-family: var(--body); }
.taxt { color: var(--warn); font-size: 12px; font-family: var(--body); font-weight: 700; }
.clearbtn { margin: 0 0 10px; }
.dline { display: flex; align-items: center; gap: 10px; font-size: 20px; margin: 6px 0 2px; }
.pick { margin: 12px 0; }
.popts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.popt { background: var(--steel); color: var(--ink); border: 1px solid var(--line); box-shadow: none; padding: 6px 10px; min-height: 48px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; text-align: left; font-family: var(--body); text-transform: none; letter-spacing: 0; font-size: 15px; font-weight: 700; }
.popt .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.popt .pc { color: #e8c15a; font-size: 13px; display: inline-flex; align-items: center; gap: 2px; }
.popt .why { padding-left: 0; flex-basis: 100%; }
.popt.on { border: 2px solid var(--red2); background: rgba(200,32,47,.18); }
.popts.roles .popt { border-left: 5px solid var(--cc); }
.popts.roles .rg { color: var(--cc); }

/* prompts: full-screen, mandatory (no backdrop close) */
.overlay.prompt { background: rgba(5,6,8,.72); }
.overlay.prompt .sheet { border-top-color: var(--warn); box-shadow: 0 -16px 50px rgba(0,0,0,.75); }
.overlay.prompt .sheet > p { font-size: 16px; }
.pcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin: 8px 0; }
.pcard { min-height: 96px; background: linear-gradient(180deg, var(--steel2), var(--bg2)); color: var(--ink); border: 2px solid var(--line); border-top: 6px solid var(--cc); box-shadow: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 8px 4px; position: relative; text-transform: none; letter-spacing: 0; }
.pcard .rg { width: 28px; height: 28px; }
.pcard .bn { font-family: var(--display); font-weight: 700; font-size: 15px; text-transform: uppercase; letter-spacing: .04em; }
:lang(th) .pcard .bn { font-family: var(--body); text-transform: none; letter-spacing: 0; }
.pcard .ctag { font-family: var(--body); font-size: 11px; color: var(--warn); font-weight: 700; }
.pcard.on { border-color: var(--red2); box-shadow: 0 0 0 1px var(--red2), 0 0 12px var(--redglow); }
.pcard .okic { position: absolute; top: 6px; right: 6px; width: 18px; height: 18px; }
.react { border-left: 5px solid var(--cc) !important; }
.react .rg { color: var(--cc); width: 20px; height: 20px; }
.sheet .tag { margin-top: 10px; }

/* nudge: the staller's screen flashes */
.nudgeflash { position: fixed; inset: 0; z-index: 80; pointer-events: none; border: 6px solid var(--warn); box-shadow: inset 0 0 60px rgba(227,163,59,.6); opacity: 0; animation: nudge .45s ease-in-out 4; }
@keyframes nudge { 0%, 100% { opacity: 0; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .nudgeflash { animation: nudge 1.6s ease-in-out 1; } }

/* dock + log + sheets */
.dock { display: flex; gap: 6px; margin: 12px 0; }
.dock button { flex: 1; padding: 8px 6px; font-size: 14px; }
.log { margin: 0; padding: 0; list-style: none; font-size: 13px; }
.log li { padding: 4px 0; border-bottom: 1px solid rgba(53,59,69,.6); }
.log li:last-child { border-bottom: 0; }
.log li.lg-turn { color: var(--mut); font-family: var(--display); letter-spacing: .06em; text-transform: uppercase; font-size: 12px; padding-top: 8px; }
:lang(th) .log li.lg-turn { font-family: var(--body); letter-spacing: 0; }
.log li.lg-lose, .log li.lg-out, .log li.lg-left { color: #ffb3b7; }
.log li.lg-win { color: var(--ok); font-weight: 700; }
.log.full { margin-bottom: 10px; }
.rcard { background: var(--steel); border: 1px solid var(--line); border-left: 5px solid var(--cc); border-radius: var(--r); padding: 8px 12px; margin: 6px 0; }
.rcard .rch { display: flex; align-items: center; gap: 10px; font-size: 17px; }
.rcard .rch .rl { flex: 1; }
.rcard p { margin: 4px 0 0; font-size: 14px; }
.catlbl { font-size: 11px; font-weight: 700; color: var(--cc); text-transform: uppercase; letter-spacing: .06em; }
:lang(th) .catlbl { text-transform: none; letter-spacing: 0; }
.toklegend p { margin: 4px 0; font-size: 14px; }
/* How to play: a walkthrough of 6 cards (big type, works at 360 px) */
.htdeck { min-height: 380px; background: var(--steel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; touch-action: pan-y; }
.htdeck h3 { font-family: var(--display); font-size: 26px; line-height: 1.15; text-transform: uppercase; letter-spacing: .04em; margin: 8px 0 10px; color: var(--ink); }
:lang(th) .htdeck h3 { font-family: var(--body); text-transform: none; letter-spacing: 0; font-size: 24px; }
.htdeck p { font-size: 17px; line-height: 1.5; margin: 8px 0; }
.htill { display: flex; justify-content: center; align-items: center; gap: 12px; margin: 6px 0 4px; min-height: 110px; position: relative; }
.bcard.mini { width: 72px; height: 100px; border-radius: 8px; gap: 4px; position: relative; }
.bcard.mini .bn { font-size: 12px; }
.bcard.mini .rg, .bcard.back.mini .ic { width: 26px; height: 26px; }
.bcard.mini .stamp { font-size: 11px; padding: 1px 4px; top: 40%; }
.bcard.mini.dead > :not(.stamp) { filter: grayscale(1); opacity: .62; }
.bcard.mini.dead { border-color: var(--line); }
.htq { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 40px; font-weight: 700; color: var(--ink); text-shadow: 0 2px 8px #000; }
.htbubble { position: relative; background: var(--ink); color: var(--bg); font-weight: 700; font-size: 17px; border-radius: 14px; padding: 10px 14px; max-width: 60%; }
.htbubble::before { content: ""; position: absolute; left: -8px; top: 50%; margin-top: -8px; border: 8px solid transparent; border-left: 0; border-right-color: var(--ink); }
.htbubble .rl, .htbubble .rl.c-classic { color: var(--bg); }
.htbubble .rl .rg { color: var(--red); }
.htmenu { display: flex; flex-direction: column; gap: 4px; margin: 6px 0; }
.htopt b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.htopt .htfx { flex: none; font-size: 14px; }
.htopt { display: flex; align-items: center; gap: 8px; min-height: 38px; white-space: nowrap; background: var(--bg2); border: 1px solid var(--line); border-left: 4px solid var(--cc); border-radius: 8px; padding: 5px 10px; font-size: 15px; line-height: 1.3; }
.htopt b { font-family: var(--display); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
:lang(th) .htopt b { font-family: var(--body); text-transform: none; letter-spacing: 0; font-weight: 700; }
.htopt .ic.rg { width: 20px; height: 20px; }
.htex { display: flex; flex-direction: column; gap: 4px; }
.htline { font-weight: 600; }
.htrow { display: flex; align-items: center; gap: 12px; }
.htrow p { flex: 1; }
.htalt { color: var(--mut); font-size: 15px !important; border-top: 1px dashed var(--line); padding-top: 8px; }
.htkey { color: var(--warn); font-weight: 700; }
.htwho { color: #f0d58a; }
.htstamp { color: var(--red2); border: 2px solid var(--red2); border-radius: 4px; padding: 0 5px; text-transform: uppercase; font-family: var(--display); letter-spacing: .06em; white-space: nowrap; }
:lang(th) .htstamp { font-family: var(--body); text-transform: none; letter-spacing: 0; }
.htdots { display: flex; justify-content: center; gap: 8px; margin: 12px 0 2px; }
.htdot { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.htdot.on { background: var(--red2); box-shadow: 0 0 6px var(--redglow); }
.htn { margin: 2px 0 6px; }
.htnav { display: flex; gap: 8px; }
.htnav button { flex: 1; font-size: 19px; padding: 12px; }

/* game over */
.winner .av { width: 64px; height: 64px; font-size: 36px; filter: none; }
.winner h2 { font-family: var(--display); font-size: 28px; margin: 4px 0; text-transform: uppercase; letter-spacing: .06em; }
:lang(th) .winner h2 { font-family: var(--body); letter-spacing: 0; }
.rvl { display: flex; flex-direction: column; gap: 6px; }
.rvrow { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.rvrow:last-child { border-bottom: 0; }
.rvrow.win .nm { color: var(--ok); }
.rvrow .nm { font-weight: 700; min-width: 70px; }
.rvcards { display: flex; flex-wrap: wrap; gap: 4px; flex: 1; }
.mcard { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px 2px 6px; border-radius: 6px; border: 1px solid var(--cc); font-size: 13px; font-weight: 700; background: var(--steel); }
.mcard .rg { width: 15px; height: 15px; }
.mcard.lost { border-color: var(--line); color: var(--mut); }
.mcard.lost > span:not(.mstamp) { text-decoration: line-through; text-decoration-color: var(--red2); }
.mcard.lost > :not(.mstamp) { filter: grayscale(1); opacity: .6; }
.mstamp { font-family: var(--display); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--red2); border: 1px solid var(--red2); border-radius: 3px; padding: 0 3px; transform: rotate(-6deg); text-decoration: none; display: inline-block; }
:lang(th) .mstamp { font-family: var(--body); letter-spacing: 0; text-transform: none; }
.mcard.aside, .mcard.oop { border-style: dashed; }
.legend { margin: 8px 0 0; }
.lgk { display: inline-block; width: 12px; height: 12px; border-radius: 3px; border: 1px solid var(--ink); margin: 0 4px -1px 8px; }
.lgk.lost { opacity: .5; } .lgk.aside, .lgk.oop { border-style: dashed; }

/* optional character art (assets/art/manifest.json): a portrait replaces the icon where it is set; with no
   manifest none of these rules match anything. Portraits are 3:4. */
img.art { display: block; object-fit: cover; object-position: 50% 20%; flex: none; border-radius: 4px; background: var(--bg); }
img.art.rg { width: 30px; height: 40px; }
.slotbtn img.art.rg, .opt .opth img.art.rg { width: 30px; height: 40px; margin: 2px 0; }
.mcard img.art.rg { width: 18px; height: 24px; border-radius: 3px; }
.pcard img.art.rg { width: 54px; height: 72px; border-radius: 6px; }
.cd.pic { overflow: hidden; padding: 0; }
.cd.pic img.art { width: 100%; height: 100%; border-radius: 0; }
.bcard.pic { position: relative; overflow: hidden; padding: 0; justify-content: flex-end; gap: 0; }
.bcard.pic img.cimg { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 0; }
.bcard.face.pic .bn, .bcard.face.pic .bc { position: relative; z-index: 1; width: 100%; text-align: center; background: rgba(13,14,16,.82); padding: 1px 4px; }
.bcard.face.pic .bn { padding-top: 4px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bcard.face.pic .bc { padding-bottom: 4px; }
.rcard.pic { display: grid; grid-template-columns: 48px 1fr; column-gap: 10px; align-items: start; }
.rcard.pic img.rthumb { grid-row: 1 / span 2; width: 48px; height: 64px; }
.rcard.pic > p { grid-column: 2; }

/* dev table: a read-only seat may look but never act */
.readonly [data-act]:not([data-look]) { pointer-events: none; }

/* ── the action announcer (app.js annLayer): a fixed layer beside the app, outside morph; never takes taps
   except a splash while it is up (tap anywhere to close it). Banners: top band (bottom when the window bar's
   buttons sit under it). Splash: a centred card, only on a phone with no open decision. ── */
.annlayer { position: fixed; inset: 0; z-index: 70; pointer-events: none; font-family: var(--body); }
/* measured by app.js (annBand): the band banners use, the same height .overlay keeps clear */
.annsafe { position: absolute; top: 0; left: 0; width: 1px; height: calc(84px + env(safe-area-inset-top, 0px)); visibility: hidden; }
.annb { position: absolute; left: 50%; top: calc(8px + env(safe-area-inset-top, 0px)); width: min(528px, calc(100% - 32px));
  transform: translateX(-50%); display: flex; align-items: center; gap: 10px; min-height: 56px; max-height: 70px; padding: 6px 12px 6px 6px;
  background: rgba(24,26,31,.97); border: 1px solid var(--line); border-left: 4px solid var(--red); border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,.65); font-size: 15px; line-height: 1.3; color: var(--ink); animation: annDown .3s cubic-bezier(.2,1.2,.4,1) both; }
.annb.bottom { top: auto; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); animation-name: annUp; }
.annb.steady, .anns.steady, .anns.steady .annscard { animation: none; }   /* redrawn in place: no second entrance */
.annb.out { animation: annLeaveUp .24s ease-in both; }
.annb.bottom.out { animation-name: annLeaveDown; }
.annb.big { border-left-color: var(--warn); }
.annb.big.k-coup, .annb.big.k-bad, .annb.big.k-lose, .annb.big.k-out { border-left-color: var(--red2); }
.annb.big.k-ok { border-left-color: var(--ok); }
.annb .av { flex: none; }
.annpic { position: relative; flex: none; width: 33px; height: 44px; border-radius: 5px; overflow: hidden; border: 1px solid var(--cc); background: var(--steel2);
  display: flex; align-items: center; justify-content: center; }
.annpic img.art.rg { width: 100%; height: 100%; border-radius: 0; }
.annpic .ic.rg { width: 22px; height: 22px; color: var(--cc); }
.anntx { min-width: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.annarr, .annsep { color: var(--mut); font-weight: 700; }
.anns { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: calc(84px + env(safe-area-inset-top, 0px)) 16px 24px; pointer-events: auto;
  cursor: pointer; background: radial-gradient(ellipse at 50% 45%, rgba(5,6,8,.35), rgba(5,6,8,.78)); animation: annFade .2s ease-out both; }
.anns.out, .anns.steady.out { pointer-events: none; animation: annFadeOut .26s ease-in both; }
.annscard { width: min(340px, 100%); text-align: center; color: var(--ink); background: linear-gradient(180deg, #1f2228, #121418);
  border: 1px solid var(--line); border-top: 4px solid var(--warn); border-radius: 18px; padding: 16px 16px 12px;
  box-shadow: 0 24px 70px rgba(0,0,0,.8); animation: annPop .5s cubic-bezier(.2,1.5,.35,1) both; }
.annscard.k-coup { border-top-color: var(--red2); box-shadow: 0 24px 70px rgba(0,0,0,.8), 0 0 46px var(--redglow); animation-name: annSlam; }
.annscard.k-bad, .annscard.k-lose, .annscard.k-out { border-top-color: var(--red2); }
.annscard.k-ok { border-top-color: var(--ok); }
.annscard.k-win { border-top-color: #e8c15a; box-shadow: 0 24px 70px rgba(0,0,0,.8), 0 0 50px rgba(232,193,90,.35); }
.annport { position: relative; display: block; width: 156px; height: 208px; margin: 0 auto 10px; border-radius: 12px; overflow: hidden;
  border: 2px solid var(--cc); background: var(--steel2); box-shadow: 0 10px 26px rgba(0,0,0,.6); }
.annport img.cimg { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 0; }
.annport > .ic.rg { position: absolute; left: 50%; top: 50%; width: 80px; height: 80px; transform: translate(-50%, -50%); color: var(--cc); }
/* a lost card: grey + ELIMINATED; a claim caught bluffing: grey + ✗ (never reads as a card someone holds) */
.annport.dead img, .annport.dead > .ic, .annport.bad img, .annport.bad > .ic,
.annpic.dead img, .annpic.dead > .ic, .annpic.bad img, .annpic.bad > .ic { filter: grayscale(1); opacity: .6; }
.annx { position: absolute; right: 8px; top: 8px; z-index: 2; width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; background: var(--red2); color: #fff; font-size: 26px; font-weight: 700; line-height: 1; box-shadow: 0 2px 10px rgba(0,0,0,.6); }
.annpic .annx { right: 1px; top: auto; bottom: 1px; width: 16px; height: 16px; font-size: 11px; box-shadow: none; }
.annvs { font-family: var(--display); font-weight: 700; font-size: 15px; letter-spacing: .06em; color: var(--warn); border: 1px solid var(--warn);
  border-radius: 6px; padding: 0 5px; line-height: 1.4; }
.annport .stamp { font-size: 18px; }
.annbig { display: flex; align-items: center; justify-content: center; width: 92px; height: 92px; margin: 2px auto 10px; border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, #3a3f48, #1a1d22); border: 2px solid var(--line); }
.annbig .ic { width: 52px; height: 52px; color: var(--ink); }
.k-coup .annbig { border-color: var(--red2); } .k-coup .annbig .ic { color: var(--red2); }
.k-win .annbig { border-color: #e8c15a; } .k-win .annbig .ic { color: #e8c15a; }
.k-out .annbig .ic { color: var(--red2); }
.annavs { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 0 8px; }
.annavs .annto { width: 18px; height: 18px; color: var(--warn); }
.anntitle { font-family: var(--display); font-size: 26px; font-weight: 700; line-height: 1.15; text-transform: uppercase; letter-spacing: .03em; }
:lang(th) .anntitle { font-family: var(--body); text-transform: none; letter-spacing: 0; font-size: 22px; line-height: 1.4; }
.anntitle .rl .rg { display: none; }
.annsub { margin-top: 6px; font-size: 16px; line-height: 1.35; }
.annhint { margin-top: 10px; font-size: 12px; color: var(--mut); }
@keyframes annDown { from { transform: translate(-50%, -140%); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes annUp { from { transform: translate(-50%, 140%); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes annLeaveUp { to { transform: translate(-50%, -60%); opacity: 0; } }
@keyframes annLeaveDown { to { transform: translate(-50%, 60%); opacity: 0; } }
@keyframes annFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes annFadeOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes annPop { 0% { transform: scale(.55) rotate(-4deg); opacity: 0; } 60% { transform: scale(1.06) rotate(1deg); opacity: 1; } 100% { transform: none; opacity: 1; } }
@keyframes annSlam { 0% { transform: scale(1.9); opacity: 0; } 55% { transform: scale(.94); opacity: 1; } 70% { transform: translateX(-6px); } 82% { transform: translateX(5px); } 100% { transform: none; opacity: 1; } }
/* reduced motion: fades only, nothing moves */
@media (prefers-reduced-motion: reduce) {
  .annb, .annb.bottom { animation: annFade .2s ease-out both; }
  .annb.out, .annb.bottom.out { animation: annFadeOut .2s ease-in both; }
  .annscard, .annscard.k-coup { animation: annFade .2s ease-out both; }
  .annb.steady:not(.out), .anns.steady .annscard { animation: none; }
}
