/* ─────────────────────────────────────────────────────────────
   문서 페이지 — 정책 4종 · 고객문의

   상단바(공용 네비) → 가운데 본문 → 푸터 밴드
   네비 스타일은 site_nav.css 가 소유합니다. doc_base.html 이 둘을 함께 읽습니다.
   ───────────────────────────────────────────────────────────── */

.doc-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse at 50% -10%, var(--bg-glow-soft), transparent 55%),
    var(--bg);
}

.doc {
  flex: 1;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 52px) clamp(18px, 4vw, 40px) 80px;
}

/* 고객문의는 카드가 넓어 본문 폭이 조금 큽니다. */
.doc--wide { max-width: 860px; }

/* 현재 보고 있는 메뉴 표시 */
.lp-nav-link.is-active {
  color: var(--text);
  font-weight: 700;
}

/* ── 되돌아가기 링크 ── */
.doc-back {
  display: inline-block;
  margin-bottom: 22px;
  font-size: 13.5px;
  color: var(--accent);
  text-decoration: none;
}

.doc-back:hover { color: var(--accent-hover); }

/* ── 문서 머리말 ── */
.doc-head {
  border-bottom: 1px solid var(--border);
  padding-bottom: 24px;
  margin-bottom: 34px;
}

.doc-eyebrow {
  margin-bottom: 12px;
  font-size: 12px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--accent);
}

.doc-title {
  margin: 0 0 10px;
  font: 600 clamp(28px, 5vw, 36px) var(--font-serif);
  letter-spacing: -.5px;
  color: var(--text);
}

.doc-updated {
  margin: 0;
  font-size: 13px;
  color: var(--text-faint);
}

/* ── 본문 ── */

/* 아래 두 규칙은 `.doc p` 보다 구체적이어야 여백이 먹습니다. */

/* 머리말과 첫 조항 사이의 총론 문단(개인정보처리방침). */
.doc p.doc-intro { margin-bottom: 34px; }

/* 조항 끝에 붙는 연락처 블록. */
.doc p.doc-contact { margin-top: 10px; }

/* 앞 목록과 한 칸 띄우는 보충 설명. */
.doc p.doc-note { margin-top: 12px; }

.doc-section { margin-bottom: 40px; }
.doc-section:last-child { margin-bottom: 0; }

.doc-h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
  font: 600 20px var(--font-serif);
  color: var(--text);
}

/* 번호 배지 */
.doc-num {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 14px var(--font-sans);
}

.doc-h3 {
  margin: 18px 0 6px;
  font: 700 15px var(--font-sans);
  color: var(--accent);
}

.doc p {
  margin: 0 0 4px;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--text-body);
}

.doc ul {
  margin: 8px 0 0;
  padding-left: 22px;
}

.doc p + ul { margin-top: 4px; }

.doc li {
  margin-bottom: 6px;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--text-body);
}

.doc p.doc-strong {
  margin-top: 12px;
  font-weight: 700;
  color: var(--text);
}

/* 이용약관은 번호 배지 대신 "제N조 [제목]" 꼴을 씁니다. */
.doc-h2--article {
  display: block;
  margin-bottom: 12px;
  font-size: 19px;
}

.doc-article-name { color: var(--accent); }

.doc ol {
  margin: 8px 0 0;
  padding-left: 22px;
}

.doc p + ol { margin-top: 4px; }

/* 조항 안에 다시 열거가 붙는 경우(예: 승낙 거절 사유). */
.doc li > ul,
.doc li > ol {
  margin: 6px 0 8px;
}

.doc li > ul > li {
  list-style: '– ';
  margin-bottom: 3px;
}

/* ── 표 (개인정보 수집 항목) ── */
.doc-table {
  margin-top: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.doc-table-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  font-size: 14px;
}

.doc-table-row + .doc-table-row { border-top: 1px solid var(--border); }

.doc-table-row > * { padding: 13px 16px; }

.doc-table-row > :first-child {
  border-right: 1px solid var(--border);
  font-weight: 700;
  color: var(--text);
}

.doc-table-row > :last-child { color: var(--text-body); }

.doc-table-row--head {
  background: var(--surface-muted);
  font-size: 13px;
}

.doc-table-row--head > * {
  padding: 12px 16px;
  font-weight: 700;
  color: var(--text-faint);
}

.doc-table-row--head > :last-child { color: var(--text-faint); }

/* 폭이 좁아지면 구분/항목을 위아래로 쌓습니다. */
@media (max-width: 520px) {
  .doc-table-row { grid-template-columns: 1fr; }
  .doc-table-row > :first-child {
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding-bottom: 6px;
  }
  .doc-table-row--head { display: none; }
}

/* ── 콜아웃 (예시·공식) ── */
.doc-callout {
  margin-top: 14px;
  padding: 14px 18px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
}

.doc-callout p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--text-muted);
}

.doc-formula {
  margin: 0 0 8px !important;
  font-size: 14.5px !important;
  font-weight: 700;
  color: var(--text) !important;
}

/* ── 선택지 A/B ── */
.doc-options {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 16px 0 4px;
}

.doc-option { display: flex; gap: 14px; }

.doc-option-mark {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface-muted);
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 13px var(--font-sans);
}

.doc-option h3 {
  margin: 0 0 4px;
  font: 700 15.5px var(--font-sans);
  color: var(--text);
}

.doc-option p {
  margin: 0;
  font-size: 14px;
  line-height: 1.9;
}

.doc a { color: var(--accent); }
.doc a:hover { color: var(--accent-hover); }

/* ─────────────────────────────────────────────────────────────
   고객문의
   ───────────────────────────────────────────────────────────── */
.faq-head {
  text-align: center;
  margin-bottom: 38px;
}

.faq-eyebrow {
  margin-bottom: 16px;
  font-size: 12px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
}

.faq-title {
  margin: 0 0 12px;
  font: 600 clamp(30px, 5vw, 40px) var(--font-serif);
  letter-spacing: -.5px;
  color: var(--text);
}

.faq-lede {
  margin: 0;
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-muted);
}

/* ── 분류 필터 ── */
.faq-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 32px;
}

.faq-filter {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--control-bg);
  color: var(--text-muted);
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s;
}

.faq-filter:hover { border-color: var(--accent); }

.faq-filter[aria-pressed='true'] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-on-solid);
}

/* ── 질문 목록 ── */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--control-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}

.faq-item[data-open='true'] {
  border-color: var(--accent);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--accent) 12%, transparent);
}

.faq-item[hidden] { display: none; }

.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 22px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
}

.faq-cat {
  flex: none;
  padding: 3px 10px;
  background: var(--surface-muted);
  color: var(--accent);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
}

.faq-q-text {
  flex: 1;
  font-size: 15.5px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.5;
}

.faq-sign {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface-muted);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 900;
  transition: transform .25s;
}

.faq-item[data-open='true'] .faq-sign { transform: rotate(45deg); }

.faq-a[hidden] { display: none; }

.faq-a {
  padding: 0 22px 22px;
  animation: doc-fade .25s;
}

.faq-a-inner {
  border-top: 1px solid var(--border);
  padding-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-a p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--text-body);
}

/* 답변 본문에 섞여 나오는 링크(원본: 굵게 + 밑줄). */
.faq-a-link {
  font-weight: 700;
  text-decoration: underline;
  color: var(--accent);
}

.faq-a-link:hover { color: var(--accent-hover); }

.faq-empty {
  text-align: center;
  margin: 40px 0;
  font-size: 14px;
  color: var(--text-faint);
}

.faq-empty[hidden] { display: none; }

/* ── 문의 채널 ── */
.faq-contact {
  margin-top: 44px;
  padding: clamp(28px, 5vw, 40px);
  border-radius: 20px;
  text-align: center;
  background: linear-gradient(135deg, var(--feature-bg), var(--feature-bg2));
  color: var(--feature-text);
}

.faq-contact h2 {
  margin: 0 0 8px;
  font: 600 22px var(--font-serif);
}

.faq-contact-lede {
  margin: 0 0 26px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--feature-muted);
}

.faq-channels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  text-align: left;
}

.faq-channel {
  padding: 20px 22px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  text-decoration: none;
  transition: all .2s;
}

.faq-channel:hover {
  background: rgba(255, 255, 255, .12);
  transform: translateY(-2px);
}

.faq-channel-name {
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
}

.faq-channel-desc {
  font-size: 13px;
  color: var(--feature-muted);
}

.faq-hours {
  margin: 24px 0 0;
  font-size: 12.5px;
  color: var(--feature-muted);
}

@keyframes doc-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .faq-a { animation: none; }
  .faq-sign { transition: none; }
  .faq-channel:hover { transform: none; }
}
