#game{touch-action:none;cursor:grab}
#game:active{cursor:grabbing}
.top-actions{gap:6px}
.utility-icon{width:38px;height:38px;padding:8px!important;display:grid;place-items:center}
.utility-icon[hidden],.settings-install[hidden],.shortcut-suggestion[hidden]{display:none}
.utility-icon svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.map-heading{display:flex;align-items:center;justify-content:space-between;gap:14px}
.map-close{width:28px;height:28px;padding:0;border:1px solid #e4e5d153;border-radius:50%;background:#111c1d;color:#e9eddf;font-size:20px;line-height:1;cursor:pointer}
.minimap-frame{width:min(340px,32vw);max-height:calc(100dvh - 100px);overflow:hidden;transition:inset .2s,width .2s,height .2s,transform .2s}
.minimap-frame canvas{width:100%;max-height:none;aspect-ratio:10/7;object-fit:contain;cursor:zoom-in;touch-action:manipulation}
.map-legend{justify-content:flex-start;flex-wrap:wrap;column-gap:12px;row-gap:5px;font-size:8px}
.map-legend span{display:inline-flex;align-items:center;gap:4px;color:#c6d4cb!important}
.legend-icon{display:inline-grid;place-items:center;width:16px;height:16px;border:1px solid currentColor;border-radius:5px;font-style:normal;line-height:1}
.person-icon{color:#f1dfc1}.computer-icon{color:#8be8d8}.clue-icon{color:#f2d186}.shard-icon{color:#7ff3df}.lock-icon{color:#bec6c6}
.map-help{margin:7px 0 0;color:#aab7ab;font:8px var(--mono);letter-spacing:.04em}
.minimap-frame.expanded{z-index:8;inset:76px 3vw 3vh;width:auto;max-height:none;padding:clamp(12px,2vw,24px);display:flex;flex-direction:column;background:rgba(10,17,18,.97);border-color:#d8edb370;box-shadow:0 24px 90px #000c}
.minimap-frame.expanded canvas{flex:1;min-height:0;max-height:none;width:100%;height:100%;margin:10px 0 2px;aspect-ratio:auto;cursor:crosshair}
.minimap-frame.expanded .map-legend{font-size:10px}
.minimap-frame.expanded .map-help{font-size:10px}
.movement-stack{align-items:flex-end;gap:12px}
.run-button{width:50px;height:50px;display:grid;place-items:center;margin-bottom:4px;padding:10px;border:1px solid #f2c77787;border-radius:50%;background:linear-gradient(145deg,#50412b,#191b19);color:#ffdf9c;box-shadow:0 7px 22px #0008,0 0 18px #ffc85b24;touch-action:manipulation;cursor:pointer}
.run-button svg{width:27px;height:27px;fill:currentColor}
.run-button.active{background:linear-gradient(145deg,#946334,#49301d);border-color:#ffdf9c;box-shadow:0 0 25px #ffc85b68,0 7px 22px #0008}
.action-controls button{width:58px;height:58px;display:grid;place-items:center;padding:0;font-size:25px;color:#e5ffb9}
.action-controls button span{position:absolute;right:-3px;top:-3px;display:grid;place-items:center;width:20px;height:20px;margin:0;background:#162020;font-size:9px}
.camera-hint{position:absolute;z-index:2;right:30%;top:50%;transform:translateY(-50%);pointer-events:none;opacity:.2;color:#f4eedb;font:9px var(--mono);letter-spacing:.18em;text-shadow:0 2px 8px #000;transition:opacity .3s}
.game-shell:hover .camera-hint{opacity:.55}
.camera-hint-touch{display:none}
.game-shell[data-hand=left] .movement-stack{left:auto;right:max(23px,env(safe-area-inset-right));flex-direction:row-reverse}
.game-shell[data-hand=left] .action-controls{right:auto;left:max(28px,env(safe-area-inset-left))}
.game-shell[data-hand=left] .camera-hint{right:auto;left:30%}
.game-shell[data-hand=left] #game{cursor:grab}
.hand-setting{grid-column:1/-1;margin:0;padding:11px;border:1px solid rgba(229,238,219,.12);border-radius:10px;background:#101819}
.hand-setting legend{padding:0 6px;color:#d7dfd4;font-size:10px}
.hand-choice{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.hand-choice button{padding:10px;border:1px solid var(--line);border-radius:9px;background:#182221;color:#c8d0c7;font:9px var(--mono);letter-spacing:.08em;cursor:pointer}
.hand-choice button[aria-pressed=true]{border-color:#bde88a;color:#d9ffad;background:#25342b}
.settings-install{width:100%;padding:12px;border:1px solid #bde88a66;border-radius:10px;background:#d5ee9914;color:#dbf4b3;font:9px var(--mono);letter-spacing:.08em;cursor:pointer}
.shortcut-suggestion{display:block;width:100%;margin-top:12px;padding:11px 13px;border:1px solid #bde88a57;border-radius:11px;background:rgba(191,228,137,.08);color:#d4e9b4;font:9px var(--mono);letter-spacing:.08em;cursor:pointer}
.shortcut-suggestion span{float:right;color:#f2c777}
.rotate-screen.visible{z-index:20}
@media(max-width:820px){
  .utility-icon{width:32px;height:32px;padding:6px!important}
  .utility-icon svg{width:16px;height:16px}
  .map-heading{gap:8px}
  .minimap-frame{width:min(260px,31vw);right:10px;max-height:calc(100dvh - 72px)}
  .minimap-frame.expanded{inset:54px 2vw 2vh}
  .map-legend{column-gap:8px;font-size:7px}
  .legend-icon{width:14px;height:14px}
  .movement-stack{gap:7px}
  .run-button{width:42px;height:42px;padding:8px}
  .run-button svg{width:23px;height:23px}
  .camera-hint-mouse{display:none}.camera-hint-touch{display:inline}
  .game-shell[data-hand=left] .movement-stack{right:max(13px,env(safe-area-inset-right))}
  .game-shell[data-hand=left] .action-controls{left:max(17px,env(safe-area-inset-left))}
}
@media(max-width:600px) and (orientation:landscape){
  .movement-stack{left:max(9px,env(safe-area-inset-left));bottom:max(10px,env(safe-area-inset-bottom))}
  .run-button{width:39px;height:39px;margin-bottom:2px}
  .action-controls{right:max(12px,env(safe-area-inset-right));bottom:max(18px,env(safe-area-inset-bottom))}
  .action-controls button{width:46px;height:46px}
  .game-shell[data-hand=left] .movement-stack{right:max(9px,env(safe-area-inset-right))}
  .game-shell[data-hand=left] .action-controls{left:max(12px,env(safe-area-inset-left))}
}
@media(max-width:500px) and (orientation:portrait){
  .minimap-frame.expanded{inset:52px 8px 8px}
  .minimap-frame.expanded .map-legend{font-size:8px}
  .game-shell[data-hand=left] .movement-stack{right:10px}
  .game-shell[data-hand=left] .action-controls{left:12px}
}
