/* styles.css
   Voidrock visual shell: black field, terminal typography, and a
   responsive letterboxed stage.  The system monospace stack keeps
   the futuristic/technical tone without external font requests. */

:root {
  --bg: #000000;
  --ink: #e8eef2;
  --dim: #8fa3b0;
  --accent: #7ef9ff;
  --gold: #ffd700;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas,
          "Liberation Mono", monospace;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  overflow: hidden;
}

.frame {
  height: 100%;
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 16px;
}

/* ---- HUD ------------------------------------------------------ */

.hud {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 18px;
  min-height: 44px;
}

.hud-block {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.hud-label {
  font-size: 11px;
  color: var(--dim);
}

.hud-value {
  font-size: 22px;
  color: var(--ink);
  text-shadow: 0 0 8px rgba(126, 249, 255, 0.35);
  font-variant-numeric: tabular-nums;
}

.hud-best {
  font-size: 11px;
  color: var(--dim);
}

.lives {
  color: var(--accent);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 20px;
}

.chip {
  font-size: 11px;
  padding: 2px 7px;
  border: 1px solid var(--gold);
  border-radius: 2px;
  color: var(--gold);
  white-space: nowrap;
}

/* ---- Stage and overlays --------------------------------------- */

.stage {
  position: relative;
  width: 100%;
  background: var(--bg);
}

canvas {
  display: block;
  width: min(100%, max(300px, calc((100vh - 120px) * 1.5)));
  height: auto;
  margin: 0 auto;
}

.overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
  background: rgba(0, 0, 0, 0.82);
}

.overlay.hidden,
.hidden {
  display: none;
}

.title {
  font-size: 52px;
  font-weight: 700;
  letter-spacing: 0.35em;
  margin-right: -0.35em; /* optically recenter tracked text */
  color: var(--ink);
  text-shadow: 0 0 18px rgba(126, 249, 255, 0.45);
}

.title.small {
  font-size: 34px;
  letter-spacing: 0.12em;
  margin-right: -0.12em;
}

.subtitle {
  font-size: 12px;
  color: var(--accent);
}

.controls-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--ink);
}

.key {
  display: inline-block;
  padding: 1px 8px;
  border: 1px solid var(--dim);
  border-radius: 3px;
  font-size: 12px;
}

.key-arrows {
  display: inline-block;
  padding: 1px 8px;
  border: 1px solid var(--dim);
  border-radius: 3px;
  font-size: 12px;
  letter-spacing: 0.15em;
}

.hint {
  font-size: 11px;
  color: var(--gold);
}

.prompt {
  font-size: 14px;
  color: var(--accent);
}

.blink {
  animation: blink 1.2s steps(2, start) infinite;
}

@keyframes blink {
  to {
    visibility: hidden;
  }
}

.final-stats {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--dim);
}

.final-stats .big {
  font-size: 30px;
  color: var(--ink);
  margin-left: 8px;
}

.new-best {
  color: var(--gold);
  font-size: 13px;
}

.footnote {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--dim);
}

/* ---- Responsive behaviour ------------------------------------- */

@media (max-width: 720px) {
  .frame {
    padding: 10px;
  }

  .hud-value {
    font-size: 17px;
  }

  .title {
    font-size: 32px;
  }
}

@media (max-height: 340px) {
  .footnote {
    display: none;
  }
}
