/* IAX lab — 2026 편집형 산업 디자인 시스템
   원칙: 종이처럼 읽히는 본문, 계기판처럼 정확한 수치 표기, 장식은 최소.
   CSP(style-src 'self') 아래서 동작: 인라인 style 없음, 외부 글꼴 없음. */

/* ───────── 1. 토큰 ───────── */
:root {
  color-scheme: light;
  --paper: #f6f4ee;
  --paper-2: #efece4;
  --surface: #fffdf8;
  --ink: #16171a;
  --ink-2: #2b2d32;
  --muted: #5b5d63;
  --faint: #8a8b8f;
  --line: #dedad0;
  --line-strong: #c9c4b7;
  --accent: #7a5a1c;          /* 본문 위 강조 글자: 대비 6.5:1 */
  --accent-wash: #efe5cd;
  --brass: #e6d8b7;           /* 브랜드 점·다크 영역 강조 */
  --signal: #1f7a68;          /* 운영 중 */
  --signal-wash: #dcefe9;
  --caution: #9a3b22;
  --caution-wash: #f6e3dc;
  --note-wash: #e7ecf2;
  --note: #2d4a6b;
  --shadow: 0 1px 0 #0000000a, 0 12px 32px -12px #2a22101f;
  --panel: #0f1114;           /* 계기판 영역은 테마와 무관하게 어둡게 */
  --panel-2: #171a1f;
  --panel-ink: #eef0f2;
  --panel-muted: #a9adb4;
  --panel-line: #2a2e35;

  --font-sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Noto Sans CJK KR", "Malgun Gothic", system-ui, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", "Cascadia Mono", Menlo, Consolas, monospace;

  --step--1: 0.8125rem;                                   /* 13px — 가독성 하한 */
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --step-1: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --step-2: clamp(1.375rem, 1.2rem + 0.8vw, 1.75rem);
  --step-3: clamp(1.75rem, 1.4rem + 1.6vw, 2.625rem);
  --step-4: clamp(2.25rem, 1.6rem + 3.2vw, 4.25rem);
  --step-5: clamp(2.6rem, 1.6rem + 4.6vw, 5.5rem);

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1320px;
  --radius: 14px;
  --radius-sm: 8px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --header-h: 68px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #0e0f12;
    --paper-2: #131519;
    --surface: #16181c;
    --ink: #f2f0ea;
    --ink-2: #dddad2;
    --muted: #a8aaaf;
    --faint: #7d8086;
    --line: #26292f;
    --line-strong: #363a42;
    --accent: #e6d8b7;
    --accent-wash: #2a261d;
    --signal: #5fd0b6;
    --signal-wash: #12302a;
    --caution: #f0a58c;
    --caution-wash: #33201a;
    --note-wash: #18222e;
    --note: #9fc0e4;
    --shadow: 0 1px 0 #ffffff08, 0 18px 40px -18px #000c;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0e0f12;
  --paper-2: #131519;
  --surface: #16181c;
  --ink: #f2f0ea;
  --ink-2: #dddad2;
  --muted: #a8aaaf;
  --faint: #7d8086;
  --line: #26292f;
  --line-strong: #363a42;
  --accent: #e6d8b7;
  --accent-wash: #2a261d;
  --signal: #5fd0b6;
  --signal-wash: #12302a;
  --caution: #f0a58c;
  --caution-wash: #33201a;
  --note-wash: #18222e;
  --note: #9fc0e4;
  --shadow: 0 1px 0 #ffffff08, 0 18px 40px -18px #000c;
}

/* ───────── 2. 바탕 ───────── */
@view-transition { navigation: auto; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 20px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.75;
  word-break: keep-all;
  overflow-wrap: anywhere;
  line-break: strict;
  font-feature-settings: "ss01", "tnum" 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
/* 아주 옅은 종이 결 — data URI(img-src data:)만 사용 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
body > * { position: relative; z-index: 1; }
img, svg, canvas { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
h1, h2, h3 { text-wrap: balance; font-weight: 700; letter-spacing: -0.025em; line-height: 1.28; }
p, li, dd { text-wrap: pretty; }
button { font: inherit; color: inherit; cursor: pointer; }
button, a, summary { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent-wash); color: var(--ink); }
.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; }
.skip { position: fixed; left: 12px; top: -80px; z-index: 100; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: var(--radius-sm); }
.skip:focus { top: 12px; }

.wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; letter-spacing: 0; }
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: currentColor; }
.lede { font-size: var(--step-1); color: var(--ink-2); line-height: 1.7; max-width: 46ch; }

/* ───────── 3. 버튼·배지 ───────── */
.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 600;
  font-size: 15px;
  border: 1px solid var(--ink);
  transition: transform .25s var(--ease), background .25s, color .25s;
  white-space: nowrap;
}
.button:hover { transform: translateY(-1px); }
.button.secondary { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.button.secondary:hover { border-color: var(--ink); }
.button.ghost { background: transparent; color: inherit; border-color: transparent; padding-inline: 4px; }
.arrow { display: inline-block; transition: transform .3s var(--ease); }
a:hover .arrow, button:hover .arrow { transform: translate(2px, -2px); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--step--1);
  line-height: 1;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  white-space: nowrap;
  font-weight: 500;
}
.badge.live { color: var(--signal); border-color: color-mix(in srgb, var(--signal) 40%, transparent); background: var(--signal-wash); }
.badge.live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 25%, transparent); }
@media (prefers-reduced-motion: no-preference) {
  .badge.live::before { animation: pulse 2.4s var(--ease) infinite; }
}
@keyframes pulse { 50% { box-shadow: 0 0 0 6px transparent; } }
.tag {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  color: var(--accent);
  letter-spacing: .02em;
}

/* ───────── 4. 머리글 ───────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { height: 100%; display: flex; align-items: center; gap: 28px; }
.logo { font-weight: 900; font-size: 26px; letter-spacing: -0.06em; line-height: 1; display: inline-flex; align-items: baseline; }
.logo span { color: var(--accent); }
:root[data-theme="dark"] .logo span { color: var(--brass); }
.primary-nav { display: flex; align-items: center; gap: 4px; margin-left: 12px; font-size: 15px; }
.primary-nav > a, .nav-services > summary {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--ink-2);
  transition: background .2s;
  list-style: none;
  cursor: pointer;
}
.nav-services > summary::-webkit-details-marker { display: none; }
.primary-nav > a:hover, .nav-services > summary:hover, .primary-nav > a[aria-current="page"] { background: var(--paper-2); color: var(--ink); }
.nav-services { position: relative; }
.nav-services > summary::after { content: "▾"; font-size: 11px; margin-left: 6px; color: var(--faint); }
.nav-services-panel {
  position: absolute;
  top: calc(100% + 10px);
  left: -8px;
  width: 340px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 8px;
  display: grid;
}
.nav-services-panel a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px; border-radius: 10px; }
.nav-services-panel a:hover { background: var(--paper-2); }
.header-tools { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.icon-btn {
  height: 40px;
  min-width: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
  font-size: 14px;
}
.icon-btn:hover { border-color: var(--line-strong); color: var(--ink); }
.icon-btn svg { width: 18px; height: 18px; }
.kbd { font-family: var(--font-mono); font-size: 13px; border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; color: var(--faint); }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
.header-cta { min-height: 40px; font-size: 14px; padding: 0 16px; }
.mobile-menu { display: none; }
.read-progress {
  position: absolute;
  left: 0;
  bottom: -1px;
  height: 2px;
  width: 100%;
  background: var(--accent);
  transform-origin: 0 50%;
  transform: scaleX(0);
}
@supports (animation-timeline: scroll()) {
  .read-progress { animation: progress linear both; animation-timeline: scroll(root); }
}
@keyframes progress { to { transform: scaleX(1); } }

/* ───────── 5. 공통 섹션 ───────── */
main { display: block; }
.section { padding-block: clamp(56px, 8vw, 120px); }
.section + .section { border-top: 1px solid var(--line); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 20px 40px; margin-bottom: clamp(28px, 4vw, 48px); }
.section-head h2 { font-size: var(--step-3); max-width: 22ch; }
.section-head p { color: var(--muted); max-width: 52ch; grid-column: 1 / -1; }
.section-head .more { font-size: 15px; color: var(--ink-2); display: inline-flex; gap: 8px; align-items: center; border-bottom: 1px solid var(--line-strong); padding-bottom: 2px; }
.section-head .more:hover { border-color: var(--ink); }

/* ───────── 6. 홈 히어로 ───────── */
.hero { padding-top: clamp(40px, 7vw, 96px); padding-bottom: clamp(40px, 6vw, 80px); overflow: clip; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: end; }
.hero h1 { font-size: var(--step-5); letter-spacing: -0.045em; line-height: 1.12; margin-top: 22px; }
.hero h1 em { font-style: normal; color: var(--accent); white-space: nowrap; }
.hero .lede { margin-top: 24px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.signal-strip {
  margin-top: clamp(36px, 5vw, 56px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
}
.signal-strip div { padding: 16px 16px 0 0; }
.signal-strip div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.signal-strip dt { font-family: var(--font-mono); font-size: var(--step--1); color: var(--faint); letter-spacing: .06em; }
.signal-strip dd { font-size: 15px; color: var(--ink-2); margin-top: 4px; line-height: 1.5; }

.console-frame {
  position: relative;
  border-radius: calc(var(--radius) + 6px);
  padding: 8px;
  background: linear-gradient(180deg, #2a2d33, #121418);
  box-shadow: 0 40px 80px -30px #1a140a66, 0 0 0 1px #ffffff14 inset;
}
.console-frame::before {
  content: "";
  position: absolute;
  inset: 8px 8px auto;
  height: 28px;
  border-radius: var(--radius) var(--radius) 0 0;
  background: #1b1e23;
  border-bottom: 1px solid #ffffff10;
}
.console-frame .dots { position: absolute; top: 18px; left: 22px; display: flex; gap: 6px; z-index: 1; }
.console-frame .dots i { width: 9px; height: 9px; border-radius: 50%; background: #3a3e45; }
.console-frame img { border-radius: 0 0 var(--radius) var(--radius); margin-top: 28px; }
.console-caption { display: flex; justify-content: space-between; gap: 12px; margin-top: 12px; font-size: var(--step--1); color: var(--muted); }
.console-caption a { border-bottom: 1px solid var(--line-strong); margin-left: auto; }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) and (min-width: 900px) {
    .hero .console-frame { animation: tilt linear both; animation-timeline: view(); animation-range: cover 0% cover 60%; }
  }
}
@keyframes tilt {
  from { transform: perspective(1400px) rotateX(9deg) rotateY(-8deg) translateY(20px); }
  to { transform: perspective(1400px) rotateX(0) rotateY(0) translateY(0); }
}

/* 스크롤 진입 — 지원 브라우저에서만, 움직임 줄이기 존중 */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal { animation: reveal linear both; animation-timeline: view(); animation-range: entry 5% cover 22%; }
  }
}
@keyframes reveal { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }

/* ───────── 7. 벤토(LineCare가 보는 것) ───────── */
.bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 14px; }
.tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(20px, 2.4vw, 32px);
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}
.tile h3 { font-size: var(--step-2); }
.tile p { color: var(--muted); }
.tile.span-7 { grid-column: span 7; }
.tile.span-5 { grid-column: span 5; }
.tile.span-4 { grid-column: span 4; }
.tile.span-8 { grid-column: span 8; }
.tile.span-6 { grid-column: span 6; }
.tile.dark { background: var(--panel); color: var(--panel-ink); border-color: var(--panel-line); }
.tile.dark p { color: var(--panel-muted); }
.tile.media { padding: 0; overflow: hidden; }
.tile.media { position: relative; margin: 0; background: #11141a; }
.tile.media img { height: 100%; object-fit: cover; object-position: left top; }
.tile.media.map { aspect-ratio: 2160 / 1500; }
.tile.media figcaption { position: absolute; left: 14px; bottom: 12px; font-size: 13px; color: #c9ccd2; background: #0f1114cc; padding: 6px 10px; border-radius: 999px; }
.tile .num { font-family: var(--font-mono); font-size: var(--step--1); color: var(--faint); }
.chip-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0; }
.chip-list li { border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: 14px; color: var(--ink-2); background: var(--paper); }
.tile.dark .chip-list li { background: var(--panel-2); border-color: var(--panel-line); color: var(--panel-ink); }
.tile .button { align-self: flex-start; margin-top: auto; }
.tile.dark .button { background: var(--brass); color: #16171a; border-color: var(--brass); }

/* ───────── 8. 하는 일(색인 목록) ───────── */
.axis-index { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line-strong); }
.axis-index li { border-bottom: 1px solid var(--line); }
.axis-index a {
  display: grid;
  grid-template-columns: 64px minmax(0, 1.1fr) minmax(0, 1.6fr) auto;
  gap: 24px;
  align-items: center;
  padding: 26px 4px;
  transition: background .25s, padding .35s var(--ease);
}
.axis-index a:hover { background: var(--surface); padding-inline: 16px; }
.axis-index .idx { font-family: var(--font-mono); color: var(--faint); font-size: 15px; }
.axis-index h3 { font-size: var(--step-2); }
.axis-index p { color: var(--muted); font-size: 15px; }
.axis-index .end { display: flex; align-items: center; justify-content: flex-end; gap: 16px; min-width: 170px; }
.axis-note { margin: 18px 0 0; font-size: 15px; color: var(--muted); }
.axis-note a { border-bottom: 1px solid var(--line-strong); }

/* ───────── 9. 인사이트 카드 ───────── */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 14px; }
.post-card {
  container-type: inline-size;
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 250px;
  transition: border-color .25s, transform .35s var(--ease), box-shadow .35s;
}
.post-card:hover { border-color: var(--line-strong); transform: translateY(-3px); box-shadow: var(--shadow); }
.post-card .meta { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.post-card h3 { font-size: var(--step-1); line-height: 1.42; letter-spacing: -0.02em; }
.post-card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.post-card p { color: var(--muted); font-size: 15px; line-height: 1.65; }
.post-card .foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; font-size: var(--step--1); color: var(--faint); font-family: var(--font-mono); padding-top: 12px; border-top: 1px dashed var(--line); }
.post-card.feature { grid-column: 1 / -1; min-height: 0; padding: clamp(24px, 4vw, 48px); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 16px 48px; background: var(--panel); color: var(--panel-ink); border-color: var(--panel-line); }
.post-card.feature h3 { font-size: var(--step-3); line-height: 1.25; letter-spacing: -0.035em; }
.post-card.feature p { color: var(--panel-muted); font-size: var(--step-0); }
.post-card.feature .tag { color: var(--brass); }
:root[data-theme="dark"] .post-card.feature { background: radial-gradient(120% 140% at 100% 0%, #2a2519 0%, #15171b 55%); border-color: #3a3426; }
.post-card.feature .foot { border-color: var(--panel-line); color: var(--panel-muted); grid-column: 1 / -1; }
.post-card.feature ol { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; counter-reset: kp; align-content: start; }
.post-card.feature ol li { counter-increment: kp; display: grid; grid-template-columns: 28px 1fr; gap: 10px; font-size: 15px; color: var(--panel-ink); line-height: 1.6; padding-bottom: 10px; border-bottom: 1px solid var(--panel-line); }
.post-card.feature ol li::before { content: counter(kp, decimal-leading-zero); font-family: var(--font-mono); color: var(--brass); font-size: var(--step--1); padding-top: 3px; }
@container (max-width: 300px) { .post-card .foot span:first-child { display: none; } }

.topic-quad { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.topic-card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color .25s;
}
.topic-card:hover { border-color: var(--ink); }
.topic-card h3 { font-size: var(--step-1); }
.topic-card .count { font-family: var(--font-mono); font-size: 40px; line-height: 1; letter-spacing: -0.04em; color: var(--ink); }
.topic-card .count small { font-size: 14px; color: var(--faint); margin-left: 4px; letter-spacing: 0; }
.topic-card ul { list-style: none; padding: 0; margin: 4px 0 0; display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.topic-card ul li::before { content: "— "; color: var(--faint); }
.topic-card a.cover::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }

/* ───────── 10. 계기판(설명용 모형) ───────── */
.instrument { background: var(--panel); color: var(--panel-ink); border-radius: calc(var(--radius) + 6px); padding: clamp(20px, 3vw, 40px); border: 1px solid var(--panel-line); }
.instrument .section-head h2 { color: var(--panel-ink); }
.instrument .section-head p, .instrument .subtitle { color: var(--panel-muted); }
.instrument .badge { color: var(--panel-muted); border-color: var(--panel-line); }
.model-detail { border-top: 1px solid var(--panel-line); }
.model-detail:last-of-type { border-bottom: 1px solid var(--panel-line); }
.model-detail > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px; padding: 22px 0; font-size: var(--step-1); font-weight: 600; }
.model-detail > summary::-webkit-details-marker { display: none; }
.model-detail > summary::after { content: "+"; margin-left: auto; font-family: var(--font-mono); font-size: 22px; color: var(--panel-muted); transition: transform .3s var(--ease); }
.model-detail[open] > summary::after { transform: rotate(45deg); }
.model-body { padding-bottom: 28px; }
.model-body .subtitle { margin-bottom: 18px; font-size: 15px; }
.engine-wrap { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 20px; }
.engine-side { display: flex; flex-direction: column; gap: 16px; }
.eng-legend { display: grid; gap: 8px; }
.eng-row { display: grid; grid-template-columns: 12px 1fr auto; align-items: center; gap: 10px; padding: 10px 12px; background: var(--panel-2); border: 1px solid var(--panel-line); border-radius: 10px; font-size: 14px; }
.eng-dot { width: 10px; height: 10px; border-radius: 50%; }
.eng-dot.teal { background: #35d0c0; }
.eng-dot.ink { background: #edf2f8; }
.eng-dot.red { background: #e4573d; }
.eng-v { font-family: var(--font-mono); color: var(--panel-muted); font-size: 13px; }
.eng-cues { display: flex; flex-wrap: wrap; gap: 8px; }
.eng-btn { min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--panel-line); background: transparent; color: var(--panel-ink); font-size: 14px; }
.eng-btn:hover { border-color: var(--panel-muted); }
.engine-panel { background: #0a0c0f; border: 1px solid var(--panel-line); border-radius: 12px; padding: 12px; min-width: 0; }
.engine-panel canvas { width: 100%; height: auto; aspect-ratio: 2116 / 1120; }
.engine-cap { font-size: 13px; color: var(--panel-muted); margin-top: 8px; font-family: var(--font-mono); }
.demo-readout { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13px; color: var(--panel-muted); font-family: var(--font-mono); }
.demo-readout [data-active="true"] { color: #f2a33c; }
[data-df-engine-tooltip] { position: fixed; z-index: 60; pointer-events: none; background: #111; color: #eee; border: 1px solid #333; border-radius: 8px; padding: 6px 10px; font-size: 13px; }
.graph-legend { display: flex; gap: 20px; font-size: 13px; color: var(--panel-muted); margin-bottom: 10px; }
.graph-legend span::before { content: ""; display: inline-block; width: 18px; height: 2px; vertical-align: middle; margin-right: 8px; background: #35d0c0; }
.graph-legend span + span::before { background: #8b8f97; }
#graph-draw-module svg { width: 100%; height: auto; }
#graph-draw-module .gridline { stroke: #ffffff12; fill: none; }
#graph-draw-module .irregular { stroke: #8b8f97; stroke-width: 2; fill: none; opacity: .75; }
#graph-draw-module .periodic { stroke: #35d0c0; stroke-width: 3; fill: none; stroke-dasharray: var(--length, 2000); stroke-dashoffset: var(--length, 2000); transition: stroke-dashoffset 2.4s var(--ease); }
#graph-draw-module[data-entered="true"] .periodic { stroke-dashoffset: 0; }
#graph-draw-module .caption { font-size: 13px; color: var(--panel-muted); margin-top: 8px; font-family: var(--font-mono); }

/* ───────── 11. 현장 이미지 띠 ───────── */
.field-band { margin: 0; border-radius: calc(var(--radius) + 6px); overflow: hidden; position: relative; aspect-ratio: 21 / 8; }
.field-band img { width: 100%; height: 100%; object-fit: cover; }
.field-band figcaption { position: absolute; left: 20px; bottom: 18px; display: flex; gap: 10px; flex-wrap: wrap; }
.field-band figcaption span { background: #0f1114cc; color: #f2f0ea; padding: 8px 12px; border-radius: 999px; font-size: 13px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* ───────── 12. 문의 띠 ───────── */
.contact-band { padding-block: clamp(64px, 9vw, 128px); border-top: 1px solid var(--line); }
.contact-band .inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: end; }
.contact-band h2 { font-size: var(--step-4); letter-spacing: -0.045em; line-height: 1.1; }
.contact-band .mail { font-family: var(--font-mono); font-size: var(--step-2); border-bottom: 1px solid var(--line-strong); display: inline-block; margin-top: 18px; letter-spacing: -0.02em; }
.contact-band .mail:hover { border-color: var(--ink); }

/* ───────── 13. 바닥글 ───────── */
.site-footer { border-top: 1px solid var(--line); padding-block: 56px 32px; background: var(--paper-2); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.footer-grid p { color: var(--muted); font-size: 15px; max-width: 42ch; margin-top: 14px; }
.footer-heading { font-family: var(--font-mono); font-size: var(--step--1); color: var(--faint); letter-spacing: .06em; margin-bottom: 12px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.footer-col a { color: var(--ink-2); }
.footer-col a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.wordmark { font-weight: 900; letter-spacing: -0.07em; line-height: .8; font-size: clamp(88px, 22vw, 300px); color: transparent; -webkit-text-stroke: 1px var(--line-strong); margin-top: 48px; user-select: none; }
.wordmark span { -webkit-text-stroke: 0; color: var(--accent); }
.prototype { font-size: var(--step--1); color: var(--faint); margin-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ───────── 14. 하위 페이지 머리 ───────── */
.page-head { padding-block: clamp(40px, 6vw, 88px) clamp(28px, 4vw, 48px); border-bottom: 1px solid var(--line); }
.page-head h1 { font-size: var(--step-4); letter-spacing: -0.045em; line-height: 1.15; margin-top: 18px; max-width: 20ch; }
.page-head .lede { margin-top: 20px; }
.page-head .actions { margin-top: 26px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--muted); list-style: none; padding: 0; margin: 0; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--faint); }
.crumbs a:hover { color: var(--ink); }

.steps-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 14px; counter-reset: st; }
.steps-grid li { counter-increment: st; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; min-height: 140px; display: flex; flex-direction: column; justify-content: space-between; gap: 18px; }
.steps-grid li::before { content: counter(st, decimal-leading-zero); font-family: var(--font-mono); color: var(--accent); font-size: 14px; }
.steps-grid h3 { font-size: var(--step-1); }
.fit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 14px; }
.fit-grid .tile h3 { font-size: var(--step-1); }

/* 인사이트 목록: 주제 필터(CSS :has) + 검색 */
.filter-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-bottom: 28px; position: sticky; top: var(--header-h); z-index: 5; padding-block: 12px; background: color-mix(in srgb, var(--paper) 90%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; border: 0; padding: 0; margin: 0; }
.filters legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.filters label { position: relative; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong); font-size: 14px; cursor: pointer; color: var(--ink-2); background: var(--surface); transition: background .2s, color .2s, border-color .2s; }
.filters label .n { font-family: var(--font-mono); font-size: 13px; color: var(--faint); }
.filters input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.filters label:has(input:checked) { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.filters label:has(input:checked) .n { color: var(--paper); opacity: .7; }
.filters label:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }
.search-field { display: flex; align-items: center; gap: 8px; min-height: 40px; border: 1px solid var(--line-strong); border-radius: 999px; padding: 0 14px; background: var(--surface); min-width: min(100%, 280px); }
.search-field input { border: 0; background: transparent; font: inherit; font-size: 15px; color: var(--ink); width: 100%; outline: none; }
.search-field svg { width: 16px; height: 16px; color: var(--faint); flex: none; }
.insights-page:has(#f-ot-security-incidents:checked) .post-card:not([data-topic="ot-security-incidents"]),
.insights-page:has(#f-factory-pc:checked) .post-card:not([data-topic="factory-pc"]),
.insights-page:has(#f-ax-adoption:checked) .post-card:not([data-topic="ax-adoption"]),
.insights-page:has(#f-ai-training:checked) .post-card:not([data-topic="ai-training"]) { display: none; }
.post-card[hidden] { display: none; }
.empty-state { display: none; padding: 40px; text-align: center; color: var(--muted); border: 1px dashed var(--line-strong); border-radius: var(--radius); }
.empty-state.on { display: block; }

.question-index { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line-strong); }
.question-index li { border-bottom: 1px solid var(--line); }
.question-index a { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 18px; padding: 22px 4px; align-items: baseline; transition: padding .3s var(--ease), background .2s; }
.question-index a:hover { padding-inline: 14px; background: var(--surface); }
.question-index .idx { font-family: var(--font-mono); color: var(--faint); font-size: 14px; }
.question-index h3 { font-size: var(--step-1); }
.question-index p { color: var(--muted); font-size: 15px; margin-top: 6px; }
.question-index .q { font-family: var(--font-mono); font-size: 13px; color: var(--faint); display: block; margin-top: 6px; }

.contact-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; }
.contact-options a { position: relative; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 22px; min-height: 120px; display: flex; flex-direction: column; justify-content: space-between; transition: border-color .25s, transform .3s var(--ease); }
.contact-options a:hover { border-color: var(--ink); transform: translateY(-2px); }
.contact-options h2 { font-size: var(--step-1); }
.contact-options .sub { font-family: var(--font-mono); font-size: 13px; color: var(--faint); }
.text-link { border-bottom: 1px solid var(--line-strong); }
.text-link:hover { border-color: var(--ink); }

/* ───────── 15. 글 페이지 ───────── */
.article-head { padding-block: clamp(36px, 6vw, 80px) clamp(28px, 4vw, 44px); }
.article-head h1 { font-size: var(--step-4); letter-spacing: -0.045em; line-height: 1.16; margin-top: 22px; max-width: 22ch; }
.article-head .dek { font-size: var(--step-1); color: var(--ink-2); margin-top: 22px; max-width: 52ch; line-height: 1.7; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); align-items: center; }
.article-meta .mono { color: var(--ink-2); }
.article-meta .tools { margin-left: auto; display: flex; gap: 8px; }

.keypoints { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 18px 32px; }
.keypoints h2 { font-size: var(--step--1); font-family: var(--font-mono); letter-spacing: .08em; color: var(--accent); font-weight: 600; text-transform: uppercase; }
.keypoints ol { list-style: none; margin: 0; padding: 0; counter-reset: kp; display: grid; gap: 12px; }
.keypoints li { counter-increment: kp; display: grid; grid-template-columns: 32px 1fr; gap: 8px; font-weight: 500; line-height: 1.6; }
.keypoints li::before { content: counter(kp, decimal-leading-zero); font-family: var(--font-mono); font-size: 13px; color: var(--faint); padding-top: 4px; }

.article-layout { display: grid; grid-template-columns: 220px minmax(0, 720px) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); padding-block: clamp(36px, 5vw, 64px); align-items: start; }
.toc { position: sticky; top: calc(var(--header-h) + 28px); font-size: 14px; max-height: calc(100vh - var(--header-h) - 56px); overflow: auto; }
.toc p { font-family: var(--font-mono); font-size: var(--step--1); color: var(--faint); letter-spacing: .08em; margin-bottom: 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; display: grid; gap: 2px; }
.toc li { counter-increment: toc; }
.toc a { display: grid; grid-template-columns: 26px 1fr; padding: 7px 10px; border-radius: 8px; color: var(--muted); line-height: 1.45; transition: color .2s, background .2s; }
.toc a::before { content: counter(toc, decimal-leading-zero); font-family: var(--font-mono); font-size: 13px; color: var(--faint); padding-top: 2px; }
.toc a:hover { color: var(--ink); }
.toc a[aria-current="true"] { color: var(--ink); background: var(--paper-2); font-weight: 600; }
.toc a[aria-current="true"]::before { color: var(--accent); }
.toc-mobile { display: none; }

.prose { font-size: 17px; line-height: 1.9; color: var(--ink-2); counter-reset: h2; }
.prose > * + * { margin-top: 1.15em; }
.prose .lead { font-size: var(--step-1); line-height: 1.8; color: var(--ink); font-weight: 500; }
.prose h2 { counter-increment: h2; font-size: var(--step-2); color: var(--ink); margin-top: 2.6em; padding-top: 1.1em; border-top: 1px solid var(--line); display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: baseline; }
.prose h2::before { content: counter(h2, decimal-leading-zero); font-family: var(--font-mono); font-size: 14px; color: var(--accent); font-weight: 500; letter-spacing: 0; }
.prose h3 { font-size: var(--step-1); color: var(--ink); margin-top: 1.9em; }
.prose h2 + *, .prose h3 + * { margin-top: .8em; }
.prose strong { color: var(--ink); font-weight: 700; }
.prose a:not(.cite) { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .5em; }
.prose li::marker { color: var(--faint); }
.prose code { font-family: var(--font-mono); font-size: .88em; background: var(--paper-2); border: 1px solid var(--line); border-radius: 5px; padding: .08em .38em; color: var(--ink); word-break: break-all; }
.prose pre { background: var(--panel); color: var(--panel-ink); border-radius: var(--radius-sm); padding: 18px 20px; overflow-x: auto; font-size: 14px; line-height: 1.7; }
.prose pre code { background: none; border: 0; padding: 0; color: inherit; word-break: normal; font-size: inherit; }
.prose em { font-style: normal; color: var(--muted); }
.prose p > em:only-child { font-size: 15px; }

/* 알림 상자: 네 변 같은 테두리의 양식 카드. 머리줄(기호·제목·종류)과 본문을 점선으로 나눈다. 한쪽 색 막대는 쓰지 않는다. */
.callout { --k: var(--note); --k-wash: var(--note-wash); border: 1px solid color-mix(in srgb, var(--k) 28%, var(--line)); border-radius: 12px; background: var(--surface); padding: 0 20px 18px; overflow: hidden; }
.callout[data-kind="caution"] { --k: var(--caution); --k-wash: var(--caution-wash); }
.callout[data-kind="tip"] { --k: var(--signal); --k-wash: var(--signal-wash); }
.callout > * + * { margin-top: .6em; }
.callout-title { display: flex; align-items: center; gap: 10px; margin: 0 -20px 14px; padding: 12px 20px; background: color-mix(in srgb, var(--k-wash) 75%, transparent); border-bottom: 1px dashed color-mix(in srgb, var(--k) 30%, var(--line)); font-weight: 700; color: var(--ink); font-size: 15px; line-height: 1.5; }
.callout-title::before { content: "i"; flex: none; width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--k); color: var(--k); display: grid; place-items: center; font-family: var(--font-mono); font-size: 13px; font-weight: 700; line-height: 1; }
.callout[data-kind="caution"] .callout-title::before { content: "!"; }
.callout[data-kind="tip"] .callout-title::before { content: "✓"; }
.callout-title::after { content: "참고"; margin-left: auto; font-family: var(--font-mono); font-size: 13px; font-weight: 500; letter-spacing: .06em; color: var(--k); }
.callout[data-kind="caution"] .callout-title::after { content: "주의"; }
.callout[data-kind="tip"] .callout-title::after { content: "요령"; }
.callout p { font-size: 16px; line-height: 1.8; }

.prose ol.steps { list-style: none; padding: 0; counter-reset: step; display: grid; gap: 0; border-left: 1px solid var(--line-strong); margin-left: 14px; }
.prose ol.steps > li { counter-increment: step; position: relative; padding: 0 0 1.2em 30px; margin: 0; }
.prose ol.steps > li::before { content: counter(step); position: absolute; left: -15px; top: 2px; width: 29px; height: 29px; border-radius: 50%; background: var(--paper); border: 1px solid var(--line-strong); font-family: var(--font-mono); font-size: 13px; display: grid; place-items: center; color: var(--ink); }
.prose ol.steps > li > strong:first-child { display: block; color: var(--ink); }

.prose ul.checklist { list-style: none; padding: 0; display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.prose ul.checklist > li { margin: 0; padding: 12px 16px 12px 48px; position: relative; border-top: 1px solid var(--line); cursor: pointer; user-select: none; transition: background .2s; }
.prose ul.checklist > li:first-child { border-top: 0; }
.prose ul.checklist > li:hover { background: var(--paper); }
.prose ul.checklist > li::before { content: ""; position: absolute; left: 16px; top: 17px; width: 18px; height: 18px; border: 1.5px solid var(--line-strong); border-radius: 5px; background: var(--surface); transition: background .2s, border-color .2s; }
.prose ul.checklist > li[aria-checked="true"] { color: var(--muted); }
.prose ul.checklist > li[aria-checked="true"]::before { background: var(--signal); border-color: var(--signal); }
.prose ul.checklist > li[aria-checked="true"]::after { content: ""; position: absolute; left: 22px; top: 20px; width: 5px; height: 10px; border: solid var(--surface); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.checklist-note { font-size: 13px; color: var(--faint); font-family: var(--font-mono); margin-top: 8px !important; display: flex; justify-content: space-between; gap: 12px; }
.checklist-note button { border: 0; background: none; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; font-size: 13px; padding: 0; }

.prose dl.glossary { display: grid; grid-template-columns: minmax(110px, auto) 1fr; border-top: 1px solid var(--line); }
.prose dl.glossary dt, .prose dl.glossary dd { padding: 12px 0; border-bottom: 1px solid var(--line); }
.prose dl.glossary dt { font-weight: 700; color: var(--ink); padding-right: 20px; }

.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); background-image: linear-gradient(to right, var(--surface) 30%, transparent), linear-gradient(to left, var(--surface) 30%, transparent), linear-gradient(to right, #0000001a, transparent), linear-gradient(to left, #0000001a, transparent); background-position: left, right, left, right; background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%; background-repeat: no-repeat; background-attachment: local, local, scroll, scroll; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.6; }
.prose table.table-wide { min-width: 860px; }
.prose caption { text-align: left; padding: 12px 16px 0; font-size: 13px; color: var(--muted); font-family: var(--font-mono); }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.prose thead th { font-size: 13px; color: var(--muted); font-weight: 600; background: var(--paper-2); position: sticky; top: 0; white-space: nowrap; }
.prose tbody tr:last-child td { border-bottom: 0; }
.prose td:first-child { color: var(--ink); font-weight: 600; }
.prose table.table-wide td { height: 46px; }
.table-hint { font-size: 13px; color: var(--faint); font-family: var(--font-mono); }
/* 표가 넘치는 좁은 폭(800 미만)에서만 안내 줄을 보인다 */
@media (min-width: 800px) { .table-hint { display: none; } }

/* 인용 번호 → 팝오버 */
.nb { white-space: nowrap; }
.cite-wrap { line-height: 0; }
.cite { font-family: var(--font-mono); font-size: 13px; line-height: 1; padding: 2px 5px; margin-left: 2px; border-radius: 4px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--accent); vertical-align: 3px; transition: background .2s, border-color .2s; }
.cite:hover, .cite:focus-visible { background: var(--accent-wash); border-color: var(--accent); }
.cite-pop { margin: 0; inset: auto 16px 16px 16px; width: auto; max-width: 560px; margin-inline: auto; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); color: var(--ink); box-shadow: var(--shadow); padding: 16px 18px; font-size: 14px; line-height: 1.6; position: fixed; white-space: normal; text-align: left; font-weight: 400; }
.cite-pop::backdrop { background: transparent; }
.cite-pop .n { font-family: var(--font-mono); font-size: 13px; color: var(--accent); }
.cite-pop strong { display: block; margin-top: 4px; font-weight: 600; }
.cite-pop .loc { color: var(--muted); display: block; margin-top: 2px; }
.cite-pop .go { display: inline-flex; gap: 6px; margin-top: 10px; font-size: 13px; color: var(--accent); border-bottom: 1px solid currentColor; }

.article-end { display: grid; gap: clamp(36px, 5vw, 56px); margin-top: clamp(48px, 6vw, 72px); }
.end-block h2 { font-size: var(--step-2); margin-bottom: 18px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 0; font-weight: 600; display: grid; grid-template-columns: 28px 1fr 24px; gap: 8px; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "Q"; font-family: var(--font-mono); color: var(--accent); }
.faq summary::after { content: "+"; font-family: var(--font-mono); color: var(--faint); text-align: right; transition: transform .3s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .a { padding: 0 0 20px 36px; color: var(--ink-2); line-height: 1.85; }

.sources ol { list-style: none; margin: 0; padding: 0; counter-reset: none; border-top: 1px solid var(--line); }
.sources li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; line-height: 1.6; scroll-margin-top: calc(var(--header-h) + 20px); }
.sources li:target { background: var(--accent-wash); }
.sources .n { font-family: var(--font-mono); color: var(--accent); font-size: 14px; padding-top: 1px; }
.sources .t { color: var(--ink); font-weight: 600; }
.sources .pub, .sources .loc { color: var(--muted); }
.sources .url { display: inline-flex; gap: 6px; margin-top: 4px; font-family: var(--font-mono); font-size: 13px; color: var(--accent); word-break: break-all; }
.sources .url:hover { text-decoration: underline; text-underline-offset: 3px; }
.sources .acc { font-family: var(--font-mono); font-size: 13px; color: var(--faint); margin-left: 8px; }
.disclaimer { font-size: 14px; color: var(--muted); border: 1px dashed var(--line-strong); border-radius: var(--radius-sm); padding: 14px 16px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pager a { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; background: var(--surface); display: grid; gap: 6px; transition: border-color .25s; }
.pager a:hover { border-color: var(--ink); }
.pager .dir { font-family: var(--font-mono); font-size: 13px; color: var(--faint); }
.pager .next { text-align: right; }

/* ───────── 16. 검색 팔레트 ───────── */
.palette { width: min(640px, calc(100vw - 32px)); max-height: min(70vh, 640px); padding: 0; border: 1px solid var(--line-strong); border-radius: 18px; background: var(--surface); color: var(--ink); box-shadow: 0 40px 100px -20px #000a; margin: 12vh auto auto; overflow: hidden; }
.palette::backdrop { background: color-mix(in srgb, var(--paper) 40%, #0008); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.palette[open] { display: flex; flex-direction: column; }
@media (prefers-reduced-motion: no-preference) {
  .palette[open] { animation: pop .22s var(--ease); }
}
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }
.palette-input { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.palette-input svg { width: 18px; height: 18px; color: var(--faint); flex: none; }
.palette-input input { flex: 1; border: 0; background: transparent; font: inherit; font-size: 17px; color: var(--ink); outline: none; }
.palette-results { list-style: none; margin: 0; padding: 8px; overflow: auto; }
.palette-results li a { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 14px; border-radius: 10px; }
.palette-results li a .t { font-weight: 600; }
.palette-results li a .d { grid-column: 1; font-size: 13px; color: var(--muted); }
.palette-results li a .k { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-family: var(--font-mono); font-size: 13px; color: var(--faint); }
.palette-results li[aria-selected="true"] a { background: var(--paper-2); }
.palette-results mark { background: var(--accent-wash); color: inherit; border-radius: 3px; padding: 0 1px; }
.palette-foot { border-top: 1px solid var(--line); padding: 10px 18px; display: flex; gap: 16px; font-size: 13px; color: var(--faint); font-family: var(--font-mono); }
.palette-empty { padding: 28px; text-align: center; color: var(--muted); font-size: 15px; }

/* ───────── 17. 반응형 ───────── */
@media (max-width: 1180px) {
  .article-layout { grid-template-columns: 200px minmax(0, 1fr); }
  .article-layout > .rail { display: none; }
  .primary-nav { gap: 0; }
}
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .tile.span-7, .tile.span-5, .tile.span-4, .tile.span-8, .tile.span-6 { grid-column: 1 / -1; }
  .topic-quad { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
  .article-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { display: none; }
  .toc-mobile { display: block; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); margin-bottom: 8px; }
  .toc-mobile summary { padding: 14px 16px; cursor: pointer; font-weight: 600; font-size: 15px; }
  .toc-mobile ol { margin: 0; padding: 0 16px 16px 36px; font-size: 15px; display: grid; gap: 6px; }
  .toc-mobile a { color: var(--ink-2); }
  .post-card.feature { grid-template-columns: 1fr; }
  .keypoints { grid-template-columns: 1fr; }
  .engine-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .primary-nav, .header-cta, .search-label { display: none; }
  .mobile-menu { display: block; }
  .mobile-menu > summary { list-style: none; height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14px; }
  .mobile-menu > summary::-webkit-details-marker { display: none; }
  .mobile-menu[open] > summary .plus { transform: rotate(45deg); }
  .mobile-menu .plus { transition: transform .3s var(--ease); display: inline-block; }
  .mobile-menu nav { position: fixed; left: 0; right: 0; top: var(--header-h); bottom: 0; background: var(--paper); padding: 20px var(--gutter) 40px; overflow: auto; display: grid; align-content: start; gap: 2px; border-top: 1px solid var(--line); }
  .mobile-menu nav a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 18px; }
  .mobile-menu nav .menu-cta { justify-content: center; margin-bottom: 12px; border: 0; font-size: 16px; }
  .axis-index a { grid-template-columns: 40px minmax(0, 1fr); gap: 6px 14px; }
  .axis-index p { grid-column: 2; }
  .axis-index .end { grid-column: 2; }
  .section-head { grid-template-columns: 1fr; }
  .contact-band .inner { grid-template-columns: 1fr; }
  .signal-strip { grid-template-columns: 1fr; }
  .signal-strip div + div { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); padding-top: 12px; }
  .field-band { aspect-ratio: 4 / 3; }
  .pager { grid-template-columns: 1fr; }
  .article-meta .tools { margin-left: 0; width: 100%; }
}
@media (max-width: 560px) {
  .topic-quad { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .question-index a { grid-template-columns: 32px minmax(0, 1fr); }
  .question-index .arrow { display: none; }
  .prose { font-size: 16.5px; }
  .prose dl.glossary { grid-template-columns: 1fr; }
  .prose dl.glossary dt { border-bottom: 0; padding-bottom: 0; }
  .header-tools .theme-toggle { display: none; }
  .hero h1 { letter-spacing: -0.04em; }
}

/* ───────── 18. 인쇄(현장 점검표용) ───────── */
@media print {
  @page { margin: 16mm 14mm; }
  :root { --paper: #fff; --surface: #fff; --ink: #000; --ink-2: #111; --muted: #444; --line: #bbb; --line-strong: #888; --accent: #000; }
  body::before, .site-header, .site-footer, .toc, .toc-mobile, .contact-band, .pager, .article-meta .tools, .cite-pop, .related, .skip, .checklist-note button { display: none !important; }
  body { font-size: 11pt; background: #fff; }
  .article-layout { display: block; padding: 0; }
  .article-head { padding: 0 0 12pt; }
  .article-head h1 { font-size: 22pt; }
  .prose { font-size: 10.5pt; line-height: 1.7; }
  .prose h2 { break-after: avoid; }
  .table-scroll { overflow: visible; border: 0; background: none; }
  .prose table.table-wide { min-width: 0; }
  .prose th, .prose td { border: 1px solid #888; }
  .prose table.table-wide td { height: 26pt; }
  .cite { border: 0; padding: 0; color: #000; }
  .cite::before { content: "["; } .cite::after { content: "]"; }
  .sources .url::after { content: ""; }
  .faq details { display: block; } .faq .a { display: block; }
}
