/* ═══════════════════════════════════════════════════════════════════
   Omaha Royale — Premium Casino App Styles (Half-Table Edition)
   Viktory Gaming © 2026
   ═══════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

:root {
  --bg: #0a0e17;
  --surface: #111827;
  --surface-2: #1a2234;
  --surface-3: #243044;
  --felt: #0d4422;
  --felt-light: #166534;
  --felt-dark: #052e13;
  --felt-edge: #0a3518;
  --rail: #4a2e12;
  --rail-mid: #6b4420;
  --rail-light: #8b6914;
  --rail-shine: #c9a055;
  --gold: #d4a543;
  --gold-light: #f0d078;
  --gold-dim: #8a6d28;
  --accent: #10b981;
  --accent-dim: #065f46;
  --danger: #ef4444;
  --danger-dim: #7f1d1d;
  --warning: #f59e0b;
  --info: #3b82f6;
  --text: #f1f5f9;
  --text-dim: #64748b;
  --text-muted: #475569;
  --border: #1e293b;
  --border-light: #334155;
  --card-white: #fefdf8;
  --card-shadow: rgba(0,0,0,0.4);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'SF Mono', monospace;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: var(--bg);
  font-family: var(--font);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── App Shell ──────────────────────────────────────────────────── */
.app {
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Header ─────────────────────────────────────────────────────── */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  margin-bottom: 12px;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-crown {
  width: 44px;
  height: 44px;
  filter: drop-shadow(0 2px 8px rgba(212,165,67,0.3));
}

.logo-text h1 {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--gold);
  letter-spacing: 0.06em;
  line-height: 1;
}

.logo-text .subtitle {
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-top: 3px;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.session-stats {
  text-align: right;
  padding-right: 12px;
  border-right: 1px solid var(--border);
}

.session-stats .label {
  font-size: 0.55rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.session-stats .value {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 600;
}

.header-btn {
  background: var(--surface-2);
  border: 1px solid var(--border-light);
  color: var(--text-dim);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font);
}

.header-btn:hover {
  background: var(--surface-3);
  color: var(--text);
  border-color: var(--gold-dim);
}

/* ── Stage Bar ──────────────────────────────────────────────────── */
.stage-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

.stage-pill {
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: all 0.3s ease;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
}

.stage-pill.active {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  color: #1a0f00;
  border-color: transparent;
  box-shadow: 0 2px 12px rgba(212,165,67,0.3);
}

.stage-pill.completed {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: var(--accent-dim);
}

.acting-indicator {
  margin-left: 8px;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--gold);
  animation: pulse-glow 1.5s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}


/* ═══════════════════════════════════════════════════════════════════
   HALF-TABLE — CASINO STYLE
   Flat top (dealer side), curved bottom (player side)
   ═══════════════════════════════════════════════════════════════════ */

.felt-table-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
  padding: 0 8px;
}

.felt-table {
  position: relative;
  width: 100%;
  max-width: 960px;
  height: 0;
  padding-bottom: 60%;  /* half-circle aspect — taller to fit larger bet circles and cards */

  /* Half-oval shape: flat top, rounded bottom */
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  overflow: visible;

  /* Multi-layer green felt */
  background:
    radial-gradient(ellipse 90% 130% at 50% 0%, #1a6b3a 0%, var(--felt) 45%, var(--felt-dark) 75%, #031a0a 100%);

  /* Wooden rail border — thicker at bottom curve, thinner at top */
  border-left: 10px solid var(--rail);
  border-right: 10px solid var(--rail);
  border-bottom: 12px solid var(--rail);
  border-top: 6px solid var(--rail-mid);

  box-shadow:
    /* Inner rail gleam */
    inset 0 0 0 2px var(--rail-light),
    inset 0 0 0 4px rgba(0,0,0,0.35),
    /* Felt depth shadow */
    inset 0 20px 50px rgba(0,0,0,0.35),
    inset 0 -10px 30px rgba(0,0,0,0.2),
    /* Outer drop shadow */
    0 8px 40px rgba(0,0,0,0.6),
    0 2px 80px rgba(0,0,0,0.25);
}

/* Felt fabric texture */
.felt-table::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    repeating-linear-gradient(
      90deg,
      transparent, transparent 3px,
      rgba(255,255,255,0.006) 3px, rgba(255,255,255,0.006) 4px
    ),
    repeating-linear-gradient(
      0deg,
      transparent, transparent 3px,
      rgba(0,0,0,0.01) 3px, rgba(0,0,0,0.01) 4px
    );
  pointer-events: none;
  z-index: 1;
}

/* Gold trim line following half-oval inside the felt */
.felt-table::after {
  content: '';
  position: absolute;
  top: 14px; left: 18px; right: 18px; bottom: 18px;
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  border: 1.5px solid rgba(212,165,67,0.12);
  border-top: 1px solid rgba(212,165,67,0.06);
  pointer-events: none;
  z-index: 1;
}

/* Rail highlight gradient overlay */
.table-rail {
  position: absolute;
  inset: -12px;
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  pointer-events: none;
  z-index: 2;
  background:
    linear-gradient(180deg,
      rgba(201,160,85,0.2) 0%,
      rgba(74,46,18,0.05) 30%,
      rgba(201,160,85,0.12) 100%
    );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  padding: 10px;
}

/* ── Dealer Area — behind the flat top edge ──────────────────────── */
.dealer-area {
  position: absolute;
  top: 6%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  z-index: 10;
}

.dealer-label {
  font-size: 0.55rem;
  font-weight: 800;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-bottom: 5px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.dealer-cards {
  display: flex;
  gap: 4px;
  justify-content: center;
}

.dealer-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 5px;
}

.dealer-hand-label {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text);
  text-shadow: 0 1px 4px rgba(0,0,0,0.7);
}

.qualify-badge {
  font-size: 0.5rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  letter-spacing: 0.06em;
  text-shadow: none;
}

.qualify-badge.yes {
  background: rgba(16,185,129,0.25);
  color: #6ee7b7;
  border: 1px solid rgba(16,185,129,0.4);
}

.qualify-badge.no {
  background: rgba(239,68,68,0.25);
  color: #fca5a5;
  border: 1px solid rgba(239,68,68,0.4);
}

/* ── Community Cards — upper center of half table ────────────────── */
.community-area {
  position: absolute;
  top: 32%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  z-index: 10;
}

.community-label {
  font-size: 0.5rem;
  font-weight: 800;
  color: rgba(255,255,255,0.2);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin-bottom: 5px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.community-cards {
  display: flex;
  gap: 5px;
  justify-content: center;
}

/* ── Seat Spots — arrayed along the curved bottom ────────────────── */
.seat-spot {
  position: absolute;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: all 0.3s ease;
}

/*
 * Half-table seat layout — vertical bet circles pointing toward dealer:
 *
 *  ┌───────────────── flat top (dealer) ──────────────────┐
 *  │                                                       │
 *  │                  community cards                      │
 *  │                                                       │
 *  │ [bets]                                       [bets]   │
 *  │ [S1  ]                                       [S5  ]   │
 *  │                                                       │
 *  │      [bets]       [bets]        [bets]                │
 *  │      [S2  ]       [S3  ]        [S4  ]                │
 *  └───────────── curved bottom (players) ────────────────┘
 *
 * Bet circles extend upward toward dealer; cards sit at player edge.
 */

.seat-spot.pos-1 {
  top: 38%;
  left: -1%;
}
.seat-spot.pos-2 {
  bottom: 4%;
  left: 16%;
}
.seat-spot.pos-3 {
  bottom: -2%;
  left: 50%;
  transform: translateX(-50%);
}
.seat-spot.pos-4 {
  bottom: 4%;
  right: 16%;
}
.seat-spot.pos-5 {
  top: 38%;
  right: -1%;
}

.seat-spot.inactive { opacity: 0.25; }

.spot-label {
  display: flex;
  align-items: center;
  gap: 6px;
}

.spot-id {
  background: rgba(0,0,0,0.55);
  color: var(--gold-light);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: 8px;
  border: 1px solid rgba(212,165,67,0.2);
  white-space: nowrap;
  backdrop-filter: blur(4px);
}

.spot-bankroll {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--text);
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  white-space: nowrap;
}

.spot-cards {
  display: flex;
  gap: 2px;
}

/* ── Player info wrapper ─────────────────────────────────────────── */
.spot-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

/* ── Bet Area — side bets left, main bets right ────────────────── */
.spot-bet-area {
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  gap: 4px;
  margin-bottom: 4px;
}

/* Main bet circles — vertical stack toward dealer */
.spot-bet-circles {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

/* Side bets — parallel vertical column to the left */
.spot-side-bets {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.bet-circle {
  position: relative;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bet-circle-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px dashed rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s ease;
}

.bet-circle.has-bet .bet-circle-ring {
  border-style: solid;
  border-color: rgba(255,255,255,0.25);
}

.bet-circle-label {
  font-size: 0.52rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  text-shadow: 0 1px 2px rgba(0,0,0,0.6);
}

.bet-circle.has-bet .bet-circle-label {
  opacity: 0.18;
  font-size: 0.42rem;
}

/* Circle color accents */
.bet-circle.circle-ante .bet-circle-ring { border-color: rgba(212,165,67,0.2); }
.bet-circle.circle-blind .bet-circle-ring { border-color: rgba(212,165,67,0.2); }
.bet-circle.circle-play .bet-circle-ring { border-color: rgba(59,130,246,0.2); }
.bet-circle.circle-trips .bet-circle-ring { border-color: rgba(167,139,250,0.2); }
.bet-circle.circle-qq .bet-circle-ring { border-color: rgba(192,132,252,0.2); }

.bet-circle.circle-ante.has-bet .bet-circle-ring { border-color: rgba(212,165,67,0.4); }
.bet-circle.circle-blind.has-bet .bet-circle-ring { border-color: rgba(212,165,67,0.4); }
.bet-circle.circle-play.has-bet .bet-circle-ring { border-color: rgba(59,130,246,0.4); }
.bet-circle.circle-trips.has-bet .bet-circle-ring { border-color: rgba(167,139,250,0.4); }
.bet-circle.circle-qq.has-bet .bet-circle-ring { border-color: rgba(192,132,252,0.4); }

/* Chip stack container (inside a betting circle) */
.bet-circle-chips {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
}

/* ── Chip Stack ──────────────────────────────────────────────────── */
.chip-stack {
  position: relative;
  width: 34px;
  height: 44px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.chip-stack.chip-drop {
  animation: chipDrop 0.35s cubic-bezier(0.2, 0, 0.2, 1) both;
}

@keyframes chipDrop {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.85);
  }
  80% {
    opacity: 1;
    transform: translateY(2px) scale(1.02);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.chip-piece {
  position: absolute;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 35% 35%, rgba(255,255,255,0.15) 0%, transparent 60%),
    linear-gradient(135deg, var(--chip-color) 0%, var(--chip-color) 100%);
  border: 2.5px solid var(--chip-rim);
  box-shadow:
    0 1px 3px rgba(0,0,0,0.5),
    inset 0 1px 1px rgba(255,255,255,0.1);
}

/* Dashed inner ring pattern on chips */
.chip-piece::before {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  border: 1px dashed var(--chip-rim);
  opacity: 0.4;
}

.chip-val {
  font-family: var(--mono);
  font-size: 0.55rem;
  font-weight: 800;
  color: var(--chip-text);
  text-shadow: 0 1px 1px rgba(0,0,0,0.4);
  position: relative;
  z-index: 1;
}

.chip-total {
  position: absolute;
  bottom: -14px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 900;
  color: #fff;
  white-space: nowrap;
  text-shadow: 0 0 6px rgba(0,0,0,1), 0 1px 4px rgba(0,0,0,0.9), 0 0 12px rgba(212,165,67,0.4);
  background: rgba(0,0,0,0.65);
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.02em;
  z-index: 10;
}

.spot-folded {
  font-size: 0.55rem;
  font-weight: 800;
  color: #ef4444;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  letter-spacing: 0.08em;
}

.spot-strength {
  font-size: 0.56rem;
  font-weight: 700;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  white-space: nowrap;
  background: rgba(0,0,0,0.45);
  padding: 1px 8px;
  border-radius: 6px;
  backdrop-filter: blur(4px);
  letter-spacing: 0.02em;
}

.panel-live {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.spot-result {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 800;
  text-shadow: 0 2px 8px rgba(0,0,0,0.7);
  padding: 2px 10px;
  border-radius: 8px;
  backdrop-filter: blur(4px);
}

.spot-result.win {
  color: #34d399;
  background: rgba(16,185,129,0.2);
}

.spot-result.loss {
  color: #f87171;
  background: rgba(239,68,68,0.2);
}

.spot-result.push {
  color: #fbbf24;
  background: rgba(245,158,11,0.2);
}

/* Acting glow ring */
.spot-acting-ring {
  position: absolute;
  inset: -8px;
  border-radius: 12px;
  border: 2px solid var(--gold);
  box-shadow: 0 0 16px rgba(212,165,67,0.35);
  animation: actRing 1.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes actRing {
  0%, 100% { opacity: 1; box-shadow: 0 0 16px rgba(212,165,67,0.35); }
  50% { opacity: 0.5; box-shadow: 0 0 24px rgba(212,165,67,0.5); }
}

/* ── Deal Button (on felt, between community and seats) ──────────── */
.felt-deal-area {
  position: absolute;
  top: 54%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 15;
}

.btn-deal {
  background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold) 100%);
  color: #1a0f00;
  font-family: var(--font);
  font-weight: 800;
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  border: none;
  border-radius: var(--radius);
  padding: 10px 40px;
  cursor: pointer;
  box-shadow: 0 4px 24px rgba(212,165,67,0.35), 0 0 0 2px rgba(212,165,67,0.15);
  transition: all 0.2s ease;
  text-transform: uppercase;
  white-space: nowrap;
}

.btn-deal:hover {
  background: linear-gradient(180deg, #f4e0a0, var(--gold-light));
  box-shadow: 0 8px 32px rgba(212,165,67,0.5), 0 0 0 2px rgba(212,165,67,0.35);
  transform: translateY(-2px);
}

.btn-deal:active {
  transform: translateY(0);
  box-shadow: 0 2px 12px rgba(212,165,67,0.3);
}


/* ── Playing Cards ──────────────────────────────────────────────── */
.card {
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 6px;
  font-family: var(--mono);
  font-weight: 700;
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  flex-shrink: 0;
}

.card-sm {
  width: 36px;
  height: 50px;
  font-size: 0.72rem;
  padding: 2px 3px;
  border-radius: 5px;
}

.card-md {
  width: 46px;
  height: 64px;
  font-size: 0.9rem;
  padding: 3px 4px;
}

.card-lg {
  width: 58px;
  height: 82px;
  font-size: 1.1rem;
  padding: 4px 6px;
}

.card-face {
  background: linear-gradient(170deg, #ffffff 0%, var(--card-white) 40%, #f5f0e0 100%);
  border: 1px solid #c8c0a8;
  box-shadow:
    0 2px 8px var(--card-shadow),
    inset 0 1px 0 rgba(255,255,255,0.95),
    inset 0 -1px 0 rgba(0,0,0,0.05);
}

.card-face .card-corner { line-height: 1; }
.card-face .card-center { text-align: center; font-size: 1.3em; line-height: 1; }
.card-face .card-bottom { line-height: 1; transform: rotate(180deg); align-self: flex-end; }

/* 4-color deck */
.card-face.hearts .card-corner,
.card-face.hearts .card-center,
.card-face.hearts .card-bottom { color: #dc2626; }

.card-face.diamonds .card-corner,
.card-face.diamonds .card-center,
.card-face.diamonds .card-bottom { color: #2563eb; }

.card-face.clubs .card-corner,
.card-face.clubs .card-center,
.card-face.clubs .card-bottom { color: #16a34a; }

.card-face.spades .card-corner,
.card-face.spades .card-center,
.card-face.spades .card-bottom { color: #1e1b4b; }

.card-back {
  background: linear-gradient(135deg, #1e3a6e 0%, #243f8a 50%, #1e3a6e 100%);
  border: 1px solid #3454a0;
  box-shadow: 0 2px 8px var(--card-shadow);
  overflow: hidden;
}

.card-back::after {
  content: '';
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 3px;
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,0.03), rgba(255,255,255,0.03) 4px, transparent 4px, transparent 8px),
    radial-gradient(circle at center, rgba(212,165,67,0.08) 0%, transparent 60%);
}

.card-empty {
  border: 2px dashed rgba(255,255,255,0.08);
  border-radius: 6px;
  background: rgba(255,255,255,0.02);
}

.card.deal-animate {
  animation: dealFly 0.55s cubic-bezier(0.2, 0, 0.2, 1) both;
}

@keyframes dealFly {
  0% {
    opacity: 0;
    transform: translate(0, -140px) scale(0.35) rotate(-18deg);
    filter: blur(2px);
  }
  55% {
    opacity: 1;
    transform: translate(0, 6px) scale(1.05) rotate(1.5deg);
    filter: blur(0);
  }
  78% {
    transform: translate(0, -3px) scale(0.98) rotate(-0.5deg);
  }
  100% {
    opacity: 1;
    transform: translate(0, 0) scale(1) rotate(0);
    filter: blur(0);
  }
}

/* Showdown flip for dealer reveal */
.card.flip-animate {
  animation: flipReveal 0.6s ease both;
}

@keyframes flipReveal {
  0% { transform: rotateY(0) scale(1); }
  50% { transform: rotateY(90deg) scale(1.06); }
  100% { transform: rotateY(0) scale(1); }
}


/* ── Seat Detail Panels (below table) ────────────────────────────── */
.seats-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.seat-panel {
  flex: 1;
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all 0.3s ease;
}

.seat-panel.inactive {
  opacity: 0.35;
  filter: grayscale(0.5);
}

.seat-panel.acting {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold-dim), 0 0 24px rgba(212,165,67,0.15);
}

.seat-panel.won {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(16,185,129,0.08) 0%, var(--surface) 100%);
}

.seat-panel.lost {
  border-color: var(--danger-dim);
  background: linear-gradient(180deg, rgba(239,68,68,0.06) 0%, var(--surface) 100%);
}

.seat-panel.push-result {
  border-color: var(--warning);
  background: linear-gradient(180deg, rgba(245,158,11,0.06) 0%, var(--surface) 100%);
}

.seat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.seat-id {
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--gold);
  letter-spacing: 0.12em;
}

.toggle-btn {
  font-size: 0.55rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  cursor: pointer;
  border: 1px solid;
  letter-spacing: 0.06em;
  transition: all var(--transition);
  font-family: var(--font);
}

.toggle-btn.on {
  background: rgba(16,185,129,0.15);
  border-color: rgba(16,185,129,0.3);
  color: var(--accent);
}

.toggle-btn.off {
  background: rgba(100,116,139,0.1);
  border-color: var(--border-light);
  color: var(--text-muted);
}

.acting-badge {
  font-size: 0.55rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 0.08em;
  animation: pulse-glow 1.5s ease-in-out infinite;
}

.seat-bankroll {
  font-family: var(--mono);
  font-size: 0.85rem;
  font-weight: 600;
}

.seat-bankroll.negative { color: var(--danger); }

.seat-net {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  margin-left: 6px;
}

.seat-net.positive { color: var(--accent); }
.seat-net.negative { color: var(--danger); }
.seat-net.neutral { color: var(--warning); }

.topup-row {
  display: flex;
  gap: 4px;
  margin-top: 4px;
}

.topup-btn {
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.2);
  color: var(--accent);
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 0.58rem;
  font-weight: 700;
  font-family: var(--mono);
  cursor: pointer;
  transition: all var(--transition);
}

.topup-btn:hover {
  background: rgba(16,185,129,0.2);
}

.bet-config {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bet-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.bet-label {
  font-size: 0.58rem;
  font-weight: 700;
  width: 2.2rem;
  flex-shrink: 0;
}

.bet-label.ante { color: var(--gold); }
.bet-label.trips { color: #a78bfa; }
.bet-label.qq { color: #c084fc; }

.bet-input {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-light);
  color: var(--text);
  border-radius: 6px;
  padding: 3px 6px;
  font-family: var(--mono);
  font-size: 0.7rem;
  width: 3.5rem;
  outline: none;
  transition: border-color var(--transition);
}

.bet-input:focus {
  border-color: var(--gold);
}

.seat-cards {
  display: flex;
  gap: 2px;
  flex-wrap: wrap;
}

.hand-strength {
  font-size: 0.68rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.bet-status {
  font-size: 0.58rem;
  color: var(--text-muted);
}

.bet-status .amount { color: var(--gold); }
.bet-status .trips-amt { color: #a78bfa; }
.bet-status .qq-amt { color: #c084fc; }

/* ── Result Grade Card ──────────────────────────────────────────── */
.result-card {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(0,0,0,0.2);
  animation: fadeSlideIn 0.4s ease both;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.rc-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.rc-banner.win {
  background: linear-gradient(90deg, rgba(16,185,129,0.25), rgba(16,185,129,0.1));
  color: #34d399;
}

.rc-banner.loss, .rc-banner.fold {
  background: linear-gradient(90deg, rgba(239,68,68,0.2), rgba(239,68,68,0.08));
  color: #f87171;
}

.rc-banner.push {
  background: linear-gradient(90deg, rgba(245,158,11,0.2), rgba(245,158,11,0.08));
  color: #fbbf24;
}

.rc-net {
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 900;
}

.rc-section {
  padding: 6px 10px;
  border-top: 1px solid rgba(255,255,255,0.04);
}

.rc-section-label {
  font-size: 0.45rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin-bottom: 3px;
  text-transform: uppercase;
}

.rc-hand-name {
  font-size: 0.72rem;
  font-weight: 800;
  margin-bottom: 3px;
}

.rc-cards-used {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.rc-cards-tag {
  font-family: var(--mono);
  font-size: 0.55rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  white-space: nowrap;
}

.rc-cards-tag.hole {
  background: rgba(59,130,246,0.15);
  color: #93c5fd;
  border: 1px solid rgba(59,130,246,0.2);
}

.rc-cards-tag.board {
  background: rgba(16,185,129,0.1);
  color: #6ee7b7;
  border: 1px solid rgba(16,185,129,0.15);
}

.rc-plus {
  font-size: 0.5rem;
  color: var(--text-muted);
}

.rc-bet-rows {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.rc-bet-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2px 0;
  font-size: 0.56rem;
}

.rc-bet-row.rc-bet-total {
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 2px;
  padding-top: 4px;
  font-weight: 800;
}

.rc-bet-name {
  color: var(--text);
  font-weight: 600;
}

.rc-bet-name.trips-color { color: #a78bfa; }
.rc-bet-name.qq-color { color: #c084fc; }

.rc-bet-result {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.56rem;
}

.rc-bet-result.win { color: #34d399; }
.rc-bet-result.loss { color: #f87171; }
.rc-bet-result.push { color: #fbbf24; }

.folded-label {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--danger);
  letter-spacing: 0.08em;
}

/* ── Action Bar ─────────────────────────────────────────────────── */
.action-bar {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 100%);
  border: 1px solid var(--gold-dim);
  border-radius: var(--radius);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.action-seat-label {
  color: var(--gold);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.action-divider {
  width: 1px;
  height: 32px;
  background: rgba(212,165,67,0.2);
  flex-shrink: 0;
}

.action-buttons {
  display: flex;
  gap: 8px;
  flex: 1;
  flex-wrap: wrap;
  align-items: center;
}

.btn-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-radius: var(--radius-sm);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  border: 1px solid transparent;
  padding: 8px 18px;
  min-width: 68px;
  gap: 2px;
  font-family: var(--font);
}

.btn-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.btn-action:active {
  transform: translateY(0);
}

.btn-action .btn-label { font-size: 0.9rem; }
.btn-action .btn-sub {
  font-size: 0.6rem;
  font-family: var(--mono);
  opacity: 0.75;
}

.btn-4x {
  background: linear-gradient(180deg, #991b1b, #7f1d1d);
  border-color: #b91c1c;
  color: #fca5a5;
}
.btn-4x:hover { background: linear-gradient(180deg, #b91c1c, #991b1b); }

.btn-3x {
  background: linear-gradient(180deg, #9a3412, #7c2d12);
  border-color: #c2410c;
  color: #fdba74;
}
.btn-3x:hover { background: linear-gradient(180deg, #c2410c, #9a3412); }

.btn-2x {
  background: linear-gradient(180deg, #92400e, #78350f);
  border-color: #b45309;
  color: #fde68a;
}
.btn-2x:hover { background: linear-gradient(180deg, #b45309, #92400e); }

.btn-1x {
  background: linear-gradient(180deg, #166534, #14532d);
  border-color: #16a34a;
  color: #86efac;
}
.btn-1x:hover { background: linear-gradient(180deg, #16a34a, #166534); }

.btn-check {
  background: rgba(59,130,246,0.2);
  border-color: #3b82f6;
  color: #93c5fd;
}
.btn-check:hover { background: rgba(59,130,246,0.35); }

.btn-fold {
  background: rgba(100,116,139,0.15);
  border-color: var(--border-light);
  color: #94a3b8;
}
.btn-fold:hover { background: rgba(100,116,139,0.3); color: #cbd5e1; }


/* ── Paytables ──────────────────────────────────────────────────── */
.paytables-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}

.paytable {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.pt-header {
  background: rgba(0,0,0,0.3);
  padding: 6px 10px;
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  border-bottom: 1px solid var(--border);
}

.pt-header.blind { color: var(--gold); }
.pt-header.trips { color: #a78bfa; }
.pt-header.qq { color: #c084fc; }

.pt-body { padding: 4px 0; }

.pt-row {
  display: flex;
  justify-content: space-between;
  padding: 2px 10px;
  font-size: 0.56rem;
  border-bottom: 1px solid rgba(255,255,255,0.02);
}

.pt-row .pt-hand { color: var(--text); font-weight: 500; }
.pt-row .pt-pay {
  font-family: var(--mono);
  font-weight: 600;
  color: var(--gold-light);
}

.pt-row .pt-pay.loss { color: var(--text-muted); }

/* ── Win Animation ──────────────────────────────────────────────── */
@keyframes winPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(16,185,129,0.3); }
  50% { box-shadow: 0 0 0 6px rgba(16,185,129,0); }
}

.seat-panel.won {
  animation: winPulse 1s ease 2;
}

.seat-spot.won .spot-result {
  animation: winPulse 1s ease 2;
}

/* ── Divider ────────────────────────────────────────────────────── */
.gold-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,165,67,0.2), transparent);
  margin: 8px 0;
}


/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .felt-table {
    padding-bottom: 60%;  /* taller ratio on mobile */
  }

  .seats-row {
    flex-direction: column;
  }

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

  .card-lg {
    width: 44px;
    height: 62px;
    font-size: 0.9rem;
  }

  .card-md {
    width: 36px;
    height: 52px;
    font-size: 0.75rem;
  }

  .card-sm {
    width: 28px;
    height: 40px;
    font-size: 0.62rem;
  }

  .seat-spot.pos-1 { top: 44%; left: 0%; }
  .seat-spot.pos-2 { bottom: 8%; left: 14%; }
  .seat-spot.pos-3 { bottom: 0%; left: 50%; }
  .seat-spot.pos-4 { bottom: 8%; right: 14%; }
  .seat-spot.pos-5 { top: 44%; right: 0%; }

  .btn-deal {
    font-size: 0.75rem;
    padding: 8px 28px;
  }

  .dealer-cards { gap: 2px; }
  .community-cards { gap: 3px; }
}

@media (max-width: 480px) {
  .felt-table {
    padding-bottom: 75%;
  }

  .dealer-area { top: 4%; }
  .community-area { top: 28%; }
  .felt-deal-area { top: 48%; }

  .spot-label { flex-direction: column; gap: 1px; }
  .spot-bankroll { font-size: 0.5rem; }

  .action-bar {
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 12px;
  }

  .action-buttons { gap: 4px; }
  .btn-action { padding: 6px 12px; min-width: 56px; }
}

/* ── Number spinner ─────────────────────────────────────────────── */
input[type=number]::-webkit-inner-spin-button { opacity: 0.3; }
input[type=number]::-webkit-outer-spin-button { opacity: 0.3; }
