:root {
  --bg: #101a17; --panel: #1b2925; --panel2: #24362f; --line: rgba(167, 243, 208, 0.16);
  --text: #eefaf4; --dim: #9db5aa; --accent: #6ee7b7; --accent2: #a7f3d0; --bad: #f87171; --gold: #facc15;
  --r: 16px;
  /* 판 꾸미기 */
  --felt: #1f7a4d; --felt2: #19673f; --grid: rgba(0, 0, 0, 0.35); --frame: #3b2a1a; --wall: #2b2017;
  --disc-b: radial-gradient(circle at 35% 30%, #4b5563, #0b0d10 70%); --disc-w: radial-gradient(circle at 35% 30%, #ffffff, #d1d5db 75%);
  --dot: rgba(0, 0, 0, 0.28); --dot-on: rgba(255, 255, 255, 0.5);
}
body.t-wood { --felt: #b7834f; --felt2: #a87443; --grid: rgba(60, 30, 10, 0.45); --frame: #4a2e16; --wall: #3a2412; --dot: rgba(60, 30, 10, 0.35); }
body.t-marble { --felt: #d9dde3; --felt2: #c9ced6; --grid: rgba(70, 80, 95, 0.4); --frame: #6b7280; --wall: #4b5563; --dot: rgba(40, 50, 70, 0.3); }
body.t-neon { --felt: #10172e; --felt2: #0c1226; --grid: rgba(56, 189, 248, 0.45); --frame: #1e1b4b; --wall: #312e81;
  --disc-b: radial-gradient(circle at 35% 30%, #f472b6, #831843 75%); --disc-w: radial-gradient(circle at 35% 30%, #a5f3fc, #0891b2 75%); --dot: rgba(56, 189, 248, 0.45); }
body.t-night { --felt: #1c2347; --felt2: #161c3b; --grid: rgba(165, 180, 252, 0.3); --frame: #0f1330; --wall: #0b0e24;
  --disc-b: radial-gradient(circle at 35% 30%, #6366f1, #1e1b4b 75%); --disc-w: radial-gradient(circle at 35% 30%, #fff7cc, #fbbf24 80%); --dot: rgba(253, 230, 138, 0.4); }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: radial-gradient(circle at 50% 0%, #1d3a30 0%, var(--bg) 60%, #070d0b 100%);
  color: var(--text);
  font-family: system-ui, -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  display: flex; flex-direction: column; overflow: hidden;
  -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none;
}
button { font: inherit; color: inherit; cursor: pointer; }
button:disabled { cursor: default; opacity: 0.45; }
[hidden] { display: none !important; }

.topbar { display: flex; align-items: center; gap: 10px; padding: 8px 12px; padding-top: max(8px, env(safe-area-inset-top)); }
.back-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px;
  background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.3); color: #7dd3fc;
  text-decoration: none; font-size: 0.85rem; font-weight: 700;
}
.back-btn:hover { background: rgba(56, 189, 248, 0.22); }
.total { margin-left: auto; font-weight: 800; }
.tools { display: flex; gap: 6px; }
.mini { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: var(--panel); font-weight: 800; }

/* 돌 */
.d { display: block; border-radius: 50%; }
.d.b { background: var(--disc-b); box-shadow: 0 2px 3px rgba(0, 0, 0, 0.5); }
.d.w { background: var(--disc-w); box-shadow: 0 2px 3px rgba(0, 0, 0, 0.45); }

/* ── 메뉴 ── */
.screen { flex: 1; overflow-y: auto; padding: 4px 16px 32px; }
.screen > * { max-width: 680px; margin-left: auto; margin-right: auto; }
.logo { text-align: center; margin: 2px auto 12px; }
.logo-art { display: inline-grid; grid-template-columns: repeat(2, 30px); gap: 4px; padding: 6px; border-radius: 10px; background: #1f7a4d; }
.logo-art .d { width: 30px; height: 30px; animation: lflip 4s ease-in-out infinite; }
.logo-art .d:nth-child(2) { animation-delay: 1s; } .logo-art .d:nth-child(3) { animation-delay: 2s; } .logo-art .d:nth-child(4) { animation-delay: 3s; }
@keyframes lflip { 0%, 80%, 100% { transform: none; } 88% { transform: scaleX(0.05); } }
h1 { margin: 10px 0 2px; font-size: 1.6rem; letter-spacing: -0.02em; }
h1 span { color: var(--accent); }
.tagline { margin: 0; color: var(--dim); font-size: 0.9rem; }

.tabs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 12px; }
.tab { padding: 9px 2px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); font-weight: 700; font-size: 0.82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tab.on { background: var(--accent); color: #062418; border-color: var(--accent); }
.dim { color: var(--dim); }
.small { font-size: 0.82rem; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; margin-bottom: 12px; }
.card h3 { margin: 0 0 6px; font-size: 1.05rem; }
.btn { padding: 10px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); font-weight: 800; }
.btn.go { background: var(--accent); color: #062418; border-color: var(--accent); }
.btn.small { padding: 6px 10px; font-size: 0.85rem; }
.btn.wide { width: 100%; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.continue {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; margin-bottom: 12px;
  border-radius: var(--r); border: 1px solid rgba(110, 231, 183, 0.5); background: linear-gradient(135deg, rgba(110, 231, 183, 0.2), rgba(110, 231, 183, 0.05));
}
.continue .ci { width: 34px; height: 34px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #062418; }
.continue b { display: block; } .continue small { color: var(--dim); }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; text-align: center; margin: 8px 0; }
.kpis div { background: var(--panel2); border-radius: 12px; padding: 8px 2px; }
.kpis b { display: block; font-size: 1.2rem; } .kpis small { color: var(--dim); font-size: 0.72rem; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin-top: 8px; }
.cal span { aspect-ratio: 1; border-radius: 6px; background: var(--panel2); display: grid; place-items: center; font-size: 0.7rem; color: var(--dim); }
.cal .w { background: #1f7a4d; color: #fff; font-weight: 800; } .cal .t { outline: 2px solid var(--accent); }
.wk { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; font-size: 0.66rem; color: var(--dim); text-align: center; margin-top: 8px; }

.opps { display: grid; gap: 8px; }
.opp { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r); border: 1px solid var(--line); background: var(--panel); text-align: left; width: 100%; }
.opp .oi { font-size: 1.9rem; width: 44px; text-align: center; flex: none; }
.opp .om { flex: 1; min-width: 0; }
.opp b { display: block; } .opp small { color: var(--dim); display: block; font-size: 0.76rem; }
.opp .os { color: var(--gold); font-size: 1rem; letter-spacing: 1px; white-space: nowrap; }
.opp.next { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(110, 231, 183, 0.25) inset; }
.opp.lock { opacity: 0.45; }
.chap { margin-bottom: 12px; }
.chap-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.chap-h b { font-size: 1rem; } .chap-h small { color: var(--dim); }
.chap-h .zs { margin-left: auto; font-weight: 800; color: var(--accent2); font-size: 0.85rem; white-space: nowrap; }
.pzs { display: grid; grid-template-columns: repeat(10, 1fr); gap: 5px; }
.pz { aspect-ratio: 1; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 800; padding: 0; font-size: 0.85rem; }
.pz small { font-size: 0.5rem; color: var(--gold); letter-spacing: -1px; min-height: 0.8em; }
.pz.done { background: var(--panel2); border-color: rgba(110, 231, 183, 0.4); }
.pz.next { border-color: var(--accent); }
.locked { opacity: 0.45; }
.seg { display: flex; gap: 4px; flex-wrap: wrap; margin: 4px 0 10px; }
.seg button { flex: 1; min-width: 44px; padding: 8px 6px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel2); font-weight: 700; font-size: 0.82rem; }
.seg button.on { background: var(--accent); color: #062418; border-color: var(--accent); }
.lbl { font-weight: 800; font-size: 0.85rem; margin-top: 4px; }
.lbl small { color: var(--dim); font-weight: 400; }
.achs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.ach { display: flex; gap: 8px; align-items: center; padding: 8px; border-radius: 12px; background: var(--panel2); font-size: 0.8rem; }
.ach .ai { font-size: 1.3rem; } .ach b { display: block; font-size: 0.85rem; } .ach small { color: var(--dim); }
.ach.off { opacity: 0.45; filter: grayscale(1); }
.opt { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.opt:first-of-type { border-top: 0; }
.opt div { flex: 1; } .opt small { display: block; color: var(--dim); }
.sw { width: 50px; height: 28px; border-radius: 999px; border: 1px solid var(--line); background: #3b4a43; position: relative; flex: none; }
.sw::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform 0.15s; }
.sw.on { background: #1f9d63; } .sw.on::after { transform: translateX(22px); }
.themes { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.th { padding: 6px 2px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); font-size: 0.68rem; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.th i { width: 34px; height: 34px; border-radius: 8px; display: block; border: 2px solid rgba(0, 0, 0, 0.3); }
.th.on { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(110, 231, 183, 0.3) inset; }
.th-felt { background: #1f7a4d; } .th-wood { background: #b7834f; } .th-marble { background: #d9dde3; } .th-neon { background: #10172e; box-shadow: 0 0 6px #38bdf8 inset; } .th-night { background: #1c2347; }
.lvwins { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; text-align: center; font-size: 0.72rem; }
.lvwins div { background: var(--panel2); border-radius: 8px; padding: 4px 0; } .lvwins b { display: block; font-size: 0.9rem; }

/* ── 대국 ── */
#play { flex: 1; display: flex; flex-direction: column; min-height: 0; padding-bottom: env(safe-area-inset-bottom); }
.p-head { display: flex; align-items: center; gap: 8px; padding: 2px 12px 4px; max-width: 560px; width: 100%; margin: 0 auto; }
.p-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.p-title b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .p-title small { color: var(--dim); font-size: 0.76rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.score { display: flex; align-items: center; gap: 8px; padding: 2px 12px; max-width: 560px; width: 100%; margin: 0 auto; }
.side { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); transition: box-shadow 0.2s, border-color 0.2s; }
.side.r { justify-content: flex-end; text-align: right; }
.side .d { width: 28px; height: 28px; flex: none; }
.side div { min-width: 0; } .side small { display: block; color: var(--dim); font-size: 0.72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side b { font-size: 1.35rem; line-height: 1; }
.side.on { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(110, 231, 183, 0.3); }
.vs { flex: none; width: 92px; text-align: center; font-size: 0.78rem; font-weight: 700; color: var(--accent2); line-height: 1.25; }
.vs.think::after { content: ''; display: inline-block; width: 1.2em; text-align: left; animation: dots 1s steps(4) infinite; }
@keyframes dots { 0% { content: ''; } 25% { content: '.'; } 50% { content: '..'; } 75% { content: '...'; } }
.bar { height: 5px; max-width: 536px; width: calc(100% - 24px); margin: 6px auto 0; border-radius: 3px; background: #e5e7eb; overflow: hidden; }
.bar i { display: block; height: 100%; width: 50%; background: #111827; transition: width 0.35s; }
.board-wrap { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; position: relative; padding: 6px 8px; }
.board {
  display: grid; gap: 0; padding: var(--pad, 10px); border-radius: 12px; position: relative;
  background: var(--frame); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), inset 0 0 0 2px rgba(255, 255, 255, 0.06);
}
.cell {
  width: var(--cs, 40px); height: var(--cs, 40px); padding: 0; border: 0; border-radius: 0; position: relative;
  background: var(--felt); box-shadow: inset 0 0 0 0.5px var(--grid); display: grid; place-items: center; touch-action: manipulation;
}
.cell:nth-child(odd) { background: var(--felt); }
.cell.alt { background: var(--felt2); }
.cell.wall { background: var(--wall); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.3), inset 0 4px 8px rgba(0, 0, 0, 0.4); cursor: default; }
.cell.wall::before { content: ''; width: 40%; height: 40%; border-radius: 4px; background: rgba(255, 255, 255, 0.05); }
.cell .d { width: 84%; height: 84%; }
.cell .d.new { animation: drop 0.22s ease-out; }
.cell .d.fb { animation: toB 0.36s ease-in-out both; }
.cell .d.fw { animation: toW 0.36s ease-in-out both; }
@keyframes drop { from { transform: scale(1.35); opacity: 0.4; } to { transform: none; opacity: 1; } }
@keyframes toB { 0% { background: var(--disc-w); transform: scaleX(1); } 49% { background: var(--disc-w); transform: scaleX(0.06); } 51% { background: var(--disc-b); transform: scaleX(0.06); } 100% { background: var(--disc-b); transform: scaleX(1); } }
@keyframes toW { 0% { background: var(--disc-b); transform: scaleX(1); } 49% { background: var(--disc-b); transform: scaleX(0.06); } 51% { background: var(--disc-w); transform: scaleX(0.06); } 100% { background: var(--disc-w); transform: scaleX(1); } }
.cell .mv { width: 26%; height: 26%; border-radius: 50%; background: var(--dot); }
.cell.can:hover .mv, .cell.can:focus-visible .mv { background: var(--dot-on); transform: scale(1.4); }
.cell .mv.n { width: auto; height: auto; background: none; font-size: calc(var(--cs) * 0.3); font-weight: 900; color: var(--dot-on); text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); }
.cell .last { position: absolute; width: 16%; height: 16%; border-radius: 50%; background: #ef4444; box-shadow: 0 0 4px #ef4444; pointer-events: none; }
.cell.hint { box-shadow: inset 0 0 0 3px var(--gold), inset 0 0 14px rgba(250, 204, 21, 0.6); }
.cell.hint .mv { background: var(--gold); transform: scale(1.4); }
.cell.bad { box-shadow: inset 0 0 0 3px var(--bad); }
.coord { position: absolute; font-size: 0.6rem; color: rgba(255, 255, 255, 0.45); font-weight: 700; pointer-events: none; }
.toast { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); background: #f1f5f9; color: #0f172a; padding: 8px 14px; border-radius: 10px; font-weight: 800; font-size: 0.88rem; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4); z-index: 3; max-width: calc(100% - 24px); text-align: center; pointer-events: none; }
.toast.bad { background: #fee2e2; color: #7f1d1d; }
.ctrl { display: flex; gap: 8px; justify-content: center; padding: 4px 12px 12px; max-width: 560px; width: 100%; margin: 0 auto; }
.cbtn { flex: 1; max-width: 140px; display: flex; flex-direction: column; align-items: center; padding: 6px 8px; border-radius: 14px; border: 1px solid var(--line); background: var(--panel); font-size: 1.15rem; line-height: 1.15; }
.cbtn span { font-size: 0.7rem; color: var(--dim); }
.cbtn.used { border-color: rgba(250, 204, 21, 0.5); }

/* ── 모달 ── */
.modal { position: fixed; inset: 0; background: rgba(4, 8, 6, 0.7); display: grid; place-items: center; padding: 16px; z-index: 10; }
.modal-box { width: min(440px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 20px; padding: 18px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); }
.modal-box h2 { margin: 0 0 8px; font-size: 1.25rem; }
.modal-box p { line-height: 1.5; }
.modal-btns { display: flex; gap: 8px; justify-content: flex-end; margin-top: 14px; flex-wrap: wrap; }
.modal-btns .btn { flex: 1; white-space: nowrap; padding: 10px 8px; }
.err { font-family: ui-monospace, monospace; font-size: 0.75rem; background: #08100c; padding: 8px; border-radius: 8px; white-space: pre-wrap; color: #fecaca; max-height: 140px; overflow: auto; user-select: text; -webkit-user-select: text; }
.win { text-align: center; }
.win-ico { font-size: 2.6rem; animation: rise 0.5s ease-out; }
@keyframes rise { from { transform: scale(0.6) rotate(-6deg); opacity: 0; } to { transform: none; opacity: 1; } }
.final { display: flex; justify-content: center; align-items: center; gap: 14px; font-size: 1.8rem; font-weight: 900; margin: 6px 0; }
.final .d { width: 30px; height: 30px; }
.final span { display: flex; align-items: center; gap: 6px; }
.stars { font-size: 2rem; color: var(--gold); letter-spacing: 4px; }
.win-line { margin: 4px 0; font-weight: 700; }
.ach-got { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 8px; }
.ach-got span { padding: 5px 10px; border-radius: 999px; background: rgba(167, 243, 208, 0.12); border: 1px solid rgba(167, 243, 208, 0.45); font-size: 0.82rem; font-weight: 700; }
.intro { text-align: center; }
.intro .oi { font-size: 3rem; }
.intro q { display: block; margin: 8px 0; font-style: italic; color: var(--accent2); }
.intro ul { text-align: left; margin: 8px 0; padding-left: 20px; font-size: 0.86rem; color: var(--dim); }
.ex { display: inline-grid; grid-template-columns: repeat(5, 26px); gap: 0; padding: 4px; border-radius: 6px; background: #3b2a1a; margin: 4px 0; }
.ex span { width: 26px; height: 26px; background: #1f7a4d; box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.35); display: grid; place-items: center; }
.ex .d { width: 20px; height: 20px; } .ex .mv { width: 8px; height: 8px; border-radius: 50%; background: #facc15; }
.noscript { padding: 20px; text-align: center; }

@media (max-width: 400px) { .back-txt { display: none; } .tab { font-size: 0.72rem; } .pzs { gap: 3px; } .vs { width: 76px; font-size: 0.72rem; } .side { padding: 5px 7px; } .side .d { width: 22px; height: 22px; } .side b { font-size: 1.15rem; } }
@media (max-height: 620px) { .cbtn span { display: none; } .p-title small { display: none; } }

/* ── 복기 ── */
#review { flex: 1; display: flex; flex-direction: column; min-height: 0; padding-bottom: env(safe-area-inset-bottom); }
#review > .p-head, .rv-sum, .rv-graph, .rv-info, .rv-moves { max-width: 560px; width: calc(100% - 24px); margin-left: auto; margin-right: auto; }
#review > .p-head { width: 100%; }
.rv-sum { display: grid; gap: 4px; margin-top: 2px; }
.rv-side { display: flex; align-items: center; gap: 6px; padding: 4px 8px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); font-size: 0.8rem; min-width: 0; }
.rv-side .d { width: 18px; height: 18px; flex: none; }
.rv-side > b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 30%; }
.rv-side .acc { font-weight: 900; color: var(--accent2); }
.rv-side .cnts { flex: 1; min-width: 0; display: flex; gap: 4px; flex-wrap: wrap; }
.rv-side .btn.small { padding: 3px 8px; font-size: 0.74rem; white-space: nowrap; }
.rv-sum .ach-got { margin-top: 2px; }
.rv-prog { position: relative; padding: 6px 10px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); font-size: 0.8rem; overflow: hidden; }
.rv-prog span { position: relative; z-index: 1; }
.rv-prog i { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(110, 231, 183, 0.18); transition: width 0.2s; }
.g { font-weight: 800; white-space: nowrap; }
.g.g0 { color: #a7f3d0; } .g.g1 { color: #bef264; } .g.g2 { color: #fde047; } .g.g3 { color: #fb923c; } .g.g4 { color: #f87171; }
.rv-graph { display: block; height: 52px; margin-top: 6px; border-radius: 10px; overflow: hidden; cursor: pointer; border: 1px solid var(--line); }
.rv-graph .up { fill: #2a3a34; } .rv-graph .down { fill: #dfe7e3; }
.rv-graph .area { fill: rgba(17, 24, 39, 0.55); }
.rv-graph .ln { fill: none; stroke: #6ee7b7; stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.rv-graph .mid { stroke: rgba(110, 231, 183, 0.4); stroke-width: 1; vector-effect: non-scaling-stroke; }
.rv-graph .cur { stroke: var(--gold); stroke-width: 2; vector-effect: non-scaling-stroke; }
.rv-graph .dot.g3 { fill: #fb923c; } .rv-graph .dot.g4 { fill: #ef4444; }
.rv-info { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; justify-content: center; min-height: 2.6em; padding: 4px 0 2px; font-size: 0.86rem; text-align: center; }
.rv-info .rv-cnt { font-weight: 800; color: var(--accent2); }
.rv-info .best { color: var(--gold); }
.cell .d.ghost { width: 62%; height: 62%; opacity: 0.5; box-shadow: none; }
.rv-moves { position: relative; display: flex; gap: 4px; overflow-x: auto; padding: 2px 0 6px; scrollbar-width: thin; }
.mvc { flex: none; display: flex; flex-direction: column; align-items: center; min-width: 36px; padding: 2px 4px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); font-size: 0.6rem; color: var(--dim); line-height: 1.2; }
.mvc b { font-size: 0.78rem; color: var(--text); }
.mvc.pb { border-left: 3px solid #0b0d10; } .mvc.pw { border-left: 3px solid #e5e7eb; }
.mvc.g2 { background: rgba(253, 224, 71, 0.16); } .mvc.g3 { background: rgba(251, 146, 60, 0.25); } .mvc.g4 { background: rgba(248, 113, 113, 0.3); }
.mvc.on { outline: 2px solid var(--gold); }
.rv-ctrl .cbtn { max-width: 110px; }
.games { display: grid; gap: 6px; }
.gm { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); }
.gm > div { flex: 1; min-width: 0; } .gm b { display: block; font-size: 0.88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .gm small { color: var(--dim); font-size: 0.72rem; }
.gm .gr { flex: none; font-size: 0.78rem; font-weight: 800; width: 52px; }
.gm .gr.win { color: var(--accent); } .gm .gr.lose, .gm .gr.resign { color: var(--bad); }
.gm .ga { flex: none; font-size: 0.74rem; color: var(--accent2); text-align: right; }
@media (max-height: 700px) { .rv-graph { height: 38px; } .rv-moves .mvc { padding: 1px 3px; } }
@media (max-height: 620px) { .rv-ctrl .cbtn span { display: none; } }
