/* Neon Worms — shell styles. */
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  background: #0a0a18; color: #dff3ff; overflow: hidden;
  font-family: "Segoe UI", system-ui, sans-serif;
  -webkit-user-select: none; user-select: none;
  -webkit-tap-highlight-color: transparent;
}
#app { height: 100%; display: flex; flex-direction: column; }

#topbar {
  position: absolute; top: 0; left: 0; right: 0; z-index: 5;
  display: flex; gap: 6px; align-items: center; padding: 8px; pointer-events: none;
}
#topbar .chip {
  background: rgba(10,14,36,0.72); border: 1px solid rgba(0,229,255,0.3);
  border-radius: 999px; padding: 4px 10px; font-size: .78rem;
  display: flex; gap: 6px; align-items: center; min-height: 30px;
}
#topbar .lb { color: #7f93b8; font-size: .64rem; letter-spacing: .08em; }
#topbar b { color: #00e5ff; font-variant-numeric: tabular-nums; }
#muteBtn { pointer-events: auto; }

#stage { position: absolute; inset: 0; touch-action: none; }
#cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

#boardWrap {
  position: absolute; top: 52px; right: 8px; z-index: 4;
  background: rgba(10,14,36,0.66); border: 1px solid rgba(124,77,255,0.35);
  border-radius: 10px; padding: 6px 10px; min-width: 110px;
}
#boardTitle { font-size: .6rem; letter-spacing: .12em; color: #9db4d8; margin-bottom: 3px; }
#board { list-style: none; font-size: .74rem; line-height: 1.5; color: #cfe3ff; }
#board li span { color: #64789c; display: inline-block; width: 16px; }
#board li.me { color: #00e5ff; font-weight: 700; }

#boostBtn {
  position: absolute; right: 14px; bottom: 18px; z-index: 4;
  width: 68px; height: 68px; border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, rgba(0,229,255,.5), rgba(124,77,255,.35));
  border: 2px solid #00e5ff; color: #fff; font-size: 1.5rem;
  box-shadow: 0 0 24px rgba(0,229,255,.45); cursor: pointer; touch-action: none;
}
#boostBtn:active { transform: scale(.92); }

#panel {
  position: absolute; inset: 0; z-index: 6; display: flex; align-items: center; justify-content: center;
  background: rgba(6,8,24,0.7); backdrop-filter: blur(3px);
}
#panel.hide { display: none; }
#panelBox {
  text-align: center; padding: 26px 30px; border-radius: 16px; max-width: 88%;
  background: rgba(14,18,44,0.92); border: 1px solid rgba(0,229,255,0.35);
  box-shadow: 0 0 34px rgba(0,229,255,0.18), inset 0 0 22px rgba(124,77,255,0.12);
}
#panelBox h1 { font-size: 1.5rem; letter-spacing: .1em; color: #00e5ff; text-shadow: 0 0 18px rgba(0,229,255,.6); }
#panelBox h2 { font-size: 1.25rem; letter-spacing: .06em; color: #ff2d95; text-shadow: 0 0 16px rgba(255,45,149,.55); }
#panelBox .sub { color: #9db4d8; margin: 6px 0 10px; font-size: .84rem; }
#panelBox .modes { display: flex; gap: 8px; justify-content: center; margin-bottom: 12px; }
.tab {
  background: rgba(124,77,255,0.12); color: #9db4d8; border: 1px solid rgba(124,77,255,0.4);
  border-radius: 999px; padding: 8px 16px; min-height: 44px; font-weight: 700; font-size: .8rem; cursor: pointer;
}
.tab.on { background: linear-gradient(135deg, rgba(0,229,255,.25), rgba(124,77,255,.35)); color: #fff; border-color: #00e5ff; }
#panelBox .bigscore { font-size: 2.4rem; font-weight: 800; color: #ffd54a; margin: 8px 0; text-shadow: 0 0 20px rgba(255,213,74,.5); }
#panelBox .newbest { color: #ffd54a; font-weight: 700; letter-spacing: .12em; margin-bottom: 6px; animation: pulse 1.1s infinite; }
#panelBox .rows { color: #9db4d8; font-size: .86rem; margin-bottom: 12px; line-height: 1.8; }
#panelBox .rows b { color: #dff3ff; }
#panelBox .bests { color: #9db4d8; font-size: .85rem; margin-bottom: 12px; }
#panelBox .kbhint { color: #64789c; font-size: .7rem; margin-top: 12px; max-width: 300px; }
.primary {
  background: linear-gradient(135deg, #00e5ff, #7c4dff); color: #061024; font-weight: 800;
  border: 0; border-radius: 12px; padding: 12px 30px; min-height: 44px; font-size: 1rem;
  cursor: pointer; letter-spacing: .05em; box-shadow: 0 4px 18px rgba(0,229,255,.35);
}
.primary:active { transform: scale(.96); }
@keyframes pulse { 50% { opacity: .55; } }
@media (prefers-reduced-motion: reduce) { #panelBox .newbest { animation: none; } }
