#gameRoot .room { min-height: 0; height: clamp(300px,39vh,410px); }
#gameRoot .game-card { position:relative; }
#gameRoot .target-tray { padding:10px 12px; margin-top:10px; }
#gameRoot .target-list { gap:8px; margin-top:6px; }
#gameRoot .target-entry { min-height:42px; padding:5px 9px; }
#gameRoot .target-name { font:12px system-ui,sans-serif; }
#gameRoot .target-heading { margin-bottom:5px; }
#gameRoot .game-status { margin:10px 0; }
#gameRoot .room-object:focus-visible { outline:2px solid #e9ffc1; outline-offset:3px; }
#gameRoot .room-object { cursor:url('/images/cursors/hover.cur') 11 0,url('/images/cursors/hover.png') 11 0,pointer; }
@media(max-width:600px) {
 #gameRoot .room { height:320px; }
 #gameRoot .hud { grid-template-columns:repeat(3,minmax(0,1fr)); }
 #gameRoot .target-list { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:5px; }
 #gameRoot .target-entry { padding:4px; gap:4px; }
 #gameRoot .target-name { font-size:10px; }
}

/* Exact whole-frame sprite stepping, including the final atlas frame. */
@keyframes candle-flicker { from {background-position:0 0;} to {background-position:109.0909090909091% 0;} }
@keyframes spider-twitch { from {background-position:0 0;} to {background-position:109.0909090909091% 0;} }
@keyframes ghost-drift { from {background-position:0 0;} to {background-position:114.28571428571429% 0;} }
#gameRoot .room-art, #gameRoot .room.is-warm .room-art { background-image:linear-gradient(#04111722,#05121455),url('assets/seance-relics-key-art.png'); background-size:cover; background-position:center; filter:saturate(.8) brightness(.95); opacity:1; }
#gameRoot .room.is-warm .room-art { background-position:right center; filter:saturate(.8) sepia(.15) brightness(.95); }
#gameRoot .room-sigil { display:none; }
#gameRoot .atlas-cross,#gameRoot .atlas-bone,#gameRoot .atlas-brain,#gameRoot .atlas-gear,#gameRoot .atlas-cactus { background-size:400% 450%; }
#gameRoot .atlas-cross { background-position:0 28.571429%; }
#gameRoot .atlas-bone { background-position:100% 28.571429%; }
#gameRoot .atlas-brain { background-position:33.333333% 100%; }
#gameRoot .atlas-gear { background-position:66.666667% 100%; }
#gameRoot .atlas-cactus { background-position:0 100%; }
#gameRoot .room-object { display:grid; place-items:center; }
#gameRoot .object-sprite { width:auto; max-width:100%; height:100%; aspect-ratio:1; filter:drop-shadow(0 2px 2px #000); }
#gameRoot .target-sprite { width:28px; height:28px; flex:0 0 28px; }
#gameRoot .room-object:focus-visible::after { content:attr(aria-label); position:absolute; bottom:100%; left:50%; transform:translateX(-50%); padding:4px 6px; background:#06171f; border:1px solid #9dc7bb; color:#e2fff7; font:12px system-ui,sans-serif; white-space:nowrap; pointer-events:none; }
@media(max-width:600px){
 #gameRoot .hud {grid-template-columns:repeat(6,minmax(0,1fr));}
 #gameRoot .hud-cell > span {font-size:8px;letter-spacing:0;}
 #gameRoot .hud-cell strong {font-size:17px;}
 #gameRoot .hud-time small {display:none;}
 #gameRoot .game-heading {display:flex;flex-direction:row;align-items:center;gap:8px;}
 #gameRoot .game-heading h2 {font-size:16px;}
 #gameRoot .game-heading .room-status {font-size:8px;}
 #gameRoot .room-toolbar {display:flex;flex-direction:row;align-items:center;gap:8px;margin:8px 0;padding:0;}
 #gameRoot .room-toolbar p {font-size:10px;line-height:1.35;flex:1;margin:0;}
 #gameRoot .hint-button {width:auto;min-width:100px;padding:8px;min-height:38px;font-size:10px;}
 #gameRoot .room {height:300px;}
 #gameRoot .target-heading .panel-kicker {font-size:9px;}
 #gameRoot .target-tray {padding:8px;}
 #gameRoot .target-entry {min-height:40px;}
 #gameRoot .game-status {font-size:11px;line-height:1.35;}
}
#gameRoot .room.is-warm .room-art {filter:hue-rotate(-12deg) brightness(1.08);}
#gameRoot .room-vignette {opacity:.3;}

#gameRoot .object-sprite svg,#gameRoot .target-sprite svg {display:block;width:100%;height:100%;}
#gameRoot .object-sprite {filter:drop-shadow(1px 3px 2px #0009);}
#gameRoot .room-light {opacity:.25;}
#gameRoot .room::before,#gameRoot .room::after {display:none;}
#gameRoot .object-sprite {width:100%;height:100%;min-width:0;min-height:0;aspect-ratio:auto;}
#gameRoot .object-sprite svg {width:100%;height:100%;min-width:0;min-height:0;}
#gameRoot .room-object {min-height:0;min-width:0;grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(0,1fr);}
#gameRoot .room-art,#gameRoot .room.is-warm .room-art {background-image:url('assets/table-v2.png');background-size:100% 100%;background-position:center;filter:none;}
#gameRoot .room.is-warm .room-art {filter:sepia(.1) brightness(1.06);}
#gameRoot .object-sprite {width:auto;max-width:100%;height:100%;aspect-ratio:1;min-width:0;min-height:0;}
#gameRoot .room-art,#gameRoot .room.is-warm .room-art {background-size:cover;}
