#game { max-width:560px; margin:0 auto; -webkit-user-select:none; user-select:none; -webkit-touch-callout:none; }
#game .hud { display:flex; justify-content:space-between; align-items:center; gap:8px; margin-bottom:8px; font-size:14px; flex-wrap:wrap; }
#game .hud b { color:var(--accent); }
#game .hud button { min-height:34px; padding:4px 10px; font-size:12px; }
#game .stage { box-sizing:content-box; position:relative; margin:0 auto; border:2px solid var(--line); border-radius:6px; overflow:hidden; background:var(--bg); }
#game canvas { display:block; touch-action:none; }
#game .overlay { position:absolute; left:0; top:0; right:0; bottom:0; display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; padding:16px; background:rgba(11,13,16,.9); }
#game .overlay.off { display:none; }
#game .overlay h2 { margin:0 0 8px; font-size:22px; letter-spacing:1px; color:var(--text); text-transform:none; }
#game .overlay p { margin:0 0 16px; color:var(--dim); font-size:13px; max-width:300px; }
#game .overlay button { min-width:160px; }
#game .pad { display:flex; justify-content:space-between; align-items:flex-end; margin-top:14px; gap:10px; }
#game .pad.center { justify-content:center; }
#game .dpad button, #game .fire button { width:68px; height:68px; padding:0; font-size:26px; border-radius:14px; }
#game .dr { display:flex; justify-content:center; gap:6px; margin-bottom:6px; }
#game .dr i { display:block; width:68px; }
#game .fire button { width:128px; height:84px; font-size:20px; font-weight:700; letter-spacing:1px; }
#game button:active { border-color:var(--accent); background:#1b2128; }
#game .keys { text-align:center; color:var(--dim); font-size:12px; margin-top:12px; }
.games-list { display:block; }
html.eink #game .overlay { background:#fff; }
html.eink #game .stage { border-width:3px; }
html.eink #game button:active { background:#000 !important; color:#fff !important; }
@media (max-width:640px) { #game .keys { display:none; } }
@media (pointer:coarse) { #game .keys { display:none; } }
@media (max-width:420px) {
  #game .dpad button { width:56px; height:56px; font-size:22px; }
  #game .dr i { width:56px; }
  #game .fire button { width:104px; height:72px; font-size:17px; }
}
