/* A short turn payoff before handing the phone to the next team. */
.charades-page #ch-results{background:#f0efff;color:#17223b;border:1px solid #aaa9ca;border-radius:16px;padding:24px;max-width:760px;margin:0 auto}
.charades-page #ch-results[data-stage=match]{background:#fff2c7;border-color:#c4ae65}
.charades-page #ch-result-title{font:650 18px/1.3 'Albert Sans',sans-serif;text-align:center;margin:0 0 12px;color:#17223b}
.charades-page #ch-turn-gain{font:750 clamp(30px,5vw,52px)/1.1 'Bricolage Grotesque',sans-serif;letter-spacing:-.035em;text-align:center;margin:0 0 14px;color:#17223b}
.charades-page #ch-winner{font:750 clamp(24px,4vw,38px)/1.15 'Bricolage Grotesque',sans-serif;text-align:center;overflow-wrap:anywhere;color:#17223b;margin:12px 0}
.charades-page #ch-next-up{font:650 17px/1.4 'Albert Sans',sans-serif;text-align:center;overflow-wrap:anywhere;margin:12px 0;color:#17223b}
.charades-page #ch-reason{font-size:15px;text-align:center;line-height:1.5}
.charades-page :is(#ch-winner,#ch-reason,#ch-next-up):empty{display:none}
.charades-page .ch-result-actions{display:flex;justify-content:center;margin:16px 0 22px}
.charades-page :is(#ch-next,#ch-restart){background:#1758a6;color:#fff;border:1px solid #1758a6;min-height:52px;min-width:230px;max-width:100%;font-size:18px;white-space:normal}
.charades-page #ch-results .ch-result-board>h3{font-size:14px;text-align:center;text-transform:uppercase;letter-spacing:.08em;color:#536071;margin:14px 0 8px}
.charades-page #ch-scores{padding:0;margin:0;list-style:none;font-variant-numeric:tabular-nums;border-top:1px solid #aaa9ba}
.charades-page #ch-scores li{border-bottom:1px solid #aaa9ba;padding:10px 12px;font-size:17px;line-height:1.3;overflow-wrap:anywhere}
.charades-page #ch-word-history{margin-top:16px;border:0;border-radius:0;background:transparent}
.charades-page #ch-word-history summary{min-height:44px;padding:12px 0;font-size:14px;cursor:pointer;color:#17223b}
.charades-page #ch-word-history .grid-2{padding-top:12px}
.charades-page #ch-word-history h3{font-size:16px;color:#17223b}
.charades-page #ch-word-history ul{font-size:15px;padding-left:20px;color:#17223b}
.charades-page #ch-results :is(button,summary):focus-visible{outline:3px solid #1758a6;outline-offset:3px}
@media(max-width:600px){.charades-page #ch-results{padding:18px}.charades-page #ch-turn-gain{font-size:32px}.charades-page #ch-scores li{font-size:15px;padding:9px}.charades-page :is(#ch-next,#ch-restart){min-width:0;width:100%;font-size:17px}}
@media(max-height:450px) and (orientation:landscape){
 .charades-page #ch-results{display:grid;grid-template-columns:1fr 1fr;gap:20px;padding:14px;max-width:900px}
 .charades-page .ch-result-main,.charades-page .ch-result-board{min-width:0}
 .charades-page #ch-turn-gain{font-size:30px}
 .charades-page #ch-winner{font-size:22px}
 .charades-page #ch-results .ch-result-main>*{margin-top:4px;margin-bottom:8px}
 .charades-page #ch-results .ch-result-board>h3{margin-top:0}
 .charades-page #ch-word-history{margin-top:8px}
}
.charades-page #ch-results[data-stage=match][data-mode=charades] #ch-turn-gain{font:650 16px/1.4 'Albert Sans',sans-serif;letter-spacing:0;color:#536071}
.charades-page #ch-game:has(#ch-results:not([hidden])) #ch-rules{display:none}
.charades-page .ch-portrait-hint{padding:14px;border:2px solid var(--primary);border-radius:8px;font-weight:700;line-height:1.5}
.charades-page .charades-touch :is(#ch-correct,#ch-skip){min-height:64px;flex:1;font-size:20px;white-space:normal}
@media(max-width:600px){#ch-app .btn { min-height:44px; min-width:44px; }}
/* The 44px floor above outranks the 60px turn buttons of party-classics.css, so the turn row states its own size. */
.charades-page #ch-app .charades-actions .btn{min-height:60px}
@media(max-width:600px){
 .charades-page #ch-app #ch-correct{flex:1 1 100%;min-height:72px;font-size:1.35rem}
 .charades-page #ch-app #ch-reveal{flex:1 1 100%;min-height:72px}
}
/* Last five seconds. */
.charades-page #ch-time.charades-last{background:#b3261e;color:#fff}
@media(prefers-reduced-motion:no-preference){.charades-page #ch-time.charades-last{animation:ch-last 1s steps(2,jump-none) infinite}}
@keyframes ch-last{50%{background:#f4d34e;color:#161616}}

/* Forehead mode while the clock runs: the word is the screen, read from across the room. */
.charades-page #ch-app.charades-running{display:flex;flex-direction:column}
.charades-page #ch-app.charades-running #ch-game{flex:1;min-height:0;display:flex;flex-direction:column}
.charades-page #ch-app.charades-running #ch-live{flex:1;min-height:0;display:flex;flex-direction:column}
.charades-page #ch-app.charades-running .charades-card{flex:1;min-height:0;margin:.3rem 0;padding:8px;overflow:hidden}
.charades-page #ch-app.charades-running #ch-word{line-height:1.05;overflow-wrap:normal;word-break:normal;hyphens:none;text-wrap:balance}
.charades-page #ch-app.charades-running #ch-heading{display:none}
.charades-page #ch-app.charades-running .charades-stats{padding:0;font-size:1rem}
.charades-page #ch-app.charades-running #ch-time{font-size:2rem}
.charades-page #ch-app.charades-running :is(#ch-rules,#ch-skips,#ch-feedback,#ch-sensor,#ch-wake,#ch-screen,#ch-status,#ch-fullscreen,#ch-exit){display:none}
.charades-page #ch-app.charades-running.charades-limited #ch-skips{display:block;margin:.2rem 0 0;text-align:center}
.charades-page #ch-app.charades-running #ch-game>.charades-actions{display:none}
.charades-page #ch-app.charades-running .charades-actions{flex-wrap:nowrap;margin:.3rem 0 0}
.charades-page #ch-app.charades-running :is(#ch-correct,#ch-skip){flex:1 1 0;min-height:64px;font-size:1.25rem;overflow-wrap:normal;white-space:nowrap}
.charades-page #ch-app.charades-running #ch-correct{flex-grow:2}
.charades-page #ch-app.charades-running .ch-portrait-hint{margin:.3rem 0 0;padding:8px;font-size:.9rem;line-height:1.3}
.charades-page #ch-app.charades-running #ch-pause{flex:0 0 auto;min-height:64px}
/* Upright phone: the scoring button gets its own row, skip and pause share the next one. */
@media(max-width:600px){
 .charades-page #ch-app.charades-running .charades-actions{flex-wrap:wrap;gap:.75rem}
 .charades-page #ch-app.charades-running #ch-correct{flex:1 1 100%;min-height:72px}
 .charades-page #ch-app.charades-running:is(.charades-turn-left,.charades-turn-right) .charades-actions{flex-wrap:nowrap;gap:.6rem}
 .charades-page #ch-app.charades-running:is(.charades-turn-left,.charades-turn-right) #ch-correct{flex:2 1 0;min-height:64px}
}
/* Results: who plays next is the thing to read; a single player needs no table; moved focus needs no frame. */
.charades-page #ch-next-up{font:750 clamp(20px,5vw,26px)/1.25 'Albert Sans',sans-serif}
.charades-page #ch-game:has(#ch-results[data-stage=match]:not([hidden])) #ch-heading{display:none}
.charades-page #ch-results[data-players=one] :is(.ch-result-board>h3,#ch-scores){display:none}
.charades-page :is(#ch-heading,#ch-result-title):focus{outline:none}
/* Rotation lock keeps the page portrait while the phone lies sideways: turn the whole turn screen instead. */
.charades-page #ch-app.charades-running:is(.charades-turn-left,.charades-turn-right){inset:auto;top:50%;left:50%;width:100vh;height:100vw;width:100dvh;height:100dvw}
.charades-page #ch-app.charades-running.charades-turn-left{transform:translate(-50%,-50%) rotate(-90deg)}
.charades-page #ch-app.charades-running.charades-turn-right{transform:translate(-50%,-50%) rotate(90deg)}

@media (max-width:600px) {
  #ch-app label:has(input[type="checkbox"], input[type="radio"]) {
    display:inline-flex; align-items:center; gap:.5rem;
    min-height:44px; min-width:44px; padding:.5rem; box-sizing:border-box;
  }
}
