/* ═══════════════════════════════════════════════════════════
   2410 초성 센터 — "원고지 자모 표본" 디자인
   · 출발점: kit-luxury 의 헤어라인 프레임·세리프 제목·모서리 절제만 가져왔다
     (다크 골드·블러 헤더·그라디언트 배경은 전부 버림 — 기피 디자인 §6)
   · 모티프: 원고지 칸. 초성은 테두리를 공유하는 원고지 칸 안에 명조체로 앉는다
   · 색: 종이 흰색 + 먹색 잉크 + 원고지 녹색 1색 액센트. 면은 평면, 그림자 없음
   · 구조: 데스크톱은 왼쪽 도구 목록(색인) + 오른쪽 작업대, 모바일은 2×2 도구 칸
═══════════════════════════════════════════════════════════ */
:root {
  --bg: #F6F5F1;
  --surface: #FFFFFF;
  --surface-2: #EEEDE7;
  --ink: #17201C;
  --ink-2: #4A544F;
  --ink-3: #7D8581;
  --rule: #D5D9D2;          /* 기본 괘선 */
  --rule-strong: #A9B2AC;   /* 입력칸·버튼 테두리 */
  --cell: #9CC3AF;          /* 원고지 칸 선 */
  --accent: #1D6A50;        /* 원고지 녹색 */
  --accent-ink: #FFFFFF;
  --accent-soft: #E3EFE8;
  --ok: #1D6A50;
  --bad: #B3261E;
  --r: 4px;
  --font: 'IBM Plex Sans KR', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
  --font-serif: 'Noto Serif KR', 'AppleMyungjo', 'Batang', serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #111614;
  --surface: #181E1B;
  --surface-2: #202824;
  --ink: #E6ECE8;
  --ink-2: #B2BCB6;
  --ink-3: #7F8A84;
  --rule: #2B3530;
  --rule-strong: #46524B;
  --cell: #3E6B56;
  --accent: #6CC39F;
  --accent-ink: #0E1512;
  --accent-soft: #1C3229;
  --ok: #6CC39F;
  --bad: #FF8A80;
  color-scheme: dark;
}
[hidden] { display: none !important; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.7;
  -webkit-font-smoothing: antialiased; word-break: keep-all; overflow-wrap: anywhere;
  min-height: 100vh; display: flex; flex-direction: column;
}
a { color: var(--accent); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ── header ── */
.site-header { border-bottom: 1px solid var(--rule); background: var(--surface); position: sticky; top: 0; z-index: 30; }
.header-inner { max-width: 1120px; margin: 0 auto; padding: 0 16px; height: 64px; display: flex; align-items: center; gap: 14px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); flex-shrink: 0; }
.brand-mark { display: inline-flex; }
.brand-mark span { width: 24px; height: 24px; border: 1px solid var(--accent); display: inline-grid; place-items: center;
  font: 600 14px/1 var(--font-serif); color: var(--accent); background: var(--surface); }
.brand-mark span + span { margin-left: -1px; }
.brand-mark span:first-child { background: var(--accent); color: var(--accent-ink); }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-family: var(--font-serif); font-weight: 700; font-size: 20px; letter-spacing: -0.2px; }
.brand-sub { font-size: 11.5px; color: var(--ink-3); letter-spacing: 0.4px; }
.nav { display: flex; align-items: stretch; gap: 4px; margin-left: auto; align-self: stretch; }
.nav a { color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: 15px; padding: 0 12px; display: inline-flex; align-items: center;
  border-bottom: 2px solid transparent; margin-bottom: -1px; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--accent); }
.icon-btn { width: 36px; height: 36px; border-radius: var(--r); border: 1px solid var(--rule-strong); background: var(--surface); cursor: pointer;
  display: inline-grid; place-items: center; margin-left: 4px; }
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 17px; height: 17px; }
@media (max-width: 760px) {
  .header-inner { height: auto; flex-wrap: wrap; padding: 10px 16px 0; row-gap: 4px; }
  .brand-sub { display: none; }
  .nav { order: 3; width: calc(100% + 16px); margin: 0 -8px; overflow-x: auto; scrollbar-width: none; align-self: auto; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { font-size: 14.5px; padding: 8px 10px 9px; white-space: nowrap; }
  .theme-slot { margin-left: auto; }
}

/* ── layout ── */
main { flex: 1; width: 100%; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 24px 16px 44px; }
.narrow { max-width: 780px; }

/* ── 도구: 색인(왼쪽) + 작업대(오른쪽) ── */
.tool-layout { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 960px) { .tool-layout { grid-template-columns: 236px minmax(0, 1fr); gap: 28px; align-items: start; } }
.tool-side { display: flex; flex-direction: column; gap: 14px; }
@media (min-width: 960px) { .tool-side { position: sticky; top: 88px; } }
.side-title { display: none; font-size: 12px; font-weight: 600; letter-spacing: 1.5px; color: var(--ink-3); margin: 0 0 2px; }
@media (min-width: 960px) { .side-title { display: block; } }
.tabs { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--rule); background: var(--surface); }
.tab { border: 0; background: transparent; padding: 11px 12px; cursor: pointer; text-align: left; display: flex; align-items: center; gap: 10px;
  font-weight: 600; font-size: 15px; line-height: 1.3; border-bottom: 1px solid var(--rule); color: var(--ink-2); position: relative; min-height: 52px; }
.tab:nth-child(odd) { border-right: 1px solid var(--rule); }
.tab:nth-child(n+3) { border-bottom: 0; }
.tab .tab-no { font: 600 12px/1 var(--font); color: var(--ink-3); letter-spacing: 0.5px; min-width: 18px; font-variant-numeric: tabular-nums; }
.tab .tab-t { display: block; }
.tab .tab-desc { display: none; font-weight: 400; font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.tab:hover { color: var(--ink); background: var(--surface-2); }
.tab[aria-selected="true"] { color: var(--ink); background: var(--accent-soft); }
.tab[aria-selected="true"]::before { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--accent); }
.tab[aria-selected="true"] .tab-no { color: var(--accent); }
@media (min-width: 960px) {
  .tabs { grid-template-columns: 1fr; }
  .tab { border-right: 0 !important; border-bottom: 1px solid var(--rule) !important; padding: 14px 16px 14px 14px; align-items: flex-start; }
  .tab:last-child { border-bottom: 0 !important; }
  .tab .tab-no { padding-top: 3px; }
  .tab .tab-desc { display: block; }
  .tab[aria-selected="true"]::before { left: 0; top: -1px; bottom: -1px; right: auto; width: 3px; height: auto; }
}
.side-note { display: none; border-top: 1px solid var(--rule); padding-top: 12px; font-size: 13px; color: var(--ink-2); line-height: 1.6; }
.side-note p { margin: 0 0 8px; }
.side-note b { font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
@media (min-width: 960px) { .side-note { display: block; } }

.panel { border: 1px solid var(--rule); background: var(--surface); padding: 22px 24px 24px; }
@media (max-width: 560px) { .panel { padding: 16px 14px 18px; } }
.panel-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px;
  border-bottom: 1px solid var(--rule); padding-bottom: 12px; margin-bottom: 18px; }
.panel-head h2 { margin: 0; font-family: var(--font-serif); font-weight: 700; font-size: 22px; letter-spacing: -0.3px; }
.panel-head p { margin: 0; font-size: 13.5px; color: var(--ink-3); }
.panel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 820px) { .panel-grid { grid-template-columns: 1fr; gap: 14px; } }
.field-label { font-weight: 600; font-size: 13.5px; color: var(--ink-2); display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; gap: 8px; }
.field-label small { font-weight: 400; color: var(--ink-3); font-size: 12.5px; }
textarea, input[type="text"], input[type="number"], select {
  width: 100%; border: 1px solid var(--rule-strong); background: var(--surface); border-radius: var(--r);
  padding: 11px 13px; outline: none; font-size: 16px;
}
textarea:focus, input:focus, select:focus { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
textarea { resize: vertical; min-height: 170px; line-height: 1.65; }
.out-box { min-height: 170px; border: 1px solid var(--rule); border-left: 3px solid var(--accent); padding: 12px 14px; background: var(--bg);
  font-family: var(--font-serif); font-weight: 600; font-size: 26px; line-height: 1.55; letter-spacing: 3px; white-space: pre-wrap; word-break: break-all; }
.out-box.empty { font-family: var(--font); font-weight: 400; font-size: 15px; color: var(--ink-3); letter-spacing: 0; border-left-color: var(--rule-strong); }
.opts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--rule); }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.row.end { justify-content: flex-end; }

/* 칩 — 단독(토글)·세그먼트(연결형) 공용 */
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--rule-strong); border-radius: var(--r); padding: 6px 12px;
  font-size: 14px; font-weight: 500; cursor: pointer; background: var(--surface); user-select: none; color: var(--ink-2); line-height: 1.35; }
.chip:hover { border-color: var(--ink-2); color: var(--ink); }
.chip input { accent-color: var(--accent); margin: 0; }
.chip.on { border-color: var(--accent); background: var(--accent); color: var(--accent-ink); }
.seg.row { display: inline-flex; flex-wrap: nowrap; gap: 0; }
.seg .chip { border-radius: 0; }
.seg .chip + .chip { margin-left: -1px; }
.seg .chip:first-child { border-radius: var(--r) 0 0 var(--r); }
.seg .chip:last-child { border-radius: 0 var(--r) var(--r) 0; }
.seg .chip.on { position: relative; z-index: 1; background: var(--ink); border-color: var(--ink); color: var(--bg); }

.btn { border: 1px solid var(--rule-strong); background: var(--surface); border-radius: var(--r); padding: 9px 15px; font-weight: 600; cursor: pointer;
  display: inline-flex; align-items: center; gap: 7px; font-size: 15px; text-decoration: none; color: var(--ink); line-height: 1.25; }
.btn:hover { border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.primary:hover { background: color-mix(in srgb, var(--accent) 88%, var(--ink)); }
.btn.dark { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.sm { padding: 6px 11px; font-size: 14px; }
.btn svg { width: 16px; height: 16px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.stat-line { font-size: 13px; color: var(--ink-3); margin-top: 8px; }

/* ── 초성 = 원고지 칸 ── */
.tiles { display: flex; flex-wrap: wrap; gap: 0.35em 0.5em; justify-content: center; }
.tword { display: inline-flex; flex-wrap: nowrap; }
.tile { width: 1.8em; height: 1.8em; border: 1px solid var(--cell); display: inline-grid; place-items: center;
  font-family: var(--font-serif); font-weight: 600; background: var(--surface); line-height: 1; color: var(--ink); }
.tile + .tile { margin-left: -1px; }
.tile.open { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); position: relative; z-index: 1; }
.tile.raw { color: var(--ink-3); background: transparent; }

/* ── 퀴즈 만들기 ── */
.q-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0; margin-top: 16px; border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.q-card { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 14px; background: var(--surface); display: flex; flex-direction: column; gap: 10px; }
.q-card .q-no { font-size: 12.5px; font-weight: 600; letter-spacing: 0.5px; color: var(--ink-3); display: flex; justify-content: space-between; font-variant-numeric: tabular-nums; }
.q-card .tiles { font-size: 19px; min-height: 48px; align-items: center; }
.q-hints { display: flex; flex-wrap: wrap; gap: 5px; min-height: 26px; }
.hint-pill { font-size: 13px; background: var(--surface-2); border: 1px solid var(--rule); border-radius: var(--r); padding: 1px 9px; font-weight: 500; color: var(--ink-2); }
.q-answer { font-family: var(--font-serif); font-weight: 700; font-size: 19px; text-align: center; color: var(--accent); }
.q-actions { display: flex; gap: 6px; margin-top: auto; }
.q-actions .btn { flex: 1; justify-content: center; }
.share-box { display: flex; gap: 8px; margin-top: 12px; }
.share-box input { font-size: 13px; background: var(--bg); }
#mkEditor > summary { list-style: none; padding: 2px 0 10px; justify-content: flex-start; }
#mkEditor > summary::-webkit-details-marker { display: none; }
#mkEditor > summary::before { content: '▾'; margin-right: 6px; color: var(--ink-3); }
#mkEditor:not([open]) > summary::before { content: '▸'; }
.mk-bar { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--rule); justify-content: space-between; }
.mk-count { font-family: var(--font-serif); font-size: 18px; font-weight: 700; }

/* ── 단어 찾기 ── */
.find-input { font-family: var(--font-serif) !important; font-weight: 600; font-size: 30px !important; letter-spacing: 4px; padding: 12px 16px !important; }
.cat-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 4px; }
.cat-chips .chip { padding: 5px 11px; }
.results { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 0; margin-top: 14px; border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.res { border: 0; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 9px 12px; background: var(--surface); cursor: pointer; text-align: left; min-width: 0; }
.res:hover { background: var(--accent-soft); }
.res b { font-size: 16.5px; font-weight: 600; display: block; line-height: 1.35; }
.res.exact b::after { content: ''; display: inline-block; width: 6px; height: 6px; background: var(--accent); margin-left: 6px; vertical-align: 3px; }
.res small { color: var(--ink-3); font-size: 12.5px; display: block; line-height: 1.4; }
.res-meta { font-size: 14px; color: var(--ink-2); margin-top: 14px; }
.res-detail { margin-top: 12px; border: 1px solid var(--rule); border-left: 3px solid var(--accent); padding: 14px 16px; background: var(--bg); }
.res-detail h3 { margin: 0 0 4px; font-family: var(--font-serif); font-weight: 700; font-size: 24px; }

/* ── 바로 풀기 ── */
.play-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; align-items: center; }
.score { display: flex; border: 1px solid var(--rule); }
.score div { padding: 5px 12px; text-align: center; min-width: 72px; }
.score div + div { border-left: 1px solid var(--rule); }
.score b { display: block; font-family: var(--font-serif); font-size: 21px; font-weight: 700; line-height: 1.25; font-variant-numeric: tabular-nums; }
.score span { font-size: 11.5px; color: var(--ink-3); }
@media (max-width: 480px) { .score { width: 100%; } .score div { flex: 1; min-width: 0; padding: 5px 4px; } }
.play-stage { text-align: center; padding: 28px 0 8px; margin-top: 14px; border-top: 1px solid var(--rule); }
.play-stage .tiles { font-size: clamp(24px, 7vw, 44px); }
.play-hint { min-height: 30px; margin: 16px 0 4px; display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.play-form { display: flex; gap: 8px; max-width: 520px; margin: 12px auto 0; }
.play-form input { font-size: 20px; text-align: center; flex: 1; min-width: 0; }
.play-form .btn { flex-shrink: 0; white-space: nowrap; }
.feedback { min-height: 28px; margin-top: 10px; font-weight: 600; }
.feedback.ok { color: var(--ok); } .feedback.bad { color: var(--bad); }

/* ── 발표 모드 ── */
.stage-overlay { position: fixed; inset: 0; z-index: 100; background: var(--bg); display: flex; flex-direction: column; }
.stage-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 20px; border-bottom: 1px solid var(--rule); background: var(--surface); }
.stage-title { font-family: var(--font-serif); font-weight: 700; font-size: 20px; }
.stage-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px; text-align: center; padding: 20px; }
.stage-body .tiles { font-size: clamp(30px, 8vw, 110px); }
.stage-body > div, .play-stage > div { max-width: 100%; }
.stage-body .tile { border-width: 2px; }
.stage-body .tile + .tile { margin-left: -2px; }
.stage-hints { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; min-height: 36px; }
.stage-hints .hint-pill { font-size: clamp(15px, 2.2vw, 24px); padding: 4px 16px; }
.stage-answer { font-family: var(--font-serif); font-weight: 700; font-size: clamp(30px, 6vw, 72px); color: var(--accent); min-height: 1.2em; }
.stage-timer { font: 600 30px/44px var(--font); font-variant-numeric: tabular-nums; min-width: 76px; text-align: center; border: 1px solid var(--rule-strong); border-radius: var(--r); padding: 0 10px; background: var(--bg); }
.stage-timer.low { color: var(--bad); border-color: var(--bad); }
.stage-bar { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; padding: 14px 16px 18px; border-top: 1px solid var(--rule); background: var(--surface); }
.stage-bar .btn { min-width: 96px; justify-content: center; }
@media (max-width: 480px) { .stage-top { padding: 10px 12px; } .stage-title { font-size: 16px; } .stage-bar .btn { min-width: 0; flex: 1 1 40%; } }

/* ── 인쇄: 원고지식 문제지·정답지 ── */
#printArea { display: none; }
@media print {
  @page { size: A4; margin: 14mm 14mm 16mm; }
  body { background: #fff !important; }
  body > *:not(#printArea) { display: none !important; }
  #printArea { display: block !important; color: #000; }
  .print-page { page-break-after: always; font-family: var(--font); }
  .print-page:last-child { page-break-after: auto; }
  .print-page h1 { font-family: var(--font-serif); font-weight: 700; font-size: 19pt; margin: 0 0 6pt; padding-bottom: 6pt; border-bottom: 2pt solid #000; }
  .print-page .pmeta { font-size: 10.5pt; margin: 0 0 12pt; text-align: right; }
  .print-table { width: 100%; border-collapse: collapse; }
  .print-table th { font-size: 9.5pt; font-weight: 600; letter-spacing: 1pt; border-top: 1pt solid #000; border-bottom: 1pt solid #000; padding: 5pt 6pt; text-align: left; }
  .print-table td { border-bottom: 0.6pt solid #999; padding: 9pt 6pt; font-size: 12pt; vertical-align: middle; }
  .print-table .pc { font-family: var(--font-serif); font-weight: 600; font-size: 17pt; letter-spacing: 4pt; }
  .print-table th:first-child { text-align: center; }
  .print-table .blank { width: 38%; border-bottom: 0.6pt solid #999; }
  .print-table small { color: #555; }
}

/* ── 공통 페이지(콘텐츠) ── */
.crumb { font-size: 13px; color: var(--ink-3); margin-bottom: 14px; }
.crumb a { color: var(--ink-2); text-decoration: none; }
.crumb a:hover { text-decoration: underline; }
.crumb span.sep { margin: 0 7px; color: var(--rule-strong); }
.page-head { margin: 4px 0 26px; padding-bottom: 20px; border-bottom: 1px solid var(--rule); }
.page-head .eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: 1px; color: var(--accent); }
.page-head .eyebrow::before { content: ''; width: 10px; height: 10px; border: 1px solid var(--accent); background: var(--accent-soft); }
.page-head h1 { font-family: var(--font-serif); font-weight: 700; font-size: clamp(27px, 5vw, 40px); line-height: 1.3; margin: 8px 0 10px; letter-spacing: -0.6px; }
.page-head p { color: var(--ink-2); margin: 0; font-size: 17px; max-width: 46em; }
.prose { font-size: 17px; line-height: 1.8; }
.prose h2 { font-family: var(--font-serif); font-weight: 700; font-size: 24px; line-height: 1.4; margin: 40px 0 12px; letter-spacing: -0.3px;
  display: flex; align-items: baseline; gap: 10px; }
.prose h2::before { content: ''; flex: 0 0 auto; width: 12px; height: 12px; border: 1px solid var(--accent); background: var(--accent); transform: translateY(-1px); }
.prose h3 { font-size: 18.5px; font-weight: 700; margin: 26px 0 8px; }
.prose p { margin: 0 0 15px; }
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 15px; }
.prose li { margin: 5px 0; }
.prose li::marker { color: var(--accent); }
.prose blockquote { margin: 18px 0; padding: 12px 16px; border-left: 3px solid var(--accent); background: var(--surface); border-top: 1px solid var(--rule); border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.prose blockquote p { margin: 0; }
.prose code { background: var(--surface-2); padding: 1px 6px; border-radius: 3px; font-size: .92em; font-family: var(--font); }
.prose table { border-collapse: collapse; width: 100%; margin: 14px 0 20px; font-size: 15px; display: block; overflow-x: auto; }
.prose th, .prose td { border-bottom: 1px solid var(--rule); padding: 9px 12px; text-align: left; }
.prose th { border-top: 1px solid var(--ink); border-bottom-color: var(--ink); font-weight: 600; font-size: 14px; }
.meta-line { font-size: 13px; color: var(--ink-3); margin-top: 24px; }

/* 색인형 카드 — 상자 대신 윗선 */
.card-grid { display: grid; grid-template-columns: 1fr; gap: 0 28px; }
@media (min-width: 640px) { .card-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .card-grid { grid-template-columns: 1fr 1fr 1fr; } }
.link-card { border-top: 1px solid var(--ink); padding: 14px 0 20px; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 5px; }
.link-card h3 { margin: 0; font-family: var(--font-serif); font-weight: 700; font-size: 20px; line-height: 1.4; }
.link-card h3::after { content: ' →'; color: var(--accent); font-family: var(--font); font-weight: 500; }
.link-card:hover h3 { color: var(--accent); }
.link-card p { margin: 0; color: var(--ink-2); font-size: 14.5px; line-height: 1.6; }
.link-card .lc-tag { font-size: 12.5px; color: var(--ink-3); font-weight: 500; font-variant-numeric: tabular-nums; }
.section-t { font-family: var(--font-serif); font-weight: 700; font-size: 22px; margin: 36px 0 12px; }

/* 퀴즈 모음 페이지 */
.qlist { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 0;
  border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.qitem { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 13px 16px 14px; background: var(--surface); }
.qitem .qi-top { display: flex; gap: 12px; align-items: baseline; }
.qitem .qi-no { font-size: 12.5px; font-weight: 600; color: var(--ink-3); min-width: 24px; font-variant-numeric: tabular-nums; }
.qitem .qi-cho { font-family: var(--font-serif); font-weight: 600; font-size: 24px; letter-spacing: 3px; line-height: 1.35; word-break: keep-all; }
.qitem .qi-hint { font-size: 14px; color: var(--ink-2); margin: 4px 0 0 36px; }
.qitem details { margin: 6px 0 0 36px; }
.qitem summary { cursor: pointer; font-weight: 600; font-size: 13.5px; color: var(--accent); list-style: none; }
.qitem summary::-webkit-details-marker { display: none; }
.qitem summary::before { content: '＋ '; }
.qitem details[open] summary::before { content: '－ '; }
.qitem .qi-ans { font-family: var(--font-serif); font-size: 18px; font-weight: 700; margin-top: 4px; }
.qitem .qi-ans small { display: block; font-family: var(--font); font-weight: 400; color: var(--ink-2); font-size: 13.5px; }
.faq-item { border-top: 1px solid var(--rule); padding: 16px 0 4px; }
.faq-item h3 { margin: 0 0 6px; font-size: 17.5px; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0; border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.feature { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 14px 16px; background: var(--surface); }
.feature h3 { margin: 0 0 4px; font-size: 16.5px; }
.feature p { margin: 0; font-size: 14.5px; color: var(--ink-2); line-height: 1.6; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-top: 30px; border-top: 1px solid var(--ink); }
.pager a { padding: 14px 14px 14px 0; text-decoration: none; color: var(--ink-3); font-size: 12.5px; }
.pager a b { display: block; color: var(--ink); font-family: var(--font-serif); font-size: 16px; font-weight: 700; line-height: 1.45; margin-top: 2px; }
.pager a.next { text-align: right; padding: 14px 0 14px 14px; border-left: 1px solid var(--rule); }
.pager a:hover b { color: var(--accent); }
.nf-code { font-size: 44px; margin-bottom: 20px; }

/* ── 광고(애드핏 규정: 래퍼에 radius·overflow 금지) ── */
.ad-grid { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; max-width: 672px; margin: 28px auto 0; }
.ad-grid[data-ad-layout="mixed"] { max-width: 760px; }
.ad-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; width: 100%; }
.ad-cell { min-height: 50px; }
.ad-pc { display: none; }
@media (min-width: 720px) { .ad-pc { display: flex; } .ad-mo { display: none; } }

/* ── footer ── */
.site-footer { border-top: 1px solid var(--rule); background: var(--surface); margin-top: 36px; }
.footer-inner { max-width: 1120px; margin: 0 auto; padding: 26px 16px 30px; }
.footer-brand { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.footer-brand b { font-family: var(--font-serif); font-size: 17px; }
.footer-brand span { font-size: 13px; color: var(--ink-3); }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--rule); }
.footer-links a { color: var(--ink-2); text-decoration: none; font-size: 14px; font-weight: 500; }
.footer-links a:hover { color: var(--accent); }
.footer-note { font-size: 12.5px; color: var(--ink-3); margin: 0 0 4px; line-height: 1.6; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: var(--r); font-weight: 600; font-size: 14px; z-index: 200; opacity: 0; pointer-events: none; transition: opacity .2s; }
.toast.show { opacity: 1; }
