:root{
  --bg:#0b0d12;
  --card:#131826;
  --muted:#a6b0bf;
  --text:#e7eef7;
  --border:rgba(255,255,255,.10);
  --shadow: 0 16px 30px rgba(0,0,0,.35);
  --accent:#7c3aed;
  --accent2:#06b6d4;
}
*{box-sizing:border-box}
body{margin:0; min-height:100vh; background: radial-gradient(900px 520px at 20% 20%, rgba(124,58,237,.18), transparent 60%), radial-gradient(900px 520px at 80% 20%, rgba(6,182,212,.14), transparent 55%), var(--bg); color:var(--text); font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial; }
.wrap{width:min(1100px, calc(100% - 24px)); margin:0 auto; padding:16px}
.top{display:flex; justify-content:space-between; align-items:flex-end; gap:14px; flex-wrap:wrap}
h1{margin:0 0 6px 0; font-size:28px}
.muted{color:var(--muted)}
.card{margin-top:14px; background:rgba(19,24,38,.92); border:1px solid var(--border); border-radius:18px; padding:16px; box-shadow: var(--shadow)}
.hud{display:flex; gap:10px; align-items:center; flex-wrap:wrap}
.chip{background:rgba(255,255,255,.06); border:1px solid var(--border); border-radius:999px; padding:8px 10px; font-weight:800}
.btn{cursor:pointer; border:1px solid rgba(124,58,237,.35); background:rgba(124,58,237,.16); color:var(--text); border-radius:12px; padding:9px 12px; font-weight:900}
.btn:hover{filter:brightness(1.04)}
.board{
  width:min(520px, 100%);
  aspect-ratio: 1 / 1;
  margin:0 auto;
  padding:12px;
  border-radius:18px;
  background: rgba(0,0,0,.18);
  border:1px dashed rgba(255,255,255,.18);
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap:12px;
}
.tile{
  border-radius:16px;
  background:rgba(255,255,255,.07);
  border:1px solid rgba(255,255,255,.12);
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:1000;
  font-size:28px;
  user-select:none;
  cursor:pointer;
}
.tile.empty{opacity:.25; cursor:default}
.tile:hover{filter:brightness(1.05)}
.msg{min-height:24px; margin-top:12px; font-weight:1000; text-align:center}
.msg.ok{color:#34d399}
