/* ============================================================
   SLOT MACHINE CSS — Premium Casino Style
   ============================================================ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --slot-bg: #0e0e12;
  --slot-cabinet: linear-gradient(145deg, #1e2028 0%, #12131a 40%, #0a0b0f 100%);
  --slot-chrome: linear-gradient(180deg, #d4af37 0%, #f5d060 30%, #c9a020 50%, #f5d060 70%, #d4af37 100%);
  --slot-chrome-dark: linear-gradient(180deg, #8b7320 0%, #a08830 50%, #8b7320 100%);
  --slot-reel-bg: linear-gradient(180deg, #111318 0%, #0a0c10 50%, #111318 100%);
  --slot-border: #2a2d38;
  --slot-gold: #d4af37;
  --slot-gold-bright: #f5d060;
  --slot-gold-dark: #8b7320;
  --slot-win-glow: rgba(245, 208, 96, 0.6);
  --slot-sym-size: 80px;
  --slot-reel-gap: 4px;
  --slot-reel-h: calc(var(--slot-sym-size) * 3);
  --slot-spin-duration-1: 2s;
  --slot-spin-duration-2: 2.2s;
  --slot-spin-duration-3: 2.4s;
}

/* ── Machine Container ─────────────────────────────────────── */
.slot-machine {
  position: relative;
  max-width: 400px;
  margin: 0 auto;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
}

/* ── Cabinet Frame ─────────────────────────────────────────── */
.slot-cabinet {
  position: relative;
  background: var(--slot-cabinet);
  border-radius: 18px;
  border: 3px solid var(--slot-gold);
  box-shadow:
    0 0 20px rgba(212, 175, 55, 0.15),
    0 8px 32px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.4);
  padding: 24px 20px 20px;
  overflow: hidden;
}

.slot-cabinet::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--slot-gold-bright), transparent);
  opacity: 0.5;
}

/* Top chrome strip */
.slot-cabinet-top {
  position: absolute;
  top: 0; left: 20px; right: 20px;
  height: 4px;
  background: var(--slot-chrome);
  border-radius: 0 0 2px 2px;
  box-shadow: 0 2px 6px rgba(212, 175, 55, 0.3);
}

/* Bottom chrome strip */
.slot-cabinet-bottom {
  position: absolute;
  bottom: 0; left: 20px; right: 20px;
  height: 4px;
  background: var(--slot-chrome-dark);
  border-radius: 2px 2px 0 0;
}

/* ── Header / Title ────────────────────────────────────────── */
.slot-header {
  text-align: center;
  margin-bottom: 16px;
}

.slot-title {
  font-size: 28px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 3px;
  background: var(--slot-chrome);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: none;
  filter: drop-shadow(0 2px 4px rgba(212, 175, 55, 0.3));
  margin: 0;
  line-height: 1.2;
}

.slot-subtitle {
  font-size: 11px;
  letter-spacing: 4px;
  color: #6b6e7b;
  text-transform: uppercase;
  margin: 4px 0 0;
}

/* ── Reel Container ────────────────────────────────────────── */
.slot-reels-wrap {
  position: relative;
  background: #08090d;
  border-radius: 12px;
  padding: 10px;
  border: 2px solid var(--slot-border);
  box-shadow:
    inset 0 4px 12px rgba(0, 0, 0, 0.7),
    inset 0 -4px 12px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.03);
}

.slot-reels {
  display: flex;
  flex-direction: row;
  gap: var(--slot-reel-gap);
  overflow: hidden;
  border-radius: 8px;
  background: var(--slot-reel-bg);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.6);
  position: relative;
}

/* Horizontal win lines */
.slot-reels::before,
.slot-reels::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.04);
  z-index: 5;
  pointer-events: none;
}

.slot-reels::before { top: calc(var(--slot-sym-size) - 1px); }
.slot-reels::after  { top: calc(var(--slot-sym-size) * 2 - 1px); }

/* ── Individual Reel ───────────────────────────────────────── */
.slot-reel {
  position: relative;
  flex: 1;
  height: var(--slot-reel-h);
  overflow: hidden;
}

.slot-reel::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 40px;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.7), transparent);
  z-index: 3;
  pointer-events: none;
}

.slot-reel::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 40px;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.7), transparent);
  z-index: 3;
  pointer-events: none;
}

/* Reel strip (the scrolling column of symbols) */
.slot-reel-strip {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  will-change: transform;
  transition: transform 0.1s ease-out;
}

/* ── Symbols ───────────────────────────────────────────────── */
.slot-sym {
  width: 100%;
  height: var(--slot-sym-size);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  line-height: 1;
  position: relative;
  transition: transform 0.3s ease;
}

.slot-sym::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 8px;
  background: radial-gradient(circle, rgba(255,255,255,0.03), transparent 70%);
  pointer-events: none;
}

/* Symbol color glows */
.slot-sym.sym-cherry {
  text-shadow:
    0 0 12px rgba(255, 40, 60, 0.8),
    0 0 28px rgba(255, 40, 60, 0.4),
    0 0 50px rgba(255, 40, 60, 0.15);
}

.slot-sym.sym-lemon {
  text-shadow:
    0 0 12px rgba(255, 220, 40, 0.8),
    0 0 28px rgba(255, 220, 40, 0.4),
    0 0 50px rgba(255, 220, 40, 0.15);
}

.slot-sym.sym-orange {
  text-shadow:
    0 0 12px rgba(255, 140, 30, 0.8),
    0 0 28px rgba(255, 140, 30, 0.4),
    0 0 50px rgba(255, 140, 30, 0.15);
}

.slot-sym.sym-plum {
  text-shadow:
    0 0 12px rgba(160, 60, 200, 0.8),
    0 0 28px rgba(160, 60, 200, 0.4),
    0 0 50px rgba(160, 60, 200, 0.15);
}

.slot-sym.sym-bell {
  text-shadow:
    0 0 12px rgba(245, 208, 96, 0.9),
    0 0 28px rgba(245, 208, 96, 0.5),
    0 0 50px rgba(245, 208, 96, 0.2);
}

.slot-sym.sym-bar {
  text-shadow:
    0 0 12px rgba(180, 180, 200, 0.8),
    0 0 28px rgba(180, 180, 200, 0.4),
    0 0 50px rgba(180, 180, 200, 0.15);
}

.slot-sym.sym-seven {
  text-shadow:
    0 0 14px rgba(255, 50, 50, 0.9),
    0 0 30px rgba(255, 215, 0, 0.6),
    0 0 60px rgba(255, 50, 50, 0.25);
  filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.3));
}

.slot-sym.sym-diamond {
  text-shadow:
    0 0 14px rgba(80, 160, 255, 0.9),
    0 0 30px rgba(80, 160, 255, 0.5),
    0 0 60px rgba(80, 200, 255, 0.2);
}

.slot-sym.sym-star {
  text-shadow:
    0 0 14px rgba(255, 255, 255, 0.9),
    0 0 28px rgba(255, 255, 200, 0.6),
    0 0 60px rgba(255, 255, 200, 0.2);
}

.slot-sym.sym-joker {
  text-shadow:
    0 0 16px rgba(255, 0, 180, 0.9),
    0 0 36px rgba(255, 0, 180, 0.5),
    0 0 70px rgba(255, 0, 180, 0.2);
}

/* ── Spin Animation Keyframes ──────────────────────────────── */
@keyframes reelSpin {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-300%); }
}

@keyframes reelStop {
  0%   { transform: translateY(-300%); }
  60%  { transform: translateY(-295%); }
  75%  { transform: translateY(-300%); }
  85%  { transform: translateY(-298%); }
  95%  { transform: translateY(-300%); }
  100% { transform: translateY(-300%); }
}

.slot-reel.is-spinning .slot-reel-strip {
  animation: reelSpin var(--slot-spin-duration) linear forwards;
}

.slot-reel.is-stopping .slot-reel-strip {
  animation: reelStop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.slot-reel.reel-1 { --slot-spin-duration: var(--slot-spin-duration-1); }
.slot-reel.reel-2 { --slot-spin-duration: var(--slot-spin-duration-2); }
.slot-reel.reel-3 { --slot-spin-duration: var(--slot-spin-duration-3); }

/* Blur during spin */
.slot-reel.is-spinning .slot-sym {
  filter: blur(2px);
  transition: filter 0.15s;
}

.slot-reel.is-stopping .slot-sym,
.slot-reel:not(.is-spinning):not(.is-stopping) .slot-sym {
  filter: blur(0);
  transition: filter 0.3s ease;
}

/* ── Win Line Effects ──────────────────────────────────────── */
.slot-win-line {
  position: absolute;
  left: 0; right: 0;
  height: var(--slot-sym-size);
  z-index: 4;
  pointer-events: none;
  border: 2px solid transparent;
  border-radius: 6px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.slot-win-line.is-active {
  opacity: 1;
  border-color: var(--slot-gold-bright);
  animation: winPulse 0.6s ease-in-out infinite alternate;
  box-shadow:
    0 0 15px var(--slot-win-glow),
    0 0 30px rgba(245, 208, 96, 0.3),
    inset 0 0 15px rgba(245, 208, 96, 0.1);
}

.slot-win-line.line-top    { top: 0; }
.slot-win-line.line-middle { top: var(--slot-sym-size); }
.slot-win-line.line-bottom { top: calc(var(--slot-sym-size) * 2); }

@keyframes winPulse {
  0% {
    box-shadow:
      0 0 10px rgba(245, 208, 96, 0.4),
      0 0 20px rgba(245, 208, 96, 0.2),
      inset 0 0 10px rgba(245, 208, 96, 0.08);
    border-color: var(--slot-gold);
  }
  100% {
    box-shadow:
      0 0 20px rgba(245, 208, 96, 0.7),
      0 0 40px rgba(245, 208, 96, 0.4),
      inset 0 0 20px rgba(245, 208, 96, 0.15);
    border-color: var(--slot-gold-bright);
  }
}

/* Highlight winning symbols */
.slot-sym.is-winning {
  animation: symWinBounce 0.5s ease-in-out infinite alternate;
  z-index: 6;
}

@keyframes symWinBounce {
  0%   { transform: scale(1); }
  100% { transform: scale(1.15); }
}

/* ── Big Win Overlay ───────────────────────────────────────── */
.big-win-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.big-win-overlay.is-active {
  opacity: 1;
  pointer-events: all;
}

.big-win-title {
  font-size: 64px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 6px;
  background: var(--slot-chrome);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 20px rgba(245, 208, 96, 0.6));
  animation: bigWinPulse 1s ease-in-out infinite alternate;
  text-align: center;
  line-height: 1.1;
}

.big-win-amount {
  font-size: 48px;
  font-weight: 800;
  color: var(--slot-gold-bright);
  text-shadow:
    0 0 20px rgba(245, 208, 96, 0.8),
    0 0 40px rgba(245, 208, 96, 0.4);
  margin-top: 12px;
  animation: bigWinAmount 1.2s ease-in-out infinite alternate;
}

.big-win-subtitle {
  font-size: 16px;
  letter-spacing: 3px;
  color: #aaa;
  text-transform: uppercase;
  margin-top: 20px;
}

@keyframes bigWinPulse {
  0%   { transform: scale(1); filter: drop-shadow(0 0 20px rgba(245, 208, 96, 0.4)); }
  100% { transform: scale(1.06); filter: drop-shadow(0 0 40px rgba(245, 208, 96, 0.8)); }
}

@keyframes bigWinAmount {
  0%   { transform: scale(1); opacity: 0.9; }
  100% { transform: scale(1.08); opacity: 1; }
}

/* ── Confetti Particles ────────────────────────────────────── */
.confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

.confetti-piece {
  position: absolute;
  width: 10px;
  height: 10px;
  top: -20px;
  opacity: 0;
}

.confetti-piece.is-active {
  animation: confettiFall var(--fall-duration, 3s) var(--fall-delay, 0s) ease-in forwards;
}

@keyframes confettiFall {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg) scale(1);
  }
  25% {
    opacity: 1;
    transform: translateY(25vh) rotate(180deg) scale(0.9);
  }
  50% {
    opacity: 0.9;
    transform: translateY(50vh) rotate(360deg) scale(1);
  }
  75% {
    opacity: 0.6;
    transform: translateY(75vh) rotate(540deg) scale(0.8);
  }
  100% {
    opacity: 0;
    transform: translateY(105vh) rotate(720deg) scale(0.6);
  }
}

/* Confetti shapes */
.confetti-piece.confetti-square {
  border-radius: 2px;
}

.confetti-piece.confetti-circle {
  border-radius: 50%;
}

.confetti-piece.confetti-rect {
  width: 6px;
  height: 14px;
  border-radius: 2px;
}

/* Confetti colors */
.confetti-piece.confetti-gold   { background: var(--slot-gold-bright); box-shadow: 0 0 6px rgba(245, 208, 96, 0.6); }
.confetti-piece.confetti-red    { background: #ff3040; box-shadow: 0 0 6px rgba(255, 48, 64, 0.5); }
.confetti-piece.confetti-blue   { background: #4090ff; box-shadow: 0 0 6px rgba(64, 144, 255, 0.5); }
.confetti-piece.confetti-green  { background: #30d870; box-shadow: 0 0 6px rgba(48, 216, 112, 0.5); }
.confetti-piece.confetti-purple { background: #b040ff; box-shadow: 0 0 6px rgba(176, 64, 255, 0.5); }
.confetti-piece.confetti-white  { background: #fff; box-shadow: 0 0 6px rgba(255, 255, 255, 0.5); }

/* ── Controls ──────────────────────────────────────────────── */
.slot-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
  flex-wrap: wrap;
}

/* Balance display */
.slot-balance {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 10px 16px;
  background: rgba(0, 0, 0, 0.35);
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.slot-balance-label {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #6b6e7b;
}

.slot-balance-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--slot-gold-bright);
  font-variant-numeric: tabular-nums;
  min-width: 80px;
  text-align: right;
}

/* Bet controls */
.slot-bet-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.slot-bet-label {
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #6b6e7b;
}

.slot-bet-btn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--slot-border);
  background: rgba(255, 255, 255, 0.04);
  color: #ccc;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.slot-bet-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--slot-gold-dark);
  color: var(--slot-gold-bright);
}

.slot-bet-btn:active {
  transform: scale(0.92);
}

.slot-bet-value {
  min-width: 60px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--slot-border);
  background: rgba(0, 0, 0, 0.3);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  text-align: center;
  padding: 0 8px;
  font-variant-numeric: tabular-nums;
}

/* Win display */
.slot-win-display {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  min-height: 42px;
  transition: all 0.3s ease;
}

.slot-win-display.has-win {
  border-color: rgba(245, 208, 96, 0.3);
  background: rgba(212, 175, 55, 0.08);
}

.slot-win-label {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #6b6e7b;
}

.slot-win-value {
  font-size: 18px;
  font-weight: 700;
  color: #555;
  font-variant-numeric: tabular-nums;
  transition: color 0.3s;
}

.slot-win-display.has-win .slot-win-value {
  color: var(--slot-gold-bright);
  text-shadow: 0 0 10px rgba(245, 208, 96, 0.4);
}

/* ── Spin Button ───────────────────────────────────────────── */
.slot-spin-btn {
  position: relative;
  width: 100%;
  max-width: 220px;
  height: 56px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #1a1200;
  background: linear-gradient(180deg, #f5d060 0%, #d4af37 40%, #c9a020 60%, #d4af37 80%, #f5d060 100%);
  box-shadow:
    0 4px 16px rgba(212, 175, 55, 0.35),
    0 2px 4px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -2px 4px rgba(0, 0, 0, 0.15);
  transition: all 0.2s ease;
  outline: none;
  overflow: hidden;
}

.slot-spin-btn::before {
  content: "";
  position: absolute;
  top: 0; left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

.slot-spin-btn:hover::before {
  left: 120%;
}

.slot-spin-btn:hover {
  transform: scale(1.03);
  box-shadow:
    0 6px 24px rgba(212, 175, 55, 0.5),
    0 2px 8px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.5),
    inset 0 -2px 4px rgba(0, 0, 0, 0.15);
}

.slot-spin-btn:active {
  transform: scale(0.96);
  box-shadow:
    0 2px 8px rgba(212, 175, 55, 0.3),
    0 1px 2px rgba(0, 0, 0, 0.3),
    inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.slot-spin-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  filter: grayscale(0.4);
}

.slot-spin-btn:disabled:hover::before {
  left: -100%;
}

/* Spin button text states */
.slot-spin-btn .btn-text-spin   { display: inline; }
.slot-spin-btn .btn-text-spinning { display: none; }

.slot-spin-btn.is-spinning .btn-text-spin   { display: none; }
.slot-spin-btn.is-spinning .btn-text-spinning { display: inline; }

.slot-spin-btn.is-spinning {
  pointer-events: none;
}

/* Auto-spin toggle */
.slot-auto-btn {
  padding: 8px 16px;
  border-radius: 10px;
  border: 1px solid var(--slot-border);
  background: rgba(255, 255, 255, 0.04);
  color: #888;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease;
}

.slot-auto-btn:hover {
  border-color: var(--slot-gold-dark);
  color: var(--slot-gold);
}

.slot-auto-btn.is-active {
  background: rgba(212, 175, 55, 0.12);
  border-color: var(--slot-gold);
  color: var(--slot-gold-bright);
}

/* ── Paytable ──────────────────────────────────────────────── */
.slot-paytable {
  margin-top: 16px;
}

.slot-paytable-toggle {
  width: 100%;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--slot-border);
  background: rgba(255, 255, 255, 0.03);
  color: #888;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.slot-paytable-toggle:hover {
  border-color: var(--slot-gold-dark);
  color: var(--slot-gold);
}

.slot-paytable-toggle .arrow {
  display: inline-block;
  transition: transform 0.3s ease;
  font-size: 10px;
}

.slot-paytable.is-open .slot-paytable-toggle .arrow {
  transform: rotate(180deg);
}

.slot-paytable-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
  padding: 0 12px;
}

.slot-paytable.is-open .slot-paytable-body {
  max-height: 600px;
  padding: 12px;
}

.slot-paytable-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.slot-pay-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s;
}

.slot-pay-row:hover {
  border-color: rgba(212, 175, 55, 0.2);
}

.slot-pay-sym {
  font-size: 24px;
  line-height: 1;
}

.slot-pay-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
}

.slot-pay-count {
  font-size: 10px;
  letter-spacing: 1px;
  color: #666;
  text-transform: uppercase;
}

.slot-pay-amount {
  font-size: 14px;
  font-weight: 700;
  color: var(--slot-gold-bright);
}

/* Full-width pay row */
.slot-pay-row.slot-pay-row-full {
  grid-column: 1 / -1;
}

/* ── Lines indicator ───────────────────────────────────────── */
.slot-lines-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 11px;
  color: #6b6e7b;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.slot-lines-count {
  color: var(--slot-gold);
  font-weight: 700;
}

/* ── Sound toggle ──────────────────────────────────────────── */
.slot-sound-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--slot-border);
  background: rgba(0, 0, 0, 0.4);
  color: #888;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10;
}

.slot-sound-btn:hover {
  border-color: var(--slot-gold-dark);
  color: var(--slot-gold);
}

/* ── Near-miss flash ───────────────────────────────────────── */
.slot-near-miss-flash {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  opacity: 0;
  pointer-events: none;
  z-index: 6;
}

.slot-near-miss-flash.is-active {
  animation: nearMissFlash 0.4s ease-out;
}

@keyframes nearMissFlash {
  0%   { opacity: 0.15; }
  100% { opacity: 0; }
}

/* ── Free Spins Banner ─────────────────────────────────────── */
.slot-freespins-banner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  padding: 14px 28px;
  background: rgba(0, 0, 0, 0.9);
  border: 2px solid var(--slot-gold);
  border-radius: 14px;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.slot-freespins-banner.is-active {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: all;
}

.slot-freespins-banner .freespins-text {
  font-size: 22px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
  background: var(--slot-chrome);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: center;
}

.slot-freespins-banner .freespins-count {
  font-size: 36px;
  font-weight: 900;
  color: var(--slot-gold-bright);
  text-shadow: 0 0 20px rgba(245, 208, 96, 0.6);
  text-align: center;
  margin-top: 4px;
}

/* ── Mobile Responsive ─────────────────────────────────────── */
@media (max-width: 480px) {
  .slot-machine {
    max-width: 100%;
    padding: 0 8px;
  }

  .slot-cabinet {
    padding: 16px 12px 14px;
    border-radius: 14px;
    border-width: 2px;
  }

  :root {
    --slot-sym-size: 68px;
  }

  .slot-title {
    font-size: 22px;
    letter-spacing: 2px;
  }

  .slot-subtitle {
    font-size: 9px;
    letter-spacing: 3px;
  }

  .slot-spin-btn {
    height: 50px;
    font-size: 16px;
    letter-spacing: 2px;
  }

  .slot-balance-value {
    font-size: 17px;
  }

  .slot-win-value {
    font-size: 16px;
  }

  .slot-paytable-grid {
    grid-template-columns: 1fr;
  }

  .big-win-title {
    font-size: 40px;
    letter-spacing: 3px;
  }

  .big-win-amount {
    font-size: 32px;
  }

  .slot-freespins-banner .freespins-text {
    font-size: 18px;
  }

  .slot-freespins-banner .freespins-count {
    font-size: 28px;
  }
}

@media (max-width: 360px) {
  :root {
    --slot-sym-size: 60px;
  }

  .slot-cabinet {
    padding: 12px 8px 10px;
    border-radius: 12px;
  }

  .slot-title {
    font-size: 18px;
    letter-spacing: 1.5px;
  }

  .slot-controls {
    gap: 8px;
  }

  .slot-bet-value {
    min-width: 48px;
    height: 30px;
    font-size: 13px;
  }

  .slot-bet-btn {
    width: 30px;
    height: 30px;
    font-size: 14px;
  }

  .slot-spin-btn {
    height: 46px;
    font-size: 14px;
    letter-spacing: 2px;
    border-radius: 12px;
  }

  .slot-sym {
    font-size: 36px;
  }

  .big-win-title {
    font-size: 32px;
    letter-spacing: 2px;
  }

  .big-win-amount {
    font-size: 26px;
  }
}

/* ── Reduced Motion ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .slot-reel.is-spinning .slot-reel-strip,
  .slot-reel.is-stopping .slot-reel-strip {
    animation: none !important;
    transition: transform 0.5s ease;
  }

  .slot-win-line.is-active {
    animation: none;
  }

  .slot-sym.is-winning {
    animation: none;
  }

  .big-win-overlay.is-active .big-win-title,
  .big-win-overlay.is-active .big-win-amount {
    animation: none;
  }

  .confetti-piece.is-active {
    animation: none;
    display: none;
  }
}

/* ── Print hidden ──────────────────────────────────────────── */
@media print {
  .slot-machine { display: none; }
}
