/* 사이트 전체 디자인. 색을 바꾸고 싶으면 아래 :root 의 값만 바꾸면 됩니다. */
:root {
  --bg: #f7f7f5;
  --card: #ffffff;
  --text: #1c1c1e;
  --muted: #6b6b70;
  --line: #e4e4e0;
  --accent: #0b6e4f;
  --accent-soft: #e3f2ec;
  --warn: #9a5b00;
  --warn-soft: #fff1d6;
  --bad: #a3322a;
  --bad-soft: #fbe7e5;
  --radius: 12px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

a { color: var(--accent); }

.wrap { max-width: 960px; margin: 0 auto; padding: 0 16px; }

/* 상단 메뉴 */
.top {
  background: var(--card);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 10;
}
.top .wrap { display: flex; align-items: center; gap: 16px; height: 56px; }
.logo { font-weight: 800; color: var(--text); text-decoration: none; margin-right: auto; }
.top nav { display: flex; gap: 14px; font-size: 15px; }
.top nav a { color: var(--muted); text-decoration: none; }
.top nav a[aria-current="page"] { color: var(--text); font-weight: 700; }

main { padding: 28px 0 56px; }

h1 { font-size: clamp(24px, 5vw, 32px); line-height: 1.3; margin: 0 0 8px; }
h2 { font-size: 20px; margin: 36px 0 12px; }
.lead { color: var(--muted); margin: 0 0 24px; }

/* 카드 */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}

/* 첫 화면 필터 */
.filter { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.filter label { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.filter input, .filter select {
  width: 100%; font: inherit; font-size: 17px;
  padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--text);
}
.filter .hint { font-size: 13px; color: var(--muted); margin-top: 4px; }
@media (max-width: 560px) { .filter { grid-template-columns: 1fr; } }

.result-title { margin: 28px 0 12px; font-size: 18px; }
.results { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.country-card {
  display: block; text-decoration: none; color: var(--text);
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px;
}
.country-card:hover { border-color: var(--accent); }
.country-card strong { font-size: 18px; }
.country-card dl { margin: 8px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; font-size: 14px; }
.country-card dt { color: var(--muted); }
.country-card dd { margin: 0; }
.country-card .go { display: block; margin-top: 10px; font-size: 14px; color: var(--accent); font-weight: 700; }
.excluded { margin-top: 20px; color: var(--muted); font-size: 14px; }
.excluded summary { cursor: pointer; }
.excluded li { margin: 4px 0; }
.empty { color: var(--muted); }

/* 확인 중 표시 */
.checking {
  display: inline-block; white-space: nowrap;
  font-size: 12px; font-weight: 700; line-height: 1;
  padding: 4px 7px; border-radius: 999px;
  background: var(--warn-soft); color: var(--warn);
  vertical-align: middle;
}

/* 비교 표 */
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
table { border-collapse: collapse; width: 100%; min-width: 640px; font-size: 15px; }
th, td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
thead th { background: #fafaf8; font-size: 13px; color: var(--muted); white-space: nowrap; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
.sticky { position: sticky; left: 0; background: var(--card); z-index: 1; box-shadow: 1px 0 0 var(--line); }
thead .sticky { background: #fafaf8; }
td .checking { margin-top: 4px; }
tbody th.sticky { white-space: nowrap; }
td { min-width: 120px; }
.muted { color: var(--muted); }

/* 나라별 상세 */
.breadcrumb { font-size: 14px; color: var(--muted); margin-bottom: 8px; }
.breadcrumb a { color: var(--muted); }
.keyfacts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 4px; }
.keyfacts div { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.keyfacts span { display: block; font-size: 12px; color: var(--muted); }
.keyfacts b { font-size: 15px; line-height: 1.45; }
/* 특이사항: 가로 전체 한 칸, 높이 일정 (PC 2줄, 휴대폰 최대 3줄) */
.keyfacts .kf-note { grid-column: 1 / -1; background: var(--accent-soft); border-color: #cfe6dc; }
.keyfacts .kf-note span { color: var(--accent); font-weight: 700; }
.keyfacts .kf-note p {
  margin: 2px 0 0; font-size: 15px; line-height: 1.5; min-height: 3em;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
}
@media (max-width: 560px) {
  .keyfacts { grid-template-columns: 1fr 1fr; gap: 6px; }
  .keyfacts div { padding: 8px 10px; }
  .keyfacts b { font-size: 14px; }
  .keyfacts .kf-note p { font-size: 13.5px; min-height: 4.5em; -webkit-line-clamp: 3; }
}

/* 분류 탭 (화면을 내려도 위에 붙어 있음, 휴대폰에서는 옆으로 밀기) */
.tabs {
  position: sticky; top: 56px; z-index: 5;
  display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none;
  margin: 16px -16px 0; padding: 10px 16px;
  background: var(--bg); border-bottom: 1px solid var(--line);
}
.tabs::-webkit-scrollbar { display: none; }
.tabs a {
  flex: none; padding: 7px 14px; border-radius: 999px; white-space: nowrap;
  background: var(--card); border: 1px solid var(--line); color: var(--text); text-decoration: none; font-size: 15px;
}
.tabs a[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }
.panel { scroll-margin-top: 120px; }
.single-tab .panel h2 { margin-top: 20px; }

/* 쉽게 말하면 상자 */
.easy { margin-top: 12px; padding: 12px 14px; border-radius: 10px; background: var(--accent-soft); }
.easy b { display: block; font-size: 13px; color: var(--accent); margin-bottom: 2px; }
.easy p { margin: 0; }

/* 눌러서 설명을 보는 용어 */
button.term {
  font: inherit; color: var(--accent); background: none; border: 0; padding: 0; margin: 0;
  cursor: pointer; text-decoration: underline dotted; text-underline-offset: 3px; text-decoration-thickness: 1.5px;
}
button.term:hover, button.term.open { background: var(--accent-soft); border-radius: 3px; }
button.term[disabled] { cursor: default; }

.term-pop {
  position: absolute; z-index: 30; width: 340px; max-width: calc(100vw - 32px);
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(0, 0, 0, .14); padding: 16px 40px 14px 16px; font-size: 15px;
}
.term-pop p { margin: 6px 0 0; }
.term-pop .more { color: var(--muted); font-size: 14px; }
.term-pop .meta { margin-top: 10px; font-size: 12px; color: var(--muted); }
.term-pop-close {
  position: absolute; top: 6px; right: 6px; width: 32px; height: 32px;
  border: 0; background: none; font-size: 22px; line-height: 1; color: var(--muted); cursor: pointer;
}
/* 휴대폰에서는 화면 아래에서 올라오는 카드로 */
.term-pop.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; top: auto; width: auto; max-width: none;
  border-radius: 16px 16px 0 0; padding: 20px 44px calc(20px + env(safe-area-inset-bottom)) 16px;
}

.items { display: grid; gap: 10px; }
.item h3 { margin: 0; font-size: 15px; color: var(--muted); font-weight: 600; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.item .summary { font-size: 18px; font-weight: 700; margin: 4px 0 6px; }
.item .detail { margin: 0; white-space: pre-line; }
.step .detail { white-space: pre-line; }
.item .meta {
  margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line);
  font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 14px;
}

.notice { font-size: 14px; color: var(--muted); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-top: 32px; }

footer { border-top: 1px solid var(--line); padding: 24px 0 40px; font-size: 13px; color: var(--muted); }

/* 최종 확인일 */
.updated { margin: 0; font-size: 14px; color: var(--muted); }
.updated b { color: var(--text); }

/* 준비 순서 타임라인 */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before {
  content: ""; position: absolute; left: 15px; top: 16px; bottom: 16px; width: 2px; background: var(--line);
}
.step { position: relative; display: flex; gap: 14px; padding-bottom: 14px; }
.step-no {
  flex: none; position: relative; z-index: 1; width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 14px;
  background: var(--accent); color: #fff; box-shadow: 0 0 0 4px var(--bg);
}
.step-body {
  flex: 1; min-width: 0; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 16px;
}
.step-when {
  display: inline-block; font-size: 13px; font-weight: 700; color: var(--accent);
  background: var(--accent-soft); border-radius: 999px; padding: 2px 10px;
}
.step h3 { margin: 6px 0 4px; font-size: 17px; }
.step .detail { margin: 0; }
.step .meta { margin-top: 10px; font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 14px; }

/* 비교 표 나라 고르기 */
.picker { margin-bottom: 14px; }
.picker-actions { display: flex; gap: 8px; margin-bottom: 8px; }
.picker-actions button {
  font: inherit; font-size: 13px; padding: 4px 10px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--line); background: var(--card); color: var(--muted);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-size: 15px;
  padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--card);
}
.chip:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); font-weight: 700; }
.chip input { accent-color: var(--accent); margin: 0; }

.small { font-size: 13px; }
.linklike { font: inherit; color: var(--accent); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; }

/* 나라 찾기: 조건 더 넣기 */
.more-conditions { grid-column: 1 / -1; border-top: 1px dashed var(--line); padding-top: 12px; }
.more-conditions summary { cursor: pointer; font-weight: 700; color: var(--accent); }
.more-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 14px; }
.more-grid .full { grid-column: 1 / -1; }
.more-grid .label { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.more-grid .checks { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.filter label.inline { display: inline-flex; align-items: center; gap: 6px; font-weight: 400; margin: 0; }
.filter label.inline input, .filter .chip input { width: auto; padding: 0; accent-color: var(--accent); }
.filter .chip { font-weight: 400; margin: 0; }
@media (max-width: 560px) { .more-grid { grid-template-columns: 1fr; } }

.tier-ok { color: var(--accent); }
.tier-prep { color: var(--warn); }
.method {
  display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--line); color: var(--muted); vertical-align: 2px; margin-left: 4px;
}
.notes { margin: 10px 0 0; padding: 8px 10px 8px 26px; border-radius: 8px; font-size: 14px; }
.notes.prep { background: var(--warn-soft); color: var(--warn); }
.notes.no { background: var(--bad-soft); color: var(--bad); }

/* 준비 체크리스트 */
.cl-summary { margin-bottom: 16px; }
.cl-progress { display: flex; align-items: center; gap: 12px; }
.cl-bar { flex: 1; height: 10px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); overflow: hidden; }
.cl-bar span { display: block; height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.cl-warn { margin: 12px 0 4px; color: var(--warn); }
.cl-ok { margin: 12px 0 4px; color: var(--accent); }
.cl-miss { margin: 0; padding-left: 20px; font-size: 14px; color: var(--muted); }
.cl-group { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 10px; }
.cl-group.required { border-color: var(--accent); }
.cl-group h3 { margin: 0 0 6px; font-size: 16px; display: flex; justify-content: space-between; }
.cl-gcount { font-size: 13px; color: var(--muted); font-weight: 600; }
.cl-group ul { list-style: none; margin: 0; padding: 0; }
.cl-group li { padding: 8px 0; border-top: 1px dashed var(--line); }
.cl-group li:first-child { border-top: 0; }
.cl-group label { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; }
.cl-group input { width: 20px; height: 20px; margin: 2px 0 0; flex: none; accent-color: var(--accent); }
.cl-group input:checked + span { color: var(--muted); text-decoration: line-through; }
.cl-detail { margin: 2px 0 0 30px; font-size: 14px; color: var(--muted); }

/* 나라 카드 사진 배경: 글자가 있는 왼쪽은 흰색, 오른쪽으로 갈수록 사진이 은은하게 보임 */
.country-card { position: relative; overflow: hidden; }
.country-card.has-img {
  background:
    linear-gradient(90deg, var(--card) 0%, var(--card) 38%, rgba(255, 255, 255, .82) 70%, rgba(255, 255, 255, .6) 100%),
    var(--photo) center / cover no-repeat, var(--card);
}
.cc-head { display: flex; align-items: center; gap: 6px; }
.cc-arrow { display: none; margin-left: auto; color: var(--muted); font-size: 20px; line-height: 1; }

/* 결과 제목 줄 + 보기 방식 전환 */
.sim-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.view-toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--card); flex: none; }
.view-toggle button { border: 0; background: none; padding: 7px 10px; cursor: pointer; color: var(--muted); display: grid; place-items: center; }
.view-toggle button + button { border-left: 1px solid var(--line); }
.view-toggle svg { fill: currentColor; }
.view-toggle button[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); }

/* 간략히 보기: 나라 이름 + 모집 방식만 한 줄로 */
.list-view .results { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.list-view .country-card { padding: 12px 14px; }
.list-view .country-card strong { font-size: 16px; }
.list-view .cc-body { display: none; }
.list-view .cc-arrow { display: block; }

#sim + p { margin-top: 16px; }

/* 분류 탭 접기·펼치기 */
.tabs-more { display: contents; }
.tabs-more::before {
  content: ""; flex: none; width: 1px; align-self: stretch; margin: 4px 2px; background: var(--line);
}
.tabs.collapsed .tabs-more { display: none; }
.tabs-toggle {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  font: inherit; font-size: 14px; color: var(--muted); cursor: pointer; white-space: nowrap;
  padding: 7px 12px; border-radius: 999px; background: transparent; border: 1px dashed #c9c9c4;
}
.tabs-toggle:hover { color: var(--text); border-color: var(--muted); }
.tabs-toggle svg { transition: transform .15s; }
.tabs-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.tt-count {
  display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: 999px; background: var(--line); color: var(--text); font-size: 12px; font-weight: 700;
}
.tt-close { display: none; }
.tabs-toggle[aria-expanded="true"] .tt-open { display: none; }
.tabs-toggle[aria-expanded="true"] .tt-close { display: inline; }

.method.pending { background: var(--warn-soft); border-color: #f0d9a8; color: var(--warn); }

/* 준비 중인 나라 */
.preparing { margin: 20px 0 0; padding: 12px 14px; border: 1px dashed var(--line); border-radius: 10px; font-size: 14px; color: var(--muted); }
.preparing b { color: var(--text); margin-right: 6px; }
.preparing span { font-size: 13px; }

/* 소개·면책·제보·방침 페이지 */
.doc { max-width: 720px; }
.doc p, .doc li { line-height: 1.75; }
.doc li { margin: 6px 0; }
.doc h2 { font-size: 18px; margin-top: 28px; }
.callout { background: var(--accent-soft); border-radius: 10px; padding: 12px 14px; }
footer p { margin: 0 0 12px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.foot-links a { color: var(--muted); }
.foot-links a[aria-current="page"] { color: var(--text); font-weight: 700; }
footer .foot-mail { margin: 10px 0 0; font-size: 13px; color: var(--muted); }
.foot-mail a { color: var(--muted); }

/* 허브 첫 화면 */
.hub { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.hub-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none; }
a.hub-card:hover { border-color: var(--accent); }
.hub-card strong { font-size: 18px; }
.hub-card span { font-size: 14px; color: var(--muted); }
.hub-card em { font-style: normal; font-size: 14px; font-weight: 700; color: var(--accent); margin-top: auto; padding-top: 6px; }
.hub-card.soon { background: transparent; border-style: dashed; }
.hub-card.soon em { color: var(--muted); font-weight: 500; }

/* 없는 페이지(404) */
.notfound { padding: 24px 0 8px; }
.nf-code { margin: 0; font-size: 56px; font-weight: 800; color: var(--accent); line-height: 1; }

/* 머리글 검색 아이콘 */
.top nav { align-items: center; }
.nav-search { display: inline-flex; align-items: center; }

/* 접수 상태 */
.sch-badge { display: inline-block; margin-left: 6px; padding: 1px 9px; border-radius: 99px; font-size: 13px; font-weight: 700; text-decoration: none; border: 1px solid var(--line); color: var(--muted); background: var(--card); }
.sch-badge.ok { background: var(--accent-soft); border-color: transparent; color: var(--accent); }
.sch-badge.soon { background: var(--warn-soft); border-color: transparent; color: var(--warn); }
.sch-badge.no { background: var(--bad-soft); border-color: transparent; color: var(--bad); }
.sch-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; background: var(--line); }
.sch-dot.ok { background: var(--accent); }
.sch-dot.soon { background: #e0a030; }
.sch-dot.no { background: var(--bad); }

/* 접수 달력 */
.cal-now { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cal-now h2 { margin: 0 0 10px; font-size: 16px; }
@media (max-width: 640px) { .cal-now { grid-template-columns: 1fr; } }
.cal-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cal-chips .chip { text-decoration: none; color: var(--text); background: var(--card); }
.cal-chips .chip span { color: var(--muted); font-size: 13px; }
.cal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.cal-month { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.cal-month h3 { margin: 0 0 6px; font-size: 15px; }
.cal-month ul { list-style: none; margin: 0; padding: 0; }
.cal-month li { padding: 6px 0; border-top: 1px solid var(--line); font-size: 14px; }
.cal-month li:first-child { border-top: 0; }
.cal-month li a { font-weight: 700; color: var(--text); }
.cal-month li span { color: var(--muted); font-size: 13px; }
.cal-month li em { display: block; font-style: normal; font-size: 13px; color: var(--muted); }
.cal-month li.open em { color: var(--accent); font-weight: 700; }
.cal-month li.open em::after { content: " · 접수 중"; }
.cal-month li.done { opacity: .55; }
.cal-month.past { opacity: .6; }
.cal-month.current { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.cal-month p { margin: 0; font-size: 13px; }
.cal-notes { font-size: 14px; color: var(--muted); padding-left: 18px; }

/* 검색 결과에서 온 항목 강조 */
@keyframes flash { from { box-shadow: 0 0 0 3px var(--accent); } to { box-shadow: 0 0 0 3px transparent; } }
.flash { animation: flash 2.4s ease-out; }

/* 검색 */
.search-box input { width: 100%; padding: 14px 16px; font-size: 17px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); color: var(--text); }
.search-box input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.s-results { display: grid; gap: 8px; margin-top: 8px; }
.s-hit { display: block; padding: 12px 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none; }
.s-hit:hover { border-color: var(--accent); }
.s-hit b { display: block; }
.s-where { display: block; font-size: 12px; color: var(--muted); }
.s-sum { display: block; font-size: 15px; }
.s-more { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); }
.s-hit mark { background: #fff1b8; color: inherit; border-radius: 2px; padding: 0 1px; }
button.linklike { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; cursor: pointer; font: inherit; }

/* 비교 항목 고르기 */
.col-picker { margin-top: -4px; }
.col-picker summary { cursor: pointer; font-weight: 700; font-size: 15px; }
.col-picker summary span { font-weight: 500; color: var(--muted); font-size: 13px; }
.col-picker .picker-actions { margin-top: 10px; }
.sch-cell { white-space: nowrap; }

/* 인쇄 */
.print-only { display: none; }
@media print {
  header.top, footer, .tabs, #tabs-anchor, .term-pop, .notice, .view-toggle, .breadcrumb, .cl-tools, .picker, .col-picker { display: none !important; }
  body { background: #fff; font-size: 12pt; }
  .card, .country-card, .cal-month { box-shadow: none !important; break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
  body.print-checklist main .wrap > *:not(h1):not(#checklist) { display: none !important; }
  body.print-checklist #checklist { display: block !important; }
  body.print-checklist .cl-group { break-inside: avoid; }
  body.print-checklist input[type=checkbox] { width: 14px; height: 14px; }
}

/* 조건 비교 / 비용 비교 전환 */
.subtabs { display: inline-flex; gap: 4px; padding: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 99px; margin-bottom: 14px; }
.subtabs a { padding: 5px 14px; border-radius: 99px; text-decoration: none; color: var(--muted); font-size: 14px; font-weight: 600; }
.subtabs a[aria-current="page"] { background: var(--accent); color: #fff; }

/* 비용 비교 */
.cost-note { margin-bottom: 16px; font-size: 14px; }
.cost-note ul { margin: 6px 0 0; padding-left: 18px; color: var(--muted); }
.cost-table td small { display: block; font-size: 12px; color: var(--muted); max-width: 220px; }
.cost-table td b { white-space: nowrap; }
.cost-bar { display: block; width: 140px; height: 6px; background: var(--line); border-radius: 3px; margin-top: 6px; overflow: hidden; }
.cost-bar span { display: block; height: 100%; background: var(--accent); }
.cost-extra { display: inline-block; font-size: 12px; padding: 1px 7px; border-radius: 99px; background: var(--warn-soft); color: var(--warn); white-space: nowrap; margin: 1px 0; }

/* 사진 출처 */
.credits { columns: 3 160px; font-size: 13px; color: var(--muted); padding-left: 18px; }

/* 기관마다 다름 / 변경 예정 표시 */
.checking.differ { background: #e7eefb; color: #2451a6; }
.checking.change { background: #eef4e6; color: #4a6b1f; }
footer p .checking { margin: 0 2px; }
.keyfacts .checking { display: inline-block; font-size: 11px; color: inherit; }
.keyfacts .checking.differ { color: #2451a6; }
.keyfacts .checking.change { color: #4a6b1f; }
.keyfacts .checking:not(.differ):not(.change) { color: var(--warn); }

/* 기관별 안내 (배지를 누르면 뜨는 말풍선) */
button.agency-btn { border: 0; cursor: pointer; font-family: inherit; }
button.agency-btn:hover, button.agency-btn.open { filter: brightness(0.95); text-decoration: underline; }
.agency-list { list-style: none; margin: 10px 0 0; padding: 0; }
.agency-list li { padding: 10px 0; border-top: 1px solid var(--line); }
.agency-list li b { display: block; font-size: 14px; }
.agency-list li > span { display: block; font-size: 15px; margin: 2px 0 4px; }
.agency-list .meta { font-size: 12px; }
.agency-list .meta { display: flex; flex-wrap: wrap; gap: 2px 10px; }

/* 나라 페이지 맨 아래 이동 */
.country-nav { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; align-items: center; margin: 32px 0 8px; }
.country-nav a { display: inline-block; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); color: var(--text); text-decoration: none; font-weight: 600; font-size: 15px; }
.country-nav a:hover { border-color: var(--accent); }
.country-nav .cn-next { justify-self: end; }
.country-nav .cn-prev { justify-self: start; }
.country-nav .cn-list { background: var(--accent); border-color: var(--accent); color: #fff; }
@media (max-width: 480px) { .country-nav a { padding: 9px 10px; font-size: 14px; } }

/* 로고 아이콘 */
.logo { display: inline-flex; align-items: center; gap: 7px; }
.logo-mark { width: 20px; height: 20px; color: var(--accent); flex: none; }

/* 하단 표시 설명 (접기) */
.legend summary { cursor: pointer; margin-bottom: 8px; }
.legend ul { list-style: none; padding: 0; margin: 0 0 12px; }
.legend li { margin: 6px 0; }

/* 맨 위로 버튼 */
.to-top { position: fixed; right: 16px; bottom: 20px; z-index: 30; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--text); font-size: 20px; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.12); }
.to-top:hover { border-color: var(--accent); color: var(--accent); }
@media print { .to-top { display: none !important; } }

/* 허브 첫 화면: 나이로 바로 찾기 + 접수 현황 */
.hub-quick { margin-bottom: 14px; }
.hub-quick label { display: block; margin-bottom: 10px; }
.hub-quick label b { display: block; font-size: 18px; }
.hub-quick label span { display: block; font-size: 14px; color: var(--muted); }
.hub-quick-row { display: flex; gap: 8px; }
.hub-quick-row input { flex: 1; min-width: 0; font: inherit; font-size: 17px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--text); }
.hub-quick-row button { font: inherit; font-weight: 700; padding: 0 20px; border: 0; border-radius: 10px; background: var(--accent); color: #fff; cursor: pointer; }
.hub-now { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 8px; }
.hub-now h2 { margin: 0 0 10px; font-size: 16px; }
@media (max-width: 640px) { .hub-now { grid-template-columns: 1fr; } }
.hub-title { font-size: 18px; margin: 28px 0 10px; }
.hub-updated { margin-top: 14px; }

/* 휴대폰: 나라 찾기 입력칸을 촘촘하게 */
@media (max-width: 560px) {
  .filter { gap: 10px; padding: 14px; }
  .filter label { font-size: 14px; margin-bottom: 4px; }
  .filter input, .filter select { padding: 10px; font-size: 16px; }
  .filter .hint:not(#age-hint) { display: none; }
  .filter + #sim, #filter + #sim { margin-top: 0; }
}

/* 위쪽 돋보기 검색 (페이지 위에 작게 펼침) */
.top { position: sticky; top: 0; z-index: 40; }
.hs-panel { position: sticky; top: 56px; z-index: 39; height: 0; }
.hs-box { margin-left: auto; width: min(460px, 100%); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(0,0,0,.14); padding: 10px; margin-top: 6px; }
.hs-box input { width: 100%; font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--text); }
.hs-box input:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.hs-results { list-style: none; margin: 6px 0 0; padding: 0; max-height: min(50vh, 380px); overflow-y: auto; }
.hs-results li a { display: block; padding: 7px 8px; border-radius: 8px; color: var(--text); text-decoration: none; }
.hs-results li a:hover, .hs-results li a:focus { background: var(--accent-soft); }
.hs-results b { display: block; font-size: 14px; font-weight: 600; }
.hs-results span { display: block; font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hs-results .hs-country b { color: var(--accent); }
.hs-empty { padding: 8px; font-size: 13px; color: var(--muted); }
.hs-all { display: block; text-align: right; font-size: 13px; padding: 6px 8px 2px; }

/* 허브 카드 (워홀 카드 안 작은 검색칸) */
.hub-card { position: relative; }
.hub-card-link { display: flex; flex-direction: column; gap: 6px; color: var(--text); text-decoration: none; }
.hub-card-link strong { font-size: 18px; }
.hub-card-link span { font-size: 14px; color: var(--muted); }
div.hub-card:not(.soon):hover { border-color: var(--accent); }
.hub-mini { display: flex; gap: 6px; margin-top: 12px; }
.hub-mini input { flex: 1; min-width: 0; font: inherit; font-size: 15px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; background: var(--bg); color: var(--text); }
.hub-mini input:focus { outline: 2px solid var(--accent); outline-offset: 0; background: #fff; }
.hub-mini button { width: 42px; border: 0; border-radius: 9px; background: var(--accent); color: #fff; font-size: 18px; font-weight: 700; cursor: pointer; }
.hub-card-more { margin-top: auto; padding-top: 12px; font-size: 14px; font-weight: 700; color: var(--accent); text-decoration: none; }

/* 풀이 브랜드 로고 + 분야 묶음 이름 */
.logo .lg-ko { letter-spacing: -.3px; }
.logo .lg-en { font-size: 12px; font-weight: 600; color: var(--muted); margin-left: 1px; letter-spacing: .4px; }
.logo { margin-right: 0; }
.sub-brand { margin-right: auto; margin-left: 2px; padding-left: 12px; border-left: 1px solid var(--line); color: var(--text); text-decoration: none; font-size: 14px; font-weight: 600; white-space: nowrap; }
.sub-brand[aria-current="page"] { color: var(--accent); }
.top .wrap > .logo:not(:has(+ .sub-brand)) { margin-right: auto; }
@media (max-width: 480px) { .logo .lg-en { display: none; } .sub-brand { font-size: 13px; padding-left: 9px; } .top nav { gap: 10px; font-size: 14px; } }

/* 풀이 첫 화면 */
.hub-headline { font-size: clamp(22px, 4.5vw, 30px); margin: 8px 0 22px; }
.cat-card .cat-sections { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.cat-card .cat-sections li { font-size: 13px; padding: 3px 10px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.cat-card .cat-sections li.soon { background: var(--bg); color: var(--muted); font-weight: 500; }
.cat-card .cat-sections small { font-size: 11px; }
.checking.stale { background: #eeeeec; color: #6b6b70; }

/* 소식 */
.news-list { display: grid; gap: 10px; }
.news-item { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none; }
.news-item:hover { border-color: var(--accent); }
.news-item strong { font-size: 17px; }
.news-item span { grid-column: 1; font-size: 14px; color: var(--muted); }
.news-item em { grid-column: 2; grid-row: 1; font-style: normal; font-size: 13px; color: var(--muted); }
.news-post table { font-size: 14px; }
.news-post blockquote { margin: 12px 0; padding: 10px 14px; border-left: 3px solid var(--accent); background: var(--accent-soft); border-radius: 0 8px 8px 0; }
.notice-line { display: flex; align-items: center; gap: 8px; margin: 18px 0 -4px; font-size: 14px; color: var(--text); text-decoration: none; }
.notice-line span { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--accent); color: #fff; flex: none; }
.notice-line em { font-style: normal; color: var(--muted); font-size: 13px; margin-left: auto; flex: none; }
.notice-line:hover { color: var(--accent); }
/* 휴대폰 머리글: 한 줄 유지 */
.logo, .top nav a { white-space: nowrap; }
@media (max-width: 440px) { .sub-brand { display: none; } .logo { margin-right: auto; } .top .wrap { gap: 10px; } .top nav { gap: 11px; } }
@media (max-width: 350px) { .top nav { font-size: 13px; gap: 8px; } }
