:root {
  color-scheme: dark;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #000;
  color: #f4f4f4;
  font-synthesis: none;
  -webkit-tap-highlight-color: transparent;
}
* { box-sizing: border-box; }
body { margin: 0; }
button { font: inherit; }
.table {
  min-height: 100vh;
  min-height: 100svh;
  max-width: 680px;
  margin: 0 auto;
  padding: max(32px, env(safe-area-inset-top)) 24px max(36px, env(safe-area-inset-bottom));
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  align-items: center;
}
.opponent, .player, .community { display: flex; flex-direction: column; align-items: center; }
.hand { display: flex; gap: 9px; }
.opponent-trigger { background: transparent; border: 0; padding: 0; cursor: pointer; touch-action: manipulation; border-radius: 8px; }
.opponent-trigger:focus-visible, .opponent-choice:focus-visible { outline: 2px solid #f3f0e9; outline-offset: 4px; }
.opponent-picker { width: min(320px, calc(100% - 24px)); padding: 20px; margin: auto; border: 1px solid #343434; border-radius: 16px; background: #111; color: #f4f4f4; }
.opponent-picker::backdrop { background: #000b; }
.opponent-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.opponent-choice { min-height: 52px; border: 1px solid #555; border-radius: 6px; background: #222; color: #f4f4f4; font-size: 20px; cursor: pointer; touch-action: manipulation; }
.opponent-choice[aria-pressed="true"] { background: #f3f0e9; color: #151515; }
.playing-card {
  width: clamp(70px, 21vw, 92px);
  aspect-ratio: 5 / 7;
  border-radius: 8px;
  position: relative;
  display: block;
  flex: 0 0 auto;
}
.card-back {
  background: #f3f0e9 url('/rider-back.webp') center / 100% 100% no-repeat;
  border: 1px solid #d9d4ca;
}
.eyebrow { margin-top: 18px; color: #858585; font-size: 10px; font-weight: 500; text-transform: uppercase; letter-spacing: .2em; }
.board { display: flex; justify-content: center; gap: clamp(6px, 2vw, 12px); padding: 10px 0; border: 0; background: transparent; width: 100%; cursor: pointer; touch-action: manipulation; }
.board:focus-visible { outline: 2px solid #aaa; outline-offset: 8px; border-radius: 8px; }
.board .playing-card { width: calc((100% - 48px) / 5); max-width: 86px; border-radius: 6px; }
.card-slot { border: 1px dotted #555; background: transparent; }
.card-face { background: #f3f0e9; color: #151515; box-shadow: 0 1px 0 #fff3 inset; }
.card-face.red { color: #b8313b; }
.card-face.hand-card { box-shadow: 0 0 0 1px #000, 0 0 0 3px #39ff88, 0 0 12px #39ff8833; }
.corner { position: absolute; top: 8%; left: 11%; display: flex; flex-direction: column; align-items: center; font-size: clamp(18px, 5.5vw, 25px); font-weight: 650; line-height: 1.05; }
.corner .small-suit { font-size: .75em; margin-top: 2px; }
.center-suit { position: absolute; bottom: 12%; right: 13%; font-family: Georgia, serif; font-size: clamp(26px, 8vw, 38px); line-height: 1; }
.board .corner { font-size: clamp(15px, 4.3vw, 24px); }
.board .center-suit { font-size: clamp(22px, 6vw, 36px); }
.stage { margin: 14px 0 0; min-height: 18px; text-align: center; font-size: 12px; color: #858585; letter-spacing: .025em; }
.player-row { display: flex; align-items: center; gap: clamp(18px, 6vw, 36px); }
.odds { display: flex; flex-direction: column; align-items: flex-start; min-width: 86px; }
.percentage { font-size: clamp(30px, 9vw, 42px); font-weight: 450; line-height: 1.15; letter-spacing: -.055em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.odds-label { color: #999; font-size: 11px; margin-top: 5px; }
.odds-detail { color: #777; font-size: 10px; margin-top: 9px; white-space: nowrap; }
.odds[aria-busy="true"] .percentage { color: #777; }
@keyframes deal { from { opacity: 0; transform: translateY(-7px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: no-preference) { .dealt { animation: deal 240ms ease-out both; } }
@media (max-width: 350px) { .table { padding-left: 18px; padding-right: 18px; } .player-row { gap: 16px; } .hand { gap: 7px; } .playing-card { width: 65px; } }
@media (max-height: 520px) and (orientation: landscape) { .table { min-height: 520px; } }
