/* ============================================================================
   닥터시선 (DRLOOK) — 병의원·개원 전문 숏폼 스튜디오
   디자인 시스템: 클린 스틸 화이트 · 딥 슬레이트 잉크 · 메디컬 틸/코랄
   기반: TailThemes Foundry(MIT)의 토큰·타이포 위계·헤어라인 그리드·룰 원장·
   라이트/다크 규칙을 한국어 조판(본문 Pretendard · 디스플레이 Noto Serif KR ·
   word-break: keep-all)으로 옮긴 것.

   원칙
   1. 모든 색·간격·타입 결정은 이 파일의 토큰에서만 나온다.
   2. 틸(--primary)은 면·큰 글자·장식에만. 작은 글자·링크·라벨은
      --accent-foreground(코랄 딥)로 두어 4.5:1 이상을 지킨다.
   3. --border는 헤어라인(장식), 조작 가능한 입력의 경계는 --field-border.
   4. 그림자·그라디언트·알파 상태색 없음. 모션은 150ms 색 변화 하나.
   ========================================================================== */

/* ── 서체 ──────────────────────────────────────────────────────────────── */
@font-face {
  font-family: "Pretendard Variable";
  src: url("assets/fonts/PretendardVariable.woff2") format("woff2-variations");
  font-weight: 45 920;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Site Serif";
  src: url("assets/fonts/NotoSerifKR-Site.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("assets/fonts/Fraunces-Variable.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* ── 토큰 · 라이트 (clinical steel) ────────────────────────────────────── */
:root {
  --background: #f5f8fa;
  --foreground: #111820;

  --card: #ffffff;
  --card-foreground: #111820;

  --primary: #17646c;
  --primary-hover: #1d7b85;
  --primary-active: #228a95;
  --primary-foreground: #f1fbfc;

  --secondary: #e3edf1;
  --secondary-foreground: #2a3a41;

  --muted: #eaf1f5;
  --muted-foreground: #4b5c66;

  --accent: #f9eae5;
  --accent-foreground: #96412c;

  --tint: #e4f0f2;
  --tint-foreground: #125058;

  --border: #d3e0e6;
  --field-border: #6b7d86;
  --ring: #17646c;

  --radius: 3px;

  --font-display: "Fraunces", "Site Serif", "Noto Serif KR", "Nanum Myeongjo", serif;
  --font-text: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "Pretendard Variable", ui-monospace, SFMono-Regular,
    Menlo, Consolas, monospace;

  --text-d4: clamp(2.125rem, 1.25rem + 3.9vw, 3.625rem);
  --leading-d4: 1.2;
  --tracking-d4: -0.026em;

  --text-d3: clamp(1.75rem, 1.3rem + 2.1vw, 2.625rem);
  --leading-d3: 1.28;
  --tracking-d3: -0.022em;

  --text-d2: clamp(1.4375rem, 1.26rem + 0.8vw, 1.8125rem);
  --leading-d2: 1.36;
  --tracking-d2: -0.018em;

  --text-d1: 1.25rem;
  --leading-d1: 1.42;
  --tracking-d1: -0.012em;

  --text-lead: 1.0625rem;
  --leading-lead: 1.78;
  --text-body: 1rem;
  --leading-body: 1.8;
  --text-small: 0.875rem;
  --leading-small: 1.7;
  --text-caption: 0.75rem;
  --leading-caption: 1.55;
  --tracking-label: 0.1em;

  --display-weight: 500;
  --display-synthesis: weight;
  --label-weight: 500;

  --wrap: 1240px;
  --gutter: clamp(20px, 4.6vw, 52px);
  --header-h: 62px;

  --duration-feedback: 150ms;
  --ease-feedback: cubic-bezier(0.33, 1, 0.68, 1);
}

/* ── 토큰 · 다크 (night ward) ──────────────────────────────────────────── */
:root.dark {
  --background: #0b1418;
  --foreground: #e6eff2;

  --card: #101c21;
  --card-foreground: #e6eff2;

  --primary: #63b8c0;
  --primary-hover: #7cc9d0;
  --primary-active: #95d8de;
  --primary-foreground: #05161a;

  --secondary: #16262c;
  --secondary-foreground: #cfe0e6;

  --muted: #131f24;
  --muted-foreground: #96a8b0;

  --accent: #2a1a15;
  --accent-foreground: #f0a48c;

  --tint: #12292e;
  --tint-foreground: #a6dde2;

  --border: #22363c;
  --field-border: #5f757e;
  --ring: #63b8c0;
}

/* ── 리셋 ─────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-text);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  font-weight: 400;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
main { flex: 1 0 auto; }
ul, ol { list-style: none; padding: 0; }
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
table { border-collapse: collapse; width: 100%; }
summary { cursor: pointer; }
::selection { background: var(--primary); color: var(--primary-foreground); }

:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
  border-radius: var(--radius);
}

/* ── 타입 ─────────────────────────────────────────────────────────────── */
.display {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-synthesis-weight: var(--display-synthesis);
  font-optical-sizing: auto;
  font-variation-settings: "SOFT" 0, "WONK" 0;
}
.d4 { font-size: var(--text-d4); line-height: var(--leading-d4); letter-spacing: var(--tracking-d4); }
.d3 { font-size: var(--text-d3); line-height: var(--leading-d3); letter-spacing: var(--tracking-d3); }
.d2 { font-size: var(--text-d2); line-height: var(--leading-d2); letter-spacing: var(--tracking-d2); }
.d1 { font-size: var(--text-d1); line-height: var(--leading-d1); letter-spacing: var(--tracking-d1); }

.lead { font-size: var(--text-lead); line-height: var(--leading-lead); }
.small { font-size: var(--text-small); line-height: var(--leading-small); }
.caption { font-size: var(--text-caption); line-height: var(--leading-caption); }
.muted { color: var(--muted-foreground); }
.strong { font-weight: 600; }
.tnum { font-variant-numeric: tabular-nums; }

.label {
  font-family: var(--font-mono);
  font-size: var(--text-caption);
  line-height: var(--leading-caption);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  font-weight: var(--label-weight);
  font-variant-numeric: tabular-nums;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: var(--text-caption);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  font-weight: var(--label-weight);
  color: var(--accent-foreground);
}
.eyebrow::before {
  content: "";
  width: 14px;
  height: 1px;
  background: currentColor;
  flex: none;
}
.teal { color: var(--primary); }
.wash { color: var(--accent-foreground); }
.balance { text-wrap: balance; }
.pretty { text-wrap: pretty; }

/* 한글 디스플레이 보정 — 세리프는 자간을 조금 더 조인다 */
h1.display, h2.display, h3.display { font-feature-settings: "kern" 1; }

/* ── 레이아웃 ─────────────────────────────────────────────────────────── */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap-narrow { max-width: 780px; }

.section { padding-block: clamp(48px, 5.8vw, 84px); }
.section-lg { padding-block: clamp(58px, 7.4vw, 108px); }
.section-sm { padding-block: clamp(32px, 3.6vw, 52px); }
section[id] { scroll-margin-top: calc(var(--header-h) + 12px); }
.band { background: var(--muted); }
.band-card { background: var(--card); }
.band-tint { background: var(--tint); }
.rule-top { border-top: 1px solid var(--border); }

.head { display: grid; gap: 16px; max-width: 64ch; }
.head h2 { max-width: 30ch; }
.head .lead { color: var(--muted-foreground); max-width: 58ch; }
.head .pill { justify-self: start; }
.head-center { justify-items: center; text-align: center; margin-inline: auto; }
.head-center h2, .head-center .lead { max-width: 44ch; }

/* 섹션 번호 — 원장(ledger)식 머리 */
.sec-no {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
  margin-bottom: 26px;
}
.sec-no b {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--accent-foreground);
  letter-spacing: 0;
}

/* ── 스킵 링크 ────────────────────────────────────────────────────────── */
.skip {
  position: fixed;
  left: 12px;
  top: 12px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--primary);
  color: var(--primary-foreground);
  border-radius: var(--radius);
  font-size: var(--text-small);
  transform: translateY(-200%);
}
.skip:focus { transform: none; }

/* ── 헤더 ─────────────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--background) 90%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: var(--header-h);
}
.wordmark {
  display: flex;
  align-items: baseline;
  gap: 9px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.1875rem;
  letter-spacing: -0.018em;
  line-height: 1.2;
  white-space: nowrap;
}
.wordmark small {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  font-weight: 400;
}
.nav { display: none; }
.nav a {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--muted-foreground);
  padding: 8px 0;
  border-bottom: 1px solid transparent;
  transition: color var(--duration-feedback) var(--ease-feedback),
              border-color var(--duration-feedback) var(--ease-feedback);
}
.nav a:hover { color: var(--foreground); border-bottom-color: var(--border); }
.nav a[aria-current="page"] { color: var(--foreground); border-bottom-color: var(--primary); }

.actions { display: flex; align-items: center; gap: 8px; }

.mode-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 10px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  cursor: pointer;
  transition: background-color var(--duration-feedback) var(--ease-feedback);
}
.mode-toggle:hover { background: var(--tint); }
.mode-toggle svg { width: 15px; height: 15px; flex: none; }
.mode-toggle .lbl { display: none; }
:root:not(.dark) .mode-toggle .i-light { display: none; }
:root.dark .mode-toggle .i-dark { display: none; }

.menu { position: relative; }
.menu > summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: background-color var(--duration-feedback) var(--ease-feedback);
}
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary:hover { background: var(--tint); }
.menu > summary svg { width: 17px; height: 17px; }
.menu .i-close { display: none; }
.menu[open] .i-open { display: none; }
.menu[open] .i-close { display: block; }
.menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  min-width: 244px;
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.menu-panel a {
  background: var(--card);
  padding: 12px 16px;
  font-size: var(--text-small);
  transition: background-color var(--duration-feedback) var(--ease-feedback);
}
.menu-panel a:hover { background: var(--tint); }
.menu-panel a small {
  display: block;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  margin-top: 3px;
}

/* ── 버튼 ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: var(--text-small);
  font-weight: 600;
  letter-spacing: -0.005em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--duration-feedback) var(--ease-feedback),
              border-color var(--duration-feedback) var(--ease-feedback),
              color var(--duration-feedback) var(--ease-feedback);
}
.btn svg { width: 15px; height: 15px; flex: none; }
.btn-primary { background: var(--primary); color: var(--primary-foreground); border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn-primary:active { background: var(--primary-active); border-color: var(--primary-active); }
.btn-quiet { background: var(--card); color: var(--foreground); border-color: var(--field-border); }
.btn-quiet:hover { background: var(--tint); }
.btn-ink { background: var(--foreground); color: var(--background); border-color: var(--foreground); }
.btn-sm { min-height: 38px; padding: 0 14px; font-size: 0.8125rem; }
.btn-full { width: 100%; }
.btn.hide-sm { display: none; }

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: var(--text-small);
  font-weight: 600;
  color: var(--foreground);
  border-bottom: 1px solid var(--border);
  padding-bottom: 3px;
  transition: border-color var(--duration-feedback) var(--ease-feedback);
}
.arrow-link svg { width: 14px; height: 14px; transition: transform var(--duration-feedback) var(--ease-feedback); }
.arrow-link:hover { border-bottom-color: var(--primary); }
.arrow-link:hover svg { transform: translateX(3px); }
.arrow-link.coral { color: var(--accent-foreground); }

.link {
  color: var(--accent-foreground);
  border-bottom: 1px solid color-mix(in srgb, var(--accent-foreground) 35%, transparent);
}

/* ── 히어로 ───────────────────────────────────────────────────────────── */
.hero { padding-block: clamp(44px, 6vw, 84px) clamp(36px, 4.6vw, 64px); }
.hero-grid { display: grid; gap: clamp(28px, 4vw, 52px); align-items: start; }
.hero-copy { display: grid; gap: 22px; align-content: start; }
.hero h1 { max-width: 22ch; }
.hero .lead { max-width: 46ch; color: var(--muted-foreground); }
.hero-meta { display: grid; gap: 6px; }

/* 지표 레일 — 기본 2×2, 넓은 밴드에서만 4열 */
.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.facts.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.facts.two dd { white-space: normal; }
.facts > div {
  background: var(--card);
  padding: 15px 16px 17px;
  display: grid;
  gap: 5px;
  align-content: start;
}
.facts dt {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}
.facts dd {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.0625rem;
  line-height: 1.34;
  letter-spacing: -0.015em;
  font-variant-numeric: tabular-nums;
}
.facts dd span {
  display: block;
  font-family: var(--font-text);
  font-size: 11.5px;
  font-weight: 400;
  color: var(--muted-foreground);
  letter-spacing: 0;
  margin-top: 3px;
}

/* 히어로 아래 두 칸 */
.hero-below {
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: clamp(28px, 3.6vw, 48px);
}
.hero-below > * { background: var(--card); padding: clamp(18px, 2.4vw, 26px); }
.hero-quote p { font-size: 0.9375rem; line-height: 1.75; color: var(--muted-foreground); max-width: 60ch; }
.hero-quote strong { color: var(--foreground); font-weight: 600; }
.hero-index ol { display: grid; gap: 0; margin-top: 12px; }
.hero-index li {
  display: flex;
  gap: 14px;
  align-items: baseline;
  padding-block: 9px;
  border-top: 1px solid var(--border);
  font-size: 13px;
}
.hero-index li:first-child { border-top: 0; }
.hero-index .n { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; color: var(--accent-foreground); }

/* ── 헤어라인 그리드 (같은 무게의 것들의 모음) ──────────────────────── */
.lines {
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.lines > * { background: var(--card); padding: clamp(16px, 2.1vw, 24px); }
.cols-2 { grid-template-columns: 1fr; }
.cols-3 { grid-template-columns: 1fr; }
.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 640px) { .cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 768px) { .cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 960px) { .cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ── 진단(비교) ───────────────────────────────────────────────────────── */
.diagnosis {
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.diagnosis > * { background: var(--card); padding: clamp(18px, 2.4vw, 26px); }
.diag-heads { display: grid; gap: 1px; background: var(--border); }
.diag-head {
  display: grid;
  gap: 6px;
  background: var(--muted);
}
.diag-head .t {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  letter-spacing: -0.012em;
}
.diag-head .s {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}
.diag-fail .t { color: var(--muted-foreground); }
.diag-win { background: var(--tint); }
.diag-win .t { color: var(--tint-foreground); }
.diag-pair { display: grid; gap: 1px; background: var(--border); border-top: 1px solid var(--border); }
.diag-pair > div { background: var(--card); padding: 16px 18px; display: grid; gap: 7px; }
.diag-pair > div.win { background: var(--tint); }
.diag-pair .n {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--muted-foreground);
}
.diag-pair .q { font-size: 13px; line-height: 1.65; color: var(--foreground); }
.diag-pair .a { font-size: 13px; line-height: 1.65; color: var(--muted-foreground); }
.diag-pair > div.win .a { color: var(--tint-foreground); }

/* 전환 여정 4단 */
.journey { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.journey > div { background: var(--card); padding: clamp(16px, 2.2vw, 22px); display: grid; gap: 7px; align-content: start; }
.journey .st {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-foreground);
}
.journey h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.0625rem; letter-spacing: -0.012em; }
.journey p { font-size: 12.5px; line-height: 1.68; color: var(--muted-foreground); }
.journey .kpi {
  margin-top: 2px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--muted-foreground);
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

/* ── 전문 분야 인덱스 ─────────────────────────────────────────────────── */
.spec { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.spec > article { background: var(--card); padding: clamp(20px, 2.6vw, 30px); display: grid; gap: 12px; align-content: start; }
.spec .no {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--muted-foreground);
  border-bottom: 1px solid var(--border);
  padding-bottom: 9px;
}
.spec .no b { color: var(--accent-foreground); font-weight: 500; }
.spec h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.25rem; letter-spacing: -0.018em; line-height: 1.35; }
.spec .who { font-size: 12.5px; line-height: 1.65; color: var(--muted-foreground); }
.spec .block { display: grid; gap: 5px; }
.spec .block .h {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}
.spec ul.hooks { display: grid; gap: 5px; font-size: 12.5px; line-height: 1.6; }
.spec ul.hooks li { position: relative; padding-left: 13px; }
.spec ul.hooks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.76em;
  width: 6px;
  height: 1px;
  background: var(--primary);
}
.spec .care {
  font-size: 12px;
  line-height: 1.62;
  color: var(--accent-foreground);
  background: var(--accent);
  border-radius: 2px;
  padding: 9px 11px;
}

/* ── 표 ───────────────────────────────────────────────────────────────── */
.table-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow-x: auto;
  background: var(--card);
}
table.tbl { min-width: 660px; font-size: var(--text-small); }
table.tbl caption {
  caption-side: top;
  text-align: left;
  padding: 13px 18px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  border-bottom: 1px solid var(--border);
}
table.tbl th,
table.tbl td {
  text-align: left;
  vertical-align: top;
  padding: 13px 18px;
  border-bottom: 1px solid var(--border);
  line-height: 1.62;
}
table.tbl thead th {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  font-weight: 500;
  background: var(--muted);
  white-space: nowrap;
}
table.tbl tbody th { font-weight: 600; color: var(--foreground); width: 20%; min-width: 108px; }
table.tbl tbody tr:last-child th,
table.tbl tbody tr:last-child td { border-bottom: 0; }
table.tbl tr.is-key td,
table.tbl tr.is-key th { background: var(--tint); }
table.tbl .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
table.tbl .no-cell { font-family: var(--font-mono); font-size: 11px; color: var(--muted-foreground); width: 3.2rem; }
table.tbl .ban { color: var(--muted-foreground); }
table.tbl .use { color: var(--tint-foreground); }
table.tbl .t-sub { display: block; font-size: 12px; color: var(--muted-foreground); margin-top: 3px; }

/* ── 검수 절차 ───────────────────────────────────────────────────────── */
.checks { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.check { background: var(--card); padding: 18px 20px; display: grid; gap: 6px; align-content: start; }
.check .n {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--accent-foreground);
}
.check h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.0625rem; letter-spacing: -0.012em; }
.check p { font-size: 12.5px; line-height: 1.66; color: var(--muted-foreground); }

/* ── 대본 쇼케이스 ────────────────────────────────────────────────────── */
.script { border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); overflow: hidden; }
.script-head {
  display: grid;
  gap: 8px;
  padding: clamp(18px, 2.2vw, 24px);
  background: var(--muted);
  border-bottom: 1px solid var(--border);
}
.script-head .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}
.script-head h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.125rem; letter-spacing: -0.014em; line-height: 1.4; }
.script-body { display: grid; }
.script-body table.tbl { min-width: 0; font-size: 12.5px; }
.script-body table.tbl th,
.script-body table.tbl td { padding: 11px 14px; }
.script-body table.tbl tbody th {
  width: 20%;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  font-weight: 500;
  color: var(--accent-foreground);
  white-space: nowrap;
}
.script-why {
  padding: 16px 18px 18px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 6px;
  background: var(--tint);
}
.script-why .h {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--tint-foreground);
}
.script-why p { font-size: 12.5px; line-height: 1.7; color: var(--tint-foreground); }

/* ── 사진 판(plate) · 영상 ────────────────────────────────────────────── */
.plate { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 9px; }
.plate video { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 2px; background: var(--secondary); }
.plate-tall { max-width: 300px; }
.plate-cap {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  padding: 9px 3px 2px;
}

/* ── 원장(ledger) ─────────────────────────────────────────────────────── */
.ledger { border-top: 1px solid var(--border); }
.ledger > li { border-bottom: 1px solid var(--border); padding-block: clamp(16px, 2vw, 22px); }
.ledger > li > .row { display: grid; gap: 8px 20px; align-items: baseline; grid-template-columns: 1fr; }
.ledger .idx {
  font-family: var(--font-mono);
  font-size: var(--text-small);
  color: var(--accent-foreground);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}
.ledger h3 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.125rem, 1.05rem + 0.4vw, 1.375rem); line-height: 1.4; letter-spacing: -0.016em; }
.ledger .desc { font-size: var(--text-small); color: var(--muted-foreground); max-width: 52ch; margin-top: 5px; }
.ledger .fig { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--muted-foreground); white-space: nowrap; }

/* ── 가격 ─────────────────────────────────────────────────────────────── */
.plans { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.plan { background: var(--card); padding: clamp(20px, 2.4vw, 27px); display: grid; align-content: start; }
.plan .flag {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--accent-foreground);
  margin-bottom: 9px;
}
.plan h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.125rem; letter-spacing: -0.014em; }
.plan .amount {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.875rem, 1.5rem + 1.3vw, 2.375rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  margin-top: 7px;
}
.plan .amount span { font-family: var(--font-text); font-size: 0.8125rem; font-weight: 500; color: var(--muted-foreground); letter-spacing: 0; margin-left: 4px; }
.plan .per { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.05em; color: var(--muted-foreground); margin-top: 7px; }
.plan ul { display: grid; gap: 6px; margin: 16px 0 20px; font-size: var(--text-small); }
.plan ul li { position: relative; padding-left: 13px; color: var(--muted-foreground); }
.plan ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7em;
  width: 5px;
  height: 1px;
  background: var(--field-border);
}
.plan ul li strong { color: var(--foreground); font-weight: 600; }
.plan .btn { margin-top: auto; }
.plan.is-main { background: var(--tint); }
.plan.is-main .flag { color: var(--tint-foreground); }

/* ── 강조 패널 ────────────────────────────────────────────────────────── */
.panel {
  background: var(--tint);
  border: 1px solid color-mix(in srgb, var(--tint-foreground) 22%, transparent);
  border-radius: var(--radius);
  padding: clamp(22px, 3.2vw, 40px);
}
.panel .lead strong { color: var(--tint-foreground); }
.bundle { display: grid; gap: clamp(20px, 3vw, 36px); align-items: start; }
.bundle .price-big {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.25rem, 1.7rem + 2.6vw, 3.25rem);
  line-height: 1.08;
  letter-spacing: -0.032em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.bundle .price-big span { font-family: var(--font-text); font-size: 0.9375rem; font-weight: 500; letter-spacing: 0; color: var(--muted-foreground); margin-left: 6px; }

/* ── 단계 ─────────────────────────────────────────────────────────────── */
.steps { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.step { background: var(--card); padding: clamp(16px, 2vw, 22px); display: grid; gap: 7px; align-content: start; }
.step .when {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--accent-foreground);
  text-transform: uppercase;
}
.step h3 { font-family: var(--font-display); font-weight: 400; font-size: 1rem; letter-spacing: -0.012em; line-height: 1.45; }
.step p { font-size: 12.5px; line-height: 1.66; color: var(--muted-foreground); }

/* ── FAQ ──────────────────────────────────────────────────────────────── */
.faq { border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 17px 0;
  font-size: var(--text-lead);
  font-weight: 500;
  line-height: 1.62;
  list-style: none;
  transition: color var(--duration-feedback) var(--ease-feedback);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--accent-foreground); }
.faq summary .mk { flex: none; width: 18px; height: 18px; margin-top: 4px; color: var(--muted-foreground); }
.faq summary .mk .v { display: none; }
.faq details[open] summary .mk .v { display: block; }
.faq details[open] summary .mk .h { display: none; }
.faq .a { padding: 0 0 20px; max-width: 66ch; font-size: var(--text-small); color: var(--muted-foreground); }
.faq .a strong { color: var(--foreground); font-weight: 600; }

/* ── 폼 ───────────────────────────────────────────────────────────────── */
.form { display: grid; gap: 15px; }
.form .pair { display: grid; gap: 15px; }
.field { display: grid; gap: 6px; }
.field > label,
.field .lbl {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}
.field .req { color: var(--accent-foreground); }
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  padding: 11px 13px;
  background: var(--card);
  color: var(--foreground);
  border: 1px solid var(--field-border);
  border-radius: var(--radius);
  font-family: var(--font-text);
  font-size: var(--text-small);
  line-height: 1.5;
  transition: background-color var(--duration-feedback) var(--ease-feedback),
              border-color var(--duration-feedback) var(--ease-feedback);
}
.field textarea { min-height: 92px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: color-mix(in srgb, var(--muted-foreground) 76%, transparent); }
.field input:hover,
.field select:hover,
.field textarea:hover { background: var(--tint); }
.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible { background: var(--card); outline-offset: 1px; }
.consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted-foreground);
}
.consent input { margin-top: 3px; width: 15px; height: 15px; accent-color: var(--primary); flex: none; }
.form-msg { font-size: 12px; line-height: 1.62; color: var(--muted-foreground); }
.form-msg.is-error { color: var(--accent-foreground); }
.form-msg.is-ok { color: var(--tint-foreground); }

/* ── 연락 데스크 ──────────────────────────────────────────────────────── */
.desks { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.desk { background: var(--card); padding: 13px 15px; display: grid; gap: 3px; }
.desk dt { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted-foreground); }
.desk dd { font-size: var(--text-small); font-weight: 500; overflow-wrap: anywhere; }
.desks.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* ── 푸터 ─────────────────────────────────────────────────────────────── */
.site-footer { background: var(--foreground); color: var(--background); padding-block: clamp(40px, 4.6vw, 64px); }
:root.dark .site-footer { background: var(--muted); color: var(--foreground); }
.site-footer a { color: var(--background); }
:root.dark .site-footer a { color: var(--foreground); }
.foot-grid { display: grid; gap: 32px; }
.foot-brand .wm { font-family: var(--font-display); font-weight: 400; font-size: 1.4375rem; letter-spacing: -0.016em; }
.foot-brand .en { display: block; font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; opacity: 0.55; margin-top: 6px; }
.foot-brand p { margin-top: 12px; font-size: 12.5px; line-height: 1.75; opacity: 0.72; max-width: 36ch; }
.foot-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.foot-cols .h { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.13em; text-transform: uppercase; opacity: 0.5; margin-bottom: 10px; }
.foot-cols ul { display: grid; gap: 7px; font-size: 12.5px; }
.foot-cols a { opacity: 0.86; }
.foot-cols a:hover { opacity: 1; }
.foot-legal {
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid color-mix(in srgb, var(--background) 16%, transparent);
  display: grid;
  gap: 9px;
  font-size: 11.5px;
  line-height: 1.78;
  opacity: 0.62;
}
:root.dark .foot-legal { border-top-color: var(--border); }

/* ── 모바일 하단 바 ───────────────────────────────────────────────────── */
.mobile-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 1px;
  background: var(--border);
  border-top: 1px solid var(--border);
}
.mobile-bar a {
  background: var(--card);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  font-size: var(--text-small);
  font-weight: 600;
}
.mobile-bar a.primary { background: var(--primary); color: var(--primary-foreground); }
body { padding-bottom: 54px; }

/* ── 유틸 ─────────────────────────────────────────────────────────────── */
.stack { display: grid; gap: 16px; }
.stack-sm { display: grid; gap: 8px; }
.stack-lg { display: grid; gap: 26px; }
.split { display: grid; gap: clamp(22px, 3.4vw, 52px); }
.cluster { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--secondary);
  color: var(--secondary-foreground);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.pill.teal { background: var(--tint); color: var(--tint-foreground); border-color: color-mix(in srgb, var(--tint-foreground) 24%, transparent); }
.note {
  border-left: 2px solid var(--primary);
  padding: 2px 0 2px 15px;
  font-size: 12.5px;
  line-height: 1.72;
  color: var(--muted-foreground);
}
.note strong { color: var(--foreground); }
.mt-s { margin-top: 12px; }
.mt-m { margin-top: 22px; }
.mt-l { margin-top: 34px; }
.center { text-align: center; }
.rule { border: 0; border-top: 1px solid var(--border); margin-block: clamp(26px, 3vw, 40px); }

/* ── 반응형 ───────────────────────────────────────────────────────────── */
@media (min-width: 560px) {
  .tablet-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 640px) {
  :root { --header-h: 66px; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .form .pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .diag-heads { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .diag-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journey { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .checks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spec { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .btn.hide-sm { display: inline-flex; }
}

@media (min-width: 768px) {
  .nav { display: flex; align-items: center; gap: clamp(12px, 1.7vw, 24px); }
  .menu { display: none; }
  .steps { grid-template-columns: repeat(var(--step-cols, 3), minmax(0, 1fr)); }
  .mobile-bar { display: none; }
  body { padding-bottom: 0; }
  .script-body { grid-template-columns: 1fr; }
}

@media (min-width: 900px) {
  .facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .facts dd { white-space: nowrap; }
  .facts.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts.two dd { white-space: normal; }
}

@media (min-width: 960px) {
  .hero-grid { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: center; }
  .hero-below { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); }
  .split { grid-template-columns: 1fr 1fr; }
  .split-7-5 { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .split-5-7 { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .split-8-4 { grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); }
  .split-4-8 { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
  .ledger > li > .row { grid-template-columns: 2.6rem minmax(0, 1fr) auto; align-items: start; }
  .ledger > li > .row .fig { text-align: right; padding-top: 3px; }
  .journey { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .checks { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .spec { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bundle { grid-template-columns: 7fr 4fr; }
  .foot-grid { grid-template-columns: 1.3fr 1fr; }
  .head-center { text-align: center; }
}

@media (min-width: 1080px) {
  .mode-toggle .lbl { display: inline; }
}

@media (max-width: 639px) {
  table.tbl { min-width: 560px; font-size: 13px; }
  table.tbl th,
  table.tbl td { padding: 10px 12px; }
  table.tbl tbody th { min-width: 88px; width: 26%; }
  .faq summary { font-size: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* ── 07 견적 계산기 · 계약 전 걱정 (SCOPE-V1, 2026-11-29) ───────────────── */
.calc { display: grid; gap: 1.5rem; }
@media (min-width: 920px) {
  .calc { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 2.5rem; align-items: start; }
}
.calc-form fieldset {
  margin: 0 0 0.75rem; padding: 1rem 1.1rem 1.1rem;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--card);
}
.calc-form legend {
  padding: 0 0.4rem; font-family: var(--font-mono); font-size: 0.7rem;
  letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--muted-foreground);
}
.calc-opts { display: grid; gap: 0.45rem; margin-top: 0.6rem; }
.calc-opt {
  display: flex; align-items: baseline; gap: 0.55rem;
  padding: 0.6rem 0.75rem; border: 1px solid var(--border);
  border-radius: var(--radius); cursor: pointer;
}
.calc-opt input { accent-color: var(--primary); margin: 0 0.15rem 0 0; flex: none; }
.calc-opt .t { font-weight: 600; }
.calc-opt .s {
  margin-left: auto; font-family: var(--font-mono); font-size: 0.78rem;
  color: var(--muted-foreground); white-space: nowrap;
}
.calc-opt:hover { border-color: var(--field-border); }
.calc-opt:has(input:checked) { border-color: var(--primary); background: var(--tint); }
.calc-opt:has(input:focus-visible) { outline: 2px solid var(--ring); outline-offset: 2px; }
.calc-out {
  padding: 1.25rem 1.35rem 1.35rem; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--card);
}
.calc-total {
  display: flex; align-items: baseline; gap: 0.35rem; margin: 0.35rem 0 0.9rem;
  font-family: var(--font-display); font-size: clamp(1.75rem, 1.1rem + 2.4vw, 2.6rem);
  line-height: 1.1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
.calc-total span { font-size: 0.45em; color: var(--muted-foreground); }
.calc-break {
  display: grid; gap: 0.2rem; margin: 0 0 0.9rem; padding: 0; list-style: none;
  font-size: var(--text-small);
}
.calc-break li { display: flex; justify-content: space-between; gap: 1rem; color: var(--muted-foreground); }
.calc-break li b { font-weight: 500; color: var(--foreground); font-variant-numeric: tabular-nums; white-space: nowrap; }
.calc-rows { display: grid; gap: 0.3rem; margin: 0 0 1rem; }
.calc-rows > div {
  display: flex; justify-content: space-between; gap: 1rem;
  padding-bottom: 0.3rem; border-bottom: 1px solid var(--border);
}
.calc-rows dt { margin: 0; color: var(--muted-foreground); font-size: var(--text-small); }
.calc-rows dd { margin: 0; font-size: var(--text-small); font-variant-numeric: tabular-nums; text-align: right; }
.calc-includes { margin: 0.35rem 0 0.9rem; }
.calc-note { margin: 0 0 0.9rem; }
.calc-note:empty { display: none; }
.calc-msg { margin: 0.6rem 0 0; }
.worry {
  display: grid; gap: 1px; overflow: hidden;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--border);
}
@media (min-width: 760px) { .worry { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.worry > div { padding: 1.1rem 1.2rem 1.2rem; background: var(--card); }
.worry h3 { margin: 0 0 0.35rem; font-size: 1rem; line-height: 1.5; }
.worry p { margin: 0; font-size: var(--text-small); color: var(--muted-foreground); }
.worry .tag {
  display: block; margin-bottom: 0.3rem; font-family: var(--font-mono);
  font-size: 0.68rem; letter-spacing: var(--tracking-label); color: var(--accent-foreground);
}

.calc-includes { display: grid; gap: 4px; }
.calc-includes li { position: relative; padding-left: 13px; color: var(--muted-foreground); }
.calc-includes li::before {
  content: ""; position: absolute; left: 0; top: 0.72em;
  width: 5px; height: 1px; background: var(--field-border);
}
