/* ══════════════════════════════════════════════
   QABash Arena — Scoped to .ar-root
   Brand: GitHub UI · VS Code · Linear · Stripe
   ══════════════════════════════════════════════ */

.ar-root *, .ar-root *::before, .ar-root *::after {
  box-sizing: border-box; margin: 0; padding: 0;
}

.ar-root {
  --ink:      #09090B;
  --volt:     #1DB954;
  --volt-dim: #17a349;
  --zinc-3:   #d4d4d8;
  --zinc-4:   #a1a1aa;
  --zinc-5:   #71717A;
  --zinc-7:   #3f3f46;
  --border:   #d0d7de;
  --border-l: #e5e7eb;
  --bg:       #ffffff;
  --bg-s:     #f6f8fa;
  --bg-m:     #f0f2f5;
  --blue:     #0969da;
  --red:      #cf222e;
  --red-bg:   #fff0f0;
  --red-b:    #ffcdd2;
  --green:    #1a7f37;
  --green-bg: #dafbe1;
  --green-b:  #a7f3d0;
  --orange:   #bc4c00;
  --sh1: 0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.04);
  --sh2: 0 4px 14px rgba(0,0,0,.09), 0 2px 4px rgba(0,0,0,.05);
  --sh3: 0 8px 28px rgba(0,0,0,.11), 0 2px 8px rgba(0,0,0,.06);
  --r:    6px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'Fira Code', monospace;

  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  display: block;
}

.ar-root a { color: var(--ink); text-decoration: none; }
.ar-root a:hover { color: var(--volt); }

/* ════════════════════════════
   AUTH MODAL
   ════════════════════════════ */
.ar-modal-bg {
  position: fixed; inset: 0;
  background: rgba(255,255,255,.96);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; padding: 16px;
  backdrop-filter: blur(4px);
}
.ar-modal-bg.hidden { display: none; }

.ar-modal {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 10px; box-shadow: var(--sh3);
  padding: 32px 28px 26px;
  width: 100%; max-width: 420px;
  animation: ar-in .25s ease both;
}
.ar-modal-tag {
  font-family: var(--mono); font-size: 10px; color: var(--zinc-5);
  letter-spacing: .06em; margin-bottom: 10px;
}
.ar-modal-title  { font-size: 22px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); margin-bottom: 6px; }
.ar-modal-sub    { font-size: 13px; color: var(--zinc-5); line-height: 1.6; margin-bottom: 22px; }
.ar-modal-tags   { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 24px; }
.ar-modal-tag2   { font-family: var(--mono); font-size: 10px; color: var(--zinc-5); background: var(--bg-m); border: 1px solid var(--border-l); border-radius: 4px; padding: 3px 8px; }

.ar-modal-actions { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }

.ar-modal-btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%; padding: 11px;
  border-radius: var(--r);
  font-family: var(--font); font-size: 14px; font-weight: 600;
  cursor: pointer; transition: background .15s, transform .1s, border-color .15s;
  border: 1px solid transparent; text-decoration: none !important;
}
.ar-modal-btn--primary { background: var(--volt); color: #fff; border-color: var(--volt); }
.ar-modal-btn--primary:hover { background: var(--volt-dim); transform: translateY(-1px); color: #fff; }
.ar-modal-btn--ghost   { background: var(--bg); color: var(--zinc-5); border-color: var(--border); }
.ar-modal-btn--ghost:hover { background: var(--bg-s); border-color: #c6cdd5; color: var(--ink); }

.ar-modal-note { font-family: var(--mono); font-size: 10px; color: var(--zinc-4); text-align: center; }

/* ════════════════════════════
   HEADER
   ════════════════════════════ */
.ar-header {
  background: var(--bg); border-bottom: 1px solid var(--border);
  animation: ar-in .35s ease .04s both;
}
.ar-hi { max-width: 1040px; margin: 0 auto; padding: 24px 28px 0; width: 100%; }

.ar-crumb {
  font-family: var(--mono); font-size: 11px; color: var(--zinc-5);
  letter-spacing: .04em; margin-bottom: 18px;
  display: flex; align-items: center; gap: 6px;
}
.ar-crumb-sep { color: var(--zinc-3); }
.ar-crumb a { color: var(--zinc-5); }
.ar-crumb a:hover { color: var(--volt); }

.ar-header-row {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 24px;
  flex-wrap: wrap; margin-bottom: 28px;
}
.ar-header-left { flex: 1; min-width: 0; }
.ar-header-right {
  display: flex; flex-direction: column; gap: 10px;
  align-items: flex-end; flex-shrink: 0; min-width: 0;
}

/* Eyebrow badges */
.ar-eyebrow { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.ar-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--bg-s); border: 1px solid var(--border);
  border-radius: 20px; padding: 3px 10px 3px 7px;
  font-family: var(--mono); font-size: 10px; color: var(--zinc-5); white-space: nowrap;
}
.ar-badge-dot { width: 5px; height: 5px; background: var(--volt); border-radius: 50%; flex-shrink: 0; animation: ar-blink 1.8s ease infinite; }
@keyframes ar-blink { 0%,100%{opacity:1} 50%{opacity:.25} }
.ar-badge.live { background: var(--green-bg); border-color: var(--green-b); color: var(--green); }

.ar-title {
  font-size: clamp(26px, 4vw, 40px); font-weight: 700;
  letter-spacing: -.025em; line-height: 1.1; color: var(--ink);
  margin-bottom: 8px;
}
.ar-title-acc { color: var(--volt); }
.ar-sub { font-size: 14px; color: var(--zinc-5); line-height: 1.65; max-width: 500px; }

/* Player chip */
.ar-player-chip {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg-s); border: 1px solid var(--border);
  border-radius: var(--r); padding: 8px 14px;
  box-shadow: var(--sh1);
}
.ar-player-chip--guest { opacity: .8; }

.ar-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--volt); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 11px; font-weight: 700; color: #fff;
  overflow: hidden;
}
.ar-avatar--img img { width: 32px; height: 32px; border-radius: 50%; display: block; }

.ar-chip-info { display: flex; flex-direction: column; gap: 1px; }
.ar-chip-name { font-size: 13px; font-weight: 600; color: var(--ink); }
.ar-chip-meta { display: flex; align-items: center; gap: 5px; }
.ar-chip-score { font-family: var(--mono); font-size: 11px; color: var(--volt); font-weight: 600; }
.ar-chip-sep   { color: var(--zinc-4); font-size: 10px; }
.ar-chip-chips { font-family: var(--mono); font-size: 11px; color: var(--zinc-5); }

.ar-rank-pill {
  padding: 2px 8px; border-radius: 4px;
  font-family: var(--mono); font-size: 9px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em;
  border: 1px solid; flex-shrink: 0;
}
.ar-rank-pill--newcomer    { background:#f4f4f5; color:#71717a; border-color:#d4d4d8; }
.ar-rank-pill--contributor { background:#f0fdf4; color:#16a34a; border-color:#bbf7d0; }
.ar-rank-pill--member      { background:#eff6ff; color:#1d4ed8; border-color:#bfdbfe; }
.ar-rank-pill--senior      { background:#fdf4ff; color:#7e22ce; border-color:#e9d5ff; }
.ar-rank-pill--expert      { background:#fff7ed; color:#c2410c; border-color:#fed7aa; }
.ar-rank-pill--champion    { background:#fffae6; color:#a16207; border-color:#fde68a; }
.ar-rank-pill--legend      { background:#09090b; color:#1db954; border-color:#1db954; }

/* Stats row */
.ar-stats {
  display: grid; grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 1px; background: var(--border);
  border: 1px solid var(--border); border-radius: var(--r);
  overflow: hidden; box-shadow: var(--sh1);
}
.ar-stat {
  background: var(--bg); padding: 10px 14px; min-width: 0;
  transition: background .15s;
}
.ar-stat:hover { background: var(--bg-s); }
.ar-stat-n { font-family: var(--mono); font-size: 17px; font-weight: 700; color: var(--ink); display: block; }
.ar-stat-n.v { color: var(--volt); }
.ar-stat-l { font-size: 10px; color: var(--zinc-5); display: block; margin-top: 1px; }

/* Buttons */
.ar-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 14px; border-radius: var(--r);
  font-family: var(--font); font-size: 12px; font-weight: 600;
  cursor: pointer; border: 1px solid transparent;
  transition: all .15s; text-decoration: none !important;
}
.ar-btn--volt { background: var(--volt); color: #fff; }
.ar-btn--volt:hover { background: var(--volt-dim); color: #fff; }

/* Tabs */
.ar-tabs {
  display: flex; overflow-x: auto; scrollbar-width: none;
  margin-top: 8px;
}
.ar-tabs::-webkit-scrollbar { display: none; }
.ar-tab {
  padding: 8px 14px; font-size: 13px; font-weight: 500; color: var(--zinc-5);
  border-bottom: 2px solid transparent; white-space: nowrap; flex-shrink: 0;
  cursor: pointer; background: none;
  border-top: none; border-left: none; border-right: none;
  font-family: var(--font); transition: color .15s, border-color .15s;
}
.ar-tab:hover { color: var(--ink); }
.ar-tab.act   { color: var(--ink); border-bottom-color: var(--ink); }
.ar-tab-badge {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--volt); color: #fff;
  font-family: var(--mono); font-size: 8px; font-weight: 600;
  border-radius: 3px; padding: 1px 5px; margin-left: 5px; vertical-align: middle;
}

/* ════════════════════════════
   BODY + LAYOUT
   ════════════════════════════ */
.ar-body { max-width: 1040px; margin: 0 auto; padding: 28px 28px 64px; width: 100%; animation: ar-in .35s ease .12s both; }

.ar-layout {
  display: grid;
  grid-template-columns: minmax(0,1fr) 272px;
  gap: 16px; align-items: start;
}

/* ════════════════════════════
   GAME ARENA
   ════════════════════════════ */
.ar-arena {
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--bg); box-shadow: var(--sh1);
  overflow: hidden; display: flex; flex-direction: column;
  min-height: 500px;
}
.ar-arena-bar {
  background: var(--bg-s); border-bottom: 1px solid var(--border);
  padding: 0; display: flex; align-items: center;
  justify-content: space-between; flex-shrink: 0;
}
.ar-bar-dots { display: flex; align-items: center; gap: 6px; padding: 10px 14px; }
.ar-dot { width: 10px; height: 10px; border-radius: 50%; }
.ar-dot-r { background: #ff5f57; } .ar-dot-y { background: #febc2e; } .ar-dot-g { background: #28c840; }
.ar-bar-label { font-family: var(--mono); font-size: 11px; color: var(--zinc-5); flex: 1; text-align: center; }
.ar-bar-scores { display: flex; align-items: center; gap: 14px; padding: 10px 14px; }
.ar-sc { font-family: var(--mono); font-size: 11px; color: var(--zinc-5); display: flex; align-items: center; gap: 4px; }
.ar-sc span { color: var(--ink); font-weight: 700; }
.ar-sc.hi span { color: var(--volt); }

.ar-game-wrap { flex: 1; position: relative; display: flex; flex-direction: column; min-width: 0; }

.ar-game-panel { flex: 1; display: none; flex-direction: column; position: relative; }
.ar-game-panel.ar-active { display: flex; }

/* Overlay */
.ar-overlay {
  position: absolute; inset: 0;
  background: rgba(255,255,255,.97);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 12px; z-index: 20; padding: 28px; text-align: center;
}
.ar-overlay.hidden { display: none; }
.ar-ov-icon  { font-size: 38px; line-height: 1; }
.ar-ov-title { font-size: 22px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); }
.ar-ov-title .acc { color: var(--volt); }
.ar-ov-score { font-family: var(--mono); font-size: 34px; font-weight: 700; color: var(--volt); }
.ar-ov-sub   { font-size: 13px; color: var(--zinc-5); max-width: 320px; line-height: 1.6; }
.ar-ov-stat-row { display: flex; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; width: 100%; max-width: 280px; }
.ar-ov-stat { background: var(--bg-s); padding: 10px 12px; flex: 1; text-align: center; }
.ar-ov-stat-n { font-family: var(--mono); font-size: 15px; font-weight: 700; color: var(--ink); }
.ar-ov-stat-l { font-size: 10px; color: var(--zinc-5); }
.ar-ov-btns  { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.ar-ov-btn {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 9px 18px; border-radius: var(--r);
  font-size: 13px; font-weight: 600; cursor: pointer;
  font-family: var(--font); transition: all .15s; white-space: nowrap;
  border: none; text-decoration: none !important;
}
.ar-ov-btn:hover { transform: translateY(-1px); }
.ar-ov-btn.primary { background: var(--volt); color: #fff; }
.ar-ov-btn.primary:hover { background: var(--volt-dim); }
.ar-ov-btn.ghost   { background: var(--bg); color: var(--zinc-5); border: 1px solid var(--border); }
.ar-ov-btn.ghost:hover { border-color: #c6cdd5; color: var(--ink); box-shadow: var(--sh1); }

/* Chips awarded banner */
.ar-ov-chips {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--green-bg); border: 1px solid var(--green-b);
  border-radius: 20px; padding: 4px 12px;
  font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--green);
}

/* ════════════════════════════
   GAME: BUG SQUASH
   ════════════════════════════ */
.ar-bugsquash {
  flex: 1; position: relative; overflow: hidden;
  cursor: crosshair; min-height: 420px; background: var(--bg);
  background-image: linear-gradient(var(--border-l) 1px, transparent 1px), linear-gradient(90deg, var(--border-l) 1px, transparent 1px);
  background-size: 24px 24px; user-select: none;
}
.ar-bug { position: absolute; cursor: pointer; line-height: 1; user-select: none; touch-action: none; transition: transform .06s; }
.ar-bug.squashed { animation: ar-squash .22s ease forwards; pointer-events: none; }
@keyframes ar-squash { 0%{transform:scale(1.4) rotate(0deg);opacity:1} 55%{transform:scale(.12) rotate(90deg)} 100%{transform:scale(0);opacity:0} }
.ar-hit-fx { position: absolute; font-family: var(--mono); font-size: 11px; font-weight: 700; pointer-events: none; animation: ar-hitfx .55s ease forwards; z-index: 10; }
@keyframes ar-hitfx { 0%{opacity:1;transform:translateY(0)} 100%{opacity:0;transform:translateY(-32px)} }
.ar-bs-lives { position: absolute; top: 10px; left: 12px; font-size: 13px; z-index: 5; display: flex; gap: 3px; }
.ar-bs-floor { position: absolute; bottom: 0; left: 0; right: 0; height: 2px; background: var(--red); opacity: .2; }
.ar-combo-pop {
  position: absolute; pointer-events: none; z-index: 15;
  font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--volt);
  white-space: nowrap; background: var(--green-bg); border: 1px solid var(--green-b);
  border-radius: 4px; padding: 2px 8px; animation: ar-combo .5s ease forwards;
}
@keyframes ar-combo { 0%{opacity:0;transform:scale(.7) translateY(0)} 25%{opacity:1;transform:scale(1.05)} 100%{opacity:0;transform:scale(.95) translateY(-22px)} }

/* ════════════════════════════
   GAME: TYPE RACER
   ════════════════════════════ */
.ar-typeracer {
  flex: 1; padding: 24px 20px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 18px; background: var(--bg); min-height: 420px;
}
.ar-tr-cat { font-family: var(--mono); font-size: 10px; color: var(--zinc-5); letter-spacing: .08em; text-transform: uppercase; background: var(--bg-m); border: 1px solid var(--border-l); border-radius: 4px; padding: 3px 10px; }
.ar-tr-word { font-family: var(--mono); font-size: clamp(20px, 4vw, 38px); font-weight: 600; letter-spacing: .04em; text-align: center; min-height: 48px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; }
.ar-trc { display: inline; }
.ar-trc.ok  { color: var(--volt); }
.ar-trc.bad { color: var(--red); text-decoration: underline; }
.ar-trc.cur { color: var(--ink); border-bottom: 2px solid var(--volt); }
.ar-ring-wrap { position: relative; width: 70px; height: 70px; flex-shrink: 0; }
.ar-ring-bg  { fill: none; stroke: var(--border-l); stroke-width: 4; }
.ar-ring-bar { fill: none; stroke: var(--volt); stroke-width: 4; stroke-linecap: round; transform: rotate(-90deg); transform-origin: center; transition: stroke-dashoffset .1s linear, stroke .3s; }
.ar-ring-n   { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--mono); font-size: 16px; font-weight: 700; color: var(--ink); }
.ar-tr-input {
  width: 100%; max-width: 380px;
  background: var(--bg-s); border: 1px solid var(--border);
  border-radius: var(--r); padding: 11px 16px;
  font-family: var(--mono); font-size: 16px; color: var(--ink);
  outline: none; text-align: center; caret-color: var(--volt);
  letter-spacing: .06em; transition: border-color .15s, background .15s;
}
.ar-tr-input:focus { border-color: var(--volt); }
.ar-tr-input.ok  { border-color: var(--volt); background: var(--green-bg); }
.ar-tr-input.bad { border-color: var(--red);  background: var(--red-bg);  }
.ar-tr-streak { font-family: var(--mono); font-size: 11px; color: var(--zinc-5); }
.ar-tr-streak strong { color: var(--orange); }
.ar-tr-hint   { font-family: var(--mono); font-size: 10px; color: var(--zinc-4); }

/* ════════════════════════════
   GAME: ASSERT MATCH
   ════════════════════════════ */
.ar-assertmatch {
  flex: 1; padding: 16px;
  display: flex; flex-direction: column; gap: 12px;
  background: var(--bg); min-height: 420px;
}
.ar-am-info { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.ar-am-instr { font-family: var(--mono); font-size: 10px; color: var(--zinc-5); }
.ar-am-meta  { display: flex; gap: 14px; }
.ar-am-m  { font-family: var(--mono); font-size: 11px; color: var(--zinc-5); }
.ar-am-m span { color: var(--ink); font-weight: 700; }
.ar-am-m.bad span { color: var(--red); }
.ar-am-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 8px; flex: 1; }
.ar-am-card {
  background: var(--bg-s); border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 7px; cursor: pointer;
  text-align: center; transition: all .17s;
  display: flex; align-items: center; justify-content: center;
  min-height: 58px; user-select: none; min-width: 0;
}
.ar-am-card:hover:not(.ar-flipped):not(.ar-matched) { border-color: #c6cdd5; transform: translateY(-1px); box-shadow: var(--sh2); }
.ar-am-card.ar-flipped { border-color: var(--blue); background: #f0f6ff; }
.ar-am-card.ar-matched { border-color: var(--volt); background: var(--green-bg); pointer-events: none; }
.ar-am-card.ar-wrong   { border-color: var(--red);  background: var(--red-bg); animation: ar-shake .32s ease; }
@keyframes ar-shake { 0%,100%{transform:translateX(0)} 25%,75%{transform:translateX(-3px)} 50%{transform:translateX(3px)} }
.ar-am-back  { font-size: 18px; display: block; }
.ar-am-front { font-family: var(--mono); font-size: 10px; color: var(--ink); line-height: 1.35; display: none; }
.ar-am-card.ar-flipped .ar-am-back, .ar-am-card.ar-matched .ar-am-back   { display: none; }
.ar-am-card.ar-flipped .ar-am-front, .ar-am-card.ar-matched .ar-am-front { display: block; }
.ar-am-card.ar-matched .ar-am-front { color: var(--green); font-weight: 600; }

/* ════════════════════════════
   GAME: DEBUG DASH
   ════════════════════════════ */
.ar-debugdash {
  flex: 1; padding: 14px 16px;
  display: flex; flex-direction: column; gap: 10px;
  background: var(--bg); min-height: 420px;
}
.ar-dd-hint { font-family: var(--mono); font-size: 10px; color: var(--zinc-5); }
.ar-dd-timer { height: 3px; background: var(--border-l); border-radius: 2px; overflow: hidden; }
.ar-dd-fill  { height: 100%; background: var(--volt); border-radius: 2px; transition: width .1s linear, background .3s; }
.ar-dd-code  { background: var(--bg-s); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; flex: 1; display: flex; flex-direction: column; }
.ar-dd-code-top { background: var(--bg-m); border-bottom: 1px solid var(--border); padding: 6px 12px; display: flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 10px; color: var(--zinc-5); }
.ar-dd-cdots { display: flex; gap: 4px; }
.ar-dd-cdot  { width: 8px; height: 8px; border-radius: 50%; }
.ar-dd-line { display: flex; align-items: center; gap: 10px; padding: 5px 12px; cursor: pointer; border-left: 3px solid transparent; border-bottom: 1px solid var(--border-l); transition: background .12s, border-color .12s; }
.ar-dd-line:last-child { border-bottom: none; }
.ar-dd-line:hover  { background: var(--bg-m); border-left-color: var(--zinc-3); }
.ar-dd-line.ar-ok  { background: var(--green-bg); border-left-color: var(--volt); }
.ar-dd-line.ar-wrong   { background: var(--red-bg); border-left-color: var(--red); animation: ar-shake .3s ease; }
.ar-dd-line.ar-revealed{ background: var(--red-bg); border-left-color: var(--red); }
.ar-dd-ln   { font-family: var(--mono); font-size: 11px; color: var(--zinc-4); width: 18px; text-align: right; flex-shrink: 0; }
.ar-dd-text { font-family: var(--mono); font-size: 11.5px; color: var(--zinc-7); flex: 1; white-space: pre-wrap; }
.ar-dd-bmark { font-size: 11px; opacity: 0; flex-shrink: 0; transition: opacity .2s; }
.ar-dd-line.ar-revealed .ar-dd-bmark { opacity: 1; }
.ar-dd-result { font-family: var(--mono); font-size: 11px; text-align: center; min-height: 18px; }
/* Syntax tokens */
.tk { color: #d73a49; } .tf { color: #6f42c1; } .ts { color: #032f62; } .tn { color: #005cc5; } .tc { color: var(--zinc-4); font-style: italic; }

/* ════════════════════════════
   SIDEBAR
   ════════════════════════════ */
.ar-sidebar { display: flex; flex-direction: column; gap: 14px; }
.ar-sb { border: 1px solid var(--border); border-radius: 8px; background: var(--bg); box-shadow: var(--sh1); overflow: hidden; }
.ar-sb-hd {
  background: var(--bg-s); border-bottom: 1px solid var(--border);
  padding: 9px 14px; display: flex; align-items: center;
  justify-content: space-between; gap: 8px;
  font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--zinc-7);
}
.ar-sb-hd-l { display: flex; align-items: center; gap: 6px; }
.ar-sb-link { font-family: var(--mono); font-size: 10px; color: var(--volt); text-decoration: none; }
.ar-sb-link:hover { text-decoration: underline; color: var(--volt); }
.ar-volt-dot { width: 6px; height: 6px; background: var(--volt); border-radius: 50%; }

/* LB tabs */
.ar-lb-tabs { display: flex; gap: 3px; }
.ar-lb-tab { font-family: var(--mono); font-size: 9px; color: var(--zinc-5); background: var(--bg); border: 1px solid var(--border); border-radius: 4px; padding: 2px 6px; cursor: pointer; transition: all .12s; }
.ar-lb-tab.act { color: var(--volt); border-color: var(--volt); background: var(--green-bg); }

/* LB rows */
.ar-lb-row { display: flex; align-items: center; gap: 9px; padding: 8px 14px; border-bottom: 1px solid var(--border-l); transition: background .12s; }
.ar-lb-row:last-child { border-bottom: none; }
.ar-lb-row:hover { background: var(--bg-s); }
.ar-lb-row.me { background: var(--green-bg); }
.ar-lb-rank { font-family: var(--mono); font-size: 11px; color: var(--zinc-4); width: 20px; text-align: center; flex-shrink: 0; }
.ar-lb-rank.r1 { color: var(--orange); font-weight: 700; }
.ar-lb-av { width: 26px; height: 26px; border-radius: 50%; background: var(--volt); display: flex; align-items: center; justify-content: center; font-family: var(--mono); font-size: 9px; font-weight: 600; color: #fff; flex-shrink: 0; overflow: hidden; }
.ar-lb-av img { width: 26px; height: 26px; display: block; }
.ar-lb-info { flex: 1; min-width: 0; }
.ar-lb-name  { font-size: 12px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ar-lb-game  { font-family: var(--mono); font-size: 9px; color: var(--zinc-5); }
.ar-lb-score { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--volt); flex-shrink: 0; }
.ar-lb-loading { padding: 20px 14px; text-align: center; font-family: var(--mono); font-size: 11px; color: var(--zinc-4); }

/* My Bests */
.ar-my-bests { display: flex; flex-direction: column; }
.ar-my-best-row {
  display: flex; align-items: center; gap: 8px; padding: 9px 14px;
  border-bottom: 1px solid var(--border-l); font-size: 12px;
  transition: background .1s;
}
.ar-my-best-row:last-child { border-bottom: none; }
.ar-my-best-row:hover { background: var(--bg-s); }
.ar-my-best-game  { flex: 1; color: var(--zinc-7); }
.ar-my-best-score { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--volt); }
.ar-my-best-plays { font-family: var(--mono); font-size: 10px; color: var(--zinc-4); }

/* Chips info panel */
.ar-htp { padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.ar-htp-row { display: flex; align-items: flex-start; gap: 10px; }
.ar-htp-icon  { font-size: 13px; flex-shrink: 0; margin-top: 1px; }
.ar-htp-title { font-size: 12px; font-weight: 600; color: var(--ink); }
.ar-htp-desc  { font-size: 11px; color: var(--zinc-5); line-height: 1.45; margin-top: 1px; }
.ar-htp-chips { border-top: 1px solid var(--border-l); padding-top: 10px; margin-top: 2px; }
.ar-htp-chips-title { font-family: var(--mono); font-size: 10px; font-weight: 700; color: var(--volt); margin-bottom: 6px; }
.ar-htp-chips-rows { display: flex; flex-direction: column; gap: 3px; }
.ar-htp-chips-row { display: flex; justify-content: space-between; font-size: 11px; color: var(--zinc-5); font-family: var(--mono); }
.ar-htp-chips-row span:last-child { color: var(--volt); font-weight: 600; }

/* ════════════════════════════
   CTA BANNER
   ════════════════════════════ */
.ar-cta {
  background: var(--ink); border-radius: 8px; padding: 28px 32px;
  position: relative; overflow: hidden; margin-top: 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
}
.ar-cta::after {
  content: ''; position: absolute; right: -50px; top: 50%;
  transform: translateY(-50%); width: 180px; height: 180px;
  border-radius: 50%; border: 45px solid rgba(29,185,84,.07); pointer-events: none;
}
.ar-cta-l { position: relative; min-width: 0; }
.ar-cta-title { font-size: 17px; font-weight: 700; color: #fff; letter-spacing: -.015em; margin-bottom: 5px; }
.ar-cta-sub   { font-size: 13px; color: rgba(255,255,255,.5); line-height: 1.5; }
.ar-cta-btns  { display: flex; gap: 10px; flex-wrap: wrap; position: relative; flex-shrink: 0; }
.ar-cta-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 18px; border-radius: var(--r);
  font-size: 13px; font-weight: 600; text-decoration: none !important;
  font-family: var(--font); transition: all .15s; white-space: nowrap;
}
.ar-cta-btn:hover { transform: translateY(-1px); }
.ar-cta-btn.v { background: var(--volt); color: #fff; }
.ar-cta-btn.v:hover { background: var(--volt-dim); }
.ar-cta-btn.g { background: transparent; color: rgba(255,255,255,.7); border: 1px solid rgba(255,255,255,.18); }
.ar-cta-btn.g:hover { border-color: rgba(255,255,255,.4); color: #fff; }

/* ════════════════════════════
   RESPONSIVE
   ════════════════════════════ */
@media (max-width: 840px) {
  .ar-layout { grid-template-columns: minmax(0,1fr); }
  .ar-sidebar { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .ar-stats   { display: none; }
}
@media (max-width: 720px) {
  .ar-hi, .ar-body { padding-left: 16px; padding-right: 16px; }
  .ar-header-row { flex-direction: column; gap: 14px; }
  .ar-am-grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
}
@media (max-width: 560px) {
  .ar-sidebar { grid-template-columns: minmax(0,1fr); }
  .ar-cta { flex-direction: column; }
}
@media (max-width: 400px) {
  .ar-am-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

/* ════════════════════════════
   ANIMATIONS
   ════════════════════════════ */
@keyframes ar-in { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:translateY(0); } }
