/* Agreed October 2026 presentation. Legacy behavior and action IDs stay intact. */
:root {
  color-scheme: dark;
  --ui-bg: #090f1b;
  --ui-surface: #121d2e;
  --ui-raised: #19273c;
  --ui-line: #2b3a50;
  --ui-text: #f5f7fc;
  --ui-muted: #adbbcf;
  --ui-yellow: #ffe082;
  --ui-blue: #93c7ff;
  --ui-red: #d92d4c;
  --bid-panel-height: 300px;
}
[hidden] { display: none !important; }
body { background: var(--ui-bg); color: var(--ui-text); font: 16px/1.5 'Segoe UI', system-ui, sans-serif; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 3px solid var(--ui-yellow); outline-offset: 4px; }
input, select, textarea { color: var(--ui-text); background: #0e1726; border: 1px solid #53647e; border-radius: 10px; max-width: 100%; min-width: 0; }
label { font-weight: 600; font-size: .9rem; }
summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; gap: 8px; }
details > summary::after { content: '+'; margin-left: auto; color: var(--ui-muted); }
details[open] > summary::after { content: '−'; }
h1, h2, h3 { line-height: 1.2; }
h1 { font-size: clamp(1.9rem, 4vw, 3.5rem); letter-spacing: -.04em; }
h2 { font-size: 1.5rem; letter-spacing: -.02em; }
.muted, .settings-label-desc, .product-details-small { color: var(--ui-muted); font-style: normal; }
.eyebrow { display: block; color: var(--ui-yellow); text-transform: uppercase; letter-spacing: .1em; font-size: .75rem; font-weight: 700; margin-bottom: 10px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.ui-icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
#app { max-width: 1140px; margin: 20px auto; padding: 0; background: linear-gradient(145deg,#101b2c,#0c1422); border: 1px solid var(--ui-line); border-radius: 22px; min-width: 0; }
.screen { padding: 32px; }
.game-phase { padding: 0; margin-top: 28px; }
.game-phase > h2, .screen-heading h1 { color: var(--ui-yellow); text-align: left; margin-bottom: 10px; font-size: 2rem; }
.phase-subtitle, .screen-heading p { color: var(--ui-muted); margin-bottom: 24px; }
.ui-panel, .player-list-container, .bid-panel, .product-card { border: 1px solid var(--ui-line); border-radius: 18px; background: var(--ui-surface); padding: 24px; box-shadow: none; }
.btn { min-height: 46px; border-radius: 11px; padding: 11px 18px; font-size: 1rem; font-weight: 650; display: inline-flex; align-items: center; justify-content: center; gap: 8px; box-shadow: none; transform: none; }
.btn-primary, .btn-restart { background: var(--ui-red); border: 1px solid var(--ui-red); color: #fff; }
.btn-secondary { background: transparent; border: 1px solid #465872; color: var(--ui-text); }
.btn-small { font-size: .85rem; padding: 8px 12px; min-height: 44px; }
.btn-large { font-size: 1rem; padding: 12px 18px; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 16px; }
.section-heading .muted { margin: 0; font-size: .8rem; text-align: right; }

/* The same navigation before joining, in the lobby, and during the game. */
.game-header { display: flex; align-items: center; gap: 16px; padding: 18px 24px; border: 0; border-bottom: 1px solid var(--ui-line); border-radius: 22px 22px 0 0; background: #111c2d; }
.logo-banner-img { width: 214px; height: auto; max-width: 100%; }
.game-header-left { flex: none; min-width: 0; }
.room-name-display { margin-left: auto; color: var(--ui-muted); font-size: .85rem; font-weight: 600; max-width: 230px; overflow: hidden; text-overflow: ellipsis; }
.game-header-right { display: flex; gap: 6px; flex-wrap: nowrap; align-items: center; }
.btn-how-to-play, .btn-settings-gear, .btn-host-crown { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: transparent; border: 0; border-radius: 10px; padding: 10px; min-height: 44px; color: var(--ui-text); animation: none; font-size: .85rem; }
.btn-host-crown { color: var(--ui-yellow); }
.btn-settings-gear, .btn-host-crown { width: 44px; }
.room-menu { position: relative; }
.room-menu > summary { list-style: none; padding: 10px; border: 1px solid #465872; border-radius: 10px; font-size: .85rem; }
.room-menu > summary::-webkit-details-marker { display: none; }
.room-menu > summary::after { content: ''; }
.room-menu-panel { position: absolute; top: calc(100% + 10px); right: 0; z-index: 80; width: 260px; max-width: calc(100vw - 32px); display: grid; gap: 12px; padding: 16px; border: 1px solid #52647e; border-radius: 14px; background: var(--ui-raised); box-shadow: 0 12px 40px #0008; }
.btn-new-game { min-height: 44px; border: 1px solid #915264; background: #442335; color: #ffd0dc; border-radius: 10px; padding: 10px; font-size: .85rem; white-space: normal; }
.game-name-row { flex-wrap: wrap; gap: 12px; }
.game-name-row .btn-settings-gear, .game-name-row .btn-host-crown, .game-name-row .btn-qr-invite { display: none !important; }

/* Welcome, joining and the host/guest lobby. */
.welcome-layout { display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: center; padding: 30px 16px; }
.welcome-copy h1 { margin: 16px 0 24px; }
.welcome-copy > p { color: var(--ui-muted); max-width: 450px; }
.welcome-meta { margin-top: 24px; font-size: .85rem; }
.welcome-actions { display: grid; gap: 14px; }
.welcome-actions p { color: var(--ui-muted); font-size: .9rem; }
.welcome-actions .inline-form { display: flex; align-items: stretch; }
.welcome-actions input { width: 100%; min-width: 0; background: #0e1726; }
.welcome-actions .inline-form .btn { flex: none; }
.or-divider { display: flex; align-items: center; gap: 12px; color: var(--ui-muted); font-size: .8rem; margin: 8px 0; }
.or-divider::before, .or-divider::after { content: ''; flex: 1; border-top: 1px solid var(--ui-line); }
.center-card { max-width: 580px; padding: 28px; border: 1px solid var(--ui-line); border-radius: 18px; background: var(--ui-surface); box-shadow: none; }
.join-card > .page-logo-img { display: none; }
.join-card h1 { color: var(--ui-yellow); font-size: 2rem; margin-bottom: 8px; }
.join-card > .muted { margin: 0 0 24px; }
.join-card .inline-form { display: grid; gap: 12px; text-align: left; }
.join-card .inline-form input { width: 100%; }
.join-room-password-row label { display: block; margin-bottom: 8px; }
.join-room-password-row input { width: 100%; }
.lobby-container { max-width: none; text-align: left; padding: 0; }
.screen-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.screen-heading .game-name-row { margin: 0; }
.lobby-layout { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(300px,1fr); gap: 24px; align-items: start; }
.player-list-container { max-width: none; width: 100%; margin: 0; }
.player-list-container h2 { font-size: 1.25rem; color: var(--ui-yellow); margin: 0; }
#lobby-player-list li { padding: 14px 0; gap: 12px; border-color: var(--ui-line); }
.player-name { min-width: 0; overflow-wrap: anywhere; }
.player-host-badge, .player-you-badge { display: inline-block; margin-left: 6px; font-size: .65rem; border-radius: 5px; padding: 2px 6px; background: #233247; color: var(--ui-yellow); }
.player-disconnected { opacity: 1; border-left: 3px solid #ef99aa; padding-left: 10px !important; }
.conn-status-label { display: inline-block; margin-left: 8px; font-size: .7rem; color: #ffc4d3; }
.btn-remove { min-height: 44px; padding: 8px 12px; flex: none; border-color: #915264; background: #442335; color: #ffd0dc; border-radius: 9px; font-size: .8rem; }
.lobby-sidebar { display: grid; gap: 20px; }
.lobby-sidebar h2 { margin: 0 0 12px; font-size: 1.3rem; color: var(--ui-yellow); }
.invite-panel { background: #192a41; border-color: #3d5374; }
.invite-panel p { color: var(--ui-muted); margin-bottom: 18px; }
.lobby-sidebar .btn { width: 100%; margin-top: 10px; }
.lobby-setup-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 20px 0; }
.lobby-setup-summary dt { font-size: .82rem; color: var(--ui-muted); }
.lobby-setup-summary dd { margin: 4px 0 0; font-weight: 650; }
.lobby-host-checklist { margin: 24px 0 0; padding: 16px 20px; border: 1px solid var(--ui-line); background: transparent; }
.onboarding-panel { margin-bottom: 24px; text-align: left; }
.onboarding-steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.onboarding-steps strong { color: var(--ui-yellow); }
.onboarding-steps p { margin-top: 8px; font-size: .86rem; }
.onboarding-actions { display: flex; justify-content: flex-end; align-items: center; gap: 16px; margin-top: 18px; }

/* Selected compact scorecards; never collapse or hide the full roster. */
.competition-panel { padding: 16px; background: #111f32; border: 1px solid #354c68; border-radius: 14px; }
.competition-panel .section-heading { margin-bottom: 16px; }
.competition-panel h2 { color: var(--ui-yellow); text-transform: uppercase; letter-spacing: .08em; font-size: .75rem; }
.scoreboard { display: grid; grid-template-columns: repeat(auto-fill,minmax(108px,1fr)); gap: 14px 8px; padding: 0; margin: 0; border: 0; background: none; border-radius: 0; }
.score-card-wrap { position: relative; min-width: 0; }
.score-item, .score-item.other, .score-item.leader { width: 100%; min-width: 0; min-height: 64px; display: grid; align-content: center; gap: 3px; padding: 8px; border: 1px solid #5481af; border-radius: 9px; background: #234e7a; color: #f7fbff; text-align: left; font-variant-numeric: tabular-nums; transform: none; box-shadow: none; animation: none; transition: background .15s; }
.score-name-row, .score-value-row { display: flex; gap: 4px; min-width: 0; width: 100%; align-items: center; }
.score-value-row { justify-content: space-between; min-height: 23px; flex-wrap: wrap; row-gap: 2px; }
.score-item .score-name, .score-item.leader .score-name { display: block; color: inherit; font-size: .8125rem; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.score-item .score-value, .score-item.leader .score-value { color: var(--ui-yellow); font-size: 1rem; line-height: 1.2; white-space: nowrap; }
.score-value small { font-size: .5rem; font-weight: 500; }
.score-you { flex: none; background: #102d4e; color: #fff1b9; border-radius: 4px; padding: 1px 3px; font-size: .55rem; font-weight: 700; line-height: 1.3; }
.score-status { max-width: 32px; color: var(--ui-yellow); font-size: .55rem; font-weight: 750; text-align: right; line-height: 1.1; }
.score-item.disconnected { opacity: 1; background: #263a56; border: 1px dashed #ef99aa; }
.score-item.active-turn, .score-item.active-turn.disconnected { background: #ffdc64; color: #192638; border: 2px solid #fff0b0; padding: 7px; box-shadow: 0 0 0 2px #ffe08214; animation: none; }
.score-item.active-turn.disconnected { border-style: dashed; border-color: #7e3f57; }
.score-item.active-turn .score-value, .score-item.active-turn .score-status { color: #192638; }
.score-item.active-turn .score-you { background: #19263812; color: #192638; }
.score-offline-label { position: absolute; top: -8px; left: 50%; transform: translateX(-50%); padding: 2px 5px; border: 1px solid #ec9bad; border-radius: 5px; background: #432c3b; color: #ffe0e8; font-size: .56rem; line-height: 1.2; font-weight: 750; white-space: nowrap; }
.score-tooltip { display: none; position: absolute; bottom: calc(100% + 12px); left: 50%; transform: translateX(calc(-50% + var(--tooltip-offset,0px))); z-index: 85; width: 220px; max-width: calc(100vw - 24px); padding: 11px 13px; border: 1px solid #62768d; border-radius: 10px; background: #ebf2fc; color: #13243a; box-shadow: 0 7px 25px #0006; font-size: .8rem; visibility: hidden; opacity: 0; pointer-events: none; }
.score-card-wrap:focus-within .score-tooltip, .score-card-wrap.tooltip-open .score-tooltip { display: block; visibility: visible; opacity: 1; }
.score-card-wrap.tooltip-measuring .score-tooltip { display: block; visibility: hidden; }
.score-card-wrap.tooltip-dismissed .score-tooltip { visibility: hidden; opacity: 0; }
.round-indicator { margin: 0 0 14px; letter-spacing: 0; color: var(--ui-muted); text-transform: none; text-align: left; }
.phase-path { display: flex; flex-wrap: wrap; gap: 6px; font-size: .8rem; }
.phase-path span { padding: 5px 8px; border-radius: 7px; }
.phase-path .current { color: var(--ui-yellow); background: #ffe08214; }

/* Timed bidding: product + persistent action panel, without recreating inputs. */
.timed-play-layout { display: grid; grid-template-columns: minmax(0,1.4fr) minmax(290px,1fr); gap: 28px; align-items: start; }
.product-card { width: 100%; max-width: none; margin: 0; text-align: left; }
.product-image-container { width: 100%; height: 280px; margin-bottom: 22px; padding: 20px; background: radial-gradient(ellipse,#f8f9fc,#dee5ef); }
.product-image-container img { width: 100%; height: 100%; object-fit: contain; }
.product-info h3 { color: var(--ui-yellow); font-size: 1.5rem; overflow-wrap: anywhere; }
.product-info p { color: var(--ui-muted); font-size: .95rem; }
.product-detail-disclosure { margin-top: 14px; padding-top: 8px; border-top: 1px solid var(--ui-line); }
.product-hint { margin-top: 12px; background: #ffe08212; color: var(--ui-yellow); border-radius: 6px; }
.bid-panel { position: sticky; top: 20px; background: #19263a; border-color: #44546a; }
.bid-panel .section-heading { margin-bottom: 18px; }
.bid-panel .timer { font-size: 1.4rem; line-height: 1.25; padding: 7px 10px; margin: 0; border: 1px solid #53647e; border-radius: 9px; color: var(--ui-text); font-variant-numeric: tabular-nums; }
.bid-panel .timer::after { content: ' sec'; font-size: .72rem; color: var(--ui-muted); font-weight: 500; }
.bid-panel .timer.urgent { color: #ffc0ce; background: #442335; border-color: #a66077; animation: none; }
body.timer-urgent-bg { background: var(--ui-bg); animation: none; }
.bid-form { align-items: stretch; gap: 12px; margin-top: 0; text-align: left; }
/* Keep the final-seconds cue around the bid controls instead of tinting the whole page. */
body.timer-urgent-bg #bid-form,
body.timer-urgent-bg #showcase-bid-form {
  background-color: rgba(227, 24, 55, 0.08);
  border-radius: 12px;
  animation: bid-entry-urgent-pulse 1.4s ease-in-out infinite;
}
@keyframes bid-entry-urgent-pulse {
  0%, 100% { background-color: rgba(227, 24, 55, 0.07); box-shadow: 0 0 0 0 rgba(227, 24, 55, 0); }
  50% { background-color: rgba(227, 24, 55, 0.18); box-shadow: 0 0 0 1px rgba(227, 24, 55, 0.24), 0 5px 18px rgba(227, 24, 55, 0.12); }
}
.bid-input-group { width: 100%; padding: 0 14px; border: 1px solid #657994; border-radius: 12px; background: #0c1728; }
.bid-input-group:focus-within { outline: 3px solid var(--ui-yellow); outline-offset: 3px; }
.bid-input-group .dollar-sign { font-size: 1.7rem; font-weight: 500; color: var(--ui-muted); }
.bid-input-group input { width: 100%; min-width: 0; font-size: 1.8rem; padding: 14px 0 14px 8px; border: 0; background: transparent; border-radius: 0; text-align: left; font-variant-numeric: tabular-nums; }
.bid-input-group input:focus { outline: none; box-shadow: none; }
.field-help { color: var(--ui-muted); font-size: .8rem; }
.field-error { color: #ffc0ce; font-size: .85rem; }
.bid-submitted { margin-top: 0; text-align: center; }
.bid-submitted h3 { color: #b9f2d8; font-size: 1.05rem; }
.locked-amount { display: block; font-size: 2.25rem; font-variant-numeric: tabular-nums; margin: 12px 0; }
.bid-submitted p { color: var(--ui-muted); font-size: .86rem; }
.bid-progress { color: var(--ui-muted); font-size: .8rem; margin-top: 18px; }
.bid-bar { width: 100%; background: #33435b; }
.bid-bar-fill { background: #9abcdf; }
.phase-hint { color: #dfeaff; background: #1b2f49; border: 1px solid #45678d; border-radius: 12px; box-shadow: none; }
.phase-hint-dismiss { color: var(--ui-blue); min-height: 44px; }
.showcase-products { display: grid; grid-template-columns: 1fr; gap: 16px; }
.showcase-product-card { display: grid; grid-template-columns: 112px minmax(0,1fr); gap: 20px; align-items: center; padding: 20px; margin: 0; width: 100%; max-width: none; text-align: left; border: 1px solid var(--ui-line); border-radius: 14px; background: var(--ui-surface); }
.showcase-product-card.image-unavailable { grid-template-columns: minmax(0,1fr); }
.showcase-product-card img { width: 112px; height: 112px; padding: 10px; object-fit: contain; background: #e8eef6; border-radius: 10px; margin: 0; }
.showcase-product-card h4 { color: var(--ui-yellow); font-size: 1.05rem; margin-bottom: 6px; overflow-wrap: anywhere; }
.showcase-product-card p { color: var(--ui-muted); font-size: .88rem; }
.showcase-product-card details { font-size: .8rem; margin-top: 8px; color: var(--ui-muted); }
.showcase-product-copy { min-width: 0; }
.showcase-price { margin-top: 10px; font-size: 1.3rem; }

/* Wheel totals and decisions occupy one readable area. */
.wheel-decision-layout { display: grid; grid-template-columns: 1.2fr 1fr; gap: 28px; align-items: center; }
.wheel-container { width: 100%; max-width: none; padding: 24px; margin: 0; border: 1px solid var(--ui-line); border-radius: 18px; background: #121f32; }
#wheel-canvas { display: block; width: min(100%,390px); height: auto; margin: auto; }
.showdown-spinner-name { color: var(--ui-yellow); font-size: 1.25rem; margin: 20px 0; }
.showdown-spin-info { min-height: 30px; color: var(--ui-text); font-size: 1.1rem; text-align: left; margin-bottom: 12px; }
#showdown-choice { padding-top: 12px !important; }
#showdown-my-total { display: block; margin-top: 8px; font-size: 2.8rem; font-variant-numeric: tabular-nums; color: var(--ui-yellow); }
#showdown-choice > div { display: grid; gap: 12px; }
.showdown-results-table { max-width: none; margin-top: 24px; background: var(--ui-surface); border: 1px solid var(--ui-line); border-radius: 14px; padding: 12px 20px; }
.showdown-result-row { border-color: var(--ui-line); }

/* Personal-first reveals and explicit replay choices. */
.actual-price { color: var(--ui-yellow); font-size: 3rem; text-shadow: none; font-variant-numeric: tabular-nums; }
.reveal-product-img { width: 160px; height: 160px; object-fit: contain; border-radius: 14px; background: #e8eef6; padding: 12px; }
.reveal-product-name { color: var(--ui-muted); }
.round-recap { margin: 20px 0; padding: 18px 20px; color: var(--ui-text); border: 1px solid #45678d; border-radius: 12px; background: #1b2f49; text-align: left; }
.bid-reveal-item { padding: 14px 18px; border: 1px solid var(--ui-line); border-radius: 10px; background: var(--ui-surface); transform: none; }
.bid-reveal-item.winner { background: #ffe0820c; border-color: #75613c; box-shadow: none; }
.round-winner { color: var(--ui-yellow); font-size: 1.3rem; line-height: 1.4; }
.reveal-tip, .phase-countdown, .showcase-subtitle, .showdown-subtitle { color: var(--ui-muted); }
.final-scores { max-width: 700px; margin: 24px auto; }
.final-score-item { border: 1px solid var(--ui-line); background: var(--ui-surface); border-radius: 10px; padding: 16px 20px; font-size: 1rem; gap: 14px; }
.final-score-item.you { border-left: 3px solid var(--ui-yellow); }
.final-score-item .rank-trophy { width: 1em; height: 1em; fill: #111827; vertical-align: -0.12em; }
.game-over-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.game-over-actions .muted { flex-basis: 100%; }
#game-over-heading, #game-over-summary { text-align: center; }
.amazon-verify-link { background: transparent; border-color: #465872; color: var(--ui-blue); border-radius: 8px; min-height: 44px; padding: 10px 14px; }
.product-card-enter, .showcase-card-enter, .wheel-container-enter, .final-score-item-enter { animation-duration: .25s; animation-timing-function: ease-out; }
@keyframes product-pop-in { from { opacity: .5; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Existing modal controls, now with readable surfaces and visible focus. */
.modal-overlay { padding: 16px; overflow-y: auto; }
.modal-box { background: var(--ui-surface); border: 1px solid #465872; border-radius: 18px; box-shadow: 0 20px 70px #0008; padding: 28px; width: min(100%,640px); max-height: 85vh; overflow-y: auto; }
.modal-box h2 { color: var(--ui-yellow); padding-right: 32px; margin-bottom: 20px; }
.modal-close, .modal-close-btn { min-width: 44px; min-height: 44px; border-radius: 9px; color: var(--ui-text); }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.modal-header h2 { flex: 1; min-width: 0; margin: 0; padding-right: 0; text-align: left; }
.modal-header .modal-close,
.modal-header .modal-close-btn {
  position: relative;
  inset: auto;
  display: grid;
  place-items: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  margin: -8px -8px 0 0;
  padding: 0;
  font-size: 1.75rem;
  line-height: 1;
}
.settings-modal-box { max-width: 580px; }
.settings-row { gap: 18px; border-color: var(--ui-line); padding: 14px 0; }
.settings-label-text { color: var(--ui-text); }
.settings-label-desc { font-size: .8rem; line-height: 1.5; }
.settings-host-status { color: #ffc4d3; }
.settings-body { overflow: visible; }
.settings-select { padding: 8px 10px; min-height: 44px; background: #0e1726; border-color: #53647e; }
.settings-lock-notice { color: var(--ui-muted); }
.settings-tab-bar, .host-panel-tabs { border-color: var(--ui-line); }
.tab-btn { min-height: 44px; }
.settings-tab-bar .tab-btn, .host-panel-tabs .tab-btn { color: var(--ui-muted); }
.settings-tab-bar .tab-btn.active, .host-panel-tabs .tab-btn.active { color: var(--ui-yellow); border-color: var(--ui-yellow); }
.advanced-game-settings { margin-top: 14px; border-top: 1px solid var(--ui-line); }
.advanced-game-settings > summary { color: var(--ui-yellow); }
.toggle-switch:focus-within .toggle-slider { outline: 3px solid var(--ui-yellow); outline-offset: 4px; }
.host-panel-player-list li { border-color: var(--ui-line); }
.host-room-password-hint { color: var(--ui-muted); }
.invite-url-input { display: block; width: 100%; padding: 12px; font-size: .8rem; margin-top: 18px; }
.qr-url-text { display: none; }
.invite-actions { display: flex; gap: 12px; margin-top: 16px; }
.invite-actions .btn { flex: 1; }
.inline-feedback { color: #b9f2d8; font-size: .82rem; margin-top: 10px; }
.site-footer__inner { max-width: 1140px; }

@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover, .btn-restart:hover { background: #bd2340; border-color: #bd2340; transform: none; box-shadow: none; }
  .btn-secondary:hover, .btn-how-to-play:hover, .btn-settings-gear:hover, .btn-host-crown:hover { background: #253750; color: var(--ui-text); animation: none; }
  .btn-new-game:hover, .btn-remove:hover { background: #623044; color: #ffd0dc; }
  .score-item:hover { background: #2a5c8d; }
  .score-item.active-turn:hover { background: #ffe58c; }
  .score-card-wrap:hover .score-tooltip { display: block; visibility: visible; opacity: 1; }
  .score-card-wrap.tooltip-dismissed:hover .score-tooltip { visibility: hidden; opacity: 0; }
  .amazon-verify-link:hover { background: #93c7ff14; }
}
@media (max-width: 900px) {
  #app { margin: 12px; }
  .game-header { gap: 10px; padding: 16px 20px; }
  .logo-banner-img { width: 180px; }
  .welcome-layout { gap: 28px; padding: 12px 0; }
  .screen { padding: 24px; }
  .lobby-layout { grid-template-columns: minmax(0,1fr) minmax(280px,1fr); gap: 20px; }
  .timed-play-layout { gap: 20px; grid-template-columns: minmax(0,1fr) minmax(270px,1fr); }
  .wheel-decision-layout { gap: 20px; }
}
@media (max-width: 720px) {
  .welcome-layout, .lobby-layout, .wheel-decision-layout { grid-template-columns: 1fr; }
  .screen-heading { flex-wrap: wrap; }
  .onboarding-steps { grid-template-columns: 1fr; gap: 14px; }
}
@media (max-width: 640px) {
  #app { margin: 10px; border-radius: 14px; }
  .game-header { display: grid; grid-template-columns: minmax(0,1fr) auto; padding: 14px 12px; gap: 10px; border-radius: 14px 14px 0 0; }
  .game-header-left { grid-column: 1 / 3; grid-row: 1; }
  .game-header .logo-banner-img { width: 180px; }
  .game-header .room-name-display { display: block; grid-column: 1; grid-row: 2; margin-left: 0; max-width: 100%; font-size: .75rem; }
  .game-header-right { grid-column: 2; grid-row: 2; gap: 3px; }
  .btn-how-to-play span { display: none; }
  .btn-how-to-play { width: 44px; }
  .screen { padding: 18px 12px; }
  .screen-heading h1, .game-phase > h2 { font-size: 1.75rem; }
  .welcome-copy h1 { font-size: 2.6rem; }
  .welcome-actions .inline-form { flex-wrap: wrap; }
  .welcome-actions .inline-form .btn { width: 100%; }
  .ui-panel, .player-list-container, .product-card, .center-card { padding: 20px; }
  .section-heading { gap: 10px; }
  .competition-panel { padding: 14px 10px; }
  .competition-panel h2 { font-size: .68rem; }
  .competition-panel .muted { font-size: .68rem; }
  .phase-path { gap: 3px; font-size: .7rem; }
  .phase-path span { padding: 4px 5px; }
  .timed-play-layout { grid-template-columns: 1fr; }
  .product-image-container { height: 210px; padding: 16px; }
  .product-info h3 { font-size: 1.3rem; }
  #phase-bidding, #phase-showcase-bid { padding-bottom: var(--bid-panel-height); }
  .bid-panel { position: fixed; z-index: 90; top: auto; bottom: max(10px,calc(var(--keyboard-inset,0px) + 8px),env(safe-area-inset-bottom)); left: 12px; right: 12px; max-width: 616px; margin: auto; padding: 14px 18px; border-color: #617590; border-radius: 14px; box-shadow: 0 -10px 35px #0008; max-height: calc(var(--visual-viewport-height,100svh) - 24px); overflow-y: auto; }
  .bid-panel .section-heading { margin-bottom: 10px; }
  .bid-panel h3 { font-size: 1.05rem; }
  .bid-panel .timer { font-size: 1.15rem; padding: 5px 9px; }
  .bid-form { gap: 8px; }
  .bid-input-group input { font-size: 1.5rem; padding: 8px 0 8px 8px; }
  .field-help { font-size: .72rem; }
  .locked-amount { font-size: 1.7rem; margin: 8px 0; }
  .bid-progress { margin-top: 10px; }
  .showcase-product-card { grid-template-columns: 76px minmax(0,1fr); gap: 14px; padding: 16px; }
  .showcase-product-card img { width: 76px; height: 76px; padding: 8px; }
  .showcase-product-card h4 { font-size: .96rem; }
  .showcase-product-card p { font-size: .8rem; }
  .modal-box { padding: 22px 18px; }
  .settings-row { gap: 12px; }
  .settings-label { min-width: 0; }
  .settings-volume-control { max-width: 125px; }
  .settings-row .settings-select { max-width: 110px; }
  .final-score-item { padding: 14px; flex-wrap: wrap; }
  .bid-reveal-item { padding: 12px; gap: 10px; }
  .bid-player { overflow-wrap: anywhere; }
  .reveal-product-img { width: 120px; height: 120px; }
  .actual-price { font-size: 2.6rem; }
  .game-over-actions .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
html[data-reduced-motion=true] *, html[data-reduced-motion=true] *::before, html[data-reduced-motion=true] *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
