/* ============================================================
   DJ Bank 가이드(GEO 콘텐츠 블로그) — 공용 스타일시트
   토큰은 랜딩(deposit/loan) 페이지의 :root 값과 동일하게 맞춤(브랜드 일관성)
   ============================================================ */

:root {
  --brand-blue: #0046ff;
  --brand-blue-strong: #0038cc;
  --bg-soft: #f4f7fe;
  --title-ink: #191f28;
  --body-ink: #4e5968;
  --muted-ink: #8b95a1;
  --line: #e5e8ee;
  --line-soft: #eef0f4;
  --radius-lg: 22px;
  --radius-md: 16px;
  --shadow-sm: 0 1px 2px rgba(20, 33, 61, .06), 0 1px 3px rgba(20, 33, 61, .08);
  --shadow-md: 0 6px 20px rgba(20, 33, 61, .08);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg-soft); }
body {
  margin: 0;
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Apple SD Gothic Neo", "Malgun Gothic", "Segoe UI", sans-serif;
  color: var(--title-ink);
  background: #fff;
  line-height: 1.6;
  word-break: keep-all;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.wrap { max-width: 1080px; margin-inline: auto; padding-inline: 24px; }
.wrap-narrow { max-width: 720px; margin-inline: auto; padding-inline: 24px; }
/* 가이드 인덱스 전용 — 메인 홈(deposit) GNB(.dj-gnb-inner: 1496 + 좌우 32)와 동일한 고정 마진 */
.wrap-wide { max-width: 1496px; margin-inline: auto; padding-inline: 32px; }
@media (max-width: 760px) { .wrap-wide { padding-inline: 20px; } }

/* 공용 GNB(.dj-gnb)는 음수 margin-bottom으로 본문 위에 겹쳐 놓이는 글래스 헤더다.
   가이드 페이지 본문은 헤더 높이만큼 상단 여백을 확보해 첫 요소가 가려지지 않게 한다. */
body > main { padding-top: 68px; }
@media (max-width: 760px) { body > main { padding-top: 60px; } }

/* ---------- Header ---------- */
.gd-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255,255,255,.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.gd-header .inner {
  max-width: 1080px; margin-inline: auto; padding-inline: 24px;
  height: 64px; display: flex; align-items: center; justify-content: space-between;
}
.gd-header .logo { height: 22px; width: auto; }
.gd-header nav { display: flex; align-items: center; gap: 18px; font-size: 14px; font-weight: 600; color: var(--body-ink); }
.gd-header nav a:hover { color: var(--brand-blue); }
.gd-header .btn-cta {
  background: var(--brand-blue); color: #fff; padding: 9px 16px; border-radius: 999px;
  font-size: 13px; font-weight: 700;
}
.gd-header .btn-cta:hover { background: var(--brand-blue-strong); }

/* ---------- Breadcrumb ---------- */
.gd-crumb {
  font-size: 13px; color: var(--muted-ink); margin: 28px 0 0;
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
}
.gd-crumb a:hover { color: var(--brand-blue); }
.gd-crumb .sep { opacity: .5; }

/* ---------- Index hero (좌측 정렬 대형 타이틀 + 카테고리 탭) ---------- */
.gd-hero { padding: 72px 0 0; }
.gd-hero h1 {
  font-size: clamp(34px, 4.4444vw, 64px); /* 1440 기준 64px — 큰 화면에선 64px 고정 */
  font-weight: 700; line-height: 1.3; letter-spacing: -0.025em; margin: 0 0 16px;
  color: #000;
}
.gd-hero p {
  font-size: clamp(16px, 1.389vw, 20px); /* 1440 기준 20px */
  line-height: 1.5; color: var(--body-ink); margin: 0;
}
/* 모바일에서만 읽기 편한 폭으로 접는다 (PC는 한 줄로 이어짐) */
@media (max-width: 760px) { .gd-hero p { max-width: 34ch; } }
@media (max-width: 760px) { .gd-hero { padding-top: 48px; } }

/* ---------- Category tabs ---------- */
.gd-tabs {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px;
  margin: 56px 0 0; padding: 0 0 20px; border-bottom: 1px solid var(--line);
}
.gd-tab {
  appearance: none; background: none; border: 0; padding: 4px 0; cursor: pointer;
  font-family: inherit; font-size: 20px; font-weight: 500; color: var(--muted-ink);
  transition: color .15s ease;
}
.gd-tab:hover { color: var(--title-ink); }
.gd-tab[aria-selected="true"] { color: var(--title-ink); }
@media (max-width: 760px) {
  .gd-tabs { margin-top: 36px; gap: 10px 20px; padding-bottom: 16px; }
  .gd-tab { font-size: 18px; }
}

/* ---------- Card grid (3단 · 테두리 없는 플랫 카드) ---------- */
.gd-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 48px 40px; margin: 48px 0 96px;
}
@media (max-width: 1199px) { .gd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 44px 32px; } }
@media (max-width: 719px)  { .gd-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; margin: 32px 0 72px; } }

.gd-card {
  display: flex; flex-direction: column;
  background: none; border: 0; border-radius: 0; box-shadow: none;
}
.gd-card[hidden] { display: none; }

.gd-thumb {
  width: 100%; aspect-ratio: 16 / 10;
  display: flex; align-items: center; justify-content: center;
  font-size: clamp(40px, 3.6vw, 52px); color: #fff;
  position: relative; overflow: hidden;
  border-radius: 28px; margin-bottom: 24px;
}
@media (max-width: 760px) { .gd-thumb { border-radius: 20px; margin-bottom: 18px; } }
.gd-thumb::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 140% at 100% 0%, rgba(255,255,255,.22), transparent 60%);
}
/* 실사 썸네일이 들어간 카드 — 이미지가 영역을 채우고, 그라데이션 오버레이는 걷어낸다.
   배경 그라데이션(t-*)은 이미지 로드 전 플레이스홀더로 그대로 둔다. */
.gd-thumb img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.gd-thumb.has-img::after { display: none; }
.gd-thumb.t-deposit { background: linear-gradient(135deg, #0046ff, #3a6bff); }
.gd-thumb.t-loan { background: linear-gradient(135deg, #16225c, #0046ff); }
.gd-thumb.t-howto { background: linear-gradient(135deg, #00aaff, #0046ff); }
.gd-thumb.t-calc { background: linear-gradient(135deg, #0038cc, #00aaff); }
.gd-thumb.t-guide { background: linear-gradient(135deg, #191f28, #3a6bff); }

@media (hover: hover) and (pointer: fine) {
  .gd-thumb { transition: transform .5s ease; }
  .gd-card:hover .gd-thumb { transform: scale(1.05); }
  .gd-card:hover h3 { color: var(--brand-blue); }
}

.gd-card-body { display: flex; flex-direction: column; flex: 1; padding: 0 20px; }
/* 모바일은 카드 폭이 좁아 들여쓰기를 절반 이하로 줄인다 */
@media (max-width: 760px) { .gd-card-body { padding: 0 10px; } }
.gd-card-tag {
  align-self: flex-start; font-size: 12px; font-weight: 500; line-height: 16px;
  color: #374151; background: #f3f4f6;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 12px;
}
.gd-card h3 {
  font-size: 20px; font-weight: 700; line-height: 1.5; color: #17191E;
  margin: 0 0 8px; transition: color .15s ease;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.gd-card p {
  font-size: 16px; font-weight: 400; line-height: 1.4; color: #4e5968;
  margin: 0; flex: 1;
}
/* ---------- Article shell ---------- */
.gd-article-head { padding: 36px 0 8px; }
.gd-article-tag {
  display: inline-block; font-size: 13px; font-weight: 500; line-height: 16px;
  color: #374151; background: #f3f4f6;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 16px;
}
/* 아티클 헤더 썸네일 — 목록 카드와 같은 16:10 비율 */
.gd-article-thumb {
  width: 100%; aspect-ratio: 16 / 10; overflow: hidden;
  border-radius: 16px; margin: 28px 0 0; background: var(--bg-soft);
}
.gd-article-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.gd-article-head h1 {
  font-size: clamp(24px, 4vw, 34px); font-weight: 700; line-height: 1.35; margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.gd-article-meta { margin: 0; font-size: 14px; line-height: 1.2; color: var(--muted-ink); display: flex; gap: 10px; flex-wrap: wrap; }
.gd-article-note { margin: 8px 0 0; font-size: 13px; line-height: 1.5; color: var(--muted-ink); }
.gd-lead {
  font-size: 17px; color: #424242; margin: 36px 0 0; padding: 26px 22px;
  background: var(--bg-soft); border-radius: var(--radius-md); line-height: 1.7;
}
.gd-lead strong { color: var(--title-ink); }

.gd-article-body { padding: 40px 0 20px; }
.gd-article-body h2 {
  font-size: 21px; font-weight: 700; margin: 48px 0 8px; letter-spacing: -0.01em;
}
.gd-article-body h2:first-child { margin-top: 0; }
.gd-article-body p { font-size: 17px; line-height: 1.7; color: #424242; margin: 0 0 16px; }

/* ---------- Comparison table ---------- */
.gd-table-wrap { overflow-x: auto; border-radius: var(--radius-md); border: 1px solid var(--line); margin: 24px 0; }
table.gd-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14.5px; }
table.gd-table caption { caption-side: top; text-align: right; padding: 12px 16px 0; font-size: 12px; color: var(--muted-ink); }
table.gd-table th, table.gd-table td { padding: 14px 16px; text-align: center; border-bottom: 1px solid var(--line-soft); }
table.gd-table thead th { background: var(--title-ink); color: #fff; font-weight: 500; border-bottom: none; }
table.gd-table thead th.hl { background: var(--brand-blue); }
table.gd-table tbody th { background: #f8f9fb; font-weight: 700; text-align: left; }
table.gd-table.center-head tbody th { text-align: center; }
table.gd-table td.hl { color: var(--brand-blue); font-weight: 700; background: #f5f8ff; }
table.gd-table tbody tr:last-child td, table.gd-table tbody tr:last-child th { border-bottom: none; }
.gd-td-note { display: block; font-size: 11.5px; font-weight: 500; opacity: .75; margin-top: 2px; }

/* ---------- Spec list ---------- */
.gd-spec { border: 1px solid var(--line); border-radius: var(--radius-md); overflow: hidden; background: #fff; margin: 24px 0; }
.gd-spec-row { display: grid; grid-template-columns: 1fr; gap: 4px; padding: 16px 18px; border-bottom: 1px solid var(--line-soft); }
.gd-spec-row:last-child { border-bottom: none; }
.gd-spec-row dt { font-weight: 700; color: var(--brand-blue); font-size: 13.5px; }
.gd-spec-row dd { margin: 0; color: var(--title-ink); font-size: 14.5px; font-weight: 500; }
.gd-spec-sub { display: block; font-size: 11.5px; color: var(--muted-ink); font-weight: 400; margin-top: 3px; }
.gd-spec-box { display: block; margin-top: 10px; padding: 12px 16px; border-radius: 12px; background: #f2f4f6; color: #363f4c; font-size: 13px; font-weight: 400; line-height: 1.7; }
@media (min-width: 560px) { .gd-spec-row { grid-template-columns: 150px 1fr; gap: 18px; align-items: baseline; } }

/* ---------- Calc scenario table ---------- */
table.gd-calc { width: 100%; border-collapse: collapse; font-size: 14.5px; margin: 24px 0; }
table.gd-calc th, table.gd-calc td { padding: 12px 14px; text-align: center; border-bottom: 1px solid var(--line-soft); }
table.gd-calc thead th { background: var(--bg-soft); font-weight: 700; color: var(--title-ink); }
table.gd-calc td.hl { color: var(--brand-blue); font-weight: 700; }

/* ---------- Callout / diff box ---------- */
.gd-callout { background: var(--bg-soft); border-radius: var(--radius-md); padding: 22px 24px; margin: 24px 0; }
.gd-callout p { margin: 0; font-size: 15px; color: var(--title-ink); }
.gd-callout.warn { background: #fff7ec; }
.gd-callout.warn p { color: #7a5000; }

/* ---------- Product disclosure (준법: 상품안내장 수준 정보) ---------- */
.gd-product-box {
  margin: 56px 0 8px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: #fff; overflow: hidden;
}
.gd-product-head {
  background: var(--bg-soft); padding: 20px 24px; border-bottom: 1px solid var(--line);
}
.gd-product-head .pname { font-size: 17px; font-weight: 700; margin: 0; color: #252525; }
.gd-product-head .pissuer { font-size: 13px; color: var(--muted-ink); margin: 2px 0 0; }
.gd-product-body { padding: 8px 24px 22px; }
.gd-product-body .gd-spec { border: none; border-radius: 0; margin: 0; }
.gd-product-body .gd-spec-row { padding: 14px 0; }
.gd-rate-table { width: 100%; border-collapse: collapse; font-size: 13.5px; margin: 10px 0 4px; }
.gd-rate-table th, .gd-rate-table td { padding: 9px 10px; text-align: center; border-bottom: 1px solid var(--line-soft); }
.gd-rate-table thead th { background: #f8f9fb; font-weight: 700; font-size: 12.5px; }
.gd-rate-table tbody th { text-align: left; font-weight: 600; background: transparent; }
.gd-rate-table td.top { color: var(--brand-blue); font-weight: 700; }
.gd-legal {
  margin: 0; padding: 18px 24px 22px; background: #fafbfc; border-top: 1px solid var(--line);
}
.gd-legal li {
  position: relative; padding-left: 11px; font-size: 12px; line-height: 1.65;
  color: var(--muted-ink); list-style: none;
}
.gd-legal li + li { margin-top: 5px; }
.gd-legal li::before { content: "·"; position: absolute; left: 2px; }
.gd-legal ul { margin: 0; padding: 0; }
/* 예금자보호 표시(준법 필수) — 예보 로고와 법정 문구를 한 줄로 묶어 유의사항 목록 위에 둔다.
   로고는 예보 공식 배포본(kdic.or.kr 'PROTECT_LOGO.zip' > 2-1. 보호금융상품.png, 400×259).
   예보 사용규정상 비율 변형·테두리·그림자·유사색 배경이 금지라 비율을 유지한 채 크기만 줄인다. */
.gd-kdic {
  display: flex; align-items: center; gap: 14px;
  margin: 0 0 14px; padding: 0 0 14px; border-bottom: 1px solid var(--line-soft);
}
.gd-kdic img { height: 48px; width: auto; flex-shrink: 0; }
.gd-legal .gd-kdic p { margin: 0; font-size: 12px; line-height: 1.65; color: var(--body-ink); }
/* 준법감시인 심의필 번호 — 유의사항 박스 맨 아래 (본문 p 스타일보다 특정도를 높여 덮어쓴다) */
.gd-legal p.gd-approval { margin: 14px 0 0; font-size: 11.5px; line-height: 1.6; color: var(--muted-ink); }

/* ---------- FAQ accordion ---------- */
h2.gd-faq-heading { font-size: 21px; font-weight: 700; margin: 56px 0 20px; }
.gd-accordion { display: grid; gap: 10px; }
.gd-acc-item { border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; }
.gd-acc-item summary {
  list-style: none; cursor: pointer; padding: 18px 20px; font-size: 15.5px; font-weight: 500;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.gd-acc-item summary::-webkit-details-marker { display: none; }
.gd-acc-item summary::after { content: "+"; font-size: 20px; color: var(--brand-blue); flex-shrink: 0; transition: transform .2s ease; }
.gd-acc-item[open] summary::after { transform: rotate(45deg); }
.gd-acc-body { padding: 0 20px 20px; font-size: 14.5px; line-height: 1.7; color: #424242; }

/* ---------- Product CTA card ---------- */
.gd-cta-card {
  margin: 56px 0 8px; border-radius: 16px; overflow: hidden;
  background: linear-gradient(135deg, var(--title-ink), var(--brand-blue));
  color: #fff; padding: 32px 28px; display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between; gap: 18px 24px;
}
.gd-cta-card h3 { font-size: 19px; font-weight: 600; margin: 0; }
.gd-cta-card p { margin: 0; font-size: 14px; color: rgba(255,255,255,.82); }
.gd-cta-card .btn {
  flex-shrink: 0; background: #fff; color: var(--brand-blue); font-weight: 700;
  padding: 8px 32px; border-radius: 999px; font-size: 15px;
}
.gd-cta-card .btn:hover { background: #eef3ff; }

/* ---------- Related articles ---------- */
.gd-related { margin: 80px 0 80px; }
.gd-related h3 { font-size: 16px; font-weight: 600; line-height: 1.35; margin: 0 0 24px; }
.gd-related-list { display: grid; gap: 28px 24px; }
@media (min-width: 640px) { .gd-related-list { grid-template-columns: 1fr 1fr; } }

/* 썸네일 + 타이틀 카드 */
.gd-related-item { display: block; }
.gd-related-thumb {
  display: block; width: 100%; aspect-ratio: 16 / 10;
  overflow: hidden; border-radius: 10px; margin-bottom: 16px;
  background: var(--bg-soft);
}
.gd-related-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gd-related-title {
  display: block; font-size: 18px; font-weight: 700; line-height: 1.5; color: #15171A;
  transition: color .15s ease;
}
@media (hover: hover) and (pointer: fine) {
  .gd-related-thumb img { transition: transform .5s ease; }
  .gd-related-item:hover .gd-related-thumb img { transform: scale(1.05); }
  .gd-related-item:hover .gd-related-title { color: var(--brand-blue); }
}

/* 관련글 섹션이 없는 아티클은 CTA 배너와 출처 구분선이 붙어 보인다.
   관련글이 있을 때의 간격(80px)과 맞춘다. */
.gd-cta-card + p.gd-source-note { margin-top: 80px; }

p.gd-source-note {
  margin-top: 0; font-size: 17px; color: #424242; line-height: 1.7;
  border-top: 1px solid var(--line); padding-top: 20px;
}

/* ============================================================
   아티클 모바일 최적화 (≤760px)
   본문 크기·여백을 좁은 화면에 맞춰 줄이고, 터치 타깃을 키운다.
   ============================================================ */
@media (max-width: 760px) {
  .wrap-narrow { padding-inline: 20px; }

  /* 머리말 */
  .gd-crumb { margin-top: 20px; font-size: 12.5px; }
  .gd-article-head { padding: 26px 0 4px; }
  .gd-article-thumb { border-radius: 12px; margin-top: 22px; }
  .gd-article-head h1 { line-height: 1.35; letter-spacing: -0.02em; }
  .gd-article-meta { font-size: 13.5px; }
  .gd-lead { font-size: 16px; line-height: 1.65; padding: 22px 18px; margin-top: 28px; }

  /* 본문 */
  .gd-article-body { padding: 32px 0 0; }
  .gd-article-body h2 { font-size: 19px; margin: 36px 0 8px; }
  .gd-article-body p { font-size: 16px; }

  /* 표 — 가로 스크롤은 유지하되 글자와 칸을 줄여 스크롤 양을 줄인다 */
  table.gd-table { font-size: 13.5px; min-width: 480px; }
  table.gd-table th, table.gd-table td { padding: 11px 12px; }
  table.gd-calc { font-size: 13.5px; }
  table.gd-calc th, table.gd-calc td { padding: 10px 8px; }

  /* 스펙 목록 */
  .gd-spec-row { padding: 14px 16px; }
  .gd-callout { padding: 18px 18px; }
  .gd-callout p { font-size: 14.5px; }

  /* 상품안내 박스 */
  .gd-product-box { margin-top: 44px; }
  .gd-product-head { padding: 18px; }
  .gd-product-head .pname { font-size: 16px; }
  .gd-product-body { padding: 6px 18px 18px; }
  .gd-rate-table { font-size: 12.5px; }
  .gd-rate-table th, .gd-rate-table td { padding: 8px 6px; }
  .gd-legal { padding: 16px 18px 18px; }

  /* FAQ */
  h2.gd-faq-heading { font-size: 19px; margin: 44px 0 20px; }
  .gd-acc-item summary { font-size: 15px; padding: 16px 18px; }
  .gd-acc-body { padding: 0 18px 18px; font-size: 14px; }

  /* 하단 CTA — 버튼을 가로 꽉 채워 터치 타깃 확보 */
  .gd-cta-card { margin: 44px 0 8px; padding: 36px 20px 24px; gap: 0; }
  .gd-cta-card > div { flex: 1 0 100%; text-align: center; }
  .gd-cta-card h3 { font-size: 17px; }
  .gd-cta-card p { font-size: 13.5px; }
  .gd-cta-card .btn { flex: 1 0 100%; text-align: center; padding: 13px 24px; margin: 24px 0 9px; }
  .gd-cta-card + .gd-source-note { margin-top: 56px; }

  /* 관련글 · 출처 */
  /* 모바일에서는 본문과 구분되도록 미색 밴드를 화면 좌우까지 깐다 (wrap-narrow 여백 20px만큼 상쇄) */
  .gd-related {
    margin: 80px -20px 0; padding: 60px 20px 60px;
    background: #fafafa;
  }
  .gd-related-list { gap: 32px; }
  p.gd-source-note {
    margin: 0 -20px; padding: 20px 20px 100px;
    background: #fafafa; border-top: 0; position: relative;
  }
  p.gd-source-note::before {
    content: ""; position: absolute; top: 0; left: 20px; right: 20px;
    border-top: 1px solid var(--line);
  }
  /* 밴드가 푸터에 바로 닿도록 푸터 위 여백을 없앤다 (원본 .gd-footer보다 특정도 우위) */
  footer.gd-footer { margin-top: 0; }
}

/* ---------- Footer ---------- */
.gd-footer { border-top: 1px solid var(--line); margin-top: 60px; background: var(--bg-soft); }
.gd-footer .inner { max-width: 1080px; margin-inline: auto; padding: 32px 24px; font-size: 13px; color: var(--muted-ink); text-align: center; }
