/* ===== DOGECASINO — base palette + utilities ===== */
/* Layered on top of Tailwind CDN. Custom classes mirror the names used in
   cryptokeno's frontend (glass, glass-strong, font-display, text-gradient,
   play-btn, nav-item) so component code can stay consistent across sites. */

:root {
  --bg-base:        #0b1220;
  --bg-elevated:    #111a2e;
  --doge-gold:      #f59e0b;   /* primary */
  --doge-gold-hi:   #fbbf24;   /* hover/glow */
  --doge-orange:    #ea580c;   /* accent */
  --doge-blue:      #38bdf8;   /* "much wow" sky-blue accent for occasional contrast */
  --text-primary:   #f8fafc;
  --text-muted:     #94a3b8;
  --text-dim:       #64748b;
}

html, body, #root {
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin: 0;
  min-height: 100vh;
}

/* Subtle radial background — warm amber glow in the center fading to deep slate */
body {
  background:
    radial-gradient(ellipse at top, rgba(245, 158, 11, 0.08), transparent 50%),
    radial-gradient(ellipse at bottom right, rgba(234, 88, 12, 0.05), transparent 60%),
    var(--bg-base);
  background-attachment: fixed;
}

.font-display {
  font-family: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  letter-spacing: -0.01em;
}

/* Gold-to-orange gradient on the brand text */
.text-gradient {
  background: linear-gradient(135deg, var(--doge-gold) 0%, var(--doge-orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Glass surfaces — translucent, blurred */
.glass {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.glass-strong {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(245, 158, 11, 0.12);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* Primary action button — Doge gold gradient */
.play-btn {
  background: linear-gradient(135deg, var(--doge-gold) 0%, var(--doge-orange) 100%);
  color: #1a1a1a;
  font-weight: 700;
  transition: all 150ms ease;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.25);
}
.play-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--doge-gold-hi) 0%, #f97316 100%);
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.35);
  transform: translateY(-1px);
}
.play-btn:active:not(:disabled) {
  transform: translateY(0);
}

/* Navbar link items */
.nav-item {
  position: relative;
  transition: color 150ms ease;
}
.nav-item.active {
  color: var(--doge-gold);
}
.nav-item.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 12px;
  right: 12px;
  height: 2px;
  background: linear-gradient(90deg, var(--doge-gold), var(--doge-orange));
  border-radius: 2px 2px 0 0;
}

/* Game switcher tab pills */
.switcher-tab {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  transition: all 150ms ease;
}
.switcher-tab:hover:not(.active) {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
}
.switcher-tab.active {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(234, 88, 12, 0.10));
  border-color: rgba(245, 158, 11, 0.4);
  color: var(--doge-gold);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.15);
}

/* Coming-soon panel — soft float animation */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}
.float-anim {
  animation: float 3s ease-in-out infinite;
}

/* Inputs */
input[type='number'], input[type='text'] {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  transition: border-color 150ms ease;
}
input[type='number']:focus, input[type='text']:focus {
  border-color: var(--doge-gold);
  outline: none;
}

/* Scrollbar */
::-webkit-scrollbar       { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(245, 158, 11, 0.2); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(245, 158, 11, 0.35); }

/* ── Keno board cells (Phase 3b) ────────────────────────────────────── */
.keno-cell {
  transition: all 150ms ease;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  cursor: pointer;
}

.keno-cell-idle:hover:not(:disabled) {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.35);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.keno-cell-selected {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.5), rgba(234, 88, 12, 0.4));
  border-color: rgba(245, 158, 11, 0.85);
  color: #fff7ed;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.25);
}
.keno-cell-selected:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.6), rgba(234, 88, 12, 0.5));
}

.keno-cell-drawn {
  background: rgba(148, 163, 184, 0.12);
  border-color: rgba(148, 163, 184, 0.3);
  color: var(--text-muted);
}

.keno-cell-matched {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.45), rgba(5, 150, 105, 0.35));
  border-color: rgba(16, 185, 129, 0.9);
  color: #ecfdf5;
  box-shadow:
    0 0 20px rgba(16, 185, 129, 0.35),
    inset 0 0 12px rgba(16, 185, 129, 0.15);
  animation: matchPulse 600ms ease-out;
}

@keyframes matchPulse {
  0%   { transform: scale(1);    box-shadow: 0 0 0 rgba(16, 185, 129, 0); }
  50%  { transform: scale(1.08); box-shadow: 0 0 28px rgba(16, 185, 129, 0.65); }
  100% { transform: scale(1);    box-shadow: 0 0 20px rgba(16, 185, 129, 0.35); }
}

/* ── Roulette table cells (Phase 4b) ────────────────────────────────── */
.roulette-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  color: #f8fafc;
  cursor: pointer;
  transition: all 100ms ease;
  border: 1px solid rgba(255, 255, 255, 0.08);
  user-select: none;
}
.roulette-cell:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.15);
  border-color: rgba(245, 158, 11, 0.5);
}
.roulette-cell:active:not(:disabled) { transform: translateY(0); }

.roulette-cell-red {
  background: linear-gradient(135deg, #b91c1c, #7f1d1d);
}
.roulette-cell-black {
  background: linear-gradient(135deg, #1f2937, #0f172a);
}
.roulette-cell-green {
  background: linear-gradient(135deg, #047857, #064e3b);
}

.roulette-cell-outside {
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  flex-direction: column;
  line-height: 1.1;
}
.roulette-cell-outside:hover:not(:disabled) {
  background: rgba(245, 158, 11, 0.1);
  color: var(--text-primary);
}

.roulette-cell-winner {
  animation: rouletteWinnerPulse 1.2s ease-out;
  box-shadow:
    0 0 0 2px rgba(245, 158, 11, 0.9),
    0 0 24px rgba(245, 158, 11, 0.55);
  border-color: rgba(245, 158, 11, 0.95);
}

@keyframes rouletteWinnerPulse {
  0%   { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
  50%  { box-shadow: 0 0 0 4px rgba(245, 158, 11, 1), 0 0 36px rgba(245, 158, 11, 0.7); }
  100% { box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.9), 0 0 24px rgba(245, 158, 11, 0.55); }
}

/* ── Blackjack table + cards (Phase 5b) ────────────────────────────── */
.bj-felt {
  background:
    radial-gradient(ellipse at center, rgba(120, 53, 15, 0.4), rgba(15, 23, 42, 0.85)),
    var(--bg-elevated);
  border: 1px solid rgba(245, 158, 11, 0.15);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.bj-hand {
  padding: 12px;
  border-radius: 10px;
  transition: box-shadow 200ms ease;
}
.bj-hand-winner {
  box-shadow: 0 0 24px rgba(245, 158, 11, 0.25), inset 0 0 0 1px rgba(245, 158, 11, 0.35);
}

.bj-hand-cards {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 110px;
}

/* Playing card — ~70 × 100 with rounded corners */
.bj-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 70px;
  height: 100px;
  border-radius: 8px;
  padding: 6px 8px;
  background: linear-gradient(180deg, #fdfdfd, #ececec);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(0, 0, 0, 0.15);
  font-family: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  position: relative;
  flex-shrink: 0;
  animation: bjCardDeal 240ms cubic-bezier(0.2, 0.9, 0.3, 1.2);
}

@keyframes bjCardDeal {
  0%   { transform: translateY(-30px) rotate(-8deg); opacity: 0; }
  100% { transform: translateY(0)      rotate(0);    opacity: 1; }
}

.bj-card-red   { color: #b91c1c; }
.bj-card-black { color: #1f2937; }

.bj-card-corner-tl,
.bj-card-corner-br {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
}
.bj-card-corner-br {
  transform: rotate(180deg);
}
.bj-card-rank {
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
}
.bj-card-suit {
  font-size: 14px;
  line-height: 1;
  margin-top: 1px;
}
.bj-card-center {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  pointer-events: none;
}

.bj-card-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 100px;
  border-radius: 8px;
  background:
    repeating-linear-gradient(45deg,
      rgba(245, 158, 11, 0.4) 0,
      rgba(245, 158, 11, 0.4) 8px,
      rgba(234, 88, 12, 0.4)  8px,
      rgba(234, 88, 12, 0.4)  16px),
    linear-gradient(135deg, #b45309, #7c2d12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.4),
    inset 0 0 0 3px rgba(255, 255, 255, 0.08);
  color: white;
  flex-shrink: 0;
  animation: bjCardDeal 240ms cubic-bezier(0.2, 0.9, 0.3, 1.2);
}

.bj-card-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 100px;
  border-radius: 8px;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
}
