/* Sum Blast 소개 페이지 — 게임과 같은 남색 판 · 크림 글자 · 황토 버튼 */
@font-face {
  font-family: "WinkSoftDigits";
  src: url("../assets/fonts/WinkSoftDigits.ttf") format("truetype");
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0b1730;
  --bg-2: #0e263f;
  --panel: #13294a;
  --panel-2: #1d3354;
  --line: rgba(244, 234, 210, 0.14);
  --cream: #f4ead2;
  --ink: #fffaf0;
  --text: #e9eef6;
  --muted: #b9c5d6;
  --dim: #8d9bb0;
  --ochre: #e3a93f;
  --gold: #f2c766;
  --mission: #fff2d4;
  --radius: 18px;
  --shadow: 0 18px 50px rgba(3, 9, 22, 0.45);
  --font: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", system-ui, -apple-system, "Segoe UI", sans-serif;
  --digits: "WinkSoftDigits", var(--font);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold); }
code { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: .9em; color: var(--cream); background: rgba(255,255,255,.06); padding: .05em .35em; border-radius: 6px; }
h1, h2, h3 { line-height: 1.3; margin: 0; letter-spacing: -0.02em; }
h2 { font-size: clamp(28px, 4.2vw, 42px); color: var(--cream); font-weight: 800; }
h3 { font-size: 19px; color: var(--cream); font-weight: 800; }
p { margin: 0 0 .7em; }
.num { font-family: var(--digits); font-weight: 400; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; padding: 8px 14px; background: var(--cream); color: var(--bg); border-radius: 8px; }
.skip:focus { left: 12px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.wrap { width: min(1120px, 100% - 32px); margin: 0 auto; }

/* ───────── 버튼 ───────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 48px; padding: 0 22px;
  border-radius: 999px; border: 0;
  font: inherit; font-weight: 800; font-size: 16px; text-decoration: none;
  cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-play { background: linear-gradient(180deg, #f4c25a, var(--ochre)); color: #2a1a05; box-shadow: 0 6px 0 #9c6a1c, 0 14px 30px rgba(227, 169, 63, .28); }
.btn-play:active { transform: translateY(3px); box-shadow: 0 3px 0 #9c6a1c; }
.btn-ghost { background: rgba(244, 234, 210, .08); color: var(--cream); box-shadow: inset 0 0 0 2px rgba(244, 234, 210, .35); }
.btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }

/* ───────── 위 메뉴 ───────── */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 18px;
  padding: 10px max(16px, (100% - 1120px) / 2);
  background: rgba(11, 23, 48, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-brand { display: flex; align-items: center; gap: 10px; color: var(--cream); text-decoration: none; font-weight: 800; flex: none; }
.nav-brand img { border-radius: 9px; }
.nav-links { display: flex; gap: 4px; margin-left: auto; overflow-x: auto; scrollbar-width: none; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a { padding: 6px 10px; border-radius: 8px; color: var(--muted); text-decoration: none; font-size: 14px; white-space: nowrap; }
.nav-links a:hover, .nav-links a.on { color: var(--cream); background: rgba(244, 234, 210, .08); }
.nav .btn { flex: none; }

/* 언어 — 두 언어 글이 나란히 있고 html[data-lang]에 맞는 쪽만 보인다(js/i18n.js) */
:root[data-lang="en"] .l-ko, :root[data-lang="ko"] .l-en { display: none !important; }
.lang-switch { flex: none; display: flex; padding: 3px; gap: 2px; background: rgba(244, 234, 210, .07); border: 1px solid var(--line); border-radius: 999px; }
.nav-links + .lang-switch { margin-left: 4px; }
.lang-switch button { min-height: 30px; padding: 0 12px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.lang-switch button:hover { color: var(--cream); }
.lang-switch button[aria-pressed="true"] { background: var(--cream); color: #1b2a44; }

/* ───────── 첫 화면 — 게임 상단 HUD처럼: 가운데 로고 · 그 아래 STAGE 판 · 오른쪽 둥근 메달 ───────── */
.hero { position: relative; overflow: hidden; padding: 34px 0 40px; isolation: isolate; }
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, rgba(11, 23, 48, .12) 0%, rgba(11, 23, 48, .35) 30%, rgba(11, 23, 48, .82) 58%, var(--bg) 100%),
    linear-gradient(90deg, rgba(11, 23, 48, .55) 0%, rgba(11, 23, 48, 0) 60%),
    url("../assets/img/hero-wide.webp") center 22% / cover no-repeat;
}
.title-hud {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "logo medal" "plaque medal";
  align-items: center; column-gap: 14px; width: min(780px, 100%); margin: 0 auto 30px;
}
.title-logo { grid-area: logo; margin: 0; }
.title-logo img { width: 100%; filter: drop-shadow(0 8px 18px rgba(3, 9, 22, .5)); }
.title-plaque {
  grid-area: plaque; justify-self: center; margin: 6px 0 0; padding: 9px 30px 10px;
  background: url("../assets/img/plaque.webp") center / 100% 100% no-repeat;
  color: var(--cream); font-size: 15px; font-weight: 800; letter-spacing: .14em; line-height: 1.2; white-space: nowrap;
  filter: drop-shadow(0 6px 12px rgba(3, 9, 22, .45));
}
:root[data-lang="ko"] .title-plaque { letter-spacing: .08em; }
.title-medal {
  grid-area: medal; display: grid; place-items: center; align-content: center; gap: 0;
  width: 132px; aspect-ratio: 300 / 292;
  background: url("../assets/img/medallion.webp") center / contain no-repeat;
  color: var(--cream); filter: drop-shadow(0 8px 16px rgba(3, 9, 22, .5));
}
.title-medal small { font-size: 12px; font-weight: 700; color: var(--muted); line-height: 1; }
.title-medal b { font-size: 40px; line-height: 1.05; color: var(--ink); }
.title-medal i { font-style: normal; font-size: .55em; color: var(--gold); margin-left: 1px; vertical-align: .55em; }
.hero-inner { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); align-items: center; gap: 32px; }
.eyebrow, .kicker { margin: 0 0 10px; color: var(--gold); font-size: 13px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.tagline { margin: 0 0 8px; font-size: clamp(26px, 3.6vw, 40px); font-weight: 800; color: var(--ink); letter-spacing: -0.02em; text-shadow: 0 2px 14px rgba(3, 9, 22, .6); }
.lead { max-width: 34em; color: var(--muted); font-size: 18px; }
.cta { display: flex; flex-wrap: wrap; gap: 14px; margin: 26px 0 14px; }
.hero-note { color: var(--dim); font-size: 14px; }
.hero-visual { position: relative; justify-self: center; width: min(330px, 100%); }
.phone-hero { transform: rotate(2.5deg); }
.hero-fox { position: absolute; width: 46%; left: -28%; bottom: -4%; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .45)); }

.facts { list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin: 44px 0 0; padding: 0; }
.facts li { padding: 16px 14px; background: rgba(19, 41, 74, .78); border: 1px solid var(--line); border-radius: 16px; text-align: center; backdrop-filter: blur(6px); }
.facts b { display: block; font-size: 38px; line-height: 1.05; color: var(--gold); }
.facts span { color: var(--muted); font-size: 14px; }

/* ───────── 휴대폰 틀 ───────── */
.phone { margin: 0; padding: 7px; background: #070f20; border-radius: 30px; box-shadow: var(--shadow), inset 0 0 0 1px rgba(255, 255, 255, .08); }
.phone img { width: 100%; border-radius: 24px; }
.phone figcaption { padding: 10px 6px 4px; color: var(--dim); font-size: 13px; text-align: center; line-height: 1.4; }
.phone-sm { width: min(250px, 100%); }

/* ───────── 섹션 ───────── */
.section { padding: 96px 0; }
.section-band { background: linear-gradient(180deg, var(--bg-2), #0c2038); border-block: 1px solid rgba(244, 234, 210, .06); }
.section-lead { max-width: 46em; margin: 14px 0 0; color: var(--muted); font-size: 17px; }
.fineprint { color: var(--dim); font-size: 14px; }
.card { padding: 24px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.card p { color: var(--muted); }

/* 소개 */
.pitch {
  margin: 28px 0 36px; padding: 28px 32px;
  font-size: clamp(20px, 2.4vw, 26px); line-height: 1.6; color: var(--ink); font-weight: 600;
  background: linear-gradient(135deg, rgba(242, 199, 102, .12), rgba(242, 199, 102, 0) 60%), var(--panel);
  border-left: 5px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0;
}
.pitch em { font-style: normal; color: var(--gold); }
.pillars { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.pillar { padding: 22px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.pillar h3 { margin-bottom: 10px; font-size: 18px; }
.pillar p { color: var(--muted); margin: 0; font-size: 15px; }

/* 숫자 칸 — 도자기 타일 그림 위에 둥근 숫자 */
.t {
  position: relative; display: inline-grid; place-items: center;
  width: 1.9em; height: 1.9em; vertical-align: middle;
  background: center / 100% 100% no-repeat;
  font-family: var(--digits); color: var(--ink); line-height: 1;
  text-shadow: .045em .045em 0 rgba(12, 26, 43, .55);
}
.t > span { position: relative; font-size: 1.15em; transform: translateY(-.06em); }
.t[data-v="6"] > span::after, .t[data-v="9"] > span::after { content: ""; position: absolute; left: 18%; right: 18%; bottom: -.06em; height: .1em; border-radius: 1em; background: currentColor; box-shadow: .045em .045em 0 rgba(12, 26, 43, .55); }
.t.is-mission { box-shadow: 0 0 0 .14em var(--mission); border-radius: .32em; }
.t-broke { background: radial-gradient(circle, #5b2430, #2a1420); border-radius: .32em; color: #ffb4a8; }
.t[data-v="0"] { background-image: url("../assets/tiles/t0.webp"); }
.t[data-v="1"] { background-image: url("../assets/tiles/t1.webp"); }
.t[data-v="2"] { background-image: url("../assets/tiles/t2.webp"); }
.t[data-v="3"] { background-image: url("../assets/tiles/t3.webp"); }
.t[data-v="4"] { background-image: url("../assets/tiles/t4.webp"); }
.t[data-v="5"] { background-image: url("../assets/tiles/t5.webp"); }
.t[data-v="6"] { background-image: url("../assets/tiles/t6.webp"); }
.t[data-v="7"] { background-image: url("../assets/tiles/t7.webp"); }
.t[data-v="8"] { background-image: url("../assets/tiles/t8.webp"); }
.t[data-v="9"] { background-image: url("../assets/tiles/t9.webp"); }
.eq { display: inline-flex; align-items: center; gap: 8px; font-size: 24px; color: var(--cream); font-family: var(--digits); }

/* 한 수의 흐름 */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; margin: 40px 0 0; padding: 0; }
.step { display: flex; flex-direction: column; gap: 18px; }
.step .phone { width: 100%; }
.step-no { display: inline-grid; place-items: center; width: 34px; height: 34px; margin-bottom: 8px; border-radius: 50%; background: var(--gold); color: #2a1a05; font-family: var(--digits); font-size: 20px; }
.step h3 { margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 15px; }
.callout { margin-top: 44px; padding: 26px 30px; background: var(--panel); border: 1px dashed rgba(244, 234, 210, .28); border-radius: var(--radius); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 28px; align-items: center; }
.callout h3 { grid-column: 1 / -1; margin-bottom: 4px; }
.callout p { margin: 0; color: var(--muted); }
.eq-row { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 14px; }
.eq-note { color: var(--dim); font-size: 14px; }

/* 데모 */
.demo-wrap { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 44px; align-items: center; }
.demo-copy > p { color: var(--muted); }
.demo-copy h2 { margin-bottom: 16px; }
.demo-rules { margin: 18px 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.demo-rules li { padding: 10px 14px; background: var(--panel); border-radius: 12px; color: var(--muted); font-size: 15px; }
.demo-rules b { color: var(--cream); margin-right: 6px; }
.demo-note { font-size: 14px; color: var(--dim) !important; margin-bottom: 20px; }
.demo { display: grid; gap: 12px; justify-items: center; }
.demo-hud { width: min(460px, 100%); display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; }
.demo-hud > div { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 58px; padding: 6px 10px; background: var(--panel-2); border: 2px solid rgba(244, 234, 210, .16); border-radius: 16px; }
.demo-hud small { color: var(--muted); font-size: 12px; }
.demo-hud b { font-size: 26px; color: var(--ink); line-height: 1; }
.hud-mission .t { font-size: 15px; }
.hud-mission.bump { animation: bump .35s ease; }
.hud-moves, .hud-score { flex-direction: column; gap: 0 !important; }
.demo-stage { position: relative; width: min(460px, 100%); }
.demo-board {
  position: relative; width: 100%; aspect-ratio: 1;
  touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab;
  background:
    linear-gradient(var(--bg-2), var(--bg-2)) padding-box,
    linear-gradient(160deg, #3a5f9b, #1d3a6c 40%, #2b4f88) border-box;
  border: 10px solid transparent; border-radius: 22px;
  box-shadow: var(--shadow), inset 0 0 0 2px rgba(0, 0, 0, .25);
}
.demo-board.nudge { animation: nudge .25s ease; }
.demo.busy .demo-board, .demo .demo-board:active { cursor: grabbing; }
.tile, .q { position: absolute; left: 0; top: 0; display: grid; place-items: center; font-family: var(--digits); color: var(--ink); line-height: 1; text-shadow: .045em .045em 0 rgba(12, 26, 43, .55); background: center / 100% 100% no-repeat; }
.tile { width: calc(var(--u) * .94); height: calc(var(--u) * .94); margin: calc(var(--u) * .03); font-size: calc(var(--u) * .56); transition: transform .22s cubic-bezier(.3, .7, .3, 1), opacity .22s ease; will-change: transform; }
.tile > span, .q > span { position: relative; transform: translateY(-.05em); }
.tile[data-v="6"] > span::after, .tile[data-v="9"] > span::after, .q[data-v="6"] > span::after, .q[data-v="9"] > span::after { content: ""; position: absolute; left: 14%; right: 14%; bottom: -.04em; height: .09em; border-radius: 1em; background: currentColor; }
.tile.is-mission::before { content: ""; position: absolute; inset: -2px; border-radius: 22%; box-shadow: 0 0 0 3px var(--mission); }
.tile.enter { opacity: 0; }
.tile.absorb { opacity: 0; z-index: 0; }
.tile.bump { animation: bump .25s ease; }
.tile.saved { animation: saved .4s ease; }
.tile.broke { animation: broke .35s ease; }
.tile.lit { z-index: 2; filter: brightness(1.18); transform-origin: center; }
.tile.lit::after { content: ""; position: absolute; inset: -3px; border-radius: 24%; box-shadow: 0 0 0 3px var(--ink), 0 0 18px rgba(255, 242, 212, .8); }
.tile.combo::after { box-shadow: 0 0 0 3px #ffd166, 0 0 18px rgba(255, 209, 102, .8); }
.tile.pop { animation: pop .3s ease forwards; }
.q { width: calc(var(--u) * .42); height: calc(var(--u) * .42); font-size: calc(var(--u) * .26); filter: brightness(.72) saturate(.75); border-radius: 6px; }
.q[data-v="0"], .tile[data-v="0"] { background-image: url("../assets/tiles/t0.webp"); }
.q[data-v="1"], .tile[data-v="1"] { background-image: url("../assets/tiles/t1.webp"); }
.q[data-v="2"], .tile[data-v="2"] { background-image: url("../assets/tiles/t2.webp"); }
.q[data-v="3"], .tile[data-v="3"] { background-image: url("../assets/tiles/t3.webp"); }
.q[data-v="4"], .tile[data-v="4"] { background-image: url("../assets/tiles/t4.webp"); }
.q[data-v="5"], .tile[data-v="5"] { background-image: url("../assets/tiles/t5.webp"); }
.q[data-v="6"], .tile[data-v="6"] { background-image: url("../assets/tiles/t6.webp"); }
.q[data-v="7"], .tile[data-v="7"] { background-image: url("../assets/tiles/t7.webp"); }
.q[data-v="8"], .tile[data-v="8"] { background-image: url("../assets/tiles/t8.webp"); }
.q[data-v="9"], .tile[data-v="9"] { background-image: url("../assets/tiles/t9.webp"); }
.band { position: absolute; left: 0; top: 0; z-index: 1; pointer-events: none; border-radius: 12px; background: rgba(255, 209, 102, .2); box-shadow: inset 0 0 0 2px rgba(255, 209, 102, .55); }
.band.blocked { background: rgba(255, 114, 114, .18); box-shadow: inset 0 0 0 2px rgba(255, 114, 114, .6); }
.chip { position: absolute; left: 0; top: 0; z-index: 4; pointer-events: none; min-width: calc(var(--u) * .4); height: calc(var(--u) * .4); padding: 0 .3em; display: grid; place-items: center; border-radius: 999px; background: #0b1730; color: var(--cream); font-family: var(--digits); font-size: calc(var(--u) * .27); box-shadow: 0 0 0 2px rgba(244, 234, 210, .5); }
.chip.hit { background: var(--gold); color: #2a1a05; box-shadow: 0 0 0 2px #fff2d4, 0 0 14px rgba(242, 199, 102, .9); }
.chip.broke { background: #5b2430; color: #ffb4a8; box-shadow: 0 0 0 2px rgba(255, 140, 120, .6); }
.float { position: absolute; z-index: 5; pointer-events: none; transform: translate(-50%, 0); padding: 2px 10px; border-radius: 999px; background: rgba(11, 23, 48, .85); color: var(--cream); font-weight: 800; font-size: 14px; white-space: nowrap; animation: float .9s ease forwards; }
.float.warn { color: #ffb4a8; }
.demo-toast { position: absolute; left: 50%; top: 10px; z-index: 6; transform: translate(-50%, -6px); opacity: 0; pointer-events: none; text-align: center; }
.demo-toast b { display: block; font-family: var(--digits); font-size: 34px; color: #ffd166; text-shadow: 0 3px 0 #7a4b10, 0 0 22px rgba(255, 209, 102, .6); line-height: 1.1; }
.demo-toast small { display: inline-block; margin-top: 2px; padding: 2px 10px; border-radius: 999px; background: rgba(11, 23, 48, .85); color: var(--cream); font-size: 13px; font-weight: 700; }
.demo-toast.show { animation: toast 1.1s ease forwards; }
.demo-hint { position: absolute; left: 50%; bottom: -14px; transform: translate(-50%, 100%); opacity: 0; transition: opacity .3s; color: var(--gold); font-size: 14px; font-weight: 700; white-space: nowrap; pointer-events: none; }
.demo-hint.show { opacity: 1; animation: hint 1.6s ease-in-out infinite; }
.demo-over { position: absolute; inset: 0; z-index: 8; display: grid; place-items: center; background: rgba(5, 11, 24, .62); border-radius: 22px; backdrop-filter: blur(2px); }
.demo-over[hidden] { display: none; }
.demo-over-card { width: min(300px, 86%); padding: 24px; text-align: center; background: var(--panel-2); border: 2px solid rgba(244, 234, 210, .3); border-radius: 20px; box-shadow: var(--shadow); }
.demo-over-card p { color: var(--muted); }
.demo-over-title { font-size: 30px; font-weight: 800; color: var(--cream) !important; margin-bottom: 4px; }
.demo-over.is-clear .demo-over-title { color: var(--gold) !important; }
.demo-reset { margin-top: 26px; }

@keyframes bump { 50% { scale: 1.12; } }
@keyframes saved { 40% { filter: brightness(1.5); box-shadow: 0 0 22px rgba(255, 242, 212, .9); } }
@keyframes broke { 0% { filter: brightness(2) saturate(0); } 100% { filter: none; } }
@keyframes pop { 0% { opacity: 1; scale: 1; } 40% { opacity: 1; scale: 1.18; } 100% { opacity: 0; scale: .2; } }
@keyframes float { 0% { opacity: 0; translate: 0 6px; } 20% { opacity: 1; translate: 0 0; } 100% { opacity: 0; translate: 0 -26px; } }
@keyframes toast { 0% { opacity: 0; transform: translate(-50%, 8px) scale(.9); } 15% { opacity: 1; transform: translate(-50%, 0) scale(1.05); } 75% { opacity: 1; transform: translate(-50%, 0) scale(1); } 100% { opacity: 0; transform: translate(-50%, -8px); } }
@keyframes hint { 50% { translate: 0 4px; } }
@keyframes nudge { 25% { translate: -5px 0; } 75% { translate: 5px 0; } }

/* 콤보 */
.combo-grid { display: grid; grid-template-columns: 1fr 1fr minmax(0, 250px); gap: 20px; margin-top: 36px; align-items: start; }
.shape-card { display: flex; flex-direction: column; gap: 12px; }
.shape-card h3 { margin-top: 6px; }
.shape-card p { margin: 0; }
.mini { display: flex; gap: 6px; font-size: 26px; }
.mini-block { display: grid; grid-template-columns: repeat(2, max-content); gap: 6px; }
.mini .t { box-shadow: 0 0 0 .1em #ffd166; border-radius: .32em; }
.combo-shot { justify-self: end; }
.bonus { margin-top: 40px; padding: 26px 28px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.bonus h3 { font-size: 17px; margin-bottom: 18px; }
.bonus-bars { list-style: none; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; align-items: end; height: 190px; margin: 0 0 12px; padding: 0; }
.bonus-bars li { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; height: 100%; }
.bonus-bars li::before { content: ""; order: 1; width: 100%; max-width: 64px; height: calc(var(--h) / 14 * 120px); border-radius: 10px 10px 4px 4px; background: linear-gradient(180deg, #ffd166, #e3a93f); }
.bonus-bars b { order: 0; font-family: var(--digits); font-weight: 400; color: var(--gold); font-size: 20px; line-height: 1; }
.bonus-bars span { order: 2; color: var(--muted); font-size: 13px; white-space: nowrap; }

/* 스페셜 */
.specials { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 36px 0 0; padding: 0; }
.special { display: flex; align-items: center; gap: 12px; padding: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.special img { width: 84px; height: 84px; flex: none; }
.special h3 { font-size: 16px; }
.special p { margin: 2px 0 4px; color: var(--muted); font-size: 14px; line-height: 1.45; }
.special small { color: var(--dim); font-size: 12px; }
.fusion { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr) minmax(0, 250px); gap: 26px; align-items: center; margin-top: 40px; padding: 28px; background: linear-gradient(135deg, rgba(199, 146, 255, .12), transparent 60%), var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.fusion h3 { font-size: 22px; margin-bottom: 6px; }
.fusion h3 em { font-style: normal; color: #d9b8ff; }
.fusion-copy > p { color: var(--muted); }
.fusion-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; }
.fusion-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 12px; padding: 10px 14px; background: rgba(11, 23, 48, .55); border-radius: 12px; }
.fusion-list span { color: var(--muted); font-size: 14px; }
.fusion-list b { color: var(--cream); font-size: 15px; text-align: right; }
.fusion-list small { grid-column: 1 / -1; color: var(--dim); font-size: 13px; }
.fusion-art { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.fusion-art li { display: grid; justify-items: center; gap: 2px; }
.fusion-art li:first-child { grid-column: 1 / -1; }
.fusion-art img { width: 110px; }
.fusion-art span { color: var(--muted); font-size: 13px; }

/* 방해물 */
.obstacles { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 36px 0 0; padding: 0; }
.obstacles li { padding: 18px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.obstacles img { width: 72px; height: 72px; margin-bottom: 10px; }
.obstacles h3 { font-size: 17px; margin-bottom: 4px; }
.obstacles h3 small { color: var(--gold); font-size: 13px; font-weight: 700; margin-left: 4px; }
.obstacles p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; }
.more-mark { flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; border: 2px dashed rgba(242, 199, 102, .55); color: var(--gold); font-family: var(--digits); font-size: 34px; line-height: 1; }
.obstacles .more { grid-column: 1 / -1; display: flex; align-items: center; gap: 18px; background: transparent; border: 2px dashed rgba(242, 199, 102, .35); }

/* 모험 */
.chapters { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin: 36px 0 0; padding: 0; }
.chapter { position: relative; overflow: hidden; min-height: 300px; display: flex; align-items: flex-end; border-radius: var(--radius); border: 1px solid var(--line); isolation: isolate; }
.chapter img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .5s ease; }
.chapter:hover img { transform: scale(1.04); }
.chapter::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(11, 23, 48, 0) 20%, rgba(11, 23, 48, .92) 72%); }
.chapter > div { padding: 22px; }
.ch-no { margin: 0 0 2px; color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: .1em; }
.chapter h3 { font-size: 24px; margin-bottom: 6px; }
.chapter p { color: var(--text); font-size: 14px; margin-bottom: 8px; }
.chapter small { display: inline-block; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--accent) 22%, transparent); color: var(--accent); font-size: 12px; font-weight: 700; }
.chapter.is-next { grid-column: 1 / -1; min-height: 0; align-items: center; gap: 4px; padding-left: 22px; border: 2px dashed rgba(242, 199, 102, .4); background: radial-gradient(circle at 12% 50%, rgba(242, 199, 102, .1), transparent 55%); --accent: var(--gold); }
.chapter.is-next::after { display: none; }
.chapter.is-next p:not(.ch-no) { color: var(--muted); margin: 0; }
.maps { display: flex; justify-content: center; gap: 22px; margin-top: 44px; flex-wrap: wrap; }
.balance { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr) minmax(0, 1fr); gap: 28px; margin-top: 48px; padding: 28px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); align-items: center; }
.balance h3 { margin-bottom: 10px; }
.balance p { color: var(--muted); margin: 0; }
.curve { width: 100%; border-collapse: collapse; font-size: 15px; }
.curve th { text-align: left; color: var(--dim); font-weight: 700; font-size: 13px; padding: 4px 8px; border-bottom: 1px solid var(--line); }
.curve td { padding: 7px 8px; border-bottom: 1px solid rgba(244, 234, 210, .07); color: var(--text); font-variant-numeric: tabular-nums; }
.curve td:last-child, .curve th:last-child { text-align: right; }
.curve td:last-child { color: var(--gold); font-weight: 700; }
.stars-rule { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; color: var(--muted); font-size: 14px; }
.stars-rule li { display: flex; align-items: center; gap: 12px; }
.stars { flex: none; width: 66px; color: var(--gold); font-size: 18px; letter-spacing: 1px; }
.stars i { font-style: normal; color: rgba(244, 234, 210, .3); }

/* 여우 */
.fox-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.fox-copy p { color: var(--muted); }
.fox-copy h2 { margin-bottom: 18px; }
.fox-rule { padding: 14px 18px; background: var(--panel); border-radius: 14px; color: var(--cream) !important; }
.fox-poses { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 0; }
.fox-poses li { display: grid; justify-items: center; gap: 6px; padding: 14px 8px 10px; background: radial-gradient(circle at 50% 40%, rgba(242, 199, 102, .16), transparent 70%), var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.fox-poses img { height: 118px; width: auto; }
.fox-poses span { color: var(--muted); font-size: 13px; }

/* 배우는 방식 */
.principles { list-style: none; counter-reset: p; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 36px 0 0; padding: 0; }
.principles li { counter-increment: p; position: relative; padding: 22px 22px 22px 64px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.principles li::before { content: counter(p); position: absolute; left: 20px; top: 20px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: rgba(242, 199, 102, .16); color: var(--gold); font-family: var(--digits); font-size: 18px; }
.principles b { display: block; color: var(--cream); margin-bottom: 4px; }
.principles span { color: var(--muted); font-size: 14px; line-height: 1.55; display: block; }

/* 아트 */
.art-grid { display: grid; grid-template-columns: minmax(0, 250px) minmax(0, 250px) minmax(0, 1fr); gap: 24px; margin-top: 36px; align-items: center; }
.art-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.art-points li { padding: 14px 18px; background: var(--panel); border-radius: 14px; color: var(--muted); font-size: 15px; }
.art-points b { color: var(--cream); }
.palette { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 40px 0 0; font-size: 26px; }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 40px; }
.duo h3 { margin-bottom: 10px; }
.duo p { margin: 0; }


/* 마무리 · 바닥 */
.outro { padding: 80px 0; background: linear-gradient(0deg, rgba(11, 23, 48, .9), rgba(11, 23, 48, .65)), url("../assets/chapters/ch6.webp") center / cover; }
.outro-inner { display: flex; align-items: center; justify-content: center; gap: 36px; flex-wrap: wrap; text-align: left; }
.outro-inner img { width: 200px; }
.outro h2 { margin-bottom: 10px; }
.outro p { color: var(--muted); margin-bottom: 22px; }
.footer { padding: 36px 0 48px; border-top: 1px solid var(--line); color: var(--dim); font-size: 14px; text-align: center; }
.footer p { margin: 4px 0; }
.footer b { color: var(--cream); }

/* 나타나기 */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ───────── 좁은 화면 ───────── */
@media (max-width: 1020px) {
  .nav-links { display: none; }
  .lang-switch { margin-left: auto; }
  .pillars, .specials, .obstacles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .combo-grid { grid-template-columns: 1fr 1fr; }
  .combo-shot { grid-column: 1 / -1; justify-self: center; }
  .fusion { grid-template-columns: minmax(0, 1fr) minmax(0, 220px); }
  .fusion-art { display: none; }
  .chapters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .balance { grid-template-columns: 1fr 1fr; }
  .balance > div { grid-column: 1 / -1; }
  .principles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .art-grid { grid-template-columns: 1fr 1fr; justify-items: center; }
  .art-points { grid-column: 1 / -1; }
  .demo-wrap { grid-template-columns: 1fr; gap: 32px; }
}

@media (max-width: 720px) {
  body { font-size: 15px; }
  .section { padding: 68px 0; }
  .hero { padding-top: 22px; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-bg { background: linear-gradient(180deg, rgba(11, 23, 48, .1) 0, rgba(11, 23, 48, .5) 130px, rgba(11, 23, 48, .9) 320px, var(--bg) 500px), url("../assets/img/hero-wide.webp") center top / auto 520px no-repeat, var(--bg); }
  .title-hud { column-gap: 8px; margin-bottom: 24px; }
  .title-medal { width: 78px; }
  .title-medal small { font-size: 9px; }
  .title-medal b { font-size: 24px; }
  .title-plaque { font-size: 12px; padding: 7px 18px 8px; letter-spacing: .1em; }
  .hero-visual { width: min(260px, 72%); margin-top: 10px; }
  .hero-fox { left: -30%; width: 52%; }
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .facts li { padding: 12px 6px; }
  .facts b { font-size: 30px; }
  .facts span { font-size: 12px; }
  .pillars, .specials, .principles, .duo { grid-template-columns: 1fr; }
  .obstacles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .obstacles li { padding: 14px; }
  .obstacles img { width: 56px; height: 56px; }
  .steps { grid-template-columns: 1fr; gap: 36px; }
  .step { flex-direction: row; align-items: center; gap: 16px; }
  .step .phone { width: 42%; flex: none; }
  .callout { grid-template-columns: 1fr; padding: 22px; }
  .combo-grid { grid-template-columns: 1fr; }
  .fusion { grid-template-columns: 1fr; padding: 22px; }
  .fusion .phone { justify-self: center; }
  .chapters { grid-template-columns: 1fr; }
  .chapter { min-height: 240px; }
  .maps .phone { width: calc(50% - 12px); }
  .balance { grid-template-columns: 1fr; padding: 22px; }
  .fox-wrap { grid-template-columns: 1fr; }
  .art-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .bonus { padding: 22px 16px; }
  .bonus-bars { gap: 6px; height: 170px; }
  .bonus-bars b { font-size: 15px; }
  .bonus-bars span { font-size: 11px; white-space: normal; text-align: center; line-height: 1.2; }
  .pitch { padding: 22px; }
  .outro-inner { text-align: center; }
  .outro-inner img { width: 150px; }
}

@media (max-width: 420px) {
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts li:last-child { grid-column: 1 / -1; }
  .nav-brand span { display: none; }
  .nav { gap: 10px; }
  .lang-switch button { padding: 0 9px; }
  .demo-hud b { font-size: 22px; }
  .demo-hud small { font-size: 11px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
