:root {
  --bg: #121212;
  --panel: #1c1c1e;
  --panel-2: #252528;
  --text: #f5f5f5;
  --muted: #9ca3af;
  --gold: #f5c518;
  --gold-dim: #c9a012;
  --green: #22c55e;
  --green-dark: #16a34a;
  --border: #3f3f46;
  --danger: #ef4444;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
}

.casino-body {
  overscroll-behavior: none;
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  background: #0a0a0a;
}

.casino-app {
  width: 100%;
  max-width: 430px;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  position: relative;
}

@media (min-width: 520px) {
  .casino-body {
    padding: 1rem 0;
    align-items: flex-start;
  }

  .casino-app {
    min-height: min(900px, 100dvh);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
    overflow: hidden;
  }
}

.casino-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding-bottom: calc(4.5rem + var(--safe-bottom));
}

.casino-header {
  padding: 1rem 1rem 0.5rem;
}

.casino-title {
  margin: 0 0 0.75rem;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--gold);
}

.balance-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.balance-label {
  font-size: 0.95rem;
  color: var(--muted);
}

.balance-value {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--gold);
}

.coin-icon {
  font-size: 0.9em;
  color: var(--gold);
}


.game-tabs[hidden] {
  display: none !important;
}

.game-tabs {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 0.5rem;
  padding: 0.75rem 1rem 0;
}

.game-tab {
  flex: 0 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-width: 4.5rem;
  border: none;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.5rem 0.65rem;
  border-radius: 14px;
}

.game-tab-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.game-tab-label {
  line-height: 1.2;
  white-space: nowrap;
}

.game-tab.is-active {
  background: var(--gold);
  color: #111;
}

.game-tab:disabled {
  opacity: 0.55;
}

.screen-stack {
  flex: 1;
  padding: 0.75rem 1rem 1rem;
}

.screen {
  display: none;
}

.screen--active {
  display: block;
}

.screen-title {
  margin: 0 0 1rem;
  font-size: 1.1rem;
}

.slots-panel {
  margin: 0.5rem 0 1rem;
}

/* —— Слот-машина —— */
.slot-machine {
  perspective: 800px;
}

.slot-machine-frame {
  padding: 0.65rem;
  background: linear-gradient(165deg, #2a2418 0%, #141210 45%, #1a1814 100%);
  border: 3px solid var(--gold);
  border-radius: 20px;
  box-shadow:
    0 0 0 1px #8a7018 inset,
    0 12px 32px rgba(0, 0, 0, 0.55),
    0 0 24px rgba(245, 197, 24, 0.08);
}

.slot-machine--win .slot-machine-frame {
  animation: machine-win-glow 0.8s ease-in-out 2;
  border-color: #fde047;
}

@keyframes machine-win-glow {
  0%,
  100% {
    box-shadow:
      0 0 0 1px #8a7018 inset,
      0 12px 32px rgba(0, 0, 0, 0.55),
      0 0 24px rgba(245, 197, 24, 0.08);
  }
  50% {
    box-shadow:
      0 0 0 1px #fde047 inset,
      0 12px 32px rgba(0, 0, 0, 0.55),
      0 0 36px rgba(34, 197, 94, 0.35);
  }
}

.slot-machine-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  margin-bottom: 0.55rem;
}

.slot-machine-badge {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  color: #1a1408;
  background: linear-gradient(180deg, #fde68a, #d4a012);
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
}

.slot-lamp {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
  animation: lamp-blink 1.2s ease-in-out infinite;
}

.slot-lamp:last-child {
  animation-delay: 0.6s;
}

@keyframes lamp-blink {
  0%,
  100% {
    opacity: 0.45;
  }
  50% {
    opacity: 1;
  }
}

.slot-machine-body {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: stretch;
  gap: 0.35rem;
}

.slot-payline {
  width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, transparent, var(--gold-dim), transparent);
  opacity: 0.7;
}

.slot-reels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
  padding: 0.45rem;
  background: #0c0c0e;
  border-radius: 14px;
  border: 2px solid #3f3f46;
  box-shadow: inset 0 4px 16px rgba(0, 0, 0, 0.65);
  position: relative;
}

.slot-reels::before,
.slot-reels::after {
  content: '';
  position: absolute;
  left: 0.45rem;
  right: 0.45rem;
  height: 28%;
  pointer-events: none;
  z-index: 2;
}

.slot-reels::before {
  top: 0.45rem;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent);
  border-radius: 10px 10px 0 0;
}

.slot-reels::after {
  bottom: 0.45rem;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.55), transparent);
  border-radius: 0 0 10px 10px;
}

.slot-reel {
  position: relative;
  border-radius: 12px;
  background: linear-gradient(180deg, #1f1f23 0%, #121214 100%);
  border: 2px solid #52525b;
  box-shadow: inset 0 2px 8px rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

.slot-reel--landed {
  animation: reel-land 0.32s cubic-bezier(0.34, 1.4, 0.64, 1);
}

@keyframes reel-land {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.04);
  }
  100% {
    transform: scale(1);
  }
}

.slot-reel--blur .slot-reel-window {
  filter: blur(1px) brightness(1.08);
}

.slot-reel-window {
  height: clamp(5.2rem, 22vw, 6.5rem);
  overflow: hidden;
  position: relative;
}

.slot-reel-strip {
  will-change: transform;
}

.slot-reel-strip--spin .slot-symbol {
  opacity: 0.92;
}

.slot-symbol {
  height: clamp(5.2rem, 22vw, 6.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem;
}

/* Символы */
.sym-seven {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72%;
  height: 72%;
  max-width: 3.4rem;
  max-height: 3.4rem;
  border-radius: 14px;
  background: linear-gradient(145deg, #7dd3fc, #0284c7);
  color: #fff;
  font-size: clamp(1.8rem, 9vw, 2.35rem);
  font-weight: 900;
  line-height: 1;
  box-shadow:
    0 4px 0 #0369a1,
    inset 0 2px 6px rgba(255, 255, 255, 0.35);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.25);
}

.sym-bar {
  display: block;
  font-size: clamp(0.95rem, 4.5vw, 1.15rem);
  font-weight: 900;
  letter-spacing: 0.12em;
  color: #fecaca;
  background: linear-gradient(180deg, #7f1d1d, #450a0a);
  padding: 0.35rem 0.5rem;
  border-radius: 8px;
  border: 2px solid #b91c1c;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.sym-cherry {
  position: relative;
  width: 3.2rem;
  height: 3.2rem;
}

.sym-cherry::before,
.sym-cherry::after {
  content: '';
  position: absolute;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ff6b6b, #c92a2a 55%, #862e2e);
  box-shadow: inset -2px -3px 6px rgba(0, 0, 0, 0.35);
}

.sym-cherry::before {
  left: 0.15rem;
  bottom: 0.35rem;
}

.sym-cherry::after {
  right: 0.15rem;
  bottom: 0.15rem;
}

.sym-cherry {
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.35));
  background-image: linear-gradient(135deg, transparent 48%, #16a34a 48%, #15803d 52%, transparent 52%);
  background-size: 55% 55%;
  background-repeat: no-repeat;
  background-position: 52% 8%;
}

.sym-cherry::before,
.sym-cherry::after {
  box-shadow:
    inset -2px -3px 6px rgba(0, 0, 0, 0.35),
    2px 2px 0 rgba(0, 0, 0, 0.1);
}

.sym-fruit {
  font-size: clamp(2rem, 10vw, 2.75rem);
  line-height: 1;
  filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.4));
}

.sym-diamond {
  font-size: clamp(1.85rem, 9vw, 2.5rem);
}

.slot-machine-leds {
  display: flex;
  justify-content: center;
  gap: 0.45rem;
  margin-top: 0.55rem;
}

.slot-machine-leds span {
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--gold-dim);
  opacity: 0.35;
}

.slot-machine--win .slot-machine-leds span {
  animation: led-chase 0.5s linear infinite;
  background: var(--green);
  opacity: 1;
}

.slot-machine--win .slot-machine-leds span:nth-child(2) {
  animation-delay: 0.1s;
}
.slot-machine--win .slot-machine-leds span:nth-child(3) {
  animation-delay: 0.2s;
}
.slot-machine--win .slot-machine-leds span:nth-child(4) {
  animation-delay: 0.3s;
}
.slot-machine--win .slot-machine-leds span:nth-child(5) {
  animation-delay: 0.4s;
}

@keyframes led-chase {
  0%,
  100% {
    opacity: 0.25;
    transform: scale(0.85);
  }
  50% {
    opacity: 1;
    transform: scale(1.15);
  }
}

.spin-result {
  margin: 0.75rem 0 0;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 700;
}

.spin-result--win {
  color: var(--green);
}

.spin-result--lose {
  color: var(--muted);
}

.bet-panel {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.bet-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 0.65rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.bet-btn {
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--panel-2);
  color: var(--text);
  font-size: 1.4rem;
  line-height: 1;
}

.bet-value,
[data-bet-display],
.bet-input {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  min-width: 5.5rem;
  max-width: 9rem;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 800;
}

.bet-input {
  flex: 1;
  width: 6.5rem;
  padding: 0.15rem 0.35rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 800;
  -moz-appearance: textfield;
}

.bet-input::-webkit-outer-spin-button,
.bet-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.bet-input:focus {
  outline: none;
  border-color: var(--gold);
  background: var(--panel-2);
}

.bet-input::placeholder {
  color: var(--muted);
  font-weight: 600;
}

.quick-bets {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
}

.quick-bet {
  border: none;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.25rem;
}

.quick-bet.is-active {
  color: var(--gold);
}

.btn-spin {
  width: 100%;
  border: none;
  border-radius: 14px;
  padding: 1rem;
  background: linear-gradient(180deg, var(--green) 0%, var(--green-dark) 100%);
  color: #fff;
  font: inherit;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow: 0 4px 0 #14532d;
}

.btn-spin:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 2px 0 #14532d;
}

.btn-spin:disabled {
  opacity: 0.55;
}

.btn-ghost {
  width: 100%;
  margin-top: 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.75rem;
  background: transparent;
  color: var(--text);
  font: inherit;
}

.coming-soon {
  text-align: center;
  color: var(--muted);
  margin-top: 2rem;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 100%;
  max-width: 430px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
  padding: 0.5rem 0.75rem calc(0.5rem + var(--safe-bottom));
  background: var(--panel);
  border-top: 1px solid var(--border);
}

.bottom-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  border: none;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.35rem;
}

.bottom-nav-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.bottom-nav-label {
  line-height: 1.2;
}

.bottom-nav-btn.is-active {
  color: var(--gold);
}

.screen--gate[hidden],
.casino-main[hidden] {
  display: none !important;
}

.screen.screen--gate:not([hidden]) {
  display: flex !important;
}

.screen--gate {
  min-height: 100dvh;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  position: relative;
  z-index: 20;
}

#btn-gate-code {
  cursor: pointer;
  touch-action: manipulation;
  position: relative;
  z-index: 1;
}

.gate-card {
  width: 100%;
  padding: 1.5rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 18px;
  text-align: center;
}

.gate-text {
  color: var(--muted);
  line-height: 1.5;
  margin: 0 0 1rem;
}

.btn-gate-tg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  margin: 0 0 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  background: #2aabee;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(42, 171, 238, 0.35);
}

.btn-gate-tg:hover {
  filter: brightness(1.05);
}

.btn-gate-tg[hidden],
.gate-or[hidden] {
  display: none !important;
}

.gate-or {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.gate-code {
  margin: 1rem 0;
  padding: 0.75rem;
  background: var(--panel-2);
  border-radius: 12px;
}

.gate-code[hidden] {
  display: none !important;
}

.gate-code strong {
  color: var(--gold);
  font-size: 1.4rem;
  letter-spacing: 0.15em;
}

.gate-wait {
  color: var(--muted);
  font-size: 0.85rem;
}

.gate-msg {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
}

.gate-msg--ok {
  color: var(--green);
}

.gate-msg--err {
  color: var(--danger);
}

.gate-link {
  display: inline-block;
  margin-top: 1rem;
  color: var(--gold);
  font-size: 0.9rem;
}

#btn-gate-code[hidden],
.gate-link[hidden] {
  display: none !important;
}

.history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.history-item {
  padding: 0.85rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.history-item-head {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
  font-size: 0.82rem;
}

.history-item-net {
  font-weight: 800;
}

.history-item-net--win {
  color: var(--green);
}

.history-item-net--lose {
  color: var(--danger);
}

.history-item-meta {
  color: var(--muted);
  font-size: 0.78rem;
}

.profile-card {
  padding: 1rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.profile-name {
  margin: 0 0 0.25rem;
  font-size: 1.2rem;
  font-weight: 800;
}

.profile-username,
.profile-linked {
  margin: 0.25rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.profile-balance {
  margin: 0.75rem 0 0;
}

.profile-balance strong {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--gold);
}

.empty-hint {
  text-align: center;
  color: var(--muted);
}

/* —— Общее —— */
.game-panel[hidden] {
  display: none !important;
}

.game-result {
  margin: 0.65rem 0 0;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 700;
}

.game-result--win {
  color: var(--green);
}

.game-result--lose {
  color: var(--danger);
}

/* —— Краш —— */
.crash-machine-frame {
  padding: 0.75rem;
  background: linear-gradient(165deg, #1a1f2e 0%, #0f1218 100%);
  border: 2px solid #334155;
  border-radius: 18px;
  box-shadow: inset 0 0 24px rgba(56, 189, 248, 0.06);
}

.crash-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.crash-badge {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: #e0f2fe;
  background: linear-gradient(90deg, #0369a1, #0ea5e9);
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
}

.crash-rocket {
  font-size: 1.25rem;
  animation: rocket-float 1.5s ease-in-out infinite;
}

@keyframes rocket-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

.crash-graph {
  position: relative;
  height: 10rem;
  background: #0a0e14;
  border: 1px solid #1e293b;
  border-radius: 12px;
  overflow: hidden;
}

#crash-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.crash-mult-display {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(2rem, 12vw, 2.75rem);
  font-weight: 900;
  color: var(--green);
  text-shadow: 0 0 24px rgba(34, 197, 94, 0.35);
  pointer-events: none;
}

.crash-mult-display--hot {
  color: #fde047;
}

.crash-mult-display--win {
  color: var(--green);
  animation: mult-pulse 0.5s ease 2;
}

.crash-mult-display--crash {
  color: var(--danger);
  font-size: clamp(1.2rem, 7vw, 1.6rem);
}

@keyframes mult-pulse {
  50% {
    transform: scale(1.08);
  }
}

.crash-machine--crashed .crash-machine-frame {
  animation: crash-shake 0.4s ease;
  border-color: var(--danger);
}

.crash-machine--won .crash-machine-frame {
  border-color: var(--green);
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.2);
}

@keyframes crash-shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-4px);
  }
  75% {
    transform: translateX(4px);
  }
}

.crash-hint {
  margin: 0.5rem 0 0;
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
}

.crash-cashout-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.55rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.crash-cashout-label {
  font-size: 0.82rem;
  color: var(--muted);
  margin-right: 0.25rem;
}

.crash-cashout-value {
  min-width: 4.5rem;
  text-align: center;
  font-weight: 800;
  color: #38bdf8;
}

.crash-presets {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.crash-preset {
  border: 1px solid var(--border);
  background: var(--panel-2);
  color: var(--text);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
}

.crash-preset:active {
  border-color: #38bdf8;
  color: #38bdf8;
}

.btn-crash {
  background: linear-gradient(180deg, #0ea5e9 0%, #0369a1 100%);
  box-shadow: 0 4px 0 #0c4a6e;
}

.btn-crash:active:not(:disabled) {
  box-shadow: 0 2px 0 #0c4a6e;
}

/* —— Рулетка —— */
.roulette-machine-frame {
  padding: 0.75rem;
  background: linear-gradient(165deg, #1f1812 0%, #12100c 100%);
  border: 2px solid var(--gold-dim);
  border-radius: 18px;
}

.roulette-header {
  text-align: center;
  margin-bottom: 0.65rem;
}

.roulette-badge {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: #1a1408;
  background: linear-gradient(180deg, #fde68a, #d4a012);
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
}

.roulette-wheel-wrap {
  position: relative;
  width: min(16rem, 72vw);
  height: min(16rem, 72vw);
  margin: 0 auto;
}

.roulette-pointer {
  position: absolute;
  top: -0.35rem;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 18px solid var(--gold);
  z-index: 3;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.roulette-wheel {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 4px solid #57534e;
  box-shadow:
    0 0 0 3px var(--gold-dim),
    inset 0 0 20px rgba(0, 0, 0, 0.5);
  transition: transform 4s cubic-bezier(0.15, 0.85, 0.15, 1);
}

.roulette-wheel-numbers {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  pointer-events: none;
}

.roulette-wheel-num {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.35em;
  height: 1.35em;
  margin: -0.675em 0 0 -0.675em;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(0.4rem, 2vw, 0.52rem);
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85);
  transform: rotate(var(--angle)) translateY(calc(-1 * min(5.6rem, 25.5vw)))
    rotate(calc(-1 * var(--angle)));
}

.roulette-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 28%;
  height: 28%;
  border-radius: 50%;
  background: linear-gradient(145deg, #292524, #0c0a09);
  border: 3px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(1.1rem, 5vw, 1.5rem);
  font-weight: 900;
  color: #fff;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
}

.roulette-center--red {
  background: linear-gradient(145deg, #dc2626, #7f1d1d);
}

.roulette-center--black {
  background: linear-gradient(145deg, #404040, #0a0a0a);
}

.roulette-center--green {
  background: linear-gradient(145deg, #16a34a, #14532d);
}

.roulette-machine--win .roulette-machine-frame {
  box-shadow: 0 0 24px rgba(245, 197, 24, 0.15);
}

.roulette-bets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
  margin: 0.85rem 0 0.5rem;
}

.roulette-bet {
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 0.65rem 0.35rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  color: #fff;
  background: var(--panel-2);
}

.roulette-bet.is-active {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
}

.roulette-bet--red {
  background: linear-gradient(180deg, #dc2626, #991b1b);
}

.roulette-bet--black {
  background: linear-gradient(180deg, #3f3f46, #18181b);
}

.roulette-bet--green {
  background: linear-gradient(180deg, #16a34a, #14532d);
}

.roulette-bet--number {
  background: linear-gradient(180deg, #7c3aed, #4c1d95);
}

.roulette-number-wrap {
  margin: 0.65rem 0;
}

.roulette-number-wrap.hidden {
  display: none;
}

.roulette-num-grid-title {
  margin: 0 0 0.45rem;
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
}

.roulette-num-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}

.roulette-num {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  padding: 0.4rem 0;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  color: #fff;
  background: var(--panel-2);
}

.roulette-num--zero {
  grid-column: 1 / -1;
}

.roulette-num--red {
  background: linear-gradient(180deg, #dc2626, #991b1b);
}

.roulette-num--black {
  background: linear-gradient(180deg, #3f3f46, #18181b);
}

.roulette-num--green {
  background: linear-gradient(180deg, #16a34a, #14532d);
}

.roulette-num.is-picked {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  box-shadow: 0 0 10px rgba(245, 197, 24, 0.35);
}

.btn-roulette {
  background: linear-gradient(180deg, #eab308 0%, #a16207 100%);
  box-shadow: 0 4px 0 #713f12;
  color: #1a1408;
}

.btn-roulette:active:not(:disabled) {
  box-shadow: 0 2px 0 #713f12;
}

.hidden {
  display: none !important;
}
