/*
THESIS: 전략 게임 타이틀 시퀀스 같은 공부 도구. 카지노 테이블(녹색 펠트·칩·금색)과 둥근 카드 상자 앱을 거부한다.
OWN-WORLD: 흰 종이 · 먹색 1.5px 선 · 아이소메트릭 큐브와 13×13 격자 · 빨강 하나(공격 액션·실수) · Pretendard 800 제목 · 모서리 2~4px.
STORY: 열자마자 큐브가 깨져 실제 전략 격자가 되고 이름이 선다 → 상황 한 줄을 누르면 바로 한 판 → 결정마다 판정 시트 → 다음 핸드.
FIRST VIEWPORT: 시작 모션 2초 후 첫 화면 — 왼쪽 정렬 큰 제목, 실제 BTN 오픈 격자 한 장, 상황 줄(이름·팟 종류·격자 글리프), 아래 먹색 시작 버튼.
FORM: 사용자 지정(더 지니어스 오프닝) — 뽑기 생략. 연출은 시작 모션 하나, 나머지는 상태 설명 모션.
*/
@font-face { font-family: "Pretendard"; font-weight: 400; font-display: swap; src: url("fonts/Pretendard-Regular.woff2") format("woff2"); }
@font-face { font-family: "Pretendard"; font-weight: 700; font-display: swap; src: url("fonts/Pretendard-Bold.woff2") format("woff2"); }
@font-face { font-family: "Pretendard"; font-weight: 800; font-display: swap; src: url("fonts/Pretendard-ExtraBold.woff2") format("woff2"); }

:root {
  --paper: oklch(0.985 0.003 25);
  --paper-2: oklch(0.955 0.004 25);
  --ink: oklch(0.2 0.01 25);
  --ink-2: oklch(0.45 0.01 25);
  --ink-3: oklch(0.62 0.008 25);
  --rule: oklch(0.86 0.005 25);
  --red: oklch(0.56 0.21 27);
  --red-soft: oklch(0.95 0.03 27);
  --s-d: oklch(0.5 0.15 255);
  --s-c: oklch(0.5 0.12 150);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --line: 1.5px solid var(--ink);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--paper); color: var(--ink); }
body { font-family: "Pretendard", -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; font-size: 16px; line-height: 1.45; font-feature-settings: "tnum"; word-break: keep-all; overflow-wrap: anywhere; }
.sum-msg, .fb-act, .info-pop p { text-wrap: pretty; }
button, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, select:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.pad { padding: 24px 20px; }
.err { color: var(--red); }
.muted { color: var(--ink-2); }
.screen { max-width: 480px; margin: 0 auto; padding: 0 20px 128px; }

/* ---------- 시작 모션 ---------- */
.intro { position: fixed; inset: 0; z-index: 50; background: var(--paper); display: grid; place-items: center; overflow: hidden; }
.intro.out { animation: introOut 380ms var(--ease) forwards; }
@keyframes introOut { to { opacity: 0; transform: translateY(-24px); } }
.intro-stage { position: relative; width: 260px; height: 260px; }
.intro svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.cube-line { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; stroke-dasharray: 400; stroke-dashoffset: 400; animation: draw 520ms var(--ease) forwards; }
.cube-line.l2 { animation-delay: 90ms; } .cube-line.l3 { animation-delay: 180ms; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.cube-face { opacity: 0; animation: face 220ms var(--ease) forwards; }
.cube-face.top { fill: var(--red); animation-delay: 520ms; }
.cube-face.left { fill: var(--ink); animation-delay: 580ms; }
.cube-face.right { fill: var(--paper); animation-delay: 620ms; }
@keyframes face { to { opacity: 1; } }
.cube { transform-origin: 130px 130px; animation: cubeBreak 260ms var(--ease) 900ms forwards; }
@keyframes cubeBreak { to { transform: scale(0.2) rotate(30deg); opacity: 0; } }
.igrid { position: absolute; inset: 22px; display: grid; grid-template-columns: repeat(13, 1fr); gap: 2px; }
.igrid i { aspect-ratio: 1; background: var(--rule); opacity: 0; transform: translate(var(--fx), var(--fy)) scale(0.2) rotate(45deg); animation: cellIn 520ms var(--ease) forwards; animation-delay: var(--d); }
.igrid i.r { background: var(--ink); } .igrid i.m { background: var(--ink-3); } .igrid i.k { background: var(--red); }
@keyframes cellIn { to { opacity: 1; transform: none; } }
.igrid.fold { animation: gridFold 420ms var(--ease) forwards; }
@keyframes gridFold { to { transform: scaleY(0.04) translateY(-40px); opacity: 0; } }
.wordmark { position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%); text-align: center; }
.wm-big { display: block; font-weight: 800; font-size: 64px; letter-spacing: -0.04em; line-height: 0.9; clip-path: inset(0 100% 0 0); animation: wipe 520ms var(--ease) forwards; animation-delay: var(--wd); }
.wm-sub { display: block; margin-top: 12px; font-weight: 700; font-size: 14px; color: var(--ink-2); opacity: 0; animation: face 300ms var(--ease) forwards; animation-delay: calc(var(--wd) + 260ms); }
.wm-slash { display: block; width: 0; height: 4px; margin: 10px auto 0; background: var(--red); animation: slash 360ms var(--ease) forwards; animation-delay: calc(var(--wd) + 160ms); }
@keyframes wipe { to { clip-path: inset(0 0 0 0); } }
@keyframes slash { to { width: 72px; } }
.intro-skip { position: absolute; bottom: calc(24px + env(safe-area-inset-bottom)); left: 0; right: 0; text-align: center; font-size: 12px; color: var(--ink-3); }

/* ---------- 첫 화면 ---------- */
.home-top { display: flex; align-items: flex-start; justify-content: space-between; padding: 32px 0 0; }
.home-title { margin: 0; font-weight: 800; font-size: 44px; line-height: 0.95; letter-spacing: -0.04em; }
.home-title span { display: block; font-size: 16px; letter-spacing: -0.01em; font-weight: 700; color: var(--ink-2); margin-top: 12px; }
.info { flex: none; width: 36px; height: 36px; border: var(--line); border-radius: 2px; background: var(--paper); font-weight: 800; }
.info[aria-expanded="true"] { background: var(--ink); color: var(--paper); }
.info-pop { margin: 20px 0 0; padding: 4px 0 4px 16px; border-left: 1.5px solid var(--ink); font-size: 14px; color: var(--ink-2); animation: rise 260ms var(--ease); }
.info-pop p { margin: 12px 0; }
.info-pop b { color: var(--ink); }
.ledger { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 28px; margin: 28px 0 0; padding: 16px 0; border-top: var(--line); border-bottom: 1px solid var(--rule); }
.ledger div { display: flex; flex-direction: column; }
.ledger span { font-size: 12px; color: var(--ink-2); }
.ledger b { font-size: 28px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.sec { margin: 36px 0 12px; font-size: 14px; font-weight: 800; letter-spacing: -0.01em; }
.spot { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 16px; width: 100%; text-align: left; background: none; border: 0; border-top: var(--line); padding: 16px 0; transition: background 160ms var(--ease); }
.spot:last-of-type { border-bottom: var(--line); }
a.spot { color: inherit; text-decoration: none; }
.spot:active { background: var(--paper-2); }
.spot-name { display: block; font-size: 24px; font-weight: 800; letter-spacing: -0.03em; }
.spot-name em { font-style: normal; color: var(--red); }
.spot-sub { display: block; margin-top: 4px; font-size: 13px; color: var(--ink-2); }
.glyph { display: grid; grid-template-columns: repeat(13, 5px); gap: 1px; }
.glyph i { width: 5px; height: 5px; background: var(--rule); }
.glyph i.r { background: var(--ink); } .glyph i.m { background: var(--ink-3); }
.seat-pick { display: flex; align-items: center; justify-content: space-between; margin-top: 24px; font-size: 14px; color: var(--ink-2); }
.seg { display: inline-flex; border: var(--line); border-radius: 2px; }
.seg button { border: 0; background: none; padding: 8px 14px; font-size: 14px; font-weight: 700; }
.seg button + button { border-left: 1.5px solid var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.textlink { display: inline-block; margin-top: 28px; padding: 8px 0; border: 0; background: none; font-weight: 700; font-size: 14px; border-bottom: var(--line); }

/* ---------- 판 화면 ---------- */
.bar { position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: 1fr auto; align-items: center; height: 52px; margin: 0 -20px; padding: 0 20px; background: var(--paper); border-bottom: 1px solid var(--rule); }
.back { width: 44px; height: 44px; border: 0; background: none; font-size: 22px; font-weight: 800; }
.bar-title { font-weight: 800; letter-spacing: -0.02em; }
.bar-stat { font-size: 13px; color: var(--ink-2); }
.strip { display: flex; gap: 0; overflow-x: auto; margin: 0 -20px; padding: 10px 20px; scrollbar-width: none; border-bottom: 1px solid var(--rule); }
.strip::-webkit-scrollbar { display: none; }
.st { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; font-size: 13px; color: var(--ink-2); white-space: nowrap; border-left: 1px solid var(--rule); }
.st:first-child { border-left: 0; padding-left: 0; }
.st b { color: var(--ink); font-weight: 800; }
.st b.k-agg { color: var(--red); }
.st b.k-fold { color: var(--ink-3); font-weight: 700; }
.st.auto { opacity: 0.5; }
.st.street { color: var(--ink); font-weight: 800; letter-spacing: 0.02em; }
.st.now b { color: var(--paper); background: var(--ink); padding: 1px 6px; border-radius: 2px; }
.st.enter { animation: slideIn 180ms var(--ease); }
@keyframes slideIn { from { opacity: 0; transform: translateX(12px); } }

.table { position: relative; height: 340px; margin: 16px 0 4px; }
.felt { position: absolute; inset: 22px 8px 40px; border: var(--line); clip-path: polygon(14% 0, 86% 0, 100% 22%, 100% 78%, 86% 100%, 14% 100%, 0 78%, 0 22%); background:
  linear-gradient(var(--paper), var(--paper)) padding-box,
  repeating-linear-gradient(30deg, transparent 0 11px, oklch(0.93 0.004 25) 11px 12px),
  repeating-linear-gradient(-30deg, transparent 0 11px, oklch(0.93 0.004 25) 11px 12px); }
.felt::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(30deg, transparent 0 11px, oklch(0.94 0.004 25) 11px 12px), repeating-linear-gradient(-30deg, transparent 0 11px, oklch(0.94 0.004 25) 11px 12px); opacity: 0.8; }
.felt-edge { position: absolute; inset: 22px 8px 40px; pointer-events: none; }
.felt-edge svg { width: 100%; height: 100%; overflow: visible; }
.seat { white-space: nowrap; overflow-wrap: normal; position: absolute; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 4px; z-index: 2; transition: opacity 220ms var(--ease); }
.seat.folded { opacity: 0.28; }
.plate { position: relative; display: flex; align-items: baseline; gap: 6px; background: var(--paper); border: var(--line); border-radius: 2px; padding: 3px 8px; }
.plate b { font-size: 12px; font-weight: 800; }
.plate span { font-size: 12px; color: var(--ink-2); }
.seat.hero .plate { background: var(--ink); color: var(--paper); }
.seat.hero .plate span { color: oklch(0.8 0.005 25); }
.seat.turn .plate::after { content: ""; position: absolute; inset: -5px; border: 1.5px solid var(--red); border-radius: 3px; animation: ring 900ms var(--ease) infinite alternate; }
@keyframes ring { from { opacity: 1; } to { opacity: 0.25; } }
.seat.win .plate { outline: 2px solid var(--red); outline-offset: 2px; }
.dealer { position: absolute; right: -10px; top: -10px; width: 18px; height: 18px; border: var(--line); border-radius: 50%; background: var(--paper); color: var(--ink); font-style: normal; font-size: 10px; font-weight: 800; display: grid; place-items: center; }
.seat.hero .dealer { border-color: var(--paper); }
.bet { font-size: 12px; font-weight: 800; padding: 0 4px; border-bottom: 2px solid var(--ink); }
.bet.enter { animation: pop 200ms var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } }
.hole { display: flex; gap: 3px; }
.center { position: absolute; left: 50%; top: 44%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 8px; z-index: 1; }
.pot { font-size: 13px; font-weight: 800; background: var(--paper); padding: 0 6px; }
.pot b { font-size: 18px; letter-spacing: -0.02em; }
.board { display: flex; gap: 4px; min-height: 48px; }

.card { position: relative; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; width: 34px; height: 48px; border: var(--line); border-radius: 3px; background: var(--paper); line-height: 1; }
.card b { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; }
.card i { font-style: normal; font-size: 12px; margin-top: 2px; }
.card.s2 i, .card.s2 b { color: var(--red); }
.card.s1 i, .card.s1 b { color: var(--s-d); }
.card.s0 i, .card.s0 b { color: var(--s-c); }
.card.sm { width: 22px; height: 30px; border-width: 1px; }
.card.sm b { font-size: 12px; } .card.sm i { display: none; }
.card.hero-card { width: 44px; height: 62px; box-shadow: 2px 3px 0 var(--ink); }
.card.hero-card b { font-size: 24px; } .card.hero-card i { font-size: 14px; }
.card.mini { width: 16px; height: 22px; border-width: 1px; border-radius: 2px; }
.card.mini b { font-size: 11px; } .card.mini i { display: none; }
.card.back { background: repeating-linear-gradient(45deg, var(--ink) 0 2px, var(--paper) 2px 5px); }
.card.enter { animation: deal 260ms var(--ease) both; animation-delay: var(--dd, 0ms); }
@keyframes deal { from { opacity: 0; transform: translateY(-14px) rotate(-6deg); clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }

/* 판정 시트 */
.fb { margin-top: 16px; padding-top: 16px; border-top: var(--line); }
.fb.enter { animation: rise 260ms var(--ease); }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }
.fb-head { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; }
.fb-word { font-size: 22px; font-weight: 800; letter-spacing: -0.03em; }
.fb.enter .fb-word { animation: wipe 420ms var(--ease) both; clip-path: inset(0 100% 0 0); }
.fb-loss { text-align: right; }
.fb-loss b { display: block; font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.fb-loss span { font-size: 12px; color: var(--ink-2); }
.fb-act { margin: 6px 0 12px; font-size: 13px; color: var(--ink-2); }
.mark { width: 14px; height: 14px; border: 2px solid var(--ink); flex: none; }
.mark.c-best { background: var(--ink); }
.mark.c-good { background: var(--paper); }
.mark.c-inacc { background: linear-gradient(135deg, var(--ink) 50%, var(--paper) 50%); }
.mark.c-miss { border-color: var(--red); background: var(--paper); }
.mark.c-blunder { border-color: var(--red); background: var(--red); }
.mark.c-none { border-color: var(--ink-3); border-style: dashed; }
.freqs { display: grid; gap: 8px; }
.fr { display: grid; grid-template-columns: 96px 1fr 52px 56px; align-items: center; gap: 8px; font-size: 13px; }
.fr .lab { font-weight: 700; }
.fr .bar2 { height: 8px; background: var(--paper-2); position: relative; }
.fr .bar2 i { position: absolute; inset: 0 auto 0 0; background: var(--ink); width: var(--w); transform-origin: left; animation: grow 420ms var(--ease) both; }
.fr.agg .bar2 i { background: var(--red); }
@keyframes grow { from { transform: scaleX(0); } }
.fr .n { text-align: right; }
.fr .lo { text-align: right; color: var(--ink-2); }
.fr.me .lab, .fr.me .n { color: var(--ink); text-decoration: underline 2px; text-underline-offset: 3px; }
.fr.me .lab::before { content: "▸ "; }

.summary { margin-top: 16px; padding: 16px 0; border-top: var(--line); border-bottom: var(--line); animation: rise 280ms var(--ease); }
.sum-msg { margin: 0 0 4px; font-weight: 800; font-size: 18px; letter-spacing: -0.02em; }
.sum-loss { margin: 0 0 12px; color: var(--ink-2); font-size: 14px; }
.sum-loss b { color: var(--ink); }
.sum-chips { display: flex; gap: 16px; flex-wrap: wrap; }
.sc { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; }
.sc.off { color: var(--ink-3); font-weight: 400; }
.meta { color: var(--ink-3); font-size: 12px; margin: 16px 0 0; }

/* 아래 고정 버튼 */
.bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; display: flex; gap: 8px; max-width: 480px; margin: 0 auto; padding: 12px 20px calc(16px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 1px solid var(--rule); }
.bottom.enter .act { animation: pop 200ms var(--ease) both; }
.bottom.enter .act:nth-child(2) { animation-delay: 40ms; } .bottom.enter .act:nth-child(3) { animation-delay: 80ms; } .bottom.enter .act:nth-child(4) { animation-delay: 120ms; }
.bottom .wait { margin: 0; width: 100%; height: 52px; display: grid; place-items: center; color: var(--ink-3); font-size: 14px; }
.bottom .wait::before { content: ""; width: 40px; height: 2px; background: var(--ink); margin-bottom: 8px; animation: scan 900ms var(--ease) infinite alternate; }
@keyframes scan { from { transform: translateX(-30px); } to { transform: translateX(30px); } }
.act, .btn { flex: 1; min-height: 52px; border-radius: 3px; font-weight: 800; font-size: 15px; letter-spacing: 0.01em; transition: transform 100ms var(--ease), background 120ms; }
.act:active, .btn:active { transform: translateY(2px); }
.a-fold { background: var(--paper); border: var(--line); }
.a-pass { background: var(--ink); border: var(--line); color: var(--paper); }
.a-agg { background: var(--red); border: 1.5px solid var(--red); color: var(--paper); }
.a-allin { background: var(--paper); border: 2.5px solid var(--red); color: var(--red); }
.btn.primary { background: var(--ink); border: var(--line); color: var(--paper); }
.btn.ghost { background: var(--paper); border: var(--line); }

/* 기록 */
.big4 { display: grid; grid-template-columns: 1fr 1fr; margin-top: 24px; border-top: var(--line); }
.big4 div { padding: 16px 0; border-bottom: 1px solid var(--rule); }
.big4 div:nth-child(odd) { border-right: 1px solid var(--rule); padding-right: 12px; }
.big4 div:nth-child(even) { padding-left: 16px; }
.big4 span { display: block; font-size: 12px; color: var(--ink-2); }
.big4 b { font-size: 32px; font-weight: 800; letter-spacing: -0.03em; }
.list { list-style: none; margin: 0; padding: 0; border-top: var(--line); }
.list li { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--rule); font-size: 15px; }
.list li b { margin-left: auto; font-weight: 800; }

@media (prefers-reduced-motion: reduce) and (hover: hover) and (pointer: fine) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0ms !important; transition-duration: 1ms !important; }
}

/* 무료 소진 */
.lim { padding: 56px 0 24px; border-bottom: var(--line); }
.lim-big { margin: 0; font-size: 36px; font-weight: 800; line-height: 1.1; letter-spacing: -0.04em; }
.lim-sub { margin: 16px 0 0; color: var(--ink-2); font-size: 15px; }
.lim-ok { display: flex; align-items: center; gap: 10px; margin: 20px 0 0; font-weight: 700; }
.lim-msg { margin: 16px 0 0; color: var(--red); font-size: 14px; }
.btn:disabled { opacity: 0.5; }

/* ---------- 전략 보기 ---------- */
:root { --k-fold: oklch(0.88 0.006 25); --k-allin: oklch(0.38 0.15 27); }
.crumbs { display: flex; align-items: center; gap: 4px; overflow-x: auto; margin: 0 -20px; padding: 10px 20px; border-bottom: 1px solid var(--rule); scrollbar-width: none; }
.crumbs::-webkit-scrollbar { display: none; }
.crumb { flex: none; display: inline-flex; align-items: center; gap: 4px; border: 0; background: none; padding: 4px 2px; font-size: 13px; font-weight: 700; color: var(--ink-2); white-space: nowrap; }
.crumb:last-of-type { color: var(--ink); }
.crumb.street { color: var(--ink); }
.crumbs .sep { color: var(--ink-3); font-size: 12px; }
.st-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 16px 0 8px; }
.st-who { margin: 0; font-size: 20px; letter-spacing: -0.02em; }
.st-who b { font-weight: 800; }
.st-board { display: flex; align-items: center; gap: 3px; }
.st-board span:last-child { margin-left: 8px; font-size: 13px; font-weight: 700; }
.sumbar { height: 10px; background: var(--paper-2); margin: 4px 0 10px; }
.sacts { display: flex; flex-wrap: wrap; gap: 8px; }
.sact { display: inline-flex; align-items: center; gap: 8px; border: var(--line); border-radius: 3px; background: var(--paper); padding: 8px 12px; font-size: 14px; min-height: 44px; transition: transform 100ms var(--ease); }
.sact:active { transform: translateY(2px); }
.sact b { font-weight: 800; }
.sact span:last-child { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.sw { width: 12px; height: 12px; flex: none; }
.study-body { margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.ggrid { display: grid; grid-template-columns: repeat(13, 1fr); gap: 1px; background: var(--rule); border: 1px solid var(--rule); }
.gc { position: relative; aspect-ratio: 1; border: 0; padding: 0; background: var(--paper); display: grid; place-items: center; cursor: pointer; }
.gc span { position: relative; font-size: 9px; font-weight: 800; letter-spacing: -0.04em; color: var(--paper); text-shadow: 0 0 2px oklch(0.2 0.01 25 / 0.55); }
.gc.lt span { color: var(--ink); text-shadow: none; }
.gc.empty { background: var(--paper); cursor: default; }
.gc.empty span { color: var(--ink-3); text-shadow: none; font-weight: 400; }
.gc.on { outline: 2.5px solid var(--red); outline-offset: -2px; z-index: 1; }
.detail { min-height: 80px; }
.st-hint { font-size: 13px; margin: 0; }
.dt-h { margin: 0 0 8px; font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.dt-row { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 4px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--rule); }
.dt-name { display: flex; gap: 2px; }
.dt-bar { height: 10px; background: var(--paper-2); }
.dt-nums { grid-column: 2; display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--ink-2); }
.dt-nums b { color: var(--ink); font-weight: 700; }
.dt-nums em { font-style: normal; color: var(--red); }
.st-msg { margin: 32px 0; font-size: 16px; font-weight: 700; }
.flops { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.flop { display: flex; flex-wrap: wrap; justify-content: center; gap: 3px; border: var(--line); border-radius: 3px; background: var(--paper); padding: 10px 4px 8px; }
.flop > span:last-child { width: 100%; text-align: center; font-size: 11px; color: var(--ink-2); margin-top: 4px; }
.flop:active { background: var(--paper-2); }
.picker { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; max-width: 280px; }
.pick { width: auto !important; height: 40px !important; }
.pick.off { border: 1px dashed var(--rule); border-radius: 3px; }
.sec .muted { font-weight: 400; font-size: 12px; margin-left: 6px; }

/* ---------- 넓은 화면 (웹) ---------- */

/* 해설 보기 */
.ex-toggle { margin-left: auto; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--paper); padding: 8px 14px; font-size: 14px; font-weight: 800; min-height: 44px; }
.ex-toggle[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.ex { margin-top: 20px; border-top: 1.5px solid var(--ink); padding-top: 12px; animation: rise 260ms var(--ease); }
.ex-head { display: flex; align-items: center; gap: 10px; }
.ex-head h3 { margin: 0; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.ex-steps { list-style: none; counter-reset: ex; margin: 8px 0 0; padding: 0; }
.ex-steps > li { counter-increment: ex; position: relative; padding: 12px 0 12px 30px; border-top: 1px solid var(--rule); font-size: 14px; }
.ex-steps > li::before { content: counter(ex); position: absolute; left: 0; top: 12px; width: 20px; height: 20px; border: 1.5px solid var(--ink); border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 800; }
.ex-steps > li.ex-wait { color: var(--ink-2); }
.ex-steps > li.ex-wait::before { content: ''; border-style: dashed; }
.ex-steps > li.ex-so::before { background: var(--red); border-color: var(--red); color: var(--paper); }
.ex-steps b { font-weight: 800; }
.ex-steps p { margin: 6px 0 0; color: var(--ink-2); text-wrap: pretty; word-break: keep-all; }
.ex-steps em { font-style: normal; color: var(--red); }
.ex-so b { color: var(--red); font-size: 16px; }
.ex-n { margin-left: 6px; font-weight: 800; font-variant-numeric: tabular-nums; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }
.dot.v { background: var(--red); } .dot.b { background: var(--ink); }
.mgrid { display: grid; grid-template-columns: repeat(13, 1fr); gap: 1px; width: 100%; max-width: 260px; margin-top: 8px; background: var(--rule); border: 1px solid var(--rule); }
.mgrid i { aspect-ratio: 1; background: var(--paper); display: block; }
.ex-key { font-size: 12px; }
.ex-key i { display: inline-block; width: 10px; height: 10px; margin: 0 4px 0 8px; vertical-align: -1px; }
.ex-key .kv { background: var(--red); margin-left: 0; } .ex-key .kb { background: var(--ink); }
.dt-row[data-excombo] { cursor: pointer; }
.dt-row.on { background: var(--paper-2); }

@media (min-width: 900px) {
  .screen { max-width: 1040px; }
  .study-body { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; }
  .gc span { font-size: 12px; }
  .detail { position: sticky; top: 72px; }
  .play { display: grid; grid-template-columns: minmax(0, 1fr) 380px; column-gap: 32px; align-content: start; }
  .play > .bar, .play > .strip { grid-column: 1 / -1; }
  .play > .table { grid-column: 1; grid-row: 3 / span 4; height: 460px; }
  .play > .summary, .play > .fb, .play > .meta { grid-column: 2; }
  .bottom { max-width: 1040px; }
  .home { max-width: 720px; }
}
.fb-ex { margin-top: 12px; }
/* 웹판 홈 버튼 (2026-10-08) */
.bar:has(.bar-home) { grid-template-columns: auto 1fr auto; column-gap: 10px; }
.bar-home { width: 36px; height: 36px; margin-left: -8px; border: 0; background: none; color: var(--ink); font: inherit; font-size: 20px; font-weight: 800; cursor: pointer; }
.gw-home { display: inline-block; margin: 14px 0 -6px; font-size: 13px; font-weight: 700; color: var(--ink-2); text-decoration: none; }
.gw-home:hover, .bar-home:hover { color: var(--red); }
/* 불러오는 중 창 (2026-10-08) */
.busy { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(0, 0, 0, .28); animation: busy-in .15s ease-out; }
.busy-box { display: grid; justify-items: center; gap: 12px; min-width: 168px; padding: 22px 26px; background: var(--paper); color: var(--ink); border: 2px solid var(--ink); }
.busy-box b { font-weight: 800; letter-spacing: -0.02em; }
.busy-chips { display: flex; gap: 8px; }
.busy-chips i { width: 14px; height: 14px; border-radius: 50%; background: var(--red); animation: busy-chip .9s ease-in-out infinite; }
.busy-chips i:nth-child(2) { background: var(--ink); animation-delay: .15s; }
.busy-chips i:nth-child(3) { animation-delay: .3s; }
@keyframes busy-chip { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-7px); } }
@keyframes busy-in { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) and (hover: hover) and (pointer: fine) { .busy, .busy-chips i { animation: none; } }
