:root { --ink:#fff7e8; --accent:#ffd27a; --teal:#2a9d8f; }
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; background: #8fd3e8;
  font-family: ui-rounded, "Segoe UI", system-ui, sans-serif; }
#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
#hud { position: fixed; inset: 0; pointer-events: none; color: var(--ink); }
#bar { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; gap: 10px;
  flex-wrap: wrap; }
.stat { background: rgba(28,32,38,0.72); border: 1px solid rgba(255,210,122,0.4);
  border-radius: 10px; padding: 6px 12px; display: flex; flex-direction: column; min-width: 64px; }
.stat .lab { font-size: 10px; letter-spacing: 0.12em; color: var(--accent); }
.stat b { font-size: 18px; }
#minimap { position: absolute; right: 10px; top: 10px; background: rgba(28,32,38,0.62);
  border-radius: 12px; border: 1px solid rgba(255,210,122,0.35); }
#countdown { position: absolute; left: 50%; top: 38%; transform: translate(-50%,-50%);
  font-size: 110px; font-weight: 800; color: #fff; text-shadow: 0 4px 26px rgba(0,0,0,0.55);
  opacity: 0; transition: opacity 0.15s; }
#countdown.show { opacity: 1; }
.overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(16,22,28,0.55); pointer-events: auto; }
.overlay.hidden { display: none; }
.card { background: linear-gradient(160deg, #23303a, #17222c); border: 1px solid rgba(255,210,122,0.35);
  border-radius: 18px; padding: 28px 32px; max-width: 460px; text-align: center;
  box-shadow: 0 18px 50px rgba(0,0,0,0.45); }
.card h1 { font-size: 34px; letter-spacing: 0.06em; color: var(--accent); }
.card .tag { color: #cfe8ef; margin: 8px 0 14px; }
.card .how { font-size: 13.5px; line-height: 1.6; color: #a8bcc4; margin-bottom: 18px; }
.card button, .overlay button { pointer-events: auto; font: inherit; font-weight: 800;
  letter-spacing: 0.08em; color: #17222c; background: var(--accent); border: 0;
  padding: 13px 26px; border-radius: 999px; cursor: pointer; }
.card button:hover { filter: brightness(1.12); }
#touch-controls { position: absolute; inset: auto 0 0 0; display: none; }
#touch-controls.visible { display: flex; justify-content: space-between; padding: 14px; }
.tc-left, .tc-right { display: flex; gap: 14px; pointer-events: auto; }
.tc { width: 74px; height: 74px; border-radius: 50%; border: 2px solid rgba(255,210,122,0.5);
  background: rgba(28,32,38,0.65); color: var(--ink); font-size: 15px; font-weight: 800;
  touch-action: none; user-select: none; -webkit-user-select: none; }
.tc.on { background: rgba(255,210,122,0.6); color: #17222c; }
.tc-gas { border-color: rgba(120,255,190,0.6); }
@media (max-width: 640px) {
  .stat { min-width: 50px; padding: 4px 8px; }
  .stat b { font-size: 14px; }
  #minimap { display: none; }
  .card { max-width: 88%; padding: 20px; }
  .card h1 { font-size: 26px; }
}
