:root {
  --bg: #050505;
  --panel: rgba(255, 255, 255, 0.045);
  --panel-strong: rgba(16, 16, 24, 0.78);
  --line: rgba(255, 255, 255, 0.08);
  --text: #f5f5f7;
  --muted: #9ca3af;
  --gold: #ffd700;
  --gold-dim: #d4a03c;
  --teal: #00d4aa;
  --green: #22c55e;
  --red: #ef4444;
  --sky: #38bdf8;
  --purple: #a855f7;
}

html {
  background: var(--bg);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
  background:
    radial-gradient(ellipse at 0% 0%, rgba(193, 18, 31, 0.12) 0%, transparent 50%),
    radial-gradient(ellipse at 100% 0%, rgba(212, 160, 60, 0.08) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 100%, rgba(0, 212, 170, 0.06) 0%, transparent 40%),
    #050505;
  color: var(--text);
}

.app-shell {
  padding: 20px;
  gap: 20px;
}

.topbar {
  min-height: 64px;
  padding: 12px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(16, 16, 24, 0.88), rgba(8, 8, 12, 0.92));
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(12px);
}

.topbar h1 {
  font-weight: 900;
  background: linear-gradient(135deg, #fff, var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-size: clamp(26px, 3vw, 40px);
}

.status-pill {
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 8px 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

#api-status.status-pill {
  background: rgba(34, 197, 94, 0.14);
  border-color: rgba(34, 197, 94, 0.4);
  color: #4ade80;
}

#member-status.status-pill {
  background: rgba(168, 85, 247, 0.14);
  border-color: rgba(168, 85, 247, 0.4);
  color: #c084fc;
}

#vip-status.status-pill {
  background: linear-gradient(135deg, rgba(212, 160, 60, 0.2), rgba(193, 18, 31, 0.15));
  border-color: rgba(212, 160, 60, 0.45);
  color: var(--gold);
  box-shadow: 0 0 20px rgba(212, 160, 60, 0.15);
}

.casino-sidebar {
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(14, 14, 22, 0.96), rgba(8, 8, 12, 0.94));
  border: 1px solid var(--line);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
  padding: 14px;
}

.sidebar-section {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-nav a,
.sidebar-nav button,
.secondary-link-button {
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  transition: all 0.2s ease;
}

.sidebar-nav a:hover,
.sidebar-nav button:hover,
.secondary-link-button:hover {
  background: rgba(212, 160, 60, 0.1);
  border-color: rgba(212, 160, 60, 0.4);
  transform: translateX(2px);
}

.auth-icon-button-primary {
  background: linear-gradient(135deg, rgba(212, 160, 60, 0.25), rgba(193, 18, 31, 0.15));
  border-color: rgba(212, 160, 60, 0.5);
  color: var(--gold);
}

.eyebrow {
  color: var(--gold-dim);
  font-size: 10px;
  letter-spacing: 0.18em;
}

.quick-casino-bar {
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(16, 16, 24, 0.92), rgba(8, 8, 12, 0.95));
  border: 1px solid var(--line);
  padding: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
}

.quick-casino-copy h2 {
  font-size: 28px;
  font-weight: 800;
}

.quick-wallet-balance {
  font-size: 16px;
  font-weight: 700;
  color: #4ade80;
  text-shadow: 0 0 20px rgba(74, 222, 128, 0.2);
}

.quick-game-dock button {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  transition: all 0.25s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.quick-game-dock button:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 0 30px var(--accent-glow, rgba(255, 255, 255, 0.05));
  border-color: var(--accent, rgba(255, 255, 255, 0.3));
}

.quick-game-dock button.active {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold), 0 16px 40px rgba(212, 160, 60, 0.2);
}

.quick-game-dock span {
  border-radius: 10px;
  font-weight: 900;
  font-size: 14px;
}

.games-section {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--line);
}

.family-tabs button {
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 700;
  font-size: 12px;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.04);
}

.family-tabs button.active {
  background: linear-gradient(135deg, rgba(212, 160, 60, 0.25), rgba(193, 18, 31, 0.15));
  border-color: rgba(212, 160, 60, 0.5);
  color: var(--gold);
  box-shadow: 0 0 20px rgba(212, 160, 60, 0.15);
}

.game-card {
  position: relative;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(20, 20, 30, 0.7), rgba(8, 8, 12, 0.85));
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  min-height: 220px;
}

.game-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--cover);
  background-size: cover;
  background-position: center;
  opacity: 0.92;
  transition: opacity 0.3s ease, transform 0.4s ease;
}

.game-card::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.45) 55%, rgba(0, 0, 0, 0.78) 100%);
}

.game-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(212, 160, 60, 0.1);
  border-color: rgba(212, 160, 60, 0.3);
}

.game-card:hover::before {
  opacity: 1;
  transform: scale(1.06);
}

.game-card.active {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold), 0 20px 50px rgba(212, 160, 60, 0.2);
}

.game-card.headline {
  grid-column: span 2;
  grid-row: span 2;
}

.game-card-top {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.game-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 14px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.game-status {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  color: #4ade80;
}

.game-card h3 {
  position: relative;
  z-index: 2;
  font-size: 18px;
  font-weight: 800;
  margin-top: auto;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

.game-card.headline h3 {
  font-size: 28px;
}

.game-meta {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.game-meta span {
  font-size: 10px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  color: var(--muted);
}

.game-sheen {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.premium-shelf {
  margin-bottom: 24px;
}

.premium-shelf h3 {
  font-size: 20px;
  font-weight: 800;
  margin-top: 6px;
}

.shelf-row button {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(20, 20, 30, 0.7), rgba(8, 8, 12, 0.85));
  transition: all 0.25s ease;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.shelf-row button:hover {
  transform: translateY(-4px);
  border-color: rgba(212, 160, 60, 0.3);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35), 0 0 30px rgba(212, 160, 60, 0.08);
}

.shelf-row button span {
  border-radius: 10px;
}

.arena-card {
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(16, 16, 24, 0.92), rgba(8, 8, 12, 0.95));
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

.arena {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 0 0 14px 14px;
}

.primary-button {
  border-radius: 12px;
  background: linear-gradient(135deg, #c1121f, #8b0000);
  border: 1px solid rgba(255, 107, 107, 0.4);
  color: #fff;
  font-weight: 800;
  padding: 14px 24px;
  box-shadow: 0 4px 24px rgba(193, 18, 31, 0.25);
  transition: all 0.2s ease;
}

.primary-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(193, 18, 31, 0.35);
}

.secondary-button {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
  font-weight: 700;
  transition: all 0.2s ease;
}

.secondary-button:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(212, 160, 60, 0.3);
}

.bet-slip,
.ledger-panel,
.account-panel,
.banking-console,
.banking-side,
.bourre-feature,
.ops-panel,
.vip-panel,
.compliance-grid article {
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(16, 16, 24, 0.88), rgba(8, 8, 12, 0.92));
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.bourre-table-poster {
  border-radius: 24px;
  box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.5), 0 16px 40px rgba(0, 0, 0, 0.3);
}

.seat-dot {
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.table-pot {
  border-radius: 999px;
  box-shadow: 0 0 40px rgba(212, 160, 60, 0.3), inset 0 0 20px rgba(0, 0, 0, 0.3);
}

.ledger-item,
.bank-card,
.bank-account,
.receipt {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.2s ease;
}

.ledger-item:hover,
.bank-card:hover,
.bank-account:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(212, 160, 60, 0.2);
}

.search-field input {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 12px 18px;
  color: var(--text);
  font-weight: 600;
}

.search-field input:focus {
  outline: none;
  border-color: rgba(212, 160, 60, 0.4);
  box-shadow: 0 0 0 3px rgba(212, 160, 60, 0.1);
}

.token-grid button {
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s ease;
}

.token-grid button.active {
  background: rgba(212, 160, 60, 0.15);
  border-color: rgba(212, 160, 60, 0.5);
  box-shadow: 0 0 20px rgba(212, 160, 60, 0.15);
}

.chip-row button {
  border-radius: 999px;
  background: linear-gradient(145deg, #d4a03c, #b8860b);
  box-shadow: inset 0 0 0 4px rgba(0, 0, 0, 0.2), inset 0 0 0 8px rgba(255, 255, 255, 0.2), 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease;
}

.chip-row button:hover {
  transform: scale(1.08);
}

.hero {
  border-radius: 20px;
  border: 1px solid var(--line);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
}

.hero.bourre-hero {
  border-radius: 20px;
}

.hero h2 {
  font-weight: 900;
  text-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.hero-tags span {
  border-radius: 999px;
  background: rgba(212, 160, 60, 0.12);
  border-color: rgba(212, 160, 60, 0.25);
}

.lobby-control-strip {
  margin-bottom: 18px;
}

@media (max-width: 900px) {
  .game-card.headline {
    grid-column: span 1;
    grid-row: span 1;
  }
  
  .app-shell {
    padding: 12px;
  }
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(212, 160, 60, 0.1); }
  50% { box-shadow: 0 0 40px rgba(212, 160, 60, 0.25); }
}

.game-card.headline {
  animation: pulse-glow 4s ease-in-out infinite;
}

/* Tablet/mobile: sidebar is always off-canvas — never inline */
@media (max-width: 1120px) {
  .casino-sidebar {
    display: none;
    position: fixed;
    inset: 0 auto 0 0;
    width: 280px;
    max-height: 100dvh;
    overflow-y: auto;
    z-index: 200;
    border-radius: 0 16px 16px 0;
    transform: translateX(-100%);
    transition: transform 240ms ease;
  }
  .sidebar-open .casino-sidebar {
    display: block;
    transform: translateX(0);
  }
}

/* Always hide the studio strip — wasted space */
.studio-strip {
  display: none !important;
}

/* Always hide the surface-grid (admin only) */
.surface-grid {
  display: none !important;
}

/* Hide the oscar-coach-panel empty block in sidebar */
.oscar-coach-panel {
  display: none !important;
}

/* Compact layout: slide everything up to match Stake-like density */
.app-shell {
  padding: 6px;
  gap: 10px;
}

/* Ensure topbar always renders first regardless of DOM siblings with order:0 */
.topbar {
  order: -1;
  min-height: 44px;
  padding: 6px 12px;
}

/* New structural elements need explicit order so they slot in after the hero */
.crypto-ticker-bar { order: 2; }
.main-with-betslip { order: 4; }

.topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-menu,
.mobile-profile {
  display: none;
}

.desktop-only {
  display: inline-flex;
}

.casino-sidebar,
.surface-grid,
.quick-casino-bar,
.game-route-bar,
.studio-strip,
.account-security-layout,
.bourre-command,
.banking-layout,
.layout,
.table-layout,
.compliance-grid,
.oscar-coach-full,
.premium-shelves {
  margin-top: 12px;
}

.quick-casino-bar {
  padding: 12px;
}

.game-route-bar {
  padding: 10px 12px;
}

.studio-strip {
  padding: 12px;
}

.account-security-layout,
.bourre-command,
.banking-layout,
.layout {
  gap: 12px;
}

.account-panel,
.banking-console,
.banking-side,
.bet-slip,
.games-section {
  padding: 14px;
}

.lobby-control-strip {
  margin-bottom: 10px;
}

.family-tabs {
  margin-bottom: 10px;
}

.player-tools {
  margin-bottom: 10px;
}

.games-grid {
  margin-top: 10px;
  gap: 10px;
}

.surface-card {
  padding: 12px;
}

/* Reduce headline wasted space */
.hero,
.account-security-layout,
.bourre-command,
.banking-layout,
.layout {
  min-height: 0;
}

/* ─── Main two-column layout: content + bet slip ─────────────────────────── */
/* Desktop only (≥ 900px): side-by-side */
@media (min-width: 900px) {
  .main-with-betslip {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 12px;
    align-items: start;
    margin-top: 12px;
  }

  .betslip-col {
    position: sticky;
    top: 10px;
    max-height: calc(100vh - 20px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  /* sit flush — no extra margin-top */
  .betslip-col .bet-slip {
    margin-top: 0 !important;
  }
}

/* Mobile / tablet (< 900px): single column, bet slip is sticky bottom drawer */
@media (max-width: 899px) {
  .main-with-betslip {
    display: block;
    margin-top: 8px;
    padding-bottom: 72px; /* room for the sticky drawer */
  }

  .main-content-col {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .betslip-col {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 150;
    border-radius: 18px 18px 0 0;
    background: linear-gradient(180deg, rgba(14, 14, 22, 0.98), rgba(8, 8, 12, 0.99));
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    max-height: 64px;
    transition: max-height 320ms cubic-bezier(0.4, 0, 0.2, 1);
  }

  .betslip-col.betslip-open {
    max-height: 85dvh;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .betslip-col .bet-slip {
    border-radius: 0 !important;
    border: none !important;
    background: transparent !important;
    margin-top: 0 !important;
  }

  /* Pull tab shown when closed */
  .betslip-col::before {
    content: '▲  BET SLIP  —  Tap to open';
    display: flex;
    align-items: center;
    justify-content: center;
    height: 64px;
    font-size: 12px;
    font-weight: 800;
    color: #f2d58a;
    letter-spacing: 0.08em;
    cursor: pointer;
    flex-shrink: 0;
  }

  .betslip-col.betslip-open::before {
    content: '▼  BET SLIP  —  Tap to close';
    height: 40px;
    font-size: 11px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
  }
}

.main-content-col {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Large screens: tighter sidebar gutter — use fixed sidebar + padding-left (same as styles.css baseline) */
@media (min-width: 1121px) {
  .app-shell {
    display: block;
    padding: 10px 10px 10px 256px;
    gap: 0;
  }

  .topbar {
    margin-bottom: 10px;
  }

  .casino-sidebar {
    position: fixed;
    top: 10px;
    left: 10px;
    bottom: 10px;
    width: 232px;
    max-height: none;
    overflow-y: auto;
  }

  .casino-sidebar .sidebar-section {
    padding: 10px;
  }

  .sidebar-section + .sidebar-section {
    margin-top: 6px;
  }

  .sidebar-nav {
    gap: 4px;
  }

  .sidebar-nav a,
  .sidebar-nav button {
    min-height: 34px;
  }

  /* Every direct child after sidebar flows normally */
  .quick-casino-bar,
  .game-route-bar,
  .studio-strip,
  .account-security-layout,
  .bourre-command,
  .banking-layout,
  .layout,
  .compliance-grid,
  .premium-shelves,
  .games-section {
    grid-column: unset;
    margin-top: 10px;
  }

  .quick-casino-bar {
    margin-top: 0;
  }
}

/* Mobile: compact header, menu + profile icons, slide everything up */
@media (max-width: 1024px) {
  .app-shell {
    padding: 4px;
    gap: 8px;
  }

  .topbar {
    min-height: 38px;
    padding: 4px 8px;
  }

  .desktop-only {
    display: none;
  }

  .mobile-menu,
  .mobile-profile {
    display: inline-flex;
  }

  .topbar-title {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .topbar-title .eyebrow {
    display: none;
  }

  .topbar-title h1 {
    font-size: 20px;
  }

  .topbar-actions {
    gap: 6px;
  }

  .icon-button {
    width: 36px;
    height: 36px;
  }

  .icon-button svg {
    width: 20px;
    height: 20px;
  }

  /* Dim overlay when sidebar is open */
  .sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 199;
    background: rgba(0, 0, 0, 0.6);
    cursor: pointer;
  }

  .studio-strip,
  .game-route-bar {
    display: none;
  }

  .quick-casino-bar,
  .account-security-layout,
  .bourre-command,
  .banking-layout,
  .layout,
  .compliance-grid {
    margin-top: 8px;
  }

  .quick-casino-bar {
    padding: 8px;
  }

  .quick-casino-copy h2 {
    font-size: 18px;
  }

  .lobby-control-strip {
    margin-bottom: 8px;
  }

  .family-tabs {
    margin-bottom: 8px;
  }

  .games-section {
    padding: 10px;
  }

  .games-grid {
    gap: 8px;
  }

}

/* Ensure the game table, bet slip, and game-route bar are visible on the lobby page so games are playable */
body.lobby-page .table-layout,
body.lobby-page .bet-slip,
body.lobby-page .game-route-bar {
  display: grid !important;
}

/* ─── 3D hero scene ─────────────────────────────────────────────────────────── */
.casino-hero-3d {
  position: relative;
  width: 100%;
  min-height: 620px;
  overflow: hidden;
  background: radial-gradient(circle at center, #161925 0%, #0b0e14 100%);
}

.casino-scene-3d,
.casino-scene-3d canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none !important;
}

.casino-hero-3d .quick-casino-bar {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  top: 0;
  background: linear-gradient(180deg, rgba(11, 14, 20, 0.92) 0%, rgba(11, 14, 20, 0.4) 70%, transparent 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.casino-hero-3d .quick-game-dock {
  position: absolute;
  z-index: 1;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: row;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(13, 16, 23, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.casino-hero-3d .quick-game-dock button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 64px;
  height: 64px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: #e5e7eb;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.casino-hero-3d .quick-game-dock button:hover,
.casino-hero-3d .quick-game-dock button.active {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--accent, #38bdf8);
  box-shadow: 0 0 20px color-mix(in srgb, var(--accent, #38bdf8) 30%, transparent);
  transform: translateY(-2px);
}

.casino-hero-3d .quick-game-dock button span {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  background: color-mix(in srgb, var(--accent, #38bdf8) 15%, transparent);
  color: var(--accent, #38bdf8);
}

.casino-scene-3d canvas {
  touch-action: manipulation;
  outline: none;
}

/* ─── Crypto / Live-bet ticker ─────────────────────────────────────────────── */
/* NOTE: span { display:block } in styles.css overrides <span> children.
   Ticker uses <div> and <em> elements — NOT <span>. Flex rules use
   !important to beat any block overrides. */

.crypto-ticker-bar {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 16px;
  background: linear-gradient(90deg, rgba(11, 14, 20, 0.96), rgba(16, 19, 28, 0.96));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  font-size: 12px;
}

.ticker-coins {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

.ticker-coin {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 6px;
  color: #e5e7eb;
  font-weight: 600;
  font-style: normal;
}

.ticker-coin strong { color: #f2d58a; font-weight: 800; }

.ticker-price { font-style: normal; color: #e5e7eb; }
.ticker-chg   { font-style: normal; }
.up.ticker-chg,  .ticker-coin .up   { color: #22c55e; }
.down.ticker-chg,.ticker-coin .down { color: #ef4444; }

.ticker-bets {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 8px;
  flex: 1;
  min-width: 0;
  color: #94a3b8;
}

.ticker-live-dot {
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  animation: ticker-pulse 1.4s infinite;
}

.ticker-bet-label {
  color: #22c55e;
  font-weight: 700;
  flex-shrink: 0;
  white-space: nowrap;
}

.ticker-bet-scroll {
  position: relative;
  display: block;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, black 5%, black 95%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 5%, black 95%, transparent);
}

.ticker-bet-track {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap;
  gap: 24px;
  white-space: nowrap;
  animation: ticker-marquee 24s linear infinite;
  will-change: transform;
}

.ticker-bet-item {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.ticker-bet-item strong { color: #e5e7eb; font-weight: 700; }

.ticker-bet-amount {
  font-style: normal;
  color: #f2d58a;
  font-weight: 700;
}

@keyframes ticker-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

@keyframes ticker-marquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@media (max-width: 768px) {
  .crypto-ticker-bar {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px;
    padding: 8px 10px;
  }
  .ticker-coins { gap: 12px; }
  .casino-hero-3d { min-height: 480px; }
  .casino-hero-3d .quick-game-dock {
    bottom: 16px;
    padding: 8px 10px;
    gap: 6px;
    overflow-x: auto;
    max-width: 94vw;
  }
  .casino-hero-3d .quick-game-dock button {
    width: 54px;
    height: 54px;
    flex-shrink: 0;
  }
}

/* ═══════════════════════════════════════════════════════════════
   GAME PAGE  (/casino/games/[id])
   Stake-style: left controls panel + large game canvas
   ═══════════════════════════════════════════════════════════════ */

.game-page {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ── Topbar ── */
.game-page-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  background: rgba(10, 10, 16, 0.95);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
}

.game-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
}

.game-breadcrumb a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s;
}

.game-breadcrumb a:hover { color: var(--text); }

.crumb-sep { color: rgba(255,255,255,0.25); }

.crumb-current {
  color: var(--text);
  font-weight: 600;
}

.game-page-topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.game-page-players {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  animation: live-pulse 1.4s infinite;
}

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.game-page-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s;
}

.game-page-back-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

/* ── Body: two-column ── */
.game-page-body {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: calc(100vh - 53px);
  align-items: start;
}

/* ── Left: Controls Panel ── */
.game-controls-panel {
  position: sticky;
  top: 53px;
  height: calc(100vh - 53px);
  overflow-y: auto;
  padding: 20px 16px;
  background: rgba(8, 8, 14, 0.97);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
  gap: 16px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.1) transparent;
}

.gcp-identity {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.gcp-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent, #38bdf8) 14%, rgba(255,255,255,0.04));
  border: 1px solid color-mix(in srgb, var(--accent, #38bdf8) 30%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  color: var(--accent, #38bdf8);
  flex-shrink: 0;
}

.gcp-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 4px 0;
  line-height: 1.2;
}

.gcp-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.gcp-edge-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--muted);
}

.gcp-pf-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #4ade80;
}

/* Mode tabs: Manual / Auto */
.gcp-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 10px;
  overflow: hidden;
}

.gcp-mode-tabs button {
  padding: 9px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
}

.gcp-mode-tabs button.active {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

/* Controls container */
.gcp-controls {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Field */
.gcp-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.gcp-field-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gcp-field-value {
  color: var(--text);
  font-weight: 700;
}

/* Input with token label */
.gcp-input-wrap {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  overflow: hidden;
}

.gcp-input-wrap input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 15px;
  font-weight: 700;
  padding: 10px 12px;
  outline: none;
  min-width: 0;
}

.gcp-token {
  padding: 0 12px;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  white-space: nowrap;
}

.gcp-input-solo {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 12px;
  outline: none;
}

/* Quick bet buttons */
.gcp-quick-btns {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.gcp-quick-btns button {
  padding: 8px 4px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}

.gcp-quick-btns button:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

/* Risk segmented */
.gcp-segmented {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
}

.gcp-segmented button {
  padding: 8px 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
}

.gcp-segmented button.active {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

/* Range slider */
.gcp-range {
  width: 100%;
  accent-color: var(--teal);
}

/* Balance row */
.gcp-balance-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.gcp-balance-row span { color: var(--muted); }
.gcp-balance-row strong { color: var(--gold); font-weight: 800; }

/* Big Bet button */
.gcp-bet-btn {
  width: 100%;
  padding: 14px;
  border-radius: 12px;
  border: none;
  background: color-mix(in srgb, var(--accent, #22c55e) 85%, #000 15%);
  color: #000;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: 0 4px 20px color-mix(in srgb, var(--accent, #22c55e) 35%, transparent);
  letter-spacing: 0.03em;
}

.gcp-bet-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 28px color-mix(in srgb, var(--accent, #22c55e) 45%, transparent);
}

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

/* Last result pill */
.gcp-last-result {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
}

.gcp-last-result.win {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
  color: #4ade80;
}

.gcp-last-result.loss {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
}

.gcp-last-result.push {
  background: rgba(250, 204, 21, 0.1);
  border: 1px solid rgba(250, 204, 21, 0.25);
  color: #facc15;
}

.gcp-last-mult { color: var(--muted); }
.gcp-last-amount { font-weight: 800; }

/* ── Right: Canvas Column ── */
.game-canvas-col {
  display: flex;
  flex-direction: column;
  padding: 20px 24px;
  gap: 24px;
  min-width: 0;
}

.game-canvas-wrapper {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(12, 12, 20, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.07);
  min-height: 420px;
}

/* Hide the arena-card chrome on the game page — let the game fill the space */
.game-canvas-wrapper .table-layout {
  display: block !important;
}

.game-canvas-wrapper .arena-card {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}

.game-canvas-wrapper .arena-header {
  display: none !important;
}

.game-canvas-wrapper .ledger-panel {
  display: none !important;
}

.game-canvas-wrapper .arena {
  padding: 0 !important;
}

/* ── Game Info Stats Bar ── */
.game-info-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.06);
}

.gib-stat {
  flex: 1 1 100px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  background: rgba(10, 10, 16, 0.97);
}

.gib-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.gib-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.gib-accent {
  color: var(--accent, var(--gold)) !important;
}

.gib-green { color: #4ade80 !important; }
.gib-muted { color: var(--muted) !important; }

/* ── About section ── */
.game-about {
  padding: 20px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.game-about-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 10px 0;
}

.game-about-text {
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
  margin: 0;
}

/* ── Live Bets Feed ── */
.live-bets-feed {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(10, 10, 16, 0.97);
}

.live-bets-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.live-bets-tabs button {
  flex: 1;
  padding: 12px 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
  letter-spacing: 0.03em;
}

.live-bets-tabs button.active {
  color: var(--text);
  border-bottom: 2px solid var(--teal);
}

.live-bets-table-wrap {
  overflow-x: auto;
}

.live-bets-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.live-bets-table thead th {
  padding: 10px 14px;
  text-align: left;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  white-space: nowrap;
}

.live-bet-row td {
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  white-space: nowrap;
  transition: background 0.1s;
}

.live-bet-row:hover td { background: rgba(255, 255, 255, 0.03); }

.live-bet-row.win { }
.live-bet-row.loss { }

.lbf-user { font-weight: 600; color: var(--text); }
.lbf-hidden { color: var(--muted); font-style: italic; }
.lbf-username { color: var(--sky); }
.lbf-game { color: var(--muted); max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.lbf-bet { color: var(--text); font-weight: 600; }

.lbf-mult.win { color: #4ade80; font-weight: 700; }
.lbf-mult.loss { color: var(--muted); }

.lbf-win { color: #4ade80; font-weight: 700; }
.lbf-loss { color: #f87171; font-weight: 600; }

.live-bets-empty {
  text-align: center;
  padding: 32px;
  color: var(--muted);
  font-style: italic;
}

/* ── Related Games ── */
.game-related {
  padding-bottom: 8px;
}

.game-related-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 14px 0;
}

.game-related-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 10px;
}

.game-related-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.03);
  text-decoration: none;
  transition: all 0.15s;
  cursor: pointer;
}

.game-related-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: color-mix(in srgb, var(--accent, #38bdf8) 40%, transparent);
  transform: translateY(-2px);
}

.grc-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent, #38bdf8) 14%, rgba(255,255,255,0.04));
  border: 1px solid color-mix(in srgb, var(--accent, #38bdf8) 25%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  color: var(--accent, #38bdf8);
  margin-bottom: 2px;
}

.grc-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
  text-align: center;
  line-height: 1.3;
}

.grc-edge {
  font-size: 10px;
  color: var(--muted);
}

/* ── Mobile: stack left panel above game ── */
@media (max-width: 900px) {
  .game-page-body {
    grid-template-columns: 1fr;
  }

  .game-controls-panel {
    position: static;
    height: auto;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    overflow-y: visible;
    padding: 16px;
  }

  .game-canvas-col {
    padding: 16px;
  }

  .gib-stat {
    flex: 1 1 80px;
    padding: 10px 12px;
  }

  .game-related-row {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }
}

@media (max-width: 480px) {
  .game-page-topbar {
    padding: 12px 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .game-page-topbar-right {
    gap: 10px;
  }

  .live-bets-table thead th:nth-child(2),
  .live-bet-row td:nth-child(2) {
    display: none;
  }
}

/* ─── Bourré immersive poker table (3D scene + HTML overlay) ─────────────── */

.bourre-table-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 320px;
  margin-bottom: 16px;
  border-radius: 16px;
  overflow: hidden;
  background: radial-gradient(ellipse at center, #0f2315 0%, #050a08 100%);
  box-shadow:
    inset 0 0 80px rgba(0, 0, 0, 0.6),
    0 16px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 215, 0, 0.12);
}

.bourre-table-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.bourre-table-canvas canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.slot-machine-canvas {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  min-height: 240px;
  border-radius: 16px;
  overflow: hidden;
  background: radial-gradient(ellipse at center, #1a1020 0%, #050508 100%);
  box-shadow:
    inset 0 0 60px rgba(0, 0, 0, 0.6),
    0 12px 30px rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 215, 0, 0.12);
}

.slot-machine-canvas canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.bourre-table-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.bourre-seat-overlay {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.bourre-seat-overlay--you {
  bottom: 4%;
  left: 50%;
  transform: translateX(-50%);
}

.bourre-seat-overlay--dealer {
  top: 4%;
  left: 50%;
  transform: translateX(-50%);
}

.bourre-seat-overlay--left {
  top: 50%;
  left: 4%;
  transform: translateY(-50%);
}

.bourre-seat-overlay--right {
  top: 50%;
  right: 4%;
  transform: translateY(-50%);
}

.bourre-seat-overlay--active .bourre-seat-overlay-avatar {
  box-shadow: 0 0 0 3px #ffd700, 0 0 0 6px rgba(255, 215, 0, 0.35);
  animation: seat-pulse 1.2s ease-in-out infinite;
}

.bourre-seat-overlay--active .bourre-seat-label-name {
  color: #ffd700;
  text-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
}

.bourre-seat-overlay--folded {
  opacity: 0.5;
}

.bourre-seat-overlay--folded .bourre-seat-overlay-avatar {
  filter: grayscale(100%) brightness(0.65);
}

.bourre-seat-overlay-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(255, 255, 255, 0.9);
  background: #0b1f14;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6);
  margin-bottom: 6px;
}

.bourre-seat-label-name {
  font-size: 13px;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.9);
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.4);
}

.bourre-seat-label-tricks {
  margin-top: 3px;
  font-size: 11px;
  font-weight: 600;
  color: #cbd5e1;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.35);
}

.bourre-seat-label-turn {
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #ffd700;
  color: #111;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.05em;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

@keyframes seat-pulse {
  0%, 100% { box-shadow: 0 0 0 3px #ffd700, 0 0 0 6px rgba(255, 215, 0, 0.35); }
  50% { box-shadow: 0 0 0 4px #ffd700, 0 0 0 12px rgba(255, 215, 0, 0.2); }
}

.bourre-table-center-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: auto;
  padding: 10px 16px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(2px);
}

.bourre-table-title {
  font-size: 17px;
  font-weight: 900;
  color: #ffd700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
}

.bourre-card-back {
  width: 18px;
  height: 28px;
  border-radius: 4px;
  background:
    repeating-linear-gradient(
      45deg,
      #1e3a8a,
      #1e3a8a 3px,
      #172554 3px,
      #172554 6px
    );
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.35);
  margin: 0 -4px;
}

.bourre-trump-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 16px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 215, 0, 0.35);
}

.bourre-trump-symbol {
  font-size: 34px;
  line-height: 1;
  color: #ffd700;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
}

.bourre-trump-name {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #ffd700;
  text-transform: uppercase;
}

.bourre-pot-display {
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 215, 0, 0.25);
  color: #ffd700;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.12);
}

.bourre-trick-progress {
  font-size: 11px;
  color: #94a3b8;
  font-weight: 600;
}

.bourre-trick-cards {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
}

.bourre-trick-cards--small {
  padding: 4px 8px;
  gap: 6px;
}

.bourre-trick-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.bourre-trick-card-player {
  font-size: 9px;
  color: #94a3b8;
  font-weight: 600;
}

.bourre-card-face {
  width: 46px;
  height: 66px;
  border-radius: 6px;
  background: #f8fafc;
  font-weight: 900;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  padding: 4px 6px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.bourre-card-face--small {
  width: 38px;
  height: 54px;
  font-size: 12px;
  padding: 3px 5px;
}

.bourre-action-panel {
  margin-bottom: 16px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.bourre-action-title {
  margin: 0 0 10px;
  color: #94a3b8;
  font-size: 13px;
}

.bourre-action-trick {
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.2);
}

.bourre-action-trick p {
  margin: 0 0 8px;
  color: #94a3b8;
  font-size: 12px;
}

.bourre-hand {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.bourre-hand-card {
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.bourre-hand-card:hover:not(:disabled) {
  transform: translateY(-4px);
}

.bourre-hand-card--selected .bourre-card-face {
  border: 2px solid #ff3860;
  background: rgba(255, 56, 96, 0.12);
}

.bourre-hand-card--disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.bourre-hand-card--disabled .bourre-card-face {
  background: #334155;
  color: #94a3b8;
}

.bourre-result {
  text-align: center;
}

.bourre-result-message {
  font-size: 18px;
  color: #ffd700;
  font-weight: 800;
  margin: 0 0 12px;
}

.bourre-result-scores {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.bourre-result-score {
  padding: 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bourre-result-score strong {
  color: #e5e7eb;
  font-size: 13px;
}

.bourre-result-score span {
  color: #94a3b8;
  font-size: 12px;
}

.bourre-game-log {
  max-height: 140px;
  overflow-y: auto;
  padding: 10px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
  font-size: 12px;
  color: #94a3b8;
}

.bourre-log-entry {
  margin-bottom: 4px;
}

@media (max-width: 720px) {
  .bourre-table-stage {
    min-height: 260px;
  }

  .bourre-seat-label-name {
    font-size: 10px;
  }

  .bourre-seat-label-tricks {
    font-size: 9px;
  }

  .bourre-table-title {
    font-size: 12px;
  }

  .bourre-trump-symbol {
    font-size: 26px;
  }

  .bourre-pot-display {
    font-size: 11px;
  }

  .bourre-card-back {
    width: 14px;
    height: 22px;
  }

  .bourre-card-face {
    width: 42px;
    height: 60px;
  }

  .bourre-result-scores {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ─── Avatar Picker ────────────────────────────────────────────────────────── */

.avatar-picker-overlay {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.avatar-picker-modal {
  width: min(90vw, 420px);
  padding: 20px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(16, 16, 24, 0.96), rgba(8, 8, 12, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

.avatar-picker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.avatar-picker-header h3 {
  margin: 0;
  font-size: 18px;
  color: #ffd700;
}

.avatar-picker-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: #e5e7eb;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s ease;
}

.avatar-picker-close:hover {
  background: rgba(255, 255, 255, 0.12);
}

.avatar-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.avatar-option {
  width: 60px;
  height: 60px;
  padding: 0;
  border: 3px solid transparent;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
  overflow: hidden;
}

.avatar-option:hover {
  transform: scale(1.05);
  border-color: rgba(255, 215, 0, 0.5);
}

.avatar-option--active {
  border-color: #ffd700;
  box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.3);
}

.avatar-option img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.avatar-upload {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-upload-button {
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid rgba(255, 215, 0, 0.4);
  background: rgba(255, 215, 0, 0.1);
  color: #ffd700;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.avatar-upload-button:hover {
  background: rgba(255, 215, 0, 0.18);
}

.avatar-upload-preview {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.avatar-upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ─── Win Celebration ──────────────────────────────────────────────────────── */

.win-celebration-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  overflow: hidden;
}

.confetti-piece {
  position: absolute;
  width: 8px;
  height: 16px;
  border-radius: 2px;
  opacity: 1;
  animation-name: confetti-fall;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}

@keyframes confetti-fall {
  0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}

.firework-burst {
  position: absolute;
  display: grid;
  place-items: center;
  opacity: 0;
  animation-name: firework-explode;
  animation-timing-function: ease-out;
  animation-fill-mode: forwards;
}

.firework-burst svg {
  overflow: visible;
}

.firework-line {
  stroke-dasharray: 40;
  stroke-dashoffset: 40;
  animation: firework-line 1.2s ease-out forwards;
}

@keyframes firework-explode {
  0% { transform: scale(0); opacity: 1; }
  60% { opacity: 1; }
  100% { transform: scale(1.6); opacity: 0; }
}

@keyframes firework-line {
  0% { stroke-dashoffset: 40; }
  100% { stroke-dashoffset: 0; }
}

/* ─── Boo Effect ───────────────────────────────────────────────────────────── */

.bourre-seat-boo-container {
  position: absolute;
  /* sits above the avatar, centered */
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 20;
  width: 0; /* bubbles are absolutely positioned from here */
}

.boo-bubble {
  position: absolute;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 56, 96, 0.35);
  color: #ff3860;
  font-weight: 800;
  font-size: 14px;
  opacity: 0;
  animation-name: boo-rise;
  animation-timing-function: ease-in;
  animation-fill-mode: forwards;
}

/* Seat-level variant: each bubble fans out slightly */
.boo-bubble--seat:nth-child(1) { left: -60px; animation-duration: 1.8s; }
.boo-bubble--seat:nth-child(2) { left: -20px; animation-duration: 2s; }
.boo-bubble--seat:nth-child(3) { left:  20px; animation-duration: 1.9s; }

@keyframes boo-rise {
  0% { transform: translateY(0); opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateY(-200px); opacity: 0; }
}

.boo-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 18px 24px;
  text-align: center;
  background: rgba(0, 0, 0, 0.82);
  border-top: 2px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
  font-size: 22px;
  font-weight: 900;
  text-shadow: 0 0 20px rgba(239, 68, 68, 0.3);
  animation: boo-banner 2.5s ease-out forwards;
  z-index: 9999;
}

@keyframes boo-banner {
  0% { transform: translateY(100%); opacity: 0; }
  12% { transform: translateY(0); opacity: 1; }
  72% { transform: translateY(0); opacity: 1; }
  100% { transform: translateY(100%); opacity: 0; }
}

/* ─── WSOP-style 2D Bourré table ─────────────────────────────────────────── */

.bourre-table-felt {
  position: relative;
  width: 100%;
  max-width: 760px;
  aspect-ratio: 16 / 10;
  min-height: 300px;
  margin: 0 auto 16px;
  border-radius: 30px;
  background: linear-gradient(180deg, #5c3d2a 0%, #3d2719 100%);
  border: 10px solid #4a3425;
  box-shadow:
    inset 0 0 50px rgba(0, 0, 0, 0.55),
    0 16px 40px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.bourre-table-felt-inner {
  position: absolute;
  top: 5%;
  left: 4%;
  right: 4%;
  bottom: 5%;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 35% 25%, rgba(255, 255, 255, 0.09) 0%, transparent 35%),
    radial-gradient(ellipse at 65% 75%, rgba(0, 0, 0, 0.2) 0%, transparent 35%),
    linear-gradient(160deg, #1a7a52 0%, #145c3d 50%, #0f4a30 100%);
  box-shadow:
    inset 0 0 70px rgba(0, 0, 0, 0.5),
    inset 0 0 12px rgba(255, 255, 255, 0.06);
  border: 3px solid rgba(242, 213, 138, 0.3);
}

.bourre-felt-logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  font-size: clamp(22px, 5vw, 46px);
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.12);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}

.bourre-felt-line {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 74%;
  height: 76%;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  pointer-events: none;
}

.bourre-table-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  z-index: 2;
}

.bourre-table-pot {
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 215, 0, 0.35);
  color: #ffd700;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 0 16px rgba(255, 215, 0, 0.1);
}

.bourre-trump {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 215, 0, 0.3);
}

.bourre-trump-symbol {
  font-size: 20px;
  line-height: 1;
  text-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
}

.bourre-trump-name {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #ffd700;
  text-transform: uppercase;
}

.bourre-trick-progress {
  font-size: 10px;
  color: #cbd5e1;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.4);
}

.bourre-trick-cards {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  padding: 5px 8px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.3);
  margin-top: 4px;
}

.bourre-trick-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.bourre-trick-card-player {
  font-size: 8px;
  color: #94a3b8;
  font-weight: 600;
}

.bourre-seat {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 2;
  transition: opacity 0.2s ease;
}

.bourre-seat--bottom {
  bottom: 6%;
  left: 50%;
  transform: translateX(-50%);
  flex-direction: column-reverse;
}

.bourre-seat--top {
  top: 6%;
  left: 50%;
  transform: translateX(-50%);
}

.bourre-seat--left {
  left: 5%;
  top: 50%;
  transform: translateY(-50%);
  flex-direction: row-reverse;
}

.bourre-seat--right {
  right: 5%;
  top: 50%;
  transform: translateY(-50%);
  flex-direction: row;
}

.bourre-seat--top-left {
  top: 8%;
  left: 12%;
  transform: translateX(-50%);
}

.bourre-seat--top-right {
  top: 8%;
  right: 12%;
  transform: translateX(50%);
}

.bourre-seat--bottom-left {
  bottom: 8%;
  left: 12%;
  transform: translateX(-50%);
  flex-direction: column-reverse;
}

.bourre-seat--bottom-right {
  bottom: 8%;
  right: 12%;
  transform: translateX(50%);
  flex-direction: column-reverse;
}

.bourre-seat--active .bourre-seat-avatar {
  box-shadow: 0 0 0 3px #ffd700, 0 0 0 8px rgba(255, 215, 0, 0.35);
  animation: seat-pulse 1.2s ease-in-out infinite;
}

.bourre-seat--active .bourre-seat-name {
  color: #ffd700;
}

.bourre-seat--folded {
  opacity: 0.5;
}

.bourre-seat--folded .bourre-seat-avatar {
  filter: grayscale(100%) brightness(0.7);
}

.bourre-seat-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bourre-seat--left .bourre-seat-meta,
.bourre-seat--right .bourre-seat-meta,
.bourre-seat--top-left .bourre-seat-meta,
.bourre-seat--top-right .bourre-seat-meta,
.bourre-seat--bottom-left .bourre-seat-meta,
.bourre-seat--bottom-right .bourre-seat-meta {
  flex-direction: column;
  gap: 5px;
}

.bourre-seat-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.bourre-seat-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(255, 255, 255, 0.92);
  background: #0b1f14;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6);
  cursor: pointer;
}

.bourre-seat-active-dot {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ffd700;
  border: 2px solid #1a1a1a;
  box-shadow: 0 0 8px #ffd700;
}

.bourre-seat-info {
  text-align: center;
}

.bourre-seat-name {
  font-size: 12px;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.9);
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.55);
  white-space: nowrap;
}

.bourre-seat-tricks {
  margin-top: 2px;
  font-size: 10px;
  font-weight: 600;
  color: #cbd5e1;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.45);
  white-space: nowrap;
}

.bourre-seat-cards {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 46px;
  margin: 6px 0;
}

.bourre-seat--left .bourre-seat-cards,
.bourre-seat--right .bourre-seat-cards,
.bourre-seat--top-left .bourre-seat-cards,
.bourre-seat--top-right .bourre-seat-cards,
.bourre-seat--bottom-left .bourre-seat-cards,
.bourre-seat--bottom-right .bourre-seat-cards {
  margin: 0 6px;
}

.bourre-seat-card {
  position: relative;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.bourre-seat-card--empty {
  width: 40px;
  height: 56px;
}

.bourre-card-svg {
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
  width: 40px;
  height: 56px;
}

.bourre-trick-card .bourre-card-svg {
  width: 26px;
  height: 36px;
}

.bourre-turn-banner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255, 215, 0, 0.18);
  border: 1px solid rgba(255, 215, 0, 0.5);
  color: #ffd700;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  backdrop-filter: blur(4px);
  animation: turn-banner-pulse 1.5s ease-in-out infinite;
}

@keyframes turn-banner-pulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

.bourre-table-boo-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

.bourre-boo-seat {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.bourre-boo-seat--top {
  top: 12%;
  left: 50%;
  transform: translateX(-50%);
}

.bourre-boo-seat--left {
  top: 50%;
  left: 10%;
  transform: translateY(-50%);
}

.bourre-boo-seat--right {
  top: 50%;
  right: 10%;
  transform: translateY(-50%);
}

.bourre-boo-seat--top-left {
  top: 14%;
  left: 14%;
}

.bourre-boo-seat--top-right {
  top: 14%;
  right: 14%;
}

.bourre-boo-seat--bottom-left {
  bottom: 14%;
  left: 14%;
}

.bourre-boo-seat--bottom-right {
  bottom: 14%;
  right: 14%;
}

@media (max-width: 640px) {
  .bourre-table-felt {
    aspect-ratio: 4 / 3;
    min-height: auto;
    max-width: 100%;
    border-width: 5px;
    border-radius: 18px;
  }

  .bourre-table-felt-inner {
    top: 6%;
    left: 4%;
    right: 4%;
    bottom: 6%;
    border-width: 2px;
  }

  .bourre-felt-logo {
    font-size: clamp(14px, 4.5vw, 20px);
  }

  /* Push seats to the rim of the felt */
  .bourre-seat--bottom { bottom: 5%; left: 50%; transform: translateX(-50%); }
  .bourre-seat--top { top: 5%; left: 50%; transform: translateX(-50%); }
  .bourre-seat--left { left: 5%; top: 50%; transform: translateY(-50%); }
  .bourre-seat--right { right: 5%; top: 50%; transform: translateY(-50%); }
  .bourre-seat--top-left { top: 8%; left: 12%; transform: translateX(-50%); }
  .bourre-seat--top-right { top: 8%; right: 12%; transform: translateX(50%); }
  .bourre-seat--bottom-left { bottom: 8%; left: 12%; transform: translateX(-50%); }
  .bourre-seat--bottom-right { bottom: 8%; right: 12%; transform: translateX(50%); }

  .bourre-seat-avatar {
    width: 28px;
    height: 28px;
    border-width: 2px;
  }

  .bourre-seat-active-dot {
    width: 8px;
    height: 8px;
    border-width: 1.5px;
  }

  .bourre-seat-name {
    font-size: 8px;
    padding: 1px 3px;
  }

  .bourre-seat-tricks {
    font-size: 7px;
  }

  .bourre-seat-cards {
    height: 24px;
    margin: 2px 0;
  }

  /* On mobile, hide all table cards (player hand is in action panel, trick cards stay in center) */
  .bourre-seat--top .bourre-seat-cards,
  .bourre-seat--left .bourre-seat-cards,
  .bourre-seat--right .bourre-seat-cards,
  .bourre-seat--bottom .bourre-seat-cards,
  .bourre-seat--top-left .bourre-seat-cards,
  .bourre-seat--top-right .bourre-seat-cards,
  .bourre-seat--bottom-left .bourre-seat-cards,
  .bourre-seat--bottom-right .bourre-seat-cards {
    display: none;
  }

  /* Stack bottom player's name below avatar to avoid overlapping right seat */
  .bourre-seat--bottom .bourre-seat-meta {
    flex-direction: column;
    gap: 2px;
  }

  .bourre-table-center {
    gap: 2px;
  }

  .bourre-table-pot {
    font-size: 11px;
    padding: 3px 10px;
    border-width: 1.5px;
    box-shadow: 0 0 12px rgba(255, 215, 0, 0.25);
  }

  .bourre-trump {
    padding: 2px 6px;
    gap: 3px;
  }

  .bourre-trump-symbol {
    font-size: 13px;
  }

  .bourre-trump-name {
    font-size: 8px;
  }

  .bourre-trick-progress {
    font-size: 8px;
  }

  .bourre-trick-cards {
    gap: 3px;
    padding: 3px 5px;
    margin-top: 2px;
  }

  .bourre-trick-card-player {
    font-size: 7px;
  }

  .bourre-turn-banner {
    font-size: 9px;
    padding: 4px 8px;
  }

  .bourre-card-svg {
    width: 22px !important;
    height: 30px !important;
  }

  .bourre-trick-card .bourre-card-svg {
    width: 16px !important;
    height: 22px !important;
  }

  .bourre-seat-card--empty {
    width: 22px;
    height: 30px;
  }

  /* Bottom player: small horizontal fan */
  .bourre-seat--bottom .bourre-seat-card:nth-child(1) { transform: translateX(-18px) rotate(-4deg) !important; }
  .bourre-seat--bottom .bourre-seat-card:nth-child(2) { transform: translateX(-9px) rotate(-2deg) !important; }
  .bourre-seat--bottom .bourre-seat-card:nth-child(3) { transform: translateX(0) rotate(0) !important; }
  .bourre-seat--bottom .bourre-seat-card:nth-child(4) { transform: translateX(9px) rotate(2deg) !important; }
  .bourre-seat--bottom .bourre-seat-card:nth-child(5) { transform: translateX(18px) rotate(4deg) !important; }
}


