/* F1 Pop-Up Casino · "Vegas night" look: deep blue, thin gold line art, neon, glitter */
:root {
  --navy-0: #030820;
  --navy-1: #050d2c;
  --navy-2: #0a1a4a;
  --navy-3: #12307e;
  --gold: #e9c46a;
  --gold-hi: #fff1b8;
  --gold-lo: #a87a22;
  --pink: #ff3fb4;
  --cyan: #3fe7ff;
  --red: #e10600;
  --green: #2bff88;
  --ink: #eef1ff;
  --muted: #9aa6d6;
  --f-ui: 'Oswald', 'Arial Narrow', system-ui, sans-serif;
  --f-serif: 'Playfair Display', Georgia, serif;
  --f-neon: 'Monoton', 'Oswald', sans-serif;
  --gold-grad: linear-gradient(180deg, #fff4c2 0%, #e9c46a 45%, #b9871f 55%, #f6d67e 100%);
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background-color: #030820; overflow-x: clip; }
body {
  background-color: #030820;
  background-image: radial-gradient(1200px 700px at 50% -10%, #1a3a9a 0%, #0a1a4a 38%, #050d2c 70%, #030820 100%);
  color: var(--ink);
  font-family: var(--f-ui);
  letter-spacing: 0.02em;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
#glitter { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.lattice {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .07;
  background-image:
    linear-gradient(45deg, transparent 49.3%, var(--gold) 49.5%, var(--gold) 50.5%, transparent 50.7%),
    linear-gradient(-45deg, transparent 49.3%, var(--gold) 49.5%, var(--gold) 50.5%, transparent 50.7%);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
}
a { color: inherit; }
button { font-family: inherit; }
[hidden] { display: none !important; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px;
  padding: 10px clamp(12px, 3vw, 32px);
  padding-top: max(10px, env(safe-area-inset-top));
  background: linear-gradient(180deg, rgba(3, 8, 32, .92), rgba(3, 8, 32, .6));
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(233, 196, 106, .25);
}
.top-left { justify-self: start; display: flex; align-items: center; gap: 8px; min-width: 0; }
.back-btn {
  text-decoration: none; color: var(--muted); font-size: 14px; letter-spacing: .12em;
  text-transform: uppercase; padding: 8px 12px; border: 1px solid rgba(154, 166, 214, .25); border-radius: 999px;
  transition: color .2s, border-color .2s; white-space: nowrap;
}
.back-btn span { color: var(--gold); font-size: 18px; line-height: 0; }
.back-btn:hover { color: var(--ink); border-color: var(--gold); }
.top-lobby, .top-help { padding: 7px 13px; font-size: 12px; }
.brand { text-decoration: none; display: flex; flex-direction: column; align-items: center; line-height: 1; }
.brand-top { display: none; }
.brand-neon {
  font-family: var(--f-neon); font-size: clamp(20px, 2.6vw, 32px); word-spacing: .3em; color: #ffe3f5; white-space: nowrap;
  text-shadow: 0 0 4px #fff, 0 0 10px var(--pink), 0 0 22px var(--pink), 0 0 40px #ff0090;
  animation: flicker 7s infinite;
}
@keyframes flicker { 0%, 92%, 95%, 100% { opacity: 1 } 93% { opacity: .55 } 94% { opacity: .9 } }
.top-right { justify-self: end; display: flex; align-items: center; gap: 10px; }
.credits {
  display: flex; align-items: center; gap: 8px; padding: 6px 14px 6px 6px;
  border-radius: 999px; background: rgba(5, 13, 44, .85);
  border: 1px solid var(--gold); box-shadow: 0 0 18px rgba(233, 196, 106, .25), inset 0 0 12px rgba(233, 196, 106, .12);
  transition: box-shadow .3s, transform .3s;
}
.credits.up { box-shadow: 0 0 28px rgba(43, 255, 136, .6); transform: scale(1.05); }
.credits.down { box-shadow: 0 0 18px rgba(255, 63, 180, .5); }
.credits-chip {
  width: 26px; height: 26px; border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #e8eaef 0 34%, #ff2a2a 35% 48%, #17181d 49% 100%);
  box-shadow: 0 0 0 1px #000 inset;
}
.credits-num { font-weight: 700; font-size: 20px; color: var(--gold-hi); font-variant-numeric: tabular-nums; min-width: 4.2ch; text-align: right; }
.credits-lbl { font-size: 11px; letter-spacing: .2em; color: var(--muted); text-transform: uppercase; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(233, 196, 106, .45);
  background: rgba(5, 13, 44, .85); color: var(--ink); font-size: 18px; cursor: pointer;
}
.icon-btn.off { opacity: .6; }
.icon-btn:hover { border-color: var(--gold); }

main { position: relative; z-index: 1; }
.view { min-height: calc(100vh - 70px); padding: clamp(14px, 2.5vw, 30px) clamp(10px, 3vw, 32px) 40px; }

/* ---------- Lobby ---------- */
.lobby-hero {
  display: grid; grid-template-columns: 1fr minmax(0, 720px) 1fr; align-items: center; gap: 20px;
  max-width: 1280px; margin: 0 auto 8px;
}
.hero-card { width: clamp(90px, 11vw, 150px); filter: drop-shadow(0 12px 30px rgba(0, 0, 0, .6)) drop-shadow(0 0 16px rgba(233, 196, 106, .25)); }
.hero-card svg, .hero-card img { display: block; width: 100%; height: auto; }
.hero-left { justify-self: end; transform: rotate(-9deg); animation: floatL 6s ease-in-out infinite; }
.hero-right { justify-self: start; transform: rotate(9deg); animation: floatR 6s ease-in-out infinite; }
@keyframes floatL { 50% { transform: rotate(-6deg) translateY(-8px) } }
@keyframes floatR { 50% { transform: rotate(6deg) translateY(-8px) } }
.hero-mid { text-align: center; }
.eyebrow { margin: 0 0 6px; font-size: 13px; letter-spacing: clamp(.18em, 1vw, .42em); text-transform: uppercase; color: var(--gold); }
.hero-title { margin: 0; font-family: var(--f-serif); font-weight: 900; font-size: clamp(30px, 4.6vw, 60px); line-height: 1.04; }
.neon-pink { color: #ffe3f5; text-shadow: 0 0 8px var(--pink), 0 0 24px var(--pink); font-style: italic; }
.neon-gold { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 12px rgba(233, 196, 106, .35)); }
.hero-sub { margin: 10px auto 0; max-width: 520px; color: var(--muted); font-size: 16px; font-weight: 400; letter-spacing: .04em; }

.garage { position: relative; max-width: 1280px; margin: 18px auto 0; padding: 0 0 40px; }
.garage-beam {
  display: flex; justify-content: space-around; padding: 8px 0; margin: 0 2%;
  background: linear-gradient(180deg, #1a2147, #0c1230);
  border: 1px solid rgba(233, 196, 106, .35); border-radius: 6px 6px 0 0;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .5);
}
.garage-beam span {
  font-size: 12px; letter-spacing: .5em; color: var(--gold);
  padding: 2px 14px; border: 1px solid rgba(233, 196, 106, .4); border-radius: 3px; background: #050a20;
}
.bays { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(12px, 1.6vw, 20px); padding: 0 2%; position: relative; z-index: 2; }
.bay {
  --acc: var(--pink);
  position: relative; display: flex; flex-direction: column; align-items: center; text-align: center;
  text-decoration: none; color: var(--ink);
  padding: 20px 10px 20px; border-radius: 0 0 var(--radius) var(--radius);
  background:
    repeating-linear-gradient(180deg, rgba(255, 255, 255, .025) 0 2px, transparent 2px 22px),
    linear-gradient(180deg, rgba(18, 48, 126, .55), rgba(5, 13, 44, .92));
  border: 1px solid rgba(233, 196, 106, .3); border-top: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 20px 40px rgba(0, 0, 0, .45);
  transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), box-shadow .35s, border-color .35s;
  overflow: hidden;
}
.bay[data-accent="gold"] { --acc: var(--gold); }
.bay[data-accent="cyan"] { --acc: var(--cyan); }
.bay[data-accent="rainbow"] { --acc: #ff5ec4; }
.bay[data-accent="rainbow"] .bay-light { background: linear-gradient(90deg, #ff4fa8, #ffd93d, #2bff8c, #44e5ff); }
.mini-cab-cb .mini-marquee { color: #fff4c2; text-shadow: 0 0 8px #ff4fa8, 0 0 18px #ffd93d; }
.mini-cab-cb .mini-deck span { background: linear-gradient(180deg, #ff7bc0, #f0207e 55%, #9e084b); }
.bay[data-accent="crimson"] { --acc: #ff2b4a; }
.bay[data-accent="crimson"] .bay-light { background: linear-gradient(90deg, #9d0c24, #ff2b4a, #e2bc6b, #ff2b4a, #9d0c24); }
.bay[data-accent="violet"] { --acc: #b45cff; }
.bay[data-accent="violet"] .bay-light { background: linear-gradient(90deg, #5e17eb, #b45cff, #ff4d6d, #b45cff, #5e17eb); }
.bay[data-accent="ecto"] { --acc: #2dff7a; }
.bay[data-accent="ecto"] .bay-light { background: linear-gradient(90deg, #0fa34a, #2dff7a, #f5c400, #2dff7a, #0fa34a); }
.mini-cab-gb {
  background: linear-gradient(90deg, #1a2434 0%, #0d1522 12%, #070d16 50%, #0d1522 88%, #1a2434 100%);
  border-color: #f5c400;
  box-shadow: inset 0 1px 1px rgba(255, 245, 190, .4), 0 0 22px rgba(45, 255, 122, .38), 0 12px 24px rgba(0, 0, 0, .72);
}
.mini-cab-gb .mini-marquee { color: #d8ffe6; text-shadow: 0 0 8px #2dff7a, 0 0 18px #00c853; }
.mini-cab-gb .mini-reels { background: linear-gradient(180deg, #07131d, #03080e); border-color: #2dff7a; }
.mini-cab-gb .mini-deck span { background: linear-gradient(180deg, #ff5468, #d41028 55%, #7a0312); }
.mini-cab-st {
  background: linear-gradient(90deg, #1b0d14 0%, #0d0710 12%, #06040a 50%, #0d0710 88%, #1b0d14 100%);
  border-color: #d4a64a;
  box-shadow: inset 0 1px 1px rgba(255, 238, 185, .38), 0 0 22px rgba(229, 25, 58, .38), 0 12px 24px rgba(0, 0, 0, .72);
}
.mini-cab-st .mini-marquee { color: #fff0d0; text-shadow: 0 0 8px #e5193a, 0 0 18px #ff3352; }
.mini-cab-st .mini-reels { background: linear-gradient(180deg, #11060e, #040208); border-color: #c99b42; }
.mini-cab-st .mini-deck { background: linear-gradient(180deg, #2b141a, #10070c); }
.mini-cab-st .mini-deck span { background: linear-gradient(180deg, #ff5d6e, #c80b26 55%, #5c0211); }
.bay::before { /* corner line art */
  content: ''; position: absolute; inset: 8px; border: 1px solid rgba(233, 196, 106, .18); border-top: none; border-radius: 0 0 10px 10px; pointer-events: none;
}
.bay:hover, .bay:focus-visible { transform: translateY(-6px); border-color: var(--acc); box-shadow: 0 0 0 1px var(--acc), 0 0 40px color-mix(in srgb, var(--acc) 40%, transparent), 0 26px 50px rgba(0, 0, 0, .5); outline: none; }
.bay-light { position: absolute; top: 0; left: 10%; right: 10%; height: 4px; border-radius: 0 0 4px 4px; background: var(--acc); box-shadow: 0 0 14px var(--acc), 0 0 40px var(--acc); }
.bay-light::after { content: ''; position: absolute; left: 0; right: 0; top: 4px; height: 120px; background: radial-gradient(ellipse at 50% 0, color-mix(in srgb, var(--acc) 22%, transparent), transparent 70%); }
.bay-board { font-size: 11px; letter-spacing: .45em; color: var(--acc); margin: 6px 0 10px; text-shadow: 0 0 10px var(--acc); }
.bay-art { height: 162px; width: 100%; display: flex; align-items: center; justify-content: center; position: relative; }
.bay-art > * { transform: scale(.88); }
.bay-title { margin: 12px 0 6px; font-family: var(--f-serif); font-weight: 900; font-size: clamp(18px, 1.55vw, 23px); white-space: nowrap; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.bay-desc { margin: 0 0 14px; color: var(--muted); font-size: 13.5px; font-weight: 400; line-height: 1.35; max-width: 26ch; min-height: 4.1em; }
.bay-go {
  margin-top: auto;
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; padding: 9px 15px; border-radius: 999px;
  border: 1px solid var(--acc); color: var(--ink); background: color-mix(in srgb, var(--acc) 14%, transparent);
  box-shadow: 0 0 16px color-mix(in srgb, var(--acc) 35%, transparent);
}
@media (max-width: 1140px) {
  .bays { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}
.garage-floor {
  position: absolute; left: -10%; right: -10%; bottom: -60px; height: 220px; z-index: 0;
  background-image:
    linear-gradient(rgba(233, 196, 106, .35) 1px, transparent 1px),
    linear-gradient(90deg, rgba(233, 196, 106, .35) 1px, transparent 1px);
  background-size: 60px 60px;
  transform: perspective(500px) rotateX(62deg); transform-origin: 50% 0;
  mask-image: linear-gradient(180deg, transparent, #000 30%, transparent 95%);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, transparent 95%);
}

/* lobby minis */
.mini-cab {
  width: 176px; height: 156px; border-radius: 22px 22px 10px 10px; position: relative;
  background: linear-gradient(90deg, #1b2548 0%, #0b112c 10%, #060a20 50%, #0b112c 90%, #1b2548 100%);
  border: 2px solid #cfa349;
  box-shadow: inset 0 1px 1px rgba(255, 244, 200, .4), inset 8px 0 12px rgba(0, 0, 0, .6), inset -8px 0 12px rgba(0, 0, 0, .6), 0 0 22px rgba(255, 63, 180, .3), 0 12px 24px rgba(0, 0, 0, .6);
  display: flex; flex-direction: column;
}
.mini-marquee {
  font-family: var(--f-neon); color: #ffe3f5; font-size: 24px; text-align: center; padding: 8px 0 4px;
  text-shadow: 0 0 8px var(--pink), 0 0 18px var(--pink);
  border-bottom: 1.5px solid rgba(233, 196, 106, .5);
  box-shadow: 0 4px 10px rgba(0, 0, 0, .55);
}
.mini-reels {
  display: flex; gap: 4px; justify-content: center; margin: 6px 10px 0; padding: 6px;
  background: linear-gradient(180deg, #060d2a, #020411); border-radius: 8px;
  border: 1.5px solid var(--gold); box-shadow: inset 0 8px 12px rgba(0, 0, 0, .85), 0 0 12px rgba(63, 231, 255, .2);
}
.mini-reels img { width: 44px; height: 44px; object-fit: contain; border-radius: 5px; }
.mini-deck {
  margin: auto -6px 6px; height: 22px; border-radius: 7px;
  background: linear-gradient(180deg, #24316b, #0a1030); border: 1px solid rgba(233, 196, 106, .55);
  border-bottom: 3px solid #c89634;
  display: grid; place-items: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 6px 12px rgba(0, 0, 0, .7);
}
.mini-deck span { width: 28px; height: 12px; border-radius: 999px; background: radial-gradient(circle at 40% 35%, #ff7a6e, #e10600 65%, #7a0300); border: 1px solid var(--gold); }
.mini-fan { position: relative; width: 190px; height: 150px; }
.mini-card { position: absolute; width: 84px; top: 6px; left: 53px; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .6)); transform-origin: 50% 110%; }
.mini-card svg, .mini-card img { display: block; width: 100%; height: auto; }
.mini-card.c1 { transform: rotate(-20deg); }
.mini-card.c2 { transform: rotate(0deg); }
.mini-card.c3 { transform: rotate(20deg); }
.mini-chips { position: absolute; bottom: -4px; display: flex; gap: 0; }
.mini-chips img { width: 50px; height: 50px; margin-left: -10px; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .6)); }
.mini-dice { display: flex; gap: 6px; align-items: center; }
.mini-die {
  width: 74px; height: 74px; border-radius: 16px; padding: 7px; background: var(--die);
  border: 2px solid var(--gold); box-shadow: inset -6px -8px 14px rgba(0, 0, 0, .4), inset 4px 4px 10px rgba(255, 255, 255, .22), 0 10px 18px rgba(0, 0, 0, .55);
}
.mini-die-med { width: 100%; height: 100%; border-radius: 10px; overflow: hidden; border: 2px solid rgba(233, 196, 106, .92); box-shadow: inset 0 3px 6px rgba(0, 0, 0, .75); background: #040a26; }
.mini-die-med img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.16); display: block; }
.mini-die:nth-child(2) { width: 84px; height: 84px; margin-top: -24px; }

.lobby-foot { display: flex; justify-content: center; align-items: center; gap: 16px; flex-wrap: wrap; margin: 26px auto 0; color: var(--muted); font-size: 13px; font-weight: 400; text-align: center; }
.ghost-btn {
  display: inline-block; margin: 0; padding: 8px 16px; border-radius: 999px; cursor: pointer; text-decoration: none;
  background: transparent; color: var(--gold); border: 1px solid rgba(233, 196, 106, .55); font-size: 13px; letter-spacing: .14em; text-transform: uppercase;
}
.ghost-btn:hover { background: rgba(233, 196, 106, .12); }

/* ---------- Shared game chrome ---------- */
.game-head { display: flex; align-items: center; justify-content: center; gap: 10px; max-width: 1200px; margin: 0 auto 8px; }
.game-head h1 { margin: 0; font-family: var(--f-serif); font-size: clamp(24px, 3vw, 38px); font-weight: 900; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.game-head .sub { color: var(--muted); font-size: 13px; letter-spacing: .2em; text-transform: uppercase; }
.pill-btn {
  padding: 9px 16px; border-radius: 999px; background: rgba(5, 13, 44, .8); color: var(--ink); cursor: pointer;
  border: 1px solid rgba(233, 196, 106, .45); font-size: 13px; letter-spacing: .14em; text-transform: uppercase; text-decoration: none; white-space: nowrap;
}
.pill-btn:hover { border-color: var(--gold); }
.btn {
  --b: var(--gold);
  appearance: none; border: none; cursor: pointer; border-radius: 12px; padding: 12px 18px; min-width: 96px;
  font-family: var(--f-ui); font-weight: 700; font-size: 16px; letter-spacing: .16em; text-transform: uppercase; color: #120c00;
  background: var(--gold-grad); box-shadow: 0 4px 0 var(--gold-lo), 0 8px 20px rgba(0, 0, 0, .5), 0 0 18px rgba(233, 196, 106, .3);
  transition: transform .1s, filter .2s, opacity .2s;
}
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--gold-lo), 0 4px 10px rgba(0, 0, 0, .5); }
.btn:disabled { opacity: .35; cursor: not-allowed; filter: grayscale(.6); transform: none; }
.btn.red { background: linear-gradient(180deg, #ff6a5c, #e10600 55%, #9a0400); color: #fff; box-shadow: 0 4px 0 #6a0300, 0 8px 20px rgba(0, 0, 0, .5), 0 0 18px rgba(225, 6, 0, .4); }
.btn.blue { background: linear-gradient(180deg, #4f7bff, #1d3fbf 55%, #0d2470); color: #fff; box-shadow: 0 4px 0 #071746, 0 8px 20px rgba(0, 0, 0, .5), 0 0 18px rgba(79, 123, 255, .35); }
.btn.green { background: linear-gradient(180deg, #7bffb6, #19c769 55%, #0b7a3d); color: #04140b; box-shadow: 0 4px 0 #064d26, 0 8px 20px rgba(0, 0, 0, .5), 0 0 18px rgba(43, 255, 136, .35); }
.btn.dark { background: linear-gradient(180deg, #2a335e, #141a3a); color: var(--ink); box-shadow: 0 4px 0 #070a1c, 0 8px 20px rgba(0, 0, 0, .5); border: 1px solid rgba(233, 196, 106, .4); }

.loading { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 120px 20px; color: var(--muted); letter-spacing: .2em; text-transform: uppercase; text-align: center; }
.loading span { width: 44px; height: 44px; border-radius: 50%; border: 3px solid rgba(233, 196, 106, .2); border-top-color: var(--gold); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg) } }

/* toast & modal */
.toast {
  position: fixed; left: 50%; bottom: max(24px, env(safe-area-inset-bottom)); z-index: 60; transform: translate(-50%, 30px); opacity: 0;
  padding: 12px 20px; border-radius: 12px; background: rgba(5, 13, 44, .95); border: 1px solid var(--gold); color: var(--ink);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .6); transition: all .3s; pointer-events: none; max-width: 90vw; text-align: center; font-weight: 400;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.good { border-color: var(--green); }
.toast.bad { border-color: var(--pink); }
.modal-wrap {
  position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(2, 5, 20, .72); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; transition: opacity .3s;
}
.modal-wrap.in { opacity: 1; }
.modal {
  position: relative; width: min(760px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: clamp(18px, 3vw, 32px);
  border-radius: 20px; text-align: center;
  background: radial-gradient(600px 300px at 50% 0, rgba(63, 98, 220, .35), transparent 70%), linear-gradient(180deg, #0c1e5a, #050d2c);
  border: 1px solid var(--gold); box-shadow: 0 0 0 6px rgba(5, 13, 44, .8), 0 0 0 7px rgba(233, 196, 106, .35), 0 30px 80px rgba(0, 0, 0, .7), 0 0 60px rgba(233, 196, 106, .15);
  transform: scale(.92) translateY(10px); transition: transform .35s cubic-bezier(.2, .9, .3, 1.2);
}
.modal-wrap.in .modal { transform: none; }
.modal h2 { margin: 0 0 4px; font-family: var(--f-serif); font-weight: 900; font-size: clamp(26px, 4vw, 40px); background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.modal .kicker { margin: 0 0 6px; letter-spacing: .4em; font-size: 12px; text-transform: uppercase; color: var(--pink); text-shadow: 0 0 10px var(--pink); }
.modal p { color: var(--muted); font-weight: 400; margin: 6px 0 14px; }
.modal .big-win { font-family: var(--f-serif); font-weight: 900; font-size: clamp(40px, 7vw, 72px); color: var(--gold-hi); text-shadow: 0 0 20px rgba(233, 196, 106, .6); margin: 8px 0; }
.modal .row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 10px; }

@media (max-width: 860px) {
  .lobby-hero { grid-template-columns: 1fr; }
  .hero-card { display: none; }
  .bays { grid-template-columns: 1fr; }
  .bay { padding: 18px 14px 20px; }
  .bay-art { height: 128px; }
  .bay-art > * { transform: scale(.76); }
  .bay-board { margin: 4px 0 2px; }
  .bay-title { margin: 6px 0 4px; }
  .bay-desc { min-height: 0; margin-bottom: 12px; font-size: 14px; }
  .garage-beam span { letter-spacing: .25em; padding: 2px 8px; font-size: 11px; }
}
@media (max-width: 640px) {
  .topbar { grid-template-columns: auto 1fr auto; gap: 5px; padding-left: 8px; padding-right: 8px; }
  body:not([data-view="lobby"]) .topbar { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
  body:not([data-view="lobby"]) .brand { display: none; }
  .top-left { gap: 4px; }
  .back-btn { font-size: 0; padding: 0; width: 28px; height: 28px; display: grid; place-items: center; }
  .back-btn span { font-size: 18px; }
  .top-lobby, .top-help { padding: 4px 8px; font-size: 10px; letter-spacing: .04em; }
  .brand-top { font-size: 8px; letter-spacing: .24em; }
  .brand-neon { font-size: 15px; }
  .top-right { gap: 4px; }
  .credits { padding: 3px 7px 3px 3px; gap: 4px; }
  .credits-chip { width: 18px; height: 18px; }
  .credits-num { font-size: 13px; min-width: 0; }
  .credits-lbl { display: none; }
  .icon-btn { width: 28px; height: 28px; font-size: 13px; }
  .hero-title { font-size: 30px; }
  .hero-sub { font-size: 14px; }
}

/* ---------- Slots ---------- */
.slot-stage {
  position: relative; width: min(520px, 100%); margin: 0 auto; aspect-ratio: 3 / 4.7;
  border-radius: 22px; overflow: hidden;
  box-shadow: 0 0 0 2px var(--gold), 0 0 0 7px #0a0503, 0 0 0 8px rgba(233, 196, 106, .4), 0 30px 70px rgba(0, 0, 0, .6);
}
.slot-canvas { width: 100%; height: 100%; display: block; }
.slot-stage .fs-banner { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); z-index: 4; }
.reel-window { position: absolute; z-index: 3; pointer-events: none; }
.slot-stage .lines-overlay, .slot-stage .win-flash { position: absolute; inset: 0; }
.slot-credit { margin: 8px auto 0; max-width: 70ch; text-align: center; color: var(--muted); font-size: 12px; font-weight: 400; letter-spacing: .04em; }
.cabinet.slot-panel { width: min(980px, 100%); margin: 8px auto 0; padding: 4px 6px 10px; border-radius: 0; background: transparent; border: none; box-shadow: none; }
.slot-panel .status-bar, .slot-panel .controls { margin-left: 8px; margin-right: 8px; }
#view-slots { --cell: clamp(74px, min(10.1vh, calc((100vw - 110px) / 5)), 98px); }
#view-slots .game-head { margin-bottom: 4px; }
#view-slots .game-head h1 { font-size: clamp(22px, 2.4vw, 30px); }
.head-mid { text-align: center; }
.cabinet {
  position: relative; width: fit-content; margin: 0 auto; padding: 0 0 12px;
  border-radius: 34px 34px 20px 20px;
  background: linear-gradient(90deg, #1b2548 0%, #0b112c 7%, #060a20 50%, #0b112c 93%, #1b2548 100%);
  border: 2px solid #cfa349;
  box-shadow: inset 0 2px 1px rgba(255, 244, 200, .42), inset 12px 0 18px rgba(0, 0, 0, .62), inset -12px 0 18px rgba(0, 0, 0, .62), 0 0 0 6px #060a1e, 0 0 0 8px rgba(233, 196, 106, .42), 0 14px 0 -4px #030612, 0 36px 72px rgba(0, 0, 0, .82);
}
.cab-topper {
  position: relative; z-index: 2;
  padding: 0 16px 6px; border-radius: 32px 32px 0 0;
  border-bottom: 3px solid #c99a3e;
  background: linear-gradient(180deg, rgba(255, 255, 255, .11) 0%, transparent 18%), radial-gradient(620px 150px at 50% 0, rgba(255, 63, 180, .28), rgba(14, 22, 68, .92) 74%, #060b24 100%);
  box-shadow: 0 10px 20px rgba(0, 0, 0, .72), inset 0 -2px 5px rgba(0, 0, 0, .65);
}
.cab-body { display: flex; align-items: stretch; justify-content: center; gap: 8px; padding: 8px 10px 6px; }
.cab-pillar {
  width: 15px; flex: none; border-radius: 999px;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  padding: 10px 0;
  background: linear-gradient(180deg, rgba(63, 231, 255, .92), rgba(255, 63, 180, .92));
  box-shadow: 0 0 0 2px #040716, 0 0 0 3px rgba(233, 196, 106, .35), 0 0 16px rgba(63, 231, 255, .5), 0 0 26px rgba(255, 63, 180, .4), inset 0 0 5px rgba(255, 255, 255, .85);
}
.cab-pillar i {
  width: 7px; height: 7px; border-radius: 50%;
  background: #fff2b8; border: 1px solid rgba(120, 74, 0, .55);
  box-shadow: 0 0 6px #ffd23f, 0 0 12px #ffb000;
  animation: bulb 1.1s infinite;
}
.cab-pillar i:nth-child(2n) { animation-delay: .55s; }
#view-slots.free-mode .cab-pillar {
  background: linear-gradient(180deg, #9bffc8, #19c769);
  box-shadow: 0 0 0 2px #040716, 0 0 0 3px rgba(43, 255, 136, .4), 0 0 18px rgba(43, 255, 136, .65), inset 0 0 5px rgba(255, 255, 255, .85);
}
#view-slots.free-mode .cab-pillar i {
  background: #e2fff0; box-shadow: 0 0 8px var(--green), 0 0 14px var(--green); animation-duration: .42s;
}
#view-slots.lights-mode .cab-pillar {
  background: linear-gradient(180deg, #ff7a5c, #e10600);
  box-shadow: 0 0 0 2px #040716, 0 0 0 3px rgba(255, 42, 42, .45), 0 0 20px rgba(255, 42, 42, .75), inset 0 0 5px rgba(255, 255, 255, .85);
}
.cab-stage { flex: 0 1 auto; min-width: 0; width: calc(var(--cell) * 5 + 84px); max-width: 100%; }
.cab-screen-bezel {
  padding: 11px; border-radius: 18px;
  background: linear-gradient(180deg, #05091a 0%, #111a3e 52%, #1d2959 100%);
  border: 2px solid rgba(233, 196, 106, .58);
  border-top-color: rgba(120, 86, 20, .8);
  border-bottom-color: rgba(255, 234, 165, .78);
  box-shadow: inset 0 14px 26px rgba(0, 0, 0, .92), inset 0 -4px 10px rgba(255, 255, 255, .12), 0 8px 20px rgba(0, 0, 0, .72);
}
.screen-glass {
  position: absolute; inset: 0; pointer-events: none; z-index: 6;
  background: linear-gradient(128deg, rgba(255, 255, 255, .09) 0%, rgba(255, 255, 255, .02) 22%, transparent 36%, transparent 76%, rgba(255, 255, 255, .04) 100%);
}
.cab-deck {
  position: relative; z-index: 3; width: calc(100% + 28px); max-width: calc(100vw - 16px);
  margin: 4px -14px 0; padding: 8px 14px 10px; border-radius: 14px 14px 12px 12px;
  background: linear-gradient(180deg, #24316b 0%, #121a46 28%, #0a1030 74%, #060a22 100%);
  border: 1.5px solid rgba(233, 196, 106, .58);
  border-top-color: rgba(255, 236, 175, .78);
  box-shadow: inset 0 2px 1px rgba(255, 255, 255, .24), inset 0 -4px 10px rgba(0, 0, 0, .55), 0 18px 28px rgba(0, 0, 0, .82);
}
.cab-deck-lip {
  height: 12px; margin: 8px -14px -10px; border-radius: 0 0 11px 11px;
  background: linear-gradient(180deg, #f3d589 0%, #c89634 38%, #6d4b0a 78%, #2e1d03 100%);
  border-top: 1px solid rgba(255, 248, 215, .85);
  box-shadow: 0 8px 16px rgba(0, 0, 0, .75);
}
.cab-belly {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 8px 18px 0; padding: 5px 14px; border-radius: 10px;
  background: linear-gradient(180deg, #060b24, #0a143e 45%, #04081d); border: 1px solid rgba(233, 196, 106, .38);
  box-shadow: inset 0 10px 16px rgba(0, 0, 0, .82), inset 0 -1px 0 rgba(233, 196, 106, .25);
  color: rgba(233, 196, 106, .85); font-size: 11px; letter-spacing: .24em; text-transform: uppercase;
}
.drawer-handle {
  appearance: none; border: none; background: transparent; color: var(--gold-hi);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--f-ui); font-size: 11px; font-weight: 600; letter-spacing: .24em; text-transform: uppercase;
  cursor: pointer; padding: 3px 10px; border-radius: 6px; transition: color .2s, background .2s;
}
.drawer-handle:hover { background: rgba(233, 196, 106, .14); color: #fff; }
.drawer-chevron { font-style: normal; font-size: 14px; color: var(--gold); transition: transform .28s ease; display: inline-block; }
.drawer-handle[aria-expanded="true"] .drawer-chevron { transform: rotate(180deg); }
.pt-drawer {
  max-height: 0; overflow: hidden; opacity: 0;
  width: calc(var(--cell) * 5 + 106px); max-width: calc(100% - 20px);
  margin: 0 auto; border-radius: 0 0 16px 16px;
  background: linear-gradient(180deg, #071138 0%, #040920 100%);
  border: 0 solid rgba(233, 196, 106, .48);
  box-shadow: inset 0 10px 24px rgba(0, 0, 0, .85), 0 22px 44px rgba(0, 0, 0, .78);
  transition: max-height .42s cubic-bezier(.22, .88, .32, 1), opacity .28s ease, padding .3s ease, margin .3s ease, border-width .2s;
}
.pt-drawer.open {
  max-height: 920px; opacity: 1; margin-top: 4px;
  border-width: 1.5px; border-top: none;
}
.pt-drawer-inner { padding: 14px 16px 18px; text-align: left; }
.pt-drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.pt-drawer-head .kicker { display: block; font-size: 10px; letter-spacing: .34em; text-transform: uppercase; color: var(--pink); }
.pt-drawer-head h3 { margin: 0; font-family: var(--f-serif); font-size: 22px; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pt-drawer-note { margin: 0 0 10px; font-size: 12.5px; color: var(--muted); font-weight: 400; }
.pt-scatters-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 10px; }
.pt-scatters-grid .pt-scatter { margin: 0; padding: 8px 10px; border-radius: 10px; background: rgba(2, 6, 24, .75); border: 1px solid rgba(233, 196, 106, .22); font-size: 12.5px; }
.pt-scatters-grid .pt-scatter img { width: 42px; height: 42px; flex: none; }
.pt-test-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin-top: 14px; padding: 10px 14px; border-radius: 12px;
  background: linear-gradient(180deg, rgba(24, 24, 72, .9), rgba(8, 12, 42, .95));
  border: 1.5px dashed rgba(255, 63, 180, .65);
}
.pt-test-copy { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 240px; }
.pt-test-copy b { font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-hi); }
.pt-test-copy span { font-size: 12px; color: var(--muted); line-height: 1.3; font-weight: 400; }
.test-mode-btn {
  background: linear-gradient(180deg, #ff6a5c, #d9140b); border-color: #ffe29a; color: #fff;
  box-shadow: 0 3px 0 #5c0400, 0 0 16px rgba(225, 6, 0, .45);
}
.test-mode-btn.active {
  background: linear-gradient(180deg, #7bffb6, #14b85e); border-color: #d8ffeb; color: #04180d;
  box-shadow: 0 3px 0 #064a24, 0 0 18px rgba(43, 255, 136, .55);
}
.cab-grille {
  width: 46px; height: 10px; border-radius: 4px;
  background: repeating-linear-gradient(90deg, rgba(233, 196, 106, .35) 0 2px, #020512 2px 5px);
  border: 1px solid rgba(233, 196, 106, .25);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, .85);
}
.marquee { position: relative; text-align: center; padding: 10px 24px 6px; margin: 0 -8px; }
@keyframes bulb { 50% { opacity: .25; box-shadow: none; } }
.marquee-text { font-family: var(--f-neon); font-size: clamp(24px, 3.3vw, 40px); line-height: 1.15; color: #e6f6ff; word-spacing: .2em;
  text-shadow: 0 0 4px #fff, 0 0 12px var(--cyan), 0 0 26px #00a2ff; }
.marquee-text b { font-weight: 400; color: #ffe3f5; text-shadow: 0 0 4px #fff, 0 0 12px var(--pink), 0 0 26px #ff0090; }
.mq-sub { margin-top: 3px; font-size: 11px; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.mq-sub .g { color: var(--green); } .mq-sub .a { color: #ffb000; } .mq-sub .k { color: var(--gold); }
.fs-banner {
  display: flex; align-items: center; justify-content: center; gap: 10px; margin: 0 auto 10px; padding: 8px 14px; width: fit-content;
  border-radius: 999px; border: 1px solid var(--green); background: rgba(4, 23, 14, .9); color: #c9ffe0; letter-spacing: .16em; text-transform: uppercase; font-size: 14px;
  box-shadow: 0 0 22px rgba(43, 255, 136, .35);
}
.fs-banner b { color: var(--green); }
.fs-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); animation: bulb .8s infinite; }
.reel-zone { display: flex; align-items: stretch; justify-content: center; gap: 6px; }
.line-tags { display: grid; grid-template-rows: repeat(3, 1fr); grid-auto-flow: row; position: relative; width: 22px; }
.line-tags span {
  position: absolute; left: 0; width: 22px; height: 18px; border-radius: 4px; font-size: 11px; font-weight: 700; display: grid; place-items: center;
  top: calc((var(--r) + .5) * var(--cell) - 9px); color: #0a0f2a; background: var(--c); opacity: .48; cursor: pointer; transition: opacity .15s, transform .15s, box-shadow .15s;
}
.line-tags span:hover { opacity: 1; box-shadow: 0 0 12px var(--c); z-index: 3; }
.line-tags span:nth-child(n+4) { margin-top: calc((var(--i, 0)) * 1px); }
.line-tags span:nth-child(4), .line-tags span:nth-child(5) { transform: translateY(-20px); }
.line-tags span:nth-child(6), .line-tags span:nth-child(7) { transform: translateY(20px); }
.line-tags span:nth-child(8), .line-tags span:nth-child(9) { transform: translateY(-40px); }
.line-tags span:nth-child(10) { transform: translateY(40px); }
.line-tags span.on { opacity: 1; box-shadow: 0 0 10px var(--c); }
.reels {
  position: relative; display: grid; grid-template-columns: repeat(5, var(--cell)); gap: 0;
  padding: 0; border-radius: 14px; overflow: hidden;
  border: 3px solid transparent;
  background: linear-gradient(180deg, #060d2a 0%, #03071a 52%, #020411 100%) padding-box, var(--gold-grad) border-box;
  box-shadow: 0 0 0 3px #1b0d33, 0 0 30px rgba(233, 196, 106, .35), inset 0 0 18px rgba(0, 0, 0, .55);
}
#view-slots.free-mode .reels { background-image: linear-gradient(180deg, #0b2a2a, #04121a); }
#view-slots.lights-mode .reels { background-image: linear-gradient(180deg, #2a0b14, #12040a); }
.reel { position: relative; height: calc(var(--cell) * 3); overflow: hidden; border-right: 1px solid rgba(233, 196, 106, .22); }
.reel:last-of-type { border-right: none; }
.reel::before, .reel::after { content: ''; position: absolute; left: 0; right: 0; height: 20%; z-index: 2; pointer-events: none; }
.reel::before { top: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .86) 0%, rgba(0, 0, 0, .24) 55%, transparent 100%); }
.reel::after { bottom: 0; background: linear-gradient(0deg, rgba(0, 0, 0, .86) 0%, rgba(0, 0, 0, .24) 55%, transparent 100%); }
.reel.spinning::after { height: 34%; animation: gloss 210ms linear infinite; background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .24), transparent); }
@keyframes gloss { from { transform: translateY(-120%); } to { transform: translateY(420%); } }
.reel.tease { animation: tease 320ms ease-in-out infinite; background: radial-gradient(ellipse at 50% 50%, rgba(255, 160, 0, .26), transparent 72%); }
@keyframes tease {
  0%, 100% { box-shadow: inset 0 0 0 2px rgba(255, 176, 0, .55), inset 0 0 18px rgba(255, 120, 0, .35); }
  50% { box-shadow: inset 0 0 0 4px #ffd23f, inset 0 0 32px rgba(255, 63, 180, .65); }
}
.reel.reel-thud { animation: reelThud 220ms cubic-bezier(.22, .68, .35, 1.2); }
@keyframes reelThud {
  0% { transform: translateY(5px); }
  55% { transform: translateY(-2px); }
  100% { transform: translateY(0); }
}
.strip { will-change: transform; }
.strip.blur { filter: blur(1.8px) brightness(1.18) saturate(1.12); }
.cell { height: var(--cell); display: grid; place-items: center; padding: 6%; position: relative; }
.cell img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .6)); user-select: none; transition: transform .22s, filter .22s; }
.cell.cell-land img { animation: cellLand 420ms cubic-bezier(.18, .88, .32, 1.35); filter: drop-shadow(0 0 14px rgba(255, 215, 90, .9)); }
@keyframes cellLand {
  0% { transform: scale(.78); }
  55% { transform: scale(1.18); }
  100% { transform: scale(1); }
}
.cell.lamp-off img { filter: grayscale(1) brightness(.35); }
.lamp-ring { position: absolute; inset: 10%; border-radius: 50%; border: 3px solid #fff; animation: bloom 400ms ease-out forwards; pointer-events: none; }
@keyframes bloom { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.6); opacity: 0; } }
.cell.shimmer::after { content: ''; position: absolute; inset: 0; background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.45), transparent 70%); animation: sweep 600ms linear; }
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.cell.spin-symbol img { animation: spinY 500ms linear; }
@keyframes spinY { to { transform: rotate(360deg); } }
.cell.locked { box-shadow: inset 0 0 0 3px #e9c46a; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer {
  0%, 100% { box-shadow: inset 0 0 0 3px #e9c46a, 0 0 10px rgba(233, 196, 106, .35); }
  50% { box-shadow: inset 0 0 0 3px #fff4cc, 0 0 22px rgba(255, 224, 138, .85); }
}
.reels.has-win .cell:not(.win) img { opacity: .35; filter: grayscale(.4) brightness(.65); }
.lock-layer { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(3, 1fr); pointer-events: none; z-index: 4; }
.lock-layer i { grid-column: calc(var(--i) + 1); grid-row: calc(var(--j) + 1); display: grid; place-items: center; }
.lock-layer img { width: 86%; height: 86%; object-fit: contain; filter: drop-shadow(0 0 8px #e9c46a); }
.coin-canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 5; }
.pole-ghost { position: fixed; width: 64px; height: 64px; z-index: 40; pointer-events: none; }
.bonus-lamps { display: flex; justify-content: center; gap: 6px; height: 0; overflow: hidden; }
.bonus-lamps.on { height: auto; margin: 0 0 6px; }
.bonus-lamps i { width: 12px; height: 12px; border-radius: 50%; background: #2a140c; border: 1px solid #e9c46a; }
.bonus-lamps i.lit { background: #ffd23f; box-shadow: 0 0 8px #ffd23f; }
.slot-layout { display: flex; align-items: flex-start; justify-content: center; width: 100%; }
.fuel-tank { width: 100%; margin: 0 auto 8px; }
.tank-card {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; max-width: 100%; margin: 0 auto; padding: 6px 10px 5px; border-radius: 14px;
  background: linear-gradient(180deg, #131c44, #060b24);
  border: 1.5px solid rgba(233, 196, 106, .48);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 8px 20px rgba(0, 0, 0, .55);
  color: var(--gold-hi);
}
.tanks-trio {
  display: grid; grid-template-columns: repeat(3, 1fr); align-items: center; justify-items: center;
  gap: 8px; width: 100%;
}
.tank-unit { position: relative; display: flex; align-items: center; justify-content: center; transition: transform .25s, filter .25s; }
.tank-unit.surge { animation: tankSurge 560ms ease-out; }
.tank-horiz {
  width: 152px; height: 50px; display: flex; align-items: center; justify-content: center;
  overflow: hidden; border-radius: 10px; border: 1.5px solid rgba(233, 196, 106, .65);
  background: #03081c; box-shadow: inset 0 2px 8px rgba(0, 0, 0, .85); flex: none;
}
.tank-unit.tank-green .tank-horiz { border-color: rgba(43, 255, 136, .75); box-shadow: inset 0 2px 8px rgba(0, 0, 0, .85), 0 0 12px rgba(43, 255, 136, .22); }
.tank-unit.tank-yellow .tank-horiz { border-color: rgba(255, 210, 63, .82); box-shadow: inset 0 2px 8px rgba(0, 0, 0, .85), 0 0 14px rgba(255, 210, 63, .28); }
.tank-unit.tank-red .tank-horiz { border-color: rgba(255, 58, 48, .82); box-shadow: inset 0 2px 8px rgba(0, 0, 0, .85), 0 0 14px rgba(255, 58, 48, .25); }
.tank-art { position: relative; width: 92px; aspect-ratio: 576 / 1024; transform: rotate(90deg); flex: none; }
.tank-art img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 10px; }
.tank-glass { position: absolute; left: 40.5%; right: 40.2%; top: 30%; bottom: 22.8%; overflow: hidden; border-radius: 5px; background: rgba(5, 11, 28, .9); box-shadow: inset 0 0 8px rgba(0, 0, 0, .85); }
.tank-fill { position: absolute; left: 0; right: 0; bottom: 0; background: linear-gradient(180deg, #ffe08a, #e39b00 55%, #ffb000); box-shadow: 0 0 10px rgba(255, 200, 60, .6); transition: height 400ms ease; }
.tank-unit.tank-green .tank-fill {
  background: linear-gradient(180deg, #b8ffd8 0%, #19d873 52%, #078c42 100%);
  box-shadow: 0 0 12px rgba(43, 255, 136, .85);
}
.tank-unit.tank-yellow .tank-fill {
  background: linear-gradient(180deg, #fff3b0 0%, #ffd23f 50%, #e08b00 100%);
  box-shadow: 0 0 12px rgba(255, 210, 63, .85);
}
.tank-unit.tank-red .tank-fill {
  background: linear-gradient(180deg, #ffb4a8 0%, #ff2a1f 52%, #9e0400 100%);
  box-shadow: 0 0 12px rgba(255, 48, 36, .9);
}
.tank-unit.hot .tank-fill { animation: hotPulse 1.1s ease-in-out infinite; }
@keyframes hotPulse { 50% { filter: brightness(1.28) saturate(1.2); } }
.tank-ticks { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-evenly; pointer-events: none; z-index: 2; }
.tank-ticks i { height: 1px; margin-left: 42%; margin-right: 6%; background: rgba(255, 226, 140, .82); }
.tank-tagline {
  font-size: 11.5px; font-weight: 700; letter-spacing: .26em; text-transform: uppercase;
  color: var(--gold-hi); text-align: center; text-shadow: 0 0 10px rgba(233, 196, 106, .45);
}
.fs-banner img { width: 28px; height: 28px; object-fit: contain; }
.pick-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pick { background: #0b1747; border: 1px solid var(--gold); border-radius: 12px; color: var(--ink); padding: 8px; cursor: pointer; }
.pick img { width: 100%; aspect-ratio: 1; object-fit: contain; }
.pick span { display: block; font-size: 11px; color: var(--muted); font-weight: 400; }
.pt-head, .pt-row { grid-template-columns: 46px 1fr 48px 48px 48px 48px; }
@media (max-width: 760px) {
  .slot-layout { flex-direction: column; align-items: center; }
  .cab-deck { margin: 4px 6px 0; }
  .tank-card { padding: 5px 8px 4px; gap: 3px; }
  .tanks-trio { gap: 5px; }
  .tank-horiz { width: 100px; height: 36px; }
  .tank-art { width: 64px; }
  .tank-tagline { font-size: 10px; letter-spacing: .18em; }
  .pick-row { grid-template-columns: 1fr 1fr; }
}
.tank-card.surge { animation: tankSurge 560ms ease-out; }
@keyframes tankSurge {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255, 210, 63, .9); }
  40% { transform: scale(1.06); border-color: #fff2a6; box-shadow: 0 0 28px rgba(255, 210, 63, .85), inset 0 0 16px rgba(255, 210, 63, .45); }
  100% { transform: scale(1); }
}
.cabinet.win-pulse { animation: cabPulse 900ms ease-in-out 2; }
@keyframes cabPulse {
  50% { box-shadow: inset 0 2px 1px rgba(255, 244, 200, .55), 0 0 0 6px #060a1e, 0 0 0 8px #ffd23f, 0 0 46px rgba(255, 210, 63, .65), 0 36px 72px rgba(0, 0, 0, .82); }
}
.cell.win { animation: pop .75s ease-in-out infinite; z-index: 2; }
.cell.win img { filter: drop-shadow(0 0 14px rgba(255, 215, 80, .95)) brightness(1.12); }
.cell.win::before { content: ''; position: absolute; inset: 4%; border-radius: 14px; border: 2.5px solid #ffe484; background: radial-gradient(circle, rgba(255, 210, 63, .42), transparent 72%); box-shadow: 0 0 20px rgba(255, 210, 63, .9), inset 0 0 12px rgba(255, 210, 63, .45); }
.cell.scatter::before { border-color: var(--green); box-shadow: 0 0 18px var(--green); }
@keyframes pop { 50% { transform: scale(1.11); } }
.line-pill { animation: pillPop 320ms cubic-bezier(.2, .9, .3, 1.3) backwards; animation-delay: 180ms; filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .8)); }
@keyframes pillPop { from { opacity: 0; transform: scale(.5); } }
.lines-overlay { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }
.lines-overlay .ln { stroke-dasharray: 1200; stroke-dashoffset: 1200; animation: draw .7s ease-out forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.win-flash { position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; pointer-events: none; opacity: 0; transition: opacity .3s; padding: 0 12px; text-align: center; }
.win-flash.show { opacity: 1; }
.win-flash span { font-family: var(--f-serif); font-weight: 900; font-style: italic; font-size: clamp(28px, 5.4vw, 62px); color: #fff8dc; padding: 8px 24px; border-radius: 16px; max-width: 92%;
  background: rgba(10, 16, 50, .86); border: 2px solid var(--gold); text-shadow: 0 0 18px var(--gold), 0 0 36px #ff9d00; transform: rotate(-3deg); animation: pop .6s infinite; }
.win-flash.big span { border-color: #ffd23f; text-shadow: 0 0 18px #ffd23f, 0 0 34px #ff9d00; }
.win-flash.mega span { border-color: #ff3fb4; color: #ffe6f6; text-shadow: 0 0 20px #ff3fb4, 0 0 42px #ff0088; }
.win-flash.epic span { border-color: #3fe7ff; color: #e8fcff; text-shadow: 0 0 22px #3fe7ff, 0 0 44px #ffd23f; }
.win-flash.lights span { font-size: clamp(22px, 3.8vw, 44px); border-color: #ff2a2a; color: #fff3f0; background: rgba(28, 4, 10, .9); text-shadow: 0 0 18px #ff2a2a, 0 0 36px #ff7a00; }
.win-flash.tank span { border-color: #ffe08a; color: #fff8dc; background: rgba(18, 12, 4, .88); text-shadow: 0 0 20px #ffb000, 0 0 40px #ffd23f; }
.status-bar { display: grid; grid-template-columns: minmax(0, 1fr) auto 148px; align-items: center; gap: 10px; margin: 0 2px; }
.msg-box, .win-box, .cut-box {
  background: #02061a;
  border: 1.5px solid rgba(233, 196, 106, .48);
  border-top-color: rgba(120, 88, 22, .65);
  border-bottom-color: rgba(255, 232, 162, .72);
  border-radius: 10px;
  box-shadow: inset 0 3px 8px rgba(0, 0, 0, .92), inset 0 -1px 0 rgba(255, 255, 255, .08), 0 1px 0 rgba(255, 255, 255, .12);
}
.msg-box {
  padding: 5px 10px; min-height: 40px; display: flex; align-items: center; justify-self: stretch; min-width: 0;
}
.msg {
  font-size: 11.5px; color: #dbe3ff; font-weight: 500; letter-spacing: .03em; line-height: 1.2;
  width: 100%; overflow: hidden; text-overflow: ellipsis;
}
.win-box {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 5px 12px; min-height: 40px; width: 148px; min-width: 0; justify-self: end;
}
.win-box span { font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--muted); }
.win-box b { font-size: 23px; color: var(--gold-hi); font-variant-numeric: tabular-nums; text-shadow: 0 0 10px rgba(233, 196, 106, .5); }
.spin-well {
  padding: 4px 6px 7px; border-radius: 12px;
  background: linear-gradient(180deg, #020410 0%, #09102e 100%);
  border: 1.5px solid rgba(233, 196, 106, .55);
  box-shadow: inset 0 5px 10px rgba(0, 0, 0, .95), 0 2px 0 rgba(255, 240, 190, .25);
  display: flex; align-items: center; justify-content: center;
}
.spin-btn {
  min-width: 154px; height: 36px; padding: 0 18px; border-radius: 8px; cursor: pointer;
  border: 1.5px solid #ffd88a; position: relative;
  background: linear-gradient(180deg, #ff7e70 0%, #e8140b 45%, #a10400 100%);
  box-shadow:
    0 5px 0 #520100,
    0 7px 14px rgba(0, 0, 0, .85),
    0 0 18px rgba(225, 6, 0, .48),
    inset 0 2px 2px rgba(255, 255, 255, .52),
    inset 0 -3px 6px rgba(70, 0, 0, .6);
  color: #fff; font-family: var(--f-ui); font-weight: 700; font-size: 15px; letter-spacing: .22em; text-transform: uppercase;
  transition: transform 80ms ease, box-shadow 80ms ease, filter .18s;
  transform: translateY(-2px);
}
.spin-btn span { text-shadow: 0 2px 3px rgba(0, 0, 0, .65); }
.spin-btn:hover:not(:disabled) { filter: brightness(1.1); }
.spin-btn:active:not(:disabled), .spin-btn.pressed {
  transform: translateY(3px);
  box-shadow:
    0 1px 0 #520100,
    0 2px 5px rgba(0, 0, 0, .85),
    0 0 12px rgba(225, 6, 0, .4),
    inset 0 2px 5px rgba(60, 0, 0, .7);
}
.spin-btn:disabled {
  transform: translateY(2px);
  box-shadow: 0 2px 0 #3a0200, 0 3px 6px rgba(0, 0, 0, .7);
  filter: saturate(.55) brightness(.78); cursor: progress;
}
.free-mode .spin-btn {
  border-color: #b7ffd8;
  background: linear-gradient(180deg, #8affc1 0%, #19c769 48%, #096331 100%);
  box-shadow: 0 5px 0 #04381a, 0 7px 14px rgba(0, 0, 0, .85), 0 0 22px rgba(43, 255, 136, .55), inset 0 2px 2px rgba(255, 255, 255, .55);
  color: #031a0c;
}
.controls { display: grid; grid-template-columns: 1fr 1fr; align-items: stretch; gap: 14px; margin: 8px 4px 0; }
.bet-ctl.cut-box {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 5px 12px;
}
.round-btn {
  width: 34px; height: 34px; border-radius: 8px; border: 1px solid var(--gold);
  background: linear-gradient(180deg, #172a74, #09133c); color: var(--gold-hi); font-size: 20px;
  cursor: pointer; line-height: 1;
  box-shadow: 0 3px 0 #030718, inset 0 1px 1px rgba(255, 255, 255, .25);
  transition: transform 80ms ease, box-shadow 80ms ease, background .15s;
}
.round-btn:hover { background: linear-gradient(180deg, #213a99, #0d1b52); }
.round-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #030718; }
.bet-read { display: flex; flex-direction: column; align-items: center; min-width: 74px; line-height: 1.1; }
.bet-read span { font-size: 10.5px; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }
.bet-read b { font-size: 23px; color: var(--gold-hi); font-variant-numeric: tabular-nums; text-shadow: 0 0 10px rgba(233, 196, 106, .35); }
.bet-read.total.cut-box {
  flex-direction: row; align-items: baseline; justify-content: space-between;
  padding: 6px 16px; min-width: 156px;
}

/* bonus modals */
.bonus-art { width: 164px; margin: 10px auto; filter: drop-shadow(0 0 20px rgba(43, 255, 136, .5)); }
.bonus-art img { width: 100%; height: auto; display: block; border-radius: 16px; }
.gold { color: var(--gold-hi); }
.tyre-pick { display: flex; justify-content: center; gap: clamp(10px, 3vw, 28px); margin: 18px 0 6px; flex-wrap: wrap; }
.tp {
  width: clamp(120px, 26vw, 180px); padding: 14px 10px 16px; border-radius: 16px; cursor: pointer; color: var(--ink);
  background: linear-gradient(180deg, #13296d, #071440); border: 1px solid rgba(233, 196, 106, .5);
  display: flex; flex-direction: column; align-items: center; gap: 8px; transition: transform .2s, box-shadow .2s, opacity .3s;
}
.tp img { width: 82%; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .5)); transition: transform .6s; }
.tp:hover img { transform: rotate(40deg); }
.tp:hover { transform: translateY(-4px); box-shadow: 0 0 24px rgba(233, 196, 106, .4); }
.tp-name { text-transform: uppercase; letter-spacing: .3em; font-size: 13px; color: var(--muted); }
.tp-prize { font-family: var(--f-serif); font-weight: 900; font-size: 30px; color: var(--gold-hi); min-height: 1.2em; }
.tyre-pick.done .tp { pointer-events: none; }
.tp.chosen { border-color: var(--gold); box-shadow: 0 0 0 2px var(--gold), 0 0 36px rgba(233, 196, 106, .55); transform: translateY(-6px) scale(1.04); }
.tp.other { opacity: .45; }
.pit-stage { display: grid; grid-template-columns: 56px minmax(190px, 240px) 1fr; align-items: center; justify-content: center; gap: 16px; margin: 10px 0 6px; }
.pit-stage.shake { animation: shake .3s; }
@keyframes shake { 25% { transform: translateX(-8px) } 75% { transform: translateX(8px) } }
.pit-lights { display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.pit-lights i { width: 30px; height: 30px; border-radius: 50%; background: #2a0606; border: 3px solid #111; box-shadow: inset 0 0 6px #000; }
.pit-lights i.on { background: radial-gradient(circle at 40% 35%, #ff9a8a, #ff1a00 60%, #8a0000); box-shadow: 0 0 18px #ff2a00, 0 0 34px #ff2a00; }
.pit-box {
  position: relative; width: 100%; aspect-ratio: 680 / 1040; border-radius: 10px;
  border: 2px dashed #ffd23f; background: radial-gradient(circle at 50% 45%, rgba(22, 42, 108, .35), rgba(3, 8, 28, .88));
  box-shadow: inset 0 0 24px rgba(0, 0, 0, .68); overflow: hidden;
}
.pit-car-img { width: 100%; height: 100%; object-fit: contain; display: block; pointer-events: none; user-select: none; }
.pit-box-line {
  position: absolute; left: 6px; right: 6px; bottom: 4px; border-top: 2px solid rgba(255, 255, 255, .45);
  text-align: center; padding-top: 2px; pointer-events: none;
}
.pit-box-line span { font-size: 10px; letter-spacing: .38em; color: var(--muted); text-transform: uppercase; }
.pw { position: absolute; left: var(--x); top: var(--y); width: var(--w); height: var(--h); padding: 0; border: none; background: transparent; cursor: pointer; display: block; }
.pw-ring {
  position: absolute; inset: 0; border-radius: 8px; border: 2px solid rgba(233, 196, 106, .35);
  background: transparent; transition: border-color .15s, box-shadow .15s, background .15s;
}
.pw.lit .pw-ring {
  border: 3px solid var(--pink); background: rgba(255, 63, 180, .18);
  box-shadow: 0 0 18px var(--pink), inset 0 0 12px rgba(255, 63, 180, .4); animation: bulb .4s infinite;
}
.pw.done .pw-ring { border: 3px solid var(--green); background: rgba(43, 255, 136, .16); box-shadow: 0 0 14px var(--green); }
.pw-lbl {
  position: absolute; left: 50%; top: 100%; transform: translateX(-50%); margin-top: 2px;
  font-family: var(--f-ui); font-size: 10px; font-weight: 700; letter-spacing: .1em;
  color: var(--muted); text-shadow: 0 1px 2px #000; pointer-events: none;
}
.pw.lit .pw-lbl { color: #ffd4f0; }
.pw.done .pw-lbl { color: var(--green); }
.pit-side { text-align: left; }
.pit-timer { font-family: var(--f-ui); font-weight: 700; font-size: clamp(40px, 7vw, 64px); color: var(--gold-hi); font-variant-numeric: tabular-nums; text-shadow: 0 0 14px rgba(233, 196, 106, .5); }
.pit-timer small { font-size: .45em; color: var(--muted); margin-left: 4px; }
.pit-tiers { list-style: none; padding: 0; margin: 8px 0 0; font-size: 14px; color: var(--muted); }
.pit-tiers li { padding: 3px 0; border-bottom: 1px dashed rgba(154, 166, 214, .2); display: flex; justify-content: space-between; gap: 14px; max-width: 170px; }
.pit-tiers b { color: var(--gold); }
.pit-result { display: flex; align-items: baseline; justify-content: center; gap: 14px; font-family: var(--f-serif); font-weight: 900; font-size: clamp(26px, 5vw, 44px); margin: 8px 0; }
.pit-result span { color: var(--muted); } .pit-result i { color: var(--pink); text-shadow: 0 0 12px var(--pink); }
.pit-result b { color: var(--gold-hi); font-size: 1.4em; text-shadow: 0 0 20px rgba(233, 196, 106, .6); }
.pt-modal { text-align: left; }
.pt-modal h2, .pt-modal .kicker { text-align: center; }
.pt-head, .pt-row { display: grid; grid-template-columns: 46px 1fr 48px 48px 48px 48px; align-items: center; gap: 8px; padding: 4px 6px; }
.pt-head span:nth-child(2) { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.pt-head b { color: var(--muted); font-size: 12px; letter-spacing: .2em; text-align: right; }
.pt-row { border-bottom: 1px solid rgba(233, 196, 106, .12); }
.pt-row img { width: 42px; height: 42px; }
.pt-row b { text-align: right; color: var(--gold-hi); font-size: 18px; }
.pt-scatter { display: flex; align-items: center; gap: 12px; margin: 12px 6px 0; color: var(--muted); font-weight: 400; }
.pt-scatter img { width: 54px; height: 54px; }
.pt-scatter b { color: var(--ink); font-weight: 600; }
.pt-lines { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin: 16px 0 4px; }
.pt-lines svg { width: 100%; }
.pt-modal .row { justify-content: center; }

@media (max-width: 700px) {
  #view-slots { --cell: calc((100vw - 74px) / 5); padding-left: 6px; padding-right: 6px; }
  .slot-stage { aspect-ratio: 3 / 4.9; width: min(100%, 420px); }
  .cabinet { max-width: 100%; padding: 0 0 10px; border-radius: 22px; }
  .cab-topper { padding: 0 8px 6px; border-radius: 20px 20px 0 0; }
  .cab-body { gap: 5px; padding: 8px 6px 6px; }
  .cab-pillar { width: 10px; padding: 6px 0; }
  .cab-pillar i { width: 5px; height: 5px; }
  .cab-stage { width: auto; flex: 1 1 auto; }
  .cab-screen-bezel { padding: 5px; border-radius: 14px; }
  .cab-deck { width: auto; max-width: none; margin: 4px 6px 0; padding: 8px 8px 10px; }
  .cab-deck-lip { height: 9px; margin: 8px -8px -10px; }
  .cab-belly { margin: 8px 10px 0; padding: 5px 8px; font-size: 9px; letter-spacing: .12em; }
  .drawer-handle { font-size: 9.5px; letter-spacing: .12em; padding: 2px 6px; }
  .pt-drawer { width: auto; max-width: none; margin: 0 10px; }
  .pt-scatters-grid { grid-template-columns: 1fr; }
  .cab-grille { width: 18px; }
  .line-tags { display: none; }
  .marquee { padding: 10px 8px 6px; }
  .mq-sub { font-size: 9px; letter-spacing: .14em; }
  .status-bar { grid-template-columns: 1fr auto; margin: 0 2px; gap: 6px; }
  .msg-box { grid-column: 1 / -1; order: 2; min-height: 32px; padding: 4px 8px; }
  .spin-well { order: 1; }
  .spin-btn { min-width: 132px; height: 34px; font-size: 13px; padding: 0 14px; }
  .msg { font-size: 11.5px; }
  .win-box { order: 1; width: auto; min-width: 108px; min-height: 34px; padding: 4px 10px; }
  .win-box b { font-size: 20px; }
  .controls { margin: 6px 2px 0; gap: 8px; }
  .round-btn { width: 30px; height: 30px; font-size: 18px; }
  .bet-ctl.cut-box { gap: 4px; padding: 4px 8px; }
  .bet-read { min-width: 48px; }
  .bet-read b { font-size: 19px; }
  .bet-read.total.cut-box { min-width: 90px; padding: 4px 10px; }
  .game-head .sub { display: none; }
  .pit-stage { grid-template-columns: 50px 1fr; }
  .pit-side { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; }
  .pit-lights i { width: 22px; height: 22px; }
  .pt-head, .pt-row { grid-template-columns: 34px 1fr 34px 34px 34px 34px; gap: 4px; }
}

/* ---------- Blackjack ---------- */
#view-blackjack { --cw-base: clamp(58px, min(6.6vw, 9.2vh), 96px); --cw: calc(var(--cw-base) * 1.4); }
.bj-gold { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.bj-white { color: #f6f8ff; text-shadow: 0 0 16px rgba(255, 255, 255, .25); }
.bj-wrap { max-width: min(1180px, calc((100vh - 180px) * 1.54)); min-width: min(100%, 640px); margin: 0 auto; }
.bj-dock-head { display: none; }
.bj-rotate-overlay { display: none; }
@media (max-width: 760px) and (orientation: portrait) {
  #view-blackjack .game-head, #view-blackjack .bj-wrap { visibility: hidden; pointer-events: none; }
  #view-blackjack .bj-rotate-overlay {
    display: flex; align-items: center; justify-content: center;
    position: fixed; inset: 58px 0 0; z-index: 35; padding: 20px;
    background: radial-gradient(500px 300px at 50% 35%, rgba(28, 66, 178, .35), rgba(3, 8, 28, .96));
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  }
  .bj-rotate-card {
    width: min(360px, 100%); padding: 26px 22px; border-radius: 20px; text-align: center;
    background: linear-gradient(180deg, #0d2160, #050d2c); border: 1.5px solid var(--gold);
    box-shadow: 0 24px 60px rgba(0, 0, 0, .75), 0 0 40px rgba(233, 196, 106, .18);
  }
  .bj-rotate-icon { font-size: 46px; margin-bottom: 10px; animation: bjTilt 1.6s ease-in-out infinite; display: inline-block; }
  @keyframes bjTilt { 0%, 100% { transform: rotate(0deg); } 50% { transform: rotate(-90deg); } }
  .bj-rotate-card .kicker { margin: 0 0 4px; font-size: 11px; letter-spacing: .34em; text-transform: uppercase; color: var(--pink); }
  .bj-rotate-card h2 { margin: 0 0 8px; font-family: var(--f-serif); font-size: 28px; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
  .bj-rotate-card p { margin: 0 0 18px; font-size: 15px; line-height: 1.45; color: var(--muted); }
}
.bj-rail {
  padding: clamp(10px, 1.6vw, 18px); border-radius: 40px 40px 50% 50% / 40px 40px 34% 34%;
  background: linear-gradient(180deg, #2a1810, #120905 60%, #1d0f08);
  box-shadow: 0 0 0 2px var(--gold), 0 0 0 7px #0a0503, 0 0 0 8px rgba(233, 196, 106, .4), 0 40px 80px rgba(0, 0, 0, .7), inset 0 2px 0 rgba(255, 255, 255, .15), inset 0 -10px 20px rgba(0, 0, 0, .5);
}
.felt {
  position: relative; aspect-ratio: 1000 / 650; overflow: hidden;
  border-radius: 30px 30px 50% 50% / 30px 30px 32% 32%;
  box-shadow: inset 0 0 60px rgba(0, 0, 0, .55), inset 0 0 0 2px rgba(233, 196, 106, .55);
}
.felt-art { position: absolute; inset: 0; width: 100%; height: 100%; }
.felt-rules {
  position: absolute; z-index: 1; left: 50%; transform: translateX(-50%);
  top: calc(2.5% + var(--cw) * 1.4 + 12px);
  width: min(680px, 88%); text-align: center; pointer-events: none; color: #e9c46a;
  text-shadow: 0 1px 0 rgba(0, 0, 0, .55), 0 2px 8px rgba(0, 0, 0, .45);
}
.felt-rule-main {
  margin: 0; font-family: var(--f-serif); font-weight: 700; text-transform: uppercase; line-height: 1.15;
  font-size: clamp(15px, 2vw, 24px); letter-spacing: clamp(0.08em, 0.4vw, 0.2em);
}
.felt-rule-sub {
  margin: 3px auto 0; max-width: 34em; font-weight: 500; text-transform: uppercase; line-height: 1.3;
  font-size: clamp(12px, 1.4vw, 15px); letter-spacing: clamp(0.045em, 0.18vw, 0.14em); opacity: .9;
}
.shoe { position: absolute; top: 6%; right: 6%; width: calc(var(--cw-base) * .9); text-align: center; }
.shoe-card { transform: perspective(300px) rotateX(35deg) rotate(-8deg); filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .6)); }
.shoe-card svg, .shoe-card img { display: block; width: 100%; height: auto; }
.shoe::before { content: ''; position: absolute; inset: -8px -8px 10px; border-radius: 8px; background: linear-gradient(180deg, #1a1f38, #070a1c); border: 1px solid rgba(233, 196, 106, .55); z-index: -1; transform: perspective(300px) rotateX(35deg); }
.shoe span { display: block; margin-top: 4px; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.tray { position: absolute; top: 7%; left: 6%; width: calc(var(--cw-base) * .9); height: calc(var(--cw-base) * .7); border-radius: 8px; border: 1px dashed rgba(233, 196, 106, .35); }
.zone { position: absolute; left: 0; right: 0; display: flex; justify-content: center; align-items: flex-start; gap: 4%; }
.zone::before { content: ''; position: absolute; inset: -6% 20%; background: radial-gradient(closest-side, rgba(120, 170, 255, .16), transparent); z-index: -1; pointer-events: none; }
.dealer-zone { top: 2.5%; flex-direction: row; align-items: center; gap: 10px; }
.dealer-zone .hand { order: 2; }
.dealer-zone .dealer-badge { order: 1; margin: 0; }
.player-zone { top: 43%; }
.player-zone .ph-foot { margin-top: -10px; position: relative; z-index: 2; }
.ph-foot { display: flex; gap: 8px; align-items: center; }
.hand { display: flex; justify-content: center; min-height: calc(var(--cw) * 1.4); }
.pcard { width: var(--cw); aspect-ratio: 100 / 140; perspective: 800px; transition: transform .42s cubic-bezier(.2, .8, .25, 1); }
.pcard.dealing { z-index: 10; filter: drop-shadow(-8px 18px 18px rgba(0, 0, 0, .65)); }
.pcard + .pcard { margin-left: calc(var(--cw) * -.58); }
.pc-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .45s; transform: rotateY(180deg); }
.pcard.up .pc-inner { transform: rotateY(0); }
.pc-face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; filter: drop-shadow(-3px 6px 8px rgba(0, 0, 0, .45)); }
.pc-face svg, .pc-face img, .shoe-card img { width: 100%; height: 100%; display: block; object-fit: cover; border-radius: 7px; box-shadow: 0 0 0 2px #f4efe1, 0 10px 18px rgba(0, 0, 0, .6); }
.pc-front img { filter: contrast(1.06) saturate(1.08); }
.pc-back img { outline: 1px solid rgba(233, 196, 106, .8); outline-offset: -5px; }
.pc-back { transform: rotateY(180deg); }
.pcard.sideways { margin-left: calc(var(--cw) * -.25); margin-top: calc(var(--cw) * .2); }
.pcard.sideways .pc-inner { transform: rotate(90deg); }
.phand { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 14px; transition: background .3s, box-shadow .3s; }
.phand.active { background: rgba(233, 196, 106, .08); box-shadow: 0 0 0 1px rgba(233, 196, 106, .6), 0 0 24px rgba(233, 196, 106, .25); }
.badge {
  min-width: 46px; padding: 3px 12px; border-radius: 999px; text-align: center; font-weight: 700; font-size: 16px;
  background: #050d2c; border: 1px solid var(--gold); color: var(--gold-hi); box-shadow: 0 4px 12px rgba(0, 0, 0, .5);
}
.badge.bust { border-color: var(--pink); color: #ffc2e6; }
.badge.bj { background: var(--gold-grad); color: #1a1000; }
.result { padding: 4px 12px; border-radius: 8px; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; }
.result.win, .result.bj { background: rgba(43, 255, 136, .15); color: var(--green); border: 1px solid var(--green); }
.result.push { background: rgba(255, 255, 255, .08); color: var(--ink); border: 1px solid var(--muted); }
.result.lose, .result.bust { background: rgba(255, 63, 180, .12); color: #ffb3dc; border: 1px solid var(--pink); }
.bet-spot {
  position: absolute; left: 50%; bottom: 2.5%; transform: translateX(-50%); width: calc(var(--cw-base) * 1.08); aspect-ratio: 1;
  border-radius: 12px; border: 2px dashed rgba(255, 210, 63, .8); background: rgba(255, 210, 63, .06);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.bet-spot::before { content: 'SEAT 2'; position: absolute; top: -22px; font-size: 12px; letter-spacing: .28em; color: #ffd23f; text-shadow: 0 1px 2px #000; white-space: nowrap; }
.ai-seat {
  position: absolute; top: 43%; width: 26%; z-index: 2; padding: 8px 10px; border-radius: 14px;
  background: rgba(4, 10, 36, .68); border: 1px solid rgba(233, 196, 106, .35);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  transition: border-color .25s, box-shadow .25s, opacity .3s;
}
.ai-seat.seat-1 { left: 2.5%; }
.ai-seat.seat-3 { right: 2.5%; }
.ai-seat.turn { border-color: var(--gold); box-shadow: 0 0 20px rgba(233, 196, 106, .45); }
.ai-seat.leaving { opacity: .6; }
.ai-seat.empty { display: grid; place-items: center; min-height: 126px; border-style: dashed; border-color: rgba(233, 196, 106, .22); background: rgba(4, 10, 36, .35); }
.ai-empty { text-align: center; color: var(--muted); }
.ai-empty b { display: block; font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: rgba(233, 196, 106, .78); }
.ai-empty span { font-size: 11px; letter-spacing: .08em; }
.ai-head { display: flex; align-items: center; gap: 7px; margin-bottom: 6px; }
.ai-avatar {
  width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
  font-size: 10px; font-weight: 700; color: #fff; background: var(--c); border: 1px solid rgba(255, 255, 255, .45); flex: none;
}
.ai-meta { display: flex; flex-direction: column; min-width: 0; line-height: 1.1; }
.ai-meta b { font-size: 13px; color: var(--ink); }
.ai-meta small { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ai-hand { display: flex; justify-content: center; min-height: calc(var(--cw-ai) * 1.4); --cw-ai: calc(var(--cw) * .6); }
.ai-hand .pcard { width: var(--cw-ai); }
.ai-hand .pcard + .pcard { margin-left: calc(var(--cw-ai) * -.55); }
.ai-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 6px; }
.ai-bet { font-size: 11px; color: var(--gold); letter-spacing: .08em; text-transform: uppercase; }
.ai-badge { padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: #050d2c; border: 1px solid var(--gold); color: var(--gold-hi); }
.ai-badge.bust { border-color: var(--pink); color: #ffc2e6; }
.ai-badge.bj { background: var(--gold-grad); color: #1a1000; }
.ai-pill {
  margin-top: 5px; text-align: center; padding: 2px 8px; border-radius: 6px; font-size: 11px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; background: rgba(233, 196, 106, .14); color: var(--gold-hi);
  border: 1px solid rgba(233, 196, 106, .4);
}
.ai-pill.res.win, .ai-pill.res.bj { background: rgba(43, 255, 136, .15); color: var(--green); border-color: var(--green); }
.ai-pill.res.lose, .ai-pill.res.bust { background: rgba(255, 63, 180, .12); color: #ffb3dc; border-color: var(--pink); }
.ai-pill.join { border-color: var(--cyan); color: #bdf6ff; }
.ai-pill.leave { border-color: var(--muted); color: var(--muted); }
.stack { position: relative; width: 70%; aspect-ratio: 1; }
.stack img { position: absolute; inset: 0; width: 100%; height: 100%; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .6)); }
.bet-amt { position: absolute; left: calc(100% + 12px); top: 50%; transform: translateY(-50%); white-space: nowrap; font-size: 16px; letter-spacing: .08em; color: var(--gold-hi); text-shadow: 0 2px 4px #000; font-weight: 600; }
.bet-spot:not(.has) .bet-amt { position: static; transform: none; font-size: 13px; font-weight: 500; color: rgba(255, 210, 63, .92); text-align: center; letter-spacing: .08em; text-transform: uppercase; line-height: 1.2; padding: 0 6px; }
.bet-spot:not(.has) .stack { display: none; }
.bj-banner {
  position: relative; z-index: 5; opacity: 0; width: fit-content; max-width: min(680px, 94%);
  margin: 14px auto 0; display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 10px 28px; border-radius: 14px; text-align: center; pointer-events: none;
  background: rgba(3, 8, 32, .94); border: 1px solid var(--gold);
  box-shadow: 0 0 40px rgba(233, 196, 106, .3), 0 14px 30px rgba(0, 0, 0, .6);
  transition: opacity .35s;
}
.bj-banner.show { opacity: 1; }
.bj-banner b { font-family: var(--f-serif); font-weight: 900; font-size: clamp(24px, 3vw, 38px); color: var(--gold-hi); text-shadow: 0 0 16px rgba(233, 196, 106, .6); }
.bj-banner span { color: var(--muted); font-size: 14px; letter-spacing: .06em; }
.bj-banner.win b, .bj-banner.bj b { color: #d9ffe9; text-shadow: 0 0 16px var(--green); }
.bj-banner.lose b { color: #ffd9ef; text-shadow: 0 0 16px var(--pink); }
.bj-banner.win, .bj-banner.bj { border-color: var(--green); }
.bj-banner.lose { border-color: var(--pink); }
.bj-controls { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 22px auto 0; flex-wrap: wrap; }
.chip-rack { display: flex; gap: 8px; padding: 8px 14px; border-radius: 999px; background: rgba(3, 8, 32, .75); border: 1px solid rgba(233, 196, 106, .35); }
.chip-btn { width: 62px; height: 62px; padding: 0; border: none; background: none; cursor: pointer; border-radius: 50%; transition: transform .15s; }
.chip-btn img { width: 100%; height: 100%; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .55)); }
.chip-btn:hover:not(:disabled) { transform: translateY(-5px) rotate(-12deg); }
.chip-btn:disabled { opacity: .35; cursor: default; }
.bj-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }

@media (max-width: 760px) {
  #view-blackjack { --cw-base: clamp(32px, 11.5vw, 56px); padding-left: 6px; padding-right: 6px; }
  .bj-rail { border-radius: 26px 26px 40% 40% / 26px 26px 18% 18%; padding: 8px; }
  .felt { aspect-ratio: 1000 / 650; border-radius: 20px 20px 40% 40% / 20px 20px 16% 16%; }
  .dealer-zone { top: 3%; }
  .player-zone { top: 43%; }
  .player-zone .ph-foot { margin-top: -10px; }
  .felt-rules { top: calc(3% + var(--cw) * 1.4 + 10px); width: min(360px, 88%); }
  .felt-rule-main { letter-spacing: 0.1em; }
  .felt-rule-sub { letter-spacing: 0.05em; margin-top: 3px; }
  .bet-spot { width: calc(var(--cw-base) * 1.2); bottom: 3%; }
  .bet-spot::before { font-size: 11px; letter-spacing: .16em; top: -18px; }
  .shoe { top: 3%; right: 4%; width: calc(var(--cw-base) * .75); }
  .shoe span { display: none; }
  .tray { display: none; }
  .bj-banner { width: min(360px, 94%); margin: 10px auto 0; padding: 8px 12px; }
  .bj-controls { margin-top: 12px; justify-content: center; }
  .chip-rack { padding: 6px 8px; gap: 2px; }
  .chip-btn { width: 50px; height: 50px; }
  .bj-actions { justify-content: center; width: 100%; }
  .bj-actions .btn { min-width: 0; flex: 1 1 0; padding: 10px 8px; font-size: 13px; letter-spacing: .1em; }
}

/* ---------- Dice ---------- */
.dice-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(320px, 1fr); gap: 22px; max-width: 1240px; margin: 0 auto; align-items: start; }
.dice-stage {
  position: relative; display: flex; flex-direction: column; aspect-ratio: 16 / 11.5; border-radius: 22px; overflow: hidden;
  box-shadow: 0 0 0 2px var(--gold), 0 0 0 7px #0a0503, 0 0 0 8px rgba(233, 196, 106, .4), 0 30px 70px rgba(0, 0, 0, .6), 0 0 60px rgba(63, 231, 255, .12);
}
.stage-banner {
  position: relative; z-index: 2; flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; min-height: 0; padding: 7px 14px; text-align: center; pointer-events: none;
  background: radial-gradient(120% 160% at 50% 130%, #16378f 0%, #0c246e 58%, #071544 100%);
  border-bottom: 1px solid rgba(233, 196, 106, .4);
}
.stage-banner b {
  font-family: var(--f-serif); font-weight: 900; line-height: 1; color: #e9c46a; letter-spacing: .14em;
  font-size: clamp(22px, 3.2vw, 36px); text-shadow: 0 2px 0 rgba(0, 0, 0, .35);
}
.stage-banner span {
  font-size: clamp(14px, 1.7vw, 15px); letter-spacing: clamp(.04em, .28vw, .16em); text-transform: uppercase;
  color: rgba(233, 196, 106, .9); line-height: 1.3; max-width: 46ch;
}
.vl-on .stage-banner b, .vl-on .stage-banner span { visibility: hidden; }
.dice-rail { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 10px 14px; background: rgba(4, 10, 34, .92); border-bottom: 1px solid rgba(233, 196, 106, .28); flex: 0 0 auto; z-index: 2; }
.dr-pill { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 7px 11px; border-radius: 11px; background: rgba(15, 34, 92, .72); border: 1px solid rgba(233, 196, 106, .35); }
.dr-pill.empty { justify-content: center; border-style: dashed; border-color: rgba(154, 166, 214, .28); background: transparent; color: var(--muted); font-size: 11px; letter-spacing: .08em; }
.dr-pill.win { border-color: var(--green); box-shadow: 0 0 12px rgba(43, 255, 136, .35); }
.dr-pill.leaving { opacity: .55; }
.dr-dot { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 9px; font-weight: 700; color: #fff; flex: none; border: 1px solid rgba(255, 255, 255, .45); }
.dr-copy { display: flex; flex-direction: column; gap: 2px; min-width: 0; line-height: 1.15; }
.dr-copy b { font-size: 12px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dr-copy span { font-size: 10.5px; color: var(--gold); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dice-canvas { flex: 1 1 0%; width: 100%; height: 0; min-height: 0; display: block; }
.stage-loading { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; background: #040a26; color: var(--muted); letter-spacing: .2em; text-transform: uppercase; font-size: 13px; }
.stage-loading span { width: 40px; height: 40px; border-radius: 50%; border: 3px solid rgba(233, 196, 106, .2); border-top-color: var(--gold); animation: spin 1s linear infinite; }
.roll-readout {
  position: relative; flex: 0 0 auto; align-self: stretch; opacity: 1; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  padding: 7px 12px 9px; overflow: hidden; border-radius: 0; white-space: nowrap;
  background: #07133f; border-top: 1px solid rgba(233, 196, 106, .45);
}
.roll-readout.show { opacity: 1; }
.rr-faces { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.rr-faces span { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 7px; background: var(--c); color: var(--i); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; font-size: 13px; border: 1px solid rgba(233, 196, 106, .75); }
.rr-faces span b { padding: 0 5px; border-radius: 4px; background: rgba(0, 0, 0, .38); color: #fff6d6; font-size: 13px; letter-spacing: 0; }
.rr-line { font-size: 15px; color: var(--muted); letter-spacing: .06em; }
.rr-line .up { color: var(--green); } .rr-line .dn { color: #ffb3dc; }
.vl-hud {
  position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 3; display: flex; gap: 16px; align-items: center;
  padding: 8px 18px; border-radius: 999px; background: rgba(3, 8, 32, .88); border: 1px solid var(--gold); box-shadow: 0 0 26px rgba(233, 196, 106, .35);
  letter-spacing: .14em; text-transform: uppercase; font-size: 14px; white-space: nowrap; max-width: calc(100% - 24px);
}
.vl-hud b { font-family: var(--f-serif); font-size: 20px; letter-spacing: .02em; text-transform: none; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.vl-hud em { font-style: normal; font-weight: 700; color: var(--green); font-size: 20px; }
.vl-hud.bump em { animation: pop .5s 2; display: inline-block; }
.vl-on .dice-stage { box-shadow: 0 0 0 2px var(--green), 0 0 0 7px #0a0503, 0 30px 70px rgba(0, 0, 0, .6), 0 0 60px rgba(43, 255, 136, .25); }
.dice-board {
  padding: 14px 16px; border-radius: 22px; background-color: #050d2c; background-image: linear-gradient(180deg, #16327e, #071033 55%, #050d2c);
  border: 1px solid rgba(233, 196, 106, .4); box-shadow: 0 20px 40px rgba(0, 0, 0, .45);
}
.board-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.board-head > span { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.chip-pick { display: flex; gap: 4px; }
.cp { width: 42px; height: 42px; padding: 0; border: none; background: none; cursor: pointer; border-radius: 50%; transition: transform .15s; opacity: 1; }
.cp img { width: 100%; height: 100%; }
.cp.on { opacity: 1; transform: translateY(-4px); filter: drop-shadow(0 0 8px rgba(233, 196, 106, .8)); }
.spots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.spot {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 6px 6px 8px; cursor: pointer; color: #fff8e8;
  border-radius: 16px; border: 1.5px solid #e9c46a;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, 0) 34%),
    linear-gradient(165deg, #2454c4 0%, #14327f 46%, #0a1844 100%);
  box-shadow: inset 0 1px 0 rgba(255, 244, 200, .55), inset 0 -12px 18px rgba(0, 0, 0, .38), 0 8px 16px rgba(0, 0, 0, .35);
  transition: box-shadow .2s, transform .1s;
}
.spot:hover { box-shadow: inset 0 1px 0 rgba(255, 244, 200, .7), 0 0 16px rgba(233, 196, 106, .35), 0 8px 16px rgba(0, 0, 0, .35); }
.spot:active { transform: scale(.98); }
.spot-num {
  position: absolute; top: 5px; left: 7px; font-family: Oswald, sans-serif; font-size: 12px; font-weight: 700;
  color: rgba(255, 224, 138, .92); line-height: 1; padding: 2px 5px; border-radius: 5px;
  background: rgba(2, 6, 22, .65); border: 1px solid rgba(233, 196, 106, .45); pointer-events: none;
}
.spot-ic { width: 56px; height: 56px; object-fit: contain; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .45)); }
.spot-ai { position: absolute; top: 5px; right: 6px; display: flex; gap: 2px; pointer-events: none; z-index: 2; }
.spot-ai:empty { display: none; }
.spot-ai i { font-style: normal; font-size: 9px; font-weight: 700; padding: 1px 4px; border-radius: 4px; color: #fff; border: 1px solid rgba(255, 255, 255, .5); box-shadow: 0 1px 3px rgba(0, 0, 0, .5); }
.spot-name { font-family: Oswald, sans-serif; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; font-size: 16px; line-height: 1.1; color: #fff8e8; text-shadow: 0 1px 2px rgba(0, 0, 0, .65); }
.spot-pay { font-family: Oswald, sans-serif; font-weight: 700; font-size: 14px; letter-spacing: .04em; color: #ffe08a; white-space: nowrap; line-height: 1.1; }
.spot-cond { font-size: 11px; font-weight: 600; letter-spacing: .03em; color: #d5def4; white-space: nowrap; line-height: 1.15; }
.spot-copy { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.spot-stack { position: absolute; right: 8px; bottom: 8px; width: 42px; height: 42px; pointer-events: none; }
.spot-stack:empty { display: none; }
.spot-stack img { position: absolute; right: 0; bottom: calc(var(--i) * 11px); width: 40px; height: 40px; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .55)); }
.spot-amt {
  position: absolute; left: 6px; bottom: 8px; padding: 1px 7px; border-radius: 999px; font-size: 12px; font-weight: 700;
  background: var(--gold-grad); color: #1a1000; box-shadow: 0 2px 6px rgba(0, 0, 0, .5);
}
.spot-amt:empty { display: none; }
.spot.has { padding-bottom: 46px; box-shadow: 0 0 0 1px #fff1b8, 0 0 18px rgba(233, 196, 106, .72), inset 0 0 20px rgba(255, 214, 106, .22), inset 0 1px 0 rgba(255, 244, 200, .65); }
.spot.won { border-color: var(--green); box-shadow: 0 0 0 1px var(--green), 0 0 22px rgba(43, 255, 136, .55), inset 0 0 18px rgba(43, 255, 136, .16); }
.spot.wide { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: flex-start; gap: 10px; padding: 6px 12px; text-align: left; }
.spot.wide.has { padding-bottom: 6px; padding-right: 78px; }
.spot.wide .spot-ic { width: 46px; height: 46px; flex: none; }
.spot.podium {
  background:
    linear-gradient(180deg, rgba(255, 244, 200, .35), rgba(255, 255, 255, 0) 38%),
    linear-gradient(165deg, #a67c1a 0%, #5c3e0c 48%, #241806 100%);
}
.board-foot { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.board-foot .btn { min-width: 0; padding: 12px 14px; font-size: 14px; }
.board-foot .roll-btn {
  flex: 1.35; font-family: Oswald, sans-serif; font-size: 22px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
  color: #fff; border: 1px solid #ffd2cb; padding: 14px 10px;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 210, 200, .85), transparent 42%),
    linear-gradient(180deg, #ff5a48 0%, #e10600 46%, #8c0500 100%);
  box-shadow: 0 0 22px rgba(255, 48, 36, .75), 0 4px 0 #5c0200, inset 0 1px 0 rgba(255, 255, 255, .5);
  text-shadow: 0 1px 0 #6a0200, 0 0 10px rgba(255, 220, 200, .85);
}
.board-foot .roll-btn:disabled { filter: saturate(.35) brightness(.72); box-shadow: 0 3px 0 #3a1210; }
.stake { margin-right: auto; display: flex; flex-direction: column; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.stake b { font-size: 22px; color: var(--gold-hi); letter-spacing: .02em; }
.board-note { margin: 12px 2px 0; font-size: 13px; color: var(--muted); font-weight: 400; line-height: 1.4; }
.board-note b { color: var(--gold); font-weight: 600; }
.vl-dice { display: flex; justify-content: center; gap: 14px; margin: 10px 0; }
.vl-dice svg, .vl-dice img { width: 70px; height: 70px; border-radius: 14px; border: 2px solid var(--gold); background: #0d2470; object-fit: cover; }
.dice-legend { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin: 10px 0; }
.dice-legend div { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; border-radius: 10px; border: 1px solid rgba(233, 196, 106, .35); background: #0b1b55; }
.dice-legend svg, .dice-legend img { width: 46px; height: 46px; object-fit: cover; border-radius: 8px; }
.dice-legend b { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.dice-legend span { font-size: 11px; color: var(--muted); }
@media (max-width: 900px) {
  .dice-layout { grid-template-columns: 1fr; }
  .dice-stage { aspect-ratio: 4 / 3.95; }
  .stage-banner { min-height: 0; padding: 7px 12px; }
  .dice-rail { padding: 9px 10px; gap: 8px; }
  .dr-pill { padding: 7px 9px; gap: 7px; }
  .dr-dot { width: 22px; height: 22px; font-size: 9px; }
  .dice-legend { grid-template-columns: repeat(3, 1fr); }
  .rr-faces span { font-size: 14px; padding: 3px 10px; }
  .rr-line { font-size: 15px; }
  .vl-hud { gap: 8px; font-size: 13px; padding: 6px 12px; }
  .vl-hud b, .vl-hud em { font-size: 16px; }
  .board-head { flex-wrap: wrap; align-items: center; row-gap: 8px; }
  .board-head > span { flex: 1 1 140px; font-size: 13px; letter-spacing: .12em; line-height: 1.3; }
  .chip-pick { gap: 6px; margin-left: auto; }
  .cp { width: 62px; height: 62px; }
  .spots { grid-template-columns: 1fr 1fr; }
  .spot { padding: 10px 8px 12px; }
  .spot-ic { width: 72px; height: 72px; }
  .spot.wide .spot-ic { width: 58px; height: 58px; }
  .spot-name { font-size: 18px; letter-spacing: .06em; }
  .spot-pay { font-size: 16px; }
  .spot-cond { font-size: 13px; }
  .spot-amt { font-size: 13px; }
  .stake { font-size: 12px; }
  .stake b { font-size: 26px; }
  .board-note { font-size: 15px; }
  .board-foot .roll-btn { font-size: 22px; min-height: 52px; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .topbar { min-height: 40px; padding: 3px 10px; }
  .brand-top { display: none; }
  .brand-neon { font-size: 14px; }
  .back-btn, .top-lobby, .top-help { padding: 4px 10px; font-size: 10px; }
  .dice-layout { grid-template-columns: minmax(0, 1.25fr) minmax(250px, .85fr); gap: 12px; }
  .dice-stage { aspect-ratio: auto; height: calc(100vh - 118px); max-height: 420px; }
  #view-blackjack {
    --cw-base: clamp(28px, 8.2vh, 42px); --cw: calc(var(--cw-base) * 1.4);
    min-height: 0; height: calc(100vh - 44px);
    display: flex; flex-direction: column; justify-content: center; padding: 4px 10px 6px; overflow: hidden;
  }
  #view-blackjack .game-head { display: none; }
  #view-blackjack .bj-wrap {
    flex: 1; min-height: 0; min-width: 0; max-width: 100%; width: 100%;
    display: flex; align-items: center; justify-content: center; gap: 14px;
  }
  #view-blackjack .bj-rail {
    height: calc(100vh - 56px); width: auto; aspect-ratio: 1000 / 600; max-width: calc(100vw - 244px);
    flex: none; display: block;
    padding: 7px; border-radius: 26px 26px 38% 38% / 26px 26px 22% 22%;
  }
  #view-blackjack .felt {
    height: 100%; width: 100%; aspect-ratio: auto;
    border-radius: 20px 20px 38% 38% / 20px 20px 20% 20%;
  }
  #view-blackjack .dealer-zone { top: 2%; }
  #view-blackjack .player-zone { top: 41%; }
  #view-blackjack .player-zone .phand { padding: 4px 6px; gap: 4px; }
  #view-blackjack .player-zone .ph-foot { margin-top: -8px; gap: 4px; }
  #view-blackjack .badge { min-width: 30px; padding: 1px 7px; font-size: 12px; }
  #view-blackjack .result { font-size: 10px; padding: 2px 6px; }
  #view-blackjack .ai-seat { top: 40%; width: 27.5%; padding: 4px 6px; border-radius: 10px; }
  #view-blackjack .ai-seat.seat-1 { left: 2%; }
  #view-blackjack .ai-seat.seat-3 { right: 2%; }
  #view-blackjack .ai-seat.empty { min-height: 74px; }
  #view-blackjack .ai-head { gap: 4px; margin-bottom: 3px; }
  #view-blackjack .ai-avatar { width: 18px; height: 18px; font-size: 8px; }
  #view-blackjack .ai-meta b { font-size: 11px; }
  #view-blackjack .ai-meta small { font-size: 9px; }
  #view-blackjack .ai-hand { --cw-ai: calc(var(--cw) * .55); }
  #view-blackjack .ai-foot { margin-top: 3px; }
  #view-blackjack .ai-bet { font-size: 9px; }
  #view-blackjack .ai-badge { font-size: 10px; padding: 1px 6px; }
  #view-blackjack .ai-pill { font-size: 9px; padding: 1px 4px; margin-top: 3px; }
  #view-blackjack .bet-spot { bottom: 2%; width: calc(var(--cw-base) * 1.05); }
  #view-blackjack .bet-spot::before { top: -15px; font-size: 9px; letter-spacing: .16em; }
  #view-blackjack .bet-amt { font-size: 11px; left: calc(100% + 6px); }
  #view-blackjack .bet-spot:not(.has) .bet-amt { font-size: 9px; }
  #view-blackjack .shoe { top: 3%; right: 4%; width: calc(var(--cw-base) * .72); }
  #view-blackjack .shoe span { display: none; }
  #view-blackjack .tray { display: none; }
  #view-blackjack .felt-rules { top: calc(2% + var(--cw) * 1.4 + 4px); width: min(320px, 60%); }
  #view-blackjack .felt-rule-main { font-size: 11px; letter-spacing: 0.08em; }
  #view-blackjack .felt-rule-sub { font-size: 8.5px; letter-spacing: 0.04em; margin-top: 1px; }
  #view-blackjack .bj-dock {
    width: 214px; height: calc(100vh - 56px); flex: none;
    padding: 10px 12px; border-radius: 18px;
    background: linear-gradient(180deg, rgba(14, 30, 86, .88), rgba(4, 10, 34, .95));
    border: 1.5px solid rgba(233, 196, 106, .45);
    box-shadow: 0 14px 32px rgba(0, 0, 0, .65), inset 0 1px 0 rgba(255, 255, 255, .14);
    display: flex; flex-direction: column; justify-content: space-between; gap: 6px; min-width: 0;
  }
  #view-blackjack .bj-dock-head {
    display: block; text-align: center; padding-bottom: 6px;
    border-bottom: 1px solid rgba(233, 196, 106, .28);
  }
  #view-blackjack .bj-dock-title { font-family: var(--f-serif); font-weight: 900; font-size: 20px; line-height: 1.05; }
  #view-blackjack .bj-dock-sub { margin-top: 2px; font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
  #view-blackjack .bj-banner { width: 100%; margin: 0; padding: 5px 8px; border-radius: 10px; }
  #view-blackjack .bj-banner b { font-size: 16px; }
  #view-blackjack .bj-banner span { font-size: 10px; }
  #view-blackjack .bj-controls { flex: 1; display: flex; flex-direction: column; justify-content: space-between; margin: 0; gap: 8px; width: 100%; align-items: stretch; }
  #view-blackjack .chip-rack {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 8px;
    padding: 8px 6px; border-radius: 14px; background: rgba(2, 6, 22, .65);
  }
  #view-blackjack .chip-btn { width: 42px; height: 42px; }
  #view-blackjack .bj-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; width: 100%; }
  #view-blackjack .bj-actions[hidden] { display: none; }
  #view-blackjack .bj-actions [data-act="deal"] { grid-column: 1 / -1; order: -1; }
  #view-blackjack .bj-actions .btn { padding: 8px 6px; font-size: 12px; letter-spacing: .1em; min-width: 0; width: 100%; border-radius: 10px; }
}
