/* celebque roulette: neon arcade theme */
:root {
  --bg: #07040f;
  --bg-2: #0e0820;
  --panel: rgba(20, 12, 42, 0.72);
  --panel-solid: #140c2a;
  --line: rgba(160, 130, 255, 0.18);
  --text: #ece8ff;
  --muted: #9a92c4;
  --cyan: #36e7ff;
  --lime: #c8ff3d;
  --pink: #ff3df0;
  --red: #ff3b5c;
  --felt-red: #d92d48;
  --felt-black: #1b1530;
  --felt-green: #12a66b;
  --font-rajdhani: "Rajdhani";
  --display: "Rajdhani", "Chakra Petch", system-ui, sans-serif;
  --body: "Chakra Petch", system-ui, sans-serif;
  --tube: "Monoton", "Rajdhani", sans-serif;
  --radius: 14px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  color: var(--text);
  background:
    radial-gradient(60vw 50vh at 85% -10%, rgba(255, 61, 240, 0.16), transparent 60%),
    radial-gradient(70vw 60vh at -10% 110%, rgba(54, 231, 255, 0.14), transparent 60%),
    var(--bg);
  overflow-x: hidden;
}
/* perspective floor grid */
body::before {
  content: "";
  position: fixed;
  inset: auto -50% -10% -50%;
  height: 55vh;
  background:
    repeating-linear-gradient(90deg, rgba(54, 231, 255, 0.16) 0 1px, transparent 1px 70px),
    repeating-linear-gradient(0deg, rgba(255, 61, 240, 0.14) 0 1px, transparent 1px 70px);
  transform: perspective(500px) rotateX(62deg);
  transform-origin: bottom;
  mask-image: linear-gradient(to top, #000 10%, transparent 85%);
  pointer-events: none;
  z-index: -1;
}
/* scanlines */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.022) 0 1px, transparent 1px 3px);
  pointer-events: none;
  z-index: 100;
}

a { color: var(--cyan); }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- nav ---------- */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(16px, 4vw, 48px);
  position: relative;
  z-index: 5;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}
.logo img { width: 34px; height: 34px; filter: drop-shadow(0 0 8px rgba(54, 231, 255, 0.6)); }
.logo b {
  font-family: var(--tube);
  font-weight: 400;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  color: #fff;
  text-shadow: 0 0 6px var(--pink), 0 0 18px var(--pink);
}
.nav-links { display: flex; align-items: center; gap: 10px; }
.nav-links .who { color: var(--muted); font-size: 0.85rem; margin-right: 6px; max-width: 22ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- buttons ---------- */
.btn {
  --c: var(--cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1.5px solid var(--c);
  background: transparent;
  color: var(--c);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 0 0 rgba(0, 0, 0, 0), inset 0 0 12px rgba(54, 231, 255, 0.08);
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s, color 0.2s;
}
.btn:hover { box-shadow: 0 0 18px color-mix(in srgb, var(--c) 55%, transparent), inset 0 0 14px color-mix(in srgb, var(--c) 25%, transparent); }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; box-shadow: none; }
.btn.ghost { --c: var(--muted); border-color: var(--line); color: var(--text); }
.btn.ghost:hover { --c: var(--cyan); border-color: var(--cyan); }
.btn.pay {
  --c: var(--lime);
  background: var(--lime);
  color: #120a1f;
  border-color: var(--lime);
  font-size: 1.15rem;
  padding: 15px 30px;
  box-shadow: 0 0 22px rgba(200, 255, 61, 0.45), 0 0 60px rgba(200, 255, 61, 0.18);
  animation: pulse 2.6s ease-in-out infinite;
}
.btn.pay:hover { background: #dcff7a; box-shadow: 0 0 30px rgba(200, 255, 61, 0.7), 0 0 90px rgba(200, 255, 61, 0.3); }
.btn.pay[aria-busy="true"] { animation: none; opacity: 0.7; cursor: progress; }
.btn.sm { padding: 7px 14px; font-size: 0.85rem; }
@keyframes pulse { 50% { box-shadow: 0 0 34px rgba(200, 255, 61, 0.65), 0 0 90px rgba(200, 255, 61, 0.26); } }

/* ---------- landing ---------- */
.hero {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  align-items: center;
  gap: clamp(24px, 5vw, 70px);
  padding: clamp(20px, 6vh, 70px) clamp(16px, 5vw, 64px) 40px;
  max-width: 1280px;
  margin: 0 auto;
}
.kicker {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--cyan);
  font-size: 0.85rem;
  text-shadow: 0 0 10px rgba(54, 231, 255, 0.7);
}
.hero h1 {
  font-family: var(--tube);
  font-weight: 400;
  font-size: clamp(2.6rem, 7.2vw, 6.2rem);
  line-height: 0.98;
  margin: 18px 0 22px;
  color: #fff;
  text-shadow: 0 0 4px #fff, 0 0 14px var(--pink), 0 0 40px var(--pink), 0 0 80px rgba(255, 61, 240, 0.5);
  animation: flicker 6s infinite;
}
.hero h1 em { font-style: normal; color: #fff; text-shadow: 0 0 4px #fff, 0 0 14px var(--cyan), 0 0 40px var(--cyan), 0 0 80px rgba(54, 231, 255, 0.5); }
@keyframes flicker {
  0%, 18%, 22%, 62%, 64%, 100% { opacity: 1; }
  20%, 63% { opacity: 0.55; }
}
.hero p.lede { font-size: 1.12rem; line-height: 1.6; color: #cfc8f5; max-width: 52ch; margin: 0 0 30px; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.price-tag { font-family: var(--display); color: var(--muted); font-size: 1rem; letter-spacing: 0.06em; }
.price-tag strong { color: var(--lime); font-size: 1.35rem; text-shadow: 0 0 10px rgba(200, 255, 61, 0.6); }
.fineprint { color: var(--muted); font-size: 0.78rem; margin-top: 16px; max-width: 56ch; line-height: 1.5; }

.hero-wheel { position: relative; aspect-ratio: 1; max-width: 520px; width: 100%; justify-self: center; }
.hero-wheel .ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle, #1d1438 0 38%, transparent 38.5%),
    repeating-conic-gradient(from -4.86deg, var(--felt-red) 0 9.73deg, var(--felt-black) 9.73deg 19.46deg);
  border: 3px solid var(--cyan);
  box-shadow: 0 0 30px rgba(54, 231, 255, 0.6), inset 0 0 40px rgba(0, 0, 0, 0.8), 0 0 120px rgba(255, 61, 240, 0.25);
  animation: spin 22s linear infinite;
  mask: radial-gradient(circle, transparent 0 22%, #000 22.5%);
}
.hero-wheel .ring::after {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  border: 2px dashed rgba(200, 255, 61, 0.8);
  box-shadow: 0 0 18px rgba(200, 255, 61, 0.5);
}
.hero-wheel .hub {
  position: absolute;
  inset: 34%;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 35% 30%, #4b3394, #120b26 70%);
  border: 2px solid rgba(160, 120, 255, 0.8);
  box-shadow: 0 0 30px rgba(139, 92, 255, 0.8);
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  color: var(--lime);
  text-shadow: 0 0 14px rgba(200, 255, 61, 0.9);
}
.hero-wheel .ball {
  position: absolute;
  inset: 0;
  animation: spin 3.4s cubic-bezier(.3, .1, .3, 1) infinite reverse;
}
.hero-wheel .ball::before {
  content: "";
  position: absolute;
  top: 4.5%;
  left: 50%;
  width: 4.2%;
  aspect-ratio: 1;
  translate: -50% 0;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #b9bfdc);
  box-shadow: 0 0 12px #fff;
}
@keyframes spin { to { rotate: 360deg; } }

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  max-width: 1280px;
  margin: 10px auto 40px;
  padding: 0 clamp(16px, 5vw, 64px);
}
.feature {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.feature h3 { font-family: var(--display); font-size: 1.25rem; margin: 0 0 6px; letter-spacing: 0.04em; }
.feature p { margin: 0; color: var(--muted); line-height: 1.55; font-size: 0.95rem; }
.feature .n { font-family: var(--display); font-weight: 700; color: var(--pink); text-shadow: 0 0 10px var(--pink); font-size: 0.85rem; letter-spacing: 0.2em; }

.footer { text-align: center; color: var(--muted); font-size: 0.78rem; padding: 30px 16px 40px; line-height: 1.6; }

/* staggered entrance */
.rise { opacity: 0; translate: 0 18px; animation: rise 0.7s cubic-bezier(.2, .8, .2, 1) forwards; }
.rise.d1 { animation-delay: 0.08s; } .rise.d2 { animation-delay: 0.18s; } .rise.d3 { animation-delay: 0.3s; } .rise.d4 { animation-delay: 0.42s; }
@keyframes rise { to { opacity: 1; translate: 0 0; } }

/* ---------- auth ---------- */
.auth-wrap { min-height: calc(100vh - 90px); display: grid; place-items: center; padding: 20px 16px 60px; }
.auth-card {
  width: min(420px, 100%);
  padding: 34px 30px 28px;
  border-radius: 20px;
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: blur(14px);
  box-shadow: 0 0 0 1px rgba(54, 231, 255, 0.12), 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 60px rgba(255, 61, 240, 0.12);
  position: relative;
}
.auth-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 20px;
  padding: 1px;
  background: linear-gradient(135deg, var(--cyan), transparent 40%, transparent 60%, var(--pink));
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}
.auth-card h1 { font-family: var(--tube); font-weight: 400; font-size: 1.9rem; margin: 0 0 4px; text-shadow: 0 0 12px var(--cyan); }
.auth-card .sub { color: var(--muted); margin: 0 0 24px; font-size: 0.95rem; }
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-family: var(--display); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.78rem; color: var(--muted); }
.field input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(7, 4, 15, 0.7);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field input:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(54, 231, 255, 0.18), 0 0 16px rgba(54, 231, 255, 0.3); }
.field input[aria-invalid="true"] { border-color: var(--red); }
.field .hint { font-size: 0.78rem; color: var(--muted); }
.form-error { min-height: 1.3em; color: #ff8aa0; font-size: 0.9rem; margin: 0 0 12px; }
.auth-card .btn { width: 100%; padding: 13px; }
.auth-card .switch { text-align: center; margin: 18px 0 0; color: var(--muted); font-size: 0.92rem; }

/* ---------- play ---------- */
.play {
  display: grid;
  grid-template-columns: minmax(280px, 400px) 1fr;
  grid-template-areas: "wheel table" "stats table";
  gap: 22px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 6px clamp(12px, 3vw, 36px) 40px;
  align-items: start;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  backdrop-filter: blur(10px);
}
.wheel-panel { grid-area: wheel; padding: 18px; position: relative; }
.wheel-box { position: relative; }
#wheel { width: 100%; aspect-ratio: 1; display: block; }
.pointer {
  position: absolute;
  top: -4px;
  left: 50%;
  translate: -50% 0;
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 18px solid var(--lime);
  filter: drop-shadow(0 0 6px var(--lime));
  z-index: 2;
}
.result-badge {
  position: absolute;
  inset: 50% auto auto 50%;
  translate: -50% -50%;
  width: 34%;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-content: center;
  text-align: center;
  background: rgba(7, 4, 15, 0.85);
  border: 3px solid var(--c, var(--cyan));
  box-shadow: 0 0 30px var(--c, var(--cyan)), inset 0 0 20px var(--c, var(--cyan));
  opacity: 0;
  scale: 0.5;
  transition: opacity 0.35s, scale 0.45s cubic-bezier(.3, 1.6, .5, 1);
  pointer-events: none;
}
.result-badge.show { opacity: 1; scale: 1; }
.result-badge.red { --c: var(--red); }
.result-badge.black { --c: #a99bff; }
.result-badge.green { --c: #2dffa6; }
.result-badge b { font-family: var(--display); font-size: clamp(2rem, 5vw, 3.2rem); line-height: 1; }
.result-badge small { text-transform: uppercase; letter-spacing: 0.2em; font-size: 0.7rem; color: var(--muted); }
.outcome { margin-top: 14px; text-align: center; min-height: 3.4em; }
.outcome .label { font-family: var(--display); font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; font-size: 0.78rem; color: var(--cyan); }
#outcomeText { font-size: 1.05rem; margin-top: 4px; }
#outcomeText .win { color: var(--lime); font-weight: 700; text-shadow: 0 0 10px rgba(200, 255, 61, 0.7); }
#outcomeText .lose { color: #ff8aa0; }

.table-panel { grid-area: table; padding: 18px; display: grid; gap: 16px; }
.topbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.balance {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 8px 18px;
  border-radius: 12px;
  border: 1.5px solid rgba(200, 255, 61, 0.5);
  background: rgba(200, 255, 61, 0.05);
  box-shadow: 0 0 18px rgba(200, 255, 61, 0.18);
  transition: box-shadow 0.3s;
}
.balance small { font-family: var(--display); letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); font-size: 0.72rem; }
#balanceValue { font-family: var(--display); font-weight: 700; font-size: 1.8rem; color: var(--lime); text-shadow: 0 0 12px rgba(200, 255, 61, 0.7); font-variant-numeric: tabular-nums; }
.balance.up { box-shadow: 0 0 34px rgba(200, 255, 61, 0.7); }
.balance.shake { animation: shake 0.4s; }
@keyframes shake { 25% { translate: -6px 0; } 50% { translate: 6px 0; } 75% { translate: -3px 0; } }
.stats-inline { display: flex; gap: 18px; font-size: 0.85rem; color: var(--muted); }
.stats-inline b { font-family: var(--display); font-size: 1.1rem; color: var(--text); margin-left: 4px; }
.pos { color: var(--lime) !important; }
.neg { color: #ff8aa0 !important; }

/* board: desktop = 14 cols × 5 rows; mobile = 5 cols × 14 rows (vertical table) */
.board {
  display: grid;
  grid-template-columns: 1.2fr repeat(12, minmax(0, 1fr)) 1.2fr;
  grid-template-rows: repeat(3, clamp(44px, 5vw, 62px)) 46px 46px;
  gap: 4px;
  padding: 10px;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(18, 166, 107, 0.12), rgba(54, 231, 255, 0.05)), #0a0618;
  border: 1.5px solid rgba(54, 231, 255, 0.45);
  box-shadow: 0 0 24px rgba(54, 231, 255, 0.2), inset 0 0 40px rgba(0, 0, 0, 0.6);
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.cell {
  grid-column: var(--dc);
  grid-row: var(--dr);
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid rgba(220, 210, 255, 0.18);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.03);
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(0.9rem, 1.4vw, 1.15rem);
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
  padding: 0;
  min-width: 0;
}
.cell:hover, .cell.hl { border-color: var(--cyan); box-shadow: 0 0 12px rgba(54, 231, 255, 0.55), inset 0 0 10px rgba(54, 231, 255, 0.25); }
.cell:active { transform: scale(0.96); }
.cell.num.red { background: linear-gradient(180deg, #e6345180, #a01d3580); }
.cell.num.black { background: linear-gradient(180deg, #2a2148, #15102a); }
.cell.num.green { background: linear-gradient(180deg, #16c07d90, #0a6f4890); }
.cell.outside { color: #d8d2ff; letter-spacing: 0.06em; font-size: clamp(0.75rem, 1.1vw, 0.95rem); }
.swatch { width: 26px; height: 18px; transform: rotate(45deg) scale(0.8); border-radius: 3px; }
.swatch.red { background: var(--felt-red); box-shadow: 0 0 10px var(--felt-red); }
.swatch.black { background: #2a2148; border: 1px solid #8c7fd6; }
.cell.hit { border-color: var(--lime); box-shadow: 0 0 22px rgba(200, 255, 61, 0.9), inset 0 0 16px rgba(200, 255, 61, 0.5); animation: hit 0.9s ease-in-out 3; }
.cell.win { border-color: var(--lime); box-shadow: 0 0 16px rgba(200, 255, 61, 0.65); }
@keyframes hit { 50% { box-shadow: 0 0 4px rgba(200, 255, 61, 0.3); } }
.board.locked .cell { cursor: not-allowed; }
.board.locked .cell:hover { box-shadow: none; border-color: rgba(220, 210, 255, 0.18); }

/* chips */
.chip {
  --chip: #36e7ff;
  position: relative;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.95rem;
  color: #0b0716;
  background:
    radial-gradient(circle, var(--chip) 0 54%, transparent 55%),
    repeating-conic-gradient(var(--chip) 0 22.5deg, #fff 22.5deg 45deg);
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.4), 0 3px 0 rgba(0, 0, 0, 0.45);
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s;
}
.chip span { position: relative; z-index: 1; }
.chip::after { content: ""; position: absolute; inset: 22%; border-radius: 50%; border: 1.5px dashed rgba(11, 7, 22, 0.45); }
.chip.c1 { --chip: #d4ccff; }
.chip.c5 { --chip: #ff4d6d; }
.chip.c25 { --chip: #36e7ff; }
.chip.c100 { --chip: #c8ff3d; }
.chip.c500 { --chip: #ff3df0; }
.chip.c1000 { --chip: #ffb02e; }
.chips { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.chips .chip:hover { transform: translateY(-3px); }
.chips .chip[aria-checked="true"] { transform: translateY(-6px); box-shadow: 0 0 0 3px #fff, 0 0 22px var(--chip), 0 6px 0 rgba(0, 0, 0, 0.45); }
.chips .chip:disabled { opacity: 0.5; cursor: not-allowed; }
.stake.chip {
  position: absolute;
  width: 30px;
  height: 30px;
  font-size: 0.68rem;
  pointer-events: none;
  inset: 50% auto auto 50%;
  translate: -50% -50%;
  box-shadow: 0 0 10px var(--chip), 0 2px 0 rgba(0, 0, 0, 0.5);
  animation: drop 0.22s cubic-bezier(.3, 1.6, .5, 1);
  z-index: 2;
}
@keyframes drop { from { scale: 1.6; opacity: 0; } }

.controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.controls .group { display: flex; flex-wrap: wrap; gap: 8px; }
.spin-btn {
  min-width: 150px;
  padding: 16px 34px;
  border-radius: 999px;
  border: 0;
  background: linear-gradient(90deg, var(--pink), #8b5cff 60%, var(--cyan));
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.6);
  cursor: pointer;
  box-shadow: 0 0 26px rgba(255, 61, 240, 0.55), 0 0 60px rgba(54, 231, 255, 0.25);
  transition: transform 0.15s, filter 0.2s;
}
.spin-btn:hover { filter: brightness(1.15); }
.spin-btn:active { transform: scale(0.97); }
.spin-btn:disabled { filter: grayscale(0.6) brightness(0.7); cursor: progress; }
.kbd-hint { color: var(--muted); font-size: 0.75rem; }
kbd { font-family: var(--display); border: 1px solid var(--line); border-radius: 4px; padding: 0 5px; }

.stats-panel { grid-area: stats; padding: 18px; }
.stats-panel h2 { font-family: var(--display); font-size: 0.8rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; display: flex; justify-content: space-between; }
.history { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 18px; }
.history li {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 700;
}
.history li.red { background: var(--felt-red); box-shadow: 0 0 8px rgba(217, 45, 72, 0.6); }
.history li.black { background: var(--felt-black); border: 1px solid #5d4fa5; }
.history li.green { background: var(--felt-green); box-shadow: 0 0 8px rgba(18, 166, 107, 0.7); }
.history li:first-child { outline: 2px solid var(--lime); outline-offset: 2px; }
.history li.empty { width: auto; background: none; color: var(--muted); font-family: var(--body); font-weight: 400; outline: 0; }
.dist { display: flex; height: 10px; border-radius: 99px; overflow: hidden; background: #1a1230; }
.dist span { transition: width 0.6s; }
#distRed { background: var(--felt-red); } #distBlack { background: #5d4fa5; } #distGreen { background: var(--felt-green); }
.dist-legend { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--muted); margin-top: 6px; }
.account-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); align-items: center; font-size: 0.82rem; color: var(--muted); }

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  translate: -50% 20px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--panel-solid);
  border: 1px solid var(--cyan);
  box-shadow: 0 0 20px rgba(54, 231, 255, 0.4);
  opacity: 0;
  transition: opacity 0.25s, translate 0.25s;
  pointer-events: none;
  z-index: 60;
}
.toast.show { opacity: 1; translate: -50% 0; }

/* overlays (paywall, refill) */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(5, 2, 12, 0.72);
  backdrop-filter: blur(10px);
}
.overlay[hidden] { display: none; }
.overlay .card { width: min(480px, 100%); text-align: center; padding: 34px 28px; }
.overlay h2 { font-family: var(--tube); font-weight: 400; font-size: 1.9rem; margin: 0 0 10px; text-shadow: 0 0 14px var(--pink); }
.overlay p { color: #cfc8f5; line-height: 1.55; margin: 0 0 22px; }
.overlay ul { text-align: left; color: #cfc8f5; line-height: 1.8; margin: 0 auto 24px; max-width: 32ch; padding-left: 1.2em; }
.overlay li::marker { content: "◆  "; color: var(--lime); }

.loading { min-height: 60vh; display: grid; place-items: center; color: var(--muted); font-family: var(--display); letter-spacing: 0.3em; text-transform: uppercase; }
.loading::before { content: ""; width: 46px; height: 46px; border-radius: 50%; border: 3px solid rgba(54, 231, 255, 0.2); border-top-color: var(--cyan); animation: spin 0.9s linear infinite; margin-bottom: 14px; }
.loading { grid-auto-flow: row; align-content: center; justify-items: center; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .play { grid-template-columns: 1fr; grid-template-areas: "wheel" "table" "stats"; }
  .wheel-panel { max-width: 440px; width: 100%; justify-self: center; }
}
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; text-align: left; }
  .hero-wheel { max-width: 340px; order: -1; }
  .features { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .board {
    grid-template-columns: 0.9fr 0.9fr repeat(3, minmax(0, 1.3fr));
    grid-template-rows: 44px repeat(12, 38px) 44px;
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
  }
  .cell { grid-column: var(--mc); grid-row: var(--mr); }
  .cell.side span:not(.swatch) { writing-mode: vertical-rl; rotate: 180deg; }
  .chip { width: 46px; height: 46px; font-size: 0.85rem; }
  .spin-btn { width: 100%; }
  .controls { flex-direction: column-reverse; align-items: stretch; }
  .controls .group { justify-content: center; }
  .nav-links .who { display: none; }
  .stats-inline { width: 100%; justify-content: space-between; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
