:root {
  --bg: #0b0f1f;
  --bg2: #141a33;
  --panel: rgba(255, 255, 255, 0.06);
  --panel-strong: rgba(255, 255, 255, 0.12);
  --text: #f4f6ff;
  --muted: #9aa3c7;
  --accent: #ffcc33;
  --good: #35d07f;
  --bad: #ff5c7a;
  --opt0: #ff4d6d; /* triangle */
  --opt1: #3d8bff; /* diamond */
  --opt2: #ffb703; /* circle */
  --opt3: #2ec27e; /* square */
  --team0: #ff4d6d;
  --team1: #3d8bff;
  --team2: #2ec27e;
  --team3: #ffb703;
  --radius: 18px;
  --font: "Nunito", "Segoe UI", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: var(--font);
  background: radial-gradient(1200px 800px at 20% -10%, #27306b 0%, var(--bg) 55%),
              radial-gradient(900px 700px at 110% 110%, #3b1f5e 0%, transparent 60%), var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { margin: 0; font-weight: 900; letter-spacing: -0.01em; }
button { font-family: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); }

.btn {
  border: 0; border-radius: 999px; cursor: pointer; font-weight: 900;
  padding: 14px 28px; font-size: 18px; color: #1a1400; background: var(--accent);
  box-shadow: 0 6px 0 #b8901a, 0 10px 24px rgba(0,0,0,.35);
  transition: transform .08s ease, box-shadow .08s ease, filter .15s;
}
.btn:active { transform: translateY(4px); box-shadow: 0 2px 0 #b8901a, 0 6px 16px rgba(0,0,0,.35); }
.btn:disabled { filter: grayscale(.6) brightness(.7); cursor: not-allowed; }
.btn.secondary { background: var(--panel-strong); color: var(--text); box-shadow: none; }
.btn.danger { background: var(--bad); color: white; box-shadow: 0 6px 0 #a3213b; }

.panel { background: var(--panel); border: 1px solid rgba(255,255,255,.08); border-radius: var(--radius); padding: 20px; backdrop-filter: blur(8px); }

.shape { display: inline-block; width: 1em; height: 1em; vertical-align: -0.1em; }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%);
  background: #1b2143; color: var(--text); padding: 12px 20px; border-radius: 12px;
  border: 1px solid rgba(255,255,255,.15); box-shadow: 0 10px 30px rgba(0,0,0,.5);
  z-index: 100; opacity: 0; transition: opacity .2s; pointer-events: none; max-width: 90vw; text-align: center;
}
.toast.show { opacity: 1; }

.conn { position: fixed; top: 10px; right: 12px; font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; z-index: 50; }
.conn::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--bad); }
.conn.ok::before { background: var(--good); }

@keyframes pop { 0% { transform: scale(.6); opacity: 0; } 70% { transform: scale(1.08); } 100% { transform: scale(1); opacity: 1; } }
@keyframes rise { from { transform: translateY(16px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.04); } }
.pop { animation: pop .35s cubic-bezier(.2,.9,.3,1.3) both; }
.rise { animation: rise .4s ease both; }
