:root {
  /* 촘촘 디자인 토큰. 색 이름은 예전 이름을 그대로 써서 기존 규칙이 새 색을 따르게 한다. */
  --bg: #f8fafb;
  --card: #ffffff;
  --text: #17252d;
  --sub: #4d5d66;
  --muted: #65757e;   /* 배경 #f8fafb 대비 4.5:1 이상 */
  --line: #e3e9ed;
  --line-strong: #cfd9de;
  --accent: #006b5f;  /* Deep Teal. 흰 바탕 대비 4.7:1 */
  --accent-hover: #006b5f;
  --accent-ink: #006b5f;  /* 민트 바탕 위 글자(5.4:1) */
  --accent-weak: #e3eeec; /* Mint */
  --on-accent: #ffffff;
  --chip: #eff3f5;
  --mark: #fff1b8;
  --ok: #12805c; --ok-weak: #e3f6ee;
  --warn: #b35c00; --warn-weak: #fff3e2;
  --danger: #c8323b; --danger-weak: #fdecec;
  --shadow-sm: 0 1px 2px rgba(15, 42, 50, .04), 0 1px 3px rgba(15, 42, 50, .05);
  --shadow-md: 0 4px 16px rgba(15, 42, 50, .07), 0 1px 3px rgba(15, 42, 50, .05);
  --shadow-lg: 0 12px 32px rgba(15, 42, 50, .12);
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px;
  --mono: ui-monospace, SFMono-Regular, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1417; --card: #162024; --text: #e7eef0; --sub: #b3c0c5; --muted: #8b9ca3;
    --line: #26343a; --line-strong: #34454c; --accent: #2bb3bf; --accent-hover: #4cc6d0; --accent-ink: #84dbe2;
    --accent-weak: #123a3e; --on-accent: #062428; --chip: #1e2a2f; --mark: #5c4b00;
    --ok: #5ed3a6; --ok-weak: #15302a; --warn: #ffb45e; --warn-weak: #3a2a15; --danger: #ff8a8f; --danger-weak: #3a1d20;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.3); --shadow-md: 0 4px 16px rgba(0,0,0,.35); --shadow-lg: 0 12px 32px rgba(0,0,0,.45);
  }
}
:root[data-theme="dark"] {
  --bg: #0e1417; --card: #162024; --text: #e7eef0; --sub: #b3c0c5; --muted: #8b9ca3;
  --line: #26343a; --line-strong: #34454c; --accent: #2bb3bf; --accent-hover: #4cc6d0; --accent-ink: #84dbe2;
  --accent-weak: #123a3e; --on-accent: #062428; --chip: #1e2a2f; --mark: #5c4b00;
  --ok: #5ed3a6; --ok-weak: #15302a; --warn: #ffb45e; --warn-weak: #3a2a15; --danger: #ff8a8f; --danger-weak: #3a1d20;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--text);
  font-family: "Pretendard Variable", Pretendard, -apple-system, "Segoe UI", sans-serif;
  font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased;
  min-height: 100vh; display: flex; flex-direction: column;
}
a { color: inherit; text-decoration: none; }
.wrap { width: 100%; max-width: 920px; margin: 0 auto; padding: 0 16px; }
main.wrap { flex: 1; padding-bottom: 56px; }
.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* 헤더 */
.top { background: color-mix(in srgb, var(--card) 92%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.top .wrap { max-width: 1120px; }
.top-in { display: flex; align-items: center; gap: 20px; height: 60px; }
.logo { font-weight: 800; font-size: 20px; white-space: nowrap; display: inline-flex; align-items: center; gap: 9px; letter-spacing: -0.04em; color: var(--text); }
.logo img { display: block; border-radius: 8px; }
.gnb { display: flex; gap: 2px; }
.gnb a { padding: 7px 12px; border-radius: var(--r-sm); color: var(--sub); font-size: 14.5px; font-weight: 600; white-space: nowrap; }
.gnb a:hover { background: var(--chip); color: var(--text); }
.gnb a[aria-current] { color: var(--accent-ink); background: var(--accent-weak); }
.top .search { flex: 1; max-width: 420px; margin-left: auto; }
.top-account { margin-left: auto; padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--text); white-space: nowrap; background: var(--card); }
.top .search:not([hidden]) ~ .top-account { margin-left: 0; }
.top-account:hover { border-color: var(--accent); color: var(--accent-ink); }
.mnav { display: none; position: relative; }
.mnav summary { list-style: none; cursor: pointer; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; color: var(--text); }
.mnav summary::-webkit-details-marker { display: none; }
.mnav summary:hover, .mnav[open] summary { background: var(--chip); }
.mnav-panel { position: absolute; right: 0; top: calc(100% + 8px); width: 230px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-lg); padding: 6px; display: grid; }
.mnav-panel a { padding: 11px 12px; border-radius: var(--r-sm); font-size: 15px; font-weight: 500; }
.mnav-panel a:hover, .mnav-panel a[aria-current] { background: var(--chip); }

/* 검색창 */
.search { display: flex; gap: 8px; align-items: center; }
.search input {
  flex: 1; min-width: 0; border: 1px solid var(--line-strong); background: var(--card); color: var(--text);
  border-radius: var(--r-md); padding: 0 14px; font: inherit; outline: none; transition: border-color .15s, box-shadow .15s;
}
.search input::placeholder { color: var(--muted); }
.search input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent); }
.search button {
  border: 0; border-radius: var(--r-md); background: var(--accent); color: var(--on-accent); font: inherit; font-weight: 700;
  padding: 0 18px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; transition: background .15s;
}
.search button:hover { background: var(--accent-hover); }
.search.small input, .search.small button { height: 40px; font-size: 14.5px; }
.search.small button { padding: 0 12px; }
.search.small .ico { width: 18px; height: 18px; }
/* 첫 화면 큰 검색창: 입력과 버튼을 한 상자에 담는다 */
.search.big { background: var(--card); border: 1.5px solid var(--line-strong); border-radius: 18px; padding: 7px 7px 7px 18px; gap: 10px; box-shadow: var(--shadow-md); transition: border-color .15s, box-shadow .15s; }
.search.big:focus-within { border-color: var(--accent); box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 14%, transparent), var(--shadow-md); }
.search.big .lead { color: var(--muted); width: 22px; height: 22px; }
.search.big input { border: 0; box-shadow: none !important; height: 52px; font-size: 18px; padding: 0; background: transparent; }
.search.big button { height: 52px; font-size: 16.5px; padding: 0 26px; border-radius: 13px; }

/* 첫 화면 */
.home { padding: 9vh 0 0; }
.hero { text-align: center; max-width: 680px; margin: 0 auto; }
.home h1 { font-size: clamp(30px, 5vw, 44px); line-height: 1.22; margin: 0 0 12px; letter-spacing: -0.035em; font-weight: 800; }
.home h1 em { font-style: normal; color: var(--accent); }
.hero-sub { margin: 0 0 30px; color: var(--sub); font-size: 17px; }
.hint { color: var(--muted); font-size: 13px; margin-top: 14px; word-break: keep-all; }
.examples { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px; margin-top: 12px; }
.ex-label { color: var(--muted); font-size: 12.5px; margin-right: 2px; }
.examples small { color: var(--muted); font-size: 11.5px; margin-left: 2px; }
.features { max-width: 920px; margin: 56px auto 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; text-align: left; }
.feature { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 18px 20px; box-shadow: var(--shadow-sm); transition: border-color .15s, transform .15s, box-shadow .15s; display: block; }
.feature:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.f-ico { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--accent-weak); color: var(--accent-ink); margin-bottom: 12px; }
.feature h2 { font-size: 15.5px; margin: 0 0 6px; letter-spacing: -0.02em; }
.feature h2::after { content: " →"; color: var(--muted); font-weight: 500; }
.feature p { margin: 0; color: var(--sub); font-size: 13.5px; line-height: 1.55; word-break: keep-all; }
/* 예전 첫 화면 소개 상자(.intro)는 다른 화면에서 쓰지 않지만 둘러보기 카드가 같은 모양을 쓴다 */
.intro-item { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 15px; display: block; }
a.intro-item:hover { border-color: var(--accent); }
.donate { margin-top: 8px; }
.donate a { color: var(--accent); font-weight: 600; }
.match-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.match-progress { width: 100%; height: 8px; margin-top: 8px; accent-color: var(--accent); }
button.badge { border: 1px solid transparent; cursor: pointer; font: inherit; font-size: 12px; }
button.badge.on { border-color: currentColor; font-weight: 700; }
.bulk-head .dl { display: flex; gap: 6px; }
.match-cols .match-info { grid-column: 1 / -1; margin: 0; color: var(--sub); font-size: 13.5px; }
.match-cols select { width: 100%; height: 36px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--text); font: inherit; font-size: 14px; padding: 0 8px; margin-top: 4px; }
@media (max-width: 560px) { .match-cols { grid-template-columns: 1fr; } }
.home-sec { max-width: 920px; margin: 48px auto 0; text-align: left; }
.home-sec h2 { font-size: 17px; margin: 0 0 10px; display: flex; justify-content: space-between; align-items: baseline; letter-spacing: -0.01em; }
.home-sec h2 a { font-size: 13px; font-weight: 500; color: var(--muted); }
.home-sec h2 a:hover { color: var(--accent); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 2px; }
.stat-label { color: var(--sub); font-size: 12.5px; }
.stat strong { font-size: 21px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat-sub { color: var(--muted); font-size: 11.5px; line-height: 1.4; word-break: keep-all; }
.stt-bar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; background: var(--chip); margin-top: 14px; }
.b-active, .d-active { background: var(--accent); }
.b-paused, .d-paused { background: #f2a43a; }
.b-closed, .d-closed { background: #c3cfd4; }
.stt-legend { margin: 8px 0 0; color: var(--sub); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.stt-legend span { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin: 0 5px 0 12px; }
.stt-legend span:first-child { margin-left: 0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .b-closed, :root:not([data-theme="light"]) .d-closed { background: #46565d; } }
:root[data-theme="dark"] .b-closed, :root[data-theme="dark"] .d-closed { background: #46565d; }

.meta { color: var(--muted); font-size: 13px; margin: 20px 2px 10px; }
.meta b { color: var(--text); font-weight: 700; }
.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
/* 결과 한 줄: 왼쪽은 상세로 가는 링크, 오른쪽은 사업자번호 복사 버튼 */
.item { display: flex; align-items: stretch; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-sm); transition: border-color .15s, box-shadow .15s; }
.item:hover { border-color: var(--accent); box-shadow: var(--shadow-md); }
.item > a { display: block; flex: 1; min-width: 0; padding: 15px 18px; border-radius: var(--r-md); }
.item .row1 { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.item .name { font-weight: 700; font-size: 16.5px; letter-spacing: -0.015em; margin-right: 2px; }
.item .no { color: var(--accent-ink); font-variant-numeric: tabular-nums; font-size: 14.5px; font-weight: 600; margin-left: auto; letter-spacing: .01em; }
.item .row2 { color: var(--sub); font-size: 13.5px; margin-top: 5px; }
.item .row2 span + span::before { content: "·"; margin: 0 6px; color: var(--muted); }
.item > .copy { align-self: center; margin: 0 14px 0 -6px; flex: none; }
mark { background: var(--mark); color: inherit; border-radius: 3px; padding: 0 1px; }

.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; line-height: 1.6; padding: 0 8px; border-radius: 6px; background: var(--chip); color: var(--sub); font-weight: 600; white-space: nowrap; vertical-align: 1px; }
.badge.corp { background: var(--accent-weak); color: var(--accent-ink); }
.badge.active { background: var(--ok-weak); color: var(--ok); }
.badge.active::before, .badge.closed::before, .badge.paused::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.closed { background: var(--danger-weak); color: var(--danger); }
.badge.paused { background: var(--warn-weak); color: var(--warn); }
button.badge::before { content: none !important; }

.pager { display: flex; justify-content: center; gap: 6px; margin-top: 20px; }
.pager button {
  min-width: 38px; height: 38px; border: 1px solid var(--line); background: var(--card); color: var(--text);
  border-radius: 8px; font: inherit; cursor: pointer;
}
.pager button[aria-current] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.pager button:disabled { opacity: .4; cursor: default; }

.empty { text-align: center; color: var(--sub); padding: 56px 16px; }
.empty .e-ico { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; background: var(--chip); color: var(--muted); margin-bottom: 14px; }
.empty .e-ico .ico { width: 26px; height: 26px; }
.empty .e-title { font-size: 17px; font-weight: 700; color: var(--text); margin: 0 0 6px; }
.empty p { margin: 4px 0; word-break: keep-all; }
.empty .tips { display: inline-block; text-align: left; margin: 14px 0 0; padding: 12px 16px 12px 32px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); color: var(--sub); font-size: 13.5px; }
.empty .tips li { margin: 2px 0; }
.empty.error .e-ico { background: var(--danger-weak); color: var(--danger); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 40px; padding: 0 18px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--card); color: var(--text); font: inherit; font-weight: 600; font-size: 14.5px; cursor: pointer; }
.btn:hover { border-color: var(--accent); color: var(--accent-ink); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn.primary:hover { background: var(--accent-hover); color: var(--on-accent); }
.empty .btn { margin-top: 16px; }

/* 불러오는 중: 결과 자리 모양 */
.skel { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.skel li { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px 18px; }
.skel i { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, var(--chip) 25%, var(--line) 50%, var(--chip) 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite linear; }
.skel i + i { margin-top: 10px; width: 62%; height: 10px; }
.skel i:first-child { width: 38%; height: 15px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.loading-bar { height: 4px; border-radius: 2px; background: var(--chip); overflow: hidden; margin: 12px 0 4px; position: relative; }
.loading-bar::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 35%; background: var(--accent); border-radius: 2px; animation: slide 1.1s infinite ease-in-out; }
@keyframes slide { from { left: -35%; } to { left: 100%; } }

/* 알림 토스트 */
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 12px); background: #17252d; color: #fff; padding: 11px 18px; border-radius: 12px; font-size: 14.5px; font-weight: 600; box-shadow: var(--shadow-lg); z-index: 60; opacity: 0; transition: opacity .18s, transform .18s; pointer-events: none; white-space: nowrap; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.toast::before { content: "\2713"; color: #9fd3c9; margin-right: 8px; }


.detail { margin-top: 24px; }
.detail h1 { font-size: 28px; line-height: 1.25; margin: 0 0 8px; letter-spacing: -0.03em; word-break: keep-all; font-weight: 800; }
.id-row { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 12px; font-size: 14px; color: var(--sub); }
.id-row span { display: inline-flex; align-items: center; gap: 6px; }
.id-row b { color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; font-size: 16px; letter-spacing: .01em; }
.id-row .copy { margin-left: 0; }
.title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.share {
  flex: none; border: 1px solid var(--line-strong); background: var(--card); color: var(--text); border-radius: 10px;
  font: inherit; font-size: 13.5px; font-weight: 600; padding: 7px 14px; cursor: pointer; margin-top: 2px;
}
.share:hover { border-color: var(--accent); color: var(--accent); }
.detail .sub { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.summary { margin: -6px 0 16px; color: var(--sub); font-size: 14.5px; line-height: 1.6; word-break: keep-all; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 6px 20px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.card h2 { font-size: 15px; color: var(--text); font-weight: 700; margin: 16px 0 4px; letter-spacing: -0.015em; }
dl { margin: 0; }
.kv { display: grid; grid-template-columns: 112px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.card h2 + dl .kv:first-child { border-top: 0; }
.kv dt { color: var(--sub); font-size: 14px; }
.kv dd { margin: 0; word-break: keep-all; overflow-wrap: anywhere; }
.kv dd .note { color: var(--muted); font-size: 12.5px; display: block; }
.copy {
  margin-left: 6px; border: 1px solid var(--line-strong); background: var(--card); color: var(--sub); border-radius: 7px;
  font: inherit; font-size: 12px; font-weight: 600; padding: 2px 9px; cursor: pointer; vertical-align: 1px; white-space: nowrap;
}
.copy:hover { border-color: var(--accent); color: var(--accent-ink); }
.copy.done { background: var(--accent-weak); border-color: transparent; color: var(--accent-ink); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.warn { color: var(--warn); font-size: 13px; }
.back { display: inline-block; color: var(--sub); font-size: 14px; margin-top: 18px; }

/* 자동완성 */
.search { position: relative; }
.suggest {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 20; margin: 0; padding: 6px; list-style: none;
  background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.08); text-align: left;
}
.suggest li { padding: 8px 10px; border-radius: 8px; cursor: pointer; display: flex; flex-direction: column; }
.suggest li.on, .suggest li:hover { background: var(--chip); }
.s-name { font-weight: 600; font-size: 15px; }
.s-sub { color: var(--muted); font-size: 12.5px; }

/* 필터 */
.filters { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.tabs { display: flex; gap: 4px; background: var(--chip); padding: 3px; border-radius: 10px; }
.tab { padding: 5px 14px; border-radius: 8px; font-size: 14px; color: var(--sub); }
.tab[aria-current] { background: var(--card); color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.filter-right { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.filter-right select, #sortSel, #secSel {
  height: 32px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--text); font: inherit; font-size: 14px; padding: 0 8px;
}
.chip { display: inline-block; padding: 4px 11px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); font-size: 13.5px; color: var(--sub); }
.chip.on { border-color: var(--accent); color: var(--accent); background: var(--accent-weak); font-weight: 600; }
.pg { min-width: 38px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); background: var(--card); border-radius: 8px; }
.pg[aria-current] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* 검색창 최근 기록(빈 검색창을 눌렀을 때) */
.suggest .s-head { padding: 8px 10px 4px; font-size: 12px; font-weight: 600; color: var(--muted); cursor: default; }
.suggest .s-head:hover { background: none; }
.suggest li[data-href] { flex-direction: row; justify-content: space-between; align-items: baseline; gap: 12px; }
.suggest li.s-q { justify-content: flex-start; gap: 6px; font-size: 15px; }
.suggest .s-foot { padding: 4px 6px 2px; border-top: 1px solid var(--line); margin-top: 4px; border-radius: 0; cursor: default; align-items: flex-end; }
.suggest .s-foot:hover { background: none; }
.suggest .s-foot button { border: 0; background: none; color: var(--muted); font: inherit; font-size: 12.5px; cursor: pointer; padding: 4px; }
.mini { list-style: none; margin: 0; padding: 0; }
.mini li a { display: flex; justify-content: space-between; gap: 12px; padding: 10px 2px; border-top: 1px solid var(--line); align-items: baseline; }
.mini li:first-child a { border-top: 0; }
.mini .no { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mini small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }

/* 상세 보조 */
.link { color: var(--accent); }
.none { color: var(--muted); }
.maps { display: flex; gap: 10px; margin-top: 4px; font-size: 13px; }
.maps a { color: var(--accent); }
.card .mini { padding-bottom: 6px; }

/* 안내 페이지 */
.doc { margin-top: 24px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 8px 22px 22px; }
.doc h1 { font-size: 22px; margin: 16px 0 10px; letter-spacing: -0.02em; }
.doc h2 { font-size: 16px; margin: 22px 0 6px; }
.doc p, .doc li { color: var(--sub); }
.doc ul { padding-left: 20px; margin: 6px 0; }
.doc-meta { font-size: 13px; color: var(--muted) !important; }
.todo { color: #d9480f; font-weight: 600; }
.table-wrap { overflow-x: auto; margin: 12px 0; }
.doc table { border-collapse: collapse; width: 100%; font-size: 14px; min-width: 560px; }
.doc table.narrow { min-width: 0; }
.doc th, .doc td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.doc th { color: var(--muted); font-weight: 600; font-size: 13px; }
/* 사업장 목록 (상세 카드 안) */
.card .table-wrap { margin: 6px 0 4px; }
table.sites { border-collapse: collapse; width: 100%; font-size: 13.5px; min-width: 520px; }
table.sites th, table.sites td { text-align: left; padding: 8px 6px; border-top: 1px solid var(--line); vertical-align: top; }
table.sites th { color: var(--muted); font-weight: 600; font-size: 12.5px; border-top: 0; }
table.sites td small { display: block; color: var(--muted); font-size: 12px; }
table.sites .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.card > .note { color: var(--muted); font-size: 12.5px; margin: 6px 0 12px; }
.fix-link { color: var(--muted); font-size: 13px; margin: 14px 2px 0; }

/* 요청 양식 */
.req { display: grid; gap: 14px; margin-top: 14px; }
.req label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.req input:not([type=radio]):not([type=checkbox]), .req textarea {
  font: inherit; font-weight: 400; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--card); color: var(--text);
}
.req input:focus, .req textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-weak); }
.req fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; }
.req legend { font-size: 14px; font-weight: 600; margin-bottom: 6px; width: 100%; }
.req .opt { display: flex; align-items: center; gap: 6px; font-weight: 400; color: var(--sub); }
.req .agree { align-items: flex-start; font-size: 13px; }
.req .agree input { margin-top: 3px; }
.req .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.req button { justify-self: start; border: 0; border-radius: 10px; background: var(--accent); color: var(--on-accent); font: inherit; font-weight: 600; padding: 11px 22px; cursor: pointer; }
.req button:disabled { opacity: .6; cursor: default; }
.form-msg { color: #d9480f; font-size: 13px; margin: 0; min-height: 1em; }
.done { margin-top: 14px; padding: 16px; border-radius: 12px; background: var(--accent-weak); }
.done p { margin: 4px 0; color: var(--text); }

.bulk-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
/* 관리 화면 */
.admin .chips { margin: 4px 0 12px; }
.req-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.req-list li { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: grid; gap: 6px; }
.req-list .row1 { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.req-list .row1 .no { margin-left: auto; color: var(--muted); font-size: 12.5px; }
.req-list .row2 { color: var(--sub); font-size: 13.5px; }
.req-list .msg { margin: 0; padding: 8px 10px; background: var(--chip); border-radius: 8px; white-space: pre-wrap; color: var(--text); font-size: 14px; }
.req-list .note { font: inherit; font-size: 13px; border: 1px solid var(--line); border-radius: 8px; padding: 6px 8px; background: var(--card); color: var(--text); }
.req-list .actions { display: flex; flex-wrap: wrap; gap: 6px; }
.req-list .actions button { border: 1px solid var(--line); background: var(--card); color: var(--sub); border-radius: 8px; font: inherit; font-size: 13px; padding: 4px 10px; cursor: pointer; }
.req-list .actions button:hover { border-color: var(--accent); color: var(--accent); }
.foot-links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-bottom: 8px; }
.foot-links a { color: var(--sub); }
.foot-links a:hover { color: var(--accent); }

.foot { color: var(--muted); font-size: 12.5px; border-top: 1px solid var(--line); padding: 26px 0 34px; background: var(--card); }
.foot-brand { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; color: var(--text); flex-wrap: wrap; }
.foot-brand img { border-radius: 6px; }
.foot-brand b { font-size: 16px; font-weight: 800; letter-spacing: -0.03em; }
.foot-brand span { color: var(--muted); font-size: 12.5px; }
.foot p { margin: 4px 0; }

@media (max-width: 860px) {
  .gnb, .top-account { display: none; }
  .mnav { display: block; margin-left: auto; }
  .top .search:not([hidden]) ~ .mnav { margin-left: 0; }
  .features { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .home { padding-top: 6vh; }
  .hero-sub { font-size: 15.5px; margin-bottom: 22px; }
  .features { grid-template-columns: 1fr; margin-top: 36px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .home-sec { margin-top: 36px; }
  .search.big { padding: 5px 5px 5px 14px; border-radius: 16px; }
  .search.big .lead { display: none; }
  .search.big input { height: 48px; font-size: 16px; }
  .search.big button { height: 48px; font-size: 15px; padding: 0 16px; }
  .item > a { padding: 14px; }
  .item .no { margin-left: 0; width: 100%; }
  .item > .copy { align-self: flex-end; margin: 0 12px 14px -4px; }
  .kv { grid-template-columns: 92px 1fr; }
  .detail h1 { font-size: 23px; }
  .top-in { gap: 10px; height: 56px; }
  /* 상단 검색창이 보일 때는 마크만 남겨 검색 버튼이 밀려나지 않게 한다. */
  .top-in:has(.search:not([hidden])) .logo span { display: none; }
  .toast { bottom: 20px; }
}

#secSel { max-width: 180px; }

/* 접근성 */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.search input:focus-visible { outline: none; }
.skip { position: absolute; left: 8px; top: -40px; background: var(--accent); color: var(--on-accent); padding: 8px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { top: 8px; }
.badge.cert { background: #eefbf3; color: #127a3f; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .badge.cert { background: #16301f; color: #6fd99a; } }
:root[data-theme="dark"] .badge.cert { background: #16301f; color: #6fd99a; }
.dym { font-size: 16px; margin-bottom: 14px !important; }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
/* 관리 화면: 운영 현황 */
.admin-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 6px 0 14px; }
.admin-tabs a { padding: 8px 12px; color: var(--sub); border-bottom: 2px solid transparent; margin-bottom: -1px; font-weight: 600; font-size: 14.5px; }
.admin-tabs a.on { color: var(--accent); border-bottom-color: var(--accent); }
.admin h2 { font-size: 16px; margin: 26px 0 8px; }
.admin h2 .sub, .admin .sub { color: var(--muted); font-size: 12.5px; font-weight: 400; }
.admin table.info { width: 100%; table-layout: fixed; }
.admin table.info th { width: 130px; white-space: nowrap; }
.admin table.info td { overflow-wrap: anywhere; }
.admin table.num td, .admin table.num th { text-align: right; white-space: nowrap; }
.admin table.num td:first-child, .admin table.num th:first-child { text-align: left; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 10px; }
.kpi { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: grid; gap: 2px; background: var(--card); }
.kpi span { color: var(--muted); font-size: 12.5px; }
.kpi b { font-size: 22px; color: var(--text); font-variant-numeric: tabular-nums; }
.kpi small { color: var(--muted); font-size: 12px; }
.kpi small a { color: var(--accent); }
@media (max-width: 640px) { .kpis { grid-template-columns: repeat(2, 1fr); } .admin table.info th { width: 84px; white-space: normal; } .admin table.info td { overflow-wrap: break-word; } }
.pbar { display: inline-block; width: 90px; height: 6px; border-radius: 3px; background: var(--chip); vertical-align: middle; margin-right: 6px; overflow: hidden; }
.pbar i { display: block; height: 100%; background: var(--accent); }
.spark { display: flex; align-items: flex-end; gap: 4px; height: 90px; margin: 4px 0 10px; }
.spark div { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; }
.spark i { display: block; width: 100%; max-width: 26px; min-height: 2px; background: var(--accent); border-radius: 3px 3px 0 0; opacity: .85; }
.spark span { font-size: 11px; color: var(--muted); }
.linkbtn { border: 0; background: none; color: var(--accent); font: inherit; cursor: pointer; padding: 0; }
/* 고용 추이·부정당제재 (상세) */
.card h2 small.muted { color: var(--muted); font-size: 12.5px; font-weight: 400; margin-left: 4px; }
.card > .alert { margin: 4px 0 10px; padding: 10px 12px; border-radius: 10px; background: #fff4e5; color: #8a4500; font-size: 13.5px; line-height: 1.55; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .card > .alert { background: #3a2a15; color: #ffcf99; } }
:root[data-theme="dark"] .card > .alert { background: #3a2a15; color: #ffcf99; }
table.sites.fin { min-width: 0; }
table.fin th:first-child { text-align: left; font-weight: 500; white-space: nowrap; }
table.fin tbody th { border-top: 1px solid var(--line); }
table.fin th.num { text-align: right; }
table.fin td.neg { color: var(--danger, #d92d20); }
.fin-facts { margin: 0 0 10px; font-weight: 600; }
table.emp td.bar { width: 40%; }
table.emp td.bar i { display: block; height: 8px; border-radius: 4px; background: var(--accent); opacity: .7; }
ul.sanctions { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
ul.sanctions li { border-top: 1px solid var(--line); padding-top: 10px; }
ul.sanctions li:first-child { border-top: 0; padding-top: 0; }
ul.sanctions li div { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 14px; }
ul.sanctions p { margin: 6px 0 2px; font-size: 13.5px; color: var(--sub); }
ul.sanctions small { color: var(--muted); font-size: 12px; }

/* 둘러보기(지역별·고용 증가·오래된 회사) */
.note { color: var(--muted); font-size: 12px; line-height: 1.55; margin: 10px 2px 0; word-break: keep-all; }
.area-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.area-chip { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); font-size: 13px; }
.area-chip span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.area-chip b { color: var(--muted); font-weight: 500; font-size: 12px; font-variant-numeric: tabular-nums; }
.area-chip:hover { border-color: var(--accent); }
.bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.bars li { display: grid; grid-template-columns: 170px 1fr 48px; align-items: center; gap: 10px; font-size: 13px; }
.bars .bl { color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bars .bt { height: 8px; background: var(--chip); border-radius: 4px; overflow: hidden; }
.bars .bt span { display: block; height: 100%; background: var(--accent); border-radius: 4px; }
.bars .bv { text-align: right; font-variant-numeric: tabular-nums; color: var(--sub); }
.topic-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.topic-grid h3 { font-size: 14.5px; margin: 0 0 6px; }
.topic-grid p { margin: 0; color: var(--sub); font-size: 13px; line-height: 1.5; word-break: keep-all; }
.topic-grid a:hover { border-color: var(--accent); }
.browse { max-width: 760px; margin: 0 auto; padding: 18px 0 30px; }
.browse h1 { font-size: 24px; margin: 6px 0 8px; letter-spacing: -0.02em; word-break: keep-all; }
.browse .lead { color: var(--sub); margin: 0 0 16px; line-height: 1.6; word-break: keep-all; }
.browse > .chips { margin: 0 0 14px; }
.browse-sec { margin-top: 28px; }
.browse-sec h2 { font-size: 16px; margin: 0 0 10px; }
.crumbs { font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crumbs a:hover { color: var(--accent); }
.crumbs i { font-style: normal; color: var(--line); }
.item .rank { color: var(--muted); font-size: 13px; min-width: 20px; font-variant-numeric: tabular-nums; }
.item .up { color: #e5484d; font-weight: 650; }
@media (max-width: 560px) {
  .area-grid { grid-template-columns: 1fr 1fr; }
  .topic-grid { grid-template-columns: 1fr; }
  .bars li { grid-template-columns: 110px 1fr 44px; }
  .browse h1 { font-size: 21px; }
}
.browse .item .no, .browse .item .no b { margin-left: auto; width: auto; white-space: nowrap; }
.browse .item .name { font-size: 15px; }
.browse .item .row1 { flex-wrap: nowrap; }
.browse .item .name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail .crumbs { margin-bottom: 8px; }
.faq details { border-top: 1px solid var(--line); padding: 11px 2px; }
.faq details:first-of-type { border-top: 0; }
.faq summary { cursor: pointer; font-weight: 600; font-size: 14.5px; list-style: none; display: flex; justify-content: space-between; gap: 10px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 8px 0 2px; color: var(--sub); font-size: 14px; line-height: 1.6; word-break: keep-all; }
.area-card .cmp-title { font-size: 14.5px; margin: 2px 0 8px; }
.stats.cmp { grid-template-columns: repeat(3, 1fr); }
.cmp-text { margin: 12px 2px 0; line-height: 1.65; font-size: 14px; word-break: keep-all; }
.cmp-more { margin: 8px 2px 14px; font-size: 14px; }
.area-card dl { margin-top: 10px; }
.bars .bl a:hover { color: var(--accent); text-decoration: underline; }
.code { color: var(--muted); font-size: 13px; }
@media (max-width: 560px) { .stats.cmp { grid-template-columns: 1fr 1fr 1fr; } .stats.cmp .stat strong { font-size: 16px; } }

/* API 안내·내 계정 */
.doc .tbl { min-width: 0; margin: 8px 0; }
.doc pre { background: var(--chip); border-radius: 10px; padding: 12px 14px; overflow-x: auto; font-size: 12.5px; line-height: 1.55; margin: 8px 0; }
.doc code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 0.92em; }
.doc :not(pre) > code { background: var(--chip); padding: 1px 5px; border-radius: 5px; }
.doc ol { padding-left: 20px; color: var(--sub); }
.login-btns { display: grid; gap: 8px; margin: 18px 0 10px; max-width: 360px; }
.login { display: block; text-align: center; padding: 12px; border-radius: 10px; font-weight: 600; font-size: 15px; border: 1px solid var(--line); }
.login.google { background: var(--card); color: var(--text); }
.login.kakao { background: #fee500; color: #191919; border-color: #fee500; }
.login.off { color: var(--muted); background: var(--chip); font-weight: 500; }
.acct { display: grid; gap: 6px; margin: 8px 0; }
.acct div { display: grid; grid-template-columns: 80px 1fr; }
.acct dt { color: var(--muted); font-size: 13.5px; }
.acct dd { margin: 0; }
.account button { margin-top: 6px; }
.account button.ghost { background: transparent; color: var(--sub); border: 1px solid var(--line); }
.account button.danger { color: #e5484d; }
.acct-actions { display: flex; gap: 8px; margin-top: 26px; }
.newkey { background: var(--accent-weak); border-radius: 10px; padding: 12px 14px; margin: 8px 0; }
.newkey code { word-break: break-all; font-size: 13.5px; }
.usage-bar { height: 8px; background: var(--chip); border-radius: 4px; overflow: hidden; max-width: 360px; }
.usage-bar span { display: block; height: 100%; background: var(--accent); }
.form-msg.err { color: #e5484d; }
.account button { border: 0; border-radius: 10px; background: var(--accent); color: var(--on-accent); font: inherit; font-weight: 600; padding: 10px 18px; cursor: pointer; }
.account button:disabled { opacity: 0.5; cursor: default; }
.account button.copy { padding: 4px 10px; font-size: 12.5px; margin-left: 8px; background: var(--card); color: var(--sub); border: 1px solid var(--line); }

/* 같은 업종·지역 안 위치 */
.stats.peer { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.stat-rank { color: var(--accent); font-size: 13px; font-weight: 600; }

/* 연혁·변경 이력 */
ol.timeline { list-style: none; margin: 4px 0 8px; padding: 0; border-left: 2px solid var(--line); }
ol.timeline li { position: relative; display: flex; gap: 12px; padding: 6px 0 6px 14px; font-size: 14px; line-height: 1.5; }
ol.timeline li::before { content: ""; position: absolute; left: -6px; top: 13px; width: 10px; height: 10px; border-radius: 50%; background: var(--card); border: 2px solid var(--accent); }
.tl-date { flex: none; width: 84px; color: var(--sub); font-variant-numeric: tabular-nums; }
.tl-text { min-width: 0; word-break: keep-all; overflow-wrap: anywhere; }
.tl-text small { display: block; color: var(--muted); font-size: 11.5px; }

/* ── 촘촘: 안내·작업 화면(대량조회·엑셀 매칭·계정) ── */
.doc { border-radius: var(--r-lg); box-shadow: var(--shadow-sm); padding: 10px 26px 26px; }
.doc h1 { font-size: 24px; letter-spacing: -0.03em; font-weight: 800; }
.doc h2 { letter-spacing: -0.015em; }
.lead-p { color: var(--sub); font-size: 15px; margin: 0 0 6px; word-break: keep-all; }
.req input:not([type=radio]):not([type=checkbox]), .req textarea { border-color: var(--line-strong); border-radius: var(--r-md); }
.req button, .account button:not(.copy):not(.ghost) { border-radius: var(--r-md); padding: 12px 24px; font-weight: 700; }
.req button:hover:not(:disabled) { background: var(--accent-hover); }
.req label { font-size: 14.5px; }
/* 단계 안내 */
.steps { list-style: none; display: flex; gap: 6px; padding: 0; margin: 14px 0 6px; flex-wrap: wrap; counter-reset: st; }
.steps li { counter-increment: st; display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--sub); background: var(--chip); border-radius: 999px; padding: 5px 13px 5px 6px; }
.steps li::before { content: counter(st); display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--card); color: var(--accent-ink); font-weight: 700; font-size: 12px; }
/* 지원 형식·제한 */
.specs { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 4px 0 2px; padding: 0; list-style: none; font-size: 13px; color: var(--muted); }
.specs li::before { content: "·"; margin-right: 6px; }
/* 파일 올리는 곳: 기본 파일 입력을 넓은 점선 상자로 */
.drop { position: relative; display: grid !important; place-items: center; gap: 4px !important; text-align: center; padding: 22px 16px; border: 1.5px dashed var(--line-strong); border-radius: var(--r-md); background: var(--bg); cursor: pointer; transition: border-color .15s, background .15s; font-weight: 600; }
.drop:hover, .drop.over { border-color: var(--accent); background: color-mix(in srgb, var(--accent-weak) 45%, var(--card)); }
.drop .ico { width: 26px; height: 26px; color: var(--accent); }
.drop small { color: var(--muted); font-weight: 400; font-size: 12.5px; }
.drop .fname { color: var(--accent-ink); font-size: 13.5px; }
.drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12.5px; margin: -2px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
/* 결과 요약 */
.sum-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin: 18px 0 6px; }
.sum-tiles > * { border: 1px solid var(--line); border-radius: var(--r-md); padding: 10px 12px; background: var(--card); text-align: left; font: inherit; color: var(--text); display: grid; gap: 2px; }
.sum-tiles span { font-size: 12.5px; color: var(--sub); }
.sum-tiles b { font-size: 20px; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.sum-tiles .t-ok b { color: var(--ok); }
.sum-tiles .t-warn b { color: var(--warn); }
.sum-tiles .t-bad b { color: var(--danger); }
.done-msg { display: flex; align-items: center; gap: 8px; margin: 18px 0 0; padding: 12px 14px; border-radius: var(--r-md); background: var(--accent-weak); color: var(--accent-ink); font-weight: 600; font-size: 14.5px; }
.done-msg::before { content: "\2713"; display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-size: 13px; }
.bulk-head .share, .bulk-head .dl .share { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.bulk-head .share:hover { background: var(--accent-hover); color: var(--on-accent); }
.bulk-head .dl .share + .share { background: var(--card); color: var(--text); border-color: var(--line-strong); }
.doc table th { background: var(--bg); }
.doc table tbody tr:hover td { background: color-mix(in srgb, var(--accent-weak) 30%, transparent); }
.match-cols { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px; }
.match-cols label { font-size: 13.5px; }
.form-msg:not(:empty) { padding: 2px 0; }
/* 필터·탭 */
.filters { padding: 10px 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-sm); }
.tab[aria-current] { color: var(--accent-ink); }
.chip { transition: border-color .15s, color .15s; }
.chip:hover { border-color: var(--accent); color: var(--accent-ink); }
.chip.on { color: var(--accent-ink); }
.pg { min-width: 38px; height: 38px; }
.pg:hover { border-color: var(--accent); }
/* 로그인 */
.login { border-radius: var(--r-md); padding: 13px; }
.login.google:hover { border-color: var(--accent); }
@media (max-width: 560px) {
  .doc { padding: 6px 18px 20px; }
  .filters { padding: 10px; }
  .steps li { font-size: 12.5px; }
}
@media (prefers-reduced-motion: reduce) { .skel i, .loading-bar::after { animation: none; } .feature:hover { transform: none; } }
.pager { flex-wrap: wrap; }
@media (max-width: 560px) { .pg { min-width: 34px; height: 36px; font-size: 14px; } .pager { gap: 4px; } }
@media (max-width: 560px) {
  .feature { display: grid; grid-template-columns: 38px 1fr; column-gap: 12px; padding: 14px 16px; }
  .feature .f-ico { margin: 0; grid-row: span 2; }
  .feature h2 { margin: 1px 0 3px; }
}
.doc table td:first-child { white-space: nowrap; }

/* ── 다듬기(2차): 폭 통일, 그림자 줄이기, 브랜드 표기 '사업자조회 촘촘' ── */
.wrap, .top .wrap { max-width: 960px; }
.logo { gap: 10px; }
.logo-t { display: inline-flex; align-items: center; font-size: 18px; font-weight: 800; letter-spacing: -0.03em; }
.logo-t b { color: var(--accent); margin-left: 8px; padding-left: 8px; border-left: 1.5px solid var(--line-strong); line-height: 1; }
.foot-brand em { font-style: normal; color: var(--accent); }
.eyebrow { display: inline-flex; gap: 6px; align-items: center; margin: 0 0 14px; padding: 5px 12px; border-radius: 999px; background: var(--accent-weak); color: var(--accent-ink); font-size: 13px; font-weight: 600; }
.eyebrow b { font-weight: 800; }
.home h1 { font-size: clamp(32px, 5.4vw, 48px); margin-bottom: 14px; }
.home h1 em { color: var(--accent); }
.hint { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 0; }
.hint span { white-space: nowrap; }
.hint span + span::before { content: "·"; margin: 0 8px; color: var(--line-strong); }
/* 카드류: 그림자 대신 얇은 테두리 */
.item, .card, .stat, .feature, .doc, .filters { box-shadow: none; }
.item:hover, .feature:hover { box-shadow: 0 6px 20px rgba(15, 42, 50, .06); }
.feature:hover { transform: none; }
.search.big { box-shadow: 0 6px 24px rgba(15, 42, 50, .07); }
/* 기능 카드: 2×2, 아이콘 왼쪽 */
.features { grid-template-columns: repeat(2, 1fr); gap: 10px; max-width: 760px; margin-top: 52px; }
.feature { display: grid; grid-template-columns: 40px 1fr; column-gap: 14px; padding: 16px 18px; border-radius: 14px; }
.feature .f-ico { grid-row: span 2; margin: 2px 0 0; width: 40px; height: 40px; }
.feature h2 { margin: 1px 0 4px; font-size: 15.5px; }
.feature p { font-size: 13.5px; }
.home-sec { max-width: 760px; }
/* 검색 필터: 상자 없이 한 줄 */
.filters { background: transparent; border: 0; padding: 0; margin-top: 20px; }
.meta { margin-top: 14px; }
/* 상세: 읽기 폭 */
.detail, .doc, .list, .skel, .browse { max-width: 820px; margin-left: auto; margin-right: auto; }
.filters, main > .meta, main > .empty, .pager { max-width: 820px; margin-left: auto; margin-right: auto; }
@media (max-width: 860px) { .features { max-width: none; } }
@media (max-width: 560px) {
  .logo-t { font-size: 16px; }
  .logo-t b { margin-left: 6px; padding-left: 6px; }
  .features { grid-template-columns: 1fr; margin-top: 32px; }
  .eyebrow { font-size: 12px; margin-bottom: 10px; }
  .home h1 { font-size: 30px; }
  .hint { font-size: 12.5px; }
}
.hint span:first-child { flex-basis: 100%; }
.hint span:nth-child(2)::before { content: none; }

/* ── 로그인·마이페이지 ── */
.auth { max-width: 440px; margin: 7vh auto 0; }
.auth-card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 34px 30px 26px; text-align: center; }
.auth-mark { border-radius: 13px; display: block; margin: 0 auto 16px; }
.auth h1 { font-size: 22px; margin: 0 0 8px; letter-spacing: -0.03em; font-weight: 800; }
.auth h1 em { font-style: normal; color: var(--accent); }
.auth-sub { color: var(--sub); font-size: 14.5px; line-height: 1.6; margin: 0 0 22px; }
.auth-err { margin: -6px 0 16px; padding: 9px 12px; border-radius: 10px; background: var(--danger-weak); color: var(--danger); font-size: 13.5px; }
.auth .login-btns { display: grid; gap: 10px; margin: 0; max-width: none; }
.auth .login { display: flex; align-items: center; justify-content: center; gap: 10px; height: 50px; padding: 0 16px; border-radius: 12px; font-size: 15.5px; font-weight: 600; position: relative; }
.auth .login svg { position: absolute; left: 18px; }
.auth .login.kakao { background: #fee500; border-color: #fee500; color: rgba(0, 0, 0, .85); }
.auth .login.kakao:hover { background: #f5dc00; }
.auth .login.google { background: #fff; color: #1f1f1f; border: 1px solid #dadce0; }
.auth .login.google:hover { background: #f8f9fa; }
.auth .login.off { justify-content: center; }
.auth-note { color: var(--muted); font-size: 12px; line-height: 1.6; margin: 20px 0 0; text-align: left; word-break: keep-all; }
.auth-foot { text-align: center; color: var(--muted); font-size: 13px; margin: 16px 0 0; }
.mypage { max-width: 820px; margin: 28px auto 0; }
.mp-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; flex-wrap: wrap; }
.mp-avatar { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; flex: none; border: 1px solid var(--line); background: #fff; }
.mp-avatar.k { background: #fee500; border-color: #fee500; }
.mp-who { flex: 1; min-width: 0; }
.mp-who h1 { font-size: 22px; margin: 0; letter-spacing: -0.03em; font-weight: 800; }
.mp-who p { margin: 2px 0 0; color: var(--sub); font-size: 13.5px; overflow-wrap: anywhere; }
.mp-head .btn { height: 36px; font-size: 13.5px; padding: 0 14px; }
.mp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mp-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px 22px; display: flex; flex-direction: column; }
.mp-card h2 { font-size: 15px; margin: 0 0 12px; display: flex; justify-content: space-between; align-items: baseline; }
.mp-card h2 small { color: var(--muted); font-weight: 500; font-size: 12.5px; }
.mp-key { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 14px; }
.mp-key code { font-family: var(--mono); background: var(--chip); padding: 4px 8px; border-radius: 6px; font-size: 13.5px; }
.mp-key span, .mp-empty { color: var(--muted); font-size: 13.5px; }
.mp-empty { margin: 0 0 14px; }
.mp-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.btn.ghost { border-color: transparent; color: var(--sub); }
.btn.danger { color: var(--danger); }
.btn.danger:hover { border-color: var(--danger); color: var(--danger); }
.mp-note { color: var(--muted); font-size: 12.5px; margin: 10px 0 0; line-height: 1.55; }
.mp-warn { color: var(--warn); font-size: 13px; margin: 6px 0 12px; }
.mp-usage { margin: 0 0 10px; display: flex; align-items: baseline; gap: 6px; }
.mp-usage b { font-size: 30px; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.mp-usage span { color: var(--muted); font-size: 14px; }
.mypage .usage-bar { max-width: none; }
.mypage .newkey { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; }
.mypage .newkey code { font-family: var(--mono); word-break: break-all; font-size: 13px; flex: 1; min-width: 0; }
.mp-danger { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; padding: 16px 22px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); flex-wrap: wrap; }
.mp-danger p { margin: 0; display: grid; gap: 2px; }
.mp-danger b { font-size: 14.5px; }
.mp-danger span { color: var(--muted); font-size: 13px; }
@media (max-width: 640px) { .mp-grid { grid-template-columns: 1fr; } .auth-card { padding: 28px 20px 22px; } .auth { margin-top: 3vh; } }
/* 헤더가 좁을 때 오른쪽 버튼이 잘리지 않게: 검색창이 먼저 줄어든다 */
.top-in > * { flex-shrink: 0; }
.top .search { flex: 1 1 200px; min-width: 0; }
@media (max-width: 1040px) { .gnb a { padding: 7px 9px; font-size: 14px; } .top-in { gap: 14px; } }
/* 마이페이지 추가 카드·관리 화면 보조 */
.mypage .mp-grid + .mp-grid, .mp-recent { margin-top: 12px; }
.mp-code { background: var(--chip); border-radius: 10px; padding: 12px 14px; overflow-x: auto; font-size: 12.5px; line-height: 1.6; margin: 0 0 12px; }
.mp-code code { font-family: var(--mono); white-space: pre; }
.mp-bars li { grid-template-columns: 70px 1fr 56px; }
.mp-recent .mini { margin-top: -4px; }
.mp-q { margin-top: 12px; }
.admin-jump { margin: 0 0 14px; }
.admin-h3 { font-size: 14px; margin: 18px 0 8px; }
.admin-h3 .sub { color: var(--muted); font-weight: 400; font-size: 12px; }
.admin table tr.total td { font-weight: 700; border-top: 2px solid var(--line); }
.admin .up { color: var(--ok); font-size: 12px; }
.admin .down { color: var(--danger); font-size: 12px; }
.admin .kpis { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 640px) { .admin .kpis { grid-template-columns: repeat(2, 1fr); } }
.spark div { min-width: 0; }
.spark.dense { gap: 2px; }
.spark.dense span { visibility: hidden; }
.spark.dense div:nth-child(5n+1) span, .spark.dense div:last-child span { visibility: visible; }
.admin table { min-width: 0; }
.admin table.wide { min-width: 640px; }
.mp-card { min-width: 0; }

/* ── 상세: 1장 출력 버튼 ── */
.title-actions { display: flex; gap: 6px; flex: none; }
.print-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; background: var(--accent); color: var(--on-accent); border-radius: 10px; font: inherit; font-size: 13.5px; font-weight: 700; padding: 7px 14px; cursor: pointer; margin-top: 2px; }
.print-btn:hover { background: var(--accent-hover); }
.print-btn .ico { width: 17px; height: 17px; }
.print-btn:disabled { opacity: .7; cursor: default; }
@media (max-width: 560px) { .title-row { flex-wrap: wrap; } .title-actions { width: 100%; } .title-actions > * { flex: 1; justify-content: center; } }

/* ── 기업정보 1장 출력(A4 세로). 화면에는 숨기고 인쇄할 때만 보인다. ── */
.print-sheet { display: none; }
@page { size: A4 portrait; margin: 0; }
@media print {
  html, body { background: #fff !important; min-height: 0; }
  body > *:not(#printSheet) { display: none !important; }
  #printSheet { display: block; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
.ps-page { width: 210mm; height: 296mm; padding: 12mm 13mm 10mm; box-sizing: border-box; color: #17252d; font-family: "Pretendard Variable", Pretendard, sans-serif;
  font-size: 9.2pt; line-height: 1.5; display: flex; flex-direction: column; gap: 3.2mm; overflow: hidden; background: #fff; }
.ps-top { display: flex; justify-content: space-between; align-items: center; padding-bottom: 3mm; border-bottom: 2px solid #006b5f; }
.ps-brand { display: flex; align-items: center; gap: 2mm; font-size: 12pt; letter-spacing: -0.03em; }
.ps-brand b { font-weight: 800; }
.ps-brand em { font-style: normal; font-weight: 800; color: #006b5f; padding-left: 2mm; border-left: 1px solid #cfd9de; }
.ps-doc { text-align: right; display: grid; }
.ps-doc b { font-size: 11pt; letter-spacing: -0.02em; }
.ps-doc span { color: #65757e; font-size: 8pt; }
.ps-hero { padding: 1mm 0 0; }
.ps-badges { display: flex; gap: 1.5mm; margin-bottom: 1.5mm; }
.ps-badge { font-size: 7.8pt; font-weight: 600; padding: 0.3mm 2.2mm; border-radius: 1.5mm; background: #eff3f5; color: #4d5d66; }
.ps-badge.ok { background: #e3f6ee; color: #12805c; }
.ps-badge.warn { background: #fff3e2; color: #b35c00; }
.ps-badge.bad { background: #fdecec; color: #c8323b; }
.ps-hero h1 { font-size: 22pt; line-height: 1.2; margin: 0; letter-spacing: -0.035em; font-weight: 800; }
.ps-eng { margin: 0.5mm 0 0; color: #65757e; font-size: 9pt; letter-spacing: 0.01em; }
.ps-ids { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5mm; margin-top: 3mm; }
.ps-ids div { background: #f6f8f8; border: 1px solid #e3eeec; border-radius: 2.5mm; padding: 2mm 3mm; display: grid; }
.ps-ids span { color: #4d5d66; font-size: 7.6pt; }
.ps-ids b { font-size: 12pt; letter-spacing: 0.01em; font-variant-numeric: tabular-nums; color: #006b5f; }
.ps-summary { margin: 0; color: #4d5d66; font-size: 8.8pt; line-height: 1.6; word-break: keep-all; }
.ps-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3mm; }
.ps-box { border: 1px solid #e3e9ed; border-radius: 3mm; padding: 2.8mm 3.5mm 3mm; break-inside: avoid; min-width: 0; }
.ps-box h2 { font-size: 9.8pt; margin: 0 0 1.8mm; letter-spacing: -0.02em; display: flex; align-items: center; gap: 1.5mm; }
.ps-box h2::before { content: ""; width: 1.2mm; height: 3.4mm; border-radius: 1mm; background: #006b5f; }
.ps-box h2 small { color: #65757e; font-weight: 500; font-size: 7.6pt; margin-left: auto; }
.ps-kv { width: 100%; border-collapse: collapse; }
.ps-kv th, .ps-kv td { text-align: left; vertical-align: top; padding: 1mm 0; border-top: 1px solid #eef2f4; font-size: 8.6pt; }
.ps-kv tr:first-child th, .ps-kv tr:first-child td { border-top: 0; }
.ps-kv th { width: 17mm; color: #65757e; font-weight: 500; white-space: nowrap; }
.ps-kv td { word-break: keep-all; overflow-wrap: anywhere; }
.ps-kv small { color: #65757e; }
.ps-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 2mm; }
.ps-tile { background: #f8fafb; border-radius: 2mm; padding: 2mm 2.5mm; display: grid; }
.ps-tile span { color: #65757e; font-size: 7.6pt; }
.ps-tile b { font-size: 12pt; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.ps-tile small { color: #65757e; font-size: 7.2pt; }
.ps-trend { margin-top: 2.5mm; }
.ps-trend span { color: #65757e; font-size: 7.6pt; display: block; margin-bottom: 1mm; }
.ps-spark { display: block; }
.ps-fin table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.ps-fin th, .ps-fin td { padding: 1mm 1.5mm; border-top: 1px solid #eef2f4; font-size: 8.6pt; text-align: right; }
.ps-fin thead th { border-top: 0; color: #65757e; font-weight: 600; font-size: 7.8pt; background: #f8fafb; }
.ps-fin tbody th { text-align: left; font-weight: 500; color: #4d5d66; }
.ps-fin td.neg { color: #c8323b; }
.ps-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.2mm; }
.ps-list li { font-size: 8.4pt; line-height: 1.45; padding-left: 3mm; position: relative; word-break: keep-all; }
.ps-list li::before { content: ""; position: absolute; left: 0; top: 1.8mm; width: 1.2mm; height: 1.2mm; border-radius: 50%; background: #006b5f; }
.ps-checks li::before { background: #b35c00; }
.ps-list small, .ps-more { color: #65757e; }
.ps-none, .ps-ok { margin: 0; color: #65757e; font-size: 8.4pt; }
.ps-ok::before { content: "✓ "; color: #12805c; font-weight: 700; }
.ps-foot { margin-top: auto; padding-top: 2.5mm; border-top: 1px solid #e3e9ed; color: #65757e; font-size: 7.4pt; line-height: 1.55; }
.ps-foot p { margin: 0.4mm 0; }
.ps-foot b { color: #4d5d66; }
.ps-url { color: #006b5f !important; font-weight: 600; }
.ps-tiles4 { grid-template-columns: repeat(4, 1fr); }
/* 한 장에 다 들어가도록 간격을 줄인 값(재무·지역 비교가 모두 있는 큰 기업 기준) */
.ps-page { gap: 2.4mm; padding: 11mm 13mm 9mm; }
.ps-hero h1 { font-size: 20pt; }
.ps-ids { margin-top: 2.2mm; }
.ps-ids div { padding: 1.6mm 3mm; }
.ps-ids b { font-size: 11.5pt; }
.ps-kv th, .ps-kv td { padding: 0.7mm 0; }
.ps-tile { padding: 1.6mm 2.5mm; }
.ps-tile b { font-size: 11pt; }
.ps-trend { margin-top: 1.8mm; }
.ps-spark { height: 32px; }
.ps-fin th, .ps-fin td { padding: 0.65mm 1.5mm; }
.ps-box { padding: 2.4mm 3.5mm 2.6mm; }
.ps-box h2 { margin-bottom: 1.4mm; }
.ps-tight1 .ps-area { display: none; }
.ps-tight2 .ps-trend, .ps-tight2 .ps-summary { display: none; }
.ps-tight3 .ps-fin tbody tr:nth-child(n+4) { display: none; }
.ps-foot { display: flex; align-items: flex-end; gap: 5mm; }
.ps-foot-text { flex: 1; min-width: 0; }
.ps-qr { flex: none; display: grid; justify-items: center; gap: 1mm; }
.ps-qr svg { width: 21mm; height: 21mm; display: block; }
.ps-qr span { font-size: 6.8pt; color: #4d5d66; white-space: nowrap; }
.ps-hero { position: relative; }
.ps-hero .ps-qr { position: absolute; right: 0; top: 0; padding: 1.5mm; border: 1px solid #e3e9ed; border-radius: 2.5mm; background: #fff; }
.ps-hero .ps-qr svg { width: 19mm; height: 19mm; }
.ps-hero:has(.ps-qr) .ps-badges, .ps-hero:has(.ps-qr) h1, .ps-hero:has(.ps-qr) .ps-eng { margin-right: 28mm; }
.ps-hero:has(.ps-qr) .ps-ids { margin-right: 27mm; }

/* ════════════════════════════════════════════════════════════════
   촘촘 미니멀 B2B 디자인 시스템(최종). 위의 규칙보다 뒤에 두어 우선한다.
   무채색 중심, 포인트 색(#006B5F)은 검색 버튼·활성 상태에만. 그림자·그라데이션 없음.
   ════════════════════════════════════════════════════════════════ */
:root {
  --page: #ffffff; --shell: #f7f7f7; --bg: #f7f7f7; --card: #ffffff;
  --text: #202124; --sub: #4a4a4a; --muted: #6b6b6b; /* #777은 회색 바탕 대비 4.2:1이라 한 단계 진하게 */
  --line: #e6e6e6; --line-strong: #d6d6d6;
  --accent: #006b5f; --accent-hover: #00574d; --accent-ink: #006b5f; --accent-weak: #edf3f2; --on-accent: #ffffff;
  --chip: #efefef; --mark: #fff2b3;
  --shadow-sm: none; --shadow-md: none; --shadow-lg: 0 6px 24px rgba(0, 0, 0, .08);
  --r-sm: 6px; --r-md: 8px; --r-lg: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page: #111213; --shell: #1a1b1c; --bg: #1a1b1c; --card: #222324; --text: #ececec; --sub: #c4c4c4; --muted: #9d9d9d;
    --line: #2f3032; --line-strong: #3b3c3e; --accent: #3fb3a3; --accent-hover: #5cc4b5; --accent-ink: #6cc9bb; --accent-weak: #1d2b29; --on-accent: #0b1f1c; --chip: #2a2b2d;
  }
}
:root[data-theme="dark"] {
    --page: #111213; --shell: #1a1b1c; --bg: #1a1b1c; --card: #222324; --text: #ececec; --sub: #c4c4c4; --muted: #9d9d9d;
    --line: #2f3032; --line-strong: #3b3c3e; --accent: #3fb3a3; --accent-hover: #5cc4b5; --accent-ink: #6cc9bb; --accent-weak: #1d2b29; --on-accent: #0b1f1c; --chip: #2a2b2d;
  }
body { background: var(--page); font-size: 14.5px; }
.wrap { max-width: none; padding: 0; }

/* 하나의 커다란 회색 컨테이너 */
.shell { width: calc(100% - 32px); max-width: 1160px; margin: 16px auto 0; background: var(--shell); border-radius: 14px; padding: 0 28px 40px; flex: 1; display: flex; flex-direction: column; }
.shell > main { flex: 1; padding-bottom: 8px; }

/* 헤더: 왼쪽 워드마크, 오른쪽 작은 메뉴, 아래 얇은 구분선 */
.top { position: static; background: none; backdrop-filter: none; border-bottom: 1px solid var(--line); }
.top-in { height: 68px; gap: 24px; padding: 0; max-width: none; }
.logo { gap: 0; }
.wordmark { font-weight: 800; font-size: 27px; letter-spacing: -0.035em; color: var(--text); line-height: 1; }
.gnb { margin-left: auto; gap: 4px; align-items: center; }
.gnb a { padding: 6px 10px; font-size: 13.5px; font-weight: 500; color: var(--sub); border-radius: 6px; background: none; }
.gnb a:hover { color: var(--text); background: none; }
.gnb a[aria-current] { color: var(--accent); background: none; font-weight: 700; }
.gnb .top-account { margin-left: 8px; border: 1px solid var(--line-strong); border-radius: 6px; padding: 5px 11px; background: var(--card); color: var(--text); font-weight: 600; }
.gnb .top-account[aria-current] { border-color: var(--accent); }
.mnav summary { width: 36px; height: 36px; }

/* 결과·상세 화면 상단 검색줄(첫 화면에서는 숨김) */
.top-search-row:has(#topSearch:not([hidden])) { padding: 20px 0 4px; }
.top-search-row .search.small { max-width: 640px; }

/* 검색창: 흰 입력 + 짙은 녹색 버튼, 그림자 없음 */
.search { gap: 0; }
.search.big, .search.small { background: var(--card); border: 1px solid var(--line-strong); border-radius: 8px; padding: 0 5px 0 14px; box-shadow: none; align-items: center; }
.search.big:focus-within, .search.small:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent); }
.search .lead { color: var(--muted); width: 18px; height: 18px; margin-right: 10px; display: block !important; flex: none; }
.search.big input, .search.small input { border: 0; box-shadow: none !important; padding: 0; background: transparent; }
.search.big input { height: 50px; font-size: 15px; }
.search.small input { height: 42px; font-size: 14.5px; }
.search.big button, .search.small button { border-radius: 6px; font-weight: 600; letter-spacing: 0; }
.search.big button { height: 40px; padding: 0 22px; font-size: 14.5px; }
.search.small button { height: 34px; padding: 0 16px; font-size: 14px; }
.search .suggest { box-shadow: var(--shadow-lg); border-radius: 8px; }

/* 첫 화면: 왼쪽 정렬, 낮은 정보 밀도 */
.home { padding: 72px 0 24px; text-align: left; max-width: none; }
.home > h1, .home-desc, .home .search.big, .quick-links { max-width: 720px; }
.home h1 { font-size: 30px; line-height: 1.3; margin: 0 0 10px; letter-spacing: -0.03em; font-weight: 700; }
.home-desc { margin: 0 0 24px; color: var(--muted); font-size: 14.5px; }
.quick-links { display: flex; flex-wrap: wrap; gap: 4px 22px; margin-top: 14px; font-size: 13px; }
.quick-links a { color: var(--sub); }
.quick-links a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.home-more { margin-top: 88px; padding-top: 28px; border-top: 1px solid var(--line); }
.home-more .home-sec { max-width: none; margin: 0 0 36px; }
.home-more .home-sec h2 { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 12px; }
.home-more .stat, .home-more .area-chip, .home-more .intro-item { background: var(--card); border: 1px solid var(--line); border-radius: 8px; }
.home-more .stat strong { font-size: 18px; }

/* 공통 표면: 흰 바탕 + 얇은 테두리, 장식 최소화 */
.card, .doc, .mp-card, .mp-danger, .auth-card, .stat { box-shadow: none; border-radius: 10px; }
.card { padding: 4px 20px; }
.card h2 { font-size: 14px; font-weight: 700; }
.doc { margin-top: 24px; padding: 6px 24px 24px; }
.doc h1 { font-size: 22px; font-weight: 700; }
.badge { border-radius: 4px; font-weight: 600; }
.badge.corp { background: var(--chip); color: var(--sub); }
.chip { border-radius: 6px; }
.chip.on { background: var(--card); border-color: var(--accent); color: var(--accent); }
.btn, .share, .print-btn, .copy { border-radius: 6px; }
.share { font-weight: 500; }

/* 검색 결과: 하나의 흰 목록, 행 구분선만 */
.filters { margin-top: 18px; padding: 0; }
.tabs { background: var(--chip); border-radius: 7px; }
.tab { border-radius: 5px; }
.tab[aria-current] { box-shadow: none; color: var(--text); }
.list { gap: 0; background: var(--card); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.item { border: 0; border-radius: 0; box-shadow: none; border-top: 1px solid var(--line); background: none; }
.item:first-child { border-top: 0; }
.item:hover { box-shadow: none; background: #fafafa; border-color: var(--line); }
.item > a { padding: 14px 18px; border-radius: 0; }
.item .name { font-size: 15.5px; font-weight: 700; }
.item .no { color: var(--text); font-weight: 600; font-size: 14px; }
.item .row2 { color: var(--muted); font-size: 13px; }
.skel { gap: 0; background: var(--card); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.skel li { border: 0; border-top: 1px solid var(--line); border-radius: 0; }
.skel li:first-child { border-top: 0; }
.pg { border-radius: 6px; }
.pg[aria-current] { background: var(--text); border-color: var(--text); color: var(--page); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .item:hover { background: #262728; } }
:root[data-theme="dark"] .item:hover { background: #262728; }

/* 상세 */
.detail h1 { font-size: 26px; font-weight: 700; }
.print-btn { font-weight: 600; }
.id-row b { font-size: 15px; }

/* 대량조회·매칭: 장식 줄이기 */
.steps li { background: none; padding: 0; color: var(--muted); }
.steps li::before { background: var(--chip); color: var(--text); }
.drop { background: var(--card); border-radius: 8px; }
.drop .ico { color: var(--muted); }
.sum-tiles > * { border-radius: 8px; }
.done-msg { background: var(--accent-weak); color: var(--text); border-radius: 8px; font-weight: 500; }
.done-msg::before { background: var(--accent); }
.match-cols { background: var(--card); }
.doc table th { background: #fafafa; }
.doc pre, .mp-code { background: #f3f3f3; border: 1px solid var(--line); border-radius: 8px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .doc table th { background: #262728; } :root:not([data-theme="light"]) .doc pre { background: #19191a; } }
:root[data-theme="dark"] .doc table th { background: #262728; } :root[data-theme="dark"] .doc pre { background: #19191a; }

/* 로그인·마이페이지 */
.auth-mark.wordmark { font-size: 30px; margin: 0 0 10px; text-align: center; display: block; }
.auth h1 { font-size: 18px; font-weight: 700; }
.auth .login { border-radius: 8px; }
.mp-avatar { border-radius: 10px; }

/* 바닥글: 컨테이너 밖, 작고 조용하게 */
.foot { background: none; border-top: 0; padding: 22px 0 32px; }
.foot .wrap { width: calc(100% - 32px); max-width: 1160px; margin: 0 auto; padding: 0 28px; }
.foot-brand { margin-bottom: 8px; gap: 10px; }
.foot-brand b { font-size: 15px; font-weight: 800; letter-spacing: -0.03em; }
.foot-links a { color: var(--muted); font-size: 12.5px; }
.foot p { font-size: 12px; }

/* 출력 시트 워드마크 */
.ps-wordmark { font-size: 17pt; font-weight: 800; letter-spacing: -0.035em; color: #202124; }
.ps-top { border-bottom: 1.5px solid #202124; }

/* 반응형 */
@media (max-width: 860px) {
  .gnb { display: none; }
  .mnav { display: block; margin-left: auto; }
  .shell { padding: 0 20px 32px; }
}
@media (max-width: 560px) {
  .shell { width: calc(100% - 16px); margin-top: 8px; padding: 0 16px 28px; border-radius: 12px; }
  .top-in { height: 58px; }
  .wordmark { font-size: 24px; }
  .home { padding: 40px 0 16px; }
  .home h1 { font-size: 23px; }
  .home-desc { font-size: 14px; margin-bottom: 18px; }
  .search.big { padding-left: 12px; }
  .search.big input { height: 48px; font-size: 16px; }
  .search.big button { height: 38px; padding: 0 16px; }
  .search.small input { font-size: 16px; }
  .home-more { margin-top: 56px; }
  .quick-links { gap: 4px 16px; }
  .foot .wrap { padding: 0 16px; }
}
/* 본문은 헤더와 같은 왼쪽 선에 맞춘다(가운데 정렬 폭 제한을 푼다) */
.detail, .doc, .browse, .mypage { margin-left: 0; margin-right: 0; max-width: 900px; }
.list, .skel, .filters, main > .meta, main > .empty, .pager { margin-left: 0; margin-right: 0; max-width: none; }
.pager { justify-content: flex-start; }
.auth { margin-left: auto; margin-right: auto; }

/* ════════════════════════════════════════════════════════════════
   2차 정리: 회색 큰 박스 제거, 흰 바탕 통일, 고정 헤더, 가독성 강화.
   구분은 배경 면이 아니라 간격·얇은 선·글자 위계로 한다.
   ════════════════════════════════════════════════════════════════ */
:root {
  --page: #ffffff; --shell: #ffffff; --bg: #ffffff; --card: #ffffff;
  --text: #1a1a1a; --sub: #3d3d3d; --muted: #5f5f5f;  /* 보조 글자도 흰 바탕 대비 6:1 이상 */
  --line: #e8e8e8; --line-strong: #d4d4d4; --soft: #f6f6f6;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --page: #121314; --shell: #121314; --bg: #121314; --card: #18191a; --soft: #1f2021; --text: #f0f0f0; --sub: #d0d0d0; --muted: #a8a8a8; }
}
:root[data-theme="dark"] { --page: #121314; --shell: #121314; --bg: #121314; --card: #18191a; --soft: #1f2021; --text: #f0f0f0; --sub: #d0d0d0; --muted: #a8a8a8; }
body { background: var(--page); color: var(--text); }

/* 큰 회색 박스 대신 흰 바탕 위 가운데 폭만 맞춘다 */
.shell { background: none; border-radius: 0; margin: 0 auto; padding: 0 24px 48px; width: 100%; max-width: 1120px; }

/* 고정 헤더: 화면 전체 폭 흰 띠 + 아래 얇은 선 */
.top { position: sticky; top: 0; z-index: 40; background: var(--page); border-bottom: 0; margin: 0 -24px; padding: 0 24px; }
.top::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 100vw; transform: translateX(-50%); border-bottom: 1px solid var(--line); pointer-events: none; }
.top::before { content: ""; position: absolute; inset: 0 auto 0 50%; width: 100vw; transform: translateX(-50%); background: var(--page); z-index: -1; }
.top-in { height: 60px; }
.logo { display: inline-flex; align-items: baseline; gap: 10px; }
.wordmark { font-size: 24px; }
.logo-desc { font-size: 13px; font-weight: 500; color: var(--muted); letter-spacing: -0.01em; white-space: nowrap; }
.gnb a { font-size: 14px; color: var(--sub); font-weight: 500; }
.gnb a[aria-current] { color: var(--text); font-weight: 700; box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.gnb .top-account { padding: 6px 12px; }
.gnb .top-account[aria-current] { box-shadow: none; }

/* 결과·상세 상단 검색줄: 헤더 바로 아래에서 이어지게 */
.top-search-row:has(#topSearch:not([hidden])) { padding: 18px 0 2px; }

/* 검색창 */
.search.big, .search.small { border-color: var(--line-strong); }
.search input::placeholder { color: #808080; }
.search.big input { font-size: 16px; }

/* 첫 화면 */
.home { padding: 64px 0 8px; }
.home h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.035em; margin-bottom: 10px; color: var(--text); }
.home-desc { color: var(--sub); font-size: 15.5px; margin-bottom: 22px; }
.quick-links { margin-top: 12px; font-size: 13.5px; }
.quick-links a { color: var(--sub); }
.home-more { margin-top: 64px; padding-top: 32px; border-top: 1px solid var(--line); }
.home-more .home-sec { margin-bottom: 40px; }
.home-more .home-sec h2 { font-size: 15px; margin-bottom: 14px; }
.home-more .stat { padding: 16px 18px; gap: 4px; }
.home-more .stat-label { color: var(--sub); font-size: 13px; }
.home-more .stat strong { font-size: 22px; font-weight: 700; color: var(--text); }
.home-more .stat-sub { color: var(--muted); font-size: 12px; }

/* 공통 표면: 흰 바탕 + 선 */
.card, .doc, .mp-card, .mp-danger, .auth-card, .stat, .list, .skel { background: var(--card); border-color: var(--line); }
.doc table th { background: var(--soft); }
.doc pre, .mp-code { background: var(--soft); }

/* 검색 결과: 기업명·번호 위계 */
.meta { color: var(--sub); }
.item > a { padding: 15px 18px; }
.item .name { font-size: 16.5px; font-weight: 700; color: var(--text); }
.item .no { font-size: 15px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }
.item .row2 { color: var(--sub); font-size: 13.5px; margin-top: 6px; }
.item:hover { background: var(--soft); }
mark { background: #fff0a8; }

/* 태그: 높이·여백 통일 */
.badge { height: 22px; line-height: 22px; padding: 0 8px; font-size: 12px; border-radius: 4px; vertical-align: middle; }
.detail .sub { gap: 6px; margin-bottom: 14px; }

/* 상세 머리: 제목 → 번호 → 태그 → 요약, 버튼은 오른쪽에 같은 크기로 */
.detail { margin-top: 20px; }
.title-row { align-items: center; margin-bottom: 6px; }
.detail h1 { font-size: 28px; font-weight: 800; letter-spacing: -0.03em; margin: 0; }
.title-actions { gap: 6px; }
.print-btn, .title-actions .share { height: 36px; padding: 0 14px; font-size: 13.5px; font-weight: 600; margin: 0; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px; }
.title-actions .share { border: 1px solid var(--line-strong); background: var(--card); color: var(--text); }
.id-row { gap: 6px 20px; margin: 8px 0 12px; font-size: 13.5px; color: var(--sub); }
.id-row b { font-size: 16px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }
.summary { max-width: 62ch; font-size: 15px; line-height: 1.75; color: var(--sub); margin: 0 0 18px; }
.card { padding: 6px 22px; }
.card h2 { font-size: 15px; color: var(--text); margin: 16px 0 6px; }
.kv { grid-template-columns: 120px 1fr; padding: 11px 0; }
.kv dt { color: var(--sub); font-size: 13.5px; }
.kv dd { color: var(--text); font-size: 14.5px; }
.kv dd .note { color: var(--muted); font-size: 12.5px; margin-top: 2px; }

/* 복사·공유 버튼 통일 */
.copy { height: 24px; padding: 0 9px; font-size: 12px; font-weight: 600; border-radius: 5px; border: 1px solid var(--line-strong); background: var(--card); color: var(--sub); display: inline-flex; align-items: center; vertical-align: middle; }
.share { border-radius: 6px; }

/* 모바일 메뉴 패널 */
.mnav-panel { position: fixed; left: 0; right: 0; top: 60px; width: auto; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: 0 12px 24px rgba(0, 0, 0, .06); padding: 6px 16px 14px; background: var(--page); }
.mnav-panel a { padding: 13px 4px; font-size: 15.5px; font-weight: 500; border-radius: 0; border-bottom: 1px solid var(--line); color: var(--text); }
.mnav-panel a:last-child { border-bottom: 0; color: var(--muted); font-size: 14px; }
.mnav-panel a:hover { background: none; }
.mnav-panel a[aria-current] { color: var(--accent); font-weight: 700; background: none; }
.mnav summary:hover, .mnav[open] summary { background: var(--soft); }

@media (max-width: 860px) {
  .shell { padding: 0 20px 40px; }
  .top { margin: 0 -20px; padding: 0 20px; }
}
@media (max-width: 560px) {
  .shell { width: 100%; margin: 0; padding: 0 16px 32px; border-radius: 0; }
  .top { margin: 0 -16px; padding: 0 16px; }
  .top-in { height: 56px; }
  .mnav-panel { top: 56px; }
  .wordmark { font-size: 22px; }
  .logo { gap: 8px; }
  .logo-desc { font-size: 11.5px; }
  .home { padding: 36px 0 4px; }
  .home h1 { font-size: 24px; line-height: 1.35; }
  .home-desc { font-size: 14.5px; margin-bottom: 18px; }
  .search.big, .search.small { padding: 0 6px 0 12px; }
  .search.big input, .search.small input { height: 50px; font-size: 16px; }
  .search.big button, .search.small button { height: 40px; padding: 0 18px; font-size: 15px; }
  .search .lead { margin-right: 8px; }
  .quick-links { gap: 6px 18px; font-size: 13.5px; }
  .home-more { margin-top: 44px; padding-top: 26px; }
  .home-more .stats { gap: 10px; }
  .home-more .stat { padding: 14px 15px; }
  .home-more .stat strong { font-size: 19px; }
  .item > a { padding: 14px 15px; }
  .item .no { font-size: 15px; }
  .detail h1 { font-size: 23px; }
  .title-row { flex-wrap: wrap; gap: 10px; }
  .title-actions { width: 100%; }
  .title-actions > * { flex: 1; justify-content: center; }
  .card { padding: 4px 16px; }
  .kv { grid-template-columns: 96px 1fr; }
}
html, body { overflow-x: clip; }
/* 검색창 폭을 아래 본문과 맞춘다: 첫 화면·검색 결과는 본문 전체 폭, 상세·안내 화면은 본문(900px) 폭 */
.home .search.big { max-width: none; }
.top-search-row .search.small { max-width: none; }
.shell:has(main > .detail, main > .doc, main > .mypage, main > .browse) .top-search-row .search.small { max-width: 900px; }
.logo-desc { color: var(--sub); }

/* ── 영역 구분: 주 영역(검색)은 흰색, 참고 영역(통계·둘러보기)과 바닥글은 연한 회색 띠, 사이사이 얇은 선 ── */
:root { --band: #f7f7f7; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --band: #18191a; } }
:root[data-theme="dark"] { --band: #18191a; }

/* 첫 화면 아래 참고 영역: 화면 전체 폭 회색 띠 위에 흰 카드 */
.home-more { position: relative; margin-top: 64px; padding: 44px 0 16px; border-top: 0; }
.home-more::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 100vw; transform: translateX(-50%); background: var(--band); border-top: 1px solid var(--line); z-index: -1; }
.home { position: relative; z-index: 0; padding-bottom: 0; }
.home-more .home-sec { margin: 0; padding: 28px 0; border-top: 1px solid var(--line); }
.home-more .home-sec:first-child { padding-top: 0; border-top: 0; }
.home-more .stat, .home-more .area-chip, .home-more .intro-item { background: var(--card); }
.shell:has(main > .home) { padding-bottom: 0; }

/* 바닥글: 회색, 위 선으로 본문과 분리 */
.foot { background: var(--band); border-top: 1px solid var(--line); padding: 26px 0 36px; margin-top: 0; }

/* 결과·상세·기능 화면: 검색줄 아래 얇은 선으로 검색 영역과 본문을 나눈다 */
.top-search-row:has(#topSearch:not([hidden])) { padding: 18px 0; border-bottom: 1px solid var(--line); }
.filters { margin-top: 16px; }
.detail { margin-top: 18px; }
.doc { margin-top: 20px; }

/* 상세: 머리(제목·번호·태그·요약)와 정보 카드 사이 선, 카드 묶음 간격 넓히기 */
.detail > .summary { padding-bottom: 20px; margin-bottom: 22px; border-bottom: 1px solid var(--line); max-width: none; }
.detail > .summary { font-size: 15px; }
.detail .card { margin-bottom: 14px; }
.detail .fix-link { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }

@media (max-width: 560px) {
  .home-more { margin-top: 44px; padding-top: 32px; }
  .home-more .home-sec { padding: 22px 0; }
}
/* 상세 머리의 출력·공유: 아이콘 + 글자만, 버튼 상자 없이 */
.title-actions { gap: 2px; }
.print-btn, .title-actions .share { height: 34px; padding: 0 10px; border: 0; background: none; color: var(--sub); font-size: 14px; font-weight: 600; border-radius: 6px; box-shadow: none; }
.print-btn:hover, .title-actions .share:hover { background: var(--soft); color: var(--text); }
.print-btn .ico, .title-actions .share .ico { width: 18px; height: 18px; }
.print-btn:disabled { background: none; }
@media (max-width: 560px) { .title-actions { width: auto; } .title-actions > * { flex: none; } .title-row { flex-wrap: nowrap; align-items: flex-start; } }
.title-row h1 { flex: 1; min-width: 0; }
/* 로그인 버튼은 모바일에서도 헤더에 보인다(햄버거 메뉴 옆) */
.top-in > .top-account { margin-left: 8px; border: 1px solid var(--line-strong); border-radius: 6px; padding: 6px 12px; background: var(--card); color: var(--text); font-size: 13.5px; font-weight: 600; white-space: nowrap; display: inline-block; }
.top-in > .top-account:hover { border-color: var(--accent); }
.top-in > .top-account[aria-current] { border-color: var(--accent); color: var(--accent); }
@media (max-width: 860px) { .top-in > .top-account { display: inline-block; margin-left: auto; } .top-in > .top-account + .mnav { margin-left: 4px; } }
@media (max-width: 560px) { .top-in > .top-account { padding: 5px 10px; font-size: 13px; } }
@media (max-width: 340px) { .logo-desc { display: none; } }
/* 검색창 아래: 검색 예시·최근 검색(작은 글자 줄) */
.quick-links { align-items: baseline; gap: 4px 16px; }
.quick-links .ql-label { color: var(--muted); font-size: 12.5px; font-weight: 600; margin-right: -4px; }
.quick-links small { color: var(--muted); font-size: 11.5px; margin-left: 2px; }
.quick-links.recent { margin-top: 6px; }
/* 1. 첫 화면: 예시 줄과 회색 띠 사이 여백 줄이기 */
.home-more { margin-top: 40px; }
/* 3. 검색 결과 복사 버튼: 마우스가 있는 화면에서는 줄에 올렸을 때만 보인다(터치 화면은 늘 보임) */
@media (hover: hover) {
  .item > .copy { opacity: 0; transition: opacity .12s; }
  .item:hover > .copy, .item:focus-within > .copy, .item > .copy.done { opacity: 1; }
}
/* 4. 상세 섹션 바로가기: 헤더 아래에 붙어 따라오는 한 줄 */
.detail-toc { position: sticky; top: 60px; z-index: 20; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; background: var(--page); border-bottom: 1px solid var(--line); margin: -8px 0 20px; padding: 6px 0; }
.detail-toc::-webkit-scrollbar { display: none; }
.detail-toc a { flex: none; padding: 6px 10px; border-radius: 6px; font-size: 13.5px; font-weight: 500; color: var(--sub); white-space: nowrap; }
.detail-toc a:hover { background: var(--soft); color: var(--text); }
.detail > .summary + .detail-toc { margin-top: -10px; }
.detail > .summary:has(+ .detail-toc) { border-bottom: 0; margin-bottom: 0; padding-bottom: 12px; }
.detail .card { scroll-margin-top: 120px; }
@media (max-width: 560px) { .detail-toc { top: 56px; margin-left: -16px; margin-right: -16px; padding: 6px 12px; } .detail-toc a { font-size: 13px; padding: 6px 8px; } }
/* 상세 요약: 글만 있던 문장을 옅은 회색 상자 + "요약" 표시로 */
.detail > .summary { display: flex; align-items: flex-start; gap: 12px; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; padding: 12px 16px; margin: 4px 0 14px; max-width: none; font-size: 14.5px; line-height: 1.65; color: var(--text); }
.detail > .summary:has(+ .detail-toc), .detail > .summary { border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.summary-label { flex: none; margin-top: 1px; padding: 0 8px; height: 22px; line-height: 22px; border-radius: 4px; background: var(--card); border: 1px solid var(--line-strong); color: var(--sub); font-size: 12px; font-weight: 700; }
.detail > .summary + .detail-toc { margin-top: 0; }
@media (max-width: 560px) { .detail > .summary { flex-direction: column; gap: 6px; padding: 12px 14px; } }
/* 상세 섹션 탭: 앵커 탭 형태의 로컬 내비게이션. 지금 보는 섹션은 녹색 글자 + 아래 막대 */
.detail-toc { position: sticky; top: 60px; z-index: 20; background: var(--page); border-bottom: 1px solid var(--line); margin: 0 0 22px; padding: 0; display: block; overflow: visible; }
.detail-toc .toc-track { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; scroll-behavior: smooth; -webkit-overflow-scrolling: touch; padding: 0 2px; }
.detail-toc .toc-track::-webkit-scrollbar { display: none; }
.detail-toc a { position: relative; flex: none; display: inline-flex; align-items: center; height: 46px; padding: 0 14px; font-size: 14px; font-weight: 500; color: var(--sub); border-radius: 0; white-space: nowrap; background: none; }
.detail-toc a::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; border-radius: 2px; background: transparent; transition: background .15s; }
.detail-toc a:hover { color: var(--text); background: none; }
.detail-toc a:hover::after { background: var(--line-strong); }
.detail-toc a[aria-selected="true"] { color: var(--accent); font-weight: 700; }
.detail-toc a[aria-selected="true"]::after { background: var(--accent); }
.detail-toc a:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; border-radius: 6px; }
/* 넘친 탭이 있음을 알리는 오른쪽 흐림(배경색으로 덮는 얇은 띠) */
.detail-toc::after { content: ""; position: absolute; top: 0; right: 0; bottom: 1px; width: 28px; pointer-events: none; background: linear-gradient(to right, transparent, var(--page)); }
.detail > .summary + .detail-toc { margin-top: 0; }
.detail .card { scroll-margin-top: 130px; }
@media (max-width: 560px) {
  .detail-toc { top: 56px; margin-left: -16px; margin-right: -16px; padding: 0; }
  .detail-toc .toc-track { padding: 0 8px; gap: 0; }
  .detail-toc a { height: 44px; padding: 0 12px; font-size: 14px; }
  .detail-toc a::after { left: 8px; right: 8px; }
}
/* 스크롤 시 헤더로 올라온 검색창 */
.top-in > #topSearch { flex: 1 1 360px; max-width: 460px; min-width: 0; margin: 0 8px 0 20px; }
.top-in > #topSearch input { height: 36px; font-size: 14px; }
.top-in > #topSearch button { height: 28px; padding: 0 12px; font-size: 13px; }
.top-in > #topSearch .lead { width: 16px; height: 16px; margin-right: 8px; }
.top-in > #topSearch + .gnb { margin-left: auto; }
body.search-docked .logo-desc { display: none; }
@media (max-width: 1040px) { body.search-docked .gnb { display: none; } body.search-docked .mnav { display: block; } }
@media (max-width: 860px) { .top-in > #topSearch { margin: 0 4px 0 12px; max-width: none; } }
@media (max-width: 560px) {
  body.search-docked .top-in > .top-account { display: none; }
  .top-in > #topSearch { margin: 0 2px 0 10px; padding: 0 4px 0 10px; }
  .top-in > #topSearch input { font-size: 16px; }
  .top-in > #topSearch button { padding: 0 10px; }
}
/* 예전 규칙(헤더에 검색창이 있으면 로고 글자 숨김)이 다시 걸리지 않게: 워드마크는 늘 보인다 */
.top-in:has(.search:not([hidden])) .logo .wordmark { display: inline; }
@media (max-width: 560px) { body.search-docked .wordmark { font-size: 20px; } }

/* ── 화면 테마: 기본은 시스템 설정을 따르고, 헤더 버튼으로 밝게·어둡게를 고정할 수 있다 ── */
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
/* 검색어 강조: 어두운 화면에서 밝은 노란 바탕 위 흰 글자가 되던 문제 */
mark { background: var(--mark); color: inherit; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --mark: #5e4d00; } }
:root[data-theme="dark"] { --mark: #5e4d00; }
.theme-btn { width: 34px; height: 34px; margin-left: 6px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--card); color: var(--sub); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; flex: none; }
.theme-btn:hover { color: var(--text); border-color: var(--accent); }
.theme-btn .ico { width: 18px; height: 18px; }
.theme-btn .i-sun { display: none; }
:root[data-theme="dark"] .theme-btn .i-sun { display: block; }
:root[data-theme="dark"] .theme-btn .i-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .i-sun { display: block; }
  :root:not([data-theme="light"]) .theme-btn .i-moon { display: none; }
}
.top-in > .theme-btn + .mnav { margin-left: 4px; }
@media (max-width: 560px) { .theme-btn { width: 32px; height: 32px; margin-left: 4px; } }
@media (max-width: 560px) { body.search-docked .top-in > .theme-btn { display: none; } }
/* 헤더 줄 간격(24px) 안에서 로그인·테마·메뉴 버튼은 한 묶음으로 붙인다 */
.top-in > .theme-btn { margin-left: -16px; }
.top-in > .theme-btn + .mnav { margin-left: -18px; }
@media (max-width: 560px) { .top-in > .theme-btn { margin-left: -18px; } }

/* ════════════════════════════════════════════════════════════════
   무료 검색 도구로 정리: 첫 화면은 검색 → 자주 쓰는 기능 → 짧은 신뢰 정보 → 둘러보기 → 광고 자리 순.
   ════════════════════════════════════════════════════════════════ */
.home h1 { font-size: 28px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.35; }
.home-desc { font-size: 15px; color: var(--sub); margin-bottom: 18px; }
/* 자주 쓰는 기능: 카드가 아니라 얇은 선으로 나눈 한 줄 */
.home-tools { display: grid; grid-template-columns: repeat(3, 1fr); max-width: 720px; margin-top: 28px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.home-tools a { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-left: 1px solid var(--line); color: var(--text); }
.home-tools a:first-child { border-left: 0; padding-left: 0; }
.home-tools a:hover b { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.home-tools b { font-size: 14.5px; font-weight: 700; }
.home-tools span { font-size: 12.5px; color: var(--muted); }
/* 자료 현황: 한 줄 숫자 + 출처 안내 */
.home-trust .trust-figs { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 36px; }
.home-trust .trust-figs li { display: flex; flex-direction: column; gap: 2px; }
.home-trust .trust-figs span { font-size: 12.5px; color: var(--sub); }
.home-trust .trust-figs b { font-size: 20px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.home-trust .trust-note { margin: 12px 0 0; font-size: 12.5px; color: var(--muted); }
/* 상세: 기준일·출처 한 줄 */
.detail > .summary:has(+ .data-basis) { margin-bottom: 8px; }
.detail > .data-basis { margin: 0 0 18px; font-size: 12.5px; color: var(--muted); }
@media (max-width: 560px) {
  .home h1 { font-size: 22px; }
  .home-desc { font-size: 14px; margin-bottom: 14px; }
  .home-tools { grid-template-columns: 1fr; margin-top: 22px; border-bottom: 0; }
  .home-tools a, .home-tools a:first-child { flex-direction: row; justify-content: space-between; align-items: baseline; border-left: 0; border-bottom: 1px solid var(--line); padding: 13px 0; }
  .home-trust .trust-figs { gap: 12px 24px; display: grid; grid-template-columns: 1fr 1fr; }
  .home-trust .trust-figs b { font-size: 18px; }
}
.home h1, .home-desc, .home-trust .trust-note, .detail > .data-basis { word-break: keep-all; overflow-wrap: anywhere; }
.nw { white-space: nowrap; }
@media (max-width: 560px) { .home { padding-top: 28px; } .home h1 { margin-bottom: 8px; } }
.home-kicker { margin: 0 0 8px; font-size: 15px; font-weight: 700; color: var(--accent); letter-spacing: -0.01em; }
@media (max-width: 560px) { .home-kicker { font-size: 14px; margin-bottom: 6px; } }
/* 상세 탭 줄 왼쪽 기업명: 제목이 헤더 뒤로 지나가면 나타나고, 누르면 맨 위로 */
.detail-toc { display: flex; align-items: stretch; }
.detail-toc .toc-track { flex: 1; min-width: 0; }
.detail-toc a.toc-name { display: none; flex: 0 1 auto; max-width: 240px; padding: 0 14px 0 2px; margin-right: 6px; font-weight: 800; color: var(--text); overflow: hidden; text-overflow: ellipsis; border-right: 1px solid var(--line); }
.detail-toc a.toc-name::after { display: none; }
.detail-toc.stuck a.toc-name { display: block; line-height: 46px; }
@media (max-width: 560px) { .detail-toc a.toc-name { max-width: 38%; padding-right: 10px; margin-right: 2px; } .detail-toc.stuck a.toc-name { line-height: 42px; } }

/* 이용약관·개인정보처리방침: 요약 상자, 개정 공고, 번호 목록 */
.legal .doc-notice { margin: 6px 0 0; padding: 10px 14px; border-radius: 8px; background: var(--soft); border: 1px solid var(--line); font-size: 13px; color: var(--sub); }
.legal .doc-summary { margin: 20px 0 8px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); }
.legal .doc-summary p { margin: 0 0 6px; }
.legal .doc-summary ul { margin: 0; padding-left: 18px; }
.legal .doc-summary li { margin: 3px 0; color: var(--sub); }
.legal h2 { margin-top: 30px; }
.legal ol { padding-left: 22px; }
.legal ol li, .legal ul li { margin: 5px 0; line-height: 1.7; }
.legal p, .legal li { word-break: keep-all; overflow-wrap: anywhere; }
