/* WB FATAFAT — professional roulette (site greens & golds) */
@import url('https://fonts.googleapis.com/css2?family=Bungee&family=Oswald:wght@500;600;700&display=swap');

:root {
  --spin-bg: #071a22;
  --spin-ink: #0e2430;
  --spin-gold: #d4b45a;
  --spin-gold-bright: #efe0a8;
  --spin-gold-deep: #a8883a;
  --spin-orange: #e8a85a;
  --spin-blue: #3ec7e0;
  --spin-green: #2fe0a8;
  --spin-teal: #1ec8b0;
  --spin-cream: #e8f7fb;
  --spin-coral: #ff7eb6;
  --spin-burgundy: #6a3d8a;
  --spin-cyan: #5cefff;
  --spin-font-display: 'Bungee', 'Oswald', Impact, sans-serif;
  --spin-font-ui: 'Oswald', 'Trebuchet MS', sans-serif;
}

.live-wheel-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  opacity: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 20%, rgba(94, 239, 255, .18), transparent 38%),
    radial-gradient(circle at 15% 80%, rgba(47, 224, 168, .16), transparent 40%),
    radial-gradient(circle at 88% 70%, rgba(255, 126, 182, .1), transparent 36%),
    linear-gradient(180deg, #041018 0%, #0a2430 45%, #061820 100%);
  backdrop-filter: blur(12px) saturate(1.15);
  transition: opacity .28s;
  font-family: var(--spin-font-ui);
}
.live-wheel-overlay.show { opacity: 1; pointer-events: auto; }

.spin-sound-fab,
.spin-close-fab {
  position: absolute;
  z-index: 20;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(94, 239, 255, .45);
  cursor: pointer;
  opacity: .32;
  transition: opacity .2s, transform .2s, background .2s;
  backdrop-filter: blur(6px);
}
.spin-sound-fab { left: 14px; bottom: 16px; color: #c8fbff; background: rgba(6, 28, 38, .7); font-size: 18px; font-weight: 1000; }
.spin-close-fab { right: 14px; top: 14px; color: #e8fbff; background: rgba(6, 28, 38, .7); font-size: 22px; }
.spin-sound-fab:hover,
.spin-sound-fab:focus-visible,
.spin-close-fab:hover,
.spin-close-fab:focus-visible,
.spin-sound-fab.is-focused,
.live-wheel-overlay.is-demo .spin-sound-fab { opacity: .92; }
.spin-sound-fab.active {
  color: #041018;
  background: linear-gradient(145deg, #5cefff, #2fe0a8);
  opacity: .55;
}
.spin-sound-fab.active:hover,
.spin-sound-fab.active:focus-visible { opacity: 1; }

.live-panel {
  position: relative;
  width: min(520px, 100%);
  max-height: 96vh;
  overflow: auto;
  padding: 12px 12px 16px;
  border: 2px solid transparent;
  border-radius: 22px;
  color: #d7f6ff;
  background:
    linear-gradient(165deg, #0b2a36, #071e28 55%, #0a2430) padding-box,
    linear-gradient(135deg, #5cefff, #2fe0a8 40%, #d4b45a 70%, #5cefff) border-box;
  box-shadow:
    0 0 0 1px rgba(94, 239, 255, .22),
    0 0 48px rgba(47, 224, 168, .16),
    0 28px 70px rgba(0, 10, 18, .55);
  scrollbar-width: none;
}
.live-panel::-webkit-scrollbar { display: none; }

/* ★ SPIN & WIN ★ marquee title */
.spin-marquee {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  margin: 2px auto 10px;
  width: min(100%, 420px);
  min-height: 48px;
  padding: 10px 18px;
  border-radius: 14px;
  border: 2px solid rgba(94, 239, 255, .55);
  background: linear-gradient(180deg, #0e3a48, #071f28 55%, #0a3040);
  box-shadow:
    0 0 0 3px rgba(47, 224, 168, .18),
    inset 0 0 22px rgba(94, 239, 255, .12),
    0 8px 24px rgba(0, 20, 30, .4);
  overflow: hidden;
}
.spin-marquee-lights {
  position: absolute;
  inset: 4px;
  border-radius: 10px;
  pointer-events: none;
}
.spin-marquee-lights i {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fffbd4;
  box-shadow: 0 0 6px 2px #fff09a;
  animation: bulbTwinkle .7s ease-in-out infinite alternate;
}
.spin-marquee-title {
  position: relative;
  z-index: 1;
  margin: 0;
  font-family: var(--spin-font-display);
  font-size: clamp(18px, 5.2vw, 26px);
  font-weight: 400;
  letter-spacing: .08em;
  color: #fff;
  text-shadow:
    0 0 12px rgba(255, 226, 122, .65),
    0 2px 0 #b8860b,
    0 3px 8px rgba(0, 0, 0, .8);
  background: linear-gradient(180deg, #fff8df, #ffe27a 45%, #f0c14b);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.spin-marquee-title span {
  -webkit-text-fill-color: #ffe27a;
  color: #ffe27a;
  margin: 0 .2em;
}

.spin-chrome {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(94, 239, 255, .08);
  border: 1px solid rgba(94, 239, 255, .28);
  color: #d7f6ff;
}
.spin-chrome-slot { display: grid; gap: 2px; min-width: 0; }
.spin-chrome-slot small {
  color: #5cefff;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.spin-chrome-slot strong {
  font-size: clamp(13px, 3.6vw, 17px);
  font-weight: 700;
  letter-spacing: .02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #e8fbff;
}
.spin-chrome-stage {
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, #1ec8b0, #0e6a7a);
  border: 1px solid rgba(94, 239, 255, .55);
  color: #e8fbff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .12em;
  text-align: center;
  white-space: nowrap;
}

.live-panel.is-spinning .spin-chatter { display: none !important; }

/* ===== Prize wheel ===== */
.wheel-stage {
  --stage-size: min(78vw, 400px);
  --light-radius: calc(var(--stage-size) * .455);
  --number-radius: calc(var(--stage-size) * .295);
  position: relative;
  width: var(--stage-size);
  aspect-ratio: 1;
  margin: 4px auto 8px;
  filter: drop-shadow(0 0 28px rgba(240, 193, 75, .28));
  transform-style: preserve-3d;
  perspective: 900px;
}
.wheel-lights {
  position: absolute;
  z-index: 0;
  inset: 0;
  border: 3px solid #f0c14b;
  border-radius: 50%;
  background:
    radial-gradient(circle, transparent 54%, #ffb01a 55% 64%, #ffe27a 65% 72%, #8f360d 73%);
  box-shadow:
    0 0 22px rgba(255, 179, 29, .75),
    inset 0 0 24px #ffdb44,
    0 0 0 4px rgba(104, 40, 8, .85);
}
.wheel-lights i {
  position: absolute;
  top: 50%;
  left: 50%;
  width: clamp(7px, 2.4vw, 11px);
  height: clamp(7px, 2.4vw, 11px);
  margin: clamp(-5.5px, -1.2vw, -3.5px);
  transform: rotate(calc(var(--i) * 12deg)) translateY(calc(var(--light-radius) * -1));
  border: 1px solid #fff5c7;
  border-radius: 50%;
  background: #fffbd4;
  box-shadow: 0 0 7px 2px #fff09a;
  animation: bulbTwinkle .72s ease-in-out infinite alternate;
  animation-delay: calc(var(--i) * -35ms);
}
.wheel-stage.spinning .wheel-lights i { animation-duration: .28s; }
@keyframes bulbTwinkle { to { opacity: .42; filter: brightness(.7); } }

.wheel-gold-ring {
  position: absolute;
  z-index: 1;
  inset: 7.5%;
  border: 3px solid rgba(94, 239, 255, .7);
  border-radius: 50%;
  background: linear-gradient(145deg, #5cefff, #2fe0a8 42%, #d4b45a 64%, #0e6a7a);
  box-shadow: 0 0 0 3px rgba(4, 24, 36, .55), inset 0 0 14px rgba(232, 251, 255, .35);
}

.wheel-pointer {
  position: absolute;
  z-index: 8;
  top: 1.5%;
  left: 50%;
  width: 44px;
  height: 60px;
  transform: translateX(-50%);
  filter: drop-shadow(0 5px 6px rgba(0, 0, 0, .55));
  transform-origin: 50% 12%;
}
.wheel-pointer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 28px;
  height: 28px;
  transform: translateX(-50%);
  border: 3px solid #ffe56d;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, #fff7ad, #ff9a21 34%, #e63031 68%);
  box-shadow: 0 0 12px rgba(255, 154, 33, .7);
}
.wheel-pointer::after {
  content: "";
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  border-right: 16px solid transparent;
  border-left: 16px solid transparent;
  border-top: 32px solid #f13b38;
}
.wheel-pointer i {
  position: absolute;
  z-index: 1;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  border-right: 9px solid transparent;
  border-left: 9px solid transparent;
  border-top: 18px solid #ff9d21;
}
.wheel-stage.spinning .wheel-pointer { animation: pointerFlick .14s ease-in-out infinite alternate; }
.wheel-stage.pointer-land .wheel-pointer { animation: pointerLand .55s cubic-bezier(.2, .8, .2, 1); }
@keyframes pointerFlick { to { transform: translateX(-50%) rotate(-7deg); } }
@keyframes pointerLand {
  0% { transform: translateX(-50%) rotate(0); }
  35% { transform: translateX(-50%) rotate(-14deg); }
  65% { transform: translateX(-50%) rotate(8deg); }
  100% { transform: translateX(-50%) rotate(0); }
}

.wheel {
  position: absolute;
  z-index: 3;
  inset: 11.5%;
  overflow: hidden;
  border: 4px solid rgba(94, 239, 255, .75);
  border-radius: 50%;
  outline: 3px solid rgba(47, 224, 168, .35);
  /* Futuristic soft cyber palette */
  background: conic-gradient(
    from -18deg,
    #3ec7e0 0 36deg,
    #2fe0a8 36deg 72deg,
    #d4b45a 72deg 108deg,
    #ff7eb6 108deg 144deg,
    #7a6cff 144deg 180deg,
    #3ec7e0 180deg 216deg,
    #2fe0a8 216deg 252deg,
    #d4b45a 252deg 288deg,
    #ff7eb6 288deg 324deg,
    #7a6cff 324deg 360deg
  );
  box-shadow:
    inset 0 0 0 3px rgba(94, 239, 255, .45),
    inset 0 0 22px rgba(4, 20, 30, .25),
    0 0 32px rgba(94, 239, 255, .28);
  will-change: transform;
  transform: translateZ(0);
}
.wheel.spin-blur { filter: blur(.2px) saturate(1.12) brightness(1.06); }
.wheel > span {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  display: grid;
  width: clamp(28px, 7.2vw, 38px);
  height: clamp(28px, 7.2vw, 38px);
  margin: clamp(-19px, -3.6vw, -14px);
  place-items: center;
  transform: rotate(calc(var(--i) * 36deg)) translateY(calc(var(--number-radius) * -1)) rotate(calc(var(--i) * -36deg));
  border: 2px solid rgba(94, 239, 255, .55);
  border-radius: 50%;
  color: #041018;
  background: radial-gradient(circle at 35% 28%, #e8fbff, #9fefff 72%);
  font-family: var(--spin-font-ui);
  font-size: clamp(15px, 4.2vw, 23px);
  font-weight: 700;
  line-height: 1;
  text-shadow: none;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .35), 0 2px 8px rgba(0, 30, 40, .25);
  transition: transform .35s ease, box-shadow .35s ease, background .35s ease;
}
.wheel > span.is-winner {
  color: #041018;
  background: radial-gradient(circle at 35% 28%, #fff17c, #2fe0a8 70%);
  border-color: #efe0a8;
  box-shadow: 0 0 0 3px rgba(94, 239, 255, .75), 0 0 18px rgba(47, 224, 168, .65);
  transform: rotate(calc(var(--i) * 36deg)) translateY(calc(var(--number-radius) * -1)) rotate(calc(var(--i) * -36deg)) scale(1.12);
}

.wheel-center {
  position: absolute;
  z-index: 5;
  inset: 32%;
  display: grid;
  place-items: center;
  align-content: center;
  border: 4px solid rgba(94, 239, 255, .8);
  border-radius: 50%;
  color: #fff;
  background: radial-gradient(circle at 38% 28%, #2fe0a8, #0e6a7a 52%, #041820);
  text-align: center;
  box-shadow:
    0 0 0 3px rgba(47, 224, 168, .4),
    inset 0 0 16px rgba(255, 255, 255, .14),
    0 8px 18px rgba(0, 20, 30, .35);
  transition: background .45s, border-color .45s, box-shadow .45s;
  transform: translateZ(12px);
}
.wheel-center small {
  color: #ffe97d;
  font-size: clamp(6px, 1.5vw, 8px);
  font-weight: 700;
  letter-spacing: .1em;
}
.wheel-center b {
  margin-top: 1px;
  color: #fff;
  font-family: var(--spin-font-display);
  font-size: clamp(14px, 4.2vw, 22px);
  font-weight: 400;
  line-height: .95;
  letter-spacing: .04em;
  text-shadow: 0 2px 6px rgba(0, 0, 0, .55);
}
.wheel-center em {
  margin-top: 3px;
  color: #fff1ad;
  font-size: clamp(6px, 1.5vw, 8px);
  font-style: normal;
  font-weight: 700;
  letter-spacing: .14em;
}
.wheel-stage.spinning .wheel-center { animation: centerResultPulse .72s ease-in-out infinite alternate; }
@keyframes centerResultPulse {
  to { box-shadow: 0 0 0 5px #ffbd23, 0 0 32px #ff9c1e, inset 0 0 18px rgba(255, 255, 255, .34); }
}

.live-wheel-overlay.result-landed .wheel-center,
.live-panel.result-landed .wheel-center,
.wheel-stage.result-landed .wheel-center {
  border-color: var(--spin-gold-bright);
  background: radial-gradient(circle at 38% 28%, #4aab82, #1f5b49 55%, #143e34);
  box-shadow: 0 0 0 4px rgba(212, 180, 90, .55), 0 0 22px rgba(47, 138, 104, .4);
}
.live-wheel-overlay.result-landed .wheel-center b,
.live-panel.result-landed .wheel-center b,
.wheel-stage.result-landed .wheel-center b {
  background: linear-gradient(180deg, #fff, #efe0a8);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Mid result — colorful animated categories */
.stage-mid-panel {
  margin: 0 auto 10px;
  width: min(94%, 420px);
  padding: 14px 12px 12px;
  border-radius: 16px;
  border: 2px solid transparent;
  background:
    linear-gradient(160deg, #0b2a36, #071e28) padding-box,
    linear-gradient(135deg, #5cefff, #2fe0a8, #d4b45a, #5cefff) border-box;
  text-align: center;
  color: #d7f6ff;
  box-shadow: 0 0 28px rgba(94, 239, 255, .14);
  animation: midPanelIn .55s cubic-bezier(.2, .85, .2, 1) both;
}
.stage-mid-panel[hidden] { display: none !important; }
.stage-mid-panel.is-visible { display: block; }
@keyframes midPanelIn {
  from { opacity: 0; transform: translateY(16px) scale(.94); }
  to { opacity: 1; transform: none; }
}
.stage-mid-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}
.stage-mid-number {
  font-family: var(--spin-font-display);
  font-size: clamp(36px, 12vw, 56px);
  font-weight: 400;
  line-height: 1;
  background: linear-gradient(180deg, #e8fbff, #5cefff 40%, #2fe0a8);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 8px rgba(94, 239, 255, .35));
  animation: popNumber .7s cubic-bezier(.2, .9, .2, 1) both;
}
@keyframes popNumber {
  0% { transform: scale(.4) rotate(-8deg); opacity: 0; }
  60% { transform: scale(1.12); }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes colorShift {
  to { filter: drop-shadow(0 2px 14px rgba(255, 79, 216, .5)) hue-rotate(18deg); }
}
.stage-mid-cats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}
.stage-mid-cats em {
  min-width: 72px;
  padding: 8px 12px;
  border-radius: 10px;
  font-style: normal;
  font-family: var(--spin-font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  color: #fff;
  border: 2px solid transparent;
  animation: catBounce .65s cubic-bezier(.2, .9, .2, 1) both;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .45);
}
.stage-mid-cats em:nth-child(2) { animation-delay: .12s; }
.stage-mid-cats em.is-even {
  background: linear-gradient(145deg, #6bb8c4, #4a9aaa);
  border-color: #a8d5dc;
  box-shadow: 0 0 12px rgba(74, 154, 170, .35);
}
.stage-mid-cats em.is-odd {
  background: linear-gradient(145deg, #e898a8, #d97878);
  border-color: #f0c0c8;
  box-shadow: 0 0 12px rgba(217, 120, 120, .3);
}
.stage-mid-cats em.is-small {
  background: linear-gradient(145deg, #5cbc92, #2f8a68);
  border-color: #a8dcc4;
  box-shadow: 0 0 12px rgba(47, 138, 104, .3);
}
.stage-mid-cats em.is-big {
  background: linear-gradient(145deg, #e0b86a, #c9a34a);
  border-color: #efe0a8;
  box-shadow: 0 0 12px rgba(201, 163, 74, .3);
}
@keyframes catBounce {
  0% { opacity: 0; transform: translateY(18px) scale(.7); }
  70% { transform: translateY(-4px) scale(1.06); }
  100% { opacity: 1; transform: none; }
}
.next-spin-countdown {
  margin-top: 12px;
  padding: 9px 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, .45);
  border: 1px solid rgba(240, 193, 75, .4);
  color: #fff8df;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .04em;
}
.next-spin-countdown b {
  color: var(--spin-gold-bright);
  font-size: 1.25em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 10px rgba(255, 226, 122, .55);
}

/* ===== Leaf reel — centered “Leaf number XXX”, colorful, no left counters ===== */
.leaf-reel-stage {
  position: relative;
  width: min(94%, 420px);
  margin: 6px auto 10px;
}
.leaf-reel-stage[hidden] { display: none !important; }
.leaf-reel-frame {
  position: relative;
  padding: 14px 12px;
  border-radius: 18px;
  border: 2px solid transparent;
  background:
    linear-gradient(180deg, #0b2a36, #071e28 40%, #0a2430) padding-box,
    linear-gradient(135deg, #5cefff, #2fe0a8, #d4b45a, #5cefff) border-box;
  box-shadow: inset 0 0 30px rgba(0, 20, 30, .35), 0 0 28px rgba(94, 239, 255, .18);
}
.leaf-reel-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  color: #9fefff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .14em;
}
.leaf-reel-window {
  --chip-h: 56px;
  --window-h: calc(var(--chip-h) * 5);
  position: relative;
  height: var(--window-h);
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(94, 239, 255, .4);
  background: linear-gradient(180deg, #041018, #0a2430 50%, #041018);
  box-shadow: inset 0 0 24px rgba(0, 0, 0, .45);
}
.leaf-reel-window::before,
.leaf-reel-window::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  z-index: 4;
  height: 28%;
  pointer-events: none;
}
.leaf-reel-window::before {
  top: 0;
  background: linear-gradient(180deg, rgba(4, 16, 24, .95), transparent);
}
.leaf-reel-window::after {
  bottom: 0;
  background: linear-gradient(0deg, rgba(4, 16, 24, .95), transparent);
}
.leaf-reel-center-line {
  position: absolute;
  z-index: 5;
  left: 6px;
  right: 6px;
  top: 50%;
  height: var(--chip-h);
  margin-top: calc(var(--chip-h) / -2);
  border: 2px solid rgba(94, 239, 255, .55);
  border-radius: 10px;
  box-shadow: 0 0 12px rgba(94, 239, 255, .25), inset 0 0 10px rgba(47, 224, 168, .1);
  pointer-events: none;
  transition: border-color .3s, box-shadow .3s;
}
.leaf-reel-strip {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  will-change: transform;
}
.leaf-chip {
  display: grid;
  place-items: center;
  height: var(--chip-h);
  padding: 0 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  color: #fff;
  font-weight: 700;
  text-align: center;
}
.leaf-chip-mid {
  display: grid;
  gap: 1px;
  justify-items: center;
  line-height: 1.05;
}
.leaf-chip-mid em {
  font-style: normal;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: .9;
}
.leaf-chip-mid b {
  font-size: clamp(18px, 5.2vw, 26px);
  font-weight: 800;
  letter-spacing: .06em;
  font-variant-numeric: tabular-nums;
  transition: color .25s, text-shadow .25s;
}

/* Each leaf row a different soft futuristic color */
.leaf-chip.leaf-tone-0 { background: linear-gradient(90deg, rgba(62, 199, 224, .35), rgba(62, 199, 224, .12)); }
.leaf-chip.leaf-tone-1 { background: linear-gradient(90deg, rgba(47, 224, 168, .35), rgba(47, 224, 168, .12)); }
.leaf-chip.leaf-tone-2 { background: linear-gradient(90deg, rgba(212, 180, 90, .38), rgba(212, 180, 90, .12)); }
.leaf-chip.leaf-tone-3 { background: linear-gradient(90deg, rgba(255, 126, 182, .32), rgba(255, 126, 182, .1)); }
.leaf-chip.leaf-tone-4 { background: linear-gradient(90deg, rgba(122, 108, 255, .35), rgba(122, 108, 255, .12)); }
.leaf-chip.leaf-tone-5 { background: linear-gradient(90deg, rgba(255, 159, 67, .35), rgba(255, 159, 67, .12)); }
.leaf-chip.leaf-tone-6 { background: linear-gradient(90deg, rgba(92, 239, 255, .32), rgba(92, 239, 255, .1)); }
.leaf-chip.leaf-tone-7 { background: linear-gradient(90deg, rgba(129, 236, 160, .35), rgba(129, 236, 160, .12)); }
.leaf-chip.leaf-tone-8 { background: linear-gradient(90deg, rgba(250, 177, 160, .35), rgba(250, 177, 160, .12)); }
.leaf-chip.leaf-tone-9 { background: linear-gradient(90deg, rgba(116, 185, 255, .35), rgba(116, 185, 255, .12)); }
.leaf-chip.leaf-tone-10 { background: linear-gradient(90deg, rgba(162, 155, 254, .35), rgba(162, 155, 254, .12)); }
.leaf-chip.leaf-tone-11 { background: linear-gradient(90deg, rgba(255, 234, 167, .35), rgba(255, 234, 167, .12)); }

/* Winner only after reel fully stops */
.leaf-chip.is-winner {
  background: linear-gradient(90deg, rgba(47, 224, 168, .55), rgba(94, 239, 255, .35)) !important;
  box-shadow: inset 0 0 0 1px rgba(94, 239, 255, .7);
  animation: winnerFlash .6s ease both;
}
.leaf-chip.is-winner .leaf-chip-mid b {
  color: #fff8c8;
  text-shadow: 0 0 14px rgba(255, 226, 122, .75);
}
.leaf-chip.is-winner .leaf-chip-mid em { color: #e8fbff; }
@keyframes winnerFlash {
  0% { filter: brightness(1.6); }
  100% { filter: none; }
}
.leaf-reel-stage.spinning .leaf-reel-strip { filter: blur(.3px); }
.leaf-reel-stage.spinning .leaf-reel-center-line {
  border-color: rgba(94, 239, 255, .3);
  box-shadow: none;
}
.leaf-reel-stage.pointer-land .leaf-reel-center-line {
  border-color: #5cefff;
  animation: reelLock .5s ease;
}
@keyframes reelLock {
  0%, 100% { box-shadow: 0 0 16px rgba(94, 239, 255, .35); }
  40% { box-shadow: 0 0 28px rgba(47, 224, 168, .75); transform: scaleX(1.02); }
}

/* Finale burst + bomb */
.finale-burst {
  position: absolute;
  inset: 0;
  z-index: 15;
  pointer-events: none;
  overflow: hidden;
  opacity: 0;
}
.finale-burst.show { opacity: 1; animation: burstFlash .9s ease both; }
@keyframes burstFlash {
  0% { opacity: 0; }
  15% { opacity: 1; }
  100% { opacity: 1; }
}
.finale-burst i {
  position: absolute;
  top: 45%;
  left: 50%;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--spin-gold-bright);
  opacity: 0;
}
.finale-burst.show i {
  animation: confettiBurst 1.15s cubic-bezier(.15, .75, .25, 1) forwards;
  animation-delay: calc(var(--i) * 18ms);
}
@keyframes confettiBurst {
  0% { opacity: 1; transform: translate(-50%, -50%) scale(.4) rotate(0); }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(1) rotate(var(--rot));
  }
}
.finale-bomb {
  position: absolute;
  z-index: 16;
  top: 42%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff8df, var(--spin-gold) 45%, var(--spin-burgundy));
  opacity: 0;
  pointer-events: none;
}
.finale-bomb.show { animation: bombPop .7s cubic-bezier(.2, .9, .2, 1) both; }
@keyframes bombPop {
  0% { opacity: 1; transform: scale(.2); box-shadow: 0 0 0 0 rgba(240, 193, 75, .6); }
  45% { opacity: 1; transform: scale(3.2); box-shadow: 0 0 0 40px rgba(240, 193, 75, 0); }
  100% { opacity: 0; transform: scale(4.5); }
}

/* Result card — photo-matched congratulations box */
.reveal-card {
  position: relative;
  z-index: 2;
  overflow: hidden;
  max-height: 0;
  padding: 0 12px;
  opacity: 0;
  transform: translateY(18px) scale(.94);
  border: 0 solid transparent;
  border-radius: 18px;
  background:
    linear-gradient(160deg, #1a1008, #120a12 55%, #1a0810) padding-box,
    linear-gradient(135deg, #ffe27a, #b8860b, #ffe27a) border-box;
  text-align: center;
  transition: opacity .45s, transform .45s, max-height .55s, padding .35s, border-width .2s;
}
.reveal-card.show {
  max-height: 560px;
  padding: 18px 14px 16px;
  opacity: 1;
  transform: none;
  border-width: 2px;
  box-shadow: 0 0 36px rgba(240, 193, 75, .35);
  animation: revealGlow 2.2s ease-in-out infinite alternate;
}
@keyframes revealGlow {
  to { box-shadow: 0 0 48px rgba(255, 138, 31, .4), 0 0 20px rgba(240, 193, 75, .3); }
}
.reveal-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 auto 8px;
  padding: 5px 14px;
  border-radius: 999px;
  border: 1px solid rgba(240, 193, 75, .65);
  background: linear-gradient(135deg, #5a2a10, #2a1408);
  color: #fff8df;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  animation: badgePulse 1.4s ease-in-out infinite alternate;
}
@keyframes badgePulse {
  to { box-shadow: 0 0 14px rgba(240, 193, 75, .45); transform: scale(1.03); }
}
.reveal-card > span.reveal-kicker {
  display: block;
  color: var(--spin-gold-bright);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .14em;
}
.reveal-card h3 {
  margin: 6px 0 4px;
  font-family: var(--spin-font-display);
  font-size: clamp(22px, 6vw, 32px);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: .04em;
  background: linear-gradient(180deg, #fff8df, #ffe27a 50%, #f0c14b);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, .45));
  animation: titleShine 2s ease-in-out infinite alternate;
}
@keyframes titleShine {
  to { filter: drop-shadow(0 2px 14px rgba(255, 226, 122, .55)) brightness(1.08); }
}
.reveal-card > small {
  color: var(--spin-cyan);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  animation: cyanGlow 1.6s ease-in-out infinite alternate;
}
@keyframes cyanGlow {
  to { text-shadow: 0 0 12px rgba(92, 225, 255, .7); }
}
.reveal-equation {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 10px 0 6px;
}
.reveal-equation strong,
.reveal-equation b {
  font-family: var(--spin-font-display);
  font-size: clamp(30px, 9vw, 48px);
  font-weight: 400;
  line-height: 1;
}
.reveal-equation strong {
  background: linear-gradient(180deg, #fff, #ffe27a, #ff8a1f);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: popNumber .8s cubic-bezier(.2, .9, .2, 1) both;
}
.reveal-equation b {
  background: linear-gradient(180deg, #fff, #5ce1ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: popNumber .8s .1s cubic-bezier(.2, .9, .2, 1) both;
}
.reveal-equation i {
  color: #e8c56a;
  font-size: 22px;
  font-style: normal;
  font-weight: 700;
}
.reveal-number-stack { display: grid; gap: 4px; justify-items: center; }
.reveal-number-stack small {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  padding: 3px 10px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(90deg, #1e6bff, #8b2dff, #e31b23);
  animation: catBounce .7s .15s both;
}
.reveal-card p {
  margin: 0;
  color: #ffe8b0;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .04em;
}

.finale-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 14px 0 10px;
}
.finale-meta span {
  display: grid;
  gap: 3px;
  padding: 10px 8px;
  border-radius: 12px;
  background: rgba(0, 0, 0, .4);
  border: 1px solid rgba(240, 193, 75, .28);
  text-align: center;
  animation: catBounce .6s both;
}
.finale-meta span:nth-child(1) { animation-delay: .05s; border-color: rgba(255, 138, 31, .55); }
.finale-meta span:nth-child(2) { animation-delay: .12s; border-color: rgba(92, 225, 255, .45); }
.finale-meta span:nth-child(3) { animation-delay: .18s; }
.finale-meta span:nth-child(4) { animation-delay: .24s; }
.finale-meta small {
  color: var(--spin-gold-bright);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .12em;
}
.finale-meta b {
  font-family: var(--spin-font-ui);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .04em;
}
.finale-meta .meta-number b {
  background: linear-gradient(180deg, #fff8df, #ff8a1f);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 22px;
}
.finale-meta .meta-patti b {
  background: linear-gradient(180deg, #fff, #5ce1ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.finale-meta .meta-parity b.is-even { color: #5ce1ff; text-shadow: 0 0 10px rgba(92, 225, 255, .55); }
.finale-meta .meta-parity b.is-odd { color: #ff4fd8; text-shadow: 0 0 10px rgba(255, 79, 216, .55); }
.finale-meta .meta-size b.is-small { color: #3dff8a; text-shadow: 0 0 10px rgba(61, 255, 138, .5); }
.finale-meta .meta-size b.is-big { color: #ff8a1f; text-shadow: 0 0 10px rgba(255, 138, 31, .5); }

.reveal-footer {
  margin-top: 4px;
  color: rgba(255, 232, 176, .75);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .1em;
}

.wheel-stage.spinning { animation: stageEnergy 1.35s ease-in-out infinite; }
@keyframes stageEnergy { 50% { filter: drop-shadow(0 0 18px rgba(240, 193, 75, .5)); } }

.live-wheel-overlay.is-demo::before {
  content: "DEMO / TEST · DOES NOT AFFECT LIVE RESULTS";
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 25;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--spin-burgundy);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .06em;
  max-width: calc(100% - 100px);
  text-align: center;
}

.wheel-stage.is-parked {
  --stage-size: min(48vw, 200px);
  margin-bottom: 4px;
  opacity: .9;
}
.wheel-stage.is-parked .wheel-pointer { transform: translateX(-50%) scale(.8); }

@media (max-width: 520px) {
  .spin-sound-fab { left: 10px; bottom: 12px; width: 38px; height: 38px; }
  .spin-close-fab { right: 10px; top: 10px; width: 38px; height: 38px; }
  .leaf-reel-window { --chip-h: 52px; }
  .leaf-chip { padding: 0 10px; }
  .spin-marquee { min-height: 44px; padding: 8px 14px; }
  .live-wheel-overlay.is-demo::before {
    font-size: 8px;
    top: 8px;
    max-width: calc(100% - 88px);
  }
}
