/* Casino atmosphere */
/* Beta notice */
.beta-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  padding: 0.55rem 1rem;
  background: linear-gradient(90deg, rgba(196, 30, 58, 0.92), rgba(154, 117, 16, 0.9));
  color: #fffef8;
  font-size: 0.8rem;
  font-weight: 500;
  text-align: center;
  border-bottom: 1px solid rgba(240, 193, 75, 0.35);
  position: relative;
  z-index: 40;
}

.beta-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.15rem 0.5rem;
  border-radius: 0.3rem;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  background: #06261d;
  color: #f0c14b;
  border: 1px solid rgba(240, 193, 75, 0.5);
}

.beta-title-tag {
  display: inline-block;
  margin-left: 0.55rem;
  vertical-align: middle;
  padding: 0.2rem 0.45rem;
  border-radius: 0.35rem;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #06261d;
  background: linear-gradient(135deg, #f0c14b, #d4a017);
  position: relative;
  top: -0.55em;
}

/* Contact button + modal */
.contact-mail-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  align-self: flex-end;
  padding: 0.5rem 0.9rem;
  border-radius: 0.55rem;
  border: 1px solid rgba(212, 160, 23, 0.4);
  background: rgba(6, 38, 29, 0.7);
  color: #f0c14b;
  font-size: 0.85rem;
  font-weight: 600;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.contact-mail-btn:hover {
  background: rgba(212, 160, 23, 0.15);
  border-color: #d4a017;
  box-shadow: 0 0 16px rgba(212, 160, 23, 0.25);
}

.contact-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.contact-modal[hidden] {
  display: none !important;
}

.contact-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 16, 12, 0.72);
  backdrop-filter: blur(4px);
}

.contact-dialog {
  position: relative;
  width: min(480px, 100%);
  max-height: min(90vh, 720px);
  overflow-y: auto;
  border-radius: 1rem;
  border: 1px solid rgba(212, 160, 23, 0.3);
  background:
    radial-gradient(ellipse 80% 40% at 50% 0%, rgba(212, 160, 23, 0.1), transparent 55%),
    #06261d;
  padding: 1.25rem 1.35rem 1.5rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  animation: fade-in 0.25s ease both;
}

.contact-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.contact-close {
  width: 2rem;
  height: 2rem;
  border-radius: 0.4rem;
  border: 1px solid rgba(212, 160, 23, 0.3);
  background: transparent;
  color: #f0c14b;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.contact-close:hover {
  background: rgba(212, 160, 23, 0.12);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.contact-textarea {
  resize: vertical;
  min-height: 100px;
  font-family: "DM Sans", system-ui, sans-serif;
}

.contact-form-error {
  color: #fca5a5;
  font-size: 0.85rem;
  font-weight: 600;
}

.contact-form .g-recaptcha {
  transform-origin: left top;
}

@media (max-width: 420px) {
  .contact-form .g-recaptcha {
    transform: scale(0.9);
  }
}

/* Star ratings */
.rating-summary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 1rem;
}

.stars-display {
  display: flex;
  gap: 0.2rem;
  font-size: 1.6rem;
  line-height: 1;
  color: rgba(254, 243, 199, 0.2);
}

.stars-display .star.is-on {
  color: #f0c14b;
  text-shadow: 0 0 12px rgba(240, 193, 75, 0.45);
}

.stars-display .star.is-half {
  background: linear-gradient(90deg, #f0c14b 50%, rgba(254, 243, 199, 0.2) 50%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: none;
}

.rating-summary-text {
  font-size: 0.85rem;
  color: rgba(254, 243, 199, 0.65);
}

.rating-summary-text strong {
  font-family: "JetBrains Mono", monospace;
  color: #f0c14b;
  margin-right: 0.4rem;
}

.stars-input {
  display: flex;
  gap: 0.35rem;
}

.star-btn {
  background: transparent;
  border: none;
  padding: 0.15rem;
  font-size: 2rem;
  line-height: 1;
  color: rgba(254, 243, 199, 0.25);
  cursor: pointer;
  transition: color 0.15s, transform 0.15s;
}

.star-btn:hover,
.star-btn.is-active,
.star-btn.is-preview {
  color: #f0c14b;
  transform: scale(1.08);
}

.felt-bg {
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(212, 160, 23, 0.12), transparent 55%),
    radial-gradient(ellipse 60% 40% at 90% 80%, rgba(196, 30, 58, 0.08), transparent 50%),
    radial-gradient(ellipse 50% 40% at 10% 70%, rgba(20, 92, 69, 0.4), transparent 45%),
    linear-gradient(165deg, #06261d 0%, #0d3b2e 40%, #0a2f24 70%, #041a14 100%);
}

.felt-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}

.particles {
  background-image:
    radial-gradient(1.5px 1.5px at 20% 30%, rgba(240, 193, 75, 0.35), transparent),
    radial-gradient(1px 1px at 70% 20%, rgba(240, 193, 75, 0.25), transparent),
    radial-gradient(1.5px 1.5px at 40% 70%, rgba(240, 193, 75, 0.2), transparent),
    radial-gradient(1px 1px at 85% 60%, rgba(240, 193, 75, 0.3), transparent);
  animation: drift 28s linear infinite;
}

@keyframes drift {
  from { transform: translateY(0); }
  to { transform: translateY(-40px); }
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fade-in 0.7s ease-out both;
}

/* Tabs */
.tab-btn {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.55rem 1.1rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(212, 160, 23, 0.25);
  color: rgba(254, 243, 199, 0.65);
  background: rgba(6, 38, 29, 0.6);
  transition: color 0.2s, background 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.tab-btn:hover {
  color: #f0c14b;
  border-color: rgba(212, 160, 23, 0.5);
}

.tab-btn.tab-active {
  color: #06261d;
  background: linear-gradient(135deg, #f0c14b, #d4a017);
  border-color: transparent;
  box-shadow: 0 0 24px rgba(212, 160, 23, 0.3);
}

/* Buttons & inputs */
.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 700;
  padding: 0.75rem 1.5rem;
  border-radius: 0.6rem;
  color: #06261d;
  background: linear-gradient(135deg, #f0c14b 0%, #d4a017 50%, #b8860b 100%);
  box-shadow: 0 4px 20px rgba(212, 160, 23, 0.35);
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

.btn-gold:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow: 0 6px 28px rgba(212, 160, 23, 0.45);
}

.btn-gold:active:not(:disabled) {
  transform: translateY(1px);
}

.btn-gold:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-outline {
  font-weight: 600;
  padding: 0.65rem 1.15rem;
  border-radius: 0.6rem;
  color: #f0c14b;
  border: 1px solid rgba(212, 160, 23, 0.4);
  background: rgba(6, 38, 29, 0.5);
  transition: background 0.2s, border-color 0.2s;
}

.btn-outline:hover {
  background: rgba(212, 160, 23, 0.12);
  border-color: #d4a017;
}

.input-casino {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(212, 160, 23, 0.3);
  background: rgba(4, 26, 20, 0.85);
  color: #fef3c7;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input-casino:focus {
  border-color: #d4a017;
  box-shadow: 0 0 0 3px rgba(212, 160, 23, 0.2);
}

.result-stage {
  border-radius: 1.25rem;
  border: 1px solid rgba(212, 160, 23, 0.2);
  background:
    radial-gradient(circle at 50% 0%, rgba(212, 160, 23, 0.08), transparent 55%),
    rgba(4, 26, 20, 0.65);
  box-shadow: inset 0 1px 0 rgba(240, 193, 75, 0.08);
}

.rng-icon {
  color: #f0c14b;
  margin-bottom: 0.75rem;
  opacity: 0.85;
  animation: rng-spin-soft 8s linear infinite;
}

.rng-icon svg {
  display: block;
}

@keyframes rng-spin-soft {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.result-number {
  text-shadow: 0 0 40px rgba(240, 193, 75, 0.35);
  animation: pop-in 0.45s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}

@keyframes pop-in {
  from { opacity: 0; transform: scale(0.6); }
  to { opacity: 1; transform: scale(1); }
}

/* Playing cards decoration */
.card-fan {
  position: relative;
  width: 120px;
  height: 70px;
}

.playing-card {
  position: absolute;
  width: 52px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 6px;
  background: linear-gradient(160deg, #fffef8, #f5ecd7);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  color: #1a1a1a;
}

.playing-card.card-1 { left: 0; transform: rotate(-18deg); color: #1a1a1a; }
.playing-card.card-2 { left: 34px; transform: rotate(0deg) translateY(-6px); color: #c41e3a; z-index: 2; }
.playing-card.card-3 { left: 68px; transform: rotate(16deg); color: #c41e3a; }

/* Bingo */
.bingo-ball {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 35% 30%, #fffef5, #e8d5a3 45%, #c9a227 100%);
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.4),
    inset 0 -8px 16px rgba(0, 0, 0, 0.12),
    inset 0 8px 12px rgba(255, 255, 255, 0.5);
  animation: ball-bounce 0.5s ease-out;
}

@keyframes ball-bounce {
  0% { transform: scale(0.3) translateY(-40px); opacity: 0; }
  60% { transform: scale(1.08) translateY(0); }
  100% { transform: scale(1); opacity: 1; }
}

.bingo-board {
  display: grid;
  gap: 5px;
  padding: 0.85rem;
  border-radius: 1rem;
  border: 1px solid rgba(212, 160, 23, 0.2);
  background: rgba(4, 26, 20, 0.55);
  overflow-x: auto;
}

/* Filas horizontales: letra + numeros de esa letra */
.bingo-board--75.bingo-board--horizontal {
  grid-template-columns: 44px repeat(15, minmax(28px, 1fr));
  grid-template-rows: repeat(5, auto);
  align-items: stretch;
}

.bingo-board--90.bingo-board--horizontal {
  grid-template-columns: 52px repeat(11, minmax(26px, 1fr));
  grid-template-rows: repeat(9, auto);
}

.bingo-col-letter {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  flex-shrink: 0;
  border-radius: 0.4rem;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #06261d !important;
  background: linear-gradient(145deg, #f0c14b, #d4a017);
  box-shadow: 0 2px 8px rgba(212, 160, 23, 0.3);
  position: sticky;
  left: 0;
  z-index: 2;
}

.bingo-col-letter--range {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.6rem;
  letter-spacing: 0;
  min-height: 30px;
  padding: 0 2px;
  text-align: center;
}

.bingo-cell {
  aspect-ratio: 1;
  min-height: 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  font-family: "JetBrains Mono", monospace;
  font-weight: 600;
  border-radius: 0.35rem;
  color: rgba(254, 243, 199, 0.55);
  border: 1px solid rgba(212, 160, 23, 0.12);
  background: rgba(6, 38, 29, 0.6);
  transition: background 0.25s, color 0.25s, transform 0.25s, box-shadow 0.25s;
  line-height: 1;
  padding: 2px;
}

.bingo-cell-letter {
  display: none; /* la letra ya esta en la fila */
}

.bingo-cell-num {
  display: block;
  font-size: 0.75rem;
  line-height: 1;
}

.bingo-cell--empty {
  visibility: hidden;
  pointer-events: none;
  border: none;
  background: transparent;
}

@media (max-width: 900px) {
  .bingo-board--75.bingo-board--horizontal {
    grid-template-columns: 36px repeat(15, minmax(24px, 1fr));
  }

  .bingo-cell-num {
    font-size: 0.65rem;
  }

  .bingo-col-letter {
    font-size: 1rem;
    min-height: 28px;
  }
}

.bingo-cell.drawn {
  color: #06261d;
  background: linear-gradient(145deg, #f0c14b, #d4a017);
  border-color: transparent;
  box-shadow: 0 0 12px rgba(212, 160, 23, 0.4);
}

.bingo-cell.drawn .bingo-cell-letter {
  color: rgba(6, 38, 29, 0.75);
}

/* Lota cartones (3x9) */
.lota-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.lota-card {
  background: #f7f4ea;
  border: 3px solid #1e4f8c;
  border-radius: 0.35rem;
  padding: 0.5rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.lota-card.is-line {
  box-shadow: 0 0 0 2px #f0c14b, 0 8px 24px rgba(0, 0, 0, 0.35);
}

.lota-card.is-full {
  box-shadow: 0 0 0 3px #c41e3a, 0 8px 28px rgba(196, 30, 58, 0.45);
}

.lota-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.4rem;
  padding: 0 0.15rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.7rem;
  color: #1e4f8c;
  font-weight: 700;
}

.lota-card-status {
  color: #9a7510;
}

.lota-card-status.full {
  color: #c41e3a;
}

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

.lota-cell {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid #7aa0c8;
  background: #fff;
  position: relative;
  font-family: "JetBrains Mono", monospace;
  color: #1e4f8c;
  font-weight: 700;
  font-size: clamp(0.7rem, 1.8vw, 0.95rem);
  line-height: 1;
}

.lota-cell.is-blank {
  background: #2f6fb0;
  border-color: #1e4f8c;
}

.lota-cell .lota-n-main {
  font-size: 1em;
}

.lota-cell .lota-n-sub {
  font-size: 0.55em;
  opacity: 0.55;
  margin-top: 1px;
}

.lota-cell.is-marked::after {
  content: attr(data-n);
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e85a5a, #c41e3a 55%, #8b1528);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85em;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.lota-cell.is-marked .lota-n-main,
.lota-cell.is-marked .lota-n-sub {
  visibility: hidden;
}

.lota-cell.just-marked::after {
  animation: ball-bounce 0.45s ease;
}

.bingo-board--90.bingo-board--horizontal.bingo-board--compact {
  grid-template-columns: repeat(10, minmax(22px, 1fr));
  gap: 3px;
  padding: 0.6rem;
}

.bingo-board--compact .bingo-col-letter {
  display: none;
}

.bingo-board--compact .bingo-cell {
  min-height: 26px;
  font-size: 0.65rem;
  aspect-ratio: 1;
}

.bingo-cell.just-drawn {
  animation: flash-gold 0.6s ease;
  transform: scale(1.12);
}

@keyframes flash-gold {
  0%, 100% { box-shadow: 0 0 12px rgba(212, 160, 23, 0.4); }
  50% { box-shadow: 0 0 28px rgba(240, 193, 75, 0.9); }
}

.bingo-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-family: "JetBrains Mono", monospace;
  font-weight: 600;
  background: rgba(212, 160, 23, 0.15);
  color: #f0c14b;
  border: 1px solid rgba(212, 160, 23, 0.3);
  animation: fade-in 0.3s ease both;
}

/* Roulette */
.roulette-stage {
  min-height: 460px;
}

.roulette-outer {
  position: relative;
  width: min(440px, 90vw);
  height: min(440px, 90vw);
  border-radius: 50%;
  padding: 10px;
  background: radial-gradient(circle, #2a1a0a, #1a1008);
  box-shadow:
    0 0 0 4px #d4a017,
    0 0 0 8px #7a5a10,
    0 20px 50px rgba(0, 0, 0, 0.55),
    0 0 60px rgba(212, 160, 23, 0.15);
}

.roulette-wheel {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: block;
  transition: transform 0s;
}

.roulette-wheel.spinning {
  transition: transform 5s cubic-bezier(0.12, 0.75, 0.15, 1);
}

.roulette-hub {
  position: absolute;
  inset: 38%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, #3d2a12, #1a1008);
  border: 3px solid #d4a017;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.5);
  z-index: 2;
  pointer-events: none;
}

.roulette-pointer {
  position: absolute;
  top: calc(50% - min(220px, 45vw) - 8px);
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-top: 28px solid #f0c14b;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.5));
  z-index: 5;
}

.roulette-chip {
  width: 100px;
  height: 100px;
  margin: 0 auto;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 2.5rem;
  font-weight: 700;
  border: 4px dashed rgba(255, 255, 255, 0.35);
  transition: background 0.3s, color 0.3s, box-shadow 0.3s;
}

.roulette-chip--idle {
  background: rgba(26, 26, 26, 0.8);
  color: rgba(254, 243, 199, 0.4);
}

.roulette-chip--red {
  background: radial-gradient(circle at 35% 30%, #e8455a, #c41e3a 60%, #8b1528);
  color: #fff;
  box-shadow: 0 0 30px rgba(196, 30, 58, 0.45);
}

.roulette-chip--black {
  background: radial-gradient(circle at 35% 30%, #333, #1a1a1a 60%, #0a0a0a);
  color: #fff;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.roulette-chip--green {
  background: radial-gradient(circle at 35% 30%, #2d8a5e, #145c45 60%, #0a3d2e);
  color: #fff;
  box-shadow: 0 0 30px rgba(20, 92, 69, 0.5);
}

.history-chip {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.2);
  animation: fade-in 0.3s ease both;
}

.history-chip.red { background: #c41e3a; }
.history-chip.black { background: #1a1a1a; }
.history-chip.green { background: #145c45; }

/* Roulette outside bets board */
.roulette-bets {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(212, 160, 23, 0.25);
  background: rgba(4, 26, 20, 0.65);
}

.rb-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
}

.rb-row--six {
  grid-template-columns: repeat(6, 1fr);
}

.rb-row--pairs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
}

.rb-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem;
}

.rb-bet {
  border: 1px solid rgba(212, 160, 23, 0.28);
  background: rgba(6, 38, 29, 0.85);
  color: rgba(254, 243, 199, 0.75);
  border-radius: 0.45rem;
  padding: 0.65rem 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  transition: background 0.25s, color 0.25s, box-shadow 0.25s, border-color 0.25s, transform 0.2s;
  cursor: default;
}

.rb-bet span {
  display: block;
  font-weight: 500;
  font-size: 0.65rem;
  color: rgba(254, 243, 199, 0.45);
  margin-top: 0.15rem;
}

.rb-bet--red {
  background: rgba(196, 30, 58, 0.35);
  border-color: rgba(196, 30, 58, 0.5);
}

.rb-bet--black {
  background: rgba(26, 26, 26, 0.75);
  border-color: rgba(255, 255, 255, 0.15);
}

.rb-bet.is-hit {
  color: #06261d;
  background: linear-gradient(145deg, #f0c14b, #d4a017);
  border-color: transparent;
  box-shadow: 0 0 18px rgba(240, 193, 75, 0.55);
  transform: scale(1.03);
}

.rb-bet.is-hit span {
  color: rgba(6, 38, 29, 0.7);
}

.rb-bet--red.is-hit,
.rb-bet--black.is-hit {
  color: #fff;
  box-shadow: 0 0 20px rgba(240, 193, 75, 0.45);
}

.rb-bet--red.is-hit {
  background: linear-gradient(145deg, #e8455a, #c41e3a);
}

.rb-bet--black.is-hit {
  background: linear-gradient(145deg, #333, #1a1a1a);
  border-color: #f0c14b;
}

.roulette-props {
  display: grid;
  gap: 0.4rem;
}

.rp-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.75rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(212, 160, 23, 0.15);
  background: rgba(4, 26, 20, 0.55);
  font-size: 0.8rem;
  color: rgba(254, 243, 199, 0.55);
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}

.rp-item strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.78rem;
  color: rgba(254, 243, 199, 0.85);
  text-align: right;
}

.rp-item.is-hit {
  border-color: rgba(240, 193, 75, 0.55);
  background: rgba(212, 160, 23, 0.18);
  color: #f0c14b;
}

.rp-item.is-hit strong {
  color: #f0c14b;
}

@media (max-width: 720px) {
  .rb-row--six {
    grid-template-columns: repeat(3, 1fr);
  }

  .rb-row--pairs {
    grid-template-columns: 1fr;
  }
}

.range-chip {
  min-width: 3.5rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  color: #06261d;
  background: linear-gradient(145deg, #f0c14b, #d4a017);
  box-shadow: 0 4px 16px rgba(212, 160, 23, 0.3);
  animation: pop-in 0.4s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}

.toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 0.75rem 1.25rem;
  border-radius: 0.6rem;
  background: rgba(196, 30, 58, 0.95);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  z-index: 50;
  opacity: 0;
  transition: opacity 0.25s, transform 0.25s;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.toast.ok {
  background: rgba(20, 92, 69, 0.95);
}

/* Craps / dice table */
.craps-table {
  position: relative;
  border-radius: 1.25rem;
  overflow: hidden;
  border: 3px solid #9a7510;
  box-shadow:
    0 0 0 6px rgba(212, 160, 23, 0.25),
    0 20px 50px rgba(0, 0, 0, 0.45);
}

.craps-rail {
  position: absolute;
  inset: 0;
  border: 14px solid #5c3d1e;
  border-radius: 1.1rem;
  pointer-events: none;
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.35);
  z-index: 2;
}

.craps-felt {
  position: relative;
  min-height: 340px;
  padding: 2.5rem 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.75rem;
  background:
    radial-gradient(ellipse 70% 60% at 50% 40%, rgba(30, 110, 75, 0.5), transparent 70%),
    linear-gradient(160deg, #0a3d2e 0%, #145c45 45%, #0d3b2e 100%);
}

.craps-banner {
  position: absolute;
  top: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.85rem;
  letter-spacing: 0.45em;
  color: rgba(240, 193, 75, 0.55);
  pointer-events: none;
}

.dice-pair {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  justify-content: center;
  z-index: 1;
  min-height: 96px;
}

.die {
  --die-size: 84px;
  width: var(--die-size);
  height: var(--die-size);
  border-radius: 14px;
  background: linear-gradient(145deg, #fffef8 0%, #f0e6d0 55%, #e2d4b5 100%);
  box-shadow:
    0 10px 24px rgba(0, 0, 0, 0.45),
    inset 0 2px 4px rgba(255, 255, 255, 0.8),
    inset 0 -3px 6px rgba(0, 0, 0, 0.08);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  padding: 12px;
  gap: 4px;
  transform-origin: center;
}

.die.rolling {
  animation: die-toss 0.9s ease-in-out;
}

.die.landing {
  animation: die-land 0.35s cubic-bezier(0.22, 1.2, 0.36, 1);
}

@keyframes die-toss {
  0% { transform: translateY(0) rotate(0deg) scale(1); }
  20% { transform: translateY(-48px) rotate(90deg) scale(1.05); }
  40% { transform: translateY(-20px) rotate(180deg) scale(0.95); }
  60% { transform: translateY(-56px) rotate(270deg) scale(1.08); }
  80% { transform: translateY(-10px) rotate(320deg) scale(1); }
  100% { transform: translateY(0) rotate(360deg) scale(1); }
}

@keyframes die-land {
  0% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.pip {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: transparent;
  justify-self: center;
  align-self: center;
}

.die[data-face="1"] .pip[data-p="5"],
.die[data-face="2"] .pip[data-p="1"],
.die[data-face="2"] .pip[data-p="9"],
.die[data-face="3"] .pip[data-p="1"],
.die[data-face="3"] .pip[data-p="5"],
.die[data-face="3"] .pip[data-p="9"],
.die[data-face="4"] .pip[data-p="1"],
.die[data-face="4"] .pip[data-p="3"],
.die[data-face="4"] .pip[data-p="7"],
.die[data-face="4"] .pip[data-p="9"],
.die[data-face="5"] .pip[data-p="1"],
.die[data-face="5"] .pip[data-p="3"],
.die[data-face="5"] .pip[data-p="5"],
.die[data-face="5"] .pip[data-p="7"],
.die[data-face="5"] .pip[data-p="9"],
.die[data-face="6"] .pip[data-p="1"],
.die[data-face="6"] .pip[data-p="3"],
.die[data-face="6"] .pip[data-p="4"],
.die[data-face="6"] .pip[data-p="6"],
.die[data-face="6"] .pip[data-p="7"],
.die[data-face="6"] .pip[data-p="9"] {
  background: radial-gradient(circle at 35% 30%, #3a1515, #1a0505 70%);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.craps-sum-box {
  text-align: center;
  z-index: 1;
}

.craps-sum {
  font-size: 4rem;
  line-height: 1;
  font-weight: 700;
  color: #f0c14b;
  text-shadow: 0 0 36px rgba(240, 193, 75, 0.4);
}

.craps-sum.pop {
  animation: pop-in 0.45s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}

.craps-hist {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  border-radius: 0.6rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  font-weight: 600;
  background: rgba(4, 26, 20, 0.7);
  border: 1px solid rgba(212, 160, 23, 0.25);
  color: #fef3c7;
  animation: fade-in 0.3s ease both;
}

.craps-hist .mini-die {
  width: 22px;
  height: 22px;
  border-radius: 4px;
  background: #f5ecd7;
  color: #1a0505;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
}

.craps-hist .hist-sum {
  color: #f0c14b;
  margin-left: 0.15rem;
}

.craps-hist.natural { border-color: rgba(45, 138, 94, 0.6); }
.craps-hist.craps { border-color: rgba(196, 30, 58, 0.55); }

/* Blackjack */
.bj-table {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 1.75rem 1.25rem;
  border-radius: 1.25rem;
  border: 3px solid #9a7510;
  background:
    radial-gradient(ellipse 70% 50% at 50% 40%, rgba(30, 110, 75, 0.45), transparent 70%),
    linear-gradient(165deg, #0a3d2e, #0d3b2e 55%, #06261d);
  box-shadow:
    0 0 0 6px rgba(212, 160, 23, 0.2),
    0 16px 40px rgba(0, 0, 0, 0.4);
}

.bj-hand-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.bj-value {
  font-family: "JetBrains Mono", monospace;
  font-size: 1.1rem;
  font-weight: 700;
  color: #f0c14b;
}

.bj-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  min-height: 110px;
  align-items: center;
}

.bj-card {
  width: 72px;
  height: 102px;
  border-radius: 8px;
  background: linear-gradient(160deg, #fffef8, #f0e6d0);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0.4rem 0.45rem;
  font-family: "JetBrains Mono", monospace;
  font-weight: 700;
  color: #1a1a1a;
  animation: pop-in 0.35s cubic-bezier(0.22, 1.2, 0.36, 1) both;
  position: relative;
}

.bj-card.is-red {
  color: #c41e3a;
}

.bj-card.is-hidden {
  background:
    repeating-linear-gradient(
      45deg,
      #7a1528,
      #7a1528 6px,
      #9a1c34 6px,
      #9a1c34 12px
    );
  color: transparent;
  border-color: #5c101e;
}

.bj-card.is-hidden::after {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(240, 193, 75, 0.35);
  border-radius: 4px;
}

.bj-card-rank {
  font-size: 1rem;
  line-height: 1;
}

.bj-card-suit {
  font-size: 1.4rem;
  text-align: center;
  line-height: 1;
}

.bj-card-rank-br {
  font-size: 1rem;
  line-height: 1;
  align-self: flex-end;
  transform: rotate(180deg);
}

.bj-message {
  text-align: center;
  font-weight: 600;
  font-size: 1rem;
  color: #f0c14b;
  min-height: 1.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  background: rgba(4, 26, 20, 0.45);
  border: 1px solid rgba(212, 160, 23, 0.2);
}

.bj-message.is-win {
  color: #6ee7b7;
  border-color: rgba(45, 138, 94, 0.5);
}

.bj-message.is-lose {
  color: #fca5a5;
  border-color: rgba(196, 30, 58, 0.45);
}

.bj-message.is-push {
  color: #fde68a;
}

@media (max-width: 640px) {
  .bj-card {
    width: 58px;
    height: 84px;
  }
}

/* Craps betting zones */
.craps-bets {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(212, 160, 23, 0.25);
  background: rgba(4, 26, 20, 0.65);
}

.cb-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: rgba(240, 193, 75, 0.7);
  margin-bottom: 0.45rem;
}

.cb-sums {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  gap: 0.35rem;
}

.cb-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.45rem;
}

.cb-row--2 {
  grid-template-columns: repeat(2, 1fr);
}

.cb-row--4 {
  grid-template-columns: repeat(4, 1fr);
}

.cb-bet {
  border: 1px solid rgba(212, 160, 23, 0.28);
  background: rgba(6, 38, 29, 0.85);
  color: rgba(254, 243, 199, 0.78);
  border-radius: 0.45rem;
  padding: 0.7rem 0.4rem;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  transition: background 0.25s, color 0.25s, box-shadow 0.25s, border-color 0.25s, transform 0.2s;
  cursor: default;
}

.cb-bet span {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.65rem;
  font-weight: 500;
  color: rgba(254, 243, 199, 0.45);
}

.cb-sum {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.85rem;
  padding: 0.55rem 0.2rem;
}

.cb-bet--big {
  font-size: 0.95rem;
  padding: 0.9rem 0.5rem;
}

.cb-bet.is-hit {
  color: #06261d;
  background: linear-gradient(145deg, #f0c14b, #d4a017);
  border-color: transparent;
  box-shadow: 0 0 18px rgba(240, 193, 75, 0.55);
  transform: scale(1.04);
}

.cb-bet.is-hit span {
  color: rgba(6, 38, 29, 0.7);
}

.cb-bet.is-hit-red {
  color: #fff;
  background: linear-gradient(145deg, #e8455a, #c41e3a 55%, #8b1528);
  border-color: transparent;
  box-shadow: 0 0 22px rgba(196, 30, 58, 0.65);
  transform: scale(1.06);
}

.cb-bet.is-hit-red span {
  color: rgba(255, 255, 255, 0.85);
}

.cb-bet--big.is-hit {
  background: linear-gradient(145deg, #f5d76e, #d4a017 40%, #c41e3a);
  color: #fff;
}

.cb-bet--big.is-hit span {
  color: rgba(255, 255, 255, 0.85);
}

@media (max-width: 720px) {
  .cb-sums {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .cb-row,
  .cb-row--4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Lottery */
.lottery-stage {
  display: grid;
  gap: 1.5rem;
  padding: 1.5rem;
  border-radius: 1.25rem;
  border: 1px solid rgba(212, 160, 23, 0.22);
  background:
    radial-gradient(ellipse 60% 50% at 50% 0%, rgba(196, 30, 58, 0.12), transparent 55%),
    rgba(4, 26, 20, 0.7);
}

.lottery-machine {
  display: flex;
  justify-content: center;
}

.lottery-drum {
  width: min(220px, 55vw);
  height: min(220px, 55vw);
  border-radius: 50%;
  border: 6px solid #d4a017;
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.12), transparent 40%),
    radial-gradient(circle at 50% 50%, #1a3d32, #06261d 70%);
  box-shadow:
    inset 0 0 40px rgba(0, 0, 0, 0.45),
    0 0 30px rgba(212, 160, 23, 0.2);
  position: relative;
  overflow: hidden;
}

.lottery-drum::before {
  content: "";
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  border: 2px dashed rgba(240, 193, 75, 0.35);
}

.lottery-drum.spinning {
  animation: drum-spin 1.2s linear infinite;
}

.lottery-drum.spinning::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff, #f0c14b 40%, #c41e3a);
  top: 22%;
  left: 40%;
  box-shadow:
    40px 30px 0 -2px #f0c14b,
    -28px 45px 0 -3px #c41e3a,
    20px 70px 0 -1px #fffef5;
  animation: ball-tumble 0.6s ease-in-out infinite alternate;
}

@keyframes drum-spin {
  to { transform: rotate(360deg); }
}

@keyframes ball-tumble {
  from { transform: translate(0, 0); }
  to { transform: translate(12px, 18px); }
}

.lottery-balls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  min-height: 4rem;
}

.lotto-ball {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "JetBrains Mono", monospace;
  font-weight: 700;
  font-size: 1.15rem;
  color: #06261d;
  background: radial-gradient(circle at 32% 28%, #fffef8, #f0c14b 48%, #c9a227);
  box-shadow:
    0 8px 18px rgba(0, 0, 0, 0.35),
    inset 0 -4px 8px rgba(0, 0, 0, 0.12),
    inset 0 4px 8px rgba(255, 255, 255, 0.45);
  animation: ball-drop 0.45s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}

@keyframes ball-drop {
  from {
    opacity: 0;
    transform: translateY(-28px) scale(0.4);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.lotto-ball.bonus {
  color: #fff;
  background: radial-gradient(circle at 32% 28%, #ff8a9a, #c41e3a 50%, #8b1528);
}

.lottery-bonus-wrap {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(212, 160, 23, 0.15);
}

.lottery-hist-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(212, 160, 23, 0.18);
  background: rgba(4, 26, 20, 0.55);
  animation: fade-in 0.3s ease both;
}

.lottery-hist-row .hist-label {
  font-size: 0.75rem;
  color: rgba(240, 193, 75, 0.7);
  min-width: 7rem;
}

.lottery-hist-row .hist-nums {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.9rem;
  font-weight: 600;
  color: #fef3c7;
  letter-spacing: 0.04em;
}

.lottery-hist-row .hist-bonus {
  color: #fca5a5;
}

@media (max-width: 640px) {
  .roulette-stage {
    min-height: 360px;
  }

  .die {
    --die-size: 68px;
  }

  .craps-sum {
    font-size: 3rem;
  }

  .lotto-ball {
    width: 46px;
    height: 46px;
    font-size: 0.95rem;
  }
}
