:root{color-scheme:dark;--ink:#f0f1f3;--muted:#95999e;--signal:#f0f1f3;font-family:Menlo,Consolas,"Liberation Mono",monospace;background:#08090b;color:var(--ink)}
*{box-sizing:border-box}body{margin:0}button,a,input{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{font:inherit;color:inherit;cursor:pointer}button:disabled{cursor:wait;opacity:.55}button:focus-visible,a:focus-visible,input:focus-visible{outline:2px solid var(--signal);outline-offset:5px}button{border:1px solid #72767c;background:#101216;padding:11px 15px;font-size:11px;letter-spacing:.06em}button:hover{background:#24272b;border-color:#fff}a{color:inherit;text-decoration:none}a:hover{text-decoration:underline}[hidden]{display:none!important}
#review{width:100%;height:100svh;min-height:560px;overflow:hidden;position:relative;isolation:isolate;background:radial-gradient(ellipse at 50% 38%,#171c22 0%,#0b0e12 37%,#050608 80%)}
#review[data-state=hired]{--signal:#50ff18}#review[data-state=fired]{--signal:#ff2444}
#camera,.screen-shade,#hud,.scanlines{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}#camera{object-fit:cover;transform:scaleX(-1);opacity:0;transition:opacity .35s}#review.live #camera{opacity:1}#camera.unmirrored{transform:none}.screen-shade{background:linear-gradient(180deg,#0003,transparent 35%,#0002 55%,#0008);z-index:1}.screen-shade::after{content:"";position:absolute;inset:0;background:var(--signal);opacity:0;mix-blend-mode:color;transition:opacity .4s}#review[data-state=hired]:not(.no-tint) .screen-shade::after,#review[data-state=fired]:not(.no-tint) .screen-shade::after{opacity:.22}#hud{z-index:2;filter:drop-shadow(0 0 3px color-mix(in srgb,var(--signal) 40%,transparent))}.scanlines{z-index:3;background:repeating-linear-gradient(transparent 0 3px,#000 3px 4px);opacity:.09}
.welcome{position:absolute;z-index:4;top:32%;left:50%;transform:translateX(-50%);width:min(92%,570px);text-align:center}.eyebrow{font-size:10px;letter-spacing:.23em;color:var(--muted);margin:0 0 18px}h1{font-size:clamp(32px,4.2vw,64px);font-weight:400;line-height:1;letter-spacing:-.07em;margin:0}h1 span{font-size:.28em;letter-spacing:0;vertical-align:middle;color:var(--muted);margin:0 .15em}.intro{font-size:15px;margin:16px 0 12px}.instructions{font-size:12px;line-height:1.7;color:var(--muted);margin:0 0 23px}.primary{background:var(--ink);color:#111;border:1px solid var(--ink);padding:14px 24px;min-width:220px;font-weight:bold;letter-spacing:.09em}.primary:hover{background:#fff;color:#000}.primary span{margin-left:30px}.text-button{display:block;margin:10px auto 0;border-color:transparent;background:transparent;color:#b8bcc2;padding:9px;font-size:10px}.text-button:hover{background:transparent;color:white;border-color:transparent;text-decoration:underline}.privacy{font-size:9px;color:#757d87;margin-top:19px}
.controls{position:absolute;z-index:5;left:3.3%;right:3.3%;bottom:max(20px,env(safe-area-inset-bottom));display:flex;align-items:center;gap:24px;color:#9ba1a8;font-size:10px;letter-spacing:.04em}.control-actions{display:flex;gap:7px;margin-left:auto}.controls button{font-size:10px;padding:8px 10px;background:#080a0dbb;border-color:#3a3e44}.controls button:hover{color:white;border-color:#90969f}.home-link{white-space:nowrap}#source-label{font-size:9px}.tracking-message{position:absolute;z-index:4;top:32%;left:50%;transform:translateX(-50%);font-size:11px;text-align:center;letter-spacing:.09em;padding:10px 16px;background:#07090bb8;max-width:88%;line-height:1.6}.result-actions{position:absolute;z-index:4;top:85%;left:50%;transform:translateX(-50%);text-align:center;color:var(--signal);white-space:nowrap}.result-actions p{font-size:10px;letter-spacing:.09em;margin:0 0 10px}.result-actions button{border-color:var(--signal);background:#080a0dbb;font-size:10px;padding:8px 14px}.demo-controls{position:absolute;z-index:5;top:24px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:8px;white-space:nowrap;font-size:9px;color:#adb3bb}.demo-controls button{font-size:9px;padding:8px 10px;border-color:#484d55;background:#080a0dbb}.demo-controls button[aria-pressed=true]{background:#ebedf0;color:#111;border-color:#ebedf0}.error{position:absolute;z-index:6;top:22px;left:50%;transform:translateX(-50%);border:1px solid #aa7777;background:#241819;padding:15px 20px;font-size:12px;line-height:1.5;max-width:560px;width:90%;text-align:center}
dialog{max-width:480px;width:calc(100% - 32px);max-height:90svh;overflow:auto;border:1px solid #b6bdc6;background:#0d1014;color:var(--ink);padding:25px;box-shadow:0 0 40px #000}dialog::backdrop{background:#000b;backdrop-filter:blur(4px)}dialog header{display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #424952;padding-bottom:15px;margin-bottom:25px}dialog h2{font-size:15px;font-weight:400;margin:0}dialog header button{border:0;font-size:24px;padding:0 5px;background:none}dialog label{font-size:11px;display:block;line-height:1.5}dialog output{float:right;color:#aeb5c0}dialog input[type=range]{width:100%;margin:20px 0 0;accent-color:#eceff3}dialog p{font-size:11px;line-height:1.7;color:#9ca4af}dialog .check{display:flex;gap:12px;align-items:center;margin:20px 0}dialog input[type=checkbox]{accent-color:#f1f3f5;width:16px;height:16px}dialog h3{font-size:11px;font-weight:400}.how-it-works{border-top:1px solid #424952;margin-top:25px;padding-top:12px}dialog .primary{width:100%;margin-top:14px}.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}
@media(max-width:600px) and (orientation:portrait){#review{min-height:720px}.welcome{top:27%}.eyebrow{font-size:8px;letter-spacing:.13em;margin-bottom:15px}h1{font-size:40px}.intro{font-size:13px}.instructions{font-size:11px;margin-bottom:17px}.privacy{font-size:8px}.controls{gap:8px;flex-wrap:wrap;bottom:14px;font-size:9px}.control-actions{gap:4px}.controls button{font-size:9px;padding:8px}.controls #fullscreen span{display:none}#source-label{position:absolute;bottom:38px;font-size:8px}.result-actions{top:56%}.result-actions p{font-size:9px}.tracking-message{top:24%;font-size:10px}.demo-controls{top:20px;gap:4px}.demo-controls>span{display:none}.error{top:12px}}
@media(max-height:650px) and (min-width:601px){#review{min-height:420px}.welcome{top:26%}.eyebrow{margin-bottom:10px}h1{font-size:38px}.intro{margin:10px 0}.instructions{margin-bottom:10px;font-size:10px}.primary{padding:10px 20px}.privacy{margin-top:7px}.text-button{margin-top:4px;padding:5px}.result-actions{top:84%}.result-actions p{display:none}.controls{bottom:12px}.demo-controls{top:10px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition:none!important}.scanlines{display:none}}
@media(max-height:500px) and (min-width:601px){#review{min-height:390px}.welcome{top:25%}.welcome .eyebrow,.welcome .instructions{display:none}.welcome h1{font-size:30px}.welcome .intro{font-size:12px;margin:9px 0 14px}.welcome .primary{min-width:180px;padding:10px 16px}.welcome .text-button{display:inline-block;margin:0 0 0 12px;padding:10px 5px}.welcome .privacy{font-size:8px;margin:10px 0 0}.result-actions{top:84%}}
.tracking-message{top:22%}
.ready-overlay{position:absolute;inset:0;z-index:4;pointer-events:none;color:#eff5fa;text-align:center}.body-guide{position:absolute;top:26%;left:50%;transform:translateX(-50%);width:min(64vw,360px);height:36%;stroke:currentColor;stroke-width:1.5;filter:drop-shadow(0 0 6px #e0efff55);opacity:.55}.guide-center{stroke-dasharray:3 9;opacity:.35}.guide-joints{fill:#e8f2ff;stroke-width:0}.ready-copy{position:absolute;top:58%;left:50%;transform:translateX(-50%);width:min(94%,550px);text-shadow:0 1px 5px #000,0 1px 10px #000}.ready-copy p{margin:0}.ready-copy #ready-title{font-size:15px;letter-spacing:.14em}.ready-copy #ready-hint{font-size:10px;line-height:1.6;margin-top:9px}.counting .body-guide{opacity:.12}.counting .ready-copy,.crowd-ready .ready-copy{top:33%}.ready-copy strong{display:block;font-size:100px;line-height:1.2;font-weight:400}.crowd-ready .body-guide{display:none}@media(max-height:500px){.body-guide{width:200px;top:24%;height:33%}.ready-copy{top:57%}.ready-copy #ready-title{font-size:11px}.ready-copy #ready-hint{font-size:9px;margin-top:4px}.ready-copy strong{font-size:58px}.counting .ready-copy,.crowd-ready .ready-copy{top:28%}}@media(prefers-reduced-motion:reduce){.body-guide{filter:none}}

/* Match the welcome wordmarks to the same pixel glyphs used by the verdict HUD. */
.review-title{display:flex;align-items:center;justify-content:center;gap:16px;width:100%;margin:0 auto;letter-spacing:0}
.review-title img{display:block;width:calc((100% - 66px)/2);max-width:220px;height:auto;filter:drop-shadow(0 0 5px #edf0f520)}
.review-title .title-divider{flex:0 0 34px;margin:0;padding:7px 0;border-top:1px solid #697079;border-bottom:1px solid #697079;font:10px/1 Menlo,Consolas,monospace;letter-spacing:.12em;color:#a6adb5}
.welcome .intro{font-size:13px;letter-spacing:0;line-height:1.6;margin-top:22px}
.welcome .instructions{font-size:11px;line-height:1.8}
.welcome .primary{font-weight:500;letter-spacing:.12em}
.controls{font-family:Menlo,Consolas,"Liberation Mono",monospace;letter-spacing:.06em}
@media(max-width:600px) and (orientation:portrait){
 .review-title{gap:10px}.review-title img{width:calc((100% - 48px)/2)}
 .review-title .title-divider{flex-basis:28px;font-size:9px;padding:6px 0}
 .welcome .intro{font-size:12px;margin-top:18px}.welcome .instructions{font-size:10px}
}
@media(max-height:650px) and (min-width:601px){.review-title img{max-width:165px}.welcome .intro{margin-top:12px;font-size:12px}}

/* One instruction and one action before the live framing guide. */
.welcome{top:35%}
.welcome .instructions{margin:24px 0 26px;font-size:15px;color:#adb3bb}
@media(max-width:600px) and (orientation:portrait){.welcome{top:32%}.welcome .instructions{font-size:13px;margin:22px 0 24px}}
@media(max-height:650px) and (min-width:601px){.welcome{top:32%}.welcome .instructions{display:block;margin:16px 0 18px;font-size:13px}}

#start{display:inline-flex;align-items:center;justify-content:center;gap:14px;min-height:50px;padding:15px 24px}
#start .camera-button-icon{width:22px;height:22px;flex:none}
#start .camera-button-label{display:block;width:auto;height:14px}
#start .sr-only{margin:0}
@media(max-width:600px){#start{gap:12px;padding:14px 20px}#start .camera-button-label{height:12px}#start .camera-button-icon{width:20px;height:20px}}

/* Keep the whole game and touch controls inside a phone's visible viewport. */
@media(max-width:600px) and (orientation:portrait){
 #review{min-height:0}
 .controls{display:grid;grid-template-columns:1fr auto;gap:7px;bottom:max(10px,env(safe-area-inset-bottom))}
 .controls #source-label{position:static;text-align:right;align-self:center}
 .control-actions{grid-column:1/-1;margin:0;justify-content:space-between}
 .controls button{min-height:44px;min-width:44px;padding:8px}
 dialog header button{min-width:44px;min-height:44px}
 #song-picker{max-height:calc(100svh - 32px)}
}
@media(max-height:500px) and (orientation:landscape){
 #review{min-height:0}
 .controls button{min-height:40px}
}
@media(max-height:500px) and (orientation:landscape){
 .welcome{top:30%}
 .welcome .instructions{margin:10px 0 14px}
}
@media(max-width:700px) and (max-height:500px) and (orientation:landscape){
 .review-title img{max-width:110px}
 .welcome .instructions{font-size:10px}
 #start{min-height:44px;padding:10px 20px}
}

/* Music browser: cover strip, track list, and selected sleeve. */
#song-picker{--edge:#ffffff24;width:min(1040px,calc(100% - 48px));max-width:none;height:min(760px,calc(100svh - 64px));max-height:none;padding:28px;background:radial-gradient(ellipse at 95% 0,#25313970,transparent 60%),#0b1015;border:1px solid #69767e;overflow:hidden;box-shadow:0 30px 100px #000b}
#song-picker[open]{display:flex;flex-direction:column;gap:20px}
#song-picker::backdrop{background:#020509df;backdrop-filter:blur(12px)}
#song-picker .picker-header{flex:none;display:grid;grid-template-columns:44px 1fr auto;gap:18px;align-items:center;padding:0 0 18px;margin:0;border-bottom:1px solid var(--edge)}
#song-picker h2{font-size:18px;letter-spacing:.13em}
.picker-index{font-size:10px;letter-spacing:.12em;color:#8e9ca6}
#song-picker .picker-back,.rail-arrow{display:grid;place-items:center;width:44px;height:44px;padding:10px;border:1px solid var(--edge);background:#ffffff06}
.picker-back svg,.rail-arrow svg,#start-game svg{width:22px;height:22px;stroke:currentColor;stroke-width:1.5}
.collection-bar{display:flex;gap:20px;flex:none;overflow-x:auto;scrollbar-width:thin}.collection-bar button{white-space:nowrap}
.collection-bar button{font-size:11px;letter-spacing:.1em;padding:0 0 9px;background:none;border:0;border-bottom:2px solid transparent;color:#83919d;min-height:30px}
.collection-bar button[aria-pressed=true]{color:#fff;border-bottom-color:#fff}
.cover-carousel{display:flex;gap:12px;align-items:center;min-width:0;flex:none}
.rail-arrow{flex:none;width:30px;padding:3px;border:0;color:#aab5bf}
#cover-rail{display:flex;gap:12px;overflow-x:auto;min-width:0;scrollbar-width:thin;scrollbar-color:#667781 transparent;padding:4px 3px 12px;scroll-snap-type:x proximity;overscroll-behavior-x:contain}
.cover-tile{position:relative;flex:0 0 112px;width:112px;height:112px;padding:0;border:1px solid #ffffff30;background:#253139;text-align:left;scroll-snap-align:start;transition:transform .18s,border-color .18s}
.tile-art,.song-thumb{display:block;position:relative;overflow:hidden;background:#28323b}
.tile-art{position:absolute;inset:0}
.tile-art img,.song-thumb img,.selected-art>img{width:100%;height:100%;object-fit:cover;transform:scale(1.34)}
.tile-art::after{content:"";position:absolute;inset:0;background:linear-gradient(transparent 25%,#03080bd9)}
.tile-title{position:absolute;bottom:9px;left:9px;right:7px;font-size:10px;letter-spacing:0;line-height:1.3;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;color:#fff;text-shadow:0 1px 4px #000}
.tile-number{position:absolute;top:7px;left:8px;font-size:9px;color:white;text-shadow:0 1px 5px #000}
.cover-tile:hover{transform:translateY(-2px);border-color:#fff}
.cover-tile[aria-pressed=true]{outline:1px solid white;outline-offset:2px;border-color:white;box-shadow:0 0 16px #ffffff20}
.cover-tile[aria-pressed=true]::after{content:"";position:absolute;top:8px;right:8px;width:6px;height:6px;background:white;box-shadow:0 0 8px #fff}
.song-browser{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:30px;flex:1;min-height:0}
.track-panel{display:flex;flex-direction:column;min-height:0;min-width:0}
.track-panel-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px 14px;background:linear-gradient(90deg,#ffffff16,#ffffff03);border-left:2px solid white;flex:none}
#song-picker .track-panel-heading h3{margin:0;font-size:12px;letter-spacing:.05em}
#collection-count{font-size:9px;color:#93a0aa;white-space:nowrap}
#song-list{border:0;padding:8px 6px 0 0;margin:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#657580 transparent;min-height:0;flex:1}
.song-row{position:relative;display:flex;align-items:center;gap:12px;min-height:64px;padding:8px 12px;border-bottom:1px solid #ffffff0c;cursor:pointer;border-left:2px solid transparent}
.song-row:hover{background:#ffffff08}
.song-row:has(input:checked){background:linear-gradient(90deg,#e9f2ff21,#ffffff07);border-left-color:#fff}
.song-row:has(input:focus-visible){outline:1px solid white;outline-offset:-2px}
.song-row input{position:absolute;opacity:0;width:1px;height:1px;margin:0}
.song-thumb{width:42px;height:42px;flex:none}
.song-title{flex:1;font-size:12px;line-height:1.35;overflow-wrap:anywhere}
.song-title small{display:block;color:#8b99a5;font-size:10px;margin-top:5px}
.song-duration{font-size:11px;color:#a8b4be;flex:none}
.song-preview{display:grid;grid-template-rows:minmax(0,1fr) auto auto;min-width:0;min-height:0}
.selected-art{position:relative;aspect-ratio:1;height:100%;width:auto;max-width:100%;justify-self:center;min-height:0;overflow:hidden;border:1px solid #ffffff24;background:#26323c}
.selected-art::after{content:"";position:absolute;inset:0;pointer-events:none;box-shadow:inset 0 0 35px #0003}
.selected-art>img{position:absolute;inset:0}
.art-cross{position:absolute;z-index:1;color:#fff;font-size:17px;font-weight:200;text-shadow:0 0 5px black}
.art-cross-top{top:9px;left:12px}.art-cross-bottom{bottom:9px;right:12px}
.selected-info{padding:15px 0 0;flex:none}
#selected-collection{font-size:9px;color:#91a0ac;letter-spacing:.14em}
#song-picker #selected-title{font-size:clamp(15px,1.9vw,23px);line-height:1.25;margin:7px 0;letter-spacing:-.02em;font-weight:500;overflow-wrap:anywhere}
#song-picker .selected-info p{display:flex;justify-content:space-between;font-size:10px;letter-spacing:.08em;margin:0;color:#a9b4bf}
#start-game{display:flex;align-items:center;justify-content:space-between;gap:16px;width:100%;min-width:0;margin:18px 0 0;min-height:50px;padding:14px 18px;flex:none}
#start-game>img{height:14px;width:auto;max-width:calc(100% - 35px)}
#start-game .sr-only{margin:0}
@media(max-width:600px){
 #song-picker{width:calc(100% - 20px);height:calc(100svh - 24px);max-height:none;padding:16px}
 #song-picker[open]{gap:12px}
 #song-picker .picker-header{gap:12px;padding-bottom:10px;grid-template-columns:36px 1fr auto}
 #song-picker .picker-back{width:36px;height:36px;min-width:36px;min-height:36px;padding:8px}
 #song-picker h2{font-size:12px;letter-spacing:.08em}.picker-index{font-size:8px}
 .collection-bar{gap:18px}.collection-bar button{font-size:10px;min-height:32px}
 .cover-carousel{gap:0}.rail-arrow{display:none}
 #cover-rail{gap:10px;padding-bottom:10px}.cover-tile{flex-basis:88px;width:88px;height:88px}.tile-title{font-size:9px}
 .song-browser{display:flex;flex-direction:column;gap:12px}
 .track-panel{flex:1}.track-panel-heading{padding:9px 10px}#song-picker .track-panel-heading h3{font-size:10px}#collection-count{font-size:8px}
 .song-row{min-height:58px;padding:7px;gap:10px}.song-title{font-size:11px}.song-title small{font-size:9px;margin-top:3px}.song-thumb{width:36px;height:36px}
 .song-preview{flex:none;display:grid;grid-template-columns:60px 1fr;gap:0 12px;border-top:1px solid var(--edge);padding-top:12px}
 .selected-art{height:60px;min-height:60px;width:60px;grid-row:1}.art-cross{display:none}
 .selected-info{padding:0;align-self:center;min-width:0}#selected-collection{font-size:8px}
 #song-picker #selected-title{font-size:13px;margin:4px 0;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
 #song-picker .selected-info p{font-size:8px}#start-game{grid-column:1/-1;margin-top:12px;min-height:46px}
}
@media(max-height:540px) and (orientation:landscape){
 #song-picker{height:calc(100svh - 20px);width:calc(100% - 32px);padding:14px 20px}
 #song-picker[open]{gap:8px}#song-picker .picker-header{padding-bottom:8px;grid-template-columns:32px 1fr auto}#song-picker .picker-back{width:32px;height:32px;padding:6px}#song-picker h2{font-size:13px}
 .collection-bar{position:absolute;right:100px;top:20px}.collection-bar button{font-size:9px;min-height:24px}
 .cover-tile{width:68px;height:68px;flex-basis:68px}.tile-title{font-size:8px;bottom:5px;left:5px}.tile-number{font-size:7px;top:5px;left:5px}#cover-rail{padding-bottom:7px}
 .song-browser{display:grid;gap:20px}.track-panel-heading{padding:8px 12px}.song-row{min-height:52px;padding:5px 10px}.song-thumb{width:34px;height:34px}
 .song-preview{border:0;padding:0;display:grid;grid-template-columns:minmax(70px,1fr) 1.2fr;grid-template-rows:1fr auto;gap:10px 16px}.selected-art{height:100%;width:100%;grid-row:1;aspect-ratio:auto}.selected-info{padding:0;align-self:center}#song-picker #selected-title{font-size:15px}#start-game{grid-column:1/-1;margin:0;min-height:42px;padding:10px 15px}
}

.preview-control{position:absolute;z-index:2;right:10px;top:10px;display:grid;place-items:center;width:36px;height:36px;min-width:36px;padding:8px;border:1px solid #ffffff70;background:#070c12c9;color:white;backdrop-filter:blur(8px)}
.preview-control svg{width:20px;height:20px;fill:currentColor}
.preview-control:hover{background:#101923;border-color:white}
@media(max-width:600px){.preview-control{inset:0;width:100%;height:100%;background:#02060940;border:0;backdrop-filter:none}.preview-control svg{width:24px;height:24px}}

/* Touch targets and safe-area clearance for phone song browsing. */
@media(max-width:600px){
 #song-picker{height:calc(100svh - max(12px,env(safe-area-inset-top)) - max(12px,env(safe-area-inset-bottom)))}
 #song-picker .picker-back{width:44px;height:44px;min-width:44px;min-height:44px}
 #song-picker .picker-header{grid-template-columns:44px 1fr auto;gap:8px}
 .collection-bar button{min-height:44px}
}
@media(orientation:landscape) and (max-height:540px){
 #song-picker .picker-back{width:44px;height:44px;min-width:44px;min-height:44px}
 #song-picker .picker-header{grid-template-columns:44px 1fr auto}
 .collection-bar{top:14px}.collection-bar button{min-height:44px}
 .preview-control{width:44px;height:44px;min-width:44px;right:5px;top:5px}
}
@media(orientation:landscape) and (max-width:600px){
 #song-picker{height:calc(100svh - 20px);padding:10px 14px}
 #song-picker h2{font-size:10px;letter-spacing:0}
 .collection-bar{top:10px;right:74px;gap:12px}.collection-bar button{font-size:8px}
 .cover-tile{width:56px;height:56px;flex-basis:56px}.tile-title{font-size:7px}
 #cover-rail{padding-bottom:6px}.song-browser{gap:12px;grid-template-columns:1.15fr 1fr}
 .track-panel-heading{padding:5px 7px}.song-row{gap:7px;min-height:48px;padding:5px}
 .song-title{font-size:10px}.song-duration{font-size:9px}
 .song-preview{grid-template-columns:50px 1fr;gap:8px}.selected-art{min-height:0;width:100%;height:100%}
 #song-picker #selected-title{font-size:11px}#selected-collection{font-size:7px}
 .preview-control{inset:0;width:100%;height:100%}#start-game{min-height:44px}
}

@media(max-width:600px) and (max-height:650px) and (orientation:portrait){
 #song-picker{padding:12px}#song-picker[open]{gap:8px}
 #song-picker .picker-header{padding-bottom:8px}
 .cover-tile{width:68px;height:68px;flex-basis:68px}.tile-title{font-size:8px;left:5px;bottom:5px}
 #cover-rail{padding-bottom:8px}
 .song-preview{grid-template-columns:48px 1fr;padding-top:8px;gap:0 10px}
 .selected-art{width:48px;height:48px;min-height:48px}
 .song-row{min-height:54px}#start-game{margin-top:8px;min-height:44px}
}

/* Small white portrait projection on the opening screen. */
.portrait-hologram{position:absolute;bottom:calc(100% + 22px);left:50%;transform:translateX(-50%);width:156px;height:176px;opacity:0;transition:opacity .5s;pointer-events:none;color:#eef7ff}
.portrait-hologram.ready{opacity:1}
#portrait-scan{position:absolute;left:14%;top:4%;width:72%;height:90%;filter:drop-shadow(0 0 5px #eff8ff3b)}
.portrait-reticle{position:absolute;inset:0;width:100%;height:100%;stroke:currentColor;stroke-width:.7;opacity:.5}
.portrait-orbit,.portrait-orbit-inner{position:absolute;inset:7% 0;border:1px solid #e6f5ff25;border-radius:50%;transform:rotate(-18deg);box-shadow:0 0 20px #d4edff08}
.portrait-orbit::after{content:"";position:absolute;inset:-1px;border:1px solid transparent;border-top-color:#e8f5ff90;border-bottom-color:#e8f5ff55;border-radius:50%;animation:portrait-orbit 16s linear infinite}
.portrait-orbit-inner{inset:12% -7%;border-style:dashed;opacity:.32;transform:rotate(18deg)}
@keyframes portrait-orbit{to{transform:rotate(360deg)}}
.welcome{top:40%}
@media(max-width:600px) and (orientation:portrait){.welcome{top:39%}.portrait-hologram{width:124px;height:140px;bottom:calc(100% + 16px)}.welcome .instructions{margin:16px 0 18px}}
@media(max-height:650px) and (min-width:601px){.portrait-hologram{width:110px;height:124px;bottom:calc(100% + 14px)}}
@media(max-height:650px) and (orientation:portrait){.portrait-hologram{width:98px;height:110px;bottom:calc(100% + 12px)}.welcome{top:38%}.welcome .instructions{font-size:12px;margin:12px 0 14px}}
@media(max-height:500px) and (orientation:landscape){.welcome{top:30%}.portrait-hologram{left:5%;bottom:auto;top:6px;transform:translateX(-100%);width:80px;height:92px}.welcome{width:min(66%,450px)}}
@media(prefers-reduced-motion:reduce){.portrait-orbit::after{animation:none}.portrait-hologram{transition:none}}

/* Full-body dancing projection, in the same compact opening-screen slot. */
.portrait-hologram{width:180px;height:224px;bottom:calc(100% + 12px)}
#portrait-scan{inset:0;width:100%;height:100%;filter:drop-shadow(0 0 3px #eff8ff25)}
.portrait-orbit{inset:9% 4%;opacity:.6}.portrait-orbit-inner{inset:13% -3%;opacity:.2}.portrait-reticle{opacity:.35}
@media(max-width:600px) and (orientation:portrait){.portrait-hologram{width:142px;height:180px;bottom:calc(100% + 10px)}}
@media(max-height:650px) and (min-width:601px){.portrait-hologram{width:126px;height:158px;bottom:calc(100% + 10px)}}
@media(max-height:650px) and (orientation:portrait){.portrait-hologram{width:118px;height:148px;bottom:calc(100% + 8px)}}
@media(max-height:500px) and (orientation:landscape){.portrait-hologram{width:90px;height:114px;top:3px;bottom:auto}}

.selected-info .preview-error{display:block;font-size:12px;color:#d6dce2;margin:8px 0 0;letter-spacing:0}
.selected-info .preview-error[hidden]{display:none}

/* Canvas corner markers respect notches in portrait and landscape. */
#hud{--hud-safe-bottom:env(safe-area-inset-bottom,0px);--hud-safe-top:env(safe-area-inset-top,0px);--hud-safe-left:env(safe-area-inset-left,0px);--hud-safe-right:env(safe-area-inset-right,0px)}

/* Three direct controls fit on a phone; utilities live in the menu. */
#game-menu{max-width:360px}
#game-menu header{margin-bottom:18px}
.menu-actions{display:grid;gap:10px}
.menu-actions button{min-height:46px;width:100%;margin:0;font-size:12px}
@media(max-width:600px) and (orientation:portrait){
 .control-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}
 .control-actions:has(#choose-song[hidden]){grid-template-columns:repeat(2,minmax(0,1fr))}
 .controls button{min-width:0;padding:8px 4px;font-size:9px;line-height:1.35}
}

/* Countdown stays over the live camera; the canvas version is included in clips. */
.big-countdown .ready-copy,.big-countdown .body-guide,.big-countdown .holo-guide{visibility:hidden}
.big-countdown #ready-overlay svg{visibility:hidden}
.result-buttons{display:flex;justify-content:center;gap:8px}
.result-buttons button{min-height:44px}
#clip-dialog{width:min(92vw,680px);max-height:94svh;padding:20px;overflow:auto}
#clip-dialog header{margin-bottom:14px}
#clip-video{display:block;width:100%;max-height:65svh;object-fit:contain;background:#000}
.clip-actions{display:flex;gap:10px;margin-top:16px}
.clip-actions button{flex:1;min-width:0;min-height:48px;margin:0;font-size:13px}
#clip-status{font-size:12px;margin:8px 0 0;color:var(--muted)}
#clip-status:empty{display:none}
.clip-note{font-size:10px;color:var(--muted);margin:10px 0 0;grid-column:1/-1}
@media(max-width:600px){#clip-dialog{padding:14px}.result-buttons{gap:6px}.result-buttons button{font-size:10px;padding:8px 12px}.clip-note{font-size:9px}}

/* Keep the camera controls clean; tracking remains available to screen readers. */
#source-label{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
/* Alignment is only needed before the music starts. */
.ready-overlay.counting svg{visibility:hidden}
