.action-dock { position: relative; display: grid; container: poker-controls / inline-size; grid-template-columns: minmax(0, .8fr) minmax(0, 1fr); align-content: start; gap: 20px; padding: 20px var(--panel-inset); background: #222c38; border: 1px solid #45505f; border-radius: var(--panel-radius); }
.action-context { display: grid; align-content: start; grid-template-rows: 44px 44px auto; gap: 2px; min-width: 0; }
.action-context .eyebrow { align-self: center; font-size: 14px; color: var(--accent); }
.action-context strong { align-self: center; font-size: 20px; font-weight: 650; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
.action-context>span:last-child { font-size: 14px; color: #bcc6d0; line-height: 1.4; }
.action-buttons { display: flex; gap: 10px; grid-column: 1 / -1; }
.action-buttons .button { min-height: 68px; font-size: 16px; flex: 1; min-width: 0; display: grid; grid-template-rows: 22px minmax(20px, auto); align-content: start; gap: 2px; }
.action-buttons small { font-size: 17px; font-weight: 750; white-space: normal; overflow-wrap: anywhere; }
.fold-button { background: #2c3745; color: #e0e4e9; border-color: #546170; }
.call-button { background: #335c65; color: #eef8f8; border-color: #608d95; }
.bet-controls { align-self: center; min-width: 0; }
.bet-topline { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 8px; }
.bet-topline>label { font-size: 14px; color: #c2ccd6; }
.bet-presets { display: flex; justify-content: flex-end; gap: 4px; }
.preset-button { background: transparent; border: 1px solid #526070; border-radius: 4px; padding: 0 7px; min-height: 44px; min-width: 44px; color: #e1e8ef; font-size: 14px; flex: 1; max-width: 80px; }
.preset-button:hover { background: #405165; }
.amount-field { grid-column: 1 / -1; display: flex; width: 100%; align-items: center; gap: 8px; margin-top: 2px; padding: 0 10px; border: 1px solid #637082; border-radius: 5px; background: #141d27; }
.amount-field input { min-height: 44px; min-width: 0; width: 100%; border: none; background: none; font-size: 18px; padding: 5px 0; font-weight: 650; }
.amount-field>span { flex: none; white-space: nowrap; font-size: 14px; color: #aab8c6; }
.amount-field:focus-within { border-color: var(--accent); }
.bet-slider { display: block; width: 100%; height: 44px; padding: 0; margin: 4px 0 0; appearance: none; border: 0; background: transparent; cursor: pointer; }
.bet-slider::-webkit-slider-runnable-track { height: 4px; background: linear-gradient(to right, #e2be80 var(--range, 0%), #5c6a7a var(--range, 0%)); border-radius: 3px; }
.bet-slider::-webkit-slider-thumb { appearance: none; width: 22px; height: 22px; border-radius: 50%; background: #f4d5a0; border: 2px solid #fff0d2; margin-top: -9px; }
.bet-slider::-moz-range-track { height: 4px; background: #697687; }
.bet-slider::-moz-range-thumb { background: #f4d5a0; border: 2px solid #fff0d2; }
.bet-bounds { display: flex; justify-content: space-between; color: #b8c3cf; font-size: 14px; }
.action-message { grid-column: 1 / -1; padding: 12px; border: 1px solid #a17562; background: #48372f; color: #ffe0cb; border-radius: 6px; font-size: 14px; line-height: 1.45; }
.action-message:empty { display: none; }
.action-dock.read-only { display: flex; align-items: center; justify-content: space-between; }
.action-dock.read-only .action-context { flex: 1; }
.action-dock.read-only .action-buttons:empty { display: none; }
.action-dock.replay-mode { border-top-color: #ba9d68; }
.panel-scrim { position: fixed; inset: 0; background: #070c13aa; z-index: 20; }
.history-panel { position: fixed; z-index: 21; right: 0; top: 0; bottom: 0; width: min(440px, 100vw); display: flex; flex-direction: column; background: #1b2531; border-left: 1px solid #586473; box-shadow: -20px 0 60px #0005; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px var(--panel-inset); border-bottom: 1px solid #3b4857; }
.panel-heading .eyebrow { margin-bottom: 7px; font-size: 14px; }
.panel-heading>div { flex: 1; min-width: 0; }
.panel-heading h2 { font-size: 23px; overflow-wrap: anywhere; }
.panel-heading>button { flex: none; }
.history-list { padding: 10px 14px; overflow-y: auto; max-height: 28%; border-bottom: 1px solid #394656; min-height: 75px; flex: none; }
.history-hand { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: transparent; border: 1px solid transparent; width: 100%; border-radius: 7px; padding: 12px 9px; text-align: left; }
.history-hand:hover, .history-hand.selected { background: #2b3949; border-color: #526375; }
.hand-summary { display: flex; flex-direction: column; min-width: 0; gap: 5px; }
.hand-summary strong { font-size: 15px; }
.hand-summary>span { font-size: 14px; color: #b7c5d3; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.history-detail { flex: 1; overflow: auto; padding: 0 var(--panel-inset) 20px; min-height: 0; }
.history-street { color: var(--accent); font-size: 14px; letter-spacing: 1px; margin: 22px 0 12px; }
.history-event { font-size: 14px; line-height: 1.65; padding: 8px 0; border-bottom: 1px solid #ffffff0a; color: #d8e0e8; }
.history-event.current { color: white; font-weight: 600; }
.history-empty { padding: 22px 8px; color: #b5c2d0; font-size: 14px; line-height: 1.6; }
.settlement-summary { background: #ffffff04; border: 1px solid #536270; border-radius: 7px; padding: 0 14px 10px; margin-top: 20px; }
.replay-controls { padding: 20px var(--panel-inset); border-top: 1px solid #566575; background: #253342; }
.replay-progress { display: flex; justify-content: space-between; font-size: 14px; font-weight: 650; color: #e4c58f; margin-bottom: 12px; }
.replay-buttons { display: flex; gap: 7px; }
.replay-buttons .button { padding: 9px 11px; }
.settings-dialog { width: min(650px, calc(100vw - 24px)); max-height: calc(100dvh - 32px); padding: 0; color: var(--text); border: 1px solid #586575; border-radius: 12px; background: #1c2733; box-shadow: 0 24px 90px #0007; }
.settings-dialog::backdrop { background: #060a10bd; }
.settings-body { padding: 20px var(--panel-inset); }
.settings-intro { color: #bdcbd8; font-size: 15px; line-height: 1.5; }
.setting-section { margin-top: 24px; }
.settings-grid { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 14px; }
.settings-grid label, .director-options label { display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: #ccd6e0; }
.settings-grid input, .settings-grid select { width: 100%; }
.segmented { display: flex; gap: 4px; }
.segmented button { border: 1px solid #4b5a6b; border-radius: 5px; background: #253444; min-height: 44px; padding: 0 9px; font-size: 14px; color: #c7d3df; }
.segmented button.selected { background: #d7b77e; border-color: #f0d3a1; color: #221c13; font-weight: 650; }
.lineup-head, .lineup-row { display: grid; grid-template-columns: 65px minmax(0, 1fr) 108px; gap: 9px; align-items: center; }
.lineup-head { color: #a5b6c8; font-size: 14px; letter-spacing: .8px; margin: 16px 0 9px; }
.lineup-row { margin: 7px 0; }
.lineup-row input { width: 100%; height: 44px; font-size: 15px; }
.lineup-seat { display: flex; align-items: center; min-height: 44px; gap: 8px; font-size: 14px; }
.lineup-seat input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.lineup-row.inactive input:not([type=checkbox]) { opacity: .35; }
.field-hint { color: #a9bbcd; line-height: 1.6; font-size: 14px; margin: 10px 0; }
.director-options { border-top: 1px solid #465566; margin-top: 24px; padding-top: 16px; }
.director-options summary { min-height: 44px; display: flex; justify-content: space-between; align-items: center; font-size: 14px; font-weight: 600; list-style: none; }
.details-plus { font-size: 20px; color: var(--accent); }
.director-options label { margin: 14px 0; }
.director-options textarea { resize: vertical; }
.export-link { padding-left: 0; }
.form-error { margin-top: 16px; border: 1px solid #a97768; border-radius: 6px; padding: 12px; background: #4b352f; color: #ffd9cb; font-size: 14px; }
.dialog-footer { display: flex; justify-content: space-between; align-items: center; padding: 20px var(--panel-inset); gap: 18px; border-top: 1px solid #465566; background: #253241; }
.dialog-footer>span { font-size: 14px; color: #b9c8d7; line-height: 1.5; }
@container poker-controls (max-width: 560px) {
  .action-context, .bet-controls, .action-buttons { grid-column: 1 / -1; }
  .action-context { grid-template-rows: auto auto auto; gap: 6px; }
}
@media (max-width: 540px) {
  .action-dock { padding: 20px var(--panel-inset); grid-template-columns: 1fr; gap: 12px; }
  .action-context strong { align-self: center; font-size: 19px; }
  .action-context .eyebrow { font-size: 14px; }
  .action-context>span:last-child { font-size: 14px; }
  .bet-topline { grid-template-columns: 1fr; }
  .bet-presets { gap: 5px; width: 100%; justify-content: space-between; }
  .bet-topline>label { display: none; }
  .preset-button { padding: 0 8px; min-height: 44px; flex: 1; }
  .amount-field { width: 100%; margin: 2px 0 0; }
  .amount-field input { font-size: 17px; }
  .action-buttons { gap: 7px; }
  .action-buttons .button { min-height: 68px; font-size: 15px; padding: 8px 5px; gap: 2px; }
  .action-buttons small { font-size: 15px; }
  .action-dock.read-only { flex-direction: column; align-items: stretch; }
  .settings-body { padding: 16px; }
  .panel-heading { padding: 18px 16px; gap: 10px; }
  .panel-heading h2 { font-size: 21px; }
  .setting-section .section-heading { flex-wrap: wrap; }
  .lineup-head, .lineup-row { grid-template-columns: 47px minmax(0, 1fr) 100px; gap: 6px; }
  .lineup-row input { padding: 8px; font-size: 14px; }
  .lineup-seat { gap: 5px; }
  .settings-grid { gap: 8px; grid-template-columns: 1fr 1fr; }
  .settings-grid label:last-child { grid-column: 1 / -1; }
  .settings-grid select { max-width: none; }
  .dialog-footer { padding: 16px; align-items: flex-end; gap: 12px; }
  .dialog-footer .button { padding: 10px; }
}
