/* HOME-SBS-V1 — 사이트 공통 셸(머리말·분야 메가메뉴·서랍·안내 띠·퀵메뉴·모바일 하단바·푸터·상담 레일)
 * SBS 디자인. 모든 공개 페이지가 reference-shell.css 다음에 이 파일을 불러온다.
 *
 * 이 파일만으로 셸이 완결되도록 쓴다 — 홈은 옛 전역 style.css를 불러오지 않는다.
 * 변수는 옛 스타일과 부딪히지 않게 --sb- 접두어를 쓴다.
 * 구조(버튼·aria·hidden)는 js/nav-menu.js·js/site-shell.js가 맡고, 여기는 모양만 맡는다.
 */

@font-face { font-family: 'Pretendard'; font-weight: 400; font-display: swap; src: url('../fonts/Pretendard-Regular.subset.woff2') format('woff2'); }
@font-face { font-family: 'Pretendard'; font-weight: 700; font-display: swap; src: url('../fonts/Pretendard-Bold.subset.woff2') format('woff2'); }
@font-face { font-family: 'Pretendard'; font-weight: 800; font-display: swap; src: url('../fonts/Pretendard-ExtraBold.subset.woff2') format('woff2'); }

:root {
  --sb-brand: #1f44c9;
  --sb-brand-deep: #14226b;
  --sb-accent: #ffd43b;
  --sb-accent-ink: #231c00;
  --sb-ink: #16181d;
  --sb-ink-2: #454b57;
  --sb-ink-3: #666d78;
  --sb-ink-4: #a2a8b3;
  --sb-line: #e6e8ec;
  --sb-line-2: #f0f1f4;
  --sb-bg-2: #f6f7f9;
  --sb-dark: #111318;
  --sb-r-sm: 6px;
  --sb-r: 10px;
  --sb-wrap: 1200px;
  --sb-gutter: 20px;
  --sb-header-h: 80px;
  --sb-ease: cubic-bezier(.22, 1, .36, 1);
  /* 2026-10-03 Impeccable 감지 gpt-thin-border-wide-shadow → 짧고 또렷한 그림자(빠른 메뉴·맨 위로·패널) */
  --sb-shadow: 0 4px 12px rgba(17, 19, 24, .14), 0 1px 2px rgba(17, 19, 24, .08);
  --sb-f: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
}
/* OD-27 (원장 2026-10-02 "왼쪽 여백을 좀 더 사용") — 넓은 화면(1520px~)에서는 본문·머리말 폭을 1400px까지. 1440 이하 화면은 그대로 */
@media (min-width: 1520px) { :root { --sb-wrap: 1400px; } }

header.site, .site-utility, footer.site, .quick-dock, .quick-top, .mobile-sticky { font-family: var(--sb-f); letter-spacing: -0.01em; }
header.site svg, .quick-dock svg, .quick-top svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }

/* ── 모집 상태 배지 (홈·메가메뉴 공통) ─────────────────────────── */
.badge { display: inline-flex; align-items: center; height: 24px; padding: 0 8px; border-radius: 4px; font-size: 12px; font-weight: 700; white-space: nowrap; letter-spacing: 0; }
.badge--open { color: #1f44c9; background: #eef2ff; }
.badge--always { color: #0f7a4b; background: #e7f6ee; }
.badge--soon { color: #9a5800; background: #fff3dc; }
.badge--closed { color: #5f6670; background: #eef0f2; }   /* 대비 3.3 → 5.1:1 (2026-10-03 Impeccable 감지) */
.badge--consult { color: #334155; background: transparent; box-shadow: inset 0 0 0 1px #c9d2df; }   /* OD-24·OD-32 자격증 기본 "일정 문의" — 채운 상태 배지(모집중·개강예정·개강 안함)와 달리 테두리만: 상태가 아니라 문의 안내 */

/* ── 안내 띠 (PROMO_BADGE) ─────────────────────────────────────── */
.site-utility { background: var(--sb-brand-deep); color: #fff; border: 0; }
.site-utility .wrap { max-width: calc(var(--sb-wrap) + var(--sb-gutter) * 2); margin: 0 auto; padding: 0 var(--sb-gutter); min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.site-utility-brand { margin: 0; font-size: 13px; color: #cdd3e6; }
.site-utility-links { display: flex; gap: 4px 20px; margin: 0; padding: 0; list-style: none; flex-wrap: wrap; }
.site-utility-links a { display: inline-flex; align-items: center; min-height: 44px; font-size: 13px; font-weight: 700; color: #fff; text-decoration: none; }
.site-utility-links a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ── 머리말 ─────────────────────────────────────────────────────── */
header.site { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--sb-line); box-shadow: none; }
header.site .bar, header.site nav#main-nav, header.site .nav-group--family { position: static !important; }
header.site .bar { max-width: calc(var(--sb-wrap) + var(--sb-gutter) * 2); margin: 0 auto; padding: 0 var(--sb-gutter); min-height: var(--sb-header-h); display: flex; align-items: center; gap: 16px; }
header.site .logo { flex: 0 0 auto; font-size: inherit; }
header.site .logo a { display: flex; align-items: center; gap: 10px; min-height: 44px; color: var(--sb-ink); text-decoration: none; }
header.site .logo-mark { width: 40px; height: 40px; border-radius: 10px; background: var(--sb-brand); color: #fff; display: grid; place-items: center; font: 800 16px/1 var(--sb-f); letter-spacing: -0.04em; }
header.site .logo-txt { display: flex; flex-direction: column; line-height: 1.2; }
header.site .logo-txt strong { font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
header.site .logo-txt strong em { font-style: normal; font-weight: 700; color: var(--sb-brand); margin-left: 2px; }
header.site .logo-txt small { font-size: 12px; color: var(--sb-ink-3); margin-top: 2px; font-weight: 400; }

header.site nav#main-nav { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 0; flex-wrap: nowrap; }
header.site nav#main-nav > a.nav-item,
header.site nav#main-nav .nav-group-toggle {
  position: relative; display: inline-flex; align-items: center; gap: 0; height: var(--sb-header-h); padding: 0 9px;
  font: 400 16px/1 var(--sb-f); letter-spacing: -0.01em; color: var(--sb-ink); white-space: nowrap;
  background: none; border: 0; border-radius: 0; cursor: pointer; text-decoration: none;
}
header.site nav#main-nav .nav-group-toggle::after { display: none; }
header.site nav#main-nav > a.nav-item::before,
header.site nav#main-nav .nav-group-toggle::before {
  content: ''; position: absolute; left: 9px; right: 9px; bottom: -1px; height: 2px; background: var(--sb-ink);
  transform: scaleX(0); transition: transform .2s var(--sb-ease);
}
header.site nav#main-nav > a.nav-item:hover, header.site nav#main-nav .nav-group-toggle:hover,
header.site nav#main-nav .nav-group-toggle[aria-expanded="true"], header.site nav#main-nav [aria-current="page"] { background: none; font-weight: 700; color: var(--sb-ink); }
/* 2026-10-03 현재 위치 표시(site-shell.js markCurrentSection): 지금 보는 쪽이 속한 윗줄 항목에 굵은 글씨 + 파란 밑줄.
   색만이 아니라 밑줄로도 알린다. 온라인 캠퍼스 알약은 테두리로. */
header.site nav#main-nav .nav-item[data-section-current="1"]:not(.nav-online) { font-weight: 800; color: var(--sb-ink); text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--sb-brand); text-underline-offset: 10px; }
header.site nav#main-nav .nav-online[data-section-current="1"] { border-color: var(--sb-ink); font-weight: 800; }
/* 상단 남색 띠 링크의 현재 표시가 옛 reference-shell.css 의 남색 글씨로 바뀌어 남색 위 남색(거의 안 보임)이 됐다 — 흰 글씨 + 밑줄로 */
.site-utility .site-utility-links a[aria-current="page"] { color: #fff; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
header.site nav#main-nav > a.nav-item:hover::before, header.site nav#main-nav .nav-group-toggle:hover::before,
header.site nav#main-nav .nav-group-toggle[aria-expanded="true"]::before { transform: scaleX(1); }
header.site nav#main-nav a.cta { height: 44px; margin-left: 8px; padding: 0 18px; border-radius: 999px; background: var(--sb-accent); color: var(--sb-accent-ink); font-weight: 800; }
header.site nav#main-nav a.cta::before { display: none; }
header.site nav#main-nav a.cta:hover { background: #ffcb0f; }
header.site nav#main-nav .nav-utility { display: inline-flex; align-items: center; min-height: 44px; margin-left: 8px; padding: 0 4px; font-size: 13px; font-weight: 400; color: var(--sb-ink-3); text-decoration: none; }
header.site nav#main-nav .nav-utility:hover { color: var(--sb-ink); background: none; }

/* 1140~1319px: 메뉴 12개가 한 줄에 들어가도록 한 단계 조밀하게 */
@media (min-width: 1140px) and (max-width: 1319px) {
  header.site .bar { gap: 12px; }
  header.site nav#main-nav > a.nav-item, header.site nav#main-nav .nav-group-toggle { padding: 0 6px; font-size: 15px; }   /* OD-27: 7→6 (온라인 캠퍼스 버튼 자리) */
  header.site nav#main-nav > a.nav-item::before, header.site nav#main-nav .nav-group-toggle::before { left: 6px; right: 6px; }
  header.site nav#main-nav a.cta { margin-left: 4px; padding: 0 14px; }
  header.site .logo-txt small { display: none; }
}

/* 작은 드롭다운 (커뮤니티·학원안내) */
header.site .nav-group { position: relative; display: flex; }
header.site .nav-group-panel[hidden] { display: none; }
header.site .nav-group-panel {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%); z-index: 60;
  display: grid; gap: 0; min-width: 200px; max-width: min(280px, calc(100vw - 24px)); padding: 8px;
  background: #fff; border: 1px solid var(--sb-line); border-top: 0; border-radius: 0 0 var(--sb-r) var(--sb-r); box-shadow: var(--sb-shadow);
}
header.site nav#main-nav .nav-group-panel a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: var(--sb-r-sm); font-size: 15px; font-weight: 400; color: var(--sb-ink-2); white-space: normal; text-decoration: none; }
header.site nav#main-nav .nav-group-panel a:hover { background: var(--sb-bg-2); color: var(--sb-ink); }

/* 분야 메가메뉴 */
header.site .nav-group--family { position: static; }
header.site .nav-group-panel.nav-mega {
  /* 전체 폭 패널: nav-menu.js의 화면 밖 보정(인라인 left/right)이 적용되지 않게 고정한다 */
  position: absolute; left: 0 !important; right: 0 !important; top: 100%; transform: none; max-width: none; min-width: 0; padding: 0;
  border: 0; border-top: 1px solid var(--sb-line); border-radius: 0; box-shadow: 0 8px 12px rgba(17, 19, 24, .08);
}
.fam-mega { max-width: calc(var(--sb-wrap) + var(--sb-gutter) * 2); margin: 0 auto; padding: 40px var(--sb-gutter) 48px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 320px; gap: 48px; }
.fam-mega-h { margin: 0 0 12px; padding-bottom: 12px; border-bottom: 1px solid var(--sb-line); font-size: 16px; font-weight: 700; color: var(--sb-ink); }
.fam-mega-list { margin: 0; padding: 0; list-style: none; }
header.site nav#main-nav .fam-mega-list a { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; padding: 4px 0; border-radius: 0; font-size: 15px; color: var(--sb-ink-2); background: none; }
header.site nav#main-nav .fam-mega-list a:hover { color: var(--sb-brand); background: none; }
header.site nav#main-nav .fam-mega-list a.is-closed { color: var(--sb-ink-4); }
.fam-mega-empty { margin: 0; font-size: 14px; color: var(--sb-ink-3); }
header.site nav#main-nav a.fam-mega-card { position: relative; display: block; min-height: 0; padding: 0; border-radius: var(--sb-r); overflow: hidden; background: var(--sb-brand-deep); color: #fff; aspect-ratio: 4 / 3; }
.fam-mega-media, .fam-mega-media > * { position: absolute; inset: 0; width: 100%; height: 100%; }
.fam-mega-media img { width: 100%; height: 100%; object-fit: cover; }
.fam-mega-cap { position: absolute; left: 12px; right: 12px; bottom: 12px; z-index: 1; display: grid; gap: 4px; padding: 14px 16px; border-radius: 8px; background: rgba(12, 14, 19, .82); }
.fam-mega-cap strong { font-size: 17px; font-weight: 800; }
.fam-mega-cap span { font-size: 13px; line-height: 1.5; color: #e4e7ec; }
.fam-mega-cap .fam-mega-all { display: inline-flex; align-items: center; gap: 2px; margin-top: 4px; font-weight: 700; color: var(--sb-accent); }
.fam-mega-card--text .fam-mega-cap { position: static; margin: 0; height: 100%; border-radius: 0; background: none; align-content: end; padding: 20px; }

/* 햄버거는 좁은 화면 전용 */
header.site .nav-toggle { display: none; }
header.site nav#main-nav .nav-utility { white-space: nowrap; }

/* 도구 아이콘 */
header.site .site-tools { display: flex; align-items: center; gap: 4px; flex: 0 0 auto; }
header.site .site-tool { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--sb-ink); text-decoration: none; }
header.site .site-tool:hover { background: var(--sb-bg-2); }

/* 서랍 전용 목록(site-shell.js enrichDrawer)은 넓은 화면에서 숨긴다 */
header.site .drawer-families { display: none; }

/* ── 1140px 미만: 햄버거 서랍 ─────────────────────────────────── */
@media (max-width: 1139px) {
  :root { --sb-header-h: 64px; }
  header.site .bar { gap: 8px; }
  header.site .logo { margin-right: auto; }
  header.site .nav-toggle { display: inline-flex !important; order: 3; width: 44px; height: 44px; border: 0; background: none; border-radius: 50%; align-items: center; justify-content: center; }
  /* 메뉴(≡) 아이콘 — 새 홈은 style.css 를 불러오지 않으므로 공통 셸이 직접 그린다(스테이징 점검에서 홈 휴대폰 화면에 아이콘이 안 보였음). */
  header.site .nav-toggle .bars { position: relative; display: block; width: 20px; height: 2px; border-radius: 1px; background: var(--sb-ink, #16181d); }
  header.site .nav-toggle .bars::before, header.site .nav-toggle .bars::after { content: ''; position: absolute; left: 0; width: 20px; height: 2px; border-radius: 1px; background: var(--sb-ink, #16181d); }
  header.site .nav-toggle .bars::before { top: -6px; }
  header.site .nav-toggle .bars::after { top: 6px; }
  header.site .site-tools { order: 2; }
  header.site nav#main-nav:not(.open) { display: none !important; }
  header.site nav#main-nav.open {
    display: flex !important; position: absolute; top: 100%; left: 0; right: 0; z-index: 60;
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--sb-gutter) 24px;
    max-height: calc(100vh - var(--sb-header-h)); overflow-y: auto; overscroll-behavior: contain;
    background: #fff; border-bottom: 1px solid var(--sb-line); box-shadow: var(--sb-shadow);
  }
  header.site nav#main-nav > a.nav-item, header.site nav#main-nav .nav-group-toggle { height: auto; min-height: 52px; padding: 0 4px; font-size: 16px; font-weight: 700; border-bottom: 1px solid var(--sb-line-2); justify-content: space-between; width: 100%; }
  header.site nav#main-nav > a.nav-item::before, header.site nav#main-nav .nav-group-toggle::before { display: none; }
  header.site nav#main-nav .nav-group-toggle::after { display: block; content: ''; width: 7px; height: 7px; border: 0; border-right: 1.8px solid var(--sb-ink-3); border-bottom: 1.8px solid var(--sb-ink-3); transform: rotate(45deg); }
  header.site nav#main-nav .nav-group-toggle[aria-expanded="true"]::after { transform: rotate(-135deg); }
  header.site .nav-group { display: block; }
  /* 분야는 서랍 전용 목록(과정까지 펼쳐지는 details)이 대신 보여준다 */
  header.site .nav-group--family { display: none; }
  header.site .nav-group-panel, header.site .nav-group-panel.nav-mega { position: static; transform: none; min-width: 0; max-width: none; margin: 0; padding: 4px 0 8px 12px; border: 0; box-shadow: none; border-radius: 0; }
  header.site nav#main-nav a.cta { width: 100%; margin: 16px 0 0; justify-content: center; }
  header.site nav#main-nav .nav-utility { margin: 8px 0 0; justify-content: center; }
  header.site .drawer-families { display: block; order: -1; }
  header.site .drawer-head { margin: 16px 0 4px; font-size: 12px; font-weight: 700; color: var(--sb-brand); }
  header.site .drawer-families ul { list-style: none; margin: 0; padding: 0; }
  header.site .drawer-families summary, header.site .drawer-families a { display: flex; align-items: center; justify-content: space-between; min-height: 48px; font-size: 16px; font-weight: 700; color: var(--sb-ink); text-decoration: none; border-bottom: 1px solid var(--sb-line-2); cursor: pointer; }
  header.site .drawer-families .drawer-courses a { font-weight: 400; font-size: 15px; color: var(--sb-ink-2); padding-left: 12px; }
  header.site .drawer-count { margin-left: 8px; font-size: 12px; color: var(--sb-ink-3); font-weight: 400; }
  header.site .drawer-links { display: none; }
  .site-utility .site-utility-brand { display: none; }
}
@media (max-width: 719px) {
  :root { --sb-gutter: 16px; }
  header.site .logo-mark { width: 34px; height: 34px; font-size: 14px; border-radius: 8px; }
  header.site .logo-txt strong { font-size: 17px; }
  header.site .logo-txt small { font-size: 11px; }
  .site-utility-links { gap: 0 14px; }
  .site-utility-links a { font-size: 12px; min-height: 44px; }
}

/* ── 퀵메뉴 (DOCK_ITEM, 넓은 화면): 화면 아래 가운데 알약 ─────── */
@media (min-width: 1140px) {
  .quick-dock {
    position: fixed; left: 50%; bottom: 24px; top: auto; right: auto; z-index: 40; transform: translateX(-50%);
    display: flex; flex-direction: row; align-items: center; gap: 4px; width: auto; padding: 8px 8px 8px 28px;
    border-radius: 999px; background: rgba(255, 255, 255, .96); border: 1px solid var(--sb-line); box-shadow: var(--sb-shadow);
  }
  .quick-dock::before { content: 'QUICK MENU'; margin-right: 12px; font: 800 12px/1 var(--sb-f); letter-spacing: .14em; color: var(--sb-ink); white-space: nowrap; }
  .quick-dock .quick-dock-item, .quick-dock .quick-dock-toggle {
    display: inline-flex; flex-direction: row; align-items: center; gap: 6px; height: 44px; width: auto; padding: 0 16px;
    border: 1px solid var(--sb-line); border-radius: 999px; background: #fff; color: var(--sb-ink-2);
    font: 400 14px/1 var(--sb-f); white-space: nowrap; text-decoration: none; cursor: pointer;
  }
  .quick-dock .quick-dock-item svg, .quick-dock .quick-dock-toggle svg { width: 18px; height: 18px; }
  .quick-dock .quick-dock-item:hover, .quick-dock .quick-dock-toggle:hover { border-color: var(--sb-ink-3); color: var(--sb-ink); }
  .quick-dock .quick-dock-item--primary { order: 10; height: 48px; margin-left: 8px; padding: 0 24px; border: 0; background: var(--sb-accent); color: var(--sb-accent-ink); font-weight: 800; font-size: 15px; }
  .quick-dock .quick-dock-item--primary:hover { background: #ffcb0f; color: var(--sb-accent-ink); }
  .quick-dock .quick-dock-sep { display: none; }
  .quick-dock #quick-dock-top { display: none; }
  .quick-dock .quick-dock-more { position: relative; }
  .quick-dock .quick-dock-panel { position: absolute; bottom: calc(100% + 12px); left: 50%; transform: translateX(-50%); top: auto; right: auto; display: grid; min-width: 160px; padding: 8px; background: #fff; border: 1px solid var(--sb-line); border-radius: var(--sb-r); box-shadow: var(--sb-shadow); }
  .quick-dock .quick-dock-panel[hidden] { display: none; }
  .quick-dock .quick-dock-panel a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: var(--sb-r-sm); font-size: 14px; color: var(--sb-ink-2); text-decoration: none; }
  .quick-dock .quick-dock-panel a:hover { background: var(--sb-bg-2); }
  .mobile-sticky { display: none !important; }
  /* 아래로 읽는 동안: 오른쪽 아래 작은 묶음(상담 + 빠른 메뉴), 위로 올리면 가운데 바로 다시 펼침(quick-dock.js data-compact).
     본문을 가리던 폭 약 640px → 약 250px. 맨 위로 버튼은 그 위(bottom 96px)에 그대로. */
  /* 위치 이동은 애니메이션 없이 바로 바꾼다 — left 는 auto 에서 전환되지 않아 이동 중간에 한쪽으로 치우쳐 멈춰 보였다(실측). */
  /* 하위 페이지는 옛 style.css 의 .quick-dock[data-visible="true"] { transform: translateY(-50%) translateX(0) } 가 이겨
     바가 화면 가운데가 아니라 가운데 선에서 오른쪽으로 치우쳐 있었다(2026-10-03 실측, 홈은 style.css 를 안 불러 정상). 같은 세기로 되돌린다. */
  .quick-dock[data-visible] { transform: translateX(-50%); }
  .quick-dock[data-visible][data-compact="true"] { left: auto; right: 24px; transform: none; padding: 6px; gap: 6px; }
  .quick-dock[data-compact="true"]::before { display: none; }
  .quick-dock[data-compact="true"] .quick-dock-item:not(.quick-dock-item--primary) { display: none; }
  .quick-dock[data-compact="true"] .quick-dock-item--primary { margin-left: 0; }
  .quick-dock[data-compact="true"] .quick-dock-more .quick-dock-panel { left: auto; right: 0; transform: none; }
}
@media (max-width: 1139px) {
  .quick-dock { display: none !important; }
}

/* 맨 위로 */
.quick-top { position: fixed; right: 24px; bottom: 96px; z-index: 39; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--sb-line); background: #fff; color: var(--sb-ink); display: grid; place-items: center; box-shadow: var(--sb-shadow); cursor: pointer; }
.quick-top[data-visible="false"] { opacity: 0; pointer-events: none; }
@media (max-width: 1139px) { .quick-top { right: 16px; bottom: 88px; } }

/* ── 모바일 하단바 (DOCK_ITEM, 좁은 화면) ─────────────────────── */
@media (max-width: 1139px) {
  .mobile-sticky {
    display: flex !important; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; gap: 8px;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--sb-line);
  }
  .mobile-sticky a { flex: 1; display: flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 12px; border-radius: 999px; font: 800 16px/1 var(--sb-f); text-decoration: none; }
  .mobile-sticky a.primary { background: var(--sb-accent); color: var(--sb-accent-ink); }
  .mobile-sticky a.secondary { background: #fff; color: var(--sb-ink); border: 1px solid var(--sb-line); }
  body { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
}

/* ── 푸터 ───────────────────────────────────────────────────────── */
footer.site { background: #0b0d11; color: #9aa1ad; padding: 56px 0 112px; border: 0; }
footer.site .wrap { max-width: calc(var(--sb-wrap) + var(--sb-gutter) * 2); margin: 0 auto; padding: 0 var(--sb-gutter); }
footer.site, footer.site div { font-size: 13px !important; line-height: 1.8 !important; color: #9aa1ad !important; }
footer.site b { color: #e4e7ec; }
footer.site .foot-social { display: flex; flex-wrap: wrap; gap: 8px !important; margin: 16px 0 !important; }
footer.site .foot-social a { display: inline-flex; align-items: center; height: 44px; padding: 0 16px; border: 1px solid #2a2f38; border-radius: 999px; color: #c4c9d2; text-decoration: none; font-size: 12px; }
footer.site .foot-social a:hover { border-color: #6d7480; color: #fff; }
footer.site a { color: #c4c9d2 !important; }
footer.site a[href*="privacy"] { display: inline-flex; align-items: center; min-height: 44px; }

/* ── 상담 레일 (하위 페이지 [data-shell-rail]) ─────────────────── */
.rail-card { font-family: var(--sb-f); border: 1px solid var(--sb-line); border-radius: var(--sb-r); padding: 24px; background: #fff; box-shadow: none; }
.rail-title { margin: 0 0 12px; font-size: 18px; font-weight: 700; color: var(--sb-ink); }
.rail-phones { list-style: none; margin: 0 0 16px; padding: 0; border-top: 1px solid var(--sb-line); }
.rail-phones li { display: flex; justify-content: space-between; align-items: center; min-height: 44px; border-bottom: 1px solid var(--sb-line-2); font-size: 14px; }
.rail-campus { color: var(--sb-ink-2); }
.rail-phone { font-weight: 800; color: var(--sb-ink); font-variant-numeric: tabular-nums; text-decoration: none; }
.rail-actions { display: grid; gap: 8px; }
.rail-btn { display: flex; align-items: center; justify-content: center; min-height: 48px; border-radius: 999px; border: 1px solid var(--sb-line); color: var(--sb-ink); font-weight: 700; text-decoration: none; }
.rail-btn--primary { background: var(--sb-accent); border-color: var(--sb-accent); color: var(--sb-accent-ink); }
.rail-links { list-style: none; margin: 12px 0 0; padding: 0; }
.rail-links a { display: flex; align-items: center; min-height: 44px; font-size: 14px; color: var(--sb-ink-2); text-decoration: none; border-bottom: 1px solid var(--sb-line-2); }

@media (prefers-reduced-motion: reduce) {
  header.site *, .quick-dock * { transition-duration: 0s !important; }
}

/* OD-15: 분야 메뉴 사진 자리의 기본 바탕 — 파란 회색 그라데이션(AI 패턴 X-4) 대신 단색 */
.ms-frame { background: var(--sb-bg-2) !important; }
/* OD-27 18번 — 머리말 "온라인 캠퍼스"를 따로 눈에 띄는 버튼으로(예전 "내 강의실" 작은 글자 자리) */
header.site nav#main-nav .nav-utility.nav-online { padding: 0 14px; min-height: 44px; border: 1px solid var(--sb-line); border-radius: 999px; font-size: 13px; font-weight: 700; color: var(--sb-ink); }
header.site nav#main-nav .nav-utility.nav-online:hover { border-color: var(--sb-ink); }
/* OD-27: 1320~1519px 는 온라인 캠퍼스 버튼이 들어오며 로고·아이콘과 겹쳤다(실측 10px) — 메뉴 여백 9→7, 버튼 여백 14→10 */
@media (min-width: 1320px) and (max-width: 1519px) {
  header.site nav#main-nav > a.nav-item:not(.cta), header.site nav#main-nav .nav-group-toggle { padding: 0 6px; }   /* 상담(.cta)은 제외 — 제 여백 유지 · 글꼴이 달라도 여유(Codex PR #50) */
  header.site nav#main-nav > a.nav-item::before, header.site nav#main-nav .nav-group-toggle::before { left: 6px; right: 6px; }
}
@media (max-width: 1519px) { header.site nav#main-nav .nav-utility.nav-online { padding: 0 10px; } }
@media (min-width: 1140px) and (max-width: 1199px) {
  header.site nav#main-nav > a.nav-item:not(.cta), header.site nav#main-nav .nav-group-toggle { padding: 0 4px; font-size: 14px; }   /* Codex PR #50: 리눅스 글꼴에서 6px — 여유 확보(글자 15→14) */
  header.site nav#main-nav > a.nav-item::before, header.site nav#main-nav .nav-group-toggle::before { left: 4px; right: 4px; }
  header.site nav#main-nav .nav-utility.nav-online { padding: 0 8px; }
}
/* OD-27: 메뉴가 빠듯해도 상담·온라인 캠퍼스 버튼은 줄어들지 않는다(홈 화면 게이트 G2 — 1440px 상담 43px 실측) */
header.site nav#main-nav a.cta, header.site nav#main-nav .nav-utility.nav-online { flex-shrink: 0; }

/* ── 모션(2026-10-04): 더메인 허브와 같은 원리(라이브러리 없음). transform·opacity 만, 움직임 줄이기면 전부 끔 ── */
@media (prefers-reduced-motion: no-preference) {
  .m-reveal { transition: opacity .6s cubic-bezier(.2,.7,.2,1), transform .6s cubic-bezier(.2,.7,.2,1); }
  .m-reveal.m-hide { opacity: 0; transform: translateY(20px); }
  .m-reveal .m-item { transition: opacity .5s cubic-bezier(.2,.7,.2,1), transform .5s cubic-bezier(.2,.7,.2,1); transition-delay: calc(var(--m-i, 0) * 60ms + 120ms); }
  .m-reveal.m-hide .m-item { opacity: 0; transform: translateY(14px); }
  /* 첫 화면 등장: 분야·자격·캠퍼스 머리 — 글은 차례로 올라오고 사진은 살짝 커졌다 제자리 */
  @keyframes m-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
  @keyframes m-photo { from { opacity: 0; transform: scale(1.035); } to { opacity: 1; transform: none; } }
  body:not(.hp) .lp-hero .cx-hero-copy > *, body:not(.hp) #campus-detail-root .campus-hero-main > * { animation: m-up .6s cubic-bezier(.2,.7,.2,1) both; }
  body:not(.hp) .lp-hero .cx-hero-copy > :nth-child(2), body:not(.hp) #campus-detail-root .campus-hero-main > :nth-child(2) { animation-delay: .06s; }
  body:not(.hp) .lp-hero .cx-hero-copy > :nth-child(3), body:not(.hp) #campus-detail-root .campus-hero-main > :nth-child(3) { animation-delay: .12s; }
  body:not(.hp) .lp-hero .cx-hero-copy > :nth-child(4), body:not(.hp) #campus-detail-root .campus-hero-main > :nth-child(4) { animation-delay: .18s; }
  body:not(.hp) .lp-hero .cx-hero-copy > :nth-child(n+5) { animation-delay: .24s; }
  body:not(.hp) .lp-hero-photo img, body:not(.hp) #campus-detail-root .campus-gallery .campus-lead img { animation: m-photo .9s cubic-bezier(.2,.7,.2,1) both; }
}
@media print { .m-reveal.m-hide, .m-reveal.m-hide .m-item { opacity: 1 !important; transform: none !important; } }

/* 2026-10-04 원장 "http://www.theplanart.co.kr/ 이게 기존 로고야" → 머리말 "TP" 이니셜 대신 기존 공식 로고(theplanart.co.kr/img/logo.png, 342×80 투명, 무손실 WebP 로 바꿈).
   CSS 배경으로 넣어 어느 깊이의 쪽(/courses/it/ 등)에서도 같은 파일(../images/…)을 쓴다. 40px 높이 = 원본의 2배 밀도. */
header.site .logo-img { display: block; width: 171px; height: 40px; background: url("../images/brand/theplan-logo.webp") left center / contain no-repeat; }
@media (max-width: 1023px) { header.site .logo-img { width: 137px; height: 32px; } }
