* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; background: #101426;
  font-family: ui-sans-serif, system-ui, "Segoe UI", Roboto, sans-serif; color: #e8ecff; }
#game-canvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
#hud { position: fixed; top: 10px; left: 12px; right: 12px; pointer-events: none; }
.hud-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hud-chip { background: rgba(20,26,54,.8); border: 1px solid #35e0c855; border-radius: 9px;
  padding: 5px 10px; font-size: 13px; }
.hud-chip b { color: #35e0c8; }
#move-label { font-size: 13px; }
#move-label b { color: #ffd166; }
#move-bar-wrap { flex: 1; max-width: 220px; height: 8px; background: #232a52; border-radius: 4px; overflow: hidden; }
#move-bar { height: 100%; width: 100%; background: linear-gradient(90deg, #ff5d8f, #ffd166); transition: width .25s; }
#toast { position: fixed; top: 70px; left: 50%; transform: translateX(-50%);
  background: rgba(53,224,200,.15); border: 1px solid #35e0c8; color: #baf7ec;
  padding: 8px 18px; border-radius: 20px; font-size: 15px; opacity: 0; transition: opacity .3s; pointer-events: none; }
#toast.show { opacity: 1; }
.overlay { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(10,13,28,.78); backdrop-filter: blur(4px); z-index: 10; }
.overlay.hidden { display: none; }
.panel { max-width: 520px; margin: 16px; padding: 26px 30px; text-align: center;
  background: rgba(26,32,64,.92); border: 1px solid #35e0c866; border-radius: 18px;
  box-shadow: 0 0 40px #35e0c833; }
.panel h1 { font-size: 30px; color: #ffd166; letter-spacing: 1px; margin-bottom: 8px; }
.tag { color: #9fb0ff; margin-bottom: 14px; }
.how { list-style: none; text-align: left; font-size: 14px; line-height: 1.7; margin-bottom: 18px; }
.how b { color: #35e0c8; }
.dot-teal { color: #35e0c8; }
.btn-big { display: inline-block; border: none; cursor: pointer; font-size: 17px; font-weight: 700;
  color: #101426; background: linear-gradient(120deg, #35e0c8, #ffd166);
  padding: 12px 30px; border-radius: 30px; letter-spacing: .5px; }
.btn-big:hover { filter: brightness(1.15); }
#touch-controls { opacity: .55; position: fixed; bottom: 12px; left: 0; right: 0; display: flex;
  justify-content: space-between; padding: 0 16px; z-index: 5; pointer-events: none; }
.tc-left, .tc-right { display: flex; align-items: flex-end; gap: 10px; pointer-events: auto; }
.dpad { display: grid; grid-template-columns: 48px 48px 48px; grid-template-rows: 48px 48px 48px; }
.tc-up { grid-column: 2; grid-row: 1; } .tc-l { grid-column: 1; grid-row: 2; }
.tc-r { grid-column: 3; grid-row: 2; } .tc-d { grid-column: 2; grid-row: 3; }
.tc { width: 48px; height: 48px; border-radius: 12px; border: 1px solid #35e0c866;
  background: rgba(35,42,82,.75); color: #cfe8ff; font-size: 18px; cursor: pointer;
  touch-action: none; user-select: none; }
.tc:active { background: #35e0c844; }
.tc-big { width: 72px; height: 72px; font-size: 26px; border-radius: 50%;
  background: rgba(255,209,102,.22); border-color: #ffd16688; }
.tc-cam { font-size: 13px; }
@media (max-width: 600px) { .panel { padding: 20px; } .panel h1 { font-size: 24px; } }
#touch-controls:hover { opacity: 1; }
