:root {
  color-scheme: dark;
  font-family: "Segoe UI", Arial, sans-serif;
  --gold: #ffd86c;
  --gold-light: #fff1ad;
  --gold-dark: #9c5e19;
  --crimson: #590d20;
  --crimson-deep: #260813;
  --purple: #28123d;
  --ink: #fff7df;
  --green: #28df82;
}

* { box-sizing: border-box; }

html, body {
  width: 100%;
  height: 100%;
  min-width: 280px;
  margin: 0;
  overflow: hidden;
  overscroll-behavior: none;
}

body {
  height: 100vh;
  height: 100dvh;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 50% -20%, rgba(107, 38, 101, .42), transparent 55%),
    linear-gradient(160deg, #21102f, #100817 72%);
}

button { color: inherit; font: inherit; -webkit-tap-highlight-color: transparent; }
button:focus-visible { outline: 2px solid #fff3bb; outline-offset: 2px; }
button:disabled { cursor: default; opacity: .58; }

.game-shell {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: clamp(40px, 8dvh, 58px) minmax(0, .9fr) minmax(0, 1.3fr) clamp(152px, 25.5dvh, 204px);
  gap: clamp(4px, .9dvh, 8px);
  width: min(100%, 520px);
  height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0 auto;
  padding: max(4px, env(safe-area-inset-top)) 8px max(4px, env(safe-area-inset-bottom));
  overflow: hidden;
}

.header-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  min-width: 0;
  padding: 3px 6px;
  border: 1px solid rgba(255, 215, 111, .24);
  border-radius: 12px;
  background: linear-gradient(90deg, #28123d, #371242 50%, #251038);
  box-shadow: inset 0 1px rgba(255,255,255,.09), 0 3px 9px #0c0611;
}
.header-side { display: flex; min-width: 0; align-items: center; gap: clamp(3px, 1.1vw, 8px); }
.header-right { justify-content: flex-end; }
.mode-toggle {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 29px;
  place-items: center;
  padding: 2px;
  border: 1px solid #e8ba58;
  border-radius: 9px;
  color: #ffe8a0;
  background: linear-gradient(145deg, #704632, #35142d);
  box-shadow: inset 0 1px rgba(255,255,255,.18), 0 1px 5px #0a050c;
  font-size: 7px;
  font-weight: 1000;
  letter-spacing: .02em;
  cursor: pointer;
}
.mode-toggle[hidden] { display: none; }
.round-button {
  position: relative;
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: clamp(27px, 8.5vw, 35px);
  height: clamp(27px, 8.5vw, 35px);
  padding: 5px;
  border: 1px solid #e8ba58;
  border-radius: 50%;
  color: #ffe8a0;
  background: radial-gradient(circle at 35% 25%, #704632, #35142d 72%);
  box-shadow: 0 0 0 2px rgba(116, 67, 29, .75), inset 0 1px rgba(255,255,255,.18), 0 1px 5px #0a050c;
  cursor: pointer;
}
.round-button svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.round-button #sound-muted { display: none; }
.round-button.muted #sound-waves { display: none; }
.round-button.muted #sound-muted { display: block; }
.round-button.muted { color: #ffaaa1; }
.help-mark { font-family: Georgia, serif; font-size: 19px; font-weight: 900; }
.exit-button { color: #ffcf82; }
.signal-status { display: flex; align-items: center; gap: 3px; padding-left: 1px; color: #8dffc0; font-size: clamp(7px, 2vw, 9px); font-weight: 900; white-space: nowrap; text-shadow: 0 0 6px rgba(40,223,130,.65); }
.signal-bars { display: flex; height: 13px; align-items: flex-end; gap: 1px; }
.signal-bars i { width: 2px; border-radius: 2px; background: var(--green); box-shadow: 0 0 4px rgba(40,223,130,.8); }
.signal-bars i:nth-child(1) { height: 4px; }
.signal-bars i:nth-child(2) { height: 7px; }
.signal-bars i:nth-child(3) { height: 10px; }
.signal-bars i:nth-child(4) { height: 13px; }
.signal-status.offline { color: #f78383; text-shadow: none; }
.signal-status.offline .signal-bars i { background: #e55b64; box-shadow: none; }
.cabinet-logo { display: flex; align-items: center; justify-content: center; gap: 4px; min-width: 0; }
.logo-star { color: #ffe28a; font-size: clamp(11px, 4vw, 17px); text-shadow: 0 1px #8f4b16, 0 0 7px #f4a83c; }
.logo-mark {
  color: #ff4733;
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(24px, 8vw, 37px);
  font-style: italic;
  font-weight: 1000;
  letter-spacing: -.08em;
  line-height: .9;
  -webkit-text-stroke: 1px #ffe58d;
  text-shadow: 0 1px #7f1a0c, 0 2px #d38624, 0 0 8px #fa4b21, 0 0 14px rgba(255,113,36,.75);
}

.payout-board {
  min-height: 0;
  padding: 3px;
  border: 1px solid #ffe69b;
  border-radius: 12px;
  background: linear-gradient(135deg, #fff1a7, #a66520 25%, #ffdf79 48%, #9a5019 70%, #ffe49a);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35), 0 3px 9px rgba(0,0,0,.42);
}
.board-inner {
  display: flex;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  padding: 4px 5px;
  overflow: hidden;
  border: 1px solid rgba(255, 218, 112, .68);
  border-radius: 8px;
  background:
    radial-gradient(ellipse at 50% 0, rgba(142, 31, 44, .6), transparent 70%),
    linear-gradient(145deg, #651126, #390a19 75%);
  box-shadow: inset 0 0 14px rgba(12,0,0,.55);
}
.board-heading { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; min-height: 12px; margin-bottom: 3px; }
.board-title { color: #ffe58d; font-size: clamp(8px, 2.5vw, 10px); font-weight: 1000; letter-spacing: .12em; text-shadow: 0 1px #801a17; }
.board-caption { color: #d7a98c; font-size: 6px; font-weight: 800; letter-spacing: .12em; }
.board-layout { display: grid; min-height: 0; flex: 1; grid-template-columns: minmax(0, 1fr) clamp(72px, 24vw, 98px); gap: 5px; }
.payout-area { display: flex; min-width: 0; min-height: 0; flex-direction: column; gap: 4px; }
.payout-grid { display: grid; min-height: 0; flex: 1; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(3, minmax(0, 1fr)); gap: 3px 4px; }
.payout-prize {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 2px;
  padding: 1px 3px;
  border: 1px solid rgba(255, 224, 141, .35);
  border-radius: 4px;
  background: linear-gradient(90deg, rgba(43,7,15,.8), rgba(103,21,30,.8));
  transition: background .2s, box-shadow .2s, border-color .2s;
}
.payout-prize.is-winning, .wild-prize.is-winning {
  border-color: #fff2a1;
  background: linear-gradient(90deg, #a74318, #e39b2f);
  box-shadow: 0 0 8px #ffdb55, inset 0 0 6px rgba(255,255,255,.28);
  animation: prize-win-pulse .62s ease-in-out infinite alternate;
}
@keyframes prize-win-pulse { to { box-shadow: 0 0 14px #fff080, inset 0 0 9px rgba(255,255,255,.5); } }
.prize-symbols { display: flex; min-width: 0; align-items: center; gap: 1px; overflow: hidden; color: #fff1c8; font-size: clamp(5px, 1.65vw, 7px); font-weight: 900; letter-spacing: -.04em; white-space: nowrap; }
.prize-symbols span { min-width: 0; overflow: hidden; text-overflow: clip; }
.prize-times { flex: 0 0 auto; color: #ffe18a; font-size: clamp(8px, 2.4vw, 10px); font-weight: 1000; text-shadow: 0 1px #68151a; }
.wild-payouts { display: grid; flex: 0 0 clamp(20px, 3.8dvh, 27px); grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; }
.wild-prize {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 1px;
  border: 1px solid rgba(255, 224, 141, .42);
  border-radius: 5px;
  background: linear-gradient(120deg, #48101e, #79202b);
  transition: background .2s, box-shadow .2s;
}
.wild-label { overflow: hidden; color: #ffe8b7; font-size: clamp(5px, 1.7vw, 7px); font-weight: 900; text-overflow: clip; white-space: nowrap; }
.wild-prize b { flex: 0 0 auto; color: #ffe18a; font-size: clamp(8px, 2.3vw, 10px); }
.bonus-board { display: grid; min-width: 0; min-height: 0; grid-template-rows: minmax(0, 1fr) auto; gap: 4px; padding-left: 5px; border-left: 1px solid rgba(255, 218, 112, .42); }
.bonus-box, .respin-box { display: flex; min-height: 0; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 2px; border: 1px solid rgba(255, 218, 112, .4); border-radius: 6px; background: rgba(31, 4, 20, .58); }
.bonus-box-title { color: #f9d881; font-size: clamp(6px, 1.9vw, 8px); font-weight: 1000; letter-spacing: .08em; text-align: center; }
.multiplier-badges { display: grid; width: 100%; min-height: 0; flex: 1; grid-template: repeat(2, minmax(0, 1fr)) / repeat(2, minmax(0, 1fr)); justify-items: center; align-items: center; gap: 2px; }
.multiplier-badge {
  display: grid;
  width: clamp(20px, 5.7vh, 29px);
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid #e8bf68;
  border-radius: 50%;
  color: #fff3bd;
  background: radial-gradient(circle at 35% 25%, #a8434c, #4a1028 72%);
  box-shadow: inset 0 0 3px rgba(255,255,255,.35), 0 0 5px rgba(255,183,83,.25);
  font-size: clamp(8px, 2.8vw, 12px);
  font-weight: 1000;
  text-shadow: 0 1px #531522;
  transition: box-shadow .2s, transform .2s, background .2s;
}
.multiplier-badge.is-lit, .respin-badge.is-lit {
  color: #fff6cf;
  background: radial-gradient(circle, #ffdc72, #cb5b22 72%);
  box-shadow: 0 0 10px #ffe37e, inset 0 0 5px white;
  transform: scale(1.08);
}
.respin-box { min-height: 31px; }
.respin-badge {
  display: grid;
  min-width: 48px;
  min-height: 16px;
  place-items: center;
  padding: 2px 5px;
  border: 1px solid #d5abfc;
  border-radius: 20px;
  color: #f5dcff;
  background: linear-gradient(100deg, #542d8d, #8b3db3);
  box-shadow: inset 0 0 4px rgba(255,255,255,.28), 0 0 5px rgba(173,104,255,.4);
  font-size: 7px;
  font-weight: 1000;
  letter-spacing: .05em;
  transition: box-shadow .2s, transform .2s;
}

.machine-body { min-height: 0; }
.cabinet-frame {
  position: relative;
  display: flex;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  padding: 5px 7px 6px;
  border: 2px solid #efc265;
  border-radius: 16px;
  background: linear-gradient(145deg, #f8d57a, #9d5a22 18%, #d89c42 45%, #7a3d24 80%, #efc96a);
  box-shadow: inset 0 0 0 2px rgba(255, 247, 185, .36), 0 4px 12px rgba(0,0,0,.48), 0 0 12px rgba(255,194,71,.2);
  animation: cabinet-rim-glow 3.6s ease-in-out infinite alternate;
}
.cabinet-frame::before { position: absolute; inset: 4px; border: 1px solid rgba(255,241,172,.48); border-radius: 10px; content: ""; pointer-events: none; }
.cabinet-frame::after {
  position: absolute;
  z-index: 0;
  inset: 2px;
  border-radius: 12px;
  background: linear-gradient(112deg, transparent 38%, rgba(255,255,255,.16) 49%, transparent 58%);
  background-size: 240% 100%;
  content: "";
  pointer-events: none;
  animation: cabinet-glass-sweep 6s ease-in-out infinite;
}
.cabinet-frame > :not(.cabinet-rivets) { position: relative; z-index: 1; }
.cabinet-rivets { position: absolute; z-index: 2; top: 5px; right: 7px; left: 7px; display: flex; justify-content: space-between; pointer-events: none; }
.cabinet-rivets i { width: 4px; height: 4px; border: 1px solid #fff0aa; border-radius: 50%; background: #8b4e23; box-shadow: inset 0 0 2px #fff; }
@keyframes cabinet-rim-glow { to { box-shadow: inset 0 0 0 2px rgba(255,247,185,.48), 0 4px 12px rgba(0,0,0,.48), 0 0 18px rgba(255,194,71,.42); } }
@keyframes cabinet-glass-sweep { 0%, 25% { background-position: 120% 0; } 75%, 100% { background-position: -120% 0; } }
.reel-headings { display: grid; flex: 0 0 13px; grid-template-columns: minmax(0, 3fr) minmax(0, .82fr); align-items: center; gap: 6px; padding: 0 4px; color: #fff0ac; font-size: clamp(6px, 1.9vw, 8px); font-weight: 1000; letter-spacing: .15em; text-align: center; text-shadow: 0 1px #651421; }
.reel-headings span:last-child { color: #f0caff; }
.led-row { display: flex; height: 6px; flex: 0 0 6px; align-items: center; justify-content: space-around; margin: 1px 4px; }
.led-row i { width: 4px; height: 4px; border-radius: 50%; background: #e431c6; box-shadow: 0 0 5px 1px #eb2ecb; animation: led-glow 1.5s ease-in-out infinite alternate; }
.led-row i:nth-child(3n) { background: #a53dff; box-shadow: 0 0 5px 1px #a53dff; animation-delay: .4s; }
.led-row i:nth-child(2n) { animation-delay: .8s; }
@keyframes led-glow { to { opacity: .48; box-shadow: 0 0 2px #d343ef; } }
.reel-window {
  position: relative;
  display: grid;
  min-height: 0;
  flex: 1;
  grid-template-columns: minmax(0, 3fr) minmax(48px, .82fr);
  gap: 6px;
  padding: 3px;
  overflow: hidden;
  border: 2px solid #724321;
  border-radius: 9px;
  background: linear-gradient(180deg, #3e1526, #210914);
  box-shadow: inset 0 3px 8px rgba(0,0,0,.75), 0 0 0 1px #ffdf83, 0 0 10px rgba(228,47,194,.24);
  animation: reel-rim-pulse 2.8s ease-in-out infinite alternate;
}
@keyframes reel-rim-pulse { to { box-shadow: inset 0 3px 8px rgba(0,0,0,.75), 0 0 0 1px #fff0a5, 0 0 14px rgba(228,47,194,.48); } }
.main-reels { position: relative; display: grid; min-width: 0; min-height: 0; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; }
.reel-strip {
  position: relative;
  display: block;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border-right: 1px solid #c9a462;
  border-left: 1px solid #ffe8ac;
  background: linear-gradient(90deg, #40111c, #9d5a31 8%, #d89e4b 13%, #ffe1a0 22%, #b4773d 30%, #57202a 39%, #8e3f2a 50%, #f5d793 62%, #b07740 72%, #541724 84%, #d09442 94%, #43131e);
  box-shadow: inset 0 8px 11px rgba(29,3,12,.82), inset 0 -10px 12px rgba(29,3,12,.88), inset 0 0 0 2px rgba(255,230,158,.38);
}
.reel-track {
  position: relative;
  display: grid;
  width: 100%;
  height: 200%;
  grid-template-rows: repeat(6, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  transform: translateY(0);
}
.reel-symbol {
  position: relative;
  isolation: isolate;
  display: grid;
  min-width: 0;
  min-height: 0;
  margin: 2px 3px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,235,174,.88);
  border-radius: 8px;
  color: #fff0bd;
  background: linear-gradient(145deg, #792027, #3b0d1b 65%, #751b24);
  box-shadow: inset 0 2px 3px rgba(255,255,255,.36), inset 0 -4px 6px rgba(0,0,0,.68), 0 2px 3px rgba(32,5,11,.7);
  text-align: center;
  line-height: 1;
  white-space: nowrap;
}
.reel-symbol::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(150deg, rgba(255,255,255,.32), transparent 34%, transparent 68%, rgba(0,0,0,.32));
  content: "";
  pointer-events: none;
}
.reel-neighbor { color: #f2c99a; font-size: clamp(9px, 3.4vw, 16px); font-weight: 900; opacity: .5; }
.reel-center { position: relative; z-index: 1; border-top: 1px solid #fff0bc; border-bottom: 1px solid #e8b95b; box-shadow: inset 0 2px 3px rgba(255,255,255,.52), inset 0 -5px 6px rgba(30,4,12,.68), 0 0 8px rgba(255,211,113,.42); }
.symbol-seven {
  border-color: #ffe797;
  border-radius: 10px;
  color: #d82620;
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(19px, 7.5vw, 37px);
  font-style: italic;
  font-weight: 1000;
  letter-spacing: -.08em;
  -webkit-text-stroke: 1px #821a14;
  background: linear-gradient(155deg, #fff2ae, #bd3024 34%, #731119 72%, #e35b27);
  text-shadow: 0 1px #fff1a3, 0 2px #ffb13b, 0 4px #741417, 0 6px 5px rgba(45,4,9,.78), 0 0 8px rgba(255,86,39,.62);
}
.symbol-bar {
  border-color: #ffe09a;
  border-radius: 6px;
  color: #f6d77c;
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(10px, 4vw, 18px);
  font-style: italic;
  font-weight: 1000;
  letter-spacing: -.05em;
  -webkit-text-stroke: .8px #70151a;
  background: linear-gradient(160deg, #fff3bb, #d59b37 30%, #82202a 33%, #49101c 68%, #dc9a35 72%, #fff0a8);
  text-shadow: 0 1px #fff3ad, 0 2px #a62b1d, 0 4px 4px rgba(35,4,9,.85);
}
.symbol-cherry {
  border-color: #ffb66c;
  border-radius: 50%;
  color: #fff0dc;
  background: radial-gradient(ellipse at 32% 20%, #ffb6a2, #df2639 32%, #851225 72%, #380916);
  font-family: Georgia, serif;
  font-size: clamp(9px, 3.4vw, 16px);
  font-weight: 1000;
  text-shadow: 0 1px #ff8b67, 0 2px #6d0b1c, 0 4px 4px rgba(29,0,7,.8);
}
.symbol-cherry::before {
  position: absolute;
  top: 3px;
  right: 12%;
  width: 28%;
  height: 18%;
  border: 1px solid #c8ec72;
  border-radius: 100% 0 100% 0;
  background: linear-gradient(135deg, #d7ff74, #328b3a 75%);
  box-shadow: 0 1px 2px #42101a;
  content: "";
  transform: rotate(-24deg);
}
.symbol-blank { border-color: rgba(235,194,119,.4); color: transparent; background: linear-gradient(145deg, #53202c, #260b17 60%, #69302c); }
.bonus-strip {
  position: relative;
  display: block;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border: 1px solid #9b64d8;
  border-top: 0;
  border-bottom: 0;
  border-radius: 5px;
  background: linear-gradient(90deg, #1d0738, #6840a0 18%, #301455 48%, #6a3d9d 82%, #180630);
  box-shadow: inset 0 1px #9b64d8, inset 0 -1px #9b64d8, inset 0 0 9px rgba(9,0,25,.75), 0 0 5px rgba(191,115,255,.6);
}
.bonus-strip .reel-symbol { border-color: rgba(221,185,255,.7); border-radius: 8px; background: linear-gradient(145deg, #7548ac, #331159 62%, #17052d); box-shadow: inset 0 2px 3px rgba(255,255,255,.42), inset 0 -5px 7px rgba(9,0,22,.86), 0 2px 3px #160725; }
.bonus-strip .reel-neighbor { color: #f0dcff; }
.bonus-center { color: #fff0a4; font-size: clamp(11px, 3.8vw, 18px); font-weight: 1000; -webkit-text-stroke: .5px #9a5c15; text-shadow: 0 1px white, 0 2px #ffbe42, 0 4px #9a451c, 0 5px 5px #14071e, 0 0 9px #ffdf71; }
.bonus-center.respin-result { color: #e7c8ff; font-size: clamp(7px, 2.2vw, 10px); }
.bonus-center.bonus-face-respin { background: linear-gradient(145deg, #ac71e8, #37105d 65%, #17042d); text-shadow: 0 1px white, 0 3px #721cab, 0 5px #180526, 0 0 9px #dca2ff; }
.bonus-center.bonus-face-blank { color: transparent; }
.reel-pointer { position: absolute; z-index: 4; top: 50%; width: 0; height: 0; transform: translateY(-50%); filter: drop-shadow(0 0 3px #ff1d22); }
.pointer-left { left: -1px; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 9px solid #e5292c; }
.pointer-right { right: 0; border-top: 7px solid transparent; border-right: 9px solid #e5292c; border-bottom: 7px solid transparent; }
.center-payline { position: absolute; z-index: 3; top: 50%; right: 24%; left: 1%; height: 2px; transform: translateY(-50%); background: rgba(240,33,38,.86); box-shadow: 0 0 5px 1px #ee282b; pointer-events: none; }
.reel-strip.is-spinning .reel-track,
.bonus-strip.is-spinning .reel-track { animation: reel-chain-down .16s linear infinite; }
.reel-strip.is-stopping .reel-track,
.bonus-strip.is-stopping .reel-track {
  animation: none;
  transform: translateY(0);
  transition: transform .22s cubic-bezier(.15,.82,.2,1);
}
.reel-strip.is-spinning::after,
.bonus-strip.is-spinning::after {
  position: absolute;
  z-index: 3;
  inset: -10% 0;
  background: repeating-linear-gradient(180deg, transparent 0 9px, rgba(255,242,196,.34) 10px 11px, transparent 12px 19px);
  content: "";
  opacity: .48;
  pointer-events: none;
  animation: motion-streak 90ms linear infinite;
}
.reel-strip.is-stopped .reel-center,
.bonus-strip.is-stopped .reel-center { animation: reel-bounce .24s cubic-bezier(.18,.8,.25,1); }
@keyframes reel-chain-down { from { transform: translateY(-50%); filter: blur(1.2px); } to { transform: translateY(0); filter: blur(.3px); } }
@keyframes motion-streak { to { transform: translateY(12px); } }
@keyframes reel-bounce { 0% { transform: translateY(-7px) scale(.96); } 60% { transform: translateY(2px) scale(1.035); } 100% { transform: translateY(0) scale(1); } }
.win-bar {
  display: flex;
  min-height: 23px;
  flex: 0 0 23px;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
  padding: 2px 9px;
  overflow: hidden;
  border: 1px solid #e7bf62;
  border-radius: 20px;
  background: linear-gradient(90deg, #300b17, #681329 50%, #300b17);
  box-shadow: inset 0 1px 5px rgba(0,0,0,.65), 0 1px rgba(255,245,171,.35);
}
.win-label { color: #ffe39a; font-size: 8px; font-weight: 1000; letter-spacing: .12em; }
.win-bar strong { color: #fff1a4; font-size: 15px; font-variant-numeric: tabular-nums; text-shadow: 0 0 6px #ffc443; }
.win-currency { color: #c58f66; font-size: 6px; font-weight: 800; }
.win-divider { width: 1px; height: 12px; flex: 0 0 1px; margin: 0 2px; background: rgba(255,225,164,.35); }
.result-message { min-width: 0; flex: 1 1 auto; overflow: hidden; color: #f3d9ac; font-size: clamp(7px, 2vw, 9px); font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.result-message.win { color: #ffe573; }
.result-message.error { color: #ff9797; }
.room-feed { display: flex; min-width: 0; flex: 0 1 auto; align-items: center; gap: 3px; margin-left: auto; }
.room-feed[hidden] { display: none; }
.room-feed-toggle {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 3px;
  min-height: 16px;
  padding: 1px 5px;
  border: 1px solid rgba(255,230,151,.55);
  border-radius: 12px;
  color: #bafbd3;
  background: linear-gradient(120deg, #173927, #10241d);
  box-shadow: inset 0 1px rgba(255,255,255,.18), 0 0 5px rgba(69,245,145,.2);
  font-size: 6px;
  font-weight: 1000;
  letter-spacing: .06em;
  cursor: pointer;
}
.room-feed-toggle::before { width: 4px; height: 4px; border-radius: 50%; background: #45f591; box-shadow: 0 0 5px #45f591; content: ""; }
.room-feed.is-collapsed .room-feed-toggle::before { background: #9e9a89; box-shadow: none; }
.room-ticker { display: block; min-width: 0; max-width: clamp(38px, 19vw, 84px); overflow: hidden; color: #f9e8bb; font-size: 6px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.room-feed.is-collapsed .room-ticker { display: none; }
.room-feed.is-disconnected .room-feed-toggle { color: #ffb1a8; background: linear-gradient(120deg, #4a2027, #281117); }
.room-feed.is-disconnected .room-feed-toggle::before { background: #ff706a; box-shadow: 0 0 5px #ff706a; }

.control-deck {
  display: grid;
  min-height: 0;
  grid-template-columns: minmax(0, .78fr) minmax(0, 1.2fr) minmax(0, .72fr);
  align-items: center;
  gap: 6px;
  padding: 8px;
  border: 2px solid #f3d37e;
  border-radius: 16px;
  background: linear-gradient(145deg, #f9d87c, #ae682b 16%, #e0ad52 48%, #925124 82%, #f6d474);
  box-shadow: inset 0 0 0 2px rgba(255,248,190,.35), 0 4px 11px rgba(0,0,0,.5);
}
.player-pod { display: flex; min-width: 0; flex-direction: column; align-items: center; justify-content: center; gap: clamp(4px, 1vh, 8px); }
.avatar-ring {
  display: grid;
  width: clamp(37px, 8.5vh, 58px);
  aspect-ratio: 1;
  place-items: center;
  padding: 3px;
  border: 2px solid #ffe9a1;
  border-radius: 50%;
  background: linear-gradient(145deg, #fff1a2, #a85e22 46%, #ffe080);
  box-shadow: 0 0 0 2px #754018, 0 0 9px rgba(255,221,111,.55);
}
.avatar-face { display: grid; width: 100%; height: 100%; place-items: center; border: 1px solid #f8c460; border-radius: 50%; color: #ffe49b; background: radial-gradient(circle at 35% 25%, #773a38, #28101d 75%); font-size: clamp(19px, 5.2vh, 28px); text-shadow: 0 0 6px #eb9e35; }
.wallet-bar {
  display: flex;
  width: 100%;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 3px;
  padding: 3px 4px;
  border: 1px solid rgba(255, 218, 129, .58);
  border-radius: 20px;
  background: linear-gradient(90deg, #35101b, #521522);
  box-shadow: inset 0 2px 4px rgba(0,0,0,.65);
}
.coin-stack { flex: 0 0 auto; color: #ffd76f; font-size: 14px; font-weight: 1000; line-height: 1; text-shadow: 0 0 4px #f79b2a; transform: rotate(90deg); }
.wallet-bar strong { min-width: 0; overflow: hidden; color: #ffe59a; font-size: clamp(8px, 2.7vw, 12px); font-variant-numeric: tabular-nums; text-overflow: ellipsis; }
.topup-button {
  display: grid;
  flex: 0 0 auto;
  width: clamp(17px, 5.5vw, 22px);
  height: clamp(17px, 5.5vw, 22px);
  place-items: center;
  padding: 0;
  border: 1px solid #fff1ad;
  border-radius: 50%;
  color: #4a2515;
  background: linear-gradient(#ffe994, #e7a43c);
  box-shadow: 0 0 5px rgba(255,220,102,.6);
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}
.bet-control { display: flex; min-width: 0; flex-direction: column; gap: clamp(6px, 1.2vh, 10px); }
.bet-control-row { display: flex; align-items: center; justify-content: center; gap: 4px; }
.bet-adjust {
  display: grid;
  flex: 0 0 clamp(27px, 8vw, 35px);
  width: clamp(27px, 8vw, 35px);
  height: clamp(27px, 8vw, 35px);
  place-items: center;
  padding: 0;
  border: 1px solid #ffbd80;
  border-radius: 50%;
  color: #fff3de;
  background: radial-gradient(circle at 35% 25%, #e3543e, #821b24 78%);
  box-shadow: inset 0 1px 3px rgba(255,255,255,.42), 0 2px 4px #572516;
  font-size: 21px;
  font-weight: 900;
  cursor: pointer;
}
.bet-display {
  display: flex;
  min-width: 42px;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2px 5px;
  border: 1px solid #d49c51;
  border-radius: 8px;
  background: linear-gradient(180deg, #4c171b, #2b0b13);
  box-shadow: inset 0 2px 5px rgba(0,0,0,.65), 0 1px rgba(255,240,172,.45);
}
.bet-display span { color: #d6aa71; font-size: 6px; font-weight: 1000; letter-spacing: .2em; }
.bet-display strong { color: #fff0b1; font-size: clamp(14px, 4.5vw, 19px); font-variant-numeric: tabular-nums; text-shadow: 0 1px #84231e; }
.mode-buttons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.mode-button {
  display: flex;
  min-width: 0;
  min-height: clamp(27px, 5.2vh, 36px);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  padding: 2px 3px;
  border: 1px solid #fff0aa;
  border-radius: 18px;
  color: #532517;
  background: linear-gradient(180deg, #fff0a2, #d59234);
  box-shadow: inset 0 1px rgba(255,255,255,.7), 0 2px 3px #79421c;
  font-size: clamp(7px, 2.2vw, 9px);
  font-weight: 1000;
  cursor: pointer;
}
.mode-button small { color: #814329; font-size: 6px; font-weight: 1000; letter-spacing: .12em; }
.mode-button.active { color: #fff1b1; background: linear-gradient(180deg, #ffbd54, #bb4226); box-shadow: 0 0 9px #ffd45e, inset 0 1px rgba(255,255,255,.5); }
.mode-button.active small { color: #fff2bd; }
.spin-button {
  display: flex;
  width: clamp(58px, 18vw, 82px);
  aspect-ratio: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  justify-self: center;
  gap: 0;
  padding: 3px;
  border: 3px solid #fff0a5;
  border-radius: 50%;
  color: white;
  background: radial-gradient(circle at 35% 24%, #48ee91, #0d943f 57%, #07542c 84%);
  box-shadow: 0 0 0 2px #9a5c1f, inset 0 2px 5px rgba(255,255,255,.65), 0 4px 7px rgba(45,14,9,.65), 0 0 10px rgba(91,255,147,.42);
  font-size: clamp(9px, 3vw, 12px);
  font-weight: 1000;
  letter-spacing: .1em;
  text-shadow: 0 1px 2px #075326;
  cursor: pointer;
}
.spin-arrows { font-family: Arial, sans-serif; font-size: clamp(26px, 8vw, 39px); font-weight: 400; line-height: .95; text-shadow: 0 1px 3px #075326; }
.spin-icon-image { width: clamp(25px, 7vw, 34px); height: clamp(25px, 7vw, 34px); object-fit: contain; filter: drop-shadow(0 2px 2px rgba(0,0,0,.4)); }
.spin-icon-image[hidden] { display: none; }
.spin-button.theme-gold { color: #583513; background: radial-gradient(circle at 35% 24%, #fff3a7, #e8aa3b 57%, #8c4a16 84%); text-shadow: 0 1px 2px #fff1a1; }
.spin-button.theme-gold .spin-arrows { text-shadow: 0 1px 2px #fff1a1; }
.spin-button.theme-crimson { background: radial-gradient(circle at 35% 24%, #ff8370, #bd1d32 57%, #630c20 84%); }
.spin-button.is-spinning .spin-arrows { animation: spin-rotate .55s linear infinite; }
.spin-button:not(:disabled):active { transform: scale(.96); }
.spin-button:disabled { filter: saturate(.55); }
@keyframes spin-rotate { to { transform: rotate(360deg); } }

.dialog-backdrop {
  position: fixed;
  z-index: 20;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(9, 3, 13, .78);
}
.dialog-backdrop[hidden], .big-win[hidden] { display: none; }
.info-dialog {
  position: relative;
  width: min(100%, 380px);
  max-height: 80dvh;
  padding: 22px 18px 18px;
  overflow: auto;
  border: 2px solid #eac165;
  border-radius: 16px;
  background: linear-gradient(145deg, #581126, #270a18);
  box-shadow: 0 0 28px rgba(247,173,66,.28), inset 0 0 0 2px rgba(255,255,255,.09);
}
.dialog-kicker { margin: 0 0 4px; color: #e8c66f; font-size: 8px; font-weight: 1000; letter-spacing: .2em; }
.info-dialog h2 { margin: 0 0 12px; color: #ffe58d; font-family: Georgia, serif; font-size: 21px; letter-spacing: .08em; }
.dialog-close { position: absolute; top: 10px; right: 11px; display: grid; width: 27px; height: 27px; place-items: center; border: 1px solid #d7ae5e; border-radius: 50%; color: #ffe8a0; background: #431223; font-size: 21px; cursor: pointer; }
.dialog-copy { margin: 8px 0; color: #e8cfb3; font-size: 12px; line-height: 1.5; }
.history-list { display: grid; gap: 5px; margin: 10px 0 0; padding: 0; list-style: none; }
.history-list li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 9px; border: 1px solid rgba(255,221,139,.24); border-radius: 7px; color: #f2dfc1; background: rgba(0,0,0,.16); font-size: 10px; }
.history-list strong { color: #ffe27f; }
.ranking-status {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
  margin: -4px 0 10px;
  overflow: hidden;
  color: #a9ffd0;
  font-size: 8px;
  font-weight: 1000;
  letter-spacing: .1em;
}
.ranking-status[hidden] { display: none; }
.ranking-status span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ranking-live-dot { width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: #45f591; box-shadow: 0 0 7px #45f591; animation: ranking-live-pulse 1.4s ease-in-out infinite alternate; }
@keyframes ranking-live-pulse { to { opacity: .48; box-shadow: 0 0 3px #45f591; } }
.ranking-status.is-offline { color: #ffb1a8; }
.ranking-status.is-offline .ranking-live-dot { background: #ff706a; box-shadow: 0 0 7px #ff706a; }
.ranking-list { display: grid; max-height: 48dvh; gap: 5px; margin: 0; padding: 0; overflow: auto; list-style: none; }
.ranking-row {
  display: grid;
  min-width: 0;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border: 1px solid rgba(255,221,139,.24);
  border-radius: 8px;
  color: #f2dfc1;
  background: rgba(0,0,0,.16);
  animation: ranking-row-in .22s ease-out;
}
@keyframes ranking-row-in { from { opacity: .5; transform: translateY(3px); } to { opacity: 1; transform: translateY(0); } }
.ranking-row.is-current { border-color: #ffe27f; background: linear-gradient(90deg, rgba(165,83,27,.56), rgba(91,26,38,.68)); box-shadow: 0 0 9px rgba(255,221,95,.2); }
.ranking-place { color: #ffe27f; font-size: 11px; font-weight: 1000; text-align: center; }
.ranking-name { min-width: 0; overflow: hidden; font-size: 10px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.ranking-you { margin-left: 5px; color: #a9ffd0; font-size: 7px; letter-spacing: .1em; }
.ranking-score { color: #ffe27f; font-size: 10px; font-weight: 900; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ranking-empty { margin: 4px 0; color: #e8cfb3; font-size: 11px; line-height: 1.5; }
.big-win {
  position: fixed;
  z-index: 15;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse, rgba(161,70,25,.88), rgba(42,5,21,.82));
  text-align: center;
  animation: win-appear .2s ease-out;
  pointer-events: none;
}
.big-win strong { color: #fff0a0; font-size: clamp(44px, 14vw, 76px); font-weight: 1000; font-style: italic; text-shadow: 0 0 14px #ff8c43, 0 5px #bb3825; }
.big-win > span:last-child { margin-top: 7px; color: white; font-size: 21px; font-weight: 900; }
.big-win-stars { color: var(--gold); font-size: 28px; letter-spacing: .35em; }
@keyframes win-appear { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: scale(1); } }

@media (max-height: 620px) {
  .game-shell { grid-template-rows: 38px minmax(0, .88fr) minmax(0, 1.25fr) 142px; gap: 4px; padding-top: max(3px, env(safe-area-inset-top)); padding-bottom: max(3px, env(safe-area-inset-bottom)); }
  .header-bar { padding-top: 2px; padding-bottom: 2px; }
  .board-inner { padding-top: 3px; padding-bottom: 3px; }
  .board-heading { min-height: 10px; margin-bottom: 2px; }
  .payout-area { gap: 3px; }
  .wild-payouts { flex-basis: 19px; }
  .cabinet-frame { padding-top: 3px; padding-bottom: 4px; }
  .reel-headings { flex-basis: 11px; }
  .win-bar { min-height: 20px; flex-basis: 20px; margin-top: 3px; }
  .control-deck { gap: 4px; padding: 5px; }
  .player-pod { gap: 4px; }
  .avatar-ring { width: 36px; }
  .bet-control { gap: 5px; }
  .bet-adjust { flex-basis: 27px; width: 27px; height: 27px; }
  .mode-button { min-height: 26px; }
  .spin-button { width: 58px; }
}

@media (max-width: 320px) {
  .game-shell { padding-right: 5px; padding-left: 5px; }
  .header-bar { padding-right: 4px; padding-left: 4px; }
  .header-side { gap: 2px; }
  .round-button { width: 25px; height: 25px; padding: 4px; }
  .board-inner { padding-right: 3px; padding-left: 3px; }
  .board-layout { grid-template-columns: minmax(0, 1fr) 70px; gap: 3px; }
  .bonus-board { padding-left: 3px; }
  .control-deck { grid-template-columns: minmax(0, .77fr) minmax(0, 1.2fr) minmax(0, .7fr); gap: 3px; padding: 4px; }
  .header-right { gap: 2px; }
  .mode-toggle { flex-basis: 28px; width: 28px; height: 25px; font-size: 6px; }
  .room-ticker { max-width: 48px; }
}

html.display-three-quarter,
body.display-three-quarter { background: transparent; }
body.display-three-quarter::before {
  position: fixed;
  z-index: 0;
  inset: 0 0 75dvh;
  background: linear-gradient(180deg, rgba(12,5,19,.78), rgba(12,5,19,.54));
  content: "";
  pointer-events: none;
}
body.display-three-quarter .game-shell {
  position: fixed;
  z-index: 1;
  inset: auto auto 0 50%;
  width: min(100%, 520px);
  height: min(78dvh, calc(75dvh + env(safe-area-inset-bottom)));
  min-height: 72dvh;
  max-height: 78dvh;
  transform: translateX(-50%);
  border: 1px solid rgba(255,220,135,.62);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 -7px 28px rgba(0,0,0,.42), 0 0 18px rgba(255,201,83,.12);
}
body.display-three-quarter .symbol-seven { font-size: clamp(12px, 2.4dvh, 20px); }

:root {
  --gold: #ffd86c;
  --gold-light: #fff6c4;
  --gold-dark: #7e3e12;
  --crimson: #890e35;
  --crimson-deep: #370a2b;
  --purple: #29104d;
  --ink: #fff7df;
}

body {
  background:
    radial-gradient(ellipse at 50% 0, rgba(113,44,174,.42), transparent 42%),
    radial-gradient(ellipse at 50% 100%, rgba(116,14,54,.24), transparent 45%),
    linear-gradient(155deg, #1d0c3b, #10051f 62%, #24081e);
}

.header-bar {
  border: 1px solid #ffe99c;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.1), transparent 28%),
    linear-gradient(105deg, #45156a, #210c43 48%, #571136);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.36),
    inset 0 -3px 7px rgba(13,2,27,.7),
    0 0 0 2px #8f4e1b,
    0 3px 9px rgba(0,0,0,.62),
    0 0 13px rgba(216,87,255,.23);
}
.header-side { min-width: 0; }
.header-room-status {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 4px;
  color: #e8caff;
  font-size: clamp(6px,1.8vw,8px);
  font-weight: 1000;
  letter-spacing: .12em;
  white-space: nowrap;
  text-shadow: 0 0 7px rgba(231,126,255,.65);
}
.header-room-status i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #64ffad;
  box-shadow: 0 0 7px #64ffad;
}
.royal-crest {
  position: relative;
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: clamp(3px,1.5vw,9px);
  height: 100%;
  padding: 1px clamp(7px,2.4vw,14px);
  border: 1px solid rgba(255,226,137,.76);
  border-radius: 50px;
  background:
    radial-gradient(ellipse at 50% 0, rgba(255,255,255,.2), transparent 55%),
    linear-gradient(105deg, #711e42, #39104f 50%, #761d47);
  box-shadow: inset 0 1px 3px rgba(255,255,255,.22), 0 0 0 2px rgba(130,66,21,.72), 0 0 10px rgba(255,198,70,.36);
}
.royal-crest::before, .royal-crest::after {
  position: absolute;
  top: 50%;
  width: 14px;
  height: 14px;
  border: 1px solid #ffedaa;
  background: linear-gradient(145deg,#fff2a1,#d58b23 50%,#772546);
  box-shadow: 0 0 8px rgba(255,205,83,.8), inset 0 0 3px white;
  content: "";
  transform: translateY(-50%) rotate(45deg);
}
.royal-crest::before { left: -7px; }
.royal-crest::after { right: -7px; }
.crest-star { color: #fff0a1; font-size: clamp(9px,3vw,15px); text-shadow: 0 1px #8a4218, 0 0 8px #ffc64b; }
.crest-crown { display: grid; width: clamp(20px,6vw,29px); place-items: center; filter: drop-shadow(0 1px 1px #4e0b24) drop-shadow(0 0 4px #ffcf5a); }
.crest-crown svg { width: 100%; fill: #f4bb43; stroke: #fff0a1; stroke-linejoin: round; stroke-width: 1.5; }
.crest-wordmark { display: flex; flex-direction: column; align-items: center; line-height: .78; }
.crest-wordmark small { color: #ffe8ad; font-size: clamp(5px,1.5vw,7px); font-weight: 1000; letter-spacing: .3em; }
.crest-wordmark strong { color: #ff453b; font-family: Impact,Haettenschweiler,"Arial Narrow Bold",sans-serif; font-size: clamp(22px,7vw,34px); font-style: italic; letter-spacing: -.08em; -webkit-text-stroke: 1px #ffe699; text-shadow: 0 1px #9b281e, 0 3px #7f331a, 0 0 9px #ff4d31; }

.payout-board {
  padding: 4px;
  border: 1px solid #fff0a9;
  border-radius: 15px;
  background: linear-gradient(135deg,#fff3b0 0%,#a55b21 14%,#f4cb64 26%,#6f2b89 29%,#501668 72%,#f2c65b 76%,#834117);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.46), 0 0 0 2px rgba(99,43,20,.75), 0 4px 13px rgba(0,0,0,.55), 0 0 12px rgba(228,117,255,.2);
}
.board-inner {
  border: 1px solid rgba(255,224,145,.9);
  border-radius: 10px;
  background:
    radial-gradient(circle at 8px 8px, rgba(227,177,255,.09) 1px, transparent 2px),
    radial-gradient(circle at 0 0, rgba(255,255,255,.045) 1px, transparent 2px),
    linear-gradient(140deg,#391050,#240a3b 52%,#581136);
  background-size: 16px 16px,16px 16px,auto;
  box-shadow: inset 0 0 15px rgba(7,0,16,.68), inset 0 1px 0 rgba(255,255,255,.15);
}
.board-heading { min-height: 14px; }
.board-title { color: #fff0a1; text-shadow: 0 1px #58102f,0 0 6px rgba(255,214,99,.58); }
.royal-trinkets { display: flex; flex: 0 0 auto; align-items: center; gap: 4px; }
.royal-trinkets svg { width: clamp(9px,3vw,13px); height: clamp(9px,3vw,13px); overflow: visible; fill: #f3bb4d; stroke: #fff1a7; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.5; filter: drop-shadow(0 1px 2px #290a37); }
.board-caption { color: #e9c5ff; }
.payout-prize, .wild-prize {
  border-color: rgba(255,225,147,.68);
  background: linear-gradient(105deg,rgba(42,8,66,.96),rgba(99,25,81,.92));
  box-shadow: inset 0 1px rgba(255,255,255,.12),0 1px 3px rgba(0,0,0,.25);
}
.prize-symbols { color: #fff2d1; }
.prize-times, .wild-prize b { color: #ffe68b; text-shadow: 0 1px #6c1740,0 0 5px rgba(255,218,101,.62); }
.bonus-box, .respin-box { border-color: rgba(255,225,147,.62); background: linear-gradient(145deg,rgba(54,16,81,.88),rgba(34,7,48,.94)); }
.multiplier-badge { border-color: #ffe8a0; background: radial-gradient(circle at 32% 24%,#df5f92,#641a6e 68%,#291044); }

.cabinet-frame {
  padding: 6px 8px 7px;
  border: 3px solid #ffe69a;
  border-radius: 18px;
  background:
    linear-gradient(135deg,rgba(255,255,255,.26),transparent 16%),
    linear-gradient(140deg,#fff0a5 0%,#ad5d1d 10%,#f0c555 17%,#5f1c84 20%,#2c104c 47%,#6d1d75 74%,#f7d36b 79%,#803b19 88%,#ffe8a0);
  box-shadow:
    inset 0 0 0 2px rgba(255,249,193,.8),
    inset 0 0 0 5px rgba(109,49,22,.86),
    inset 0 0 18px rgba(17,2,34,.72),
    0 0 0 2px #773c1b,
    0 5px 15px rgba(0,0,0,.62),
    0 0 16px rgba(219,95,255,.35);
}
.cabinet-frame::before { inset: 5px; border: 1px solid rgba(255,241,172,.72); border-radius: 12px; box-shadow: inset 0 0 0 2px rgba(255,255,255,.09); }
.cabinet-frame::after { inset: 3px; border-radius: 13px; background: linear-gradient(112deg,transparent 37%,rgba(255,255,255,.18) 49%,transparent 60%); background-size: 240% 100%; }
.cabinet-rivets i { width: 5px; height: 5px; border-color: #fff3b8; background: radial-gradient(circle at 35% 25%,#fff5b0,#b66525 74%); box-shadow: 0 0 5px #f4c252; }
.reel-headings { color: #fff2b0; text-shadow: 0 1px #3a0c52,0 0 6px rgba(220,113,255,.55); }
.reel-headings span:last-child { color: #f4d0ff; }
.led-row i { background: #ff42d2; box-shadow: 0 0 7px 2px #eb2ecb; }
.reel-window {
  border: 2px solid #ffdc7e;
  border-radius: 11px;
  background: linear-gradient(180deg,#250c3f,#130720);
  box-shadow: inset 0 3px 9px rgba(0,0,0,.82),0 0 0 2px #8b4b1a,0 0 13px rgba(226,70,255,.35);
}
.reel-strip {
  border-color: #ffe7a4;
  background: linear-gradient(90deg,#4b164d,#b06a3c 8%,#f7d696 18%,#653052 32%,#3b104b 50%,#d89b53 68%,#4a1646 86%,#d19649);
  box-shadow: inset 0 9px 12px rgba(21,3,33,.88),inset 0 -10px 12px rgba(21,3,33,.9),inset 0 0 0 2px rgba(255,230,158,.4);
}
.reel-symbol {
  border-color: rgba(255,231,173,.9);
  background: linear-gradient(145deg,#82214c,#3a104f 65%,#78183d);
  box-shadow: inset 0 2px 3px rgba(255,255,255,.38),inset 0 -5px 7px rgba(0,0,0,.7),0 2px 4px rgba(18,3,29,.76),0 0 4px rgba(255,209,94,.25);
}
.symbol-seven {
  color: #f32d30;
  border-color: #fff0a7;
  background: linear-gradient(155deg,#fff6c2,#ef9b36 17%,#c32833 39%,#70113c 74%,#ed6e37);
  text-shadow: 0 1px #fff4bc,0 2px #ffb539,0 4px #82112e,0 6px 6px rgba(25,2,28,.88),0 0 10px rgba(255,71,74,.8);
}
.symbol-bar {
  border-color: #fff0a6;
  background: linear-gradient(160deg,#fff8c6,#e9ac43 28%,#a92147 33%,#421047 68%,#db9738 74%,#fff0a8);
}
.symbol-cherry {
  border-color: #ffc184;
  background: radial-gradient(ellipse at 32% 18%,#ffd1b6,#f13455 30%,#9f113d 67%,#320c3f);
  box-shadow: inset 0 2px 5px rgba(255,245,232,.55),inset 0 -6px 8px rgba(38,1,18,.72),0 2px 4px #220b31,0 0 8px rgba(255,59,101,.42);
}
.symbol-cherry::before { border-color: #e5ff86; background: linear-gradient(135deg,#efff9a,#218944 75%); }
.bonus-strip {
  border-color: #d698ff;
  background: linear-gradient(90deg,#19062f,#7839a6 18%,#321052 48%,#7540a5 82%,#150427);
  box-shadow: inset 0 1px #e4b7ff,inset 0 -1px #e4b7ff,inset 0 0 10px rgba(9,0,25,.86),0 0 7px rgba(216,117,255,.72);
}
.center-payline { background: rgba(255,55,90,.92); box-shadow: 0 0 6px 2px #ff2d64; }

.machine-status {
  display: flex;
  min-width: 0;
  min-height: 20px;
  flex: 0 0 20px;
  align-items: center;
  gap: 6px;
  margin: 4px 3px 0;
  padding: 1px 7px;
  overflow: hidden;
  border: 1px solid rgba(255,222,141,.72);
  border-radius: 14px;
  background: linear-gradient(90deg,#240b3c,#42104f 50%,#260a39);
  box-shadow: inset 0 1px 4px rgba(0,0,0,.6),0 0 6px rgba(216,104,255,.2);
}
.machine-status .result-message { flex: 1 1 0; color: #f9e5bf; font-size: clamp(7px,1.9vw,9px); }
.machine-status .room-feed { flex: 0 1 auto; max-width: 58%; }
.machine-status .room-ticker { max-width: clamp(52px,27vw,150px); font-size: 7px; }
.machine-status .room-feed-toggle { min-height: 15px; }

.control-deck {
  display: flex;
  min-height: 0;
  flex-direction: column;
  justify-content: space-between;
  gap: 5px;
  padding: 7px 8px 5px;
  border: 2px solid #fff0a4;
  border-radius: 17px;
  background:
    linear-gradient(135deg,rgba(255,255,255,.15),transparent 22%),
    linear-gradient(112deg,#6b287f,#31114e 35%,#57113f 68%,#31104c);
  box-shadow:
    inset 0 0 0 2px rgba(255,255,255,.2),
    inset 0 -5px 12px rgba(11,2,31,.7),
    0 0 0 2px #814619,
    0 5px 13px rgba(0,0,0,.58),
    0 0 14px rgba(222,94,255,.28);
}
.control-main {
  display: grid;
  min-height: 0;
  flex: 1;
  grid-template-columns: minmax(78px,1fr) minmax(58px,.92fr) clamp(55px,18vw,78px);
  align-items: center;
  gap: 5px;
}
.bet-cluster { display: grid; min-width: 0; grid-template-rows: auto auto auto; gap: 4px; }
.wallet-bar {
  min-height: 22px;
  border: 1px solid #ffdf86;
  background: linear-gradient(90deg,#240b3e,#501344);
  box-shadow: inset 0 2px 4px rgba(0,0,0,.7),0 0 0 1px rgba(135,66,25,.72);
}
.coin-stack { color: #ffe280; text-shadow: 0 0 5px #ffb72e; }
.wallet-bar strong { color: #fff0a7; font-size: clamp(8px,2.6vw,12px); }
.topup-button {
  width: 19px;
  height: 19px;
  border-color: #fff5b9;
  color: #fff;
  background: radial-gradient(circle at 32% 24%,#8dffc1,#13b35b 60%,#086a37);
  box-shadow: inset 0 1px 2px rgba(255,255,255,.7),0 0 0 1px #96551c,0 0 7px rgba(74,255,155,.44);
}
.bet-control-row { gap: 3px; }
.bet-adjust {
  flex: 0 0 clamp(23px,7vw,31px);
  width: clamp(23px,7vw,31px);
  height: clamp(23px,7vw,31px);
  border: 1px solid #e4ffbd;
  color: #fff;
  background: radial-gradient(circle at 32% 22%,#8dffc1,#17b260 58%,#07562f);
  box-shadow: inset 0 1px 3px rgba(255,255,255,.58),0 0 0 1px #814319,0 2px 4px rgba(0,0,0,.46),0 0 7px rgba(91,255,151,.32);
  font-size: 18px;
}
.bet-display {
  min-width: 30px;
  padding: 2px 3px;
  border: 1px solid #ffe08a;
  border-radius: 6px;
  background: linear-gradient(180deg,#311047,#1d092e);
  box-shadow: inset 0 2px 5px rgba(0,0,0,.72),0 0 0 1px rgba(143,76,25,.6);
}
.bet-display span { color: #dfb5f7; }
.bet-display strong { color: #fff0a2; font-size: clamp(12px,4vw,17px); text-shadow: 0 1px #a42934,0 0 5px rgba(255,220,114,.3); }
.bet-cluster .mode-buttons { gap: 3px; }
.mode-button {
  min-height: clamp(21px,4vh,28px);
  border: 1px solid #ffedaa;
  color: #ffe8a1;
  background: linear-gradient(180deg,#883e89,#4b1a67 72%,#321147);
  box-shadow: inset 0 1px rgba(255,255,255,.32),0 1px 3px rgba(0,0,0,.48);
  font-size: clamp(6px,1.9vw,8px);
}
.mode-button small { color: #e4c2fb; font-size: 5px; }
.mode-button.active { color: #fff4b6; background: linear-gradient(180deg,#c8625a,#821c4b 75%,#4b124d); box-shadow: 0 0 7px rgba(255,210,80,.72),inset 0 1px rgba(255,255,255,.45); }
.control-center { position: relative; display: grid; min-width: 0; place-items: center; }
.win-bar {
  position: relative;
  z-index: 1;
  display: flex;
  width: 100%;
  min-width: 0;
  min-height: 35px;
  flex: 0 0 35px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 0;
  padding: 3px 6px;
  border: 2px solid #ffe899;
  border-radius: 20px;
  background: linear-gradient(105deg,#7c173e,#d63e44 18%,#861341 48%,#b02a45 80%,#60103f);
  box-shadow: inset 0 1px rgba(255,255,255,.48),inset 0 -4px 6px rgba(52,0,30,.6),0 0 0 2px #89501d,0 2px 5px #160824,0 0 9px rgba(255,95,136,.44);
}
.win-label { color: #fff0a1; font-size: 7px; }
.win-bar strong { color: #fff3b0; font-size: clamp(13px,4.2vw,19px); text-shadow: 0 1px #a23028,0 0 8px rgba(255,222,108,.8); }
.win-currency { color: #ffe0bf; font-size: 5px; }
.center-leaves { position: absolute; z-index: 0; inset: 0; color: #ffd76f; font-size: 0; pointer-events: none; }
.center-leaves::before,.center-leaves::after { position: absolute; top: 50%; color: #ffdc76; font-family: Georgia,serif; font-size: 25px; line-height: 1; text-shadow: 0 1px #8f4219,0 0 5px rgba(255,214,87,.66); content: "❧"; transform: translateY(-50%); }
.center-leaves::before { left: -5px; }
.center-leaves::after { right: -5px; transform: translateY(-50%) scaleX(-1); }
.spin-stack { display: flex; min-width: 0; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.spin-button {
  width: clamp(53px,17vw,74px);
  flex: 0 0 auto;
  border: 3px solid #fff3a7;
  color: #fff;
  background: radial-gradient(circle at 32% 22%,#91ffc2 0,#21ce73 38%,#078442 68%,#07532e 84%);
  box-shadow: 0 0 0 2px #ad6d24,0 0 0 4px #5a2c17,inset 0 2px 7px rgba(255,255,255,.75),inset 0 -7px 10px rgba(0,52,30,.6),0 4px 8px rgba(0,0,0,.62),0 0 15px rgba(83,255,154,.55);
  font-size: clamp(8px,2.6vw,11px);
  text-shadow: 0 1px 2px #075326,0 0 7px rgba(255,255,255,.4);
}
.spin-arrows { font-size: clamp(23px,7vw,34px); }
.spin-button.theme-gold { background: radial-gradient(circle at 32% 22%,#fff7bd,#efb63e 45%,#a75413 82%); }
.spin-button.theme-crimson { background: radial-gradient(circle at 32% 22%,#ffb0a1,#e22c58 48%,#700d39 84%); }
.max-bet-button {
  width: 100%;
  min-height: 21px;
  padding: 2px 3px;
  border: 1px solid #fff0aa;
  border-radius: 16px;
  color: #4a1b47;
  background: linear-gradient(180deg,#fff3b0,#e4a834 55%,#a85b1b);
  box-shadow: inset 0 1px rgba(255,255,255,.78),0 0 0 1px #753e1b,0 2px 4px rgba(0,0,0,.48);
  font-size: clamp(6px,1.9vw,8px);
  font-weight: 1000;
  letter-spacing: .04em;
  cursor: pointer;
}
.action-dock {
  display: grid;
  min-width: 0;
  min-height: 27px;
  flex: 0 0 27px;
  grid-template-columns: repeat(10,minmax(0,1fr));
  align-items: center;
  gap: clamp(2px,.8vw,5px);
  padding: 2px 4px;
  border: 1px solid rgba(255,229,148,.84);
  border-radius: 18px;
  background: linear-gradient(90deg,#220a39,#4b145f 42%,#581239 72%,#260b3c);
  box-shadow: inset 0 1px rgba(255,255,255,.23),inset 0 -3px 5px rgba(0,0,0,.62),0 0 0 1px rgba(142,77,26,.8);
}
.dock-button {
  display: grid;
  min-width: 0;
  width: clamp(20px,6.2vw,29px);
  height: clamp(20px,6.2vw,29px);
  place-items: center;
  justify-self: center;
  padding: 3px;
  border: 1px solid #fff0a7;
  border-radius: 50%;
  color: #ffe8a2;
  background: radial-gradient(circle at 32% 22%,#924a92,#552065 57%,#2c0d49);
  box-shadow: 0 0 0 1px #783e19,inset 0 1px rgba(255,255,255,.42),inset 0 -3px 4px rgba(15,2,29,.7),0 2px 4px rgba(0,0,0,.55),0 0 7px rgba(216,118,255,.27);
  cursor: pointer;
  transition: transform .12s,filter .12s,box-shadow .12s;
}
.dock-button svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.dock-button #sound-muted { display: none; }
.dock-button.muted #sound-waves { display: none; }
.dock-button.muted #sound-muted { display: block; }
.dock-button.muted { color: #ffabb8; }
.dock-button:hover { filter: brightness(1.2); box-shadow: 0 0 0 1px #b26a26,inset 0 1px rgba(255,255,255,.5),0 0 9px rgba(255,202,99,.48); }
.dock-button:active { transform: scale(.92); }
.dock-info { display: grid; width: 13px; height: 13px; place-items: center; border: 1px solid currentColor; border-radius: 50%; font-family: Georgia,serif; font-size: 11px; font-weight: 900; }
.dock-star { color: #fff0a4; font-size: 10px; text-shadow: 0 0 5px #ffdc69; }
.action-dock .mode-toggle {
  display: flex;
  width: clamp(28px,8vw,38px);
  height: clamp(20px,6.2vw,29px);
  flex-direction: row;
  gap: 1px;
  padding: 2px;
  border-radius: 18px;
  color: #fff1a7;
  font-size: 5px;
  letter-spacing: 0;
}
.action-dock .mode-toggle[hidden] { display: none; }
.action-dock .exit-button { color: #ffcf82; }
.paytable-modal { display: grid; gap: 5px; }
.paytable-modal .payout-prize { min-height: 28px; padding: 4px 7px; border-radius: 7px; }
.paytable-modal .prize-symbols { font-size: 9px; }
.paytable-modal .prize-times { font-size: 12px; }
.dock-button:disabled,.max-bet-button:disabled { filter: grayscale(.5); opacity: .55; cursor: default; }

@media (max-height: 620px) {
  .control-deck { gap: 3px; padding: 5px 6px 4px; }
  .action-dock { min-height: 23px; flex-basis: 23px; padding: 1px 3px; }
  .dock-button { width: 21px; height: 21px; }
  .action-dock .mode-toggle { width: 29px; height: 21px; }
  .control-main { gap: 4px; }
  .mode-button { min-height: 20px; }
  .machine-status { min-height: 18px; flex-basis: 18px; margin-top: 3px; }
}

@media (max-width: 320px) {
  .royal-crest { gap: 3px; padding-right: 7px; padding-left: 7px; }
  .header-room-status { font-size: 6px; letter-spacing: .05em; }
  .royal-trinkets { gap: 2px; }
  .board-caption { display: none; }
  .control-deck { padding-right: 5px; padding-left: 5px; }
  .control-main { grid-template-columns: minmax(76px,1fr) minmax(55px,.86fr) 53px; gap: 3px; }
  .bet-adjust { flex-basis: 23px; width: 23px; height: 23px; }
  .win-bar { min-height: 31px; flex-basis: 31px; gap: 2px; padding-right: 3px; padding-left: 3px; }
  .win-label { font-size: 6px; }
  .win-bar strong { font-size: 12px; }
  .win-currency { font-size: 4px; }
  .spin-button { width: 51px; }
  .action-dock { gap: 1px; padding-right: 2px; padding-left: 2px; }
  .dock-button { width: 20px; height: 20px; padding: 2px; }
  .action-dock .mode-toggle { width: 27px; height: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .cabinet-frame,.cabinet-frame::after,.led-row i,.reel-strip.is-spinning .reel-track,.bonus-strip.is-spinning .reel-track { animation-duration: 1ms !important; }
  .dock-button { transition: none; }
}

body {
  background:
    radial-gradient(ellipse at 50% 0,rgba(132,70,201,.24),transparent 44%),
    linear-gradient(160deg,#2b0d52 0%,#1e0a3d 46%,#14072b 100%);
}
.game-shell {
  grid-template-rows: clamp(44px,8dvh,60px) minmax(0,.95fr) minmax(0,1.35fr) clamp(124px,20dvh,170px);
}
.header-bar {
  grid-template-columns: minmax(0,.95fr) auto minmax(0,1.08fr);
  gap: 3px;
  padding: 3px 4px;
  border-color: #ffe79a;
  border-radius: 12px;
  background: linear-gradient(110deg,#3b175e,#210b43 48%,#50123e);
  box-shadow: inset 0 1px rgba(255,255,255,.3),inset 0 -3px 5px rgba(10,2,28,.65),0 0 0 2px #8f511f,0 3px 9px rgba(0,0,0,.55),0 0 11px rgba(222,98,255,.28);
}
.header-left { gap: clamp(2px,.7vw,5px); }
.header-icon-button {
  display: grid;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  place-items: center;
  padding: 4px;
  border: 1px solid #fff0a8;
  border-radius: 50%;
  color: #ffe9a5;
  background: radial-gradient(circle at 32% 22%,#985b83,#501b65 58%,#270d43);
  box-shadow: inset 0 1px rgba(255,255,255,.45),0 0 0 1px #88491d,0 2px 4px rgba(0,0,0,.6),0 0 7px rgba(223,130,255,.35);
  cursor: pointer;
}
.header-icon-button svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.header-icon-button #sound-muted { display: none; }
.header-icon-button.muted #sound-waves { display: none; }
.header-icon-button.muted #sound-muted { display: block; }
.header-icon-button.muted { color: #ffb1b8; }
.header-icon-button:active { transform: scale(.93); }
.header-left .signal-status {
  display: grid;
  grid-template-columns: 14px auto;
  grid-template-rows: 12px 6px;
  column-gap: 2px;
  row-gap: 0;
  min-width: 0;
  padding: 0;
  font-size: 7px;
}
.signal-bars { grid-column: 1; grid-row: 1; }
#latency-value { grid-column: 2; grid-row: 1; align-self: center; }
.signal-status small {
  grid-column: 1 / -1;
  grid-row: 2;
  color: #d7c2ef;
  font-size: 4px;
  font-weight: 800;
  letter-spacing: .04em;
  line-height: 1;
  white-space: nowrap;
}
.royal-crest {
  gap: clamp(2px,.75vw,6px);
  padding: 1px 8px;
}
.royal-crest::before,.royal-crest::after { width: 10px; height: 10px; }
.crest-crown { width: clamp(17px,5vw,25px); }
.crest-wordmark small { font-size: clamp(4px,1.1vw,6px); }
.crest-wordmark strong { font-size: clamp(22px,6.8vw,33px); }
.header-actions {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(4,minmax(0,1fr));
  align-items: center;
  justify-items: center;
  gap: 1px;
}
.header-action {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
}
.header-action small {
  max-width: 100%;
  overflow: hidden;
  color: #f7dfb0;
  font-size: 4.5px;
  font-weight: 900;
  line-height: 1;
  text-overflow: clip;
  white-space: nowrap;
}
.mode-header-button {
  grid-template-rows: 12px 5px;
  gap: 0;
  padding: 3px;
}
.mode-header-button svg { width: 12px; height: 12px; }
.mode-header-button span { color: #fff2aa; font-size: 4px; font-weight: 1000; line-height: 1; }
.mode-toggle[hidden] { display: none; }
.header-action:has(.mode-toggle[hidden]) { display: none; }
.header-actions:has(.mode-toggle[hidden]) { grid-template-columns: repeat(3,minmax(0,1fr)); }
.exit-button { color: #ffcf82; }

.board-inner {
  background:
    radial-gradient(ellipse at 50% 0,rgba(209,57,79,.24),transparent 65%),
    linear-gradient(145deg,#641027,#3b0a20 60%,#25091c);
}
.board-heading {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto auto auto;
  align-items: center;
  justify-content: initial;
  gap: 4px;
}
.board-title {
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  color: #fff0a1;
  background: transparent;
  font: inherit;
  font-size: clamp(7px,2.4vw,10px);
  font-weight: 1000;
  letter-spacing: .08em;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}
.board-caption { font-size: 5px; }
.board-info-button {
  display: grid;
  width: 12px;
  height: 12px;
  place-items: center;
  padding: 0;
  border: 1px solid #ffe39a;
  border-radius: 50%;
  color: #ffe9a7;
  background: linear-gradient(145deg,#9c4b35,#57102f);
  font-size: 8px;
  font-weight: 1000;
  line-height: 1;
  cursor: pointer;
}
.payout-prize,.wild-prize { background: linear-gradient(105deg,rgba(51,7,24,.96),rgba(115,20,43,.94)); }
.bonus-box,.respin-box { background: linear-gradient(145deg,rgba(61,8,35,.95),rgba(34,5,24,.95)); }
.prize-symbols { font-size: clamp(5px,1.55vw,7px); }
.wild-label { font-size: clamp(4px,1.55vw,7px); }

.cabinet-frame {
  grid-template-rows: none;
  border: 3px solid #ffe89b;
  border-radius: 16px;
  background:
    linear-gradient(135deg,rgba(255,255,255,.24),transparent 18%),
    linear-gradient(140deg,#fff1ad 0%,#a55b20 12%,#f3c758 18%,#5b1d79 21%,#2b1049 48%,#6a1a73 76%,#f5cb5b 80%,#7c3d1a 90%,#ffedaa);
  box-shadow: inset 0 0 0 2px rgba(255,249,193,.8),inset 0 0 0 5px rgba(109,49,22,.86),inset 0 0 17px rgba(17,2,34,.72),0 0 0 2px #773c1b,0 5px 15px rgba(0,0,0,.62),0 0 16px rgba(219,95,255,.35);
}
.cabinet-frame > :not(.cabinet-rivets) { position: relative; z-index: 1; }
.machine-status {
  min-height: 17px;
  flex-basis: 17px;
  margin: 3px 3px 0;
  padding: 1px 6px;
}
.machine-status .room-feed { max-width: 62%; }
.machine-status .room-ticker { max-width: clamp(40px,27vw,140px); }
.win-bar {
  min-height: 22px;
  flex-basis: 22px;
  justify-content: center;
  gap: 5px;
  margin: 3px 3px 0;
  padding: 1px 8px;
  border: 1px solid #ffe391;
  border-radius: 18px;
  background: linear-gradient(90deg,#2d081b,#7c1731 27%,#500c29 72%,#2a081b);
  box-shadow: inset 0 1px rgba(255,255,255,.24),inset 0 -3px 5px rgba(0,0,0,.65),0 0 0 1px #9b5b21,0 1px 4px rgba(0,0,0,.5);
}
.win-label { color: #ffe799; font-size: 8px; }
.win-bar strong { color: #fff1a7; font-size: 14px; }
.win-currency { color: #e8bc9e; font-size: 6px; }
.center-leaves { display: none; }

.control-deck {
  display: grid;
  grid-template-columns: minmax(58px,.82fr) minmax(0,1.28fr) clamp(56px,18vw,78px);
  align-items: center;
  justify-items: center;
  gap: 6px;
  padding: 6px;
  border: 2px solid #fff0a4;
  border-radius: 15px;
  background:
    linear-gradient(135deg,rgba(255,255,255,.32),transparent 18%),
    linear-gradient(130deg,#fff0a2 0%,#bd762d 12%,#f2ce67 18%,#541b70 21%,#32114d 55%,#5c174a 78%,#e0a644 82%,#7d421d);
  box-shadow: inset 0 0 0 2px rgba(255,251,205,.55),inset 0 -6px 12px rgba(17,3,33,.6),0 0 0 2px #78401c,0 4px 12px rgba(0,0,0,.54),0 0 12px rgba(229,135,255,.22);
}
.player-panel {
  display: flex;
  width: 100%;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.avatar-box {
  position: relative;
  display: grid;
  width: clamp(33px,6.8vh,46px);
  aspect-ratio: 1;
  place-items: center;
  border: 2px solid #fff0a6;
  border-radius: 9px;
  color: #ffe68b;
  background: radial-gradient(circle at 34% 22%,#934b99,#46185f 65%,#260c43);
  box-shadow: inset 0 1px rgba(255,255,255,.52),inset 0 -5px 7px rgba(12,1,25,.75),0 0 0 2px #824619,0 2px 5px rgba(0,0,0,.58),0 0 9px rgba(226,128,255,.38);
}
.avatar-box span { font-size: clamp(21px,5.4vh,30px); line-height: 1; text-shadow: 0 1px #7f3315,0 0 7px #ffdb69; }
.avatar-box i { position: absolute; right: 3px; bottom: 3px; width: 6px; height: 6px; border: 1px solid #fff2a1; border-radius: 50%; background: #5dffa3; box-shadow: 0 0 5px #5dffa3; }
.wallet-bar {
  min-height: 23px;
  padding: 2px 3px;
  border-color: #ffe28a;
  border-radius: 16px;
  background: linear-gradient(90deg,#280c3e,#54133e);
  box-shadow: inset 0 2px 4px rgba(0,0,0,.72),0 0 0 1px #814619;
}
.wallet-bar strong { font-size: clamp(7px,2.4vw,11px); }
.topup-button { width: 18px; height: 18px; font-size: 15px; }
.bet-control { width: 100%; gap: clamp(5px,1.1vh,8px); }
.bet-control-row { gap: 4px; }
.bet-adjust {
  flex-basis: clamp(25px,7.5vw,33px);
  width: clamp(25px,7.5vw,33px);
  height: clamp(25px,7.5vw,33px);
  border-color: #d6ffbb;
  background: radial-gradient(circle at 32% 22%,#92ffc2,#18b664 57%,#07542e);
  box-shadow: inset 0 1px 3px rgba(255,255,255,.68),0 0 0 1px #8a4c1d,0 2px 4px rgba(0,0,0,.5),0 0 7px rgba(86,255,153,.35);
}
.bet-display { min-width: 38px; }
.bet-cluster { display: none; }
.mode-buttons { gap: 4px; }
.mode-button {
  min-height: clamp(24px,4.6vh,32px);
  flex-direction: row;
  gap: 3px;
  padding: 2px 4px;
  border: 1px solid #fff0a6;
  border-radius: 18px;
  color: #4a1947;
  background: linear-gradient(180deg,#fff0a5,#e6a438 65%,#a85e21);
  box-shadow: inset 0 1px rgba(255,255,255,.75),0 0 0 1px #744019,0 2px 4px rgba(0,0,0,.45);
  font-size: clamp(6px,1.9vw,8px);
}
.mode-button small { color: #71341e; font-size: 5px; }
.mode-button.active { color: #fff4b8; background: linear-gradient(180deg,#e76654,#98234e 72%,#50134e); box-shadow: 0 0 8px rgba(255,214,99,.72),inset 0 1px rgba(255,255,255,.45); }
.mode-button.active small { color: #fff0c1; }
.spin-button {
  width: clamp(55px,17vw,76px);
  border: 4px double #fff2a5;
  background: radial-gradient(circle at 32% 20%,#9bffc8 0,#2bd37a 36%,#078343 68%,#064c2a 88%);
  box-shadow: 0 0 0 2px #a56422,0 0 0 4px #542d18,inset 0 2px 8px rgba(255,255,255,.78),inset 0 -8px 11px rgba(0,45,24,.65),0 4px 8px rgba(0,0,0,.62),0 0 16px rgba(82,255,153,.5);
}
.spin-button.theme-gold { background: radial-gradient(circle at 32% 20%,#fff7bd,#efb63e 45%,#a75413 82%); }
.spin-button.theme-crimson { background: radial-gradient(circle at 32% 20%,#ffb0a1,#e22c58 48%,#700d39 84%); }
.bonus-strip .reel-symbol.bonus-face-bonus-7 { color: #fff0a4; font-family: Impact,Haettenschweiler,"Arial Narrow Bold",sans-serif; font-size: clamp(12px,4vw,20px); font-weight: 1000; text-shadow: 0 1px #fff,0 2px #ffc544,0 4px #9a451c,0 5px 5px #14071e; }

@media (max-height: 620px) {
  .game-shell { grid-template-rows: 43px minmax(0,.95fr) minmax(0,1.3fr) 124px; gap: 4px; }
  .header-bar { padding-top: 2px; padding-bottom: 2px; }
  .cabinet-frame { padding-top: 3px; padding-bottom: 4px; }
  .reel-headings { flex-basis: 11px; }
  .machine-status { min-height: 15px; flex-basis: 15px; margin-top: 2px; }
  .win-bar { min-height: 20px; flex-basis: 20px; margin-top: 2px; }
  .control-deck { padding: 4px; gap: 4px; }
  .avatar-box { width: 32px; }
  .wallet-bar { min-height: 21px; }
  .mode-button { min-height: 23px; }
  .spin-button { width: 55px; }
}
@media (max-width: 320px) {
  .header-bar { grid-template-columns: minmax(68px,.9fr) minmax(72px,auto) minmax(90px,1.05fr); gap: 2px; padding-right: 3px; padding-left: 3px; }
  .header-left { gap: 2px; }
  .header-icon-button { flex-basis: 21px; width: 21px; height: 21px; padding: 3px; }
  .header-actions { gap: 0; }
  .header-action small { font-size: 4px; }
  .mode-header-button { padding: 2px; }
  .royal-crest { gap: 2px; padding-right: 6px; padding-left: 6px; }
  .crest-wordmark strong { font-size: 22px; }
  .crest-crown { width: 16px; }
  .header-left .signal-status { grid-template-columns: 12px auto; font-size: 6px; }
  .signal-status small { font-size: 3.4px; letter-spacing: 0; }
  .board-heading { gap: 2px; }
  .royal-trinkets { gap: 1px; }
  .royal-trinkets svg { width: 8px; height: 8px; }
  .board-caption { display: block; font-size: 4px; }
  .board-info-button { width: 10px; height: 10px; }
  .control-deck { grid-template-columns: minmax(56px,.82fr) minmax(0,1.28fr) 55px; gap: 3px; }
  .wallet-bar { gap: 2px; }
  .wallet-bar strong { font-size: 7px; }
  .bet-adjust { flex-basis: 24px; width: 24px; height: 24px; }
  .bet-display { min-width: 33px; }
  .bet-display strong { font-size: 13px; }
  .mode-button { gap: 2px; padding-right: 2px; padding-left: 2px; font-size: 6px; }
  .win-bar { min-height: 19px; flex-basis: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .cabinet-frame,.cabinet-frame::after,.led-row i,.reel-strip.is-spinning .reel-track,.bonus-strip.is-spinning .reel-track { animation-duration: 1ms !important; }
}
body.display-three-quarter .reel-symbol { margin: 0 2px; }
body.display-three-quarter .symbol-seven { font-size: clamp(8px,1.55dvh,14px); }
body.display-three-quarter .bonus-strip .bonus-center { font-size: clamp(8px,1.55dvh,14px); }
body.display-three-quarter .bonus-strip .bonus-center.respin-result { font-size: clamp(7px,1.3dvh,9px); }
body.display-three-quarter .bonus-strip .reel-symbol.bonus-face-bonus-7 { font-size: clamp(8px,1.55dvh,14px); }
@media (max-height: 620px) {
  body.display-three-quarter .game-shell {
    grid-template-rows: 40px minmax(92px,.75fr) minmax(0,1.4fr) 112px;
  }
  body.display-three-quarter .control-deck { padding: 4px; }
}
