*{box-sizing:border-box}html{color-scheme:dark}body{margin:0;min-height:100vh;background:#201c28;color:#fcf1df;font-family:system-ui,sans-serif}nav,main{max-width:55rem;margin:auto;padding:0 1.25rem}nav{height:3.6rem;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #4a404d}nav a{color:#d9c9bc;text-decoration:none;padding:.5rem;font-size:.85rem}nav a[aria-current]{color:#ffe0a4;text-decoration:underline;text-underline-offset:5px}header{margin:1.75rem 0 1.2rem}h1,h2{font-family:Impact,'Arial Narrow',system-ui,sans-serif;font-weight:950;letter-spacing:-.045em;line-height:1.02;margin:0;color:#ffe0a4;text-shadow:2px 3px #724d51}h1{font-size:clamp(2.1rem,5.9vw,4.5rem)}p{margin:.45rem 0 0}header p{color:#dfcfc4}.cabinet{overflow:hidden;border:1px solid #66525e;border-radius:16px;box-shadow:0 15px 40px #120f194d;background:#302935}.meter,.rail{display:flex;align-items:center;gap:1rem;padding:.85rem 1.1rem}.meter label{font-size:.9rem;font-weight:600}.meter b{font-variant-numeric:tabular-nums}.meter progress{flex:1;min-width:35px;height:.55rem;appearance:none;border:none;background:#574857;color:#ffcf85;border-radius:1rem;overflow:hidden}.meter progress::-webkit-progress-bar{background:#574857}.meter progress::-webkit-progress-value{background:#ffcf85}.meter progress::-moz-progress-bar{background:#ffcf85}button{font:inherit;cursor:pointer;border:0;font-weight:750;border-radius:99px;padding:.65rem 1rem;color:#382d33;background:#ffdd9f}#sound{background:transparent;color:#efd9bd;border:1px solid #786877;font-size:.83rem;padding:.4rem .75rem}#sound[aria-pressed=false]{text-decoration:line-through}#stage{position:relative;overflow:hidden;touch-action:pan-y;user-select:none;-webkit-user-select:none;isolation:isolate}#stage.playing{touch-action:none}svg{display:block;width:100%;height:auto}.rail{justify-content:space-between}.rail p,.keyboard{font-size:.9rem;color:#dfcec7}.rail button{white-space:nowrap}.keyboard{color:#b9a9ba;margin:1rem 0 2rem}.mobile,[hidden]{display:none!important}#result{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;padding:.9rem;color:white;background:linear-gradient(transparent 49%,#251c2bec 83%);text-align:center;pointer-events:none}#result button{pointer-events:auto;margin:.55rem 0 0}h2{font-size:clamp(1.6rem,4vw,3rem)}#result.won{background:#302735ed;justify-content:center}#receipt{background:#f4e9d8;color:#352c37;min-width:12rem;max-width:85%;border:4px solid #161520;border-radius:17px;padding:.7rem .85rem;display:grid;gap:.3rem;margin-bottom:.7rem;font-size:.85rem;text-align:left;box-shadow:3px 4px #14121b}#receipt strong{text-align:center;border-bottom:1px solid #c7b9ab;padding-bottom:.3rem}#receipt span{background:#ddd5d0;padding:.35rem .55rem;border-radius:12px;justify-self:start}#receipt span:nth-child(3){justify-self:end;background:#cfdcc8}button:focus-visible,a:focus-visible,#stage:focus-visible{outline:3px solid #fff0c8;outline-offset:-3px}
@media(pointer:coarse){.mobile{display:block!important}.desktop,.keyboard{display:none}}@media(max-width:580px){main,nav{padding-inline:.65rem}header{margin:1.25rem .25rem .9rem}.meter,.rail{padding:.7rem;gap:.5rem}.rail{align-items:flex-start}.rail p{line-height:1.45}#receipt{font-size:.78rem;margin-bottom:.4rem;padding:.45rem}#result p{margin:.2rem 0}}
#scene{position:relative;width:100%;aspect-ratio:3/2;background:#3d3534;overflow:hidden}
.shot{display:block;position:absolute;inset:0;width:100%;height:100%;opacity:0;pointer-events:none;transition:opacity 85ms ease-out}
#stage[data-shot="tv"] #shot-tv{opacity:1;z-index:1}
#stage[data-shot="peek"] #shot-peek{opacity:1;z-index:1}
#stage[data-shot="warning"] #shot-warning{opacity:1;z-index:1}
#stage[data-shot="innocent"] #shot-innocent{opacity:1;z-index:1}
#stage[data-shot="busted"] #shot-busted{opacity:1;z-index:1}

#phone{position:absolute;left:63%;top:68%;width:13%;height:20%;border-radius:18%;z-index:2}
.playing #phone{cursor:crosshair}
#result{z-index:3}
@media(prefers-reduced-motion:reduce){.shot{transition:none}}

#receipt{width:min(21rem,85%)}#receipt span{max-width:90%}
#scene{aspect-ratio:766/304}
#phone{left:62%;top:77%;width:12%;height:23%}
#stage[data-shot=bold] #shot-bold,#stage[data-shot=glance] #shot-glance{opacity:1;z-index:1}
#clock{white-space:nowrap;font:700 1rem/1.2 ui-monospace,monospace;color:#ffe7b9}
#clock[data-low=true]{color:#ffb2a3}
#stage[data-phase=watch] .shot,#stage[data-phase=caught] .shot{transition:none}
@media(max-width:580px){#scene{width:142%;margin-left:-21%}.meter{flex-wrap:wrap}.meter label{font-size:.84rem}#stage:has(#result:not([hidden])){min-height:18rem}#result{pointer-events:auto}}
@media(prefers-reduced-motion:no-preference){.shot{animation:tvGlow 3.5s ease-in-out infinite alternate}@keyframes tvGlow{to{filter:brightness(1.026)}}}
