:root {
  --bg: #14080c;
  --ink: #fff4e0;
  --muted: #c4988a;
  --accent: #ff4d4d;
  --cyan: #ff8a1f;
  --card: rgba(28, 8, 12, 0.88);
}

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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", "Avenir Next", Futura, system-ui, sans-serif;
  user-select: none;
  touch-action: none;
}

#game {
  display: block;
  width: 100%;
  height: 100%;
  cursor: none;
}

#hud { position: fixed; inset: 0; pointer-events: none; z-index: 2; }

#hud-left {
  position: absolute;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  width: 228px;
}

#brand {
  font-weight: 800;
  letter-spacing: 0.28em;
  font-size: 13px;
  color: var(--accent);
}

#coverage {
  margin-top: 6px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  text-shadow: 0 2px 10px #000;
}

#hud-center {
  position: absolute;
  top: 16px;
  left: 16px;
  text-align: left;
}

#clock {
  font-weight: 800;
  letter-spacing: 0.12em;
  font-size: 22px;
  text-shadow: 0 2px 12px #000;
}

#toast {
  min-height: 1.2em;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-shadow: 0 2px 12px #000;
}

#board {
  margin-top: 12px;
  width: 228px;
  padding: 12px 14px 10px;
  background: var(--card);
  border: 1px solid rgba(255, 77, 77, 0.25);
  border-radius: 12px;
  backdrop-filter: blur(8px);
}

.board-title {
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 8px;
}

#board-list { list-style: none; font-size: 13px; }

#board-list li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 3px 0;
}

#board-list .team-head {
  display: block;
  margin-top: 8px;
  margin-bottom: 2px;
  padding: 4px 0 2px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

#board-list .team-head:first-child { margin-top: 0; }
#board-list .team-head.red { color: #ff6b6b; }
#board-list .team-head.blue { color: #74c0fc; }

#board-list .you { font-weight: 700; }
#board-list .dead { opacity: 0.4; text-decoration: line-through; }

.swatch {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
}

#inkbar-wrap {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  z-index: 2;
  pointer-events: none;
  width: min(460px, 78vw);
  text-align: center;
}

#hint {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-transform: uppercase;
}

#splash, #over {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  background:
    radial-gradient(800px 500px at 20% 20%, rgba(255, 77, 77, 0.22), transparent 55%),
    radial-gradient(700px 500px at 80% 80%, rgba(255, 138, 31, 0.18), transparent 50%),
    var(--bg);
}

#splash.hidden, #over.hidden { display: none; }

.splash-card {
  width: min(420px, 90vw);
  padding: 36px 32px 28px;
  background: var(--card);
  border: 1px solid rgba(255, 77, 77, 0.28);
  border-radius: 20px;
  text-align: center;
  pointer-events: auto;
}

.kicker {
  letter-spacing: 0.32em;
  font-size: 11px;
  color: var(--accent);
  margin-bottom: 10px;
}

h1 {
  font-size: 44px;
  letter-spacing: 0.12em;
  line-height: 1;
  margin-bottom: 10px;
}

.tag { color: var(--muted); margin-bottom: 22px; }

label {
  display: block;
  text-align: left;
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--muted);
  text-transform: uppercase;
}

input {
  width: 100%;
  margin: 8px 0 18px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.35);
  color: white;
  font-size: 16px;
  outline: none;
}

button {
  width: 100%;
  padding: 14px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(90deg, var(--accent), var(--cyan));
  color: #1a0808;
  font-weight: 800;
  letter-spacing: 0.22em;
  cursor: pointer;
  font-size: 15px;
}

button:hover { filter: brightness(1.08); }

.fine { margin-top: 14px; font-size: 11px; color: var(--muted); }
