/* The Wick Casino — base styles */
:root {
  --bg: #0a0e14;
  --bg2: #0f141c;
  --panel: #131a24;
  --panel2: #19222f;
  --panel3: #212c3b;
  --border: #263244;
  --border2: #33425a;
  --text: #e8edf4;
  --muted: #8d9bb0;
  --dim: #5f6d82;
  --gold: #f4c25b;
  --gold2: #d9a43a;
  --green: #35d07f;
  --green-d: #1f9c5c;
  --red: #ff5f6d;
  --blue: #59a8ff;
  --purple: #a77bff;
  --orange: #ff9f43;
  --teal: #2fd4c4;
  --felt1: #1d7b4d;
  --felt2: #0d4b2d;
  --felt-line: rgba(255, 255, 255, .24);
  /* cards scale with the viewport so tables fill the available space */
  --cw: clamp(62px, min(5.3vw, 9.6vh), 122px);
  --ch: calc(var(--cw) * 1.42);
  --radius: 12px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .45);
  --font: 'Segoe UI', 'Inter', system-ui, -apple-system, Roboto, sans-serif;
  --mono: 'Cascadia Code', 'Consolas', 'SFMono-Regular', monospace;
  --odds-w: 420px;
}
body.odds-wide { --odds-w: 560px; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font-family: var(--font); font-size: 14px; }
body { overflow: hidden; }
button { font-family: inherit; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #2a3546; border-radius: 6px; border: 2px solid var(--bg2); }
a { color: var(--blue); }
b, strong { font-weight: 650; }

/* ---------- App shell ---------- */
#app { display: grid; grid-template-columns: 204px minmax(0, 1fr); grid-template-rows: 48px minmax(0, 1fr); height: 100vh; transition: grid-template-columns .18s ease; }
body.nav-mini #app { grid-template-columns: 54px minmax(0, 1fr); }
.topbar { grid-column: 1 / 3; display: flex; align-items: center; gap: 12px; padding: 0 12px; background: linear-gradient(180deg, #121925, #0e141d); border-bottom: 1px solid var(--border); z-index: 5; }
.nav-toggle { flex: none; font-size: 16px; padding: 5px 8px; border: 1px solid var(--border); background: var(--panel2); color: var(--muted); border-radius: 8px; }
.nav-toggle:hover { color: var(--gold); border-color: var(--border2); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 16px; letter-spacing: .2px; flex: none; }
.brand-logo { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: conic-gradient(from 45deg, var(--gold), #ff7b54, var(--purple), var(--teal), var(--gold)); color: #111; font-size: 16px; box-shadow: 0 0 14px rgba(244, 194, 91, .3); }
.brand small { display: block; font-size: 9px; font-weight: 600; letter-spacing: 1.8px; color: var(--muted); text-transform: uppercase; line-height: 1.1; }
.topbar .spacer { flex: 1; }
.wallet-box { display: flex; align-items: center; gap: 4px; background: var(--panel2); border: 1px solid var(--border); border-radius: 10px; padding: 3px 5px 3px 11px; flex: none; }
.wallet-box .wb-item { display: flex; flex-direction: column; padding: 0 10px 0 0; margin-right: 6px; border-right: 1px solid var(--border); line-height: 1.15; }
.wallet-box .wb-item:last-of-type { border-right: 0; }
.wb-label { font-size: 9px; text-transform: uppercase; letter-spacing: 1.1px; color: var(--muted); }
.wb-value { font-size: 15px; font-weight: 750; font-variant-numeric: tabular-nums; }
.wb-value.bal { color: var(--gold); }
.wb-value.pos { color: var(--green); }
.wb-value.neg { color: var(--red); }
/* Recent results strip */
.hist-strip { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 4px 0 6px; background: var(--panel2); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
select.hs-n { flex: none; padding: 3px 5px; font-size: 11.5px; background: var(--panel3); border-radius: 6px; }
.hs-sum { flex: none; display: flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--muted); font-size: 11.5px; cursor: pointer; padding: 3px 4px; border-radius: 6px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hs-sum:hover { background: var(--panel3); color: var(--text); }
.hs-scope { font-weight: 700; color: #c7d1de; text-transform: uppercase; letter-spacing: .7px; font-size: 10px; }
.hs-net { font-size: 12px; color: var(--text); }
.hs-pills { flex: 1; min-width: 0; display: flex; gap: 4px; overflow: hidden; cursor: pointer; mask-image: linear-gradient(90deg, #000 85%, transparent); -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); }
.hs-pill { flex: none; display: inline-flex; align-items: center; gap: 3px; height: 22px; min-width: 40px; justify-content: center; padding: 0 6px; border-radius: 6px; font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; border: 1px solid; }
.hs-pill i { font-style: normal; opacity: .75; }
.hs-pill.win { background: rgba(53, 208, 127, .14); border-color: rgba(53, 208, 127, .45); color: #8ff0bd; }
.hs-pill.lose { background: rgba(255, 95, 109, .11); border-color: rgba(255, 95, 109, .4); color: #ffb3ba; }
.hs-pill.push { background: rgba(89, 168, 255, .1); border-color: rgba(89, 168, 255, .35); color: #a9d4ff; }
.hs-pill:first-child { box-shadow: 0 0 0 1px rgba(255, 255, 255, .25); }
.hs-table .hs-d { color: var(--muted); font-size: 12px; }
.hs-table td:last-child { text-align: left; white-space: normal; }
@media (max-width: 1400px) { .hs-scope { display: none; } }
.balance-bump { animation: bump .5s; }
@keyframes bump { 30% { transform: scale(1.12); } }

.sidebar { background: var(--bg2); border-right: 1px solid var(--border); padding: 8px 6px; overflow-y: auto; overflow-x: hidden; }
.nav-group { font-size: 9.5px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--dim); margin: 12px 8px 4px; white-space: nowrap; }
.nav-item { display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 9px; color: var(--muted); cursor: pointer; font-weight: 600; user-select: none; transition: background .15s, color .15s; font-size: 13.5px; white-space: nowrap; }
.nav-item:hover { background: var(--panel); color: var(--text); }
.nav-item.active { background: linear-gradient(90deg, rgba(244, 194, 91, .16), rgba(244, 194, 91, .03)); color: var(--gold); box-shadow: inset 3px 0 0 var(--gold); }
.nav-ico { width: 22px; text-align: center; font-size: 16px; flex: none; }
.nav-lbl { overflow: hidden; text-overflow: ellipsis; }
.nav-he { margin-left: auto; font-size: 10px; color: var(--dim); font-variant-numeric: tabular-nums; }
body.nav-mini .sidebar { padding: 8px 5px; }
body.nav-mini .nav-group { height: 1px; margin: 7px 6px; padding: 0; background: var(--border); color: transparent; overflow: hidden; }
body.nav-mini .nav-lbl, body.nav-mini .nav-he { display: none; }
body.nav-mini .nav-item { justify-content: center; padding: 9px 0; }
body.nav-mini .nav-item.active { box-shadow: inset 3px 0 0 var(--gold); }

main#main { position: relative; overflow: hidden; min-height: 0; }
.view { position: absolute; inset: 0; overflow: hidden; }
.view[hidden] { display: none !important; }
.view.scroll { overflow-y: auto; }

/* ---------- Buttons ---------- */
.btn { border: 1px solid var(--border2); background: var(--panel3); color: var(--text); padding: 9px 16px; border-radius: 10px; font-weight: 650; font-size: 13.5px; cursor: pointer; transition: transform .08s, background .15s, box-shadow .15s, opacity .15s, filter .15s; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 7px; line-height: 1.2; }
.btn:hover:not(:disabled) { background: #2a384b; filter: brightness(1.08); }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.btn:disabled { opacity: .35; cursor: not-allowed; }
.btn.primary { background: linear-gradient(180deg, #ffd577, var(--gold2)); color: #2a1d00; border-color: #c58f22; box-shadow: 0 4px 14px rgba(244, 194, 91, .25); }
.btn.primary:hover:not(:disabled) { background: linear-gradient(180deg, #ffe08f, #e5b048); }
.btn.green { background: linear-gradient(180deg, #43dd8c, #1f9c5c); border-color: #188049; color: #04220f; }
.btn.red { background: linear-gradient(180deg, #ff7d88, #d8404f); border-color: #b02f3c; color: #2b0006; }
.btn.blue { background: linear-gradient(180deg, #7bbcff, #3b82d6); border-color: #2f6db5; color: #021a33; }
.btn.purple { background: linear-gradient(180deg, #c3a3ff, #7c4ddb); border-color: #6438bf; color: #14002e; }
.btn.ghost { background: transparent; }
.btn.sm { padding: 6px 11px; font-size: 12.5px; border-radius: 8px; }
.btn.lg { padding: 12px 24px; font-size: 15px; border-radius: 12px; }
/* Main action buttons: crisp, high-contrast, keyboard hint */
.btn.xl { padding: 0 18px; min-height: 44px; min-width: 98px; font-size: 15.5px; font-weight: 750; border-radius: 12px; letter-spacing: .2px; box-shadow: 0 4px 14px rgba(0, 0, 0, .35); }
.btn.xl:not(.primary):not(.green):not(.red):not(.blue):not(.purple) { background: linear-gradient(180deg, #34445a, #26323f); }
/* Secondary controls (undo/clear, analysis tools) */
.btn.ctl { padding: 6px 10px; font-size: 12.5px; border-radius: 8px; background: var(--panel2); }
.btn.ctl:hover:not(:disabled) { background: var(--panel3); border-color: #4a5d7a; }
.btn.ctl.red { background: rgba(255, 95, 109, .12); color: #ffb3ba; border-color: rgba(255, 95, 109, .4); }
.head-btn { padding: 5px 9px; font-size: 12px; border-radius: 8px; background: var(--panel2); gap: 5px; }
.head-btn.accent { background: linear-gradient(180deg, rgba(244, 194, 91, .24), rgba(244, 194, 91, .09)); border-color: rgba(244, 194, 91, .55); color: #ffe1a1; }
.btn.recommended { box-shadow: 0 0 0 3px var(--gold), 0 0 24px rgba(244, 194, 91, .6); position: relative; }
.btn.recommended::after { content: '★ best'; position: absolute; top: -11px; right: -6px; background: var(--gold); color: #2a1d00; font-size: 10px; font-weight: 850; padding: 2px 6px; border-radius: 8px; letter-spacing: .3px; }
kbd { font-family: var(--mono); font-size: 10px; font-weight: 700; padding: 1px 4px; border-radius: 4px; background: rgba(0, 0, 0, .22); border: 1px solid rgba(0, 0, 0, .25); box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25); opacity: .8; color: inherit; }
.btn:not(.primary):not(.green):not(.red):not(.blue):not(.purple) kbd { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .16); }
.icon-btn { background: transparent; border: 0; color: var(--muted); font-size: 15px; cursor: pointer; padding: 5px 7px; border-radius: 7px; }
.icon-btn:hover:not(:disabled) { background: var(--panel3); color: var(--text); }
.icon-btn:disabled { opacity: .3; cursor: default; }
select, input[type=number], input[type=text] { background: var(--panel3); color: var(--text); border: 1px solid var(--border2); border-radius: 8px; padding: 6px 9px; font-family: inherit; font-size: 13px; }
select { cursor: pointer; }
select:hover, input[type=number]:hover, input[type=text]:hover { border-color: #4a5d7a; }
select.head-sel { padding: 5px 8px; background: var(--panel2); font-weight: 600; font-size: 12px; max-width: 220px; }
input[type=text] { min-width: 0; }
input:disabled { opacity: .55; }
label.chk { display: inline-flex; gap: 6px; align-items: center; cursor: pointer; color: var(--muted); font-size: 12.5px; }
input[type=checkbox] { accent-color: var(--gold); width: 15px; height: 15px; }
input[type=range] { accent-color: var(--gold); }

/* Toggle switch */
.switch { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; user-select: none; font-size: 12px; font-weight: 600; color: #c7d1de; padding: 4px 8px 4px 5px; border-radius: 8px; border: 1px solid var(--border); background: var(--panel2); }
.switch:hover { border-color: #4a5d7a; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.sw-track { width: 28px; height: 16px; border-radius: 8px; background: #3a4658; position: relative; transition: background .15s; flex: none; }
.sw-knob { position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #dfe6ef; transition: left .15s; }
.switch input:checked + .sw-track { background: var(--gold2); }
.switch input:checked + .sw-track .sw-knob { left: 14px; background: #fff; }
.switch input:focus-visible + .sw-track { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- Game layout ---------- */
.game { display: grid; grid-template-columns: minmax(0, 1fr) var(--odds-w); height: 100%; }
.game-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; padding: 8px 10px 8px; gap: 7px; }
.game-head { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; row-gap: 5px; background: var(--bg2); border: 1px solid var(--border); border-radius: 12px; padding: 5px 8px; }
.game-title { font-size: 16.5px; font-weight: 800; letter-spacing: .2px; white-space: nowrap; }
.game-title small { font-size: 11px; font-weight: 600; color: var(--muted); margin-left: 6px; }
.game-head .spacer { flex: 1; min-width: 4px; }
.rule-chips { display: flex; gap: 4px; flex-wrap: wrap; }
.rule-chip { font-size: 10px; padding: 2px 6px; border-radius: 12px; background: var(--panel2); border: 1px solid var(--border); color: var(--muted); white-space: nowrap; }

/* The felt is a size container: cards, chips and spots are sized from the felt itself (cqw / cqh) so they fill the table */
.felt { position: relative; flex: 1; min-height: 0; border-radius: 26px; isolation: isolate; container-type: size;
  --cw: clamp(64px, min(8.4cqw, calc((100cqh - 190px) / 4.4)), 170px); --ch: calc(var(--cw) * 1.42);
  background:
    radial-gradient(ellipse at 50% 30%, rgba(255, 255, 255, .07), transparent 60%),
    repeating-linear-gradient(45deg, rgba(0, 0, 0, .035) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, .02) 0 2px, transparent 2px 5px),
    radial-gradient(ellipse at 50% 35%, var(--felt1), var(--felt2) 78%);
  box-shadow: inset 0 0 0 9px #2e1a0c, inset 0 0 0 11px #8a5a2c, inset 0 0 0 13px #3b2413, inset 0 0 0 14px rgba(255, 210, 140, .25), inset 0 0 70px rgba(0, 0, 0, .6), var(--shadow);
  overflow: auto; padding: 24px; }
.felt::before { content: ''; position: absolute; inset: 22px; border-radius: 18px; border: 1.5px solid rgba(244, 194, 91, .22); box-shadow: inset 0 0 0 5px rgba(0, 0, 0, .06), inset 0 0 0 6px rgba(244, 194, 91, .1); pointer-events: none; z-index: -1; }
.felt.blue { --felt1: #1d4f86; --felt2: #0b2647; }
.felt.red { --felt1: #7d1f2c; --felt2: #3e0c14; }
.felt.purple { --felt1: #4a2b7a; --felt2: #1e1036; }
.felt-print { color: rgba(255, 255, 255, .16); font-weight: 800; letter-spacing: 3px; text-transform: uppercase; text-align: center; pointer-events: none; }
/* Watermark emblem and printed curves */
.felt-decor { position: absolute; left: 50%; top: 52%; width: min(62cqh, 46cqw); aspect-ratio: 1; transform: translate(-50%, -50%); color: rgba(255, 255, 255, .055); pointer-events: none; z-index: -1; }
.felt-decor svg { width: 100%; height: 100%; display: block; }
.felt-decor.top { top: 50%; }
.felt-arc { width: min(100%, 900px); pointer-events: none; color: rgba(255, 236, 190, .5); flex: none; }
.felt-arc svg { width: 100%; height: auto; display: block; overflow: visible; }
.felt-arc text { fill: currentColor; font-family: Georgia, 'Times New Roman', serif; font-weight: 700; }
.felt-arc text.gold { fill: rgba(244, 194, 91, .85); }
.felt-arc text.dim { fill: rgba(255, 255, 255, .32); font-family: var(--font); font-weight: 650; }
.felt-arc .arc-band { fill: none; stroke: rgba(244, 194, 91, .45); stroke-width: 3; }
/* Pay-table placards printed on the cloth */
.placard { border: 2px solid rgba(244, 194, 91, .5); border-radius: 12px; padding: 7px 11px 8px; background: rgba(0, 0, 0, .2); color: rgba(255, 240, 205, .9); font-size: clamp(10.5px, .95cqw, 14px); line-height: 1.35; min-width: 0; box-shadow: inset 0 0 0 3px rgba(0, 0, 0, .12), inset 0 0 0 4px rgba(244, 194, 91, .15); pointer-events: none; }
.pl-t { font-family: Georgia, serif; font-weight: 800; text-transform: uppercase; letter-spacing: 1.8px; color: var(--gold); text-align: center; font-size: 1.08em; margin-bottom: 3px; white-space: nowrap; }
.pl-s { text-align: center; font-size: .82em; color: rgba(255, 255, 255, .55); margin: -2px 0 3px; letter-spacing: .5px; }
.pl-rows { display: flex; flex-direction: column; gap: 1px; }
.pl-r { display: flex; justify-content: space-between; gap: 12px; white-space: nowrap; }
.pl-r span { color: rgba(255, 255, 255, .78); }
.pl-r b { color: #ffe9b0; font-weight: 750; font-variant-numeric: tabular-nums; }
.pl-r.hit { background: rgba(244, 194, 91, .3); border-radius: 4px; }
.placards { position: absolute; top: 24px; display: flex; flex-direction: column; gap: 8px; z-index: 0; max-height: calc(100% - 48px); overflow: hidden; }
.placards.left { left: 26px; }
.placards.right { right: 26px; top: 100px; max-height: calc(100% - 124px); }
@container (max-width: 900px) { .placards { display: none; } }

.controls { display: flex; align-items: center; gap: 8px; flex-wrap: nowrap; background: var(--panel); border: 1px solid var(--border); border-radius: 13px; padding: 6px 10px; min-height: 54px; }
.controls .spacer { flex: 1; min-width: 4px; }
.action-row { display: flex; gap: 7px; flex-wrap: wrap; align-items: center; }
.bet-controls { display: flex; gap: 4px; flex-wrap: nowrap; }
@media (max-width: 1120px) { .controls { flex-wrap: wrap; } }
.table-msg { position: absolute; left: 50%; transform: translateX(-50%); bottom: 14px; background: rgba(0, 0, 0, .6); padding: 8px 18px; border-radius: 20px; font-weight: 650; font-size: 14px; color: #fff; white-space: nowrap; pointer-events: none; z-index: 3; backdrop-filter: blur(4px); max-width: 90%; overflow: hidden; text-overflow: ellipsis; }
.table-msg:empty { display: none; }

/* ---------- Step-by-step bar ---------- */
.step-bar { position: absolute; left: 50%; bottom: 60px; transform: translateX(-50%); z-index: 30; width: max-content; max-width: 94%; display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 16px; border-radius: 16px; background: rgba(8, 12, 18, .92); border: 2px solid var(--gold); box-shadow: 0 10px 30px rgba(0, 0, 0, .5), 0 0 24px rgba(244, 194, 91, .25); animation: bannerIn .25s; }
.step-bar[hidden] { display: none; }
.step-txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.step-num { font-size: 10px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--gold); font-weight: 800; }
.step-cap { font-size: 14px; color: #e8edf4; line-height: 1.45; }
.step-odds { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.step-odds b { color: var(--text); }
.step-next { min-height: 44px; font-size: 15px; padding: 0 18px; }

/* ---------- Cards ---------- */
.card { width: var(--cw); height: calc(var(--cw) * 1.42); perspective: 900px; flex: none; position: relative; }
.card.small { --cw: 54px; }
.card.tiny { --cw: 38px; }
.card-inner { position: absolute; inset: 0; transition: transform .45s cubic-bezier(.3, .7, .3, 1); transform-style: preserve-3d; }
.card.facedown .card-inner { transform: rotateY(180deg); }
.card-face { position: absolute; inset: 0; border-radius: calc(var(--cw) * .1); backface-visibility: hidden; -webkit-backface-visibility: hidden; box-shadow: 0 3px 10px rgba(0, 0, 0, .45); }
.card-face.front { background: linear-gradient(160deg, #ffffff, #eef0f3); color: #1b1f27; border: 1px solid #cfd4dc; }
.card.red .card-face.front { color: #d3263a; }
.card.blue .card-face.front { color: #1f63c8; }
.card.green .card-face.front { color: #138a4a; }
.card.purple .card-face.front { color: #7a3fd0; }
.card.orange .card-face.front { color: #d26a00; }
.card-face.back { transform: rotateY(180deg); background: repeating-linear-gradient(45deg, #8e1c2a 0 6px, #a82535 6px 12px); border: calc(var(--cw) * .06) solid #f3f3f3; }
.card-face.back::after { content: ''; position: absolute; inset: 12%; border: 1.5px solid rgba(255, 255, 255, .35); border-radius: 6px; }
.c-corner { position: absolute; display: flex; flex-direction: column; align-items: center; line-height: .95; }
.c-corner b { font-size: calc(var(--cw) * .25); font-weight: 750; letter-spacing: -1px; }
.c-corner i { font-style: normal; font-size: calc(var(--cw) * .21); }
.c-corner.tl { top: 5%; left: 7%; }
.c-corner.br { bottom: 5%; right: 7%; transform: rotate(180deg); }
.c-mid { position: absolute; inset: 0; display: grid; place-items: center; }
.c-pip { font-size: calc(var(--cw) * .55); }
.c-face { position: absolute; font-size: calc(var(--cw) * .3); font-weight: 800; opacity: .16; transform: scale(2.6); }
.card.tiny .c-corner.br, .card.tiny .c-mid { display: none; }
.card.tiny .c-corner b { font-size: 14px; }
.card.tiny .c-corner i { font-size: 13px; }
.card.deal-in { animation: dealIn .38s cubic-bezier(.2, .8, .3, 1) both; }
@keyframes dealIn { from { transform: translate(140px, -220px) rotate(-25deg) scale(.7); opacity: 0; } to { transform: none; opacity: 1; } }
.card.glow .card-face.front { box-shadow: 0 0 0 3px var(--gold), 0 0 18px rgba(244, 194, 91, .7); }
.card.dim { filter: brightness(.55); }
.card.held .card-face { box-shadow: 0 0 0 3px var(--teal), 0 0 18px rgba(47, 212, 196, .6); }
.cards-row { display: flex; gap: 10px; align-items: center; min-height: var(--ch); }
.cs { font-weight: 700; white-space: nowrap; }
.cs.red { color: #ff6b7d; }
.cs.blk { color: #e9eef6; }
.cs.blue { color: #7cb7ff; }
.cs.green { color: #5fe0a0; }
.cs.purple { color: #c3a3ff; }
.cs.orange { color: #ffb36b; }

.hand-total { display: inline-flex; align-items: center; justify-content: center; min-width: 36px; height: 28px; padding: 0 10px; border-radius: 14px; background: rgba(0, 0, 0, .6); color: #fff; font-weight: 750; font-size: 15px; border: 1px solid rgba(255, 255, 255, .15); }
.hand-total.bust { background: var(--red); }
.hand-total.bj { background: var(--gold); color: #2a1d00; }
.hand-total.win { background: var(--green-d); }

/* ---------- Chips ---------- */
.chip { --cc: #ddd; --ct: #222; --cs: 58px; width: var(--cs); height: var(--cs); border-radius: 50%; position: relative; display: grid; place-items: center; font-weight: 850; font-size: calc(var(--cs) * .27); color: var(--ct); flex: none; user-select: none;
  background: radial-gradient(circle at 50% 50%, var(--cc) 0 52%, transparent 53%), repeating-conic-gradient(var(--cc) 0 22.5deg, #fff 22.5deg 45deg);
  box-shadow: 0 3px 6px rgba(0, 0, 0, .5), inset 0 0 0 2px rgba(0, 0, 0, .2), inset 0 0 0 calc(var(--cs) * .06) rgba(255, 255, 255, .08); }
.chip span { position: relative; width: 70%; height: 70%; border-radius: 50%; display: grid; place-items: center; border: 1.5px dashed rgba(255, 255, 255, .55); }
.chip.c1 { --cc: #e9e9ef; --ct: #222; }
.chip.c1 span { border-color: rgba(0, 0, 0, .3); }
.chip.c5 { --cc: #d33a3a; --ct: #fff; }
.chip.c25 { --cc: #1f9d55; --ct: #fff; }
.chip.c100 { --cc: #24272e; --ct: #fff; }
.chip.c500 { --cc: #7a3fc6; --ct: #fff; }
.chip.c1000 { --cc: #e2a516; --ct: #2a1d00; }
.chip.c5000 { --cc: #e2528f; --ct: #fff; }
.chip.cx { --cc: #3d8fd8; --ct: #fff; }
.chip-tray { display: flex; gap: 5px; align-items: center; padding: 2px 4px; }
.chip-tray .chip { --cs: clamp(36px, 2.7vw, 44px); }
.tray-chip { cursor: grab; transition: transform .15s; touch-action: none; }
.bet-spot.has-bet { touch-action: none; cursor: grab; }
.chip.drag-ghost { position: fixed; z-index: 99999; pointer-events: none; transform: translate(-50%, -50%) scale(1.12); box-shadow: 0 10px 22px rgba(0, 0, 0, .55); margin: 0; }
body.chip-dragging, body.chip-dragging * { cursor: grabbing !important; user-select: none; }
.bet-spot.drop-hover { background: rgba(244, 194, 91, .28) !important; box-shadow: 0 0 0 2px var(--gold), 0 0 14px rgba(244, 194, 91, .6); z-index: 5; }
.tray-chip:hover { transform: translateY(-3px); }
.tray-chip.sel { transform: translateY(-6px) scale(1.1); box-shadow: 0 0 0 3px var(--gold), 0 8px 18px rgba(0, 0, 0, .6); }
.chip.stacked { --cs: clamp(40px, calc(var(--cw) * .56), 78px); position: absolute; left: 50%; margin-left: calc(var(--cs) / -2); top: 50%; margin-top: calc(var(--cs) / -2); }

/* ---------- Bet spots ---------- */
.bet-spot { position: relative; border: 2px solid var(--felt-line); border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; text-align: center; transition: background .15s, border-color .15s, box-shadow .15s, transform .1s; user-select: none; color: rgba(255, 255, 255, .88); }
.bet-spot:hover { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .6); }
.bet-spot:active { transform: scale(.98); }
.bet-spot .bs-label { font-weight: 750; font-size: clamp(12px, calc(var(--cw) * .14), 17px); letter-spacing: .6px; text-transform: uppercase; pointer-events: none; z-index: 0; }
.bet-spot .bs-sub { font-size: clamp(10px, calc(var(--cw) * .105), 13px); opacity: .72; pointer-events: none; }
.bet-spot .bs-sub:empty { display: none; }
.bet-spot .chip-stack { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.bet-spot .bs-amt { position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%); font-size: 12px; font-weight: 750; background: rgba(0, 0, 0, .75); padding: 1px 7px; border-radius: 8px; white-space: nowrap; z-index: 2; pointer-events: none; color: #fff; }
.bet-spot .bs-amt:empty { display: none; }
.bet-spot.has-bet .bs-label, .bet-spot.has-bet .bs-sub { opacity: .25; }
.bet-spot.win { animation: winGlow 2s; }
.bet-spot.lose { animation: loseFade 1.4s; }
.bet-spot.push { animation: pushGlow 1.6s; }
.bet-spot.disabled { opacity: .45; cursor: not-allowed; }
.bet-spot.rec { box-shadow: 0 0 0 2px var(--gold), 0 0 16px rgba(244, 194, 91, .5); }
.bet-spot[hidden] { display: none; }
@keyframes winGlow { 0%, 60% { box-shadow: 0 0 0 3px var(--green), 0 0 26px var(--green); background: rgba(53, 208, 127, .25); } }
@keyframes loseFade { 0%, 50% { box-shadow: 0 0 0 3px var(--red); background: rgba(255, 95, 109, .2); } }
@keyframes pushGlow { 0%, 50% { box-shadow: 0 0 0 3px var(--blue); } }
.shake { animation: shake .35s; }
@keyframes shake { 25% { transform: translateX(-5px); } 50% { transform: translateX(5px); } 75% { transform: translateX(-3px); } }

.float-text { position: fixed; transform: translate(-50%, -50%); font-weight: 850; font-size: 20px; pointer-events: none; z-index: 1000; animation: floatUp 1.8s forwards; text-shadow: 0 2px 6px rgba(0, 0, 0, .8); }
.float-text.win { color: #5dffa6; }
.float-text.lose { color: #ff8a95; }
.float-text.push { color: #9fd0ff; }
@keyframes floatUp { from { opacity: 1; margin-top: 0; } to { opacity: 0; margin-top: -60px; } }

.result-banner { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -50%); z-index: 20; padding: 16px 34px; border-radius: 16px; font-size: 24px; font-weight: 850; text-align: center; background: rgba(8, 12, 18, .9); border: 2px solid var(--border2); box-shadow: var(--shadow); animation: bannerIn .35s cubic-bezier(.2, 1.4, .4, 1); pointer-events: none; white-space: nowrap; }
.result-banner small { display: block; font-size: 13.5px; font-weight: 600; color: var(--muted); margin-top: 3px; }
.result-banner.win { border-color: var(--green); color: #6dffae; box-shadow: 0 0 40px rgba(53, 208, 127, .4); }
.result-banner.lose { border-color: var(--red); color: #ff9aa4; }
.result-banner.push { border-color: var(--blue); color: #a9d4ff; }
.result-banner.big { border-color: var(--gold); color: var(--gold); box-shadow: 0 0 50px rgba(244, 194, 91, .55); }
.result-banner.out { opacity: 0; transition: opacity .4s; }
@keyframes bannerIn { from { transform: translate(-50%, -50%) scale(.6); opacity: 0; } }
@keyframes stepIn { from { transform: translate(-50%, 12px); opacity: 0; } }
.step-bar { animation: stepIn .25s; }

/* ---------- Toasts / modal ---------- */
.toast-wrap { position: fixed; top: 72px; left: 50%; transform: translateX(-50%); z-index: 2000; display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none; }
.toast { background: var(--panel3); border: 1px solid var(--border2); padding: 10px 18px; border-radius: 10px; box-shadow: var(--shadow); font-weight: 600; transition: opacity .4s, transform .4s; }
.toast.err { border-color: var(--red); color: #ffb3ba; }
.toast.warn { border-color: var(--orange); color: #ffd2a3; }
.toast.ok { border-color: var(--green); color: #a8ffd0; }
.toast.out { opacity: 0; transform: translateY(-10px); }
.modal-overlay { position: fixed; inset: 0; background: rgba(3, 6, 10, .72); z-index: 1500; display: grid; place-items: center; backdrop-filter: blur(3px); animation: fadeIn .2s; }
@keyframes fadeIn { from { opacity: 0; } }
.modal { background: var(--panel); border: 1px solid var(--border2); border-radius: 16px; width: min(560px, 94vw); max-height: 90vh; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.modal.wide { width: min(880px, 95vw); }
.modal.xwide { width: min(1180px, 96vw); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border); }
.modal-head h3 { margin: 0; font-size: 17px; }
.modal-body { padding: 16px 18px; overflow-y: auto; }
.rules h4 { margin: 16px 0 6px; color: var(--gold); }
.rules h4:first-child { margin-top: 0; }
.rules p, .rules li { color: #c9d3e0; line-height: 1.5; }
.rules table { border-collapse: collapse; margin: 6px 0; }
.rules td, .rules th { border: 1px solid var(--border); padding: 4px 10px; font-size: 13px; text-align: left; }
.rules th { background: var(--panel2); }

/* Rules forms */
.rules-modal { display: flex; flex-direction: column; gap: 10px; }
.rules-form { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 22px; }
.rf-section { grid-column: 1 / -1; font-size: 11px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--gold); font-weight: 800; margin-top: 8px; padding-bottom: 4px; border-bottom: 1px solid var(--border); }
.rf-note { grid-column: 1 / -1; }
.rf-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 10px; border-radius: 10px; background: var(--panel2); border: 1px solid var(--border); min-height: 46px; }
.rf-row select, .rf-row input[type=number] { max-width: 58%; }
.rf-row.chk { cursor: pointer; }
.rf-l { color: #d4dce8; font-weight: 600; font-size: 13.5px; display: flex; flex-direction: column; }
.rf-l small { color: var(--muted); font-weight: 500; font-size: 11px; }
.rf-range { display: flex; align-items: center; gap: 8px; }
.rf-val { min-width: 54px; text-align: right; color: var(--gold); }
.rf-actions { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.rules-modal > .rf-actions { position: sticky; bottom: -16px; margin: 0 -18px -16px; padding: 12px 18px 14px; background: linear-gradient(180deg, rgba(19, 26, 36, .85), var(--panel) 40%); border-top: 1px solid var(--border); z-index: 3; }
.rf-actions .spacer { flex: 1; }
/* Pay-table / ranking editors */
.rf-pay { grid-column: 1 / -1; background: var(--panel2); border: 1px solid var(--border); border-radius: 12px; padding: 9px 11px 10px; display: flex; flex-direction: column; gap: 8px; }
.pt-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pt-head .spacer { flex: 1; }
.pt-preset { max-width: 330px; }
.pt-edge { font-size: 12px; font-weight: 750; padding: 3px 9px; border-radius: 9px; background: rgba(255, 95, 109, .12); border: 1px solid rgba(255, 95, 109, .4); color: #ffc0c6; white-space: nowrap; }
.pt-edge.pos { background: rgba(53, 208, 127, .14); border-color: rgba(53, 208, 127, .5); color: #9ff3c6; }
.pt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 10px; }
.pt-cell { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12.5px; color: #c9d3e0; background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 4px 6px 4px 9px; }
.pt-l { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pt-in { display: inline-flex; align-items: center; gap: 5px; flex: none; }
.pt-in input { width: 74px; padding: 5px 7px; text-align: right; }
.pt-in i { font-style: normal; font-size: 11px; color: var(--muted); min-width: 26px; }
.pt-note { font-size: 12px; color: var(--muted); line-height: 1.45; }
.pt-note:empty { display: none; }
.pt-note b { color: var(--text); }
.ro-list { display: flex; flex-direction: column; gap: 3px; }
.ro-row { display: grid; grid-template-columns: 28px 1fr auto auto; align-items: center; gap: 6px; background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 3px 6px 3px 10px; font-size: 13px; }
.ro-row b { color: var(--gold); }
.rf-checks { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.rf-checks .chk { color: #d4dce8; }
/* Autopilot */
.ap { display: inline-flex; align-items: center; gap: 3px; padding: 2px; border-radius: 9px; border: 1px solid var(--border); background: var(--panel2); }
.ap .ap-btn { border: 0; background: transparent; padding: 4px 7px; }
.ap .ap-btn:hover:not(:disabled) { background: var(--panel3); }
.ap.running { border-color: rgba(53, 208, 127, .55); background: rgba(53, 208, 127, .08); }
.ap-btn.running { background: linear-gradient(180deg, #ff7d88, #d8404f); border-color: #b02f3c; color: #2b0006; animation: apPulse 1.6s infinite; }
@keyframes apPulse { 50% { box-shadow: 0 0 0 3px rgba(255, 95, 109, .35); } }
select.ap-sel { padding: 3px 4px; font-size: 11.5px; background: var(--panel3); border-color: transparent; border-radius: 6px; }
.ap-info { font-size: 11px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; padding: 0 4px; }
.ap-info:empty { display: none; }
.ap-info b { color: var(--text); }
body.ap-fast .card.deal-in { animation-duration: .07s; }
body.ap-fast .card-inner { transition-duration: .08s; }
body.ap-fast .bet-spot.win, body.ap-fast .bet-spot.lose, body.ap-fast .bet-spot.push { animation-duration: .5s; }
body.ap-fast .float-text { display: none; }
select.deck-sel { max-width: 165px; }

/* ---------- Odds panel ---------- */
.odds-panel { position: relative; background: var(--bg2); border-left: 1px solid var(--border); min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.op-resize { position: absolute; left: -4px; top: 0; bottom: 0; width: 10px; cursor: col-resize; z-index: 5; touch-action: none; }
.op-resize::after { content: ''; position: absolute; left: 3px; top: 50%; height: 64px; margin-top: -32px; width: 4px; border-radius: 2px; background: var(--border2); opacity: .7; transition: background .15s, opacity .15s, height .15s; }
.op-resize:hover::after, body.odds-dragging .op-resize::after { background: var(--gold); opacity: 1; height: 120px; margin-top: -60px; }
body.odds-dragging { cursor: col-resize; user-select: none; }
body.odds-dragging * { cursor: col-resize !important; }
.op-header { flex: none; z-index: 2; display: flex; align-items: center; gap: 6px; padding: 7px 10px 7px 12px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; font-size: 11px; color: var(--gold); background: var(--bg2); border-bottom: 1px solid var(--border); }
.op-h-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.op-header .spacer { flex: 1; }
.op-wide, .op-exp { font-size: 14px; padding: 2px 6px; border: 1px solid var(--border); background: var(--panel2); line-height: 1.2; }
.op-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); animation: pulse 2s infinite; flex: none; }
@keyframes pulse { 50% { opacity: .35; } }
.op-content { padding: 7px 9px 14px; display: flex; flex-direction: column; gap: 6px; overflow-y: auto; flex: 1; min-height: 0; container-type: inline-size; }
@container (min-width: 600px) {
  .op-content { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; gap: 7px; }
  .op-slot.is-rec { grid-column: 1 / -1; }
}
/* Slots: active sections stay crisp; idle ("last round") slots collapse to a compact 1-line bar unless clicked */
.op-slot { position: relative; flex: none; min-width: 0; }
.op-slot > * { overflow-anchor: none; transition: opacity .18s, filter .18s; }
.op-slot.idle > * { opacity: .48; filter: saturate(.35); }
.op-slot.idle:not(.idle-open) .op-body { display: none; }
.op-slot.idle:not(.idle-open) .op-title { margin-bottom: 0; }
.op-slot.idle:not(.idle-open) .op-chev { transform: rotate(-90deg); }
.op-slot.idle:not(.idle-open) .rec-detail,
.op-slot.idle:not(.idle-open) .rec-detail-wrap { display: none; }
.op-slot.idle .op-badge { visibility: hidden; }
.op-slot.idle::after { content: 'last round'; position: absolute; top: 6px; right: 24px; font-size: 9.5px; font-weight: 700; letter-spacing: .4px; color: var(--muted); background: var(--panel3); border: 1px solid var(--border2); padding: 1px 6px; border-radius: 8px; pointer-events: none; }
.op-slot.idle.is-rec::after { right: 9px; }
body.ap-fast .op-slot > * { transition: none; }

.op-section { background: var(--panel); border: 1px solid var(--border); border-radius: 10px; padding: 7px 9px 8px; }
.op-section.collapsed { padding: 6px 9px; background: rgba(19, 26, 36, .72); }
.op-section.collapsed:hover { border-color: var(--border2); background: var(--panel); }
.op-section.collapsed .op-body { display: none; }
.op-section.collapsed .op-title { margin-bottom: 0; }
.op-section.collapsed .op-chev { transform: rotate(-90deg); }
.op-title { display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 10.5px; text-transform: uppercase; letter-spacing: 1.1px; color: var(--muted); font-weight: 750; margin-bottom: 6px; }
.op-title.can-toggle { cursor: pointer; user-select: none; }
.op-title.can-toggle:hover { color: var(--text); }
.op-t-txt { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.op-t-right { display: inline-flex; align-items: center; gap: 5px; flex: none; }
.op-chev { font-size: 11px; color: var(--dim); transition: transform .15s; line-height: 1; }
.op-title.can-toggle:hover .op-chev { color: var(--gold); }
.op-badge { font-size: 9.5px; background: var(--panel3); border: 1px solid var(--border2); padding: 1px 6px; border-radius: 8px; color: var(--text); letter-spacing: .3px; text-transform: none; font-weight: 650; white-space: nowrap; max-width: 190px; overflow: hidden; text-overflow: ellipsis; }
.op-body { display: flex; flex-direction: column; gap: 5px; }
.op-note { font-size: 11.8px; color: var(--muted); line-height: 1.4; }
.op-note.warn { color: #ffc98f; }
.op-note.good { color: #8ff0bd; }
.op-note b { color: var(--text); }
/* Inline expandable detail block inside a primary section */
.op-more { background: rgba(12, 17, 25, .65); border: 1px solid var(--border); border-radius: 8px; font-size: 11.5px; }
.op-more summary { cursor: pointer; padding: 5px 8px; color: #b8c4d6; font-weight: 650; list-style: none; user-select: none; display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.op-more summary:hover { color: var(--text); }
.op-more summary::-webkit-details-marker { display: none; }
.op-more summary::after { content: '▸'; color: var(--dim); transition: transform .15s; flex: none; }
.op-more[open] summary::after { transform: rotate(90deg); color: var(--gold); }
.op-more-body { padding: 4px 8px 7px; display: flex; flex-direction: column; gap: 5px; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(84px, 1fr)); gap: 5px; }
.stat { background: var(--panel2); border: 1px solid var(--border); border-radius: 8px; padding: 5px 7px; min-width: 0; }
.stat-v { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.15; }
.stat-l { font-size: 9.5px; color: var(--muted); margin-top: 1px; text-transform: uppercase; letter-spacing: .5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat.pos .stat-v { color: var(--green); }
.stat.neg .stat-v { color: var(--red); }
.stat.gold .stat-v { color: var(--gold); }
.stat.blue .stat-v { color: var(--blue); }
.pbar { display: flex; flex-direction: column; gap: 2px; }
.pbar-top { display: flex; justify-content: space-between; font-size: 11.8px; gap: 8px; }
.pbar-l { color: #c7d1de; }
.pbar-v { font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pbar-track { height: 6px; background: var(--panel3); border-radius: 4px; overflow: hidden; }
.pbar-fill { height: 100%; background: linear-gradient(90deg, var(--blue), var(--teal)); border-radius: 4px; transition: width .5s cubic-bezier(.3, .8, .3, 1); }
.pbar.green .pbar-fill { background: linear-gradient(90deg, var(--green-d), var(--green)); }
.pbar.red .pbar-fill { background: linear-gradient(90deg, #b8303e, var(--red)); }
.pbar.gold .pbar-fill { background: linear-gradient(90deg, var(--gold2), var(--gold)); }
.pbar.purple .pbar-fill { background: linear-gradient(90deg, #6a3fc0, var(--purple)); }
.stackbar { display: flex; height: 22px; border-radius: 7px; overflow: hidden; font-size: 11px; font-weight: 750; }
.sb-seg { display: grid; place-items: center; color: rgba(0, 0, 0, .82); white-space: nowrap; overflow: hidden; transition: width .5s; }
.ev { font-weight: 750; font-variant-numeric: tabular-nums; }
.ev.pos, .pos { color: var(--green); }
.ev.neg, .neg { color: var(--red); }
.ev.zero, .zero { color: var(--blue); }
.formula { background: #0c1119; border: 1px solid var(--border); border-radius: 8px; font-size: 11.5px; }
.formula summary { cursor: pointer; padding: 5px 8px; color: #b8c4d6; font-weight: 600; list-style: none; user-select: none; }
.formula summary:hover { color: var(--text); }
.formula summary::-webkit-details-marker { display: none; }
.formula summary::after { content: '▸'; float: right; color: var(--dim); transition: transform .2s; }
.formula[open] summary::after { transform: rotate(90deg); }
.formula .fx { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 4px; background: rgba(167, 123, 255, .18); color: var(--purple); font-style: italic; font-family: Georgia, serif; font-weight: 700; font-size: 11px; }
.f-body { padding: 3px 10px 8px; font-family: var(--mono); font-size: 11.2px; color: #d6deea; line-height: 1.55; overflow-x: auto; }
.f-line { white-space: pre-wrap; word-break: break-word; }
.f-line .c { color: var(--dim); }
.f-line .k { color: var(--teal); }
.f-line .r { color: var(--gold); font-weight: 700; }
.recommend { border-radius: 10px; padding: 7px 10px; background: linear-gradient(135deg, rgba(244, 194, 91, .2), rgba(244, 194, 91, .04)); border: 1px solid rgba(244, 194, 91, .45); }
.recommend.alt { background: linear-gradient(135deg, rgba(89, 168, 255, .18), rgba(89, 168, 255, .03)); border-color: rgba(89, 168, 255, .45); }
.rec-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.rec-label { font-size: 9.5px; text-transform: uppercase; letter-spacing: 1.4px; color: var(--gold); font-weight: 800; }
.recommend.alt .rec-label { color: var(--blue); }
.rec-action { font-size: 18px; font-weight: 850; line-height: 1.15; }
.rec-detail { font-size: 11.8px; color: #c4cede; line-height: 1.4; margin-top: 3px; }
.rec-more { margin-top: 3px; }
.rec-more summary { cursor: pointer; font-size: 11px; font-weight: 700; color: var(--gold); list-style: none; user-select: none; display: inline-flex; align-items: center; gap: 4px; }
.recommend.alt .rec-more summary { color: var(--blue); }
.rec-more summary::-webkit-details-marker { display: none; }
.rec-more summary::after { content: '▸'; font-size: 10px; transition: transform .15s; }
.rec-more[open] summary::after { transform: rotate(90deg); }
.otable { width: 100%; border-collapse: collapse; font-size: 12px; font-variant-numeric: tabular-nums; }
.otable th { text-align: left; font-size: 9.5px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); font-weight: 700; padding: 3px 5px; border-bottom: 1px solid var(--border); }
.otable td { padding: 3.5px 5px; border-bottom: 1px solid rgba(38, 50, 68, .55); }
.otable tr:last-child td { border-bottom: 0; }
.otable tr.best td { background: rgba(244, 194, 91, .1); }
.otable tr.best td:first-child { box-shadow: inset 3px 0 0 var(--gold); font-weight: 750; }
.otable tr.na td { opacity: .4; }
.otable tr.hit td { background: rgba(53, 208, 127, .13); }
.otable td:not(:first-child), .otable th:not(:first-child) { text-align: right; }
.colchart { display: flex; gap: 3px; align-items: flex-end; height: 76px; }
.cc-col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; min-width: 0; }
.cc-v { font-size: 9.5px; color: var(--muted); height: 13px; white-space: nowrap; }
.cc-bar-wrap { flex: 1; width: 100%; display: flex; align-items: flex-end; }
.cc-bar { width: 100%; border-radius: 4px 4px 0 0; background: linear-gradient(180deg, var(--blue), #2a5a9a); transition: height .5s; min-height: 1px; }
.cc-col.hl .cc-bar { background: linear-gradient(180deg, var(--gold), var(--gold2)); }
.cc-col.good .cc-bar { background: linear-gradient(180deg, var(--green), var(--green-d)); }
.cc-col.bad .cc-bar { background: linear-gradient(180deg, var(--red), #a3303c); }
.cc-col.dim .cc-bar { background: #34445c; }
.cc-l { font-size: 11px; font-weight: 700; color: #c7d1de; margin-top: 4px; white-space: nowrap; }
.gauge { padding: 4px 2px; }
.gauge-track { position: relative; height: 10px; border-radius: 5px; background: linear-gradient(90deg, var(--red), #6b7a90 50%, var(--green)); }
.gauge-mid { position: absolute; left: 50%; top: -3px; bottom: -3px; width: 2px; background: rgba(255, 255, 255, .5); }
.gauge-needle { position: absolute; top: -5px; width: 4px; height: 20px; margin-left: -2px; background: #fff; border-radius: 2px; box-shadow: 0 0 8px #fff; transition: left .5s; }
.gauge-labels { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 4px; }
.gauge-labels b { color: var(--text); }
.kv { display: flex; justify-content: space-between; font-size: 12.5px; gap: 10px; }
.kv span:first-child { color: var(--muted); }
.kv span:last-child { font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.tag { display: inline-block; font-size: 10.5px; font-weight: 750; padding: 2px 7px; border-radius: 6px; background: var(--panel3); border: 1px solid var(--border2); }
.tag.pos { background: rgba(53, 208, 127, .15); border-color: rgba(53, 208, 127, .5); }
.tag.neg { background: rgba(255, 95, 109, .12); border-color: rgba(255, 95, 109, .45); }
.tag.gold { background: rgba(244, 194, 91, .15); border-color: rgba(244, 194, 91, .5); color: var(--gold); }
.spin-loader { display: inline-block; width: 12px; height: 12px; border: 2px solid var(--border2); border-top-color: var(--gold); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -2px; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress { height: 5px; background: var(--panel3); border-radius: 3px; overflow: hidden; }
.progress > div { height: 100%; background: var(--gold); transition: width .2s; }
.progress.big { height: 8px; border-radius: 4px; }
.progress.inf > div { background: repeating-linear-gradient(90deg, var(--gold) 0 18px, var(--gold2) 18px 36px); background-size: 72px 100%; animation: march .9s linear infinite; }
@keyframes march { to { background-position: 72px 0; } }
.pg { display: flex; flex-direction: column; gap: 6px; padding: 4px 0; }
.pg-top { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 1400px) { :root { --odds-w: 380px; } body.odds-wide { --odds-w: 480px; } }
@media (max-width: 1180px) { #app { grid-template-columns: 70px minmax(0, 1fr); } .brand > div:last-child { display: none; } .brand { width: auto; } .nav-item span:not(.nav-ico), .nav-group, .nav-he { display: none; } .nav-item { justify-content: center; } }
@media (max-width: 1050px) {
  .game { grid-template-columns: 1fr; grid-template-rows: auto auto; overflow-y: auto; height: auto; min-height: 100%; }
  .view { overflow-y: auto; }
  .felt { min-height: 520px; }
  .odds-panel { border-left: 0; border-top: 1px solid var(--border); }
  .op-resize { display: none; }
  .rules-form { grid-template-columns: 1fr; }
}
