/* =========================================================
 * 토큰
 * ========================================================= */
:root {
  --brand: #0F5DA8;
  --brand-dark: #0B4A87;
  --brand-weak: #E8F1FA;
  --ink: #0B2A4A;
  --paper: #F4F7FA;
  --text: #1C2B3A;
  --muted: #5A6B7D;
  --line: #DCE3EB;
  --white: #FFFFFF;
  --kakao: #FEE500;
  --kakao-ink: #191919;

  --header-h: 82px;
  --tabbar-h: 62px;

  /* 메뉴·빠른 링크 (머큐리 페이지 구조, 이 사이트 네이비 팔레트) */
  --nav-bg: rgba(11, 42, 74, .92);
  --nav-solid: #0B2A4A;
  --nav-panel: #12385E;
  --nav-drawer: #0A2440;
  --nav-bar: #071D33;
  --nav-line: rgba(255, 255, 255, .14);
  --nav-text: #B9CCDD;
  --nav-accent: #8EC5F5;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 6px 24px rgba(11, 42, 74, .08);
  --gutter: max(32px, calc((100vw - 1240px) / 2));

  --font: 'Noto Sans KR', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}

/* =========================================================
 * 기본
 * ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: hidden; }
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--white);
  word-break: keep-all;
  overflow-wrap: break-word;
}
h1, h2, h3, h4, h5, h6 { margin: 0; color: var(--ink); line-height: 1.3; word-break: keep-all; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, select, input { font: inherit; color: inherit; }
img { max-width: 100%; display: block; }
code { font-family: Consolas, 'Courier New', monospace; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 1000;
  background: var(--ink); color: var(--white); padding: 10px 16px; border-radius: 8px;
}
.skip-link:focus { top: 8px; }
:focus-visible { outline: 3px solid rgba(15, 93, 168, .45); outline-offset: 2px; }
#app:focus { outline: none; }

/* =========================================================
 * 버튼
 * ========================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 46px; padding: 0 20px;
  border-radius: var(--radius-sm); border: 1px solid transparent;
  font-weight: 700; font-size: 15px; line-height: 1.2; white-space: nowrap;
  cursor: pointer; transition: background-color .15s, border-color .15s, color .15s;
}
.btn-sm { min-height: 38px; padding: 0 14px; font-size: 14px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn-brand { background: var(--brand); color: var(--white); }
.btn-brand:hover { background: var(--brand-dark); }
.btn-line { background: var(--white); color: var(--ink); border-color: var(--line); }
.btn-line:hover { border-color: var(--brand); color: var(--brand); }
.btn-ghost { background: var(--brand-weak); color: var(--brand); }
.btn-ghost:hover { background: #D8E8F6; }
.btn-kakao { background: var(--kakao); color: var(--kakao-ink); }
.btn-kakao:hover { background: #F2DA00; }
.btn.is-disabled, .is-disabled[aria-disabled="true"] { opacity: .5; cursor: not-allowed; pointer-events: none; }

.ico-kakao, .ico-phone { display: inline-block; width: 18px; height: 18px; flex: none; background: currentColor; }
.ico-kakao {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 3C6.5 3 2 6.6 2 11c0 2.8 1.9 5.3 4.7 6.7l-1 3.6c-.1.3.3.6.6.4l4.2-2.8c.5.1 1 .1 1.5.1 5.5 0 10-3.6 10-8S17.5 3 12 3z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 3C6.5 3 2 6.6 2 11c0 2.8 1.9 5.3 4.7 6.7l-1 3.6c-.1.3.3.6.6.4l4.2-2.8c.5.1 1 .1 1.5.1 5.5 0 10-3.6 10-8S17.5 3 12 3z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.ico-phone {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15.1 15.1 0 0 0 6.6 6.6l2.2-2.2c.3-.3.7-.4 1-.2 1.1.4 2.3.6 3.6.6.6 0 1 .4 1 1V20c0 .6-.4 1-1 1A17 17 0 0 1 3 4c0-.6.4-1 1-1h3.5c.6 0 1 .4 1 1 0 1.3.2 2.5.6 3.6.1.3 0 .7-.2 1l-2.3 2.2z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.6 10.8a15.1 15.1 0 0 0 6.6 6.6l2.2-2.2c.3-.3.7-.4 1-.2 1.1.4 2.3.6 3.6.6.6 0 1 .4 1 1V20c0 .6-.4 1-1 1A17 17 0 0 1 3 4c0-.6.4-1 1-1h3.5c.6 0 1 .4 1 1 0 1.3.2 2.5.6 3.6.1.3 0 .7-.2 1l-2.3 2.2z'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* =========================================================
 * 상단 메뉴 — 머큐리 페이지와 같은 구조 (고정 헤더 + 그룹별 드롭다운)
 * ========================================================= */
body { padding-top: var(--header-h); }

.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--header-h);
  padding: 0 var(--gutter);
  display: flex; align-items: center; gap: 48px;
  background: var(--nav-bg);
  border-bottom: 1px solid var(--nav-line);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: var(--white);
}

.logo { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.logo-mark {
  width: 38px; height: 38px; border-radius: 10px; background: var(--white);
  display: flex; align-items: center; justify-content: center; overflow: hidden; flex: none;
}
.logo-mark img { width: 82%; height: 82%; object-fit: contain; display: block; }
.logo-text { display: flex; flex-direction: column; font-weight: 800; font-size: 17px; color: var(--white); line-height: 1.2; }
.logo-text small { font-size: 11px; font-weight: 700; color: var(--nav-accent); letter-spacing: .04em; }

.main-nav { display: flex; align-items: center; gap: clamp(18px, 2.2vw, 34px); margin-left: auto; }
.nav-group { position: relative; padding: 31px 0; }
.nav-trigger {
  border: 0; padding: 0; background: none; cursor: pointer;
  font-size: 14px; font-weight: 600; white-space: nowrap; color: var(--white);
}
.nav-trigger::after { content: '+'; margin-left: 7px; color: var(--nav-accent); font-weight: 400; }
.nav-group:hover .nav-trigger,
.nav-group:focus-within .nav-trigger,
.nav-group.is-current .nav-trigger { color: var(--nav-accent); }
.submenu {
  position: absolute; top: 72px; left: -16px; min-width: 190px; padding: 10px 0;
  opacity: 0; visibility: hidden; transform: translateY(8px);
  background: var(--nav-panel); border: 1px solid var(--nav-line);
  transition: .2s ease;
}
.nav-group:hover .submenu,
.nav-group:focus-within .submenu { opacity: 1; visibility: visible; transform: translateY(0); }
/* 하위 메뉴를 누른 직후에는 마우스가 메뉴 위에 있어도 닫힌 상태 유지 */
.nav-group.force-hide .submenu { opacity: 0 !important; visibility: hidden !important; transform: translateY(8px) !important; }
.submenu a { display: block; padding: 10px 16px; color: var(--nav-text); font-size: 13px; white-space: nowrap; }
.submenu a:hover { color: var(--nav-accent); background: rgba(255, 255, 255, .06); }
.submenu a.is-current { color: var(--white); font-weight: 700; }
.submenu a.is-highlight { background: rgba(142, 197, 245, .12); color: #CFE6FB; }
.submenu a.is-highlight:hover { color: var(--nav-accent); background: rgba(142, 197, 245, .2); }

.menu-toggle { display: none; border: 0; background: transparent; cursor: pointer; }
.drawer-backdrop { display: none; }

/* =========================================================
 * 빠른 링크 — 모바일 하단 고정 바 / PC 오른쪽 고정 바 (머큐리 페이지와 같은 스타일)
 * ========================================================= */
.mobile-tabbar { display: none; }
.desktop-quicklinks { display: none; }
.icon-badge { width: 24px; height: 24px; object-fit: contain; border-radius: 6px; display: block; }
.icon-badge-phone { background: #fff; padding: 4px; box-sizing: border-box; }
.mobile-tabbar a.is-disabled, .desktop-quicklinks a.is-disabled { opacity: .45; cursor: default; pointer-events: none; }

/* 바깥 여백(화면 폭 - 1240px)/2 가 바 폭(64px) + 오른쪽 20px보다 넓어지는 1440px부터 표시 */
@media (min-width: 1440px) {
  .desktop-quicklinks {
    display: flex; flex-direction: column;
    position: fixed; right: 20px; top: 50%; transform: translateY(-50%); z-index: 90;
    background: var(--nav-panel); border: 1px solid var(--nav-line);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
  }
  .desktop-quicklinks a {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    width: 64px; height: 64px; padding: 6px;
    color: var(--nav-text); font-size: 10px; line-height: 1.25; text-align: center;
    border-bottom: 1px solid var(--nav-line);
    transition: color .2s, background .2s;
  }
  .desktop-quicklinks a:last-child { border-bottom: 0; }
  .desktop-quicklinks a:hover { color: var(--nav-accent); background: rgba(255, 255, 255, .05); }
}

/* =========================================================
 * 섹션 공통
 * ========================================================= */
.section { padding: 72px var(--gutter); }
.section-paper { background: var(--paper); }

.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 800; color: var(--brand);
  letter-spacing: .04em; margin-bottom: 10px;
}
.eyebrow-light { color: #9CC7F0; }

.sec-head { display: flex; flex-direction: column; margin-bottom: 28px; }
.sec-head h2 { font-size: 30px; font-weight: 800; }
.sec-head p { margin-top: 10px; color: var(--muted); }

.loading, .empty { padding: 32px 0; color: var(--muted); text-align: center; }

.notice {
  background: var(--brand-weak); border-radius: var(--radius); padding: 20px 22px;
  display: flex; flex-direction: column; gap: 8px; align-items: flex-start;
}
.notice strong { color: var(--ink); }
.notice p { color: var(--text); }
.notice-inline { margin-bottom: 24px; }

.sample-flag {
  display: inline-block; background: #FFF4D6; color: #7A5600; font-weight: 700;
  border-radius: 6px; padding: 2px 8px;
}

/* =========================================================
 * 홈 — 히어로
 * ========================================================= */
/* 히어로 사진: 사진 교체는 images/home-hero.jpg만 바꾸면 됨.
   글씨가 있는 왼쪽은 어둡게, 배가 있는 오른쪽으로 갈수록 옅어지는 그라데이션 */
.hero {
  background:
    linear-gradient(90deg, rgba(6, 22, 40, .9) 0%, rgba(6, 22, 40, .72) 36%, rgba(6, 22, 40, .28) 68%, rgba(6, 22, 40, .1) 100%),
    linear-gradient(0deg, rgba(6, 22, 40, .55) 0%, rgba(6, 22, 40, 0) 40%),
    var(--ink) url('images/home-hero.jpg') center 62% / cover no-repeat;
  color: var(--white);
  padding: 150px var(--gutter) 190px;
}
.hero h1, .hero p, .hero .eyebrow { text-shadow: 0 1px 12px rgba(0, 0, 0, .35); }
.hero-inner { display: flex; flex-direction: column; }
.hero h1 { color: var(--white); font-size: 44px; font-weight: 800; }
.hero p { margin-top: 14px; font-size: 18px; color: #D3E3F3; }
.hero h1 { line-height: 1.25; }
/* 히어로 버튼 — 머큐리 페이지 버튼과 같은 모양(각진 모서리, 높이 50px, 올리면 살짝 뜸) */
.hero-cta { display: flex; gap: 12px; margin-top: 34px; }
.hero-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 22px;
  background: var(--nav-accent); border: 1px solid var(--nav-accent); color: var(--ink);
  font-size: 15px; font-weight: 700; transition: transform .2s, background-color .2s;
}
.hero-btn:hover { transform: translateY(-2px); background: #A9D3F8; }

/* 홈 — 내 근처 시험장 찾기 바 */
.finder-bar { padding: 0 var(--gutter); margin-top: -44px; position: relative; z-index: 2; }
.finder {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  border: 1px solid var(--line);
  padding: 20px 24px; display: flex; align-items: center; gap: 16px;
}
.finder-title { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.finder-title strong { font-size: 18px; color: var(--ink); }
.finder-title span { font-size: 14px; color: var(--muted); }
.finder-field select { min-width: 160px; }

/* 폼 필드 */
.field { display: flex; flex-direction: column; gap: 4px; }
.field > span { font-size: 13px; font-weight: 700; color: var(--muted); }
.field select, .field input {
  height: 46px; padding: 0 40px 0 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%235A6B7D' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 14px center;
  -webkit-appearance: none; appearance: none; cursor: pointer;
}
.field select:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px rgba(15, 93, 168, .15); }

/* =========================================================
 * 시험 일정
 * ========================================================= */
.sched-filters { display: flex; gap: 12px; margin-bottom: 16px; }
.sched-filters .field { width: 180px; }
.sched-table { width: 100%; border-collapse: collapse; background: var(--white); }
.sched-table th {
  text-align: left; font-size: 13px; font-weight: 700; color: var(--muted);
  padding: 12px 14px; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--line); background: var(--paper);
}
.sched-table td { padding: 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.td-date { font-weight: 700; color: var(--ink); white-space: nowrap; }
.td-center { font-weight: 500; }
.td-note { color: var(--muted); font-size: 14px; }
.td-act { text-align: right; width: 1%; white-space: nowrap; }
.phone-call { display: inline-flex; align-items: center; gap: 12px; white-space: nowrap; }
.pc-num { font-size: 15px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.grade-tag {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  background: var(--brand-weak); color: var(--brand); font-size: 13px; font-weight: 700; white-space: nowrap;
}
.sched-cards { display: none; }
.sched-meta {
  margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px;
  font-size: 13px; color: var(--muted);
}
.more-link { margin-left: auto; font-weight: 700; color: var(--brand); font-size: 14px; }

/* 시험 일정 페이지: 왼쪽 달력 + 오른쪽 날짜별 목록 */
.sched-layout { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: 40px; align-items: start; }
.cal-wrap { position: sticky; top: calc(var(--header-h) + 20px); }
.cal { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; background: var(--white); }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal-head strong { font-size: 17px; color: var(--ink); }
.cal-nav {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: var(--white);
  font-size: 18px; line-height: 1; color: var(--ink); cursor: pointer;
}
.cal-nav:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.cal-nav:disabled { opacity: .3; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; }
.cal-dow { text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); padding: 4px 0 6px; }
.cal-day {
  position: relative; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 50%; background: none; font-size: 14px; color: var(--text); padding: 0;
}
.cal-dow.is-sun, .cal-day.is-sun { color: #D14343; }
.cal-dow.is-sat, .cal-day.is-sat { color: var(--brand); }
.cal-day.is-past { color: #B8C2CC; }
.cal-day.is-today { box-shadow: inset 0 0 0 1.5px var(--ink); }
button.cal-day { cursor: pointer; font-weight: 700; }
button.cal-day:hover { background: var(--brand-weak); }
.cal-dot { position: absolute; left: 50%; bottom: 12%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--brand); }
.cal-day.is-selected, .cal-day.is-selected:hover { background: var(--brand); color: var(--white); }
.cal-day.is-selected .cal-dot { background: var(--white); }
.cal-legend { position: relative; margin-top: 12px; padding-left: 12px; font-size: 12px; color: var(--muted); }
.cal-legend .cal-dot { left: 2px; top: 7px; bottom: auto; margin-left: 0; }

.sched-main .sched-filters { margin-bottom: 18px; }
.day-summary {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px;
  padding-bottom: 14px; border-bottom: 2px solid var(--ink);
}
.day-summary strong { font-size: 18px; color: var(--ink); }
.day-summary span { font-weight: 700; color: var(--brand); }
.day-group { border-bottom: 1px solid var(--line); padding: 16px 0; }
.day-head { display: flex; align-items: baseline; gap: 8px; font-size: 16px; margin-bottom: 8px; }
.day-head span { font-size: 13px; font-weight: 500; color: var(--muted); }
.day-list { display: flex; flex-direction: column; }
.day-item { display: flex; align-items: center; gap: 14px; padding: 8px 0; }
.day-item .grade-tag { width: 72px; text-align: center; flex: none; }
.grade-tag.is-yacht { background: #E6F4EC; color: #1E7B45; }
.di-text { flex: 1; min-width: 0; display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 10px; }
.di-text strong { color: var(--ink); font-size: 16px; }
.di-text span { font-size: 14px; color: var(--muted); }
.di-text .di-time { color: var(--text); }
.day-groups .empty { padding: 40px 0; }
.day-groups.is-single .day-head { display: none; }
.cal-note { margin-top: 12px; font-size: 13px; line-height: 1.6; color: var(--muted); }
.cal-note-link { font-weight: 700; color: var(--brand); white-space: nowrap; }
.cal-jump { display: none; border: 0; background: none; padding: 0; font-size: 14px; font-weight: 700; color: var(--brand); cursor: pointer; }

/* =========================================================
 * 취득 4단계
 * ========================================================= */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; counter-reset: step; }
.step a {
  height: 100%; display: flex; flex-direction: column; gap: 8px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px;
  transition: border-color .15s, box-shadow .15s;
}
.step a:hover { border-color: var(--brand); box-shadow: var(--shadow); }
.step-no { font-size: 12px; font-weight: 800; color: var(--brand); letter-spacing: .06em; }
.step strong { font-size: 20px; color: var(--ink); }
.step p { color: var(--muted); font-size: 15px; }

/* =========================================================
 * 띠 배너
 * ========================================================= */
.band { padding: 0 var(--gutter); margin: 0 0 24px; }
.section-paper + .band { margin-top: 72px; }
.band-inner {
  border-radius: var(--radius); padding: 36px 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.band-text { display: flex; flex-direction: column; min-width: 0; }
.band-text h2 { font-size: 24px; font-weight: 800; }
.band-text p { margin-top: 8px; }
.band-actions { display: flex; gap: 10px; flex-wrap: wrap; flex: none; }
.band-center .band-inner { background: var(--paper); border: 1px solid var(--line); }
.band-center .band-text p { color: var(--muted); }
.band-kakao { margin-bottom: 72px; }
.band-kakao .band-inner { background: var(--kakao); }
.band-kakao .band-text h2 { color: var(--kakao-ink); }
.band-kakao .band-text p { color: #3A3A00; }
.band-kakao .btn-kakao { background: var(--kakao-ink); color: var(--kakao); }
.band-kakao .btn-kakao:hover { background: #000; }

/* =========================================================
 * 하위 페이지
 * ========================================================= */
.page-hero { background: var(--paper); border-bottom: 1px solid var(--line); padding: 44px var(--gutter) 36px; }
.page-hero-inner { display: flex; flex-direction: column; }
.crumb { display: flex; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 18px; }
.crumb a:hover { color: var(--brand); }
.page-hero h1 { font-size: 36px; font-weight: 800; }
.page-hero p { margin-top: 10px; color: var(--muted); font-size: 17px; }

/* 본문 블록 (content.js) */
.section-tight { padding-bottom: 0; }
.content { max-width: 880px; display: flex; flex-direction: column; gap: 28px; }
.cb-lead { font-size: 18px; line-height: 1.75; color: var(--ink); }
.cb { display: flex; flex-direction: column; }
.cb-title { font-size: 20px; font-weight: 800; margin-bottom: 14px; }
.cb-note { margin-top: 10px; font-size: 14px; color: var(--muted); }

.facts { margin: 0; border-top: 2px solid var(--ink); }
.facts div { display: flex; gap: 20px; padding: 15px 4px; border-bottom: 1px solid var(--line); }
.facts dt { width: 150px; flex: none; font-weight: 700; color: var(--ink); }
.facts dd { margin: 0; color: var(--text); }

.cb-list { border-top: 2px solid var(--ink); }
.cb-list li { position: relative; padding: 15px 4px 15px 22px; border-bottom: 1px solid var(--line); }
.cb-list li::before { content: ''; position: absolute; left: 6px; top: 25px; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }

.table-wrap { overflow-x: auto; }
.cb-table { width: 100%; border-collapse: collapse; }
.cb-table th, .cb-table td { padding: 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.cb-table thead th { font-size: 13px; color: var(--muted); background: var(--paper); border-top: 2px solid var(--ink); white-space: nowrap; }
.cb-table tbody th { color: var(--ink); white-space: nowrap; }

.flow { display: flex; flex-direction: column; gap: 16px; }
.flow-item {
  display: grid; grid-template-columns: minmax(0, 260px) minmax(0, 1fr); gap: 24px; align-items: center;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: var(--white);
}
.flow-img { width: 100%; aspect-ratio: 2 / 1; object-fit: cover; border-radius: var(--radius-sm); background: var(--paper); }
.flow-body h3 { font-size: 19px; margin-bottom: 8px; }
.flow-body li { position: relative; padding-left: 14px; color: var(--text); }
.flow-body li + li { margin-top: 4px; }
.flow-body li::before { content: '–'; position: absolute; left: 0; color: var(--muted); }

.files { display: flex; flex-direction: column; gap: 10px; }
.file { display: flex; align-items: center; gap: 16px; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; background: var(--white); }
.file-ico {
  width: 46px; height: 54px; flex: none; border-radius: 8px; background: #FDECEC; color: #C0392B;
  display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800;
}
.file-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.file-text strong { color: var(--ink); }
.file-text span { font-size: 14px; color: var(--muted); }
.file-text small { font-size: 12px; color: var(--muted); }

.cb-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding-top: 4px; }
.cb-links span { font-size: 13px; font-weight: 700; color: var(--muted); }
.cb-links a { font-size: 15px; font-weight: 700; color: var(--brand); }
.cb-links a:hover { text-decoration: underline; }
.content-source { font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; }

/* 시험장 찾기 */
.segs { display: flex; flex-wrap: wrap; gap: 8px; }
.seg {
  height: 46px; padding: 0 20px; border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: var(--white); font-size: 15px; font-weight: 700; color: var(--ink); cursor: pointer;
}
.seg:hover { border-color: var(--brand); color: var(--brand); }
.seg.is-active { background: var(--ink); border-color: var(--ink); color: var(--white); }
.find-help { margin: 14px 0 24px; font-size: 14px; color: var(--muted); }

.finder-layout { display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 28px; align-items: start; }
.find-summary {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px;
  padding-bottom: 14px; margin-bottom: 14px; border-bottom: 2px solid var(--ink);
}
.find-summary strong { font-size: 18px; color: var(--ink); }
.find-summary span { font-weight: 700; color: var(--brand); }
.link-btn { margin-left: auto; border: 0; background: none; padding: 0; font-size: 14px; font-weight: 700; color: var(--muted); text-decoration: underline; cursor: pointer; }
.link-btn:hover { color: var(--brand); }
.center-list { display: flex; flex-direction: column; gap: 12px; }
.cl-group { font-size: 16px; margin-top: 14px; }
.cl-group:first-child { margin-top: 0; }
.cl-group span { font-size: 14px; color: var(--muted); font-weight: 500; }
.center-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: var(--white); }
.cc-head { display: flex; flex-direction: column; gap: 6px; }
.cc-tags { display: flex; align-items: center; gap: 8px; }
.cat-tag { display: inline-block; padding: 2px 9px; border-radius: 6px; font-size: 12px; font-weight: 800; background: var(--brand-weak); color: var(--brand); }
.cat-tag.cat-1 { background: #EFEAFB; color: #5B3FB0; }
.cat-tag.cat-2 { background: #E6F4EC; color: #1E7B45; }
.cat-tag.cat-3 { background: #FFF1E0; color: #A3560A; }
.cc-tags, .cat-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.cc-region { font-size: 13px; font-weight: 700; color: var(--muted); }
.cc-head h3 { font-size: 18px; }
.cc-addr { margin-top: 8px; color: var(--text); font-size: 15px; }
.cc-note { color: var(--muted); }
.cc-phone { margin-top: 2px; font-size: 15px; font-weight: 700; }
.cc-phone a { color: var(--ink); }
.cc-actions { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 8px; }

.map-wrap { position: sticky; top: calc(var(--header-h) + 20px); }
.kmap { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.kmap svg { display: block; width: 100%; height: auto; max-height: 620px; margin: 0 auto; }
.kmap-region {
  fill: #CFE0F1; fill-rule: evenodd; stroke: var(--white); stroke-width: 1.2; stroke-linejoin: round;
  cursor: pointer; transition: fill .15s;
}
.kmap-region.is-hover { fill: #A8C8E8; }
.kmap-region:focus { outline: none; }
.kmap-region:focus-visible { stroke: var(--ink); stroke-width: 2; }
.kmap-region.is-empty { fill: #E3E8EE; }
.kmap-region.is-empty.is-hover { fill: #D5DCE4; }
.kmap-region.is-selected, .kmap-region.is-selected.is-hover { fill: var(--brand); stroke: var(--ink); stroke-width: 1.6; }
/* 시험장이 없어 도에 합쳐 그린 시: 테두리를 채움색과 같게 칠해 도의 경계선까지 덮음 */
.kmap-region.is-merged { stroke: #CFE0F1; stroke-width: 2; }
.kmap-region.is-merged.is-hover { stroke: #A8C8E8; }
.kmap-region.is-merged.is-empty { stroke: #E3E8EE; }
.kmap-region.is-merged.is-empty.is-hover { stroke: #D5DCE4; }
.kmap-region.is-merged.is-selected, .kmap-region.is-merged.is-selected.is-hover { stroke: var(--brand); stroke-width: 2; }
.kmap-label { cursor: pointer; text-anchor: middle; }
.kmap-name { font-size: 17px; font-weight: 800; fill: var(--ink); paint-order: stroke; stroke: rgba(255, 255, 255, .85); stroke-width: 3px; }
.kmap-label.is-empty .kmap-name { fill: #8A97A6; }
.kmap-label.is-selected .kmap-name { fill: var(--white); stroke: var(--ink); }
.kmap-label.is-city .kmap-name { font-size: 13px; }
.kmap-label.is-hidden { display: none; }
.map-ph {
  min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  padding: 24px; text-align: center; color: var(--muted);
}
.map-ph strong { font-size: 18px; color: var(--ink); }

/* 시험장 정보 */
.cc-head h3 a:hover { color: var(--brand); text-decoration: underline; }
.place { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 340px); gap: 48px; align-items: start; }
.place .info-list { margin-top: 0; border-top: 2px solid var(--ink); }
.place .info-list dt { width: 80px; }
.pl-link { color: var(--brand); font-weight: 700; word-break: break-all; }
.place-side { display: flex; flex-direction: column; gap: 12px; }
.programs { margin-top: 28px; }
.programs h2 { font-size: 17px; margin-bottom: 8px; }
.programs ul { border-top: 1px solid var(--line); }
.programs li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pg-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pg-text strong { color: var(--ink); font-size: 15px; }
.pg-text span { font-size: 13px; color: var(--muted); }
.pg-phone { font-size: 14px; font-weight: 700; color: var(--brand); white-space: nowrap; }

/* 경기조종면허시험장(청평) */
.center-intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.ci-body { display: flex; flex-direction: column; }
.ci-body h2 { font-size: 26px; font-weight: 800; }
.info-list { margin: 18px 0 0; border-top: 1px solid var(--line); }
.info-list div { display: flex; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.info-list dt { width: 56px; flex: none; font-weight: 700; color: var(--muted); }
.info-list dd { margin: 0; color: var(--ink); }
.info-list dd a { color: var(--brand); font-weight: 700; }
.ci-note { margin-top: 18px; color: var(--muted); }
.ci-actions { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 10px; }
.more-from {
  display: flex; flex-direction: column; align-items: flex-start; gap: 14px;
  padding: 28px; border-radius: var(--radius); border: 1px solid var(--line);
}
.more-from p { color: var(--muted); }

/* 404 */
.notfound { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; min-height: 50vh; }
.notfound h1 { font-size: 34px; }
.notfound p { color: var(--muted); margin-bottom: 8px; }

/* =========================================================
 * 사이트 안내 띠 + 마린랜드 푸터
 * ========================================================= */
.site-strip { background: var(--paper); border-top: 1px solid var(--line); padding: 20px var(--gutter); }
.site-strip-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; }
.site-strip-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.site-strip-links a { font-size: 14px; font-weight: 700; color: var(--ink); }
.site-strip-links a:hover { color: var(--brand); }
.site-strip-note { font-size: 13px; color: var(--muted); }

.site-footer { background: #1E1E1E; color: #A8A8A8; padding: 48px var(--gutter) 40px; }
.footer-inner { display: flex; flex-direction: column; gap: 36px; }
.footer-nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.footer-nav-col { display: flex; flex-direction: column; gap: 8px; }
.footer-nav-col strong { color: var(--white); font-size: 15px; margin-bottom: 4px; }
.footer-nav-col a { font-size: 14px; color: #A8A8A8; }
.footer-nav-col a:hover { color: var(--white); }
.footer-brand { display: flex; flex-direction: column; gap: 14px; padding-top: 28px; border-top: 1px solid #333; }
.footer-logo { height: 32px; width: auto; align-self: flex-start; object-fit: contain; }
.footer-biz { font-size: 13px; line-height: 1.8; }

/* =========================================================
 * 1100px 이하: 헤더·레이아웃 폭 조정
 * ========================================================= */
@media (max-width: 1100px) {
  .site-header { gap: 24px; }
  .logo-text { font-size: 15px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .finder-layout { grid-template-columns: minmax(0, 360px) minmax(0, 1fr); }
}

/* =========================================================
 * 모바일 (900px 이하) — 기본 규칙보다 뒤에 둡니다
 * ========================================================= */
@media (max-width: 900px) {
  :root { --gutter: 20px; }

  body { padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); }
  body.drawer-open { overflow: hidden; }

  /* 하위 position: fixed 드로어가 헤더 기준으로 잘리지 않도록 모바일에서는 블러를 끔 */
  .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--nav-solid); }
  .logo-mark { width: 34px; height: 34px; }

  .menu-toggle { display: block; position: relative; width: 26px; height: 20px; margin-left: auto; padding: 0; }
  .menu-toggle span {
    position: absolute; left: 0; width: 100%; height: 2px; background: var(--white);
    transition: top .2s ease, transform .2s ease;
  }
  .menu-toggle span:first-child { top: 5px; }
  .menu-toggle span:last-child { top: 13px; }
  .menu-toggle[aria-expanded="true"] span { top: 9px; }
  .menu-toggle[aria-expanded="true"] span:first-child { transform: rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:last-child { transform: rotate(-45deg); }

  .main-nav {
    display: none; position: fixed; top: var(--header-h); right: 0; bottom: 0; z-index: 140;
    width: min(78vw, 320px); margin: 0; padding: 12px 0 110px;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--nav-drawer); border-left: 1px solid var(--nav-line);
    overflow-y: auto;
  }
  .main-nav.is-open { display: flex; }
  .nav-group { padding: 0; border-bottom: 1px solid var(--nav-line); }
  .nav-trigger { width: 100%; padding: 16px 24px; text-align: left; font-size: 15px; }
  .nav-group.is-current .nav-trigger { color: var(--white); }
  .nav-group.is-open .nav-trigger { color: var(--nav-accent); }
  .submenu {
    position: static; opacity: 1; visibility: visible; transform: none;
    min-width: 0; padding: 0; max-height: 0; overflow: hidden;
    border: 0; background: rgba(255, 255, 255, .03);
    transition: max-height .2s ease;
  }
  .nav-group.force-hide .submenu { opacity: 1 !important; visibility: visible !important; transform: none !important; }
  .nav-group.is-open .submenu { max-height: 320px; }
  .submenu a { padding: 12px 36px; font-size: 13px; white-space: normal; }
  .drawer-backdrop { position: fixed; inset: 0; z-index: 95; background: rgba(3, 8, 12, .6); }
  .drawer-backdrop.is-visible { display: block; }

  .mobile-tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 120;
    height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding: 0 8px env(safe-area-inset-bottom);
    align-items: center; justify-content: space-around;
    background: var(--nav-bar); border-top: 1px solid var(--nav-line);
  }
  .mobile-tabbar a {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
    font-size: 10px; color: var(--nav-text);
  }

  .section { padding: 48px var(--gutter); }
  .sec-head h2 { font-size: 24px; }

  /* 모바일: 글씨가 화면 전체에 걸치므로 위아래로 고르게 어둡게 */
  .hero {
    padding: 72px var(--gutter) 108px;
    background:
      linear-gradient(180deg, rgba(6, 22, 40, .78) 0%, rgba(6, 22, 40, .62) 55%, rgba(6, 22, 40, .82) 100%),
      var(--ink) url('images/home-hero.jpg') 62% center / cover no-repeat;
  }
  .hero h1 { font-size: 28px; }
  .hero p { font-size: 15px; margin-top: 10px; }
  .hero-cta { margin-top: 24px; }
  .hero-btn { min-height: 48px; }

  .finder-bar { margin-top: -40px; }
  .finder { flex-direction: column; align-items: stretch; padding: 18px; gap: 12px; }
  .finder-field select { min-width: 0; width: 100%; }

  .sched-filters { gap: 8px; }
  .sched-filters .field { flex: 1; width: auto; min-width: 0; }
  .sched-table { display: none; }
  .sched-cards { display: flex; flex-direction: column; gap: 10px; }
  .sched-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; flex-direction: column; gap: 6px; background: var(--white); }
  .sc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .sc-date { color: var(--ink); font-size: 16px; }
  .sc-center { font-weight: 500; }
  .sc-center span { color: var(--muted); font-size: 14px; }
  .sc-note { font-size: 14px; color: var(--muted); }
  .sched-card .phone-call { display: flex; justify-content: space-between; margin-top: 6px; }
  .is-preview .sched-card:nth-child(n+4) { display: none; }
  .more-link { margin-left: 0; }

  .sched-layout { grid-template-columns: 1fr; gap: 24px; }
  .cal-wrap { position: static; }
  .cal { padding: 14px; }
  .cal-day { font-size: 15px; }
  .day-item { flex-wrap: wrap; gap: 8px 12px; padding: 10px 0; }
  .day-item .grade-tag { width: auto; }
  .day-item > .btn { margin-left: auto; }
  /* 모바일: 번호와 버튼을 이름 아래 한 줄로 */
  .day-item > .phone-call { flex-basis: 100%; display: flex; justify-content: space-between; }
  .day-summary .link-btn { margin-left: 0; }
  .cal-jump { display: inline; margin-left: auto; }

  .steps { grid-template-columns: 1fr; gap: 10px; }
  .step a { padding: 18px 20px; }
  .step strong { font-size: 18px; }


  .band-inner { flex-direction: column; align-items: stretch; padding: 26px 22px; gap: 18px; }
  .band-text h2 { font-size: 20px; }
  .band-actions { flex-direction: column; }
  .band-actions .btn { width: 100%; }
  .band-kakao { margin-bottom: 48px; }
  .section-paper + .band { margin-top: 48px; }

  .page-hero { padding: 28px var(--gutter) 24px; }
  .page-hero h1 { font-size: 26px; }
  .page-hero p { font-size: 15px; }
  .crumb { margin-bottom: 12px; }

  .content { gap: 22px; }
  .cb-lead { font-size: 16px; }
  .cb-title { font-size: 18px; }
  .facts div { flex-direction: column; gap: 2px; padding: 13px 2px; }
  .facts dt { width: auto; }
  .cb-table th, .cb-table td { padding: 12px 10px; font-size: 14px; }
  .flow-item { grid-template-columns: 1fr; gap: 14px; padding: 12px; }
  .file { flex-wrap: wrap; padding: 16px; }
  .file .btn { width: 100%; }

  .segs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
  .seg { padding: 0 2px; font-size: 13px; letter-spacing: -.02em; }
  .find-help { margin: 12px 0 16px; }
  .finder-layout { grid-template-columns: 1fr; gap: 20px; }
  .map-wrap { position: static; }
  .kmap { padding: 10px; }
  .kmap svg { max-width: 340px; margin: 0 auto; }
  .center-card { padding: 18px; }

  .place { grid-template-columns: 1fr; gap: 28px; }
  .center-intro { grid-template-columns: 1fr; gap: 24px; }
  .ci-actions .btn { flex: 1 1 calc(50% - 5px); }


  .site-strip-inner { flex-direction: column; align-items: flex-start; }
  .site-footer { padding: 36px var(--gutter) 32px; }
  .footer-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; }
}
