/* The handset arena uses the viewport as its court. Camera crops remain whole. */
.mobile-camera-preview{display:none}
.throw-warning{max-width:680px;margin:18px auto 0;padding:13px 18px;border:1px solid #b7a66e;border-radius:6px;background:#eee8d8;color:#5e4e1c;font-size:13px;line-height:1.5;text-align:center}
.throw-warning.final-warning{background:#f5e6df;color:#922e1e;border-color:#d6a294}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
  body.arena-active{background:#20221e;color:#f5f3ec;overflow:hidden;overscroll-behavior:none}
  body.arena-active>.site-header,body.arena-active>.site-footer{display:none}
  body.arena-active #app{height:100dvh;min-height:100dvh}
  .arena-active .arena-page{position:relative;isolation:isolate;width:100%;height:100dvh;min-height:100dvh;max-width:none;margin:0;padding:0;overflow:hidden;background:#20221e;color:#f5f3ec}
  .arena-active .arena-heading{position:absolute;inset:calc(10px + env(safe-area-inset-top)) 16px auto;z-index:15;margin:0;min-height:44px;gap:12px}
  .arena-active .arena-heading h1{font-size:16px;letter-spacing:-.035em;font-weight:600;line-height:1.2;color:#f5f3ec}
  .arena-active .arena-heading .connection-status{display:none}
  .arena-active .arena-tools{gap:8px}
  .arena-active .arena-heading .btn,.arena-active .arena-heading .icon-btn{min-width:44px;min-height:44px;border-color:#ffffff40;background:#20221ecc;color:#f5f3ec;padding:10px;border-radius:8px;font-size:12px}
  .arena-active .arena-heading .icon{width:18px;height:18px}
  .arena-active .scorebar{position:absolute;left:16px;right:16px;top:calc(66px + env(safe-area-inset-top));z-index:12;margin:0;padding:12px 16px;border:1px solid #ffffff26;border-radius:10px;background:#20221edb;gap:16px;justify-content:space-between;backdrop-filter:blur(8px)}
  .arena-active .score-player{gap:8px;flex-direction:row!important}
  .arena-active .score-player.right{flex-direction:row-reverse!important}
  .arena-active .score-player>span{font-size:11px;color:#f5f3ec;max-width:72px}
  .arena-active .score-dots{gap:5px}
  .arena-active .score-dot{width:8px;height:8px;border-color:#ffffff70}
  .arena-active .score-dot.won{background:#f4c0ab;border-color:#f4c0ab}
  .arena-active .round-label{font-size:8px;color:#d1d3cb;letter-spacing:.08em;white-space:nowrap}
  .arena-active .arena-grid{display:block;position:static}
  .arena-active .video-card:first-child{position:absolute;inset:0;border:0;border-radius:0;background:#20221e;z-index:0}
  .arena-active .video-card:first-child .video-panel{position:absolute;inset:0;width:100%;height:100%;aspect-ratio:auto;background:#20221e}
  .arena-active .video-card:first-child .mobile-camera-preview{display:block;z-index:0;object-fit:cover;transform:scaleX(-1) scale(1.08);filter:blur(14px);opacity:.28}
  .arena-active .video-card:first-child .video-panel>canvas{width:100%;height:100%;object-fit:contain;z-index:1}
  .arena-active .video-card:first-child .video-panel:after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(180deg,#11150fd9 0%,#11150f26 24%,transparent 43%,#11150f1a 55%,#11150fe6 85%,#11150f 100%);z-index:2}
  .arena-active .video-card:first-child .video-slate{width:160px;height:180px;opacity:.5;transform:translateY(-40px)}
  .arena-active .video-card:first-child .player-bar,.arena-active .video-topline,.arena-active .versus{display:none}
  .arena-active .video-card:last-child{position:absolute;right:16px;top:calc(126px + env(safe-area-inset-top));z-index:6;width:104px;height:132px;border:1px solid #ffffff45;border-radius:10px;background:#292d26;box-shadow:0 3px 14px #0003}
  .arena-active .video-card:last-child .video-panel{position:absolute;inset:0 0 24px;width:100%;height:auto;aspect-ratio:auto;background:#292d26}
  .arena-active .video-card:last-child .video-panel>video{object-fit:contain}
  .arena-active .video-card:last-child .video-slate{width:58px;height:76px;gap:5px;color:#f4ad91}
  .arena-active .video-card:last-child .video-slate .hand-svg{min-height:40px}
  .arena-active .video-card:last-child .video-slate>span{font-size:6px;letter-spacing:.055em;max-width:90px;white-space:normal;color:#e6e5dd}
  .arena-active .video-card:last-child .player-bar{position:absolute;bottom:0;left:0;right:0;height:24px;padding:4px 8px;background:#171a15;color:#f5f3ec}
  .arena-active .video-card:last-child .player-info{width:100%;display:block;text-align:center}
  .arena-active .video-card:last-child .player-info strong{max-width:88px;font-size:9px;color:#f5f3ec}
  .arena-active .video-card:last-child .player-info small,.arena-active .video-card:last-child .avatar,.arena-active .video-card:last-child .player-rating{display:none}
  .arena-active .video-overlay{padding:9px 5px;gap:8px;background:#292d26}
  .arena-active .video-overlay>svg,.arena-active .video-overlay p{display:none}
  .arena-active .video-overlay h3{font-size:12px;line-height:1.25;color:#f5f3ec}
  .arena-active .video-overlay .btn{font-size:9px;line-height:1.2;min-height:44px;padding:7px 5px;white-space:normal;gap:4px;border-color:#ffffff50;color:#fff}
  .arena-active .video-overlay .btn .icon{width:14px;height:14px}
  .arena-active .arena-stage{position:absolute;z-index:10;left:20px;right:20px;bottom:calc(144px + env(safe-area-inset-bottom));min-height:0;padding:0;text-align:center}
  .arena-active .arena-stage .eyebrow{margin:0 0 9px;font-size:9px;color:#dedfd8}
  .arena-active .arena-stage .stage-title{font-size:clamp(25px,7.2vw,34px);min-height:0;color:#f5f3ec;text-shadow:0 2px 16px #0009;line-height:1.08}
  .arena-active .arena-stage p{max-width:360px;margin:10px auto 0;font-size:12px;line-height:1.45;color:#e4e5de;text-shadow:0 1px 7px #000}
  .arena-active .stage-action{margin-top:18px;gap:10px}
  .arena-active .stage-action .btn{min-height:50px;max-width:100%;padding:13px 22px;border-radius:8px;white-space:normal;font-size:13px}
  .arena-active #enable-game-camera{background:#f5f3ec;color:#22241f;border-color:#f5f3ec}
  .arena-active .stage-action:has(#enable-game-camera:not([hidden])) #ready-game{display:none}
  .arena-active .arena-page[data-phase=countdown] .arena-stage,.arena-active .arena-page[data-phase=reveal] .arena-stage{top:42%;bottom:auto;transform:translateY(-50%)}
  .arena-active .arena-page[data-phase=countdown] .stage-title.counting{font-size:clamp(80px,24vw,116px);font-weight:650;letter-spacing:-.06em;line-height:1.05;font-variant-numeric:tabular-nums}
  .arena-active .recognition-feedback{position:absolute;left:16px;right:16px;bottom:calc(72px + env(safe-area-inset-bottom));z-index:10;display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:14px;padding:13px 15px;min-height:50px;margin:0;border:1px solid #ffffff29;border-radius:10px;background:#20221edb;color:#f5f3ec;backdrop-filter:blur(8px);text-align:left}
  .arena-active .recognition-feedback>strong{font-size:18px;line-height:1.2;color:#f4c0ab;letter-spacing:-.02em}
  .arena-active .recognition-feedback>span{font-size:10px;line-height:1.4;color:#e0e2d9;max-width:48%;text-align:right}
  .arena-active .throw-warning{position:absolute;left:16px;right:16px;top:calc(120px + env(safe-area-inset-top));z-index:14;margin:0;max-width:calc(100% - 152px);padding:10px 12px;background:#382f13ef;color:#ffe7a3;border:1px solid #b69a4d;border-radius:8px;font-size:11px;line-height:1.5;text-align:left}
  .arena-active .throw-warning.final-warning{background:#481e16f2;color:#ffe1d8;border-color:#cf7660}
  .arena-active .round-history,.arena-active .arena-note{display:none}
  .arena-active .arena-bottom{position:absolute;left:16px;right:16px;bottom:calc(12px + env(safe-area-inset-bottom));z-index:14;margin:0;padding:0;border:0;display:flex;justify-content:flex-end;gap:8px;min-height:44px}
  .arena-active .arena-help{display:none}
  .arena-active .arena-bottom .text-link{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:8px 12px;border:1px solid #ffffff38;border-radius:8px;background:#20221ecc;color:#e9eae3;font-size:11px;text-align:center}
  .arena-active .arena-bottom .arena-tools{margin:0;gap:8px}
  .arena-active .dialog{color:var(--text);max-height:calc(100dvh - 24px)}
  .arena-active #toasts{bottom:calc(14px + env(safe-area-inset-bottom));color:var(--text)}
}
@media(max-width:359px){
  .arena-active .arena-heading{left:12px;right:12px}.arena-active .arena-heading h1{font-size:14px}
  .arena-active .scorebar{left:12px;right:12px;padding:11px 10px;gap:8px}.arena-active .score-player{gap:6px}.arena-active .score-player>span{max-width:55px;font-size:10px}.arena-active .round-label{font-size:7px;letter-spacing:0}
  .arena-active .video-card:last-child{right:12px;width:88px;height:113px}.arena-active .video-card:last-child .player-info strong{max-width:70px}
  .arena-active .throw-warning{left:12px;max-width:calc(100% - 126px);font-size:10px;padding:9px}
}
@media(max-height:650px) and (max-width:620px){
  .arena-active .arena-stage{bottom:calc(132px + env(safe-area-inset-bottom));left:16px;right:16px}
  .arena-active .arena-stage p{font-size:11px;margin-top:7px}
  .arena-active .stage-action{margin-top:12px}.arena-active .stage-action .btn{min-height:46px}
  .arena-active .arena-stage .eyebrow{font-size:8px;margin-bottom:6px}
}
@media(orientation:landscape) and (max-height:500px){
  .arena-active .arena-heading{left:calc(16px + env(safe-area-inset-left));right:calc(16px + env(safe-area-inset-right));top:8px}
  .arena-active .arena-heading h1{max-width:170px;font-size:15px}
  .arena-active .scorebar{top:12px;left:26%;right:26%;padding:10px 12px;gap:10px}
  .arena-active .score-player{gap:6px}.arena-active .score-player>span{max-width:60px}.arena-active .round-label{font-size:7px}
  .arena-active .video-card:last-child{right:calc(16px + env(safe-area-inset-right));top:67px;width:88px;height:112px}
  .arena-active .arena-stage{left:24%;right:24%;bottom:90px}
  .arena-active .arena-stage .eyebrow{font-size:8px;margin-bottom:5px}.arena-active .arena-stage .stage-title{font-size:26px}
  .arena-active .arena-stage p{font-size:10px;margin-top:7px}.arena-active .stage-action{margin-top:10px}.arena-active .stage-action .btn{min-height:44px;padding:9px 16px;font-size:11px}
  .arena-active .arena-page[data-phase=countdown] .arena-stage,.arena-active .arena-page[data-phase=reveal] .arena-stage{top:42%;bottom:auto}
  .arena-active .arena-page[data-phase=countdown] .stage-title.counting{font-size:72px}
  .arena-active .recognition-feedback{left:26%;right:26%;bottom:16px;min-height:44px;padding:10px 13px}.arena-active .recognition-feedback>strong{font-size:15px}.arena-active .recognition-feedback>span{font-size:9px}
  .arena-active .throw-warning{left:calc(16px + env(safe-area-inset-left));right:auto;top:70px;width:21%;max-width:180px;padding:9px;font-size:10px}
  .arena-active .arena-bottom{left:auto;right:calc(16px + env(safe-area-inset-right));bottom:12px;max-width:24%}.arena-active .arena-bottom .arena-tools{flex-wrap:wrap;justify-content:flex-end;gap:5px}.arena-active .arena-bottom .text-link{font-size:9px;padding:8px}
}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
  .arena-active .arena-stage{padding:15px 12px;border-radius:12px;background:#151b13bd;border:1px solid #ffffff1a}
  .arena-active .arena-page[data-phase=countdown] .arena-stage{padding:0;background:none;border:0}
  .arena-active .arena-page[data-phase=countdown] .stage-title.counting{-webkit-text-stroke:1px #111b10a6;text-shadow:0 3px 10px #000c}
  .arena-active .arena-page[data-phase=countdown] .arena-stage>.eyebrow{display:inline-flex;padding:5px 9px;border-radius:5px;background:#151b13d9}
  .arena-active .arena-page[data-phase=countdown] .arena-stage>p{width:fit-content;padding:6px 10px;border-radius:5px;background:#151b13d9}
}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
  .arena-active .arena-stage>.eyebrow,.arena-active .arena-page[data-phase=countdown] .arena-stage>.eyebrow{display:none}
}
/* Voice is separate from camera preview and sound effects. */
.arena-bottom{flex-wrap:wrap}.voice-controls{display:flex;align-items:center;gap:8px;margin-right:auto}
.voice-button{min-width:44px;min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:8px;border:1px solid var(--line);background:transparent;border-radius:6px;padding:10px 12px;font:inherit;font-size:11px;color:var(--text);cursor:pointer}
.voice-button[aria-pressed=true]{color:var(--lime);border-color:var(--lime);background:#bf3a2408}.voice-button:disabled{opacity:.45;cursor:default}.voice-button .icon{width:18px;height:18px}.voice-status{font-size:10px;color:var(--muted);max-width:150px}
.arena-help{flex-basis:100%;margin-bottom:8px}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
 .arena-active .arena-bottom{flex-wrap:nowrap;align-items:center;gap:8px;justify-content:space-between}
 .arena-active .voice-controls{gap:8px;margin-right:auto}.arena-active .voice-status,.arena-active .voice-button>span,.arena-active #report-player>span,.arena-active #hide-video>span{display:none}
 .arena-active .voice-button{width:44px;height:44px;padding:10px;background:#20221ecc;border-color:#ffffff50;color:#f5f3ec;border-radius:8px}
 .arena-active .voice-button[aria-pressed=true]{border-color:#f4c0ab;color:#f4c0ab;background:#3e2921ef}
 .arena-active #report-player,.arena-active #hide-video{min-width:44px;padding:10px}
 .arena-active #report-player>.icon,.arena-active #hide-video>.icon{width:18px;height:18px}
 .arena-active .voice-button:disabled{opacity:.6}
}
@media(orientation:landscape) and (max-height:500px){
 .arena-active .arena-bottom{left:calc(16px + env(safe-area-inset-left));right:calc(16px + env(safe-area-inset-right));max-width:none;pointer-events:none}
 .arena-active .arena-bottom>*{pointer-events:auto}.arena-active .arena-bottom .arena-tools{margin-left:auto;flex-wrap:nowrap}
 .arena-active .voice-controls{flex-wrap:wrap;max-width:23%}
}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
 .arena-active .voice-controls{position:relative}
 .arena-active .voice-controls[data-state=unavailable] .voice-status,.arena-active .voice-controls[data-state=connecting] .voice-status{display:block;position:absolute;bottom:48px;left:0;width:118px;font-size:9px;color:#e0e2d9;line-height:1.2;text-shadow:0 1px 4px #000}
}
@media(max-width:620px),(max-width:950px) and (max-height:500px){
 .arena-active #toasts{bottom:calc(68px + env(safe-area-inset-bottom))}
}
@media(orientation:landscape) and (max-height:500px){
 .arena-active #toasts{left:calc(16px + env(safe-area-inset-left));right:auto;width:22%;max-width:190px;bottom:68px}
 .arena-active #toasts .toast{font-size:11px;line-height:1.45;padding:12px 10px;gap:7px}
 .arena-active #toasts .toast>.icon{display:none}
}
.arena-stage .stage-title{overflow-wrap:anywhere}
