/* POKER TABLE — shared kit file for the casino poker tables (this copy: Caribbean Stud Poker, csp prefix).
   Ronan 2026-10-31: every casino table game gets the new table (no game name at the top,
   the table enlarged) and the Texas Hold'em look; placement for poker chosen by Ronan,
   21:55 "A" (decision P1):
     - Desktop: the utility buttons in one row across the top right of the felt; nothing
       else moves; the title band's height goes to the cards.
     - Phones: the buttons are their own row on the felt; Last win / Last bet and the
       balance share the line under it (balance at its right).
     - Sideways (known-issue size): buttons across the top of the felt, the balance on the
       felt level with them (as Punto Banco).
   Hook: class "pkt" on #cspGame, "pkt-page" on <body>. game.css is not edited. */

/* ---- the header becomes part of the felt ---------------------------------- */
html body #cspGame.pkt #cspTable .felt-surface{ position:relative; }
html body #cspGame.pkt #cspHeader{ background:none !important; border:0 !important; box-shadow:none !important; margin:0 !important; z-index:6; }
html body #cspGame.pkt #cspHeader .info-boxes{ margin:0 !important; }

/* ---- desktop: one row, top right --------------------------------------------- */
@media (min-width:680px) and (min-height:481px){
  html body #cspGame.pkt #cspHeader{ position:absolute !important; top:20px; right:20px; width:auto !important; padding:0 !important; height:auto !important; }
  html body #cspGame.pkt #cspSecondaryControls{ display:flex !important; gap:6px !important; }
  html body #cspGame.pkt .table-wrap{ padding-top:6px !important; }
  /* the balance column starts below the row */
  html body #cspGame.pkt .csp-right{ padding-top:60px; }
  /* the dealer's / shared row starts below the button row (it ran under it once the
     band was gone); what the band's 60px leaves after that goes to the cards */
  html body #cspGame.pkt .csp-dealer{ margin-top:52px; }
  html body #cspGame.pkt{
    --card-h-v: calc((100dvh - var(--csp-fixed) + 8px) / 2);
    --card-h: clamp(62px, min(var(--card-h-v), var(--card-h-w)), 150px);
    --card-w: calc(var(--card-h) * 0.712);
    --card-gap: clamp(8px, calc(var(--card-h) * 0.1), 14px);
  }
}

/* ---- phones: the buttons are their own row on the felt -------------------- */
@media (max-width:679px) and (min-height:481px){
  html body #cspGame.pkt #cspHeader{
    position:relative !important; display:flex !important; justify-content:center;
    padding:16px 18px 0 !important; width:100% !important;
  }
  html body #cspGame.pkt #cspHeader .info-boxes{ width:100%; display:block; }
  html body #cspGame.pkt #cspSecondaryControls{ width:100%; display:flex !important; justify-content:space-between; gap:4px !important; }
  /* six buttons: each takes its label's width (equal shares left "Settings" 1px from its edges) */
  html body #cspGame.pkt #cspSecondaryControls .gold-icon-btn{ flex:1 1 auto !important; min-width:0 !important; max-width:none !important; width:auto !important; padding:0 3px !important; }
  html body #cspGame.pkt #cspSecondaryControls .gold-icon-btn .btn-label{ letter-spacing:0 !important; }
  html body #cspGame.pkt #btnNewGame .btn-label{ white-space:normal !important; max-width:44px; }
  /* Last win / Last bet and the balance hang from the layout, on one line under the row */
  html body #cspGame.pkt .csp-layout{ position:relative; padding-top:44px !important; }
  html body #cspGame.pkt .csp-rail{ top:6px !important; left:18px !important; }
  html body #cspGame.pkt .csp-bank{ position:absolute !important; top:6px !important; right:18px !important; }
  /* each label over its figure (Ronan 2026-11-01, "labels over figures"): on one line side by
     side, large amounts ran into each other at 330-363 wide (+$1,500 / $1,000 / $10,000) */
  html body #cspGame.pkt .csp-rail .felt-stat{ display:flex !important; flex-direction:column !important; align-items:flex-start !important; gap:1px !important; }
  html body #cspGame.pkt .csp-bank{ flex-direction:column !important; align-items:flex-end !important; gap:1px !important; }
  html body #cspGame.pkt .csp-rail .felt-stat label, html body #cspGame.pkt .csp-bank label{ line-height:12px !important; }
}

/* ---- the narrowest phones (330 frame): six labels need the row's full width ---- */
@media (max-width:359px) and (min-height:481px){
  html body #cspGame.pkt #cspHeader{ padding:16px 13px 0 !important; }
  html body #cspGame.pkt #cspSecondaryControls{ gap:2px !important; }
  html body #cspGame.pkt #cspSecondaryControls .gold-icon-btn{ padding:0 2px !important; }
}

/* ---- phones 360-430 wide, betting: Deal shares a row with Undo / Clear / Rebet and the
        limits; the room kept above the play buttons (casino-readable.css, 12-33px for the HINT
        badge) pushed Deal ~10px lower than its neighbours (Ronan 2026-10-31 22:03, "deal button
        seems not aligned"). The row's other items line up with Deal's middle. ------------- */
@media (max-width:430px) and (min-height:481px) and (max-height:699px){
  html body[data-ui-phase="betting"] #cspGame.pkt .rack-tools,
  html body[data-ui-phase="betting"] #cspGame.pkt .csp-limits{ align-self:flex-end !important; margin-bottom:0 !important; }
  html body[data-ui-phase="betting"] #cspGame.pkt .csp-limits{ height:44px; justify-content:center !important; }
}

/* ---- sideways phones (known-issue size): buttons across the felt top, the balance on the
        felt level with them, inside the gold line ---------------------------- */
@media (max-height:480px){
  html body #cspGame.pkt #cspHeader{ padding:16px 10px 0 18px !important; height:auto !important; }
  html body #cspGame.pkt #cspHeader .wordmark{ display:none !important; }
  html body #cspGame.pkt #cspGame .gold-icon-btn, html body #cspGame.pkt #cspSecondaryControls .gold-icon-btn{ height:40px !important; }
  /* Last win / Last bet on the button line, between the buttons and the balance */
  html body #cspGame.pkt .csp-rail{ position:fixed !important; top:32px !important; left:440px !important; right:auto !important; flex-direction:row; }
  html body #cspGame.pkt .csp-bank{ position:fixed !important; top:30px !important; right:30px !important; }
  /* the row (about 60px) comes out of the cards' height, not off the bottom of the screen */
  /* the four bet spots as a 2 x 2 block: stacked, the column was taller than the screen
     (it ran off the bottom even before the redesign) */
  html body #cspGame.pkt .csp-spots{ display:grid !important; grid-template-columns:repeat(2, auto); column-gap:10px; row-gap:4px; padding-top:0 !important; justify-items:center; }
  html body #cspGame.pkt{
    --csp-l-w: 150px;
    --csp-fixed-l: 216px;
    --csp-card-hv: calc((100dvh - var(--csp-fixed-l)) / 2);
    --card-w: clamp(44px, min(var(--csp-card-wv), calc(var(--csp-card-hv) * 0.712)), 96px);
    --card-h: calc(var(--card-w) / 0.712);
  }
}

/* =============================================================================
   LOOK STANDARD — Texas Hold'em's styling (briefs/poker-family-decisions.md,
   LOOK STANDARD), as on the blackjacks and baccarats.
   ============================================================================= */
html body #cspGame.pkt, html body.pkt-page{
  --gold:#E9C46A; --gold-b:#F3D27A; --gold-d:#D9AE4E; --gold-t:#FCE7AA; --cream:#F6F0E1;
}
/* ---- header buttons: flat gold, no border, no bevel, no shadow ------------- */
html body #cspGame.pkt .gold-icon-btn,
html body #cspGame.pkt .gold-icon-btn:hover{
  background:linear-gradient(#F3D27A, #D9AE4E) !important;
  border:0 !important; box-shadow:none !important; border-radius:9px !important;
  min-height:44px !important; color:#1B1406 !important;
}
html body #cspGame.pkt .gold-icon-btn[aria-pressed="false"],
html body #cspGame.pkt .gold-icon-btn[aria-pressed="false"]:hover{ background:linear-gradient(#E7DCC2, #C9B98F) !important; }
html body #cspGame.pkt .gold-icon-btn .btn-label,
html body #cspGame.pkt .gold-icon-btn.coach-btn .btn-val{ color:#1B1406 !important; font-weight:800 !important; font-family:Inter, "Helvetica Neue", Arial, sans-serif !important; }
html body #cspGame.pkt .gold-icon-btn .ico{ color:#1B1406 !important; }

/* ---- fonts: Georgia 700 for titles and display lines; Inter body; Plex Mono figures */
html body #cspGame.pkt .panel h2,
html body #cspGame.pkt .pt-title,
html body #cspGame.pkt .serif,
html body .coach-start-title{ font-family:Georgia, "Times New Roman", serif !important; font-weight:700 !important; }
html body #cspGame.pkt .csp-call,
html body #cspGame.pkt .csp-rank-pill,
html body #cspGame.pkt .ts-title,
html body #cspGame.pkt .st-hand{ font-family:Georgia, "Times New Roman", serif !important; font-weight:700 !important; }
html body .panel-overlay .panel h2{ font-family:Georgia, "Times New Roman", serif !important; font-weight:700 !important; }

/* ---- the selected choice turns solid gold with dark text ------------------- */
html body .coach-choice.selected{
  background:linear-gradient(#F3D27A, #D9AE4E) !important; border-color:transparent !important; box-shadow:none !important;
}
html body .coach-choice.selected .coach-choice-title,
html body .coach-choice.selected .coach-choice-desc{ color:#1B1406 !important; }


/* =============================================================================
   PANELS AND CHOICE BUTTONS = Texas Hold'em's (decisions B3/B4/B5, Ronan
   2026-10-31 18:13-18:16 "change panels"; holdem.css .overlay/.panel/.choice).
   Start, Resume, Rules, Settings, New game confirm and out-of-chips: solid
   #141A2E, 2px solid gold, 16px corners, heading Georgia 700 20px #F3D27A,
   backdrop rgba(5,7,14,.78). Choices: #26345E, 1px #4A5A8C, 10px corners,
   label 800 13px; selected solid gold with #1B1406 text.
   ============================================================================= */
html body .panel-overlay{ background:rgba(5,7,14,.78) !important; }
html body .coach-start{ background:rgba(5,7,14,.78) !important; }
html body .panel-overlay .panel,
html body .coach-start .coach-start-card{
  background:#141A2E !important; background-image:none !important;
  border:2px solid #E9C46A !important; border-radius:16px !important; box-shadow:none !important;
}
html body .panel-overlay .panel h2,
html body .coach-start .coach-start-title{ font-family:Georgia, "Times New Roman", serif !important; font-weight:700 !important; font-size:20px !important; color:#F3D27A !important; }
html body .coach-start .coach-start-sub{ color:#D3DBF2 !important; font-size:13px !important; font-weight:600 !important; }
html body .coach-choice{
  background:#26345E !important; background-image:none !important; border:1px solid #4A5A8C !important;
  border-radius:10px !important; box-shadow:none !important;
}
html body .coach-choice .coach-choice-title{ font-family:Inter, "Helvetica Neue", Arial, sans-serif !important; font-size:13px !important; font-weight:800 !important; color:#F6F0E1 !important; }
html body .coach-choice .coach-choice-desc{ font-size:12px !important; font-weight:600 !important; color:#D3DBF2 !important; }
html body .coach-choice.selected{ background:linear-gradient(#F3D27A, #D9AE4E) !important; border-color:transparent !important; }
html body .coach-choice.selected .coach-choice-title{ color:#1B1406 !important; }
html body .coach-choice.selected .coach-choice-desc{ color:#3A2C0A !important; }
