
/* ===== was intro.css ===== */
/* ---------- Game intro (public/js/fx/intro.js) ---------- */
.gi {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: radial-gradient(circle at 50% 45%, color-mix(in srgb, var(--gi) 28%, #0b1020) 0%, #05070f 70%);
  cursor: pointer;
  animation: gi-in 0.25s ease-out;
}
.gi.gi-out {
  pointer-events: none;
  animation: gi-zoom 0.6s cubic-bezier(0.6, 0, 0.9, 0.5) forwards;
}
@keyframes gi-in {
  from {
    opacity: 0;
  }
}
@keyframes gi-zoom {
  to {
    transform: scale(6);
    opacity: 0;
    filter: blur(6px);
  }
}
#view.gi-wait {
  opacity: 0;
}
#view.gi-enter {
  animation: gi-view 0.6s cubic-bezier(0.2, 0.8, 0.3, 1);
}
@keyframes gi-view {
  from {
    transform: scale(0.82);
    opacity: 0;
    filter: blur(10px);
  }
}
.gi-stage {
  position: relative;
  width: min(300px, 70vw);
  aspect-ratio: 1;
}
.gi-stage::after {
  content: "";
  position: absolute;
  inset: -30%;
  border-radius: 50%;
  background: radial-gradient(circle, #fff 0%, var(--gi) 30%, transparent 65%);
  opacity: 0;
  animation: gi-flash 0.5s ease-out var(--at) forwards;
  pointer-events: none;
}
@keyframes gi-flash {
  0% {
    opacity: 0.95;
    transform: scale(0.4);
  }
  100% {
    opacity: 0;
    transform: scale(1.3);
  }
}
.gi-scene svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.55));
}
.gi-scene svg * {
  transform-box: fill-box;
  transform-origin: center;
}
.gi-sparks {
  position: absolute;
  left: 50%;
  top: 50%;
}
.gi-spark {
  position: absolute;
  width: 12px;
  height: 12px;
  margin: -6px;
  border-radius: 3px;
  background: var(--gi);
  box-shadow: 0 0 12px var(--gi);
  opacity: 0;
  animation: gi-spark 0.7s ease-out var(--at) forwards;
}
@keyframes gi-spark {
  0% {
    opacity: 1;
    transform: rotate(var(--a)) translateX(0) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: rotate(var(--a)) translateX(calc(var(--d) * 2)) scale(0.2);
  }
}
.gi-name {
  font-family: var(--font-display, inherit);
  font-size: clamp(30px, 6vw, 54px);
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 0 24px var(--gi), 0 4px 0 rgba(0, 0, 0, 0.5);
  z-index: 1;
}
.gi-name span {
  display: inline-block;
  animation: gi-name 0.5s cubic-bezier(0.2, 1.6, 0.4, 1) calc(0.15s + var(--i) * 0.05s) backwards, gi-letter 0.4s ease-out calc(var(--at) + var(--i) * 0.03s);
}
@keyframes gi-letter {
  40% {
    transform: translateY(-14px) scale(1.15);
    color: var(--gi);
  }
}
@keyframes gi-name {
  from {
    opacity: 0;
    transform: translateY(-80px) rotate(-20deg) scale(0.4);
  }
}
/* shared bits */
.gi .s-pop {
  animation: s-pop 0.45s cubic-bezier(0.2, 1.6, 0.4, 1) calc(var(--at) - 200ms) backwards;
}
@keyframes s-pop {
  from {
    opacity: 0;
    transform: scale(0);
  }
}
.gi .s-boom {
  opacity: 0;
  animation: s-boom 0.55s ease-out calc(var(--at) - 50ms) forwards;
}
@keyframes s-boom {
  0% {
    opacity: 1;
    transform: scale(0.1);
  }
  100% {
    opacity: 0;
    transform: scale(2.4);
  }
}
/* crash: rocket climbs, then blows up */
.gi .s-rise {
  animation: s-rise 0.95s cubic-bezier(0.5, 0, 0.9, 0.6) forwards;
}
@keyframes s-rise {
  0% {
    transform: translateY(100px);
  }
  94% {
    opacity: 1;
    transform: translateY(-30px) rotate(3deg);
  }
  100% {
    opacity: 0;
    transform: translateY(-36px);
  }
}
.gi .s-flame {
  transform-origin: top;
  animation: s-flicker 0.08s linear infinite alternate;
}
@keyframes s-flicker {
  to {
    transform: scaleY(1.5) scaleX(0.8);
  }
}
/* roulette */
.gi .s-spin {
  animation: s-spin 1.05s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}
@keyframes s-spin {
  to {
    transform: rotate(1080deg);
  }
}
.gi .s-orbit {
  transform-box: view-box;
  transform-origin: 120px 120px;
  animation: s-orbit 1.05s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}
@keyframes s-orbit {
  to {
    transform: rotate(-1470deg) scale(0.86);
  }
}
/* mines */
.gi .s-tile {
  animation: s-pop 0.3s ease-out calc(var(--i) * 45ms) backwards;
}
.gi .s-gem {
  animation: s-pop 0.3s cubic-bezier(0.2, 1.6, 0.4, 1) 0.45s backwards;
}
.gi .s-gem.g2 {
  animation-delay: 0.65s;
}
.gi .s-bomb {
  animation: s-pop 0.25s ease-out 0.82s backwards;
}
/* blackjack */
.gi .s-deal {
  animation: s-deal 0.45s cubic-bezier(0.2, 0.9, 0.3, 1) calc(0.1s + var(--i) * 0.28s) backwards;
}
@keyframes s-deal {
  from {
    opacity: 0;
    transform: translate(160px, -220px) rotate(-120deg);
  }
}
/* upgrader */
.gi .s-fill {
  animation: s-fill 1s ease-in forwards;
}
@keyframes s-fill {
  to {
    stroke-dashoffset: 0;
  }
}
.gi .s-up {
  animation: s-up 0.4s ease-out 1s;
}
@keyframes s-up {
  50% {
    transform: translateY(-24px) scale(1.2);
  }
}
/* slide */
.gi .s-strip {
  animation: s-strip 1.1s cubic-bezier(0.15, 0.8, 0.3, 1) forwards;
}
@keyframes s-strip {
  from {
    transform: translateX(160px);
  }
  to {
    transform: translateX(-104px);
  }
}
/* limbo */
.gi .s-bar {
  transform-origin: bottom;
  animation: s-bar 1s cubic-bezier(0.5, 0, 0.8, 0.4) both;
}
@keyframes s-bar {
  from {
    transform: scaleY(0.02);
  }
}
/* tower */
.gi .s-stack {
  animation: s-drop 0.32s cubic-bezier(0.5, 0, 0.8, 1.3) calc(var(--i) * 0.17s) backwards;
}
@keyframes s-drop {
  from {
    opacity: 0;
    transform: translateY(-220px);
  }
}
/* battles: swords clash */
.gi .s-swl {
  animation: s-swl 0.75s cubic-bezier(0.6, 0, 0.9, 1) backwards;
}
.gi .s-swr {
  animation: s-swr 0.75s cubic-bezier(0.6, 0, 0.9, 1) backwards;
}
@keyframes s-swl {
  from {
    transform: translate(-160px, 120px) rotate(-40deg);
  }
}
@keyframes s-swr {
  from {
    transform: translate(160px, 120px) rotate(40deg);
  }
}
/* chicken: hops across the lanes */
.gi .s-hop {
  animation: s-hop 1.15s linear forwards;
}
@keyframes s-hop {
  0% {
    transform: translate(0, 0);
  }
  12% {
    transform: translate(26px, -36px);
  }
  25% {
    transform: translate(52px, 0);
  }
  37% {
    transform: translate(78px, -36px);
  }
  50% {
    transform: translate(104px, 0);
  }
  62% {
    transform: translate(130px, -36px);
  }
  75%,
  100% {
    transform: translate(156px, 0);
  }
}
/* cases: chest shakes and bursts open */
.gi .s-shake {
  animation: s-shake 0.12s linear 6;
}
@keyframes s-shake {
  25% {
    transform: rotate(-4deg);
  }
  75% {
    transform: rotate(4deg);
  }
}
.gi .s-lid {
  animation: s-lid 0.4s cubic-bezier(0.2, 1.5, 0.4, 1) 0.95s forwards;
}
@keyframes s-lid {
  to {
    transform: translate(-14px, -46px) rotate(-28deg);
  }
}
.gi .s-rays {
  opacity: 0;
  transform-box: view-box;
  transform-origin: 120px 110px;
  animation: s-rays 1.2s linear 0.95s forwards;
}
@keyframes s-rays {
  15% {
    opacity: 0.9;
  }
  to {
    opacity: 0.6;
    transform: rotate(60deg);
  }
}
/* dice */
.gi .s-roll {
  animation: s-roll 0.95s cubic-bezier(0.2, 0.8, 0.3, 1.15) backwards;
}
.gi .s-roll.r2 {
  animation-name: s-roll2;
  animation-delay: 0.08s;
}
@keyframes s-roll {
  from {
    transform: translate(-170px, -140px) rotate(-720deg);
  }
}
@keyframes s-roll2 {
  from {
    transform: translate(170px, -170px) rotate(800deg);
  }
}
/* coinflip */
.gi .s-flip {
  animation: s-flip 1.05s ease-in-out;
}
@keyframes s-flip {
  15% {
    transform: translateY(-50px) scaleY(-1);
  }
  30% {
    transform: translateY(-80px) scaleY(1);
  }
  45% {
    transform: translateY(-90px) scaleY(-1);
  }
  60% {
    transform: translateY(-70px) scaleY(1);
  }
  75% {
    transform: translateY(-30px) scaleY(-1);
  }
}
/* plinko */
.gi .s-drop {
  animation: s-drop-ball 1.15s ease-in forwards;
}
@keyframes s-drop-ball {
  20% {
    transform: translate(-16px, 45px);
  }
  40% {
    transform: translate(0, 75px);
  }
  60% {
    transform: translate(16px, 105px);
  }
  80% {
    transform: translate(32px, 140px);
  }
  100% {
    transform: translate(16px, 182px);
  }
}
/* keno */
.gi .s-ball {
  animation: s-pop 0.3s cubic-bezier(0.2, 1.6, 0.4, 1) calc(var(--i) * 55ms) backwards;
}
/* hilo */
.gi .s-turn {
  animation: s-turn 0.5s ease-in-out 0.35s 2;
}
@keyframes s-turn {
  50% {
    transform: scaleX(0);
  }
}
.gi .s-arrow {
  animation: s-arrow 0.35s ease-in-out infinite alternate;
}
.gi .s-arrow.a2 {
  animation-direction: alternate-reverse;
}
@keyframes s-arrow {
  to {
    transform: translateY(-10px);
  }
}
/* uno: cards fan out */
.gi .s-fan {
  transform-box: view-box;
  transform-origin: 120px 220px;
  animation: s-fan 0.5s cubic-bezier(0.2, 1.3, 0.4, 1) calc(0.2s + var(--i) * 0.12s) both;
}
@keyframes s-fan {
  from {
    transform: translateY(80px);
  }
  to {
    transform: rotate(calc((var(--i) - 1.5) * 24deg));
  }
}
/* slots: lever pull, reels land one by one */
.gi .s-lever {
  animation: s-lever 0.4s ease-in-out;
}
@keyframes s-lever {
  50% {
    transform: translateY(60px);
  }
}
.gi .s-reel {
  animation: s-reel calc(0.6s + var(--i) * 0.25s) cubic-bezier(0.2, 0.7, 0.3, 1.2) 0.2s backwards;
}
@keyframes s-reel {
  from {
    transform: translateY(-900px);
    filter: blur(3px);
  }
}

/* ---------- Home: faint blocky landscape behind the page ---------- */
.home-land {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 70vh;
  z-index: 0;
  pointer-events: none;
  opacity: 0.3;
  -webkit-mask-image: linear-gradient(to top, #000 30%, transparent);
  mask-image: linear-gradient(to top, #000 30%, transparent);
}
.home-land svg {
  width: 100%;
  height: 100%;
}
.home-land ~ * {
  position: relative;
  z-index: 1;
}

/* ---------- Chat cards: big wins and new lobbies ---------- */
.chat-card {
  --cc: #f2c44a;
  flex: none;
  position: relative;
  overflow: hidden;
  margin: 6px 0;
  border: 1px solid color-mix(in srgb, var(--cc) 55%, transparent);
  border-radius: 14px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--cc) 22%, transparent), transparent 70%), var(--surface-1, #151a26);
  box-shadow: 0 0 18px color-mix(in srgb, var(--cc) 25%, transparent);
  animation: cc-in 0.5s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.chat-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.22) 50%, transparent 65%);
  transform: translateX(-100%);
  animation: cc-shine 2.6s ease-in-out 0.4s 2;
  pointer-events: none;
}
@keyframes cc-in {
  from {
    opacity: 0;
    transform: translateX(-30px) scale(0.9);
  }
}
@keyframes cc-shine {
  to {
    transform: translateX(100%);
  }
}
.win-card.mega {
  --cc: #ef5b6b;
}
.win-card.epic {
  --cc: #b388ff;
  animation: cc-in 0.5s cubic-bezier(0.2, 1.4, 0.4, 1), cc-pulse 1.6s ease-in-out 0.5s 4;
}
@keyframes cc-pulse {
  50% {
    box-shadow: 0 0 34px color-mix(in srgb, var(--cc) 70%, transparent);
  }
}
.lobby-card.battle {
  --cc: #a855f7;
}
.lobby-card.uno {
  --cc: #22c55e;
}
.cc-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: color-mix(in srgb, var(--cc) 30%, transparent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  color: #fff;
}
.cc-strip .icon {
  width: 14px;
  height: 14px;
  color: var(--cc);
}
.cc-mult,
.cc-live {
  margin-left: auto;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--cc);
  color: #111;
}
.cc-live {
  animation: cc-blink 1s steps(2) infinite;
}
@keyframes cc-blink {
  50% {
    opacity: 0.45;
  }
}
.cc-body {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
}
.cc-thumb {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  overflow: hidden;
}
.cc-thumb svg {
  width: 100%;
  height: 100%;
}
.cc-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 1px;
  flex: 1;
}
.cc-who {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
}
.cc-amount {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 18px;
  font-weight: 900;
  color: var(--cc);
  text-shadow: 0 0 12px color-mix(in srgb, var(--cc) 60%, transparent);
}
.cc-amount svg {
  width: 16px;
  height: 16px;
}
.cc-sub {
  font-size: 11px;
  color: var(--text-dim, #9aa3b2);
}
.cc-join {
  flex: none;
  padding: 6px 12px;
  font-size: 12px;
  background: var(--cc);
  color: #111;
}

/* ---------- Events page ---------- */
.event-card {
  position: relative;
  overflow: hidden;
  --ev: #f2c44a;
}
.event-card.xp_boost,
.ev-row.xp_boost,
.ev-help-card.xp_boost {
  --ev: #38bdf8;
}
.event-card.rain_boost,
.ev-row.rain_boost,
.ev-help-card.rain_boost {
  --ev: #22c55e;
}
.event-card.mission,
.ev-row.mission,
.ev-help-card.mission {
  --ev: #f2c44a;
}
.event-card.live {
  border-color: var(--ev);
  background: linear-gradient(135deg, color-mix(in srgb, var(--ev) 20%, transparent), transparent 60%), var(--surface-1, #151a26);
  box-shadow: 0 0 30px color-mix(in srgb, var(--ev) 25%, transparent);
}
.event-card .event-timer {
  font-size: 1.4em;
  color: var(--ev);
}
.ev-bg-ico {
  position: absolute;
  right: -20px;
  top: -20px;
  width: 140px;
  height: 140px;
  opacity: 0.08;
  color: var(--ev);
  pointer-events: none;
}
.ev-bg-ico svg {
  width: 100%;
  height: 100%;
}
.ev-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 10px #ef4444;
  animation: cc-blink 1s steps(2) infinite;
}
.ev-list {
  display: flex;
  flex-direction: column;
  padding: 6px;
}
.ev-row {
  display: grid;
  grid-template-columns: 64px 36px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border-left: 3px solid var(--ev);
}
.ev-row + .ev-row {
  margin-top: 4px;
}
.ev-row:hover {
  background: color-mix(in srgb, var(--ev) 8%, transparent);
}
.ev-when {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.ev-when span,
.ev-count span {
  font-size: 12px;
}
.ev-ico {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--ev) 18%, transparent);
  color: var(--ev);
}
.ev-ico svg {
  width: 20px;
  height: 20px;
}
.ev-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.ev-main span {
  font-size: 13px;
}
.ev-count {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.ev-count b {
  color: var(--ev);
  font-variant-numeric: tabular-nums;
}
.ev-help {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
.ev-help-card {
  display: flex;
  gap: 12px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--ev) 35%, transparent);
  background: color-mix(in srgb, var(--ev) 7%, var(--surface-1, #151a26));
}
.ev-help-card p {
  margin: 2px 0 0;
  font-size: 13px;
}
@media (max-width: 600px) {
  .ev-row {
    grid-template-columns: 52px 1fr;
  }
  .ev-row .ev-ico {
    display: none;
  }
  .ev-count {
    grid-column: 2;
    align-items: flex-start;
  }
}

/* ---------- Intro extras: warp streaks, shock waves, shake, spark shapes ---------- */
.gi-stage {
  animation: gi-shake 0.45s ease-out var(--at);
}
@keyframes gi-shake {
  15% {
    transform: translate(-9px, 5px) rotate(-1.5deg);
  }
  30% {
    transform: translate(8px, -6px) rotate(1.5deg);
  }
  45% {
    transform: translate(-6px, -3px);
  }
  60% {
    transform: translate(4px, 4px);
  }
  80% {
    transform: translate(-2px, 1px);
  }
}
.gi-warp {
  position: absolute;
  left: 50%;
  top: 45%;
  pointer-events: none;
}
.gi-warp i {
  position: absolute;
  width: 3px;
  height: 60px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: linear-gradient(to bottom, transparent, var(--gi), #fff);
  opacity: 0;
  transform-origin: 50% 0;
  animation: gi-warp 0.8s linear var(--t) infinite;
}
@keyframes gi-warp {
  0% {
    opacity: 0;
    transform: rotate(var(--a)) translateY(40px) scaleY(0.2);
  }
  30% {
    opacity: 0.7;
  }
  100% {
    opacity: 0;
    transform: rotate(var(--a)) translateY(70vmax) scaleY(1.6);
  }
}
.gi-out .gi-warp i {
  animation-duration: 0.3s;
}
.gi-wave {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 40px;
  height: 40px;
  margin: -20px;
  border-radius: 50%;
  border: 4px solid var(--gi);
  opacity: 0;
  animation: gi-wave 0.7s ease-out var(--at) forwards;
  pointer-events: none;
}
.gi-wave.w2 {
  border-color: #fff;
  border-width: 2px;
  animation-delay: calc(var(--at) + 120ms);
}
@keyframes gi-wave {
  0% {
    opacity: 1;
    transform: scale(0.5);
  }
  100% {
    opacity: 0;
    transform: scale(9);
  }
}
.gi-spark.coin {
  width: 16px;
  height: 16px;
  margin: -8px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 55%, #b9680a);
  box-shadow: 0 0 10px #ffc23d;
}
.gi-spark.card {
  width: 12px;
  height: 17px;
  margin: -8px -6px;
  border-radius: 2px;
  background: #fff;
  border: 2px solid var(--gi);
}
.gi-spark.ember {
  width: 8px;
  height: 8px;
  margin: -4px;
  border-radius: 50%;
  background: #fff3b0;
  box-shadow: 0 0 10px #ff8a3d, 0 0 20px #ff3d00;
}
.gi-spark.ball {
  width: 12px;
  height: 12px;
  margin: -6px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff, var(--gi));
}
.gi-spark {
  animation-name: gi-spark2;
}
@keyframes gi-spark2 {
  0% {
    opacity: 1;
    transform: rotate(var(--a)) translateX(0) rotate(0) scale(1.3);
  }
  100% {
    opacity: 0;
    transform: rotate(var(--a)) translateX(calc(var(--d) * 2.4)) translateY(40px) rotate(var(--r)) scale(0.4);
  }
}
.gi-skip {
  position: absolute;
  bottom: 24px;
  font-size: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  animation: gi-in 0.4s 0.5s backwards;
}
.gi-out .gi-scene {
  transition: transform 0.6s ease-in;
  transform: scale(2.5) rotate(8deg);
}
.gi .s-smoke {
  opacity: 0;
  animation: s-smoke 0.9s ease-out calc(var(--i) * 0.15s) forwards;
}
@keyframes s-smoke {
  0% {
    opacity: 0.6;
    transform: scale(0.3);
  }
  100% {
    opacity: 0;
    transform: translateY(30px) scale(1.8);
  }
}
.gi .s-loot {
  opacity: 0;
  animation: s-loot 0.8s cubic-bezier(0.2, 1.4, 0.4, 1) 1s forwards;
}
@keyframes s-loot {
  0% {
    opacity: 1;
    transform: translateY(30px) scale(0.3);
  }
  100% {
    opacity: 1;
    transform: translateY(-70px) scale(1.5) rotate(10deg);
  }
}

/* cases intro v2: real chest */
.gi .s-chestdrop {
  animation: s-chestdrop 0.5s cubic-bezier(0.5, 0, 0.8, 1.4) backwards, s-shake2 0.1s linear 0.5s 6;
}
@keyframes s-chestdrop {
  from {
    transform: translateY(-260px) scale(0.6);
  }
}
@keyframes s-shake2 {
  25% {
    transform: rotate(-5deg) scale(1.03);
  }
  75% {
    transform: rotate(5deg) scale(1.03);
  }
}
.gi .s-open {
  opacity: 0;
  animation: s-show 0.01s linear 1.1s forwards;
}
.gi .s-closed {
  animation: s-hide 0.01s linear 1.1s forwards;
}
@keyframes s-show {
  to {
    opacity: 1;
  }
}
@keyframes s-hide {
  to {
    opacity: 0;
  }
}
.gi .s-glow {
  animation: s-glow 0.8s ease-out 1.1s forwards;
}
@keyframes s-glow {
  0% {
    opacity: 0.9;
    transform: scale(0.4);
  }
  100% {
    opacity: 0;
    transform: scale(2.2);
  }
}
.gi .s-rays {
  transform-origin: 120px 130px;
  animation: s-rays 1.4s linear 1.1s forwards;
}
.gi .s-loot {
  animation: s-loot2 0.9s cubic-bezier(0.2, 1.3, 0.4, 1) 1.15s forwards;
}
.gi .s-loot.l2 {
  --lx: -80px;
  animation-delay: 1.25s;
}
.gi .s-loot.l3 {
  --lx: 80px;
  animation-delay: 1.3s;
}
@keyframes s-loot2 {
  0% {
    opacity: 1;
    transform: translate(0, 40px) scale(0.2) rotate(0);
  }
  100% {
    opacity: 1;
    transform: translate(var(--lx, 0), -90px) scale(1.6) rotate(360deg);
  }
}

/* ===== was skins.css ===== */
/* ---------- Chat designs (shop slot "chat"): restyle a player's message bubble ---------- */
.chat-msg.skin .chat-text {
  display: inline-block;
  margin-top: 2px;
  padding: 5px 10px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 600;
}
.skin-chat_ice .chat-text {
  background: linear-gradient(135deg, #e0f7ff, #8fd3ff);
  border-color: #bff0ff;
  color: #0b3a55;
}
.skin-chat_emerald .chat-text {
  background: linear-gradient(135deg, #0f7a3c, #22c55e);
  border-color: #7dffb4;
  color: #effff5;
}
.skin-chat_candy .chat-text {
  background: repeating-linear-gradient(45deg, #ff8ad8 0 10px, #ffb3e6 10px 20px);
  border-color: #fff;
  color: #5a0838;
}
.skin-chat_gold .chat-text {
  background: linear-gradient(135deg, #fff3b0, #ffc23d 50%, #b9680a);
  border-color: #ffe9a0;
  color: #3a2200;
  box-shadow: 0 0 10px rgba(255, 194, 61, 0.45);
}
.skin-chat_neon .chat-text {
  background: #0b0420;
  border-color: #ff2bd6;
  color: #ffd6f6;
  text-shadow: 0 0 6px #ff2bd6;
  animation: skin-neon 1.6s ease-in-out infinite alternate;
}
@keyframes skin-neon {
  from {
    box-shadow: 0 0 4px #ff2bd6, inset 0 0 4px #ff2bd6;
  }
  to {
    box-shadow: 0 0 14px #2bd9ff, inset 0 0 8px #2bd9ff;
    border-color: #2bd9ff;
  }
}
.skin-chat_matrix .chat-text {
  background: repeating-linear-gradient(0deg, #021a06 0 3px, #032b0a 3px 6px);
  border-color: #22ff66;
  color: #5dff8f;
  font-family: ui-monospace, Consolas, monospace;
  text-shadow: 0 0 5px #22ff66;
}
.skin-chat_fire .chat-text {
  background: linear-gradient(0deg, #ff3d00, #ff9500, #ffd000);
  background-size: 100% 200%;
  border-color: #ffd36b;
  color: #2a0500;
  animation: skin-fire 1.2s ease-in-out infinite alternate;
}
@keyframes skin-fire {
  from {
    background-position: 0 0;
    box-shadow: 0 -2px 10px rgba(255, 120, 0, 0.6);
  }
  to {
    background-position: 0 100%;
    box-shadow: 0 -4px 16px rgba(255, 60, 0, 0.8);
  }
}
.skin-chat_galaxy .chat-text {
  background: radial-gradient(circle at 20% 30%, #fff 0 1px, transparent 2px), radial-gradient(circle at 70% 60%, #fff 0 1px, transparent 2px), radial-gradient(circle at 45% 80%, #cfe8ff 0 1px, transparent 2px), linear-gradient(120deg, #1a0638, #4b1aa8, #0a2a6e);
  background-size: 60px 30px, 50px 40px, 70px 30px, 300% 100%;
  border-color: #a77be8;
  color: #f1e6ff;
  animation: skin-galaxy 6s linear infinite;
}
@keyframes skin-galaxy {
  to {
    background-position: 60px 0, -50px 0, 70px 0, 300% 0;
  }
}
.skin-chat_rainbow .chat-text {
  background: linear-gradient(90deg, #ff4d6d, #ffb347, #ffe36b, #5fd35f, #4aa3ff, #b388ff, #ff4d6d);
  background-size: 300% 100%;
  border-color: #fff;
  color: #1a1a1a;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
  animation: skin-rainbow 3s linear infinite;
}
@keyframes skin-rainbow {
  to {
    background-position: 300% 0;
  }
}

/* shop: chat sample cards and the live preview under the avatar */
.shop-art.chat {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 70px;
}
.shop-chat {
  text-align: left;
}
.shop-chat .chat-meta b {
  font-size: 12px;
}
.shop-preview-chat {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border-radius: 12px;
  background: var(--surface-2, rgba(255, 255, 255, 0.04));
}

/* ---------- Case cards: coloured spotlight per chest, floating chest, item bob ---------- */
.case-card {
  background: radial-gradient(120% 70% at 50% 18%, color-mix(in srgb, var(--trim) 26%, transparent), transparent 65%), var(--surface-1, #151a26);
  border-color: color-mix(in srgb, var(--trim) 35%, transparent);
}
.case-card:hover {
  border-color: var(--trim);
  box-shadow: 0 10px 30px color-mix(in srgb, var(--trim) 30%, transparent);
}
.case-card .case-art svg {
  filter: drop-shadow(0 6px 14px color-mix(in srgb, var(--trim) 45%, transparent));
}
.case-card .chest-hero {
  transform-box: fill-box;
  transform-origin: center;
  animation: chest-bob 2.4s ease-in-out infinite;
}
@keyframes chest-bob {
  50% {
    transform: translateY(-2px) rotate(-4deg);
  }
}

/* ---------- Game cards: slow light rays, twinkling stars, motif lifts and a shine on hover ---------- */
.game-card .card-rays {
  transform-origin: 100px 100px;
  animation: card-rays 40s linear infinite;
}
@keyframes card-rays {
  to {
    transform: rotate(360deg);
  }
}
.game-card .card-stars {
  animation: card-twinkle 2.2s ease-in-out infinite alternate;
}
@keyframes card-twinkle {
  from {
    opacity: 0.35;
  }
}
.game-card .motif {
  transform-origin: 100px 110px;
  transition: transform 0.35s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.game-card:hover .motif {
  transform: translateY(-8px) scale(1.06) rotate(-1.5deg);
}
.game-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.28) 48%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}
.game-card:hover::after {
  transition: transform 0.7s ease;
  transform: translateX(120%);
}
.game-card:hover {
  box-shadow: 0 14px 34px color-mix(in srgb, var(--glow, #f2c44a) 35%, transparent);
}

/* ---------- Profile pictures and level locks ---------- */
.av-face.av-pic {
  overflow: hidden;
  background: radial-gradient(circle at 35% 30%, #3a4150, #1b1f27);
}
.av-face.av-pic img {
  width: 78%;
  height: 78%;
  object-fit: contain;
  image-rendering: pixelated;
}
.shop-art {
  position: relative;
}
.shop-card.locked .shop-art > :not(.shop-lock) {
  filter: grayscale(0.85) brightness(0.55);
}
.shop-lock {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffd23d;
  font-size: 12px;
  font-weight: 900;
  transform: translate(-50%, -50%);
}

/* ===== was gamefx.css ===== */
/* ---------- Shared stage effects (public/js/fx/stagefx.js) ---------- */
.sfx-layer {
  position: absolute;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  overflow: visible;
}
.sfx-p {
  position: absolute;
  width: 8px;
  height: 8px;
  margin: -4px;
  border-radius: 2px;
  background: var(--c);
  box-shadow: 0 0 8px var(--c);
  animation: sfx-p 0.95s cubic-bezier(0.15, 0.7, 0.4, 1) forwards;
}
.sfx-p.coin {
  width: 14px;
  height: 14px;
  margin: -7px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 55%, #b9680a);
  box-shadow: 0 0 8px #ffc23d;
}
.sfx-p.gem {
  width: 10px;
  height: 10px;
  margin: -5px;
  transform: rotate(45deg);
  background: linear-gradient(135deg, #e8fffd, var(--c));
}
.sfx-p.ember {
  border-radius: 50%;
  background: #fff3b0;
  box-shadow: 0 0 10px #ff8a3d, 0 0 18px #ff3d00;
}
.sfx-p.confetti {
  width: 7px;
  height: 12px;
  box-shadow: none;
}
@keyframes sfx-p {
  0% {
    opacity: 1;
    transform: translate(0, 0) rotate(0) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translate(var(--dx), calc(var(--dy) + 60px)) rotate(var(--r)) scale(0.3);
  }
}
.sfx-flash {
  position: absolute;
  inset: 0;
  z-index: 19;
  pointer-events: none;
  border-radius: inherit;
  animation: sfx-flash 0.65s ease-out forwards;
}
.sfx-flash.win {
  background: radial-gradient(circle, rgba(46, 229, 157, 0.45), transparent 70%);
}
.sfx-flash.loss {
  background: radial-gradient(circle, rgba(255, 77, 109, 0.45), transparent 70%);
}
.sfx-flash.gold {
  background: radial-gradient(circle, rgba(255, 210, 90, 0.55), transparent 70%);
}
@keyframes sfx-flash {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}
.sfx-shake {
  animation: sfx-shake 0.45s ease-out;
}
.sfx-shake-strong {
  animation: sfx-shake 0.55s ease-out;
  --s: 2;
}
@keyframes sfx-shake {
  15% {
    transform: translate(calc(-6px * var(--s, 1)), calc(3px * var(--s, 1))) rotate(-1deg);
  }
  35% {
    transform: translate(calc(6px * var(--s, 1)), calc(-3px * var(--s, 1))) rotate(1deg);
  }
  55% {
    transform: translate(calc(-4px * var(--s, 1)), 0);
  }
  75% {
    transform: translate(calc(3px * var(--s, 1)), calc(2px * var(--s, 1)));
  }
}
.sfx-float {
  position: absolute;
  z-index: 21;
  transform: translate(-50%, -50%);
  font-weight: 900;
  font-size: 22px;
  white-space: nowrap;
  pointer-events: none;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  animation: sfx-float 1.1s ease-out forwards;
}
.sfx-float.win {
  color: #2ee59d;
}
.sfx-float.loss {
  color: #ff4d6d;
}
.sfx-float.gold {
  color: #ffd23d;
}
@keyframes sfx-float {
  0% {
    opacity: 0;
    transform: translate(-50%, -20%) scale(0.6);
  }
  20% {
    opacity: 1;
    transform: translate(-50%, -60%) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -180%) scale(1);
  }
}
.crash-shake {
  animation: sfx-shake 0.55s ease-out;
  --s: 2;
}

/* ---------- Blackjack: felt table, cards fly from the shoe and flip ---------- */
.stage-blackjack {
  background: radial-gradient(ellipse at 50% 40%, #1f7a4a 0%, #0f4a2c 55%, #08301c 100%);
  border: 6px solid #5a3412;
  box-shadow: inset 0 0 0 2px #c9a14a, inset 0 0 60px rgba(0, 0, 0, 0.5);
}
.stage-blackjack .bj-arc {
  margin: 4px auto 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.25em;
  color: rgba(255, 230, 160, 0.55);
  text-align: center;
}
.stage-blackjack .hand-label {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-weight: 800;
}
.playing-card.deal-in {
  animation: bj-deal 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.1) calc(var(--k, 0) * 0.18s) backwards;
}
@keyframes bj-deal {
  from {
    opacity: 0;
    transform: translate(260px, -180px) rotate(-160deg) scale(0.6);
  }
}
.playing-card.flip-in {
  animation: bj-flip 0.5s ease-out;
}
@keyframes bj-flip {
  0% {
    transform: rotateY(90deg) scale(1.1);
  }
  100% {
    transform: rotateY(0);
  }
}
.hand.glow .playing-card {
  box-shadow: 0 0 22px rgba(255, 210, 90, 0.8);
}
.hand.bust .playing-card {
  filter: grayscale(0.7) brightness(0.7);
  transition: filter 0.4s;
}
.bj-banner {
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 0.08em;
  animation: bj-banner 0.6s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes bj-banner {
  from {
    transform: scale(0.2) rotate(-10deg);
    opacity: 0;
  }
}

/* ---------- Mines: dark cave, glowing tiles, gem pop, chain explosions ---------- */
.stage-mines {
  background: radial-gradient(ellipse at 50% 0%, rgba(78, 230, 220, 0.12), transparent 60%), radial-gradient(ellipse at 50% 100%, rgba(255, 90, 60, 0.08), transparent 60%), linear-gradient(180deg, #161a22, #0c0e13);
}
.stage-mines .tile {
  background: linear-gradient(160deg, #3a4150, #252a35);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 4px 0 #161a22, inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
}
.stage-mines .tile:not(:disabled):hover {
  transform: translateY(-3px);
  background: linear-gradient(160deg, #4b5466, #2f3543);
  box-shadow: 0 7px 0 #161a22, 0 0 16px rgba(78, 230, 220, 0.35);
}
.stage-mines .tile.safe {
  background: radial-gradient(circle, rgba(78, 230, 220, 0.35), #1b3b45);
  box-shadow: 0 0 18px rgba(78, 230, 220, 0.45), inset 0 0 12px rgba(78, 230, 220, 0.4);
}
.stage-mines .tile.mine {
  background: radial-gradient(circle, rgba(255, 90, 60, 0.45), #3a1414);
}
.stage-mines .tile.dim {
  opacity: 0.55;
}
.tile.pop-gem {
  animation: tile-pop 0.45s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes tile-pop {
  0% {
    transform: rotateY(90deg) scale(0.8);
  }
  100% {
    transform: rotateY(0) scale(1);
  }
}
.tile.boom {
  animation: tile-boom 0.6s ease-out;
}
@keyframes tile-boom {
  0% {
    transform: scale(1.4);
    filter: brightness(3);
  }
  100% {
    transform: scale(1);
  }
}
.tile.chain {
  animation: tile-chain 0.4s ease-out;
}
@keyframes tile-chain {
  40% {
    transform: scale(1.2);
    filter: brightness(2) saturate(2);
    box-shadow: 0 0 24px #ff5a3c;
  }
}

/* ---------- Tower: climbing sky, stone floors, glowing current floor ---------- */
.stage-tower {
  --climb: 0;
  background: radial-gradient(circle at 80% 10%, rgba(255, 255, 255, calc(var(--climb) * 0.15)) 0 2px, transparent 3px) 0 0 / 60px 50px, radial-gradient(circle at 30% 40%, rgba(255, 255, 255, calc(var(--climb) * 0.2)) 0 1px, transparent 2px) 0 0 / 45px 70px, linear-gradient(180deg, color-mix(in srgb, #0b0a24 calc(var(--climb) * 100%), #3b6fb5), color-mix(in srgb, #24123f calc(var(--climb) * 100%), #9cc8f0));
  transition: background 0.8s;
}
.stage-tower .tower-row {
  padding: 6px 8px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(110, 100, 90, 0.55), rgba(60, 55, 50, 0.55));
  border: 1px solid rgba(0, 0, 0, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}
.stage-tower .tower-row.current {
  background: linear-gradient(180deg, rgba(255, 194, 61, 0.35), rgba(120, 80, 20, 0.45));
  box-shadow: 0 0 22px rgba(255, 194, 61, 0.45);
  animation: row-pulse 1.4s ease-in-out infinite;
}
@keyframes row-pulse {
  50% {
    box-shadow: 0 0 34px rgba(255, 194, 61, 0.7);
  }
}
.stage-tower .tile {
  background: linear-gradient(160deg, #8a7f74, #5a524b);
  border: 1px solid rgba(0, 0, 0, 0.4);
  box-shadow: 0 4px 0 #3a342f;
}
.stage-tower .tile:not(:disabled):hover {
  transform: translateY(-3px);
  box-shadow: 0 7px 0 #3a342f, 0 0 14px rgba(255, 210, 90, 0.5);
}
.stage-tower .tile.safe {
  background: radial-gradient(circle, rgba(46, 229, 157, 0.45), #1d4a35);
}
.tower-row.locked {
  animation: row-locked 0.5s ease-out;
}
@keyframes row-locked {
  40% {
    transform: scale(1.04);
    box-shadow: 0 0 30px rgba(46, 229, 157, 0.7);
  }
}
.tower-row.crumble {
  animation: row-crumble 0.6s ease-in;
}
@keyframes row-crumble {
  30% {
    transform: translateX(-6px) rotate(-1deg);
  }
  60% {
    transform: translateX(6px) rotate(1deg);
    filter: brightness(1.6) sepia(0.6);
  }
}

/* ---------- Chicken Road: side-scrolling street with 4 areas ---------- */
.cr-world {
  position: relative;
  overflow: hidden;
  height: 300px;
  border-radius: 16px;
  background: #3a7d2c;
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.3);
}
.cr-track {
  position: relative;
  display: flex;
  height: 100%;
  transition: transform 0.5s cubic-bezier(0.3, 0.8, 0.3, 1);
}
.cr-lane {
  position: relative;
  flex: none;
  width: 92px;
  height: 100%;
  overflow: hidden;
  background: #3b3f47;
  border-right: 3px dashed rgba(255, 255, 255, 0.55);
}
.cr-start,
.cr-goal {
  display: grid;
  place-items: center;
  border-right: none;
  background: repeating-linear-gradient(0deg, #5aa83f 0 18px, #4e9a36 18px 36px);
}
.cr-goal {
  background: repeating-conic-gradient(#fff 0 25%, #111 0 50%) 0 0 / 24px 24px;
}
.cr-tag {
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.1em;
}
.cr-lane.zone-farm {
  background: linear-gradient(90deg, #8a6a43, #7b5d3a);
  border-right-color: rgba(255, 240, 200, 0.4);
}
.cr-lane.zone-city {
  background: #3b3f47;
}
.cr-lane.zone-highway {
  background: #2a2d33;
  border-right: 3px solid #f2c44a;
}
.cr-lane.zone-nether {
  background: linear-gradient(180deg, #5a1414, #3a0a0a);
  border-right-color: rgba(255, 120, 60, 0.6);
  box-shadow: inset 0 -30px 40px rgba(255, 90, 30, 0.25);
}
.cr-zone {
  position: absolute;
  top: 8px;
  left: 6px;
  z-index: 3;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.6);
  color: #ffd23d;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}
.cr-cover {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 70px;
  margin: -35px;
  border-radius: 50%;
  background: radial-gradient(circle, #5b616b, #2c3036);
  border: 3px solid #1b1e23;
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.08);
  color: #fff;
}
.cr-cover b {
  font-size: 15px;
}
.cr-cover small {
  font-size: 9px;
  opacity: 0.7;
}
.cr-lane.passed .cr-cover {
  background: radial-gradient(circle, #2ee59d, #137a52);
}
.cr-lane.here .cr-cover {
  box-shadow: 0 0 0 4px #ffd23d, 0 0 24px #ffd23d;
}
.cr-car {
  position: absolute;
  left: 50%;
  top: -80px;
  z-index: 2;
  width: 66px;
  height: 66px;
  margin-left: -33px;
  transform: rotate(90deg);
  animation: cr-drive var(--speed) linear var(--delay) infinite;
}
.cr-car svg {
  width: 100%;
  height: 100%;
}
.zone-nether .cr-car {
  filter: hue-rotate(-20deg) saturate(1.6) drop-shadow(0 0 6px #ff5a1f);
}
.zone-highway .cr-car {
  filter: hue-rotate(190deg);
}
@keyframes cr-drive {
  from {
    top: -80px;
  }
  to {
    top: 320px;
  }
}
/* Lanes the chicken stands on or has passed are blocked: no traffic there. */
.cr-lane.passed .cr-car,
.cr-lane.here .cr-car,
.cr-start .cr-car {
  display: none;
}
.cr-lane.hit .cr-car,
.cr-lane.reveal .cr-car {
  animation: cr-slam 0.35s cubic-bezier(0.6, 0, 1, 0.6) forwards;
}
@keyframes cr-slam {
  from {
    top: -80px;
  }
  to {
    top: 110px;
  }
}
.cr-lane.hit {
  box-shadow: inset 0 0 40px rgba(255, 60, 60, 0.7);
}
.cr-chicken {
  position: absolute;
  left: -32px;
  top: 50%;
  z-index: 4;
  width: 64px;
  height: 64px;
  margin-top: -40px;
  transition: transform 0.4s cubic-bezier(0.3, 0.8, 0.3, 1);
  filter: drop-shadow(0 6px 4px rgba(0, 0, 0, 0.45));
}
.cr-chicken svg {
  width: 100%;
  height: 100%;
}
.cr-chicken.cr-jump svg {
  animation: cr-hop 0.4s ease-out;
}
@keyframes cr-hop {
  40% {
    transform: translateY(-34px) scale(1.1, 0.95) rotate(-8deg);
  }
  80% {
    transform: translateY(2px) scale(1.1, 0.9);
  }
}
.cr-chicken.dead svg {
  animation: cr-dead 0.6s ease-in 0.25s forwards;
}
@keyframes cr-dead {
  to {
    transform: rotate(540deg) scale(0.2);
    opacity: 0;
  }
}
.cr-banner {
  position: absolute;
  left: 50%;
  top: 40%;
  z-index: 6;
  padding: 8px 22px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.7);
  color: #ffd23d;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 0.06em;
  white-space: nowrap;
  transform: translate(-50%, -50%);
  animation: cr-banner 1.6s ease-out forwards;
}
.cr-banner.zone-nether {
  color: #ff7a45;
  box-shadow: 0 0 30px rgba(255, 90, 30, 0.6);
}
@keyframes cr-banner {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(2);
  }
  15%,
  75% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -90%);
  }
}

/* ---------- Target slide bar (Limbo, Slide, Upgrader) ---------- */
.target-slide {
  margin: -4px 0 6px;
}
.target-range {
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, #2ee59d 0, #ffc23d calc(var(--fill, 0%) * 0.6), #ff4d6d var(--fill, 0%), rgba(255, 255, 255, 0.1) var(--fill, 0%));
  outline: none;
}
.target-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff, #ffc23d);
  border: 3px solid #1b1e23;
  box-shadow: 0 0 12px rgba(255, 194, 61, 0.7);
  cursor: grab;
}
.target-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffc23d;
  border: 3px solid #1b1e23;
}
.target-ends {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  opacity: 0.6;
}

/* ---------- Upgrader: draggable zone, glowing wheel ---------- */
.stage-upgrader {
  background: radial-gradient(circle at 50% 45%, rgba(168, 85, 247, 0.22), transparent 60%), linear-gradient(180deg, #17121f, #0c0a12);
}
.up-dial {
  cursor: grab;
  touch-action: none;
  box-shadow: 0 0 40px rgba(168, 85, 247, 0.35), inset 0 0 0 6px rgba(0, 0, 0, 0.35);
  transition: box-shadow 0.3s;
}
.up-dial.dragging {
  cursor: grabbing;
  box-shadow: 0 0 50px rgba(46, 229, 157, 0.55), inset 0 0 0 6px rgba(0, 0, 0, 0.35);
}
.up-dial.spinning {
  animation: up-pulse 0.5s ease-in-out infinite alternate;
}
@keyframes up-pulse {
  to {
    box-shadow: 0 0 70px rgba(255, 194, 61, 0.6), inset 0 0 0 6px rgba(0, 0, 0, 0.35);
  }
}
.up-dial.won {
  box-shadow: 0 0 80px rgba(46, 229, 157, 0.8), inset 0 0 0 6px rgba(0, 0, 0, 0.35);
}
.up-dial.lost {
  box-shadow: 0 0 60px rgba(255, 77, 109, 0.7), inset 0 0 0 6px rgba(0, 0, 0, 0.35);
}
.up-ticks {
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: repeating-conic-gradient(rgba(255, 255, 255, 0.35) 0 1deg, transparent 1deg 10deg);
  -webkit-mask: radial-gradient(circle, transparent 66%, #000 67%);
  mask: radial-gradient(circle, transparent 66%, #000 67%);
  pointer-events: none;
}
.up-handle {
  position: absolute;
  z-index: 3;
  width: 22px;
  height: 22px;
  margin: -11px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff, #2ee59d);
  border: 3px solid #0d2a1e;
  box-shadow: 0 0 14px #2ee59d;
  pointer-events: none;
}
.prize.prize-win {
  animation: prize-win 0.8s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes prize-win {
  40% {
    transform: scale(1.5) rotate(10deg);
    filter: drop-shadow(0 0 20px #2ee59d);
  }
}
.prize.prize-lose {
  animation: prize-lose 0.6s ease-in;
}
@keyframes prize-lose {
  50% {
    transform: scale(0.8) rotate(-8deg);
    filter: grayscale(1) brightness(0.6);
  }
}

/* ---------- Limbo: neon stage, gauge with target mark, history ---------- */
.stage-limbo {
  background: linear-gradient(180deg, transparent 60%, rgba(236, 72, 153, 0.15)), repeating-linear-gradient(90deg, rgba(236, 72, 153, 0.12) 0 1px, transparent 1px 40px), radial-gradient(circle at 50% 30%, rgba(236, 72, 153, 0.25), transparent 60%), #120a18;
}
.lb-wrap {
  display: flex;
  align-items: stretch;
  gap: 18px;
  min-height: 300px;
}
.lb-wrap .stage-center {
  flex: 1;
}
.lb-gauge {
  position: relative;
  flex: none;
  width: 26px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.08);
}
.lb-fill {
  position: absolute;
  left: 3px;
  right: 3px;
  bottom: 3px;
  height: 0;
  border-radius: 999px;
  background: linear-gradient(0deg, #ec4899, #ffc23d);
  box-shadow: 0 0 16px #ec4899;
}
.lb-gauge.passed .lb-fill {
  background: linear-gradient(0deg, #16a34a, #2ee59d);
  box-shadow: 0 0 22px #2ee59d;
}
.lb-mark {
  position: absolute;
  left: -6px;
  right: -6px;
  height: 3px;
  background: #fff;
  box-shadow: 0 0 8px #fff;
}
.lb-mark::after {
  content: attr(data-label);
  position: absolute;
  left: 34px;
  top: -9px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}
.limbo-num {
  font-size: 92px;
  text-shadow: 0 0 30px rgba(236, 72, 153, 0.5);
}
.limbo-num.counting {
  color: #fff;
  animation: lb-count 0.12s linear infinite alternate;
}
@keyframes lb-count {
  to {
    transform: scale(1.03);
  }
}
.limbo-num.lb-win {
  animation: lb-win 0.6s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes lb-win {
  40% {
    transform: scale(1.35);
    text-shadow: 0 0 40px #2ee59d;
  }
}
.limbo-num.lb-lose {
  animation: lb-lose 0.5s ease-out;
}
@keyframes lb-lose {
  30% {
    transform: scale(0.85);
    filter: blur(1px);
  }
}
.lb-history {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
}
.lb-chip {
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  animation: cc-in 0.35s ease-out;
}
.lb-chip.win {
  background: rgba(46, 229, 157, 0.18);
  color: #2ee59d;
}
.lb-chip.loss {
  background: rgba(255, 77, 109, 0.15);
  color: #ff7a8f;
}

/* ---------- Slide: glowing lane, pointers, winners highlighted ---------- */
.stage-slide {
  background: radial-gradient(ellipse at 50% 40%, rgba(6, 182, 212, 0.2), transparent 60%), linear-gradient(180deg, #0b1820, #070d12);
}
.sl-lane {
  position: relative;
  width: 100%;
  padding: 14px 0;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.3);
  box-shadow: inset 0 0 30px rgba(6, 182, 212, 0.15);
  -webkit-mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
  mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
}
.sl-lane.moving .reel-cell {
  filter: blur(1.5px);
}
.sl-pointer {
  position: absolute;
  left: 50%;
  z-index: 3;
  width: 0;
  height: 0;
  margin-left: -10px;
  border: 10px solid transparent;
}
.sl-pointer.top {
  top: 0;
  border-top-color: #ffd23d;
  filter: drop-shadow(0 0 6px #ffd23d);
}
.sl-pointer.bottom {
  bottom: 0;
  border-bottom-color: #ffd23d;
  filter: drop-shadow(0 0 6px #ffd23d);
}
.sl-lane .reel-cell.ok {
  box-shadow: inset 0 -4px 0 #2ee59d;
}
.sl-lane .reel-cell.mega {
  background: linear-gradient(160deg, #ffd23d, #b9680a);
  color: #1a1000;
}
.reel-cell.sl-hit {
  animation: sl-hit 0.7s cubic-bezier(0.2, 1.6, 0.4, 1);
  position: relative;
  z-index: 2;
}
@keyframes sl-hit {
  40% {
    transform: scale(1.35);
  }
}
.sl-lane.won .reel-cell.sl-hit {
  box-shadow: 0 0 30px #2ee59d, inset 0 0 0 3px #2ee59d;
}
.sl-lane.lost .reel-cell.sl-hit {
  box-shadow: 0 0 30px #ff4d6d, inset 0 0 0 3px #ff4d6d;
}

/* ---------- Dice ---------- */
.stage-dice {
  background: radial-gradient(ellipse at 50% 30%, rgba(59, 130, 246, 0.22), transparent 60%), linear-gradient(180deg, #0e1424, #080b14);
}
.dice-num {
  font-size: 80px;
  text-shadow: 0 0 26px rgba(59, 130, 246, 0.5);
}
.dice-tumble {
  display: flex;
  gap: 14px;
  height: 56px;
}
.dice-tumble span {
  width: 52px;
  height: 52px;
  filter: drop-shadow(0 6px 6px rgba(0, 0, 0, 0.5));
}
.dice-tumble span svg {
  width: 100%;
  height: 100%;
}
.dice-tumble.rolling span:first-child {
  animation: dice-tumble 0.6s cubic-bezier(0.2, 0.8, 0.3, 1.2);
}
.dice-tumble.rolling span:last-child {
  animation: dice-tumble2 0.65s cubic-bezier(0.2, 0.8, 0.3, 1.2);
}
@keyframes dice-tumble {
  from {
    transform: translate(-160px, -60px) rotate(-720deg);
  }
}
@keyframes dice-tumble2 {
  from {
    transform: translate(160px, -80px) rotate(760deg);
  }
}
.dice-track .marker {
  transition: left 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.1);
}
.dice-track .marker.drop {
  animation: dice-drop 0.55s ease-out;
}
@keyframes dice-drop {
  0% {
    transform: translate(-50%, -60px) rotate(-180deg);
  }
  70% {
    transform: translate(-50%, 4px) rotate(10deg);
  }
}
.stage-dice .win-zone {
  box-shadow: 0 0 18px rgba(46, 229, 157, 0.5);
}

/* ---------- Coinflip ---------- */
.stage-coinflip {
  background: radial-gradient(circle at 50% 40%, rgba(250, 204, 21, 0.22), transparent 55%), linear-gradient(180deg, #17140a, #0b0a05);
}
.cf-jump.up {
  animation: cf-up 2.1s cubic-bezier(0.3, 0, 0.4, 1);
}
@keyframes cf-up {
  0% {
    transform: translateY(0) scale(1);
  }
  45% {
    transform: translateY(-120px) scale(1.15);
  }
  90% {
    transform: translateY(0) scale(1);
  }
  95% {
    transform: translateY(-10px);
  }
}
.cf-jump.land {
  animation: cf-land 0.35s ease-out;
}
@keyframes cf-land {
  40% {
    transform: scale(1.08, 0.92);
  }
}
.cf-shadow {
  display: block;
  width: 120px;
  height: 14px;
  margin-top: -6px;
  border-radius: 50%;
  background: radial-gradient(rgba(0, 0, 0, 0.55), transparent 70%);
}
.cf-streak {
  min-height: 24px;
  font-weight: 900;
  font-size: 20px;
  color: #ffd23d;
  text-shadow: 0 0 16px rgba(255, 210, 61, 0.7);
}
.cf-streak.pop {
  animation: bj-banner 0.5s cubic-bezier(0.2, 1.6, 0.4, 1);
}

/* ---------- Keno ---------- */
.stage-keno {
  background: radial-gradient(ellipse at 50% 0%, rgba(34, 197, 94, 0.18), transparent 60%), linear-gradient(180deg, #0c1610, #070c09);
}
.kn-tube {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  margin-bottom: 12px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.3);
  box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.6);
}
.kn-ball {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #9aa3b2 70%);
  color: #111;
  font-size: 12px;
  font-weight: 900;
  animation: kn-ball 0.4s cubic-bezier(0.2, 1.5, 0.4, 1);
}
.kn-ball.hit {
  background: radial-gradient(circle at 35% 30%, #d9ffe9, #22c55e 70%);
  box-shadow: 0 0 12px #22c55e;
}
@keyframes kn-ball {
  from {
    transform: translateY(-40px) scale(0.3);
    opacity: 0;
  }
}
.stage-keno .keno-cell.hit {
  animation: kn-hit 0.5s cubic-bezier(0.2, 1.6, 0.4, 1);
  box-shadow: 0 0 16px rgba(46, 229, 157, 0.7);
}
.stage-keno .keno-cell.drawn {
  animation: kn-drawn 0.3s ease-out;
}
@keyframes kn-hit {
  40% {
    transform: scale(1.3) rotate(-6deg);
  }
}
@keyframes kn-drawn {
  50% {
    transform: scale(0.85);
  }
}

/* ---------- Hi-Lo: table glows hotter with the streak ---------- */
.stage-hilo {
  --hl-heat: 0;
  background: radial-gradient(circle at 50% 45%, color-mix(in srgb, #ff7a1f calc(var(--hl-heat) * 45%), rgba(56, 189, 248, 0.2)), transparent 60%), linear-gradient(180deg, #0d1520, #070b11);
  transition: background 0.6s;
}
.playing-card.hl-up {
  animation: hl-up 0.5s cubic-bezier(0.2, 1.3, 0.4, 1);
}
.playing-card.hl-down {
  animation: hl-down 0.5s cubic-bezier(0.2, 1.3, 0.4, 1);
}
@keyframes hl-up {
  0% {
    transform: translateY(80px) rotateX(90deg);
    opacity: 0;
  }
}
@keyframes hl-down {
  0% {
    transform: translateY(-80px) rotateX(-90deg);
    opacity: 0;
  }
}
.playing-card.hl-deal {
  animation: bj-deal 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.1);
}
.playing-card.hl-crack {
  animation: hl-crack 0.6s ease-out forwards;
}
@keyframes hl-crack {
  50% {
    filter: brightness(0.6) sepia(1) hue-rotate(-40deg) saturate(3);
  }
  100% {
    filter: grayscale(0.8) brightness(0.7);
  }
}
.stage-hilo .trail .playing-card {
  animation: cc-in 0.3s ease-out;
}

/* ---------- Bet panel (every game): glass card, coin field, pill buttons, shiny play button ---------- */
.game-cols > .controls.panel {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(242, 196, 74, 0.22);
  background: radial-gradient(120% 60% at 0% 0%, rgba(242, 196, 74, 0.1), transparent 60%), linear-gradient(180deg, #1a1d25, #12141a);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.game-cols > .controls .label {
  color: #f2c44a;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.14em;
}
.bet-box {
  position: relative;
  flex: 1;
  display: flex;
}
.bet-box .input {
  width: 100%;
  padding-left: 38px;
  font-weight: 800;
  font-size: 16px;
}
.bet-coin {
  position: absolute;
  left: 10px;
  top: 50%;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  pointer-events: none;
  filter: drop-shadow(0 0 6px rgba(255, 194, 61, 0.6));
}
.bet-coin svg {
  width: 100%;
  height: 100%;
}
.game-cols > .controls .input {
  border-radius: 12px;
  background: #0c0e13;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.game-cols > .controls .input:focus {
  border-color: #f2c44a;
  box-shadow: 0 0 0 3px rgba(242, 196, 74, 0.2);
}
.game-cols > .controls .mini-btn {
  border-radius: 10px;
  background: linear-gradient(180deg, #2a2e38, #1d2028);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-weight: 800;
  transition: transform 0.12s, border-color 0.2s, color 0.2s;
}
.game-cols > .controls .mini-btn:hover:not(:disabled) {
  border-color: #f2c44a;
  color: #f2c44a;
  transform: translateY(-1px);
}
.game-cols > .controls .mini-btn:active:not(:disabled) {
  transform: scale(0.94);
}
.game-cols > .controls .segmented {
  padding: 4px;
  border-radius: 14px;
  background: #0c0e13;
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.game-cols > .controls .segmented button {
  border-radius: 10px;
  font-weight: 800;
  transition: background 0.2s, color 0.2s, transform 0.12s;
}
.game-cols > .controls .segmented button.active {
  background: linear-gradient(180deg, #f6d36b, #e0a92a);
  color: #1a1200;
  box-shadow: 0 4px 14px rgba(242, 196, 74, 0.35);
}
.game-cols > .controls .note {
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border-left: 3px solid rgba(242, 196, 74, 0.5);
}
.game-cols > .controls .btn-block {
  position: relative;
  overflow: hidden;
  min-height: 52px;
  border-radius: 14px;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: 0.04em;
  background: linear-gradient(180deg, #ffd96b, #f2b02a 60%, #d48f12);
  box-shadow: 0 6px 0 #9a6208, 0 10px 24px rgba(242, 176, 42, 0.35);
  transition: transform 0.1s, box-shadow 0.1s;
}
.game-cols > .controls .btn-block::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.45) 50%, transparent 65%);
  transform: translateX(-120%);
  animation: play-shine 3.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes play-shine {
  0%,
  60% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(120%);
  }
}
.game-cols > .controls .btn-block:active:not(:disabled) {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #9a6208, 0 6px 14px rgba(242, 176, 42, 0.3);
}
.game-cols > .controls .btn-block:disabled::after {
  display: none;
}

/* ---------- Cases: chest hero shakes harder, pops open ---------- */
.chest-stack.shaking {
  animation: chest-shake 0.12s linear infinite;
}
@keyframes chest-shake {
  25% {
    transform: rotate(-6deg) scale(1.04);
  }
  75% {
    transform: rotate(6deg) scale(1.04);
  }
}
.chest-stack.opened {
  animation: chest-pop 0.6s cubic-bezier(0.2, 1.6, 0.4, 1);
  filter: drop-shadow(0 0 26px var(--trim, #f2c44a));
}
@keyframes chest-pop {
  40% {
    transform: scale(1.25) translateY(-8px);
  }
}
.case-hero {
  background: radial-gradient(60% 120% at 20% 50%, color-mix(in srgb, var(--trim) 22%, transparent), transparent 70%);
}

/* ---------- Mines v2: gem/bomb art, lose sequence ---------- */
.stage-mines .board-5 {
  position: relative;
}
.mn-gem,
.mn-bomb {
  width: 78%;
  height: 78%;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.5));
}
.tile.safe .mn-gem {
  animation: mn-gem-glow 1.8s ease-in-out infinite alternate;
}
@keyframes mn-gem-glow {
  to {
    filter: drop-shadow(0 0 10px #4ee6dc) brightness(1.15);
  }
}
.board-5.mn-lost .tile.safe {
  filter: grayscale(0.8) brightness(0.5);
  transition: filter 0.6s 0.3s;
}
.mn-wave {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 5;
  width: 40px;
  height: 40px;
  margin: -20px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff6c2, #ff8a3d 40%, rgba(255, 61, 0, 0) 70%);
  pointer-events: none;
  animation: mn-wave 0.8s ease-out forwards;
}
@keyframes mn-wave {
  from {
    transform: scale(0.3);
    opacity: 1;
  }
  to {
    transform: scale(16);
    opacity: 0;
  }
}
.mn-boomtext {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 6;
  font-size: 72px;
  font-weight: 900;
  color: #ffb347;
  -webkit-text-stroke: 3px #7a1d00;
  text-shadow: 0 0 30px #ff3d00;
  pointer-events: none;
  animation: mn-boom 1.4s cubic-bezier(0.2, 1.6, 0.4, 1) forwards;
}
@keyframes mn-boom {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.2) rotate(-15deg);
  }
  20%,
  70% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1) rotate(-6deg);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.3) rotate(-6deg);
  }
}

/* ===== was gamefx2.css ===== */
/* ---------- Blackjack win show ---------- */
.bj-win {
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 22;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: bj-win 2.6s ease-out forwards;
}
.bj-win b {
  position: relative;
  font-size: 54px;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #2ee59d;
  -webkit-text-stroke: 2px #0b3d24;
  text-shadow: 0 0 30px #2ee59d;
}
.bj-win.bj b {
  color: #ffd23d;
  -webkit-text-stroke: 2px #6b3b04;
  text-shadow: 0 0 40px #ffc23d;
}
.bj-win span {
  position: relative;
  padding: 4px 18px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.6);
  color: #ffd23d;
  font-size: 22px;
  font-weight: 900;
}
.bj-rays {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 420px;
  height: 420px;
  margin: -210px;
  border-radius: 50%;
  background: repeating-conic-gradient(rgba(255, 230, 140, 0.35) 0 8deg, transparent 8deg 22deg);
  -webkit-mask: radial-gradient(circle, #000 20%, transparent 70%);
  mask: radial-gradient(circle, #000 20%, transparent 70%);
  animation: bj-rays 2.6s linear;
}
@keyframes bj-rays {
  to {
    transform: rotate(120deg);
  }
}
@keyframes bj-win {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.2) rotate(-12deg);
  }
  12% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.15) rotate(3deg);
  }
  20%,
  80% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -70%) scale(0.9);
  }
}
.bj-chip {
  position: absolute;
  top: 10%;
  z-index: 21;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff 0 28%, #e0284f 30% 60%, #fff 62% 68%, #e0284f 70%);
  box-shadow: 0 3px 0 #7a0a1c, 0 0 10px rgba(255, 210, 90, 0.6);
  pointer-events: none;
  animation: bj-chip 1s cubic-bezier(0.3, 0.6, 0.4, 1.2) calc(var(--k) * 0.06s) both;
}
.bj-chip:nth-child(2n) {
  background: radial-gradient(circle, #fff 0 28%, #1f6fe0 30% 60%, #fff 62% 68%, #1f6fe0 70%);
  box-shadow: 0 3px 0 #0b2a6e;
}
.bj-chip:nth-child(3n) {
  background: radial-gradient(circle, #fff 0 28%, #111 30% 60%, #ffd23d 62% 68%, #111 70%);
  box-shadow: 0 3px 0 #000;
}
@keyframes bj-chip {
  from {
    opacity: 0;
    transform: translate(0, -40px) scale(0.6);
  }
  30% {
    opacity: 1;
  }
  to {
    transform: translate(var(--x), 300px);
    opacity: 0.9;
  }
}

/* ---------- Upgrader v2: no text selection, metal rim, WIN tag ---------- */
.stage-upgrader,
.up-dial,
.up-dial * {
  user-select: none;
  -webkit-user-select: none;
}
.up-dial {
  border: 10px solid #23202c;
  outline: 3px solid rgba(168, 85, 247, 0.4);
  outline-offset: 4px;
}
.up-dial .inner {
  background: radial-gradient(circle at 50% 35%, #2a2438, #120f19 70%);
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.7), 0 0 0 4px rgba(255, 255, 255, 0.04);
}
.up-dial .prize svg {
  filter: drop-shadow(0 0 12px rgba(46, 229, 157, 0.5));
}
.up-handle {
  width: 40px;
  height: 22px;
  margin: -11px -20px;
  border-radius: 999px;
  display: grid;
  place-items: center;
}
.up-handle span {
  font-size: 10px;
  font-weight: 900;
  color: #0d2a1e;
  letter-spacing: 0.06em;
}

/* ---------- Limbo: how-it-works steps and info boxes ---------- */
.lb-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}
.lb-steps div {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  line-height: 1.3;
}
.lb-steps i {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--step, #ec4899);
  color: #fff;
  font-style: normal;
  font-weight: 900;
}
.lb-boxes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
  margin-bottom: 8px;
}
.lb-boxes div {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.lb-boxes span {
  font-size: 11px;
  opacity: 0.7;
}
.lb-boxes b {
  font-size: 20px;
  color: #ffd23d;
}
@media (max-width: 600px) {
  .lb-steps {
    grid-template-columns: 1fr;
  }
}

/* ---------- Slide v2: gem tiles, glowing frame, legend ---------- */
.sl-stage {
  gap: 10px;
}
.sl-info {
  width: 100%;
}
.sl-lane {
  padding: 18px 0;
  -webkit-mask: none;
  mask: none;
  overflow: hidden;
  background: radial-gradient(ellipse at center, rgba(6, 182, 212, 0.16), transparent 70%), rgba(0, 0, 0, 0.35);
}
.sl-lane::before,
.sl-lane::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 22%;
  pointer-events: none;
}
.sl-lane::before {
  left: 0;
  background: linear-gradient(90deg, #070d12, transparent);
}
.sl-lane::after {
  right: 0;
  background: linear-gradient(270deg, #070d12, transparent);
}
.sl-lane .reel {
  background: transparent;
}
.sl-lane .reel-marker {
  display: none;
}
.sl-tile {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 14px;
  background: linear-gradient(170deg, color-mix(in srgb, var(--tc) 30%, #1b1f27), #11141a 85%) !important;
  border: 2px solid color-mix(in srgb, var(--tc) 45%, transparent);
  color: #fff !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.sl-tile b {
  font-size: 18px;
  font-weight: 900;
  color: var(--tc);
  text-shadow: 0 0 10px color-mix(in srgb, var(--tc) 60%, transparent);
}
.sl-gem {
  width: 44px;
  height: 44px;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.5));
}
.sl-gem svg {
  width: 100%;
  height: 100%;
}
.sl-tile.t-nether,
.sl-tile.t-diamond {
  animation: sl-shimmer 1.6s ease-in-out infinite alternate;
}
@keyframes sl-shimmer {
  to {
    box-shadow: 0 0 18px color-mix(in srgb, var(--tc) 70%, transparent), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  }
}
.sl-lane .sl-tile.ok {
  box-shadow: inset 0 -5px 0 #2ee59d, inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.sl-frame {
  position: absolute;
  left: 50%;
  top: 8px;
  bottom: 8px;
  z-index: 3;
  width: 122px;
  margin-left: -61px;
  border-radius: 18px;
  border: 3px solid #ffd23d;
  box-shadow: 0 0 22px rgba(255, 210, 61, 0.6), inset 0 0 22px rgba(255, 210, 61, 0.25);
  pointer-events: none;
  animation: sl-frame 1.2s ease-in-out infinite alternate;
}
@keyframes sl-frame {
  to {
    box-shadow: 0 0 40px rgba(255, 210, 61, 0.9), inset 0 0 30px rgba(255, 210, 61, 0.4);
  }
}
.sl-lane.won .sl-frame {
  border-color: #2ee59d;
  box-shadow: 0 0 50px rgba(46, 229, 157, 0.9), inset 0 0 30px rgba(46, 229, 157, 0.4);
}
.sl-lane.lost .sl-frame {
  border-color: #ff4d6d;
  box-shadow: 0 0 40px rgba(255, 77, 109, 0.8);
}
.sl-pointer {
  z-index: 4;
}
.sl-out .sl-res {
  color: var(--tc);
  text-shadow: 0 0 16px var(--tc);
}
.sl-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 12px;
  font-size: 11px;
  opacity: 0.85;
}
.sl-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--tc);
  font-weight: 800;
}
.sl-legend i {
  width: 14px;
  height: 14px;
}
.sl-legend i svg {
  width: 100%;
  height: 100%;
}

/* ---------- Chicken Road v3 ---------- */
.stage-chicken {
  background: linear-gradient(180deg, #14211a, #0b120e);
}
.cr-world {
  height: 340px;
  border-radius: 18px;
  background: #2f6f2a;
  box-shadow: inset 0 0 0 3px rgba(0, 0, 0, 0.35), 0 14px 30px rgba(0, 0, 0, 0.4);
}
.cr-lane {
  width: 112px;
  border-right: none;
  background-color: #3a3e46;
  background-image: linear-gradient(90deg, transparent calc(100% - 4px), rgba(255, 255, 255, 0.7) calc(100% - 4px));
  background-size: 100% 46px;
  -webkit-mask: none;
}
.cr-lane::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.75) 0 26px, transparent 26px 46px);
}
.cr-lane.zone-farm {
  background: linear-gradient(90deg, #6b4a2a, #7d5a35 50%, #6b4a2a);
}
.cr-lane.zone-farm::after {
  background: repeating-linear-gradient(180deg, #8a6a3a 0 4px, transparent 4px 18px);
  width: 6px;
}
.cr-lane.zone-city {
  background: linear-gradient(90deg, #3a3e46, #444953 50%, #3a3e46);
}
.cr-lane.zone-city.first-zone {
  background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 10px, transparent 10px 20px);
}
.cr-lane.zone-highway {
  background: linear-gradient(90deg, #26292f, #2e3239 50%, #26292f);
}
.cr-lane.zone-highway::after {
  background: linear-gradient(90deg, #f2c44a 0 40%, transparent 40% 60%, #f2c44a 60%);
  width: 6px;
}
.cr-lane.zone-nether {
  background: radial-gradient(circle at 30% 20%, rgba(255, 106, 31, 0.35) 0 3px, transparent 4px) 0 0 / 40px 50px, radial-gradient(circle at 70% 60%, rgba(255, 140, 40, 0.3) 0 2px, transparent 3px) 0 0 / 30px 40px, linear-gradient(90deg, #4a1010, #5c1414 50%, #4a1010);
  box-shadow: inset 0 -40px 50px rgba(255, 90, 30, 0.25);
}
.cr-lane.zone-nether::after {
  background: repeating-linear-gradient(180deg, #ff6a1f 0 20px, transparent 20px 40px);
  box-shadow: 0 0 8px #ff6a1f;
}
.cr-start {
  background: linear-gradient(90deg, #8c9099, #a3a7b0) !important;
}
.cr-start::after,
.cr-goal::after {
  display: none;
}
.cr-goal {
  background: repeating-conic-gradient(#fff 0 25%, #111 0 50%) 0 0 / 28px 28px !important;
}
.cr-cover {
  width: 78px;
  height: 78px;
  margin: -39px;
  background: radial-gradient(circle at 40% 35%, #7b828e, #3c424b 70%);
  border: 4px solid #22262c;
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.08), inset 0 0 0 10px rgba(0, 0, 0, 0.12), 0 4px 0 rgba(0, 0, 0, 0.4);
}
.cr-cover b {
  font-size: 16px;
  font-weight: 900;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
}
.cr-lane.passed .cr-cover {
  background: radial-gradient(circle at 40% 35%, #5fffbd, #13865a 70%);
  border-color: #0b5a3a;
}
.cr-lane.here .cr-cover {
  box-shadow: 0 0 0 4px #ffd23d, 0 0 30px #ffd23d;
}
.cr-car {
  width: 44px;
  height: 88px;
  margin-left: -22px;
  top: -130px;
  transform: none;
  filter: none;
}
.cr-car.long {
  height: 130px;
}
.zone-highway .cr-car,
.zone-nether .cr-car {
  filter: none;
}
.zone-nether .cr-car svg {
  filter: drop-shadow(0 0 8px #ff5a1f);
}
@keyframes cr-drive {
  from {
    top: -140px;
  }
  to {
    top: 360px;
  }
}
@keyframes cr-slam {
  from {
    top: -140px;
  }
  to {
    top: 110px;
  }
}
.cr-cone {
  position: absolute;
  left: 50%;
  top: 14px;
  z-index: 2;
  width: 30px;
  height: 36px;
  margin-left: -15px;
  opacity: 0;
  transform: translateY(-20px) scale(0.5);
  transition: opacity 0.3s, transform 0.4s cubic-bezier(0.2, 1.6, 0.4, 1);
}
.cr-cone + .cr-cover {
  z-index: 1;
}
.cr-lane.passed .cr-cone,
.cr-lane.here .cr-cone {
  opacity: 1;
  transform: none;
}
.cr-zone {
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 10px;
  border: 1px solid rgba(255, 210, 61, 0.5);
  box-shadow: 0 0 12px rgba(255, 210, 61, 0.35);
  z-index: 5;
}
.cr-chicken {
  width: 80px;
  height: 80px;
  left: -40px;
  margin-top: -46px;
  filter: drop-shadow(0 10px 6px rgba(0, 0, 0, 0.5));
}
.cr-chicken:not(.cr-jump):not(.dead) svg {
  animation: cr-idle 1.2s ease-in-out infinite;
}
@keyframes cr-idle {
  50% {
    transform: translateY(-3px) rotate(-3deg);
  }
}

/* ---------- Tower v3: castle wall with torches, gold-trimmed tiles ---------- */
.stage-tower {
  background: radial-gradient(circle at 8% 30%, rgba(255, 150, 50, calc(0.25 + var(--climb) * 0.2)), transparent 18%), radial-gradient(circle at 92% 30%, rgba(255, 150, 50, calc(0.25 + var(--climb) * 0.2)), transparent 18%), linear-gradient(0deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.2)), repeating-linear-gradient(0deg, #2b2620 0 2px, transparent 2px 28px), repeating-linear-gradient(90deg, #2b2620 0 2px, transparent 2px 56px), #3d352c;
  animation: tw-torch 2s ease-in-out infinite alternate;
}
@keyframes tw-torch {
  50% {
    filter: brightness(1.08);
  }
}
.stage-tower .tower-row {
  background: linear-gradient(180deg, rgba(20, 16, 12, 0.75), rgba(10, 8, 6, 0.75));
  border: 1px solid rgba(200, 160, 80, 0.25);
}
.stage-tower .tower-row .mult {
  color: #ffd23d;
  font-weight: 900;
}
.stage-tower .tile {
  position: relative;
  min-height: 46px;
  border-radius: 10px;
  background: linear-gradient(180deg, #5a4630, #3b2d1f);
  border: 2px solid #c9a14a;
  box-shadow: inset 0 2px 0 rgba(255, 230, 160, 0.25), inset 0 -3px 0 rgba(0, 0, 0, 0.35), 0 4px 0 #22190f;
}
.stage-tower .tile:empty::before {
  content: "?";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 900;
  color: rgba(255, 220, 140, 0.35);
}
.stage-tower .tower-row.current .tile:not(:disabled) {
  border-color: #ffd23d;
  animation: tw-ready 1.2s ease-in-out infinite alternate;
}
@keyframes tw-ready {
  to {
    box-shadow: inset 0 2px 0 rgba(255, 230, 160, 0.35), 0 4px 0 #22190f, 0 0 16px rgba(255, 210, 61, 0.6);
  }
}
.stage-tower .tile:not(:disabled):hover {
  transform: translateY(-3px);
  background: linear-gradient(180deg, #6e5638, #4a3825);
}
.stage-tower .tile.safe {
  background: radial-gradient(circle, rgba(46, 229, 157, 0.55), #144a33);
  border-color: #2ee59d;
}
.stage-tower .tile.mine {
  background: radial-gradient(circle, rgba(255, 90, 60, 0.6), #4a1414);
  border-color: #ff4d6d;
}

/* ---------- Dice labels ---------- */
.win-zone {
  position: relative;
}
.dz-tag {
  position: absolute;
  left: 50%;
  top: -22px;
  transform: translateX(-50%);
  font-size: 11px;
  font-weight: 900;
  color: #2ee59d;
  letter-spacing: 0.1em;
}
.stage-dice .dice-track {
  background: linear-gradient(90deg, rgba(255, 77, 109, 0.55), rgba(255, 77, 109, 0.55));
}

/* ---------- Coinflip picks ---------- */
.cf-picks {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 6px;
}
.cf-or {
  font-weight: 900;
  opacity: 0.5;
}
.cf-pick {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  width: 130px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 2px solid rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.2s, box-shadow 0.2s;
}
.cf-pick:hover:not(:disabled) {
  transform: translateY(-3px);
}
.cf-pick.active {
  border-color: #ffd23d;
  background: rgba(255, 210, 61, 0.1);
  box-shadow: 0 0 22px rgba(255, 210, 61, 0.4);
}
.cf-face {
  width: 64px;
  height: 64px;
}
.cf-face svg {
  width: 100%;
  height: 100%;
}
.cf-pick b {
  font-size: 16px;
  letter-spacing: 0.1em;
}
.cf-pick small {
  font-size: 11px;
  opacity: 0.65;
}

/* ---------- Hi-Lo deck and draw ---------- */
.hl-table {
  display: flex;
  align-items: center;
  gap: 40px;
}
.hl-deck {
  position: relative;
  width: 110px;
}
.hl-deck .playing-card {
  position: absolute;
  left: 0;
  top: 0;
}
.hl-deck .playing-card:nth-child(1) {
  position: relative;
  transform: translate(-6px, 6px);
  opacity: 0.6;
}
.hl-deck .playing-card:nth-child(2) {
  transform: translate(-3px, 3px);
  opacity: 0.8;
}
.hl-ghost {
  position: fixed;
  z-index: 150;
  margin: 0;
  pointer-events: none;
  transition: transform 0.16s cubic-bezier(0.3, 0.8, 0.4, 1);
}
.playing-card.hl-flipin {
  animation: hl-flipin 0.45s cubic-bezier(0.2, 1.3, 0.4, 1);
}
@keyframes hl-flipin {
  0% {
    transform: rotateY(90deg) scale(1.08);
  }
  100% {
    transform: rotateY(0) scale(1);
  }
}

/* ---------- Mega rain: banner, glowing card, full-screen shout ---------- */
.mega-rain {
  position: fixed;
  left: 50%;
  top: 70px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 20px;
  overflow: hidden;
  border: 2px solid #ffd23d;
  border-radius: 999px;
  background: linear-gradient(90deg, #1b3a8a, #3b82f6, #1b3a8a);
  background-size: 200% 100%;
  color: #fff;
  box-shadow: 0 0 30px rgba(59, 130, 246, 0.7), 0 0 60px rgba(255, 210, 61, 0.35);
  transform: translateX(-50%);
  cursor: pointer;
  animation: mr-bg 3s linear infinite, mr-bob 2s ease-in-out infinite;
}
@keyframes mr-bg {
  to {
    background-position: 200% 0;
  }
}
@keyframes mr-bob {
  50% {
    transform: translateX(-50%) translateY(-3px) scale(1.03);
  }
}
.mega-rain b {
  font-size: 15px;
  letter-spacing: 0.14em;
  color: #ffd23d;
  text-shadow: 0 0 10px #ffd23d;
}
.mr-pool {
  font-weight: 900;
  font-size: 16px;
}
.mr-time {
  font-size: 12px;
  opacity: 0.85;
}
.mr-coins i {
  position: absolute;
  top: -12px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d);
  animation: mr-fall 2s linear infinite;
}
@keyframes mr-fall {
  to {
    transform: translateY(60px);
    opacity: 0;
  }
}
.rain-card.mega {
  border-color: #ffd23d !important;
  background: radial-gradient(circle at 50% 0%, rgba(255, 210, 61, 0.3), transparent 70%), linear-gradient(180deg, #1b2f6e, #0f1830) !important;
  box-shadow: 0 0 26px rgba(255, 210, 61, 0.5);
  animation: mr-card 1.6s ease-in-out infinite alternate;
}
@keyframes mr-card {
  to {
    box-shadow: 0 0 44px rgba(59, 130, 246, 0.8), 0 0 20px rgba(255, 210, 61, 0.6);
  }
}
.mega-shout {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: radial-gradient(circle, rgba(27, 58, 138, 0.85), rgba(3, 6, 20, 0.9) 70%);
  pointer-events: none;
  animation: mega-shout 3.2s ease-out forwards;
}
.mega-shout span {
  font-size: clamp(40px, 9vw, 96px);
  font-weight: 900;
  letter-spacing: 0.1em;
  color: #fff;
  text-shadow: 0 0 40px #3b82f6;
}
.mega-shout b {
  font-size: clamp(36px, 7vw, 80px);
  color: #ffd23d;
  text-shadow: 0 0 40px #ffc23d;
}
.mega-shout small {
  font-size: 18px;
  opacity: 0.85;
}
@keyframes mega-shout {
  0% {
    opacity: 0;
    transform: scale(1.4);
  }
  12%,
  80% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
  }
}

/* ---------- Shop: animated items get an aura, sparkles and a moving shine ---------- */
.cos-art .cos-spin {
  animation-duration: 3s !important;
}
.shop-card.animated .shop-art::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 110px;
  height: 110px;
  margin: -55px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, transparent, var(--rarity), transparent 40%, var(--rarity), transparent 80%);
  -webkit-mask: radial-gradient(circle, transparent 48%, #000 50%, #000 58%, transparent 60%);
  mask: radial-gradient(circle, transparent 48%, #000 50%, #000 58%, transparent 60%);
  animation: shop-aura 2.4s linear infinite;
  pointer-events: none;
}
@keyframes shop-aura {
  to {
    transform: rotate(360deg);
  }
}
.shop-card.animated .shop-art::after {
  content: "✦ ✧ ✦";
  position: absolute;
  left: 0;
  right: 0;
  top: -4px;
  text-align: center;
  color: var(--rarity);
  font-size: 12px;
  letter-spacing: 18px;
  animation: shop-spark 1.6s ease-in-out infinite;
  pointer-events: none;
}
@keyframes shop-spark {
  50% {
    opacity: 0.2;
    transform: translateY(-4px) scale(1.2);
  }
}
.shop-card.animated {
  background: radial-gradient(circle at 50% 30%, color-mix(in srgb, var(--rarity) 18%, transparent), transparent 60%), var(--surface-1, #151a26);
}
.shop-card.animated:hover .shop-art .av {
  animation: shop-float 1.2s ease-in-out infinite alternate;
}
@keyframes shop-float {
  to {
    transform: translateY(-6px) scale(1.08);
  }
}
.cos-flicker {
  animation: cos-flicker2 0.5s ease-in-out infinite alternate !important;
  transform-box: fill-box;
  transform-origin: bottom;
}
@keyframes cos-flicker2 {
  from {
    transform: scaleY(0.85);
    opacity: 0.85;
  }
  to {
    transform: scaleY(1.15);
    opacity: 1;
  }
}
.cos-pulse {
  animation: cos-pulse2 1.2s ease-in-out infinite !important;
  transform-box: fill-box;
  transform-origin: center;
}
@keyframes cos-pulse2 {
  50% {
    transform: scale(1.15);
    filter: brightness(1.5) drop-shadow(0 0 3px #fff);
  }
}

/* ---------- Mines difficulty tiles ---------- */
.mn-diff {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.mn-dbtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 2px;
  border-radius: 12px;
  background: #0c0e13;
  border: 2px solid rgba(255, 255, 255, 0.06);
  color: #fff;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.12s, box-shadow 0.2s;
}
.mn-dbtn b {
  font-size: 12px;
  font-weight: 900;
  color: var(--dc);
}
.mn-dbtn span {
  font-size: 10px;
  opacity: 0.6;
}
.mn-dbtn:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--dc) 50%, transparent);
}
.mn-dbtn.active {
  border-color: var(--dc);
  background: color-mix(in srgb, var(--dc) 15%, #0c0e13);
  box-shadow: 0 0 16px color-mix(in srgb, var(--dc) 40%, transparent);
}

/* ---------- Battle create side panel: clearer type ---------- */
.bcreate-side .bcreate-label {
  display: block;
  margin: 4px 0 8px;
  color: #f2c44a;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.bcreate-side .bopt {
  border-radius: 14px;
  background: linear-gradient(180deg, #1c1f27, #14161c);
  border: 2px solid rgba(255, 255, 255, 0.07);
  transition: border-color 0.2s, transform 0.12s, box-shadow 0.2s;
}
.bcreate-side .bopt:hover {
  transform: translateY(-2px);
}
.bcreate-side .bopt b,
.bcreate-side .bopt strong {
  font-size: 22px;
  font-weight: 900;
  color: #fff;
}
.bcreate-side .bopt span {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.55);
}
.bcreate-side .bopt.active {
  border-color: #a855f7;
  background: linear-gradient(180deg, rgba(168, 85, 247, 0.25), rgba(168, 85, 247, 0.08));
  box-shadow: 0 0 18px rgba(168, 85, 247, 0.35);
}
.bcreate-side .bmode,
.bcreate-side .btoggle {
  border-radius: 14px;
  background: linear-gradient(180deg, #1c1f27, #14161c);
  border: 2px solid rgba(255, 255, 255, 0.07);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.bcreate-side .bmode b,
.bcreate-side .btoggle b {
  display: block;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #fff;
}
.bcreate-side .bmode span:not(.icon),
.bcreate-side .btoggle div span {
  display: block;
  font-size: 12px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.6);
}
.bcreate-side .bmode.active {
  border-color: #a855f7;
  background: linear-gradient(90deg, rgba(168, 85, 247, 0.28), rgba(168, 85, 247, 0.06));
  box-shadow: 0 0 18px rgba(168, 85, 247, 0.3);
}
.bcreate-side .bmode .icon,
.bcreate-side .btoggle .icon {
  width: 30px;
  height: 30px;
  padding: 6px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
}

/* ---------- Upgrader item picker ---------- */
.up-pick-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 14px 0 8px;
}
.up-pick-head b {
  color: #f2c44a;
  letter-spacing: 0.06em;
}
.up-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 8px;
  max-height: 260px;
  overflow-y: auto;
  padding: 4px;
}
.up-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 4px;
  border-radius: 12px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--rc) 14%, #1a1d25), #12141a);
  border: 2px solid color-mix(in srgb, var(--rc) 30%, transparent);
  color: #fff;
  cursor: pointer;
  transition: transform 0.12s, border-color 0.2s, box-shadow 0.2s;
}
.up-item:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: var(--rc);
}
.up-item.active {
  border-color: #2ee59d;
  box-shadow: 0 0 18px rgba(46, 229, 157, 0.5);
}
.up-item:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}
.up-item-img {
  width: 40px;
  height: 40px;
}
.up-item-img img,
.up-item-img svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.up-item b {
  font-size: 12px;
  color: #ffd23d;
}
.up-item small {
  font-size: 10px;
  opacity: 0.6;
}
.prize .up-coins svg,
.prize img {
  width: 64px;
  height: 64px;
  object-fit: contain;
}

/* ===== was gamefx3.css ===== */
/* ---------- Hi-Lo: question and verdict ---------- */
.hl-ask {
  max-width: 520px;
  padding: 10px 16px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 16px;
  text-align: center;
}
.hl-ask b {
  color: #ffd23d;
}
.hl-ask b.up {
  color: #2ee59d;
}
.hl-ask b.down {
  color: #ff4d6d;
}
.hl-verdict {
  min-height: 0;
  font-size: 16px;
  text-align: center;
}
.hl-verdict:empty {
  display: none;
}
.hl-verdict.ok,
.hl-verdict.bad {
  padding: 8px 16px;
  border-radius: 12px;
}
.hl-verdict.ok {
  background: rgba(46, 229, 157, 0.15);
  border: 2px solid #2ee59d;
  color: #c8ffe6;
}
.hl-verdict.bad {
  background: rgba(255, 77, 109, 0.15);
  border: 2px solid #ff4d6d;
  color: #ffd0d8;
}
.hl-verdict.ok b {
  color: #2ee59d;
}
.hl-verdict.bad b {
  color: #ff4d6d;
}
.hl-ask.pop,
.hl-verdict.pop {
  animation: bj-banner 0.45s cubic-bezier(0.2, 1.6, 0.4, 1);
}

/* ---------- Tower v4: castle tower at night, arched wooden doors ---------- */
.stage-tower {
  animation: none;
  background: radial-gradient(circle at 85% 12%, #fff8d8 0 22px, rgba(255, 248, 216, 0.25) 23px, transparent 70px), radial-gradient(circle at 20% 15%, #fff 0 1px, transparent 2px) 0 0 / 70px 60px, radial-gradient(circle at 60% 40%, rgba(255, 255, 255, 0.8) 0 1px, transparent 2px) 0 0 / 90px 80px, linear-gradient(180deg, #0b1030 0%, #1b1446 55%, #2a1838 100%);
}
.stage-tower .tower {
  position: relative;
  width: min(100%, 460px);
  margin: 40px auto 0;
  padding: 14px 14px 10px;
  border-radius: 6px 6px 0 0;
  background: repeating-linear-gradient(0deg, transparent 0 22px, rgba(0, 0, 0, 0.35) 22px 24px), repeating-linear-gradient(90deg, transparent 0 46px, rgba(0, 0, 0, 0.25) 46px 48px), linear-gradient(90deg, #6b6f7a, #8a8f9b 50%, #6b6f7a);
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.5), 0 20px 40px rgba(0, 0, 0, 0.5);
}
/* battlements and a flag on top */
.stage-tower .tower::before {
  content: "";
  position: absolute;
  left: -8px;
  right: -8px;
  top: -22px;
  height: 24px;
  background: linear-gradient(90deg, #7d828e 0 60%, transparent 60%) 0 0 / 40px 100%, linear-gradient(#6b6f7a, #6b6f7a) 0 100% / 100% 8px no-repeat;
  -webkit-mask: linear-gradient(#000, #000);
}
.stage-tower .tower::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -64px;
  width: 34px;
  height: 42px;
  background: linear-gradient(90deg, #3a2a1a 0 3px, transparent 3px), linear-gradient(135deg, #ef4444 0 50%, transparent 50%) 3px 0 / 30px 22px no-repeat;
  animation: tw-flag 1.2s ease-in-out infinite alternate;
}
@keyframes tw-flag {
  to {
    transform: skewY(-6deg);
  }
}
.stage-tower .tower-row {
  gap: 10px;
  padding: 6px 4px;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.stage-tower .tower-row + .tower-row {
  border-top: 3px solid rgba(0, 0, 0, 0.35);
}
.stage-tower .tower-row .mult {
  min-width: 64px;
  padding: 3px 6px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.55);
  color: #ffd23d;
  font-weight: 900;
  text-align: center;
}
.stage-tower .tower-row.current {
  animation: none;
  background: radial-gradient(ellipse at center, rgba(255, 170, 60, 0.35), transparent 70%);
  box-shadow: none;
}
.stage-tower .tile {
  min-height: 54px;
  border-radius: 26px 26px 4px 4px;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.25) 0 2px, transparent 2px) 0 0 / 12px 100%, linear-gradient(180deg, #8a5a2b, #5e3a18);
  border: 3px solid #2e2a26;
  box-shadow: inset 0 6px 0 rgba(255, 210, 150, 0.15), inset 0 -8px 0 rgba(0, 0, 0, 0.3), 0 3px 0 #1d1a17;
}
.stage-tower .tile:empty::before {
  content: "";
  inset: auto;
  right: 18%;
  top: 52%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #f2c44a;
  box-shadow: 0 0 4px #f2c44a;
}
.stage-tower .tower-row.current .tile:not(:disabled) {
  border-color: #ffd23d;
  animation: tw-ready 1.2s ease-in-out infinite alternate;
}
.stage-tower .tile:not(:disabled):hover {
  transform: translateY(-3px);
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.25) 0 2px, transparent 2px) 0 0 / 12px 100%, linear-gradient(180deg, #a06a35, #6e4520);
}
.stage-tower .tile.safe {
  background: radial-gradient(circle at 50% 60%, rgba(46, 229, 157, 0.6), #10301f 75%);
  border-color: #2ee59d;
}
.stage-tower .tile.mine {
  background: radial-gradient(circle at 50% 60%, rgba(255, 140, 40, 0.8), #3a0d0d 75%);
  border-color: #ff4d6d;
}
.stage-tower .tile.dim {
  opacity: 0.5;
}

/* ---------- Chicken Road v4: sidewalks, grass, street lamps ---------- */
.cr-world {
  height: 360px;
  background: #4a8a3a;
}
.cr-lane::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background: linear-gradient(180deg, #a9aeb6 0 30px, #6b7079 30px 34px, transparent 34px calc(100% - 34px), #6b7079 calc(100% - 34px) calc(100% - 30px), #a9aeb6 calc(100% - 30px));
}
.cr-lane.zone-farm::before {
  background: linear-gradient(180deg, #4fa83a 0 26px, #3b7f2c 26px 34px, transparent 34px calc(100% - 34px), #3b7f2c calc(100% - 34px) calc(100% - 26px), #4fa83a calc(100% - 26px));
}
.cr-lane.zone-highway::before {
  background: linear-gradient(180deg, #2c2f35 0 24px, #c9ccd2 24px 30px, transparent 30px calc(100% - 30px), #c9ccd2 calc(100% - 30px) calc(100% - 24px), #2c2f35 calc(100% - 24px));
}
.cr-lane.zone-nether::before {
  background: linear-gradient(180deg, #7a2a1a 0 26px, #ff6a1f 26px 30px, transparent 30px calc(100% - 30px), #ff6a1f calc(100% - 30px) calc(100% - 26px), #7a2a1a calc(100% - 26px));
}
.cr-start::before,
.cr-goal::before {
  display: none;
}
.cr-zone {
  top: 4px;
  z-index: 6;
}
.cr-cover {
  z-index: 2;
}
.cr-cone {
  top: 40px;
  z-index: 4;
}
.cr-lane.here {
  box-shadow: inset 0 0 40px rgba(255, 210, 61, 0.25);
}
.cr-chicken.cr-jump::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 50px;
  height: 14px;
  margin-left: -25px;
  border-radius: 50%;
  background: radial-gradient(rgba(255, 255, 255, 0.5), transparent 70%);
  animation: cr-dust 0.5s ease-out forwards;
}
@keyframes cr-dust {
  from {
    transform: scale(0.3);
    opacity: 1;
  }
  to {
    transform: scale(1.8);
    opacity: 0;
  }
}

/* Drawn profile pictures fill the whole avatar and stay smooth (only item pictures are pixel art). */
.av-face.av-pic img[src^="data:"] {
  width: 100%;
  height: 100%;
  image-rendering: auto;
}
.av-face.av-pic:has(img[src^="data:"]) {
  background: none;
}

/* ===== was gamefx4.css ===== */
/* ---------- Win animations v2 ---------- */
.win-pop {
  overflow: visible;
  background: linear-gradient(180deg, #1f8f5a, #0f5a37) !important;
  border: 2px solid #5fffbd !important;
  box-shadow: 0 0 30px rgba(46, 229, 157, 0.55), 0 10px 24px rgba(0, 0, 0, 0.4) !important;
}
.win-pop::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.5) 50%, transparent 65%);
  transform: translateX(-120%);
  animation: wp-shine 1.2s ease-out 0.2s forwards;
  pointer-events: none;
}
@keyframes wp-shine {
  to {
    transform: translateX(120%);
  }
}
.win-pop-plus {
  color: #fff !important;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.35), 0 0 14px rgba(255, 255, 255, 0.5);
}
.wp-coin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 14px;
  height: 14px;
  margin: -7px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 55%, #b9680a);
  box-shadow: 0 0 6px #ffc23d;
  opacity: 0;
  animation: wp-coin 0.9s cubic-bezier(0.2, 0.8, 0.4, 1) forwards;
}
@keyframes wp-coin {
  0% {
    opacity: 1;
    transform: rotate(var(--a)) translateX(0) scale(0.5);
  }
  100% {
    opacity: 0;
    transform: rotate(var(--a)) translateX(calc(var(--d) * 2)) scale(1);
  }
}
.bigwin-burst {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 1600px;
  height: 1600px;
  margin: -800px;
  background: repeating-conic-gradient(color-mix(in srgb, var(--accent) 22%, transparent) 0 6deg, transparent 6deg 18deg);
  -webkit-mask: radial-gradient(circle, #000 10%, transparent 60%);
  mask: radial-gradient(circle, #000 10%, transparent 60%);
  animation: bw-burst 14s linear infinite;
  pointer-events: none;
}
@keyframes bw-burst {
  to {
    transform: rotate(360deg);
  }
}
.bigwin-sparkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.bigwin-sparkles i {
  position: absolute;
  width: 6px;
  height: 6px;
  background: #fff;
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  animation: bw-sparkle 1.8s ease-in-out infinite;
}
@keyframes bw-sparkle {
  0%,
  100% {
    opacity: 0;
    transform: scale(0.3) rotate(0);
  }
  50% {
    opacity: 1;
    transform: scale(2.2) rotate(90deg);
  }
}
.bigwin-fountain {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.bigwin-fountain i {
  position: absolute;
  left: 50%;
  top: 60%;
  width: 22px;
  height: 22px;
  margin: -11px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 55%, #b9680a);
  box-shadow: 0 0 10px #ffc23d;
  opacity: 0;
  animation: bw-fountain 1.6s cubic-bezier(0.2, 0.7, 0.5, 1) infinite;
}
@keyframes bw-fountain {
  0% {
    opacity: 1;
    transform: translate(0, 0) rotate(0) scale(0.5);
  }
  50% {
    transform: translate(calc(var(--x) * 0.6), var(--y)) rotate(calc(var(--r) * 0.6)) scale(1.1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--x), 260px) rotate(var(--r)) scale(0.9);
  }
}
.bigwin-title span {
  background: linear-gradient(180deg, #fff 0%, #fff3b0 35%, var(--accent) 70%, color-mix(in srgb, var(--accent) 50%, #000));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  filter: drop-shadow(0 4px 0 rgba(0, 0, 0, 0.5)) drop-shadow(0 0 22px var(--accent));
}
.bigwin-body {
  position: relative;
  z-index: 2;
  animation: bw-slam 0.6s cubic-bezier(0.2, 1.5, 0.4, 1) both;
}
@keyframes bw-slam {
  0% {
    opacity: 0;
    transform: scale(2.6);
    filter: blur(10px);
  }
  100% {
    opacity: 1;
    transform: scale(1);
    filter: blur(0);
  }
}
.bigwin-art {
  animation: bw-art 2.4s ease-in-out infinite alternate;
}
@keyframes bw-art {
  to {
    transform: translateY(-10px) rotate(4deg) scale(1.06);
    filter: drop-shadow(0 0 30px var(--accent));
  }
}

/* ---------- Golden clover bonus ---------- */
.clover-tag {
  color: #ffd23d !important;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.08em;
}
.item-card.clover-card {
  background: radial-gradient(circle at 50% 30%, rgba(255, 210, 61, 0.28), transparent 70%), var(--surface-1, #151a26);
  border-color: #ffd23d !important;
  box-shadow: 0 0 18px rgba(255, 210, 61, 0.35);
}
.reel-cell.clover-hit {
  animation: clover-hit 0.8s cubic-bezier(0.2, 1.6, 0.4, 1);
  box-shadow: 0 0 40px #ffd23d, inset 0 0 0 3px #ffd23d !important;
}
@keyframes clover-hit {
  40% {
    transform: scale(1.4) rotate(-6deg);
  }
}
.reel.clover-mode {
  box-shadow: 0 0 0 3px #ffd23d, 0 0 40px rgba(255, 210, 61, 0.6);
  background: radial-gradient(ellipse at center, rgba(255, 210, 61, 0.2), transparent 70%);
}
.clover-show {
  position: absolute;
  left: 50%;
  top: 40%;
  z-index: 30;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: clover-show 2.2s ease-out forwards;
}
.clover-rays {
  position: absolute;
  left: 50%;
  top: 40%;
  width: 520px;
  height: 520px;
  margin: -260px;
  border-radius: 50%;
  background: repeating-conic-gradient(rgba(255, 220, 100, 0.4) 0 7deg, transparent 7deg 20deg);
  -webkit-mask: radial-gradient(circle, #000 15%, transparent 65%);
  mask: radial-gradient(circle, #000 15%, transparent 65%);
  animation: bj-rays 2.2s linear;
}
.clover-big {
  position: relative;
  width: 150px;
  height: 150px;
  animation: clover-spin 2.2s cubic-bezier(0.2, 1.2, 0.4, 1);
  filter: drop-shadow(0 0 30px #ffd23d);
}
.clover-big img,
.clover-big svg {
  width: 100%;
  height: 100%;
}
@keyframes clover-spin {
  0% {
    transform: scale(0) rotate(-540deg);
  }
  40% {
    transform: scale(1.25) rotate(0);
  }
  60% {
    transform: scale(1);
  }
}
.clover-show b {
  position: relative;
  font-size: 40px;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #ffd23d;
  -webkit-text-stroke: 2px #6b3b04;
  text-shadow: 0 0 30px #ffc23d;
}
.clover-show small {
  position: relative;
  padding: 4px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
}
@keyframes clover-show {
  0% {
    opacity: 0;
  }
  10%,
  85% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

/* ---------- Case cards v4: clover badge, best-item strip, chest lifts on hover ---------- */
.case-card {
  position: relative;
}
.case-clover {
  position: absolute;
  right: 10px;
  top: 10px;
  width: 26px;
  height: 26px;
  filter: drop-shadow(0 0 6px #ffd23d);
  animation: case-clover 2.4s ease-in-out infinite;
}
.case-clover img {
  width: 100%;
  height: 100%;
}
@keyframes case-clover {
  50% {
    transform: rotate(15deg) scale(1.15);
  }
}
.case-top {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 2px 0;
}
.case-top-item {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  padding: 3px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--rarity) 18%, rgba(0, 0, 0, 0.4));
  border: 1px solid color-mix(in srgb, var(--rarity) 55%, transparent);
}
.case-top-item img,
.case-top-item svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.case-card .case-name {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.02em;
}
.case-card .case-meta {
  font-size: 11px;
  opacity: 0.6;
}
.case-card .case-art {
  transition: transform 0.3s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.case-card:hover .case-art {
  transform: translateY(-6px) scale(1.06);
}

/* Locked shop items: you still see the item, a small level tag sits in the corner. */
.shop-card.locked .shop-art > :not(.shop-lock) {
  filter: grayscale(0.5) brightness(0.8) !important;
}
.shop-lock {
  left: auto !important;
  top: -4px !important;
  right: -14px;
  transform: none !important;
  padding: 2px 8px !important;
  font-size: 10px !important;
}

/* ===== was gamefx5.css ===== */
/* ---------- Tower v5: plain and clean ---------- */
.stage-tower {
  animation: none !important;
  background: linear-gradient(180deg, #161a22, #0f1217) !important;
}
.stage-tower .tower {
  width: min(100%, 480px);
  margin: 8px auto 0 !important;
  padding: 8px !important;
  border-radius: 16px !important;
  background: rgba(255, 255, 255, 0.03) !important;
  box-shadow: none !important;
}
.stage-tower .tower::before,
.stage-tower .tower::after {
  display: none !important;
}
.stage-tower .tower-row {
  padding: 4px !important;
  border-radius: 12px !important;
  background: transparent !important;
  border: none !important;
  animation: none !important;
}
.stage-tower .tower-row + .tower-row {
  border-top: none !important;
}
.stage-tower .tower-row.current {
  background: rgba(242, 196, 74, 0.08) !important;
}
.stage-tower .tower-row .mult {
  background: none !important;
  color: rgba(255, 255, 255, 0.55) !important;
  font-weight: 800;
}
.stage-tower .tower-row.current .mult {
  color: #f2c44a !important;
}
.stage-tower .tile {
  min-height: 46px !important;
  border-radius: 10px !important;
  background: #262b35 !important;
  border: 1px solid rgba(255, 255, 255, 0.06) !important;
  box-shadow: 0 3px 0 #1a1e26 !important;
  animation: none !important;
}
.stage-tower .tile:empty::before {
  display: none !important;
}
.stage-tower .tower-row.current .tile:not(:disabled) {
  background: #313848 !important;
  border-color: rgba(242, 196, 74, 0.45) !important;
}
.stage-tower .tile:not(:disabled):hover {
  transform: translateY(-2px);
  background: #3a4254 !important;
}
.stage-tower .tile.safe {
  background: rgba(46, 229, 157, 0.18) !important;
  border-color: #2ee59d !important;
}
.stage-tower .tile.mine {
  background: rgba(255, 77, 109, 0.2) !important;
  border-color: #ff4d6d !important;
}

/* ---------- Mines difficulty tiles: big number, small name ---------- */
.mn-dbtn {
  padding: 6px 0 !important;
}
.mn-dbtn b {
  font-size: 18px !important;
  line-height: 1.1;
}
.mn-dbtn span {
  font-size: 9px !important;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.75 !important;
  white-space: nowrap;
}

/* ---------- Chicken Road: hit chicken flies into the camera, screen cracks ---------- */
.cr-smash {
  position: fixed;
  z-index: 500;
  pointer-events: none;
  animation: cr-smash 0.75s cubic-bezier(0.5, 0, 0.9, 0.6) forwards;
}
.cr-smash svg {
  width: 100%;
  height: 100%;
}
@keyframes cr-smash {
  0% {
    transform: translate(0, 0) rotate(0) scale(1);
  }
  100% {
    transform: translate(var(--tx), var(--ty)) rotate(-25deg) scale(9);
  }
}
.cr-crack {
  position: fixed;
  inset: 0;
  z-index: 499;
  pointer-events: none;
  animation: cr-crack 1.6s ease-out forwards;
}
.cr-crack svg {
  width: 100%;
  height: 100%;
}
@keyframes cr-crack {
  0% {
    opacity: 0;
  }
  8% {
    opacity: 1;
  }
  70% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
.cr-feather {
  position: fixed;
  z-index: 501;
  width: 16px;
  height: 30px;
  border-radius: 50% 50% 50% 50% / 70% 70% 30% 30%;
  background: #fff;
  box-shadow: inset -3px 0 0 #dfe3e8;
  pointer-events: none;
  animation: cr-feather 1.6s ease-out forwards;
}
@keyframes cr-feather {
  0% {
    opacity: 1;
    transform: translate(0, 0) rotate(0);
  }
  100% {
    opacity: 0;
    transform: translate(var(--fx), var(--fy)) rotate(var(--fr));
  }
}

/* ---------- Hi-Lo buttons with chance bar, faster flip ---------- */
.stage-hilo .btn-green,
.stage-hilo .btn-red {
  position: relative;
  overflow: hidden;
  min-width: 170px;
  min-height: 56px;
}
.hl-btxt {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
}
.hl-btxt small {
  font-size: 11px;
  opacity: 0.8;
}
.hl-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 4px;
  background: rgba(255, 255, 255, 0.75);
}
.playing-card.hl-flipin {
  animation-duration: 0.28s !important;
}

/* ---------- Tutorial button and dialog ---------- */
.game-head {
  position: relative;
}
.tut-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.tut-btn:hover {
  border-color: #f2c44a;
  background: rgba(242, 196, 74, 0.1);
}
.tut-q {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #f2c44a;
  color: #1a1200;
  font-size: 13px;
  font-weight: 900;
}
.tut-overlay {
  position: fixed;
  inset: 0;
  z-index: 600;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(3, 5, 10, 0.7);
  backdrop-filter: blur(4px);
  animation: gi-in 0.2s ease-out;
}
.tut-card {
  width: min(460px, 100%);
  padding: 18px;
  border-radius: 20px;
  background: linear-gradient(180deg, #1c2029, #12151b);
  border: 1px solid rgba(242, 196, 74, 0.3);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  animation: bj-banner 0.35s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.tut-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.tut-head b {
  font-size: 20px;
  color: #f2c44a;
}
.tut-x {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}
.tut-step {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  animation: cc-in 0.35s ease-out calc(var(--i) * 0.08s) backwards;
}
.tut-step i {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f2c44a;
  color: #1a1200;
  font-style: normal;
  font-weight: 900;
}
.tut-step b {
  display: block;
  margin-bottom: 2px;
}
.tut-step p {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.75);
}
.tut-card .btn-block {
  margin-top: 12px;
}

/* ---------- Big win v3: tier climb, slams, keep-going button ---------- */
.bigwin.slam .bigwin-title {
  animation: bw-titleslam 0.45s cubic-bezier(0.2, 1.8, 0.4, 1);
}
@keyframes bw-titleslam {
  0% {
    transform: scale(2.2) rotate(-4deg);
    filter: brightness(2.5);
  }
  100% {
    transform: scale(1);
  }
}
.bigwin.slam::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.7), transparent 60%);
  animation: bw-flash 0.4s ease-out forwards;
  pointer-events: none;
}
@keyframes bw-flash {
  to {
    opacity: 0;
  }
}
.bigwin.step-mega {
  --accent: #ff5a7a !important;
}
.bigwin.step-epic {
  --accent: #b98bff !important;
}
.bigwin-value {
  transition: transform 0.2s;
}
.bigwin.counted .bigwin-value {
  animation: bw-valueslam 0.6s cubic-bezier(0.2, 1.8, 0.4, 1);
}
@keyframes bw-valueslam {
  0% {
    transform: scale(1.6);
  }
  100% {
    transform: scale(1);
  }
}
.bigwin-amount {
  font-variant-numeric: tabular-nums;
}
.bigwin-mult {
  font-variant-numeric: tabular-nums;
}
.bigwin-go {
  margin-top: 18px;
  padding: 14px 34px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffe27a, #f2b02a 60%, #d48f12);
  color: #1a1000;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.08em;
  box-shadow: 0 6px 0 #9a6208, 0 0 30px rgba(255, 210, 61, 0.6);
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
}
.bigwin.counted .bigwin-go {
  opacity: 1;
  transform: none;
  pointer-events: auto;
  animation: bw-go 0.9s ease-in-out 0.3s infinite alternate;
}
@keyframes bw-go {
  to {
    transform: scale(1.08);
    box-shadow: 0 6px 0 #9a6208, 0 0 50px rgba(255, 210, 61, 0.9);
  }
}

/* ---------- Big win v4: canvas particles, spotlights, giant coin, tension ---------- */
.bigwin-canvas {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}
.bigwin-body {
  z-index: 4 !important;
}
.bigwin-spot {
  position: absolute;
  bottom: -10%;
  width: 26vmax;
  height: 140vmax;
  background: linear-gradient(0deg, color-mix(in srgb, var(--accent) 55%, transparent), transparent 75%);
  filter: blur(14px);
  opacity: 0.55;
  transform-origin: 50% 100%;
  pointer-events: none;
  mix-blend-mode: screen;
}
.bigwin-spot.left {
  left: 5%;
  animation: bw-spot-l 3.2s ease-in-out infinite alternate;
}
.bigwin-spot.right {
  right: 5%;
  animation: bw-spot-r 3.6s ease-in-out infinite alternate;
}
@keyframes bw-spot-l {
  from {
    transform: rotate(28deg);
  }
  to {
    transform: rotate(-8deg);
  }
}
@keyframes bw-spot-r {
  from {
    transform: rotate(-28deg);
  }
  to {
    transform: rotate(8deg);
  }
}
.bigwin-bigcoin {
  position: absolute;
  left: 50%;
  top: 45%;
  width: min(62vmin, 520px);
  height: min(62vmin, 520px);
  transform: translate(-50%, -50%);
  opacity: 0.22;
  filter: drop-shadow(0 0 60px var(--accent)) blur(1px);
  perspective: 800px;
  pointer-events: none;
}
.bigwin-bigcoin span {
  display: block;
  width: 100%;
  height: 100%;
  animation: bw-coinspin 3.4s linear infinite;
}
.bigwin-bigcoin svg {
  width: 100%;
  height: 100%;
}
@keyframes bw-coinspin {
  to {
    transform: rotateY(360deg);
  }
}
.bigwin-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, transparent 45%, rgba(0, 0, 0, 0.7));
  pointer-events: none;
}
/* Tension: the screen pulses and slowly zooms in just before the final number lands. */
.bigwin.tension .bigwin-vignette {
  animation: bw-heart 0.42s ease-in-out infinite;
}
@keyframes bw-heart {
  50% {
    background: radial-gradient(circle, transparent 30%, color-mix(in srgb, var(--accent) 35%, rgba(0, 0, 0, 0.8)));
  }
}
.bigwin.tension .bigwin-body {
  animation: bw-zoomin 1.2s ease-in forwards;
}
@keyframes bw-zoomin {
  to {
    transform: scale(1.12);
  }
}
.bigwin.tension .bigwin-value {
  box-shadow: 0 0 40px var(--accent);
}
.bigwin.counted .bigwin-bigcoin {
  opacity: 0.4;
  transition: opacity 0.4s;
}
.bigwin.counted .bigwin-value {
  border-color: var(--accent) !important;
  box-shadow: 0 0 60px var(--accent), inset 0 0 20px color-mix(in srgb, var(--accent) 40%, transparent);
}
.bigwin.counted .bigwin-title span {
  animation: bw-shimmer 1.4s ease-in-out infinite !important;
}
@keyframes bw-shimmer {
  0%,
  100% {
    filter: drop-shadow(0 4px 0 rgba(0, 0, 0, 0.5)) drop-shadow(0 0 22px var(--accent));
  }
  50% {
    filter: drop-shadow(0 4px 0 rgba(0, 0, 0, 0.5)) drop-shadow(0 0 50px var(--accent)) brightness(1.4);
  }
}

/* ---------- Upgrader handle: just a round knob ---------- */
.up-handle {
  width: 24px !important;
  height: 24px !important;
  margin: -12px !important;
  border-radius: 50% !important;
}

/* ---------- Hi-Lo: big YOU LOST ---------- */
.hl-lost {
  position: absolute;
  left: 50%;
  top: 42%;
  z-index: 25;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 18px 38px;
  border-radius: 22px;
  background: rgba(30, 6, 12, 0.88);
  border: 3px solid #ff4d6d;
  box-shadow: 0 0 60px rgba(255, 77, 109, 0.55);
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: hl-lost 2.2s cubic-bezier(0.2, 1.5, 0.4, 1) forwards;
}
.hl-lost b {
  font-size: clamp(40px, 8vw, 72px);
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #ff4d6d;
  -webkit-text-stroke: 2px #5a0a18;
  text-shadow: 0 0 30px rgba(255, 77, 109, 0.8);
}
.hl-lost span {
  font-size: 16px;
  color: #ffd0d8;
}
@keyframes hl-lost {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(2.4) rotate(-6deg);
  }
  15%,
  80% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1) rotate(-3deg);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9) rotate(-3deg);
  }
}

/* ---------- Chicken Road: tumbling flight into the camera ---------- */
.cr-smash {
  animation: cr-smash2 1s cubic-bezier(0.45, 0, 0.85, 0.45) forwards !important;
}
@keyframes cr-smash2 {
  0% {
    transform: translate(0, 0) scale(1);
  }
  35% {
    transform: translate(calc(var(--tx) * 0.25), calc(var(--ty) * 0.25 - 140px)) scale(2.2);
  }
  100% {
    transform: translate(var(--tx), var(--ty)) scale(10);
  }
}
.cr-flail {
  width: 100%;
  height: 100%;
  animation: cr-flail 0.12s ease-in-out infinite alternate, cr-tumble 1s linear forwards;
}
.cr-flail svg {
  width: 100%;
  height: 100%;
}
/* Fast wobble = the chicken kicking and flapping in the air. */
@keyframes cr-flail {
  from {
    transform: rotate(-28deg) scale(1.08, 0.92);
  }
  to {
    transform: rotate(28deg) scale(0.92, 1.08) scaleX(-1);
  }
}
@keyframes cr-tumble {
  to {
    filter: drop-shadow(0 0 0 transparent) brightness(1.1);
  }
}
.cr-speed {
  position: absolute;
  inset: -30%;
  border-radius: 50%;
  background: repeating-conic-gradient(rgba(255, 255, 255, 0.55) 0 4deg, transparent 4deg 26deg);
  -webkit-mask: radial-gradient(circle, transparent 35%, #000 40%, transparent 70%);
  mask: radial-gradient(circle, transparent 35%, #000 40%, transparent 70%);
  animation: bw-burst 0.5s linear infinite;
  opacity: 0.6;
}


/* ---------- Golden clover in case battles ---------- */
.battle-clover {
  position: absolute;
  left: 50%;
  top: 30%;
  z-index: 10;
  padding: 6px 16px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffe27a, #e0a01a);
  color: #3a2000;
  font-weight: 900;
  font-size: 15px;
  letter-spacing: 0.08em;
  white-space: nowrap;
  box-shadow: 0 0 30px rgba(255, 210, 61, 0.8);
  transform: translateX(-50%);
  animation: bonk-in 0.5s cubic-bezier(0.2, 1.8, 0.4, 1);
  pointer-events: none;
}
@keyframes bonk-in {
  from {
    transform: translateX(-50%) scale(0.2) rotate(-12deg);
  }
}
.cell-clover {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 22px;
  height: 22px;
  filter: drop-shadow(0 0 6px #ffd23d);
}
.reel-cell {
  position: relative;
}

/* ---------- Chicken Road canvas edition ---------- */
.stage-chicken {
  background: linear-gradient(180deg, #0f1a12, #0a110c) !important;
}
.cr2-wrap {
  position: relative;
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.4), 0 18px 40px rgba(0, 0, 0, 0.5);
}
.cr2-canvas {
  display: block;
  width: 100%;
}
.cr2-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.cr2-go {
  min-width: 220px;
  min-height: 54px;
  font-size: 18px;
  font-weight: 900;
  border-radius: 16px;
  background: linear-gradient(180deg, #5fffbd, #1fbf7a 60%, #138a57) !important;
  color: #04261a !important;
  box-shadow: 0 6px 0 #0b5a3a, 0 0 24px rgba(46, 229, 157, 0.4);
  transition: transform 0.1s, box-shadow 0.1s;
}
.cr2-go:active:not(:disabled) {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #0b5a3a;
}
.cr2-go:disabled {
  filter: grayscale(0.7) brightness(0.7);
}
.cr2-next {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
}
.cr2-next .red {
  color: #ff6b81;
}

/* ---------- Site polish: page fade, mobile game order, badges, continue row, stats ---------- */
#view > * {
  animation: page-in 0.35s ease-out backwards;
}
#view > *:nth-child(2) {
  animation-delay: 0.04s;
}
#view > *:nth-child(3) {
  animation-delay: 0.08s;
}
@keyframes page-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}
/* On phones the game itself comes first, the bet panel right under it. */
@media (max-width: 860px) {
  .game-cols {
    display: flex !important;
    flex-direction: column-reverse;
  }
  .game-cols > .stage {
    width: 100%;
  }
}
.gc-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 4;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.1em;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}
.gc-badge.new {
  background: linear-gradient(180deg, #5fffbd, #1fbf7a);
  color: #04261a;
  animation: gc-pulse 1.6s ease-in-out infinite;
}
.gc-badge.hot {
  background: linear-gradient(180deg, #ffb347, #ff4d2e);
  color: #fff;
}
@keyframes gc-pulse {
  50% {
    box-shadow: 0 0 16px rgba(46, 229, 157, 0.8);
  }
}
.continue {
  margin: 18px 0 6px;
}
.continue h2 {
  margin-bottom: 10px;
}
.continue-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin;
}
.continue-card {
  position: relative;
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 220px;
  padding: 8px 12px 8px 8px;
  border-radius: 16px;
  background: linear-gradient(90deg, color-mix(in srgb, var(--glow, #f2c44a) 18%, #161a22), #12151b);
  border: 1px solid color-mix(in srgb, var(--glow, #f2c44a) 35%, transparent);
  color: #fff;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  animation: page-in 0.4s ease-out calc(var(--i) * 0.05s) backwards;
}
.continue-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px color-mix(in srgb, var(--glow, #f2c44a) 30%, transparent);
}
.continue-art {
  flex: none;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  overflow: hidden;
}
.continue-art svg {
  width: 100%;
  height: 100%;
}
.continue-card b {
  flex: 1;
  font-size: 15px;
}
.continue-play {
  padding: 4px 10px;
  border-radius: 999px;
  background: #f2c44a;
  color: #1a1200;
  font-size: 12px;
  font-weight: 900;
}
.stats-panel .st-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.st-tile {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.st-tile > span {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.st-tile b {
  font-size: 20px;
}
.st-tile.gold b {
  color: #ffd23d;
}
.st-tile.up {
  border-color: rgba(46, 229, 157, 0.35);
}
.st-tile.down {
  border-color: rgba(255, 77, 109, 0.35);
}
.st-game {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
}
.st-thumb {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  overflow: hidden;
}
.st-thumb svg {
  width: 100%;
  height: 100%;
}
/* Nicer scrollbars everywhere. */
* {
  scrollbar-color: rgba(242, 196, 74, 0.35) transparent;
}
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-thumb {
  background: rgba(242, 196, 74, 0.3);
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover {
  background-color: rgba(242, 196, 74, 0.55);
}
/* Keyboard focus that is easy to see. */
:focus-visible {
  outline: 2px solid #f2c44a;
  outline-offset: 2px;
}

/* ---------- Provably fair page ---------- */
.fair-intro {
  max-width: 820px;
}
.fair-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}
.fair-grid .fair-card:last-child {
  grid-column: 1 / -1;
}
.fair-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 12px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.fair-row span {
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
}
.fair-row code {
  max-width: 100%;
  overflow-wrap: anywhere;
  font-size: 12px;
  color: #ffd23d;
}
.fair-inputs {
  display: grid;
  grid-template-columns: 2fr 1fr 110px auto;
  gap: 8px;
  margin-bottom: 10px;
}
@media (max-width: 700px) {
  .fair-inputs {
    grid-template-columns: 1fr;
  }
}
.fair-note {
  margin-top: 10px;
  font-size: 12px;
}

/* ---------- Public profile + achievements ---------- */
.pf-modal {
  width: min(520px, 100%);
}
.pf-top {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 14px;
}
.pf-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}
.pf-stats div {
  display: flex;
  flex-direction: column;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}
.pf-stats > div > span {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.pf-stats b {
  font-size: 16px;
}
.ach {
  margin: 14px 0;
}
.ach-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}
.ach-head b {
  color: #f2c44a;
  letter-spacing: 0.06em;
}
.ach-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
}
.ach-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  opacity: 0.55;
}
.ach-item small {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
}
.ach-ico {
  width: 22px;
  height: 22px;
  color: rgba(255, 255, 255, 0.5);
}
.ach-item.done {
  opacity: 1;
  border-color: rgba(242, 196, 74, 0.5);
  background: linear-gradient(160deg, rgba(242, 196, 74, 0.16), rgba(255, 255, 255, 0.02));
}
.ach-item.done .ach-ico {
  color: #ffd23d;
  filter: drop-shadow(0 0 6px rgba(255, 210, 61, 0.6));
}

/* ---------- Chat moderation buttons ---------- */
.chat-mod {
  display: inline-flex;
  gap: 2px;
  margin-left: auto;
  opacity: 0.4;
  transition: opacity 0.2s;
}
.chat-msg:hover .chat-mod {
  opacity: 1;
}
.chat-mod button {
  padding: 0 4px;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 12px;
}

/* ---------- Settings ---------- */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}
.settings-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.settings-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  transition: background 0.2s;
}
.settings-link:hover {
  background: rgba(255, 255, 255, 0.05);
}
.settings-link div {
  display: flex;
  flex-direction: column;
}

/* ---------- Daily missions ---------- */
.ms-panel {
  margin-bottom: 18px;
  border: 1px solid rgba(242, 196, 74, 0.25);
}
.ms-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}
.ms-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}
.ms-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.ms-item.done {
  border-color: #2ee59d;
  box-shadow: 0 0 18px rgba(46, 229, 157, 0.25);
}
.ms-item.claimed {
  opacity: 0.55;
}
.ms-text {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.ms-reward {
  color: #ffd23d;
  font-weight: 900;
  white-space: nowrap;
}
.ms-foot {
  display: flex;
  align-items: center;
  gap: 10px;
}
.ms-foot .btn {
  margin-left: auto;
}
.ms-go {
  color: #f2c44a;
  font-weight: 800;
  text-decoration: none;
}

/* ===== Settings v2, profile fit, calm mode ===== */
/* Profile: never taller than the screen, compact achievements. */
.pf-modal {
  max-height: 90vh;
  overflow-y: auto;
  padding-bottom: 16px;
}
.pf-modal .ach-grid {
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.pf-modal .ach-item {
  padding: 6px 8px;
}
.pf-modal .ach-item b {
  font-size: 12px;
}
.pf-modal .ach-item small {
  display: none;
}
.pf-modal .ach-ico {
  width: 16px;
  height: 16px;
}
@media (max-width: 520px) {
  .pf-modal .ach-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
.chat-mod {
  opacity: 0.85 !important;
}
.set-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 16px;
  align-items: start;
}
.set-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.set-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.set-row:last-child {
  border-bottom: none;
}
.set-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.set-text span {
  font-size: 12px;
}
.set-switch {
  position: relative;
  flex: none;
  cursor: pointer;
}
.set-seg button {
  padding: 6px 12px;
  font-size: 12px;
}
.set-vol-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 180px;
}
.set-vol {
  min-width: 42px;
  text-align: right;
  color: #ffd23d;
}
.set-pw {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
/* Calm mode: decorations stand still (game results and needed motion stay). */
body.calm .home-land,
body.calm .game-card .card-rays,
body.calm .card-stars,
body.calm .gc-badge,
body.calm .case-card .chest-hero,
body.calm .game-cols > .controls .btn-block::after {
  animation: none !important;
}
body.calm #view > * {
  animation: none !important;
}
/* Compact cards on the home page. */
body.compact-cards .game-grid {
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)) !important;
}
.set-switch {
  display: inline-flex;
}
.set-switch .bswitch {
  display: block;
  width: 44px;
  height: 24px;
}
.set-switch .bswitch::after {
  width: 18px;
  height: 18px;
}
.set-switch .bswitch-input:checked + .bswitch {
  background: #2ee59d;
}
.set-switch .bswitch-input:checked + .bswitch::after {
  transform: translateX(20px);
}

/* ===== Case battle create menu: calmer type ===== */
.bcreate-side .bcreate-label {
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  color: rgba(242, 196, 74, 0.85) !important;
}
.bcreate-side .bopt b,
.bcreate-side .bopt strong {
  font-size: 18px !important;
  font-weight: 700 !important;
}
.bcreate-side .bopt span {
  font-size: 10px !important;
  font-weight: 600 !important;
  letter-spacing: 0.08em !important;
}
.bcreate-side .bmode b,
.bcreate-side .btoggle b {
  font-size: 13px !important;
  font-weight: 700 !important;
  letter-spacing: 0.02em !important;
}
.bcreate-side .bmode span:not(.icon),
.bcreate-side .btoggle div span {
  font-size: 12px !important;
  font-weight: 400 !important;
}
.bcreate-side .bmode,
.bcreate-side .btoggle,
.bcreate-side .bopt {
  border-width: 1px !important;
}
.bcreate-head .display-title {
  font-weight: 800;
}

/* ===== Daily missions: reward explained ===== */
.ms-explain {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin: 6px 0 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(90deg, rgba(242, 196, 74, 0.12), rgba(46, 229, 157, 0.08));
  border: 1px solid rgba(242, 196, 74, 0.25);
}
.ms-explain-text {
  display: flex;
  flex-direction: column;
  flex: 1 1 260px;
}
.ms-explain-text b {
  color: #ffd23d;
  font-size: 16px;
}
.ms-ex-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.ms-ex {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 110px;
  padding: 8px 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.3);
}
.ms-ex span {
  font-size: 11px;
}
.ms-ex b {
  color: #2ee59d;
  font-size: 16px;
}
.ms-calc {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 10px;
  font-size: 12px;
}
.ms-boost {
  padding: 1px 8px;
  border-radius: 999px;
  background: #2ee59d;
  color: #04261a;
  font-weight: 900;
  font-size: 11px;
}
.ms-reward.boosted {
  color: #2ee59d;
  text-shadow: 0 0 10px rgba(46, 229, 157, 0.6);
}

/* ===== Rain pool card v2: falling drops, glowing pool, countdown ring ===== */
.rain-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(90, 169, 255, 0.35) !important;
  background: radial-gradient(120% 70% at 50% 0%, rgba(59, 130, 246, 0.28), transparent 70%), linear-gradient(180deg, #121a2c, #0d1220) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.rain-card > *:not(.rain-fx) {
  position: relative;
  z-index: 1;
}
.rain-fx {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.rain-fx i {
  position: absolute;
  top: -20px;
  width: 2px;
  height: 14px;
  border-radius: 2px;
  background: linear-gradient(180deg, transparent, rgba(140, 200, 255, 0.7));
  animation: rain-drop 1.6s linear infinite;
}
.rain-fx i.coin {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 60%, #b9680a);
  box-shadow: 0 0 6px rgba(255, 194, 61, 0.7);
}
@keyframes rain-drop {
  to {
    transform: translateY(330px);
  }
}
.rain-card .rain-head {
  letter-spacing: 0.14em;
  color: #9fd0ff !important;
}
.rain-card .rain-pool {
  justify-content: center;
  font-size: 30px !important;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 0 18px rgba(90, 169, 255, 0.8);
  animation: rain-glow 2.4s ease-in-out infinite alternate;
}
@keyframes rain-glow {
  to {
    text-shadow: 0 0 28px rgba(255, 210, 61, 0.9);
  }
}
.rain-ring {
  --p: 1;
  display: grid;
  place-items: center;
  width: 108px;
  height: 108px;
  margin: 4px auto;
  border-radius: 50%;
  background: radial-gradient(circle, #0d1220 58%, transparent 60%), conic-gradient(#5aa9ff calc(var(--p) * 360deg), rgba(255, 255, 255, 0.08) 0);
  box-shadow: 0 0 22px rgba(90, 169, 255, 0.35);
}
.rain-ring .rain-countdown {
  font-size: 22px !important;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  color: #fff;
}
.rain-card .rain-meta,
.rain-card .rain-next {
  text-align: center;
}
.rain-card.window-open {
  border-color: #2ee59d !important;
}
.rain-card.window-open .rain-ring {
  background: radial-gradient(circle, #0d1220 58%, transparent 60%), conic-gradient(#2ee59d calc(var(--p) * 360deg), rgba(255, 255, 255, 0.08) 0);
  box-shadow: 0 0 30px rgba(46, 229, 157, 0.55);
}
.rain-card.window-open .rain-actions .btn:first-child {
  background: linear-gradient(180deg, #5fffbd, #1fbf7a) !important;
  color: #04261a !important;
  box-shadow: 0 0 20px rgba(46, 229, 157, 0.6);
  animation: bw-go 0.9s ease-in-out infinite alternate;
}
body.calm .rain-fx {
  display: none;
}

/* ===== Settings v3: hero card, coloured sections ===== */
.set-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 16px;
  padding: 18px 20px;
  border-radius: 20px;
  background: radial-gradient(120% 140% at 0% 0%, rgba(242, 196, 74, 0.18), transparent 60%), linear-gradient(180deg, #1a1d25, #12141a);
  border: 1px solid rgba(242, 196, 74, 0.25);
}
.set-hero-text {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.set-hero-text b {
  font-size: 22px;
}
.set-hero-text .progress {
  max-width: 320px;
}
.set-card {
  border-top: 3px solid var(--sc) !important;
  transition: transform 0.2s, box-shadow 0.2s;
}
.set-card:hover {
  box-shadow: 0 12px 30px color-mix(in srgb, var(--sc) 18%, transparent);
}
.set-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 800;
}
.set-ico {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 6px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--sc) 18%, transparent);
  color: var(--sc);
}
.set-ico svg {
  width: 100%;
  height: 100%;
}
.set-row {
  padding: 12px 8px !important;
  border-radius: 10px;
  transition: background 0.15s;
}
.set-row:hover {
  background: rgba(255, 255, 255, 0.03);
}
.set-switch .bswitch-input:checked + .bswitch {
  background: var(--sc, #2ee59d) !important;
}
.set-seg button.active {
  background: var(--sc, #f2c44a) !important;
  color: #111 !important;
}

/* ===== Hall of fame (Races page) ===== */
.hof { margin-top: 22px; padding: 18px; }
.hof-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.hof-head h2 { margin: 0; font-size: 1.2rem; }
.hof-list { display: grid; gap: 8px; }
.hof-row { display: grid; grid-template-columns: 30px 34px 1fr auto auto; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 14px; background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.06); transition: transform .15s, background .15s; }
.hof-row:hover { transform: translateX(3px); background: rgba(255,255,255,.06); }
.hof-who { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
.hof-who .muted { font-size: .78rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hof-rank { font-weight: 800; text-align: center; color: var(--muted, #9aa3b2); }
.hof-mult { font-weight: 700; font-size: .85rem; padding: 3px 9px; border-radius: 999px; background: rgba(242,196,74,.14); color: #f2c44a; }
.hof-win { font-weight: 800; color: #2ee59d; white-space: nowrap; }
.hof-row.top { border-color: rgba(242,196,74,.35); background: linear-gradient(90deg, rgba(242,196,74,.12), rgba(255,255,255,.02)); }
.hof-row.p1 { box-shadow: 0 0 22px rgba(242,196,74,.18); }
.hof-row.p1 .hof-rank { color: #ffd23d; }
.hof-row.p2 .hof-rank { color: #d7dde8; }
.hof-row.p3 .hof-rank { color: #ff9a3d; }
@media (max-width: 560px) { .hof-row { grid-template-columns: 22px 30px 1fr auto; } .hof-mult { display: none; } }

/* ===== Hall of Fame page ===== */
.hf-hero { display: flex; align-items: center; gap: 16px; padding: 22px; border-radius: 20px; margin-bottom: 18px; background: radial-gradient(120% 140% at 0% 0%, rgba(255,210,61,.22), transparent 60%), linear-gradient(135deg, #1d1a12, #121418); border: 1px solid rgba(255,210,61,.25); }
.hf-hero h1 { margin: 0 0 4px; }
.hf-hero p { margin: 0; max-width: 560px; }
.hf-trophy { width: 64px; height: 64px; flex: none; display: grid; place-items: center; border-radius: 18px; color: #3a2000; background: linear-gradient(180deg, #ffe27a, #e0a01a); box-shadow: 0 0 34px rgba(255,210,61,.45); }
.hf-trophy svg { width: 36px; height: 36px; }
.hf-prizes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 22px; }
.hf-prize-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 16px; background: rgba(255,255,255,.04); border: 1px solid var(--pc, #ffd23d); box-shadow: inset 0 0 24px color-mix(in srgb, var(--pc, #ffd23d) 14%, transparent); }
.hf-prize-card div { display: flex; flex-direction: column; gap: 2px; }
.hf-prize-card .muted { font-size: .8rem; }
.p1 { --pc: #ffd23d; } .p2 { --pc: #d7dde8; } .p3 { --pc: #e0975a; }
.hf-podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 14px; margin-bottom: 18px; }
.hf-place { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 26px 12px 0; border-radius: 20px 20px 0 0; background: linear-gradient(180deg, color-mix(in srgb, var(--pc) 16%, transparent), rgba(255,255,255,.02)); border: 1px solid color-mix(in srgb, var(--pc) 45%, transparent); border-bottom: none; }
.hf-place.p1 { padding-top: 34px; box-shadow: 0 -10px 40px rgba(255,210,61,.18); }
.hf-place.empty { opacity: .6; }
.hf-av { margin-bottom: 8px; }
.hf-win { font-weight: 800; color: #2ee59d; }
.hf-game { font-size: .8rem; }
.hf-prize { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; color: var(--pc); background: rgba(0,0,0,.35); border: 1px solid color-mix(in srgb, var(--pc) 40%, transparent); }
.hf-prize .icon { width: 14px; height: 14px; }
.hf-step { align-self: stretch; margin: 10px -12px 0; height: 46px; display: grid; place-items: center; font-weight: 900; font-size: 1.6rem; color: #1a1306; background: linear-gradient(180deg, var(--pc), color-mix(in srgb, var(--pc) 55%, #000)); }
.hf-place.p1 .hf-step { height: 70px; }
.hf-place.p3 .hf-step { height: 34px; }
@media (max-width: 720px) { .hf-prizes { grid-template-columns: 1fr; } .hf-podium { grid-template-columns: 1fr; } .hf-place .hf-step { height: 28px !important; } }
header nav a, header nav .nav-btn { white-space: nowrap; }
.hf-prize-card { gap: 22px; padding-left: 22px; }

/* ===== Surprise pack: favorites, lucky, champion, quick search, snow ===== */
.gc-fav { position: absolute; top: 8px; right: 8px; z-index: 3; width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: rgba(8,10,14,.55); color: rgba(255,255,255,.55); font-size: 16px; line-height: 1; cursor: pointer; opacity: 0; transition: opacity .15s, transform .15s, color .15s; }
.game-card:hover .gc-fav, .game-card:focus-within .gc-fav, .gc-fav.on, .gc-fav:focus-visible { opacity: 1; }
.gc-fav:hover { transform: scale(1.12); }
.gc-fav.on { color: #ffd23d; border-color: rgba(255,210,61,.6); text-shadow: 0 0 10px rgba(255,210,61,.8); }
@media (hover: none) { .gc-fav { opacity: 1; } }
.lucky-btn { white-space: nowrap; }
.champ-banner { display: flex; align-items: center; gap: 14px; margin: 14px 0; padding: 10px 16px; border-radius: 16px; color: inherit; text-decoration: none; background: linear-gradient(90deg, rgba(255,210,61,.16), rgba(255,210,61,.03) 60%, transparent); border: 1px solid rgba(255,210,61,.3); transition: transform .15s, box-shadow .15s; }
.champ-banner:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(255,210,61,.15); }
.champ-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.champ-label { font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #ffd23d; }
.champ-win { color: #2ee59d; font-weight: 700; }
.champ-cta { font-weight: 700; font-size: .85rem; padding: 6px 12px; border-radius: 999px; background: rgba(255,210,61,.15); color: #ffd23d; white-space: nowrap; }
@media (max-width: 560px) { .champ-cta { display: none; } }
.qs-back { position: fixed; inset: 0; z-index: 9000; display: flex; justify-content: center; align-items: flex-start; padding: 12vh 16px 16px; background: rgba(4,6,10,.6); backdrop-filter: blur(6px); animation: qs-in .15s ease-out; }
@keyframes qs-in { from { opacity: 0; } }
.qs-box { width: min(560px, 100%); border-radius: 18px; overflow: hidden; background: #15171d; border: 1px solid rgba(255,255,255,.1); box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.qs-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.08); }
.qs-head .icon { width: 18px; height: 18px; opacity: .7; }
.qs-input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: inherit; font: inherit; font-size: 1.05rem; }
.qs-head kbd, .set-kbd { font: 700 .72rem system-ui, sans-serif; padding: 3px 7px; border-radius: 6px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); }
.qs-list { max-height: 60vh; overflow-y: auto; padding: 6px; }
.qs-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 10px; border: 0; border-radius: 12px; background: none; color: inherit; text-align: left; cursor: pointer; }
.qs-item.active, .qs-item:hover { background: rgba(255,210,61,.1); }
.qs-art { width: 34px; height: 46px; flex: none; border-radius: 7px; overflow: hidden; }
.qs-art svg { width: 100%; height: 100%; }
.qs-ico { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border-radius: 10px; background: rgba(255,255,255,.06); }
.qs-ico svg { width: 18px; height: 18px; }
.qs-text { display: flex; flex-direction: column; min-width: 0; }
.qs-text .muted { font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qs-empty { padding: 14px; }
.snow-layer { position: fixed; inset: 0; z-index: 40; pointer-events: none; }
/* Favorite star v2: real star icon, pop + sparkles on click */
.gc-fav { display: grid; place-items: center; padding: 0; overflow: visible; color: rgba(255,255,255,.7); }
.gc-fav svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; transition: fill .2s; }
.gc-fav.on { background: linear-gradient(180deg, rgba(255,210,61,.28), rgba(255,160,20,.18)); }
.gc-fav.on svg { fill: #ffd23d; stroke: #ffb020; filter: drop-shadow(0 0 6px rgba(255,210,61,.9)); }
.gc-fav.pop { animation: fav-pop .45s cubic-bezier(.2,1.8,.4,1); }
@keyframes fav-pop { 0% { transform: scale(.6); } 60% { transform: scale(1.35) rotate(-12deg); } 100% { transform: scale(1); } }
.fav-spark { position: absolute; left: 50%; top: 50%; width: 5px; height: 5px; margin: -2.5px; border-radius: 50%; background: #ffd23d; box-shadow: 0 0 6px #ffd23d; pointer-events: none; animation: fav-spark .6s ease-out forwards; }
@keyframes fav-spark { from { transform: rotate(var(--a)) translateY(0) scale(1); opacity: 1; } to { transform: rotate(var(--a)) translateY(-26px) scale(.2); opacity: 0; } }

/* ===== Surprise pack 2 ===== */
.emoji-toggle { font-size: 18px; line-height: 1; }
.emoji-pop { position: absolute; bottom: calc(100% + 6px); left: 0; right: 0; z-index: 30; display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; padding: 8px; border-radius: 14px; background: #171a20; border: 1px solid rgba(255,255,255,.1); box-shadow: 0 16px 40px rgba(0,0,0,.5); animation: qs-in .12s ease-out; }
.emoji-pop[hidden] { display: none; }
.emoji-btn { aspect-ratio: 1; border: 0; border-radius: 8px; background: none; font-size: 18px; cursor: pointer; color: #fff; font-weight: 800; transition: transform .1s, background .1s; }
.emoji-btn:hover { background: rgba(255,255,255,.08); transform: scale(1.18); }
.avatar-slot { position: relative; display: inline-grid; place-items: center; padding: 3px; border-radius: 50%; background: conic-gradient(#ffd23d var(--xp, 0%), rgba(255,255,255,.12) 0); }
.avatar-slot > .av { box-shadow: 0 0 0 2px #121418; border-radius: 50%; }
.visit-line { font-size: .85rem; margin: -2px 0 6px; }
.game-card.gotd { box-shadow: 0 0 0 2px #ffd23d, 0 0 28px rgba(255,210,61,.45); animation: gotd-glow 2.4s ease-in-out infinite; }
@keyframes gotd-glow { 50% { box-shadow: 0 0 0 2px #ffe27a, 0 0 42px rgba(255,210,61,.7); } }
.gc-badge.gotd-badge { background: linear-gradient(180deg, #ffe27a, #e0a01a); color: #3a2000; font-size: 9px; letter-spacing: .06em; }
.hf-me { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; padding: 14px 18px; border-radius: 16px; background: rgba(46,229,157,.07); border: 1px solid rgba(46,229,157,.3); }
.hf-me > .icon { width: 22px; height: 22px; color: #2ee59d; flex: none; }
.hf-me div { display: flex; flex-direction: column; gap: 2px; }
body.calm .game-card.gotd { animation: none; }
.game-card .gc-fav svg { position: static; inset: auto; display: block; width: 17px; height: 17px; margin: 0; transform: none; }

/* ===== Mega surprise update ===== */
.game-card.lucky-hl { box-shadow: 0 0 0 3px var(--gold-2), 0 0 36px var(--gold-2); transform: translateY(-4px) scale(1.03); z-index: 2; }
.game-card.lucky-win { animation: lucky-win .6s ease-out; }
@keyframes lucky-win { 30% { transform: scale(1.12); } 100% { transform: scale(1.04); } }
.kb-box { padding-bottom: 8px; }
.kb-box .qs-head { justify-content: space-between; }
.kb-box .spacer { flex: 1; }
.kb-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 16px; border-bottom: 1px solid rgba(255,255,255,.05); }
.kb-row:last-child { border-bottom: 0; }
.kb-keys { display: inline-flex; gap: 4px; }
.kb-keys kbd { font: 700 .75rem system-ui, sans-serif; min-width: 24px; text-align: center; padding: 3px 7px; border-radius: 6px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-bottom-width: 2px; }
#chat-log .mention, .chat-log .mention { position: relative; border-radius: 12px; background: rgba(242,196,74,.1); box-shadow: inset 3px 0 0 var(--gold-2); }
.hf-tabs { margin-bottom: 14px; }
.hof-mult.big { font-size: 1rem; padding: 4px 12px; }
.accent-pick { display: flex; gap: 8px; flex-wrap: wrap; }
.accent-dot { width: 26px; height: 26px; border-radius: 50%; border: 2px solid transparent; background: var(--dot); cursor: pointer; box-shadow: 0 0 0 2px rgba(0,0,0,.4) inset; transition: transform .15s; }
.accent-dot:hover { transform: scale(1.12); }
.accent-dot.active { border-color: #fff; box-shadow: 0 0 14px var(--dot); }
.st-share { margin-left: auto; }
.panel-title:has(.st-share) { display: flex; align-items: center; gap: 8px; }
:root[data-accent="emerald"] { --gold: #2fbf7f; --gold-2: #4ee6a0; --gold-dark: #16774c; --gold-soft: rgba(78,230,160,.14); }
:root[data-accent="ruby"] { --gold: #e8475f; --gold-2: #ff5c7a; --gold-dark: #8f1f33; --gold-soft: rgba(255,92,122,.14); }
:root[data-accent="sapphire"] { --gold: #3f8fe6; --gold-2: #5aa9ff; --gold-dark: #1f5596; --gold-soft: rgba(90,169,255,.14); }
:root[data-accent="amethyst"] { --gold: #9a6cf0; --gold-2: #b388ff; --gold-dark: #5a35a0; --gold-soft: rgba(179,136,255,.14); }
:root[data-accent="sunset"] { --gold: #f07f22; --gold-2: #ff9a3d; --gold-dark: #9a4a0c; --gold-soft: rgba(255,154,61,.14); }

/* ===== Lucky spin: everything dark, a spotlight runs, the pick lights up ===== */
.game-grid.lucky-mode .game-card { filter: brightness(.28) saturate(.6); transition: filter .12s, transform .12s, box-shadow .12s; }
.game-grid.lucky-mode .game-card.lucky-hl { filter: brightness(1.25) saturate(1.2); box-shadow: 0 0 0 3px var(--gold-2), 0 0 50px var(--gold-2), 0 0 120px color-mix(in srgb, var(--gold-2) 50%, transparent); transform: translateY(-6px) scale(1.06); z-index: 3; }
.game-grid.lucky-mode .game-card.lucky-win { filter: brightness(1.45) saturate(1.3); animation: lucky-flash .65s ease-out; }
@keyframes lucky-flash { 0% { transform: scale(1.06); } 35% { transform: scale(1.18); box-shadow: 0 0 0 5px #fff, 0 0 90px #fff, 0 0 180px var(--gold-2); } 100% { transform: scale(1.1); } }

/* ===== Personal record show ===== */
.rec-show { position: fixed; inset: 0; z-index: 9500; display: grid; place-items: center; overflow: hidden; cursor: pointer; background: radial-gradient(circle at 50% 42%, rgba(70,45,0,.75), rgba(0,0,0,.92) 70%); animation: rec-in .35s ease-out; }
.rec-show.out { animation: rec-out .4s ease-in forwards; }
@keyframes rec-in { from { opacity: 0; } }
@keyframes rec-out { to { opacity: 0; transform: scale(1.05); } }
.rec-rays { position: absolute; width: 180vmax; height: 180vmax; left: 50%; top: 42%; margin: -90vmax 0 0 -90vmax; background: repeating-conic-gradient(from 0deg, rgba(255,210,61,.16) 0 6deg, transparent 6deg 18deg); animation: rec-spin 18s linear infinite; mask: radial-gradient(circle, #000 0, transparent 60%); }
@keyframes rec-spin { to { transform: rotate(360deg); } }
.rec-ring { position: absolute; left: 50%; top: 42%; width: 40px; height: 40px; margin: -20px; border-radius: 50%; border: 4px solid #ffd23d; animation: rec-ring 1.4s .5s ease-out forwards; opacity: 0; }
@keyframes rec-ring { 0% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(40); } }
.rec-core { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 0 16px; }
.rec-trophy { width: 150px; height: 150px; filter: drop-shadow(0 0 40px rgba(255,210,61,.8)); animation: rec-slam .9s cubic-bezier(.2,1.6,.4,1) both, rec-float 3s 1s ease-in-out infinite; }
.rec-trophy svg { width: 100%; height: 100%; }
@keyframes rec-slam { 0% { transform: scale(4) rotate(-25deg); opacity: 0; } 60% { opacity: 1; } 100% { transform: scale(1) rotate(0); } }
@keyframes rec-float { 50% { transform: translateY(-8px) rotate(2deg); } }
.rec-kicker { margin-top: 6px; font: 900 1rem system-ui, sans-serif; letter-spacing: .5em; color: #fff; padding: 4px 14px 4px 20px; border-radius: 999px; background: #e11d48; box-shadow: 0 0 24px #e11d48; animation: rec-pop .4s .5s both; }
.rec-title { display: flex; flex-wrap: wrap; justify-content: center; font: 900 clamp(2rem, 7vw, 4.6rem)/1 system-ui, sans-serif; letter-spacing: .02em; }
.rec-title span { display: inline-block; background: linear-gradient(180deg, #fffbe0, #ffd23d 50%, #c07a0e); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 4px 0 #5a3300) drop-shadow(0 0 18px rgba(255,210,61,.6)); animation: rec-letter .5s calc(.6s + var(--i) * .04s) cubic-bezier(.2,1.8,.4,1) both; }
@keyframes rec-letter { from { transform: translateY(60px) scale(.3); opacity: 0; } }
.rec-label { margin-top: 8px; font-weight: 800; letter-spacing: .25em; text-transform: uppercase; color: rgba(255,255,255,.75); animation: rec-pop .4s 1.1s both; }
.rec-old { color: rgba(255,255,255,.45); text-decoration: line-through; font-weight: 700; animation: rec-pop .4s 1.2s both; }
.rec-num { font: 900 clamp(2.4rem, 8vw, 5rem)/1.1 system-ui, sans-serif; color: #2ee59d; text-shadow: 0 0 30px rgba(46,229,157,.6); animation: rec-pop .4s .9s both; }
.rec-num.done { animation: rec-boom .6s ease-out; }
@keyframes rec-boom { 30% { transform: scale(1.35); text-shadow: 0 0 60px #2ee59d, 0 0 120px #fff; } }
@keyframes rec-pop { from { transform: scale(.4); opacity: 0; } }
.rec-tap { margin-top: 14px; font-size: .8rem; color: rgba(255,255,255,.4); animation: rec-pop .4s 2.6s both; }

/* ===== Admin animation preview ===== */
.anim-panel { margin-top: 18px; }
.anim-group { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid rgba(255,255,255,.06); }
.anim-btns { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.anim-btns select { width: auto; min-width: 160px; }
@media (max-width: 560px) { .anim-group { grid-template-columns: 1fr; } }

/* ===== Nice win v2 ===== */
.nice-show { position: fixed; left: 50%; top: 26vh; z-index: 9600; transform: translateX(-50%); pointer-events: none; }
.nice-show.out { animation: ns-out .4s ease-in forwards; }
@keyframes ns-out { to { opacity: 0; transform: translateX(-50%) translateY(-30px) scale(.9); } }
.ns-card { position: relative; overflow: visible; padding: 16px 34px 18px; border-radius: 22px; text-align: center; background: linear-gradient(160deg, #2a2210, #15120a 70%); border: 2px solid var(--gold-2); box-shadow: 0 0 0 6px rgba(242,196,74,.12), 0 20px 60px rgba(0,0,0,.6), 0 0 50px rgba(242,196,74,.35); animation: ns-drop .55s cubic-bezier(.2,1.6,.4,1) both; }
@keyframes ns-drop { from { transform: translateY(-120px) scale(.6) rotate(-6deg); opacity: 0; } }
.ns-sweep { position: absolute; inset: 0; border-radius: inherit; overflow: hidden; pointer-events: none; }
.ns-sweep::after { content: ''; position: absolute; top: -20%; bottom: -20%; width: 40%; left: -60%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.55), transparent); transform: skewX(-18deg); animation: ns-sweep 1s .45s ease-out; }
@keyframes ns-sweep { to { left: 130%; } }
.ns-title { display: flex; justify-content: center; font: 900 clamp(1.8rem, 5vw, 2.8rem)/1 system-ui, sans-serif; letter-spacing: .04em; }
.ns-title span { display: inline-block; background: linear-gradient(180deg, #fffbe0, #ffd23d 55%, #c07a0e); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 3px 0 #5a3300); animation: ns-letter .45s calc(.15s + var(--i) * .04s) cubic-bezier(.2,1.8,.4,1) both; }
@keyframes ns-letter { from { transform: translateY(30px) scale(.4); opacity: 0; } }
.ns-row { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 10px; }
.ns-mult { font: 900 1rem system-ui, sans-serif; padding: 4px 12px; border-radius: 999px; color: #3a2000; background: linear-gradient(180deg, #ffe27a, #e0a01a); animation: ns-stamp .4s .55s cubic-bezier(.2,2,.4,1) both; }
@keyframes ns-stamp { from { transform: scale(2.4) rotate(-12deg); opacity: 0; } }
.ns-num { font: 900 1.6rem system-ui, sans-serif; color: #2ee59d; text-shadow: 0 0 18px rgba(46,229,157,.6); }
.ns-stars { position: absolute; left: 50%; top: 50%; }
.ns-stars i { position: absolute; width: 10px; height: 10px; margin: -5px; background: #ffd23d; clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: ns-star .9s .35s ease-out both; }
@keyframes ns-star { from { transform: rotate(var(--a)) translateY(0) scale(.2); opacity: 1; } to { transform: rotate(var(--a)) translateY(calc(var(--d) * -1.6)) scale(1.2) rotate(180deg); opacity: 0; } }

/* ===== Free round v2 ===== */
.free-show { position: fixed; inset: 0; z-index: 9400; display: grid; place-items: center; pointer-events: none; background: radial-gradient(circle at 50% 50%, rgba(225,29,72,.18), transparent 55%); animation: rec-in .3s ease-out; }
.free-show.out { animation: rec-out .4s ease-in forwards; }
.fs-glow { position: absolute; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(255,210,61,.55), transparent 65%); opacity: 0; animation: fs-glow .8s .85s ease-out forwards; }
@keyframes fs-glow { to { opacity: 1; transform: scale(1.4); } }
.fs-rays { position: absolute; width: 520px; height: 520px; border-radius: 50%; background: repeating-conic-gradient(rgba(255,210,61,.22) 0 8deg, transparent 8deg 24deg); mask: radial-gradient(circle, #000 0, transparent 65%); opacity: 0; animation: fs-rays 1.6s .85s ease-out forwards, rec-spin 12s linear infinite; z-index: -1; }
@keyframes fs-rays { to { opacity: 1; } }
.fs-box { position: absolute; width: 170px; height: 170px; animation: fs-drop .5s cubic-bezier(.3,1.5,.5,1) both, fs-wobble .35s .5s ease-in-out 2, fs-fade .3s 1.05s forwards; }
.fs-box svg { width: 100%; height: 100%; overflow: visible; }
.fs-lid { transform-box: fill-box; transform-origin: 50% 100%; animation: fs-lid .5s .9s cubic-bezier(.2,1.4,.4,1) forwards; }
@keyframes fs-drop { from { transform: translateY(-60vh); } }
@keyframes fs-wobble { 25% { transform: rotate(-8deg); } 75% { transform: rotate(8deg); } }
@keyframes fs-lid { to { transform: translate(40px, -90px) rotate(35deg); opacity: 0; } }
@keyframes fs-fade { to { transform: scale(.85); opacity: 0; } }
.fs-ticket { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 14px 34px; border-radius: 12px; color: #3a2000; background: linear-gradient(180deg, #fff3b0, #ffc23d 55%, #e0a01a); box-shadow: 0 0 0 3px #8a5a06, 0 0 60px rgba(255,210,61,.7); -webkit-mask: radial-gradient(circle at 0 50%, transparent 10px, #000 11px) left / 51% 100% no-repeat, radial-gradient(circle at 100% 50%, transparent 10px, #000 11px) right / 51% 100% no-repeat; opacity: 0; animation: fs-ticket .7s .95s cubic-bezier(.2,1.6,.4,1) forwards; }
.fs-ticket small { font-weight: 900; font-size: .65rem; letter-spacing: .35em; opacity: .7; }
.fs-ticket b { font: 900 clamp(1.8rem, 5vw, 2.6rem)/1 system-ui, sans-serif; letter-spacing: .03em; }
.fs-ticket span { font-weight: 700; font-size: .85rem; }
@keyframes fs-ticket { 0% { opacity: 0; transform: translateY(40px) scale(.2) rotate(-20deg); } 100% { opacity: 1; transform: translateY(-10px) scale(1) rotate(-3deg); } }

/* ===== Multiplier record: electric purple/cyan instead of gold ===== */
.rec-show.mult { background: radial-gradient(circle at 50% 42%, rgba(60,20,120,.8), rgba(0,0,0,.93) 70%); }
.rec-show.mult .rec-rays { background: repeating-conic-gradient(from 0deg, rgba(94,231,255,.15) 0 4deg, transparent 4deg 12deg, rgba(179,136,255,.15) 12deg 16deg, transparent 16deg 24deg); animation-duration: 9s; }
.rec-show.mult .rec-ring { border-color: #5ee7ff; }
.rec-show.mult .rec-trophy { filter: drop-shadow(0 0 40px rgba(94,231,255,.9)); animation: rec-slam .9s cubic-bezier(.2,1.6,.4,1) both, rec-zap 1.2s 1s steps(2) infinite; }
@keyframes rec-zap { 50% { filter: drop-shadow(0 0 60px #b388ff) brightness(1.4); } }
.rec-show.mult .rec-kicker { background: #7b2dff; box-shadow: 0 0 24px #7b2dff; }
.rec-show.mult .rec-title span { background: linear-gradient(180deg, #ffffff, #5ee7ff 50%, #7b2dff); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 4px 0 #2a0f6e) drop-shadow(0 0 18px rgba(94,231,255,.7)); }
.rec-show.mult .rec-num { color: #5ee7ff; text-shadow: 0 0 30px rgba(94,231,255,.8), 0 0 60px rgba(179,136,255,.6); }
.rec-show.mult .rec-num.done { animation: rec-boom-m .6s ease-out; }
@keyframes rec-boom-m { 30% { transform: scale(1.35); text-shadow: 0 0 60px #5ee7ff, 0 0 120px #b388ff; } }

/* ===== Free round intro (before the game starts) ===== */
.free-show.intro { pointer-events: auto; cursor: pointer; background: radial-gradient(circle at 50% 50%, rgba(225,29,72,.3), rgba(0,0,0,.85) 65%); }
.free-show.intro .fs-ticket { animation: fs-ticket .6s .95s cubic-bezier(.2,1.6,.4,1) forwards, fs-zoom .55s 1.75s cubic-bezier(.6,0,.9,.4) forwards; }
@keyframes fs-zoom { from { opacity: 1; transform: translateY(-10px) rotate(-3deg) scale(1); } to { opacity: 0; transform: translateY(0) rotate(0) scale(9); } }
.fs-go { position: absolute; font: 900 clamp(2.4rem, 9vw, 5.5rem)/1 system-ui, sans-serif; color: #fff; letter-spacing: .04em; text-shadow: 0 0 30px #ffd23d, 0 6px 0 #8a5a06; opacity: 0; animation: fs-go .6s 1.95s cubic-bezier(.2,1.8,.4,1) forwards; }
@keyframes fs-go { from { opacity: 0; transform: scale(.3); } to { opacity: 1; transform: scale(1); } }
.fs-flash { position: absolute; inset: 0; background: #fff; opacity: 0; animation: fs-flash .5s 1.9s ease-out; pointer-events: none; }
@keyframes fs-flash { 0% { opacity: 0; } 20% { opacity: .9; } 100% { opacity: 0; } }
/* Free round: darken the whole screen (both the intro and the after-win fanfare) */
.free-show, .free-show.intro { background: radial-gradient(circle at 50% 50%, rgba(120,10,40,.55), rgba(0,0,0,.88) 60%); backdrop-filter: blur(3px) brightness(.55); }

/* ===== Donut Buddy ===== */
.donut-buddy { position: fixed; right: 18px; bottom: 18px; z-index: 900; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; pointer-events: none; }
.donut-buddy[hidden] { display: none; }
.db-body { pointer-events: auto; width: 74px; height: 74px; padding: 0; border: 0; background: none; cursor: pointer; animation: db-bob 2.6s ease-in-out infinite; filter: drop-shadow(0 8px 14px rgba(0,0,0,.45)); }
.db-body svg { width: 100%; height: 100%; overflow: visible; }
.db-body:hover { transform: scale(1.08) rotate(-4deg); }
@keyframes db-bob { 50% { transform: translateY(-6px); } }
.db-bubble { pointer-events: auto; max-width: 220px; padding: 8px 12px; border-radius: 14px 14px 4px 14px; background: #fff; color: #1d1d1f; font-size: .85rem; font-weight: 700; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.db-bubble.pop { animation: db-pop .3s cubic-bezier(.2,1.8,.4,1); }
@keyframes db-pop { from { transform: scale(.4) translateY(10px); opacity: 0; } }
.db-eyes, .db-mouth, .db-tear { display: none; }
.db-open, .db-m-normal { display: inline; }
.db-pupil { animation: db-blink 4s infinite; transform-box: fill-box; transform-origin: center; }
@keyframes db-blink { 0%, 94%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } }
.mood-happy .db-open, .mood-big .db-open, .mood-happy .db-m-normal, .mood-big .db-m-normal, .mood-sad .db-m-normal, .mood-sleep .db-open, .mood-sleep .db-m-normal { display: none; }
.mood-happy .db-happy-eyes, .mood-big .db-happy-eyes, .mood-happy .db-m-happy, .mood-big .db-m-happy { display: inline; }
.mood-sad .db-m-sad, .mood-sad .db-tear { display: inline; }
.mood-sleep .db-closed, .mood-sleep .db-m-sleep { display: inline; }
.mood-happy .db-body { animation: db-jump .5s ease-out 2; }
@keyframes db-jump { 40% { transform: translateY(-22px) scale(1.06, .94); } 80% { transform: translateY(0) scale(1.1, .9); } }
.mood-big .db-body { animation: db-spin 1s cubic-bezier(.3,1.4,.5,1) 2; filter: drop-shadow(0 0 18px #ffd23d) drop-shadow(0 8px 14px rgba(0,0,0,.45)); }
@keyframes db-spin { 0% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-34px) rotate(200deg) scale(1.15); } 100% { transform: translateY(0) rotate(360deg); } }
.mood-sad .db-body { animation: db-sad 1.2s ease-in-out; }
@keyframes db-sad { 30% { transform: translateY(4px) scale(1.04, .94) rotate(-4deg); } 70% { transform: translateY(4px) rotate(4deg); } }
.mood-sleep .db-body { animation: db-breathe 3.4s ease-in-out infinite; opacity: .85; }
@keyframes db-breathe { 50% { transform: scale(1.04, .97); } }
body.calm .db-body { animation: none; }
@media (max-width: 960px) { .donut-buddy { bottom: 84px; right: 10px; } .db-body { width: 56px; height: 56px; } }

/* ===== Session tracker under every game ===== */
.session-box { margin-top: 14px; padding: 12px 16px; border-radius: 16px; background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.07); }
.ss-stats { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; }
.ss-cell { display: flex; flex-direction: column; gap: 1px; }
.ss-cell span { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted, #9aa3b2); }
.ss-cell b { font-size: 1.05rem; }
.ss-cell b.green { color: #2ee59d; } .ss-cell b.red { color: #ff4d6d; }
.ss-flame { font-weight: 800; color: #ffb020; }
.ss-flame.hot { color: #ff6a1f; text-shadow: 0 0 12px rgba(255,106,31,.8); animation: ss-hot .8s ease-in-out infinite alternate; }
@keyframes ss-hot { to { transform: scale(1.08); } }
.session-box .btn { margin-left: auto; }
.ss-chart { height: 64px; margin-top: 10px; display: grid; place-items: center; }
.ss-chart svg { width: 100%; height: 100%; }
.ss-chart .muted { font-size: .8rem; }

/* ===== Focus mode ===== */
body.focus-mode .main-nav, body.focus-mode .site-footer, body.focus-mode .mega-rain, body.focus-mode .game-head .back-link { display: none !important; }
body.focus-mode .game-cols, body.focus-mode .stage { max-width: none; }
body.focus-mode::after { content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 5; box-shadow: inset 0 0 160px rgba(0,0,0,.7); }
.focus-btn[aria-pressed="true"] { color: var(--gold-2); border-color: var(--gold-2); }

/* ===== Live big wins of other players ===== */
.live-wins { position: fixed; left: 18px; bottom: 18px; z-index: 950; display: flex; flex-direction: column-reverse; gap: 8px; pointer-events: none; }
.live-win { display: flex; align-items: center; gap: 10px; min-width: 230px; padding: 10px 14px; border-radius: 14px; background: rgba(20,22,28,.95); border: 1px solid rgba(46,229,157,.4); box-shadow: 0 10px 30px rgba(0,0,0,.5), 0 0 20px rgba(46,229,157,.15); animation: lw-in .4s cubic-bezier(.2,1.5,.4,1); }
.live-win div { display: flex; flex-direction: column; font-size: .8rem; }
.live-win div span { color: var(--muted, #9aa3b2); }
.lw-amount { margin-left: auto; font-weight: 900; color: #2ee59d; }
.live-win.mega { border-color: rgba(179,136,255,.6); box-shadow: 0 10px 30px rgba(0,0,0,.5), 0 0 26px rgba(179,136,255,.35); }
.live-win.epic { border-color: #ffd23d; box-shadow: 0 10px 30px rgba(0,0,0,.5), 0 0 30px rgba(255,210,61,.45); }
.live-win.out { animation: lw-out .4s ease-in forwards; }
@keyframes lw-in { from { transform: translateX(-120%); } }
@keyframes lw-out { to { transform: translateX(-120%); opacity: 0; } }
@media (max-width: 960px) { .live-wins { bottom: 84px; left: 10px; } .live-win { min-width: 0; } }

/* ===== Home greeting ===== */
.greet { display: flex; align-items: center; gap: 14px; margin: 4px 0 14px; }
.greet-emoji { font-size: 2rem; animation: db-bob 3s ease-in-out infinite; }
.greet div { display: flex; flex-direction: column; }
.greet b { font-size: 1.25rem; }

/* ===== Phone tab bar ===== */
.tab-bar { display: none; }
@media (max-width: 960px) {
  .tab-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 880; display: grid; grid-template-columns: repeat(5, 1fr); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: rgba(12,13,16,.94); backdrop-filter: blur(10px); border-top: 1px solid rgba(255,255,255,.08); }
  .tb-item { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0; border: 0; background: none; color: var(--muted, #9aa3b2); font: 600 .68rem system-ui, sans-serif; text-decoration: none; border-radius: 12px; }
  .tb-item .icon { width: 22px; height: 22px; }
  .tb-item.active { color: var(--gold-2); background: var(--gold-soft); }
  body { padding-bottom: 72px; }
  body.focus-mode .tab-bar { display: none; }
}
/* ===== Unread chat counter ===== */
#chat-toggle { position: relative; }
.chat-unread { position: absolute; top: 2px; right: 50%; transform: translateX(18px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #e11d48; color: #fff; font: 800 .65rem/18px system-ui, sans-serif; font-style: normal; text-align: center; box-shadow: 0 0 0 2px #0c0d10; animation: db-pop .3s cubic-bezier(.2,1.8,.4,1); }
#chat-toggle .chat-unread { top: -4px; right: -4px; transform: none; }
.chat-unread[hidden] { display: none; }
/* ===== Loading skeletons ===== */
.skel-list { display: grid; gap: 10px; }
.skel-row { height: 56px; border-radius: 14px; background: linear-gradient(90deg, rgba(255,255,255,.04) 25%, rgba(255,255,255,.09) 50%, rgba(255,255,255,.04) 75%); background-size: 200% 100%; animation: skel 1.2s linear infinite; }
@keyframes skel { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (max-width: 720px) {
  .hf-place.p1 { order: -1; }
  .hf-tabs { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  .hf-tabs button { font-size: .8rem; white-space: nowrap; padding-inline: 6px; }
}
/* Phones: floating play button while the real one is scrolled away */
.play-fab { display: none; }
@media (max-width: 960px) {
  .play-fab:not([hidden]) { display: block; position: fixed; left: 16px; right: 92px; bottom: 84px; z-index: 870; padding: 14px; font-size: 1rem; box-shadow: 0 10px 30px rgba(0,0,0,.55), 0 0 24px var(--gold-soft); animation: db-pop .25s ease-out; }
  body.focus-mode .play-fab:not([hidden]) { bottom: 16px; }
}

/* ===== Bell: missions + notifications ===== */
.bell-btn { position: relative; }
.bell-btn .icon { width: 20px; height: 20px; }
.bell-dot { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #e11d48; color: #fff; font: 800 .65rem/18px system-ui, sans-serif; font-style: normal; text-align: center; box-shadow: 0 0 0 2px #0c0d10; }
.bell-dot[hidden] { display: none; }
.bell-menu { width: min(360px, calc(100vw - 24px)); padding: 10px; }
.bell-tabs { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 8px; }
.bell-body { display: grid; gap: 8px; max-height: min(60vh, 460px); overflow-y: auto; }
.bell-mission { padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); }
.bell-mission.done { border-color: rgba(46,229,157,.5); background: rgba(46,229,157,.07); }
.bell-mission.claimed { opacity: .55; }
.bm-top { display: flex; justify-content: space-between; gap: 10px; font-size: .85rem; }
.bm-reward { color: #2ee59d; font-weight: 800; white-space: nowrap; }
.bell-mission .progress { margin: 8px 0; }
.bm-foot { display: flex; align-items: center; gap: 8px; font-size: .78rem; }
.bm-foot .btn { margin-left: auto; }
.bm-go { color: var(--gold-2); font-weight: 700; }
.bell-more { display: block; text-align: center; padding: 6px; font-size: .8rem; color: var(--gold-2); }
.bell-note { display: flex; gap: 10px; padding: 10px; border-radius: 12px; color: inherit; text-decoration: none; background: rgba(255,255,255,.02); }
a.bell-note:hover { background: rgba(255,255,255,.06); }
.bell-note.unread { background: var(--gold-soft); box-shadow: inset 3px 0 0 var(--gold-2); }
.bn-ico { width: 30px; height: 30px; flex: none; display: grid; place-items: center; border-radius: 9px; background: rgba(255,255,255,.07); color: var(--gold-2); }
.bn-ico svg { width: 16px; height: 16px; }
.bell-note div { display: flex; flex-direction: column; gap: 1px; min-width: 0; font-size: .82rem; }
.bell-note small { font-size: .7rem; }
.bell-empty { padding: 12px; font-size: .85rem; }
.bell-actions { display: flex; justify-content: space-between; }

/* ===== Achievement unlocked pop-up ===== */
.ach-pop { position: fixed; left: 50%; top: 78px; z-index: 9550; display: flex; align-items: center; gap: 14px; padding: 12px 22px 12px 14px; border-radius: 18px; transform: translateX(-50%); cursor: pointer; background: linear-gradient(135deg, #2a2210, #14110a 70%); border: 2px solid var(--gold-2); box-shadow: 0 18px 50px rgba(0,0,0,.6), 0 0 40px rgba(242,196,74,.3); animation: ach-in .6s cubic-bezier(.2,1.5,.4,1) both; }
.ach-pop.out { animation: ach-out .45s ease-in forwards; }
@keyframes ach-in { from { transform: translateX(-50%) translateY(-140px) scale(.7); opacity: 0; } }
@keyframes ach-out { to { transform: translateX(-50%) translateY(-120px); opacity: 0; } }
.ach-medal { width: 58px; height: 72px; flex: none; animation: ach-spin 1s .25s cubic-bezier(.2,1.4,.4,1) both; filter: drop-shadow(0 0 14px rgba(255,210,61,.7)); }
.ach-medal svg { width: 100%; height: 100%; }
@keyframes ach-spin { from { transform: rotateY(540deg) scale(.4); } }
.ach-text { display: flex; flex-direction: column; gap: 1px; }
.ach-text small { font-weight: 900; font-size: .68rem; letter-spacing: .2em; color: var(--gold-2); }
.ach-text b { font-size: 1.25rem; }
.ach-text span { font-size: .82rem; color: rgba(255,255,255,.75); }
.ach-text em { font-style: normal; font-size: .72rem; color: rgba(255,255,255,.5); }
@media (max-width: 560px) { .ach-pop { left: 12px; right: 12px; transform: none; } @keyframes ach-in { from { transform: translateY(-140px); opacity: 0; } } }
.bm-foot .muted { white-space: nowrap; }
.bell-menu a.bm-go, .bell-menu a.bell-more { display: inline-flex; width: auto; padding: 2px 8px; border-radius: 8px; background: none; }
.bell-menu a.bell-more { display: block; text-align: center; }
.bell-menu a.bell-note { display: flex; padding: 10px; border-radius: 12px; }
.bell-tabs button { white-space: nowrap; }

/* ===== Live bets table (home) ===== */
.live-bets { margin-top: 28px; }
.live-bets .section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.lb-tabs button { display: inline-flex; align-items: center; gap: 6px; }
.lb-dot { width: 8px; height: 8px; border-radius: 50%; background: #2ee59d; box-shadow: 0 0 8px #2ee59d; animation: lb-blink 1.4s ease-in-out infinite; }
@keyframes lb-blink { 50% { opacity: .35; } }
.lb-table { padding: 4px 8px; overflow-x: auto; }
.lb-table table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.lb-table th { text-align: left; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted, #9aa3b2); padding: 10px 8px; }
.lb-table td { padding: 8px; border-top: 1px solid rgba(255,255,255,.05); white-space: nowrap; }
.lb-table .num { text-align: right; }
.lb-game { display: inline-flex; align-items: center; gap: 8px; color: inherit; text-decoration: none; font-weight: 700; }
.lb-thumb { width: 26px; height: 34px; border-radius: 6px; overflow: hidden; flex: none; }
.lb-thumb svg { width: 100%; height: 100%; }
.lb-player { display: inline-flex; align-items: center; gap: 8px; }
.lb-player .icon { width: 14px; height: 14px; }
.lb-mult { display: inline-block; min-width: 58px; text-align: center; padding: 3px 8px; border-radius: 999px; font-weight: 800; font-size: .78rem; background: rgba(255,255,255,.06); color: var(--muted, #9aa3b2); }
.lb-mult.win { background: rgba(46,229,157,.14); color: #2ee59d; }
.lb-table .green { color: #2ee59d; font-weight: 800; }
.lb-table .red { color: #ff4d6d; font-weight: 700; }
.lb-new { animation: lb-in .6s ease-out; }
@keyframes lb-in { from { background: var(--gold-soft); transform: translateY(-6px); opacity: 0; } }
@media (max-width: 640px) { .lb-table th:nth-child(3), .lb-table td:nth-child(3) { display: none; } .lb-game { font-size: .8rem; } }

/* ===== Case toolbar: search, sort, price bands ===== */
.case-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 6px 0 10px; }
.case-tools .search { flex: 1 1 220px; }
.case-tools select { width: auto; min-width: 170px; }
.ct-risk { display: inline-flex; align-items: center; gap: 8px; font-size: .85rem; font-weight: 600; cursor: pointer; white-space: nowrap; }
.ct-count { margin-left: auto; font-size: .82rem; white-space: nowrap; }
.ct-bands { margin-bottom: 14px; }
.case-grid > [hidden] { display: none !important; }

/* ===== Welcome tour ===== */
.tour { position: fixed; inset: 0; z-index: 9700; }
.tour-hole { position: fixed; border-radius: 16px; box-shadow: 0 0 0 9999px rgba(4,6,10,.78), 0 0 0 3px var(--gold-2), 0 0 30px var(--gold-2); transition: left .35s ease, top .35s ease, width .35s ease, height .35s ease; pointer-events: none; }
.tour.centred .tour-hole { left: 50%; top: 50%; width: 0; height: 0; box-shadow: 0 0 0 9999px rgba(4,6,10,.82); }
.tour-card { position: fixed; display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; border-radius: 18px; background: linear-gradient(160deg, #23201a, #15171c 70%); border: 1px solid rgba(242,196,74,.45); box-shadow: 0 20px 60px rgba(0,0,0,.6); transition: left .35s ease, top .35s ease; }
.tour.centred .tour-card { left: 50% !important; top: 50% !important; width: min(380px, calc(100vw - 24px)) !important; transform: translate(-50%, -50%); text-align: center; }
.tour-card.pop { animation: tour-pop .35s cubic-bezier(.2,1.5,.4,1); }
@keyframes tour-pop { from { opacity: 0; transform: translateY(10px) scale(.96); } }
.tour.centred .tour-card.pop { animation: tour-pop-c .35s cubic-bezier(.2,1.5,.4,1); }
@keyframes tour-pop-c { from { opacity: 0; transform: translate(-50%, -46%) scale(.94); } }
.tour-card b { font-size: 1.15rem; }
.tour-card p { margin: 0; color: rgba(255,255,255,.78); font-size: .9rem; line-height: 1.45; }
.tour-steps { font-size: .7rem; font-weight: 800; letter-spacing: .15em; color: var(--gold-2); }
.tour-actions { display: flex; justify-content: space-between; gap: 8px; margin-top: 8px; }
.tour.centred .tour-actions { justify-content: center; }
button.settings-link { width: 100%; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.game-grid, #rain-card { scroll-margin-top: 80px; }
/* Phones: the top bar has room for the essentials only (sound is in Settings, the streak shows in each game) */
@media (max-width: 480px) {
  #account-area > .streak-chip, #account-area > .dropdown:has(> [aria-label="Sound settings"]) { display: none; }
}
@media (max-width: 960px) {
  .bell-menu { position: fixed; left: 10px; right: 10px; top: 62px; width: auto; }
}
@media (max-width: 640px) {
  /* Live bets: game as a picture only, no level badge, so all columns fit */
  .lb-game { font-size: 0; gap: 0; }
  .lb-table .lb-player .lvl, .lb-table .lb-player .level-badge, .lb-table .lb-player [class*="badge"] { display: none; }
  .lb-table td, .lb-table th { padding: 7px 5px; }
  .lb-mult { min-width: 0; padding: 3px 6px; }
  /* Cases: two per row */
  .case-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .case-grid .case-card { padding: 10px 8px; }
  .case-grid .case-name { font-size: .9rem; }
  .case-tools select { flex: 1 1 auto; min-width: 0; }
  .ct-count { margin-left: 0; }
}

/* ===== Daily Cases v2 ===== */
.dl-hero { position: relative; overflow: hidden; display: grid; grid-template-columns: 220px 1fr; align-items: center; gap: 24px; padding: 26px 30px; margin-bottom: 18px; border-radius: 22px; background: radial-gradient(120% 140% at 15% 30%, color-mix(in srgb, var(--glow, #f2c44a) 26%, transparent), transparent 60%), linear-gradient(135deg, #1b1d23, #111216); border: 1px solid color-mix(in srgb, var(--glow, #f2c44a) 40%, transparent); }
.dl-rays { position: absolute; left: 110px; top: 50%; width: 520px; height: 520px; margin: -260px 0 0 -260px; background: repeating-conic-gradient(color-mix(in srgb, var(--glow) 18%, transparent) 0 8deg, transparent 8deg 22deg); mask: radial-gradient(circle, #000 0, transparent 62%); animation: rec-spin 30s linear infinite; pointer-events: none; }
.dl-chest { position: relative; width: 200px; height: 170px; display: grid; place-items: center; animation: db-bob 3.2s ease-in-out infinite; }
.dl-chest-art { width: 170px; height: 150px; filter: drop-shadow(0 18px 24px rgba(0,0,0,.55)) drop-shadow(0 0 26px color-mix(in srgb, var(--glow) 60%, transparent)); }
.dl-chest-art svg { width: 100%; height: 100%; }
.dl-chest .lvl-item { position: absolute; width: 54px; height: 54px; bottom: 6px; }
.dl-chest .lvl-item.a { left: 4px; transform: rotate(-12deg); }
.dl-chest .lvl-item.b { right: 4px; transform: rotate(10deg); }
.dl-chest .lvl-item svg { width: 100%; height: 100%; }
.dl-chest.locked .dl-chest-art, .dl-chest.locked .lvl-item { filter: saturate(.5) brightness(.65); }
.dl-lock { position: absolute; width: 46px; height: 46px; padding: 10px; border-radius: 50%; background: rgba(0,0,0,.7); color: #fff; box-shadow: 0 0 0 2px rgba(255,255,255,.15); }
.dl-lock svg { width: 100%; height: 100%; }
.dl-info { position: relative; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.dl-info h2 { margin: 0; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.dl-info .kicker { color: var(--glow); }
.dl-up { font-weight: 700; font-size: 1.05rem; }
.dl-up .coin-amount { color: #2ee59d; font-weight: 900; }
.dl-cta { padding: 13px 28px; font-size: 1.05rem; margin-top: 4px; }
.dl-cta.pulse { animation: dl-pulse 1.8s ease-in-out infinite; }
@keyframes dl-pulse { 50% { box-shadow: 0 0 0 6px var(--gold-soft), 0 0 30px var(--gold-2); transform: translateY(-1px); } }
.dl-wait { display: flex; flex-direction: column; }
.dl-clock { font: 900 2.2rem/1.1 system-ui, sans-serif; letter-spacing: .04em; color: #fff; }
.dl-unlock { display: flex; flex-direction: column; gap: 6px; width: min(420px, 100%); }
.dl-unlock-top { display: flex; justify-content: space-between; font-weight: 800; font-size: .85rem; }
.dl-bar { height: 10px; }
.dl-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.dl-chip { padding: 5px 12px; border-radius: 999px; font-size: .8rem; font-weight: 700; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); color: rgba(255,255,255,.8); }
.dl-chip.fire { color: #ffb020; border-color: rgba(255,176,32,.45); background: rgba(255,176,32,.1); }
.dl-chip.link { cursor: pointer; font-family: inherit; }
.dl-chip.link:hover { border-color: var(--glow); color: #fff; }
.dl-road-wrap { margin-bottom: 22px; }
.dl-road { position: relative; display: grid; grid-template-columns: repeat(20, minmax(30px, 1fr)); margin-top: 10px; padding: 0 2px; overflow-x: auto; }
.dl-road-line { position: absolute; left: 18px; right: 18px; top: 14px; height: 6px; border-radius: 99px; background: rgba(255,255,255,.08); }
.dl-road-fill { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2ee59d, var(--gold-2)); box-shadow: 0 0 12px var(--gold-soft); transition: width .6s; }
.dl-stop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0; border: 0; background: none; color: var(--muted, #9aa3b2); cursor: pointer; font: 700 .7rem system-ui, sans-serif; }
.dl-dot { width: 34px; height: 34px; border-radius: 50%; background: #17191e; border: 3px solid rgba(255,255,255,.12); transition: transform .15s; }
.dl-stop:hover .dl-dot { transform: scale(1.12); }
.dl-stop.ready .dl-dot, .dl-stop.cooldown .dl-dot { border-color: var(--c); background: color-mix(in srgb, var(--c) 30%, #17191e); box-shadow: 0 0 12px color-mix(in srgb, var(--c) 60%, transparent); }
.dl-stop.ready .dl-dot { animation: dl-ready 1.6s ease-in-out infinite; }
@keyframes dl-ready { 50% { transform: scale(1.15); box-shadow: 0 0 22px var(--c); } }
.dl-stop.ready, .dl-stop.cooldown { color: #fff; }
.dl-all { margin: 6px 0 12px; font-size: 1.2rem; }
.lvl-best { font-size: .78rem; font-weight: 700; color: rgba(255,255,255,.7); }
.lvl-best .coin-amount { color: #2ee59d; }
/* coloured even when locked, ready ones glow */
.lvl-case.locked { border-color: color-mix(in srgb, var(--trim) 22%, transparent); background: linear-gradient(180deg, color-mix(in srgb, var(--trim) 7%, transparent), rgba(16,17,20,.75)); }
.lvl-case.locked .lvl-art { filter: saturate(.45) brightness(.62); }
.lvl-case.ready { border-color: var(--trim); box-shadow: 0 0 0 1px var(--trim), 0 0 26px color-mix(in srgb, var(--trim) 45%, transparent); animation: dl-card 2.4s ease-in-out infinite; }
@keyframes dl-card { 50% { box-shadow: 0 0 0 1px var(--trim), 0 0 40px color-mix(in srgb, var(--trim) 65%, transparent); } }
body.calm .lvl-case.ready, body.calm .dl-cta.pulse, body.calm .dl-rays { animation: none; }
@media (max-width: 720px) {
  .dl-hero { grid-template-columns: 1fr; text-align: center; padding: 20px 16px; }
  .dl-chest { margin: 0 auto; }
  .dl-info { align-items: center; }
  .dl-rays { left: 50%; top: 110px; }
  .dl-chips { justify-content: center; }
  .dl-road { grid-template-columns: repeat(20, 40px); }
}
/* Opening intro: chest drops, rattles, bursts */
.dopen.intro .dopen-stage { opacity: 0; transform: scale(.92); }
.dopen .dopen-stage { transition: opacity .45s, transform .45s; }
.dopen-intro { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; transition: opacity .5s; }
.dopen:not(.intro) .dopen-intro { opacity: 0; }
.di-chest { width: 220px; height: 200px; filter: drop-shadow(0 0 40px var(--glow)); animation: di-drop .45s cubic-bezier(.3,1.5,.5,1) both, di-rattle .12s .5s linear 6, di-pop .3s 1.05s ease-in forwards; }
.di-chest svg { width: 100%; height: 100%; }
@keyframes di-drop { from { transform: translateY(-70vh) scale(.6); } }
@keyframes di-rattle { 25% { transform: rotate(-7deg) scale(1.03); } 75% { transform: rotate(7deg) scale(1.03); } }
@keyframes di-pop { to { transform: scale(1.6); opacity: 0; filter: brightness(3) drop-shadow(0 0 80px var(--glow)); } }
.di-rays { position: absolute; width: 640px; height: 640px; background: repeating-conic-gradient(color-mix(in srgb, var(--glow) 30%, transparent) 0 7deg, transparent 7deg 20deg); mask: radial-gradient(circle, #000 0, transparent 60%); opacity: 0; animation: fs-rays .5s .9s ease-out forwards, rec-spin 10s linear infinite; }
.di-flash { position: absolute; inset: 0; background: #fff; opacity: 0; animation: fs-flash .5s 1.05s ease-out; }
.dl-unlock .btn { align-self: flex-start; }
.dl-stop.locked .dl-dot { border-color: color-mix(in srgb, var(--c) 38%, transparent); }
@media (max-width: 720px) { .dl-unlock .btn { align-self: center; } }
.di-chest { display: block; position: relative; z-index: 1; }

/* ===== Chat reactions ===== */
.chat-msg { position: relative; }
.rx-add { margin-left: auto; padding: 0 6px; border: 0; border-radius: 8px; background: none; color: rgba(255,255,255,.45); font-size: .78rem; cursor: pointer; opacity: 0; transition: opacity .15s, background .15s; }
.chat-msg:hover .rx-add, .rx-add:focus-visible { opacity: 1; }
.rx-add:hover { background: rgba(255,255,255,.08); color: #fff; }
@media (hover: none) { .rx-add { opacity: .7; } }
.rx { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.rx[hidden] { display: none; }
.rx-chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 7px; border-radius: 999px; border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.05); color: #fff; font-size: .78rem; cursor: pointer; animation: db-pop .25s ease-out; }
.rx-chip b { font-size: .7rem; color: rgba(255,255,255,.75); }
.rx-chip.mine { border-color: var(--gold-2); background: var(--gold-soft); }
.rx-chip:hover { border-color: rgba(255,255,255,.3); }
.rx-pick { position: absolute; right: 8px; top: -14px; z-index: 5; display: flex; gap: 2px; padding: 4px; border-radius: 999px; background: #1b1e24; border: 1px solid rgba(255,255,255,.12); box-shadow: 0 8px 24px rgba(0,0,0,.5); animation: db-pop .2s ease-out; }
.rx-pick button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; font-size: 17px; cursor: pointer; transition: transform .12s, background .12s; }
.rx-pick button:hover { transform: scale(1.25); background: rgba(255,255,255,.08); }
.rx-pick button.on { background: var(--gold-soft); }

/* ===== Player profile v2 ===== */
.pf-modal { padding: 0; overflow: hidden auto; }
.pf-modal .close { z-index: 2; }
.pf-body { display: flex; flex-direction: column; gap: 14px; padding: 0 18px 18px; }
.pf-banner { display: flex; align-items: flex-end; gap: 16px; margin: 0 -18px; padding: 54px 20px 16px; background: radial-gradient(120% 120% at 0% 0%, hsl(var(--pf-hue, 40) 80% 55% / .45), transparent 60%), linear-gradient(135deg, hsl(var(--pf-hue, 40) 50% 22%), #121418 75%); border-bottom: 1px solid rgba(255,255,255,.08); }
.pf-av { position: relative; flex: none; padding: 5px; border-radius: 50%; background: conic-gradient(var(--gold-2), #fff6c2, var(--gold-2)); box-shadow: 0 10px 30px rgba(0,0,0,.5); }
.pf-av > .av { box-shadow: 0 0 0 3px #121418; border-radius: 50%; }
.pf-lvl { position: absolute; right: -2px; bottom: -2px; min-width: 30px; height: 30px; padding: 0 6px; border-radius: 999px; display: grid; place-items: center; font: 900 .8rem system-ui, sans-serif; color: #3a2000; background: linear-gradient(180deg, #ffe27a, #e0a01a); box-shadow: 0 0 0 3px #121418; }
.pf-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-bottom: 4px; }
.pf-name { font-size: 1.5rem; line-height: 1.1; overflow: hidden; text-overflow: ellipsis; }
.pf-rank { font-weight: 800; color: var(--gold-2); font-size: .9rem; }
.pf-joined { font-size: .78rem; }
.pf-fame { display: inline-flex; align-items: center; gap: 5px; align-self: flex-start; margin-top: 4px; padding: 3px 10px; border-radius: 999px; font-size: .75rem; font-weight: 800; color: #3a2000; background: linear-gradient(180deg, #ffe27a, #e0a01a); }
.pf-fame[hidden] { display: none; }
.pf-fame.p2 { background: linear-gradient(180deg, #ffffff, #b8c0cc); }
.pf-fame.p3 { background: linear-gradient(180deg, #ffcf9e, #c87533); }
.pf-fame.p4 { background: rgba(255,255,255,.12); color: #fff; }
.pf-fame .icon { width: 13px; height: 13px; }
.pf-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pf-tile { display: flex; flex-direction: column; gap: 2px; padding: 10px; border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); min-width: 0; }
.pf-tile-ico { width: 22px; height: 22px; padding: 4px; border-radius: 7px; background: rgba(255,255,255,.07); color: var(--gold-2); }
.pf-tile-ico svg { width: 100%; height: 100%; }
.pf-tile-label { font-size: .66rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted, #9aa3b2); margin-top: 4px; }
.pf-tile b { font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-tile.green b { color: #2ee59d; }
.pf-tile.gold b { color: var(--gold-2); }
.pf-fav { display: flex; align-items: center; gap: 12px; padding: 8px 12px 8px 8px; border-radius: 14px; color: inherit; text-decoration: none; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); transition: border-color .15s, transform .15s; }
.pf-fav:hover { border-color: var(--gold-2); transform: translateY(-1px); }
.pf-fav-art { width: 46px; height: 62px; border-radius: 9px; overflow: hidden; flex: none; }
.pf-fav-art svg { width: 100%; height: 100%; }
.pf-fav div { display: flex; flex-direction: column; }
.pf-fav .muted { font-size: .72rem; }
.pf-fav-play { font-size: .78rem; font-weight: 700; color: var(--gold-2); }
.ach-bar { height: 6px; margin: 4px 0 10px; }
@media (max-width: 560px) { .pf-tiles { grid-template-columns: repeat(2, 1fr); } .pf-banner { padding-top: 46px; } }

/* ===== Level road v2: nothing clipped, one calm colour scheme ===== */
.dl-road { padding: 16px 8px 8px; }
.dl-road-line { top: 30px; left: 26px; right: 26px; }
.dl-road-fill { background: linear-gradient(90deg, #2ee59d, #ffd23d); box-shadow: 0 0 10px rgba(46,229,157,.4); }
.dl-stop .dl-dot { position: relative; background: #15171c; border-color: rgba(255,255,255,.14); box-shadow: none; }
.dl-stop.locked .dl-dot { border-color: rgba(255,255,255,.14); }
.dl-stop.cooldown .dl-dot { border-color: #2ee59d; background: radial-gradient(circle, rgba(46,229,157,.35), #15171c 70%); box-shadow: 0 0 10px rgba(46,229,157,.35); animation: none; }
.dl-stop.cooldown .dl-dot::after { content: '✓'; position: absolute; inset: 0; display: grid; place-items: center; color: #2ee59d; font: 900 .8rem system-ui, sans-serif; }
.dl-stop.ready .dl-dot { border-color: #ffd23d; background: radial-gradient(circle, rgba(255,210,61,.5), #15171c 72%); box-shadow: 0 0 14px rgba(255,210,61,.6); animation: dl-ready2 1.6s ease-in-out infinite; }
.dl-stop.ready .dl-dot::after { content: '🎁'; position: absolute; inset: 0; display: grid; place-items: center; font-size: .8rem; }
@keyframes dl-ready2 { 50% { transform: scale(1.12); box-shadow: 0 0 22px rgba(255,210,61,.9); } }
.dl-stop.ready small { color: #ffd23d; }
.dl-stop.cooldown small { color: #2ee59d; }

/* ===== Chat reactions fix: tidy meta row, button in the corner ===== */
.chat-meta { display: flex; align-items: center; gap: 6px; min-width: 0; padding-right: 26px; }
.chat-meta .author { min-width: 0; overflow: hidden; }
.chat-meta .time { white-space: nowrap; flex: none; overflow-wrap: normal; }
.chat-mod { flex: none; white-space: nowrap; }
.rx-add { position: absolute; top: 6px; right: 6px; margin: 0; width: 24px; height: 22px; padding: 0; z-index: 2; background: rgba(255,255,255,.06); }
.rx-pick { position: fixed; z-index: 9800; }

/* ===== Daily case reel v2: glass stage, item cards, gold window ===== */
.dopen .reel { border-radius: 22px; border: 1px solid color-mix(in srgb, var(--glow, #f2c44a) 45%, transparent); background: radial-gradient(ellipse at 50% 120%, color-mix(in srgb, var(--glow, #f2c44a) 22%, transparent), #0c0d11 70%); box-shadow: 0 0 60px -12px var(--glow, #f2c44a), inset 0 0 40px rgba(0,0,0,.6); }
.dopen .reel::before { width: 110px; background: linear-gradient(90deg, #0c0d11 15%, transparent); }
.dopen .reel::after { width: 110px; background: linear-gradient(270deg, #0c0d11 15%, transparent); }
.dopen .reel-cell.item { position: relative; background: none; border: 0; padding: 12px 7px; gap: 8px; }
.dopen .reel-cell.item::before { content: ''; position: absolute; inset: 10px 6px; z-index: 0; border-radius: 16px; background: linear-gradient(180deg, color-mix(in srgb, var(--rarity) 26%, #16181e), #121318 80%); border: 1px solid color-mix(in srgb, var(--rarity) 50%, transparent); box-shadow: inset 0 -16px 24px -12px color-mix(in srgb, var(--rarity) 55%, transparent); }
.dopen .reel-cell.item::after { content: ''; position: absolute; left: 30%; right: 30%; bottom: 10px; height: 3px; border-radius: 3px; z-index: 0; background: var(--rarity); box-shadow: 0 0 10px var(--rarity); }
.dopen .reel-cell .art { position: relative; z-index: 1; width: 64px; height: 64px; filter: drop-shadow(0 6px 10px rgba(0,0,0,.5)) drop-shadow(0 0 10px color-mix(in srgb, var(--rarity) 60%, transparent)); }
.dopen .reel-cell .value { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px 3px 6px; border-radius: 999px; background: rgba(0,0,0,.6); color: #fff; font-weight: 900; font-size: .82rem; }
.dopen .reel-cell .value::before { content: ''; width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff6c2, #ffc23d 60%, #a8700c); box-shadow: 0 0 0 1px #8a5a06; }
.dopen .reel-marker { width: 112px; background: none; border: 2px solid rgba(255,255,255,.85); border-radius: 18px; box-shadow: 0 0 22px var(--glow, #f2c44a), inset 0 0 22px color-mix(in srgb, var(--glow, #f2c44a) 35%, transparent); top: 6px; bottom: 6px; }
.dopen .reel-marker::before, .dopen .reel-marker::after { border-width: 9px; }
.dopen .reel-marker::before { top: -2px; border-top-color: #fff; }
.dopen .reel-marker::after { bottom: -2px; border-bottom-color: #fff; }
.dopen .reel-cell.won::before { background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--rarity) 60%, #16181e), #121318 85%); box-shadow: 0 0 30px color-mix(in srgb, var(--rarity) 70%, transparent), inset 0 0 0 2px var(--rarity); }
.dopen .reel-cell.won .art { animation: dl-won-art .7s cubic-bezier(.2,1.8,.4,1); }
@keyframes dl-won-art { 40% { transform: scale(1.3) rotate(-6deg); } }
.dopen .reel.revealed { border-color: var(--rarity); box-shadow: 0 0 70px -10px var(--rarity), inset 0 0 40px rgba(0,0,0,.6); }
/* Header fits at every width: drop extras step by step (all of them are in the menus too) */
@media (max-width: 1760px) {
  .user-chip .user-lines { display: none; }
  #account-area > .streak-chip { display: none; }
}
@media (max-width: 1180px) {
  #account-area > .dropdown:has(> [aria-label="Sound settings"]) { display: none; }
  .main-nav > a[data-nav="referrals"] { display: none; }
}
@media (max-width: 1060px) {
  .main-nav > a[data-nav="race"] { display: none; }
  .main-nav > a, .main-nav .nav-btn { padding-inline: 9px; }
}
.user-chip .user-lines { max-width: 150px; min-width: 0; overflow: hidden; } .user-chip .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== Connection banner ===== */
.net-banner { position: fixed; left: 50%; top: 70px; z-index: 9900; display: flex; align-items: center; gap: 10px; padding: 10px 18px; border-radius: 999px; transform: translateX(-50%); background: #2a1216; border: 1px solid #ff4d6d; color: #ffd5dc; font-weight: 700; font-size: .88rem; box-shadow: 0 10px 30px rgba(0,0,0,.5); animation: db-pop .3s ease-out; }
.net-banner[hidden] { display: none; }
.net-spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255,77,109,.3); border-top-color: #ff4d6d; animation: rec-spin .8s linear infinite; }
/* UNO lobby on phones: the single column may not grow wider than the screen */
@media (max-width: 960px) {
  .uno-lobby { grid-template-columns: minmax(0, 1fr); }
  .uno-main, .uno-list, .uno-create-panel { min-width: 0; }
  .uno-list .uno-row, .uno-list > * { min-width: 0; }
}

/* ===== @mention autocomplete ===== */
.mention-pop { position: absolute; left: 0; right: 0; bottom: calc(100% + 6px); z-index: 31; display: flex; flex-direction: column; padding: 4px; border-radius: 12px; background: #171a20; border: 1px solid rgba(255,255,255,.1); box-shadow: 0 14px 34px rgba(0,0,0,.5); animation: qs-in .12s ease-out; }
.mention-pop[hidden] { display: none; }
.mention-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 0; border-radius: 8px; background: none; color: inherit; font: 600 .85rem system-ui, sans-serif; text-align: left; cursor: pointer; }
.mention-item.active, .mention-item:hover { background: var(--gold-soft); color: #fff; }

.btn.danger { color: #ff4d6d; border-color: #ff4d6d; }
/* ===== Borrow ===== */
.bborrow { margin-top: 12px; padding: 12px 14px; border-radius: 14px; background: linear-gradient(160deg, rgba(255,92,170,.14), rgba(255,92,170,.03)); border: 1px solid rgba(255,92,170,.45); }
.bborrow-head { display: flex; align-items: center; gap: 10px; }
.bborrow-ico { font-size: 1.3rem; }
.bborrow-head div { display: flex; flex-direction: column; }
.bborrow-head b { letter-spacing: .08em; text-transform: uppercase; font-size: .85rem; }
.bborrow-head span { font-size: .75rem; color: rgba(255,255,255,.65); }
.bborrow-val { display: block; text-align: center; margin: 8px 0 2px; color: #ff6fb5; font-size: 1.15rem; }
.bborrow-range { width: 100%; accent-color: #ff6fb5; }
.bborrow-scale { display: flex; justify-content: space-between; font-size: .7rem; color: rgba(255,255,255,.45); }
.bborrow-note { display: block; font-size: .72rem; font-weight: 600; color: rgba(255,255,255,.55); }
.row-start .bborrow { margin-top: 0; min-width: 230px; }
.seat-borrow { margin-left: auto; padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 800; color: #ff6fb5; background: rgba(255,92,170,.14); border: 1px solid rgba(255,92,170,.4); }
/* ===== Official / Community tabs ===== */
.bsource { display: inline-flex; padding: 3px; border-radius: 12px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); }
.bsource[hidden] { display: none; }
.bsource button { padding: 6px 12px; border: 0; border-radius: 9px; background: none; color: rgba(255,255,255,.6); font: 700 .72rem system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.bsource button.active { background: rgba(255,255,255,.1); color: #fff; }
.bcase-by { font-size: .7rem; }
.bcase-new { border: 2px dashed rgba(255,255,255,.18); background: rgba(255,255,255,.02); color: inherit; cursor: pointer; justify-content: center; gap: 6px; min-height: 180px; font: inherit; }
.bcase-new:hover { border-color: var(--gold-2); }
.bcase-new .plus { font-size: 2rem; color: var(--gold-2); line-height: 1; }
/* ===== Case creator ===== */
.cc-modal { width: min(980px, calc(100vw - 24px)); max-height: 92vh; overflow: auto; }
.cc-cols { display: grid; grid-template-columns: 1.2fr 1fr; gap: 18px; margin-top: 12px; }
.cc-left { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cc-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; max-height: 52vh; overflow-y: auto; padding-right: 4px; }
.cc-item { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; border-radius: 12px; border: 1px solid color-mix(in srgb, var(--rarity) 35%, transparent); background: linear-gradient(180deg, color-mix(in srgb, var(--rarity) 14%, transparent), rgba(255,255,255,.02)); color: #fff; font-size: .72rem; font-weight: 800; cursor: pointer; }
.cc-item.on { outline: 2px solid var(--gold-2); box-shadow: 0 0 14px var(--gold-soft); }
.cc-art { width: 40px; height: 40px; display: block; }
.cc-art svg { width: 100%; height: 100%; }
.cc-right { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cc-preview { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: rgba(255,255,255,.04); }
.cc-prev-art { width: 70px; height: 62px; display: block; }
.cc-prev-art svg { width: 100%; height: 100%; }
.cc-chests { display: flex; flex-wrap: wrap; gap: 6px; }
.cc-chest { width: 44px; height: 40px; padding: 2px; border-radius: 10px; border: 1px solid rgba(255,255,255,.1); background: rgba(255,255,255,.03); cursor: pointer; }
.cc-chest svg { width: 100%; height: 100%; }
.cc-chest.on { border-color: var(--gold-2); box-shadow: 0 0 10px var(--gold-soft); }
.cc-head { display: flex; justify-content: space-between; align-items: center; }
.cc-picked { display: grid; gap: 6px; max-height: 34vh; overflow-y: auto; }
.cc-row { display: grid; grid-template-columns: 36px 1fr 84px auto auto; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 10px; background: rgba(255,255,255,.04); border-left: 3px solid var(--rarity); }
.cc-row .cc-art { width: 32px; height: 32px; }
.cc-row-name { display: flex; flex-direction: column; min-width: 0; font-size: .8rem; }
.cc-row-name b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cc-chance { padding: 6px 8px; text-align: right; }
.cc-empty { padding: 10px; font-size: .85rem; }
.cc-sum { display: flex; justify-content: space-between; font-weight: 700; }
.cc-sum .green { color: #2ee59d; } .cc-sum .red { color: #ff4d6d; }
.cc-price { color: var(--gold-2); }
@media (max-width: 760px) { .cc-cols { grid-template-columns: 1fr; } .cc-items { max-height: 34vh; } }


.modal.cc-modal { width: min(980px, calc(100vw - 24px)); max-width: none; }
.cc-chests { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; }
.cc-chest { flex: none; width: 40px; height: 36px; }
.cc-left .search { display: flex; align-items: center; gap: 8px; }
.cc-left .search .icon { width: 16px; height: 16px; flex: none; }

