/* content/site.config.mjs 의 theme 값으로 자동 생성된 색상 변수 */
:root {
  --navy: #0b2559;
  --primary: #1d4ed8;
  --primary-light: #e8efff;
  --accent: #38bdf8;
}

/* ==========================================================================
   대출 상담 랜딩 페이지 스타일
   ※ 포인트 색상(--navy, --primary, --primary-light, --accent)은
     content/site.config.mjs 의 theme 값으로 빌드할 때 이 파일 맨 위에 자동으로 붙습니다.
     색을 바꾸려면 이 파일이 아니라 설정 파일의 theme 를 고치세요.
   ========================================================================== */

:root {
  --ink: #0f172a;          /* 제목·본문 진한 글자 */
  --text: #334155;         /* 일반 본문 */
  --muted: #64748b;        /* 흰 배경 위 보조 글자 */
  --muted-strong: #55637a; /* 옅은 회색 배경 위 보조 글자 (명도 대비 확보용) */
  --line: #e2e8f0;
  --field-line: #7f8ca3;   /* 입력 칸 테두리 (흰 배경과 3:1 이상 대비) */
  --bg-soft: #f5f7fb;
  --surface: #f1f4f9;
  --danger: #b91c1c;
  --star: #f59e0b;
  --ring: rgba(29, 78, 216, 0.2);
  --shadow-card: 0 12px 32px rgba(15, 23, 42, 0.05);
  --shadow-banner: 0 16px 36px rgba(15, 23, 42, 0.12);
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, system-ui, Roboto,
    "Helvetica Neue", "Segoe UI", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
}

@supports (color: color-mix(in srgb, red 50%, blue)) {
  :root {
    --ring: color-mix(in srgb, var(--primary) 22%, transparent);
  }
}

/* ── 기본 ─────────────────────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: #fff;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

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

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.icon {
  flex: none;
  width: 24px;
  height: 24px;
}

.icon--sm {
  width: 18px;
  height: 18px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 50;
  padding: 12px 18px;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

/* ── 맨 위 표시줄: 상호·등록번호 (대출 광고 필수 표시. 화면 왼쪽 위, 고정되지 않고 함께 스크롤됩니다) ── */
.legal-bar {
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.legal-bar__inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 8px 20px;
  text-align: left;
  /* 가장 큰 글자(32px)의 1/3 이상이어야 하므로 13px 아래로 줄이지 않습니다 */
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink);
}

.legal-bar__inner strong {
  font-weight: 800;
}

@media (min-width: 1024px) {
  .legal-bar__inner {
    padding: 8px 40px;
  }
}

/* ── 전체 배치: 왼쪽(내용) / 오른쪽(신청 폼) ──────────────────────────────── */
.shell {
  background: var(--bg-soft);
}

.col-content {
  padding: 48px 20px;
  background: var(--bg-soft);
}

.col-content__inner {
  max-width: 720px;
  margin: 0 auto;
}

.col-form {
  padding: 48px 20px 72px;
  background: #fff;
  border-top: 1px solid var(--line);
  scroll-margin-top: 12px;
}

.form-panel {
  max-width: 640px;
  margin: 0 auto;
}

@media (min-width: 1024px) {
  .shell {
    background: linear-gradient(90deg, var(--bg-soft) 50%, #fff 50%);
  }

  .layout {
    /* 위 여백: 보통 72px, 화면 높이가 낮으면(노트북 등) 줄여서 신청 버튼까지 한 화면에 보이게 합니다.
       (맨 위 표시줄 높이 약 38px 만큼 덜어 냈습니다) */
    --col-top: clamp(14px, calc(16vh - 124px), 72px);
    display: grid;
    grid-template-columns: minmax(0, 45fr) minmax(0, 55fr);
    max-width: 1440px;
    margin: 0 auto;
  }

  .col-content {
    padding: var(--col-top) 40px 80px;
    border-right: 1px solid var(--line);
  }

  .col-content__inner {
    max-width: none;
  }

  .col-form {
    padding: var(--col-top) 40px 96px;
    border-top: 0;
  }

  .form-panel {
    position: sticky;
    /* --sticky-top 은 main.js 가 화면 높이에 맞춰 계산합니다 */
    top: var(--sticky-top, 72px);
    max-width: 600px;
  }
}

/* ── 맨 위(히어로) ────────────────────────────────────────────────────────── */
.hero__title {
  font-size: clamp(26px, 7.6vw, 32px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.35;
  color: var(--ink);
}

.hero__desc {
  margin-top: 14px;
  font-size: 16.8px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--muted-strong);
}

.hero-banners {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}

.hero-banners > :first-child {
  grid-column: 1 / -1;
}

@media (max-width: 419px) {
  .hero-banners {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ── 그래픽 배너 ──────────────────────────────────────────────────────────── */
.banner {
  position: relative;
  isolation: isolate;
  display: flex;
  overflow: hidden;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--navy) 0%, var(--primary) 135%);
  box-shadow: var(--shadow-banner);
  container-type: inline-size;
}

@supports (color: color-mix(in srgb, red 50%, blue)) {
  .banner {
    background: linear-gradient(
      135deg,
      var(--navy) 0%,
      color-mix(in srgb, var(--navy) 58%, var(--primary)) 55%,
      var(--primary) 128%
    );
  }
}

/* 오른쪽 아래의 부드러운 빛 */
.banner::after {
  content: "";
  position: absolute;
  z-index: 0;
  right: -22%;
  bottom: -58%;
  width: 78%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--accent), transparent);
  opacity: 0.26;
  pointer-events: none;
}

.banner__deco {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  color: var(--accent);
  pointer-events: none;
}

.banner__content {
  position: relative;
  z-index: 1;
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto 1fr auto;
  grid-template-areas:
    "tag art"
    "title art"
    "sub sub";
  padding: 26px 26px 24px;
}

.banner__tag {
  grid-area: tag;
  align-self: start;
  justify-self: start;
  padding: 5px 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: -0.01em;
}

.banner__title {
  grid-area: title;
  align-self: end;
  margin-top: 14px;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.035em;
  color: #fff;
}

.banner__sub {
  grid-area: sub;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.88);
}

.banner__art {
  grid-area: art;
  align-self: center;
  justify-self: end;
  width: 96px;
  margin-left: 12px;
}

.ill {
  width: 100%;
  height: auto;
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ill .ill-a {
  stroke: var(--accent);
}

.ill .ill-soft {
  fill: rgba(255, 255, 255, 0.12);
  stroke: none;
}

.ill .ill-dot {
  fill: var(--accent);
  stroke: none;
}

.ill .ill-mask {
  fill: var(--navy);
  stroke: none;
}

/* 큰 배너 (약 16:9) */
.banner--lg .banner__content {
  min-height: 240px;
}

/* 본문용 가로 배너 */
.banner--wide .banner__content {
  min-height: 190px;
}

/* 작은 배너 2장 */
.banner--sm .banner__content {
  grid-template-areas:
    "tag art"
    "title title"
    "sub sub";
  min-height: 172px;
  padding: 18px;
}

.banner--sm .banner__title {
  margin-top: 12px;
  font-size: 19px;
}

.banner--sm .banner__sub {
  margin-top: 5px;
  font-size: 12.5px;
}

.banner--sm .banner__art {
  align-self: start;
  width: 46px;
}

.banner--sm .ill {
  stroke-width: 4.5;
}

/* 배너 폭에 맞춰 글자·그림 크기를 조절 (지원하는 브라우저에서만) */
@supports (width: 1cqw) {
  .banner--lg .banner__content {
    min-height: max(240px, 56.25cqw);
  }

  .banner--wide .banner__content {
    min-height: max(190px, 38cqw);
  }

  .banner--lg .banner__title,
  .banner--wide .banner__title {
    font-size: clamp(23px, 6.6cqw, 32px);
  }

  .banner--lg .banner__sub,
  .banner--wide .banner__sub {
    font-size: clamp(13.5px, 3.3cqw, 16px);
  }

  .banner--lg .banner__art,
  .banner--wide .banner__art {
    width: clamp(88px, 30cqw, 170px);
  }

  .banner--sm .banner__title {
    font-size: clamp(18px, 9.6cqw, 23px);
  }

  .banner--sm .banner__sub {
    font-size: clamp(12.5px, 6.2cqw, 14px);
  }

  .banner--sm .banner__art {
    width: clamp(42px, 24cqw, 64px);
  }
}

/* 좁은 휴대폰: 작은 배너 2장은 한 줄짜리 낮은 카드로 (그림 왼쪽 · 제목과 설명 가운데 · 꼬리표 오른쪽)
   ※ 위의 @supports 규칙보다 뒤에 있어야 그림 크기(44px)가 적용됩니다. */
@media (max-width: 419px) {
  .banner--sm .banner__content {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    grid-template-areas:
      "art title tag"
      "art sub sub";
    align-items: center;
    min-height: 0;
    padding: 16px 18px;
  }

  .banner--sm .banner__art {
    width: 44px;
    margin: 0 14px 0 0;
    justify-self: start;
    align-self: center;
  }

  .banner--sm .banner__title {
    margin-top: 0;
    align-self: end;
  }

  .banner--sm .banner__tag {
    align-self: center;
    justify-self: end;
    margin-left: 10px;
  }

  .banner--sm .banner__sub {
    margin-top: 2px;
    align-self: start;
  }
}

/* 사진 배너 (config 의 image 에 파일명을 적은 경우) */
.banner__img {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

.banner--photo::after {
  inset: 0;
  width: auto;
  aspect-ratio: auto;
  border-radius: 0;
  background: linear-gradient(180deg, rgba(7, 18, 44, 0.42) 0%, rgba(7, 18, 44, 0.84) 100%);
  opacity: 1;
}

/* ── 본문 블록(카드) ──────────────────────────────────────────────────────── */
.blocks {
  display: grid;
  gap: 24px;
  margin-top: 24px;
}

.blocks > * {
  min-width: 0;
}

.block {
  position: relative;
  padding: 24px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-card);
  container-type: inline-size;
}

@media (min-width: 480px) {
  .block {
    padding: 28px 26px;
  }
}

.block__title {
  margin-bottom: 16px;
  font-size: 18.4px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--ink);
}

/* "예시" 블록 제목 아래의 안내 문장 */
.block__title + .sample-note {
  margin-top: -8px;
}

.sample-note {
  margin-bottom: 16px;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.6;
  color: var(--text);
}

.block__text {
  font-size: 15.2px;
  line-height: 1.75;
  color: var(--muted);
}

.block__text + .block__text {
  margin-top: 12px;
}

/* "예시 (실제 아님)" 표시: 눈에 띄도록 주의색(호박색)을 씁니다.
   좁은 카드에서는 제목 위에, 넓은 카드에서는 오른쪽 위에 놓입니다(아래 @container 참고). */
.sample-badge {
  display: inline-block;
  margin-bottom: 10px;
  padding: 3px 10px;
  border: 1px solid #f59e0b;
  border-radius: 999px;
  background: #fffbeb;
  color: #92400e;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
}

/* 배너 블록은 카드 테두리 없이 배너 자체가 카드가 됩니다 */
.block--banner {
  padding: 0;
  border: 0;
  border-radius: 24px;
  background: none;
  box-shadow: none;
}

/* 후기 */
.review-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
}

.review {
  display: flex;
  flex-direction: column;
  padding: 19px 17px;
  border-radius: 14px;
  background: var(--surface);
}

.stars {
  display: flex;
  gap: 2px;
  margin-bottom: 10px;
  color: var(--star);
}

.star--off {
  color: #cbd5e1;
}

.review__text {
  flex: 1;
  margin-bottom: 14px;
  font-size: 14.6px;
  line-height: 1.65;
  color: var(--text);
}

.review__name {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}

.review__meta {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--muted-strong);
}

/* 숫자(성과) */
.metric-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

.metric {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 14px;
  padding: 15px 18px;
  border-radius: 14px;
  background: var(--surface);
}

.metric__value {
  font-size: 25px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--navy);
}

.metric__label {
  font-size: 13px;
  color: var(--muted-strong);
}

/* 막대 차트 */
.chart {
  display: grid;
  gap: 14px;
}

.chart__row {
  display: grid;
  grid-template-columns: minmax(0, var(--chart-label, 5em)) minmax(40px, 1fr) var(--chart-value, 3em);
  align-items: center;
  gap: 12px;
  font-size: 14px;
}

.chart__label {
  font-weight: 600;
  color: var(--text);
}

.chart__track {
  display: block;
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--primary-light);
}

.chart__fill {
  display: block;
  width: var(--w, 0%);
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform-origin: left center;
}

.chart__value {
  font-weight: 800;
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  color: var(--navy);
}

.chart__note {
  margin-top: 14px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}

/* 담당자 소개
   기본(좁은 카드·휴대폰): 사진 왼쪽, 글 오른쪽의 낮은 줄.
   카드 안쪽이 400px 이상이면 한 줄에 3명씩 (아래 @container 참고) */
.team-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.member {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  column-gap: 14px;
  align-items: center;
  text-align: left;
}

.avatar {
  display: grid;
  place-items: center;
  grid-row: 1 / span 3;
  width: 56px;
  height: 56px;
  margin: 0;
  overflow: hidden;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--primary-light) 10%, var(--accent) 220%);
  color: var(--navy);
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar--blank .icon {
  width: 28px;
  height: 28px;
  stroke-width: 1.5;
}

.member__name {
  font-size: 16px;
  font-weight: 800;
  line-height: 1.4;
}

.member__role {
  margin-top: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
}

.member__desc {
  margin-top: 2px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

/* 진행 절차 */
.steps {
  display: grid;
  gap: 20px;
}

.step {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 17px;
  top: 42px;
  bottom: -14px;
  width: 2px;
  border-radius: 2px;
  background: var(--line);
}

.step__num {
  flex: none;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
}

.step__body {
  min-width: 0;
  padding-top: 5px;
}

.step__title {
  font-size: 15.5px;
  font-weight: 800;
  line-height: 1.45;
}

.step__desc {
  margin-top: 3px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}

/* 이용 안내(가격) */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
  gap: 14px;
}

.plan {
  padding: 22px 18px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: #fff;
  text-align: center;
}

.plan--highlight {
  border-color: var(--primary);
  background: var(--primary-light);
}

.plan__name {
  font-size: 15px;
  font-weight: 800;
}

.plan__price {
  margin-top: 6px;
  font-size: 26px;
  font-weight: 900;
  line-height: 1.3;
  letter-spacing: -0.03em;
  color: var(--navy);
}

.plan__desc {
  margin-top: 4px;
  font-size: 13px;
  color: var(--muted-strong);
}

.plan__features {
  display: inline-grid;
  gap: 7px;
  margin-top: 14px;
  text-align: left;
}

.plan__features li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.45;
  color: var(--text);
}

.plan__features .icon {
  margin-top: 1px;
  color: var(--primary);
}

/* 자주 묻는 질문 */
.faq__item + .faq__item {
  border-top: 1px solid var(--line);
}

.faq__q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 44px;
  padding: 17px 2px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.5;
  list-style: none;
  cursor: pointer;
  border-radius: 8px;
}

.faq__q::-webkit-details-marker {
  display: none;
}

.faq__q:hover {
  color: var(--primary);
}

.faq__chev {
  width: 20px;
  height: 20px;
  color: var(--muted);
  transition: transform 0.25s ease;
}

.faq__item[open] .faq__chev {
  transform: rotate(180deg);
}

.faq__a {
  padding: 0 30px 20px 2px;
}

.faq__p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--muted);
}

.faq__p + .faq__p {
  margin-top: 10px;
}

.block--faq .block__title {
  margin-bottom: 6px;
}

.block--faq {
  padding-bottom: 10px;
}

/* 마지막 안내(CTA) */
.block--cta {
  padding-top: 34px;
  padding-bottom: 34px;
  text-align: center;
  background: linear-gradient(180deg, #fff 0%, var(--primary-light) 160%);
}

.cta__title {
  margin-bottom: 8px;
  font-size: 20px;
}

.cta__desc {
  font-size: 15.2px;
  color: var(--muted);
}

.pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  margin-top: 20px;
  padding: 12px 30px;
  border-radius: 999px;
  background: var(--navy);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.18);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.pill-btn:hover {
  filter: brightness(1.18);
  transform: translateY(-1px);
}

.pill-btn:active {
  transform: translateY(1px);
}

/* 맨 위 설명 아래의 신청 버튼: 폼이 페이지 맨 아래에 있는 휴대폰·태블릿 화면에서만 보입니다 */
.pill-btn.hero__cta {
  display: flex;
  margin-top: 20px;
}

@media (min-width: 1024px) {
  .pill-btn.hero__cta {
    display: none;
  }
}

@container (min-width: 400px) {
  /* "예시" 표시를 카드 오른쪽 위로 */
  .sample-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    margin-bottom: 0;
  }

  .block--sample > .block__title {
    padding-right: 128px;
  }

  /* 담당자 소개: 한 줄에 3명 (사진 위, 글 아래) */
  .team-grid {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 14px;
  }

  .member {
    display: block;
    text-align: center;
  }

  .avatar {
    width: 80px;
    height: 80px;
    margin: 0 auto 12px;
  }

  .avatar--blank .icon {
    width: 40px;
    height: 40px;
  }

  .member__desc {
    margin-top: 6px;
  }
}

/* 카드 안쪽 폭이 넉넉할 때의 배치 */
@container (min-width: 430px) {
  .review-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .steps {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 16px;
  }

  .step {
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-align: center;
  }

  .step:not(:last-child)::before {
    display: none;
  }

  .step__body {
    padding-top: 0;
  }
}

@container (min-width: 420px) {
  .metric-grid {
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  }

  .metric {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 20px 10px;
    text-align: center;
  }

  .metric__value {
    font-size: clamp(21px, 5.1cqw, 27px);
  }
}

/* ── 상담 신청 폼 ─────────────────────────────────────────────────────────── */
.lead-form {
  --gap-field: 26px;
  --gap-label: 12px;
  --control-h: 60px;
  --submit-h: 68px;
  --label-size: 19.2px;
  --consent-pad: 14px;
  position: relative;
}

@media (min-width: 1024px) {
  /* 화면 높이가 낮을수록 간격·높이를 조금씩 줄여 한 화면에 들어오게 합니다 */
  .lead-form {
    --gap-field: clamp(10px, calc(6vh - 32px), 32px);
    --gap-label: clamp(6px, 1.3vh, 12px);
    --control-h: clamp(48px, 6.6vh, 60px);
    --submit-h: clamp(56px, 8.2vh, 72px);
    --label-size: clamp(17px, 2.5vh, 19.2px);
    --consent-pad: clamp(2px, calc(5vh - 36px), 14px);
  }
}

/* 화면 높이가 낮은 PC(노트북 150% 배율 등): 입력 칸을 2칸으로 배치해 신청 버튼까지 한 화면에 들어오게 합니다.
   ※ 위 규칙보다 뒤에 있어야 합니다. */
@media (min-width: 1024px) and (max-height: 720px) {
  .lead-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 14px;
  }

  .lead-form > * {
    grid-column: 1 / -1;
  }

  .lead-form > .field {
    grid-column: auto;
  }

  /* 항목 수가 홀수일 때 마지막 항목은 한 줄을 다 씁니다 */
  .lead-form > .field--full {
    grid-column: 1 / -1;
  }
}

.field {
  margin-bottom: var(--gap-field);
}

.field__label {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin-bottom: var(--gap-label);
  font-size: var(--label-size);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -0.02em;
}

.field__num {
  padding: 4px 12px;
  border-radius: 20px;
  background: var(--navy);
  color: #fff;
  font-size: 13.6px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: 0;
}

.field__req {
  margin-left: -4px;
  color: #dc2626;
}

.control {
  display: block;
  width: 100%;
  height: var(--control-h);
  padding: 0 22px;
  border: 1px solid var(--field-line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  font-size: 16.8px;
  font-weight: 500;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}

.control::placeholder {
  color: var(--muted-strong);
  opacity: 1;
}

.control:hover {
  border-color: var(--muted);
}

.control:focus {
  /* 평소에는 보이지 않고, Windows 고대비 모드에서는 시스템 색으로 그려지는 테두리 */
  outline: 2px solid transparent;
  outline-offset: 2px;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 4px var(--ring);
}

.control[aria-invalid="true"] {
  border-color: var(--danger);
}

.control[aria-invalid="true"]:focus {
  box-shadow: 0 0 0 4px rgba(185, 28, 28, 0.16);
}

.select-wrap {
  position: relative;
}

.control--select {
  padding-right: 54px;
  cursor: pointer;
  text-overflow: ellipsis;
}

.control--select.is-empty {
  color: var(--muted-strong);
}

.control--select option {
  color: var(--ink);
  background: #fff;
}

.select-wrap__chev {
  position: absolute;
  right: 20px;
  top: 50%;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  color: var(--muted);
  pointer-events: none;
}

.field__error {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--danger);
}

.field__error:not(:empty) {
  margin-top: 7px;
}

/* 자동 프로그램 걸러내기용 숨김 칸 (사람에게는 보이지 않습니다) */
.hp {
  position: absolute;
  left: -9999px;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* 개인정보 동의 (수집·이용 동의 + 설정에 따라 국외 이전 동의) */
.consents {
  margin-bottom: var(--gap-field);
}

.consent + .consent {
  margin-top: 8px;
}

.consent__box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: var(--consent-pad) 12px var(--consent-pad) 22px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: var(--surface);
  font-size: 15.2px;
  font-weight: 600;
}

.consent.has-error .consent__box {
  border-color: var(--danger);
}

.consent__label {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  min-height: 44px;
  cursor: pointer;
}

@media (min-width: 1024px) {
  /* PC 에서는 마우스로 누르므로 조금 낮춰 폼 전체가 한 화면에 들어오게 합니다 */
  .consent__label,
  .consent__link {
    min-height: 40px;
  }
}

.consent__input {
  position: absolute;
  left: 0;
  top: 50%;
  width: 24px;
  height: 24px;
  margin: -12px 0 0;
  opacity: 0;
  cursor: pointer;
}

.consent__check {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 2px solid var(--muted);
  border-radius: 7px;
  background: #fff;
  color: #fff;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

/* 체크 표시는 색이 아니라 보임/숨김으로 구분합니다. (고대비 모드에서도 체크 여부가 구분되도록) */
.consent__check .icon {
  width: 16px;
  height: 16px;
  stroke-width: 3.2;
  visibility: hidden;
}

.consent__input:checked + .consent__check .icon {
  visibility: visible;
}

.consent__input:checked + .consent__check {
  border-color: var(--navy);
  background: var(--navy);
  color: #fff;
}

.consent__input:focus-visible + .consent__check {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.consent__link {
  flex: none;
  min-width: 48px;
  min-height: 44px;
  padding: 0 10px;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--primary);
  font-weight: 700;
  cursor: pointer;
}

.consent__link:hover {
  text-decoration: underline;
}

.turnstile {
  margin-bottom: var(--gap-field);
}

/* 신청 버튼 */
.submit-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: var(--submit-h);
  padding: 0 20px;
  border: 0;
  border-radius: 16px;
  background: var(--navy);
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.01em;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.2);
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease, box-shadow 0.15s ease;
}

.submit-btn:hover {
  filter: brightness(1.18);
  transform: translateY(-1px);
  box-shadow: 0 18px 32px rgba(15, 23, 42, 0.24);
}

.submit-btn:active {
  transform: translateY(1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.2);
}

.submit-btn:disabled {
  filter: none;
  transform: none;
  opacity: 0.86;
  cursor: progress;
}

.submit-btn__spinner {
  display: none;
  width: 22px;
  height: 22px;
  border: 3px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.submit-btn.is-loading .submit-btn__spinner {
  display: block;
}

.submit-btn.is-loading .submit-btn__arrow {
  display: none;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.noscript {
  margin-top: 14px;
  padding: 12px 16px;
  border-radius: 12px;
  background: #fef2f2;
  color: var(--danger);
  font-size: 14px;
  font-weight: 600;
}

/* ── 팝업 창 ──────────────────────────────────────────────────────────────── */
.dialog {
  width: calc(100% - 32px);
  max-width: 520px;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.3);
  overflow: auto;
  overscroll-behavior: contain;
}

.dialog::backdrop {
  background: rgba(15, 23, 42, 0.56);
}

.dialog--result {
  max-width: 420px;
}

.dialog__panel {
  padding: 26px 24px 22px;
}

.dialog__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.dialog__title {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: -0.02em;
}

.dialog__head .dialog__title {
  padding-top: 8px;
}

.dialog__close {
  flex: none;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin: -4px -8px 0 0;
  border: 0;
  border-radius: 12px;
  background: none;
  color: var(--muted);
  cursor: pointer;
}

.dialog__close:hover {
  background: var(--surface);
  color: var(--ink);
}

.privacy__list {
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 14px;
}

.privacy__list > div {
  display: grid;
  grid-template-columns: 8.2em minmax(0, 1fr);
}

.privacy__list > div + div {
  border-top: 1px solid var(--line);
}

.privacy__list dt {
  padding: 12px 14px;
  background: var(--surface);
  font-weight: 700;
}

.privacy__list dd {
  padding: 12px 14px;
  color: var(--text);
}

.privacy__note {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--muted);
}

.privacy__note + .privacy__note {
  margin-top: 8px;
}

.dialog__foot {
  margin-top: 22px;
}

.dialog__btn {
  display: block;
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 14px;
  background: var(--navy);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: filter 0.15s ease;
}

.dialog__btn:hover {
  filter: brightness(1.18);
}

.dialog--result .dialog__panel {
  padding-top: 32px;
  text-align: center;
}

.result__icon {
  display: none;
  place-items: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
}

.result__icon .icon {
  width: 32px;
  height: 32px;
}

.result__icon--success {
  background: var(--primary-light);
  color: var(--primary);
}

.result__icon--error {
  background: #fee2e2;
  color: var(--danger);
}

.dialog--result[data-state="success"] .result__icon--success,
.dialog--result[data-state="error"] .result__icon--error {
  display: grid;
}

.result__message {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--muted);
}

/* ── 푸터 (법정 표시 사항) ────────────────────────────────────────────────── */
.site-footer {
  padding: 44px 20px 52px;
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  color: var(--muted-strong);
  font-size: 14px;
  line-height: 1.7;
}

@media (min-width: 768px) {
  .site-footer {
    padding: 56px 32px;
  }
}

.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-info {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
}

.footer-info > div {
  display: flex;
  gap: 6px;
  min-width: 0;
}

.footer-info dt {
  flex: none;
  font-weight: 700;
  color: var(--text);
}

.footer-info a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-terms {
  margin-top: 22px;
}

.footer-terms h2 {
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
}

.footer-terms li {
  position: relative;
  padding-left: 12px;
}

.footer-terms li::before {
  content: "";
  position: absolute;
  left: 1px;
  top: 0.78em;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}

/* 경고 문구: 법적으로 꼭 보여야 하는 내용이므로 크고 진하게 표시합니다 */
.footer-warnings {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 24px;
  padding: 18px 20px;
  border: 1px solid #cbd5e1;
  border-left: 4px solid var(--navy);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font-size: 15.5px;
  font-weight: 700;
  line-height: 1.7;
}

.footer-warnings .icon {
  margin-top: 2px;
  color: var(--navy);
}

.footer-links {
  margin-top: 22px;
}

.footer-links a {
  color: var(--ink);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-copy {
  margin-top: 24px;
  font-size: 13px;
}

.footer-links + .footer-copy {
  margin-top: 10px;
}

/* ── 개인정보 처리방침 페이지 (/privacy) ──────────────────────────────────── */
.policy {
  max-width: 760px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

.policy__back {
  margin-bottom: 20px;
  font-size: 14.5px;
  font-weight: 700;
}

.policy__title {
  margin-bottom: 14px;
  font-size: clamp(24px, 6.4vw, 30px);
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.03em;
}

.policy__intro,
.policy__text {
  font-size: 15.2px;
  line-height: 1.8;
  color: var(--text);
}

.policy__text + .policy__text {
  margin-top: 12px;
}

.policy__section {
  margin-top: 30px;
}

.policy__section h2 {
  margin-bottom: 8px;
  font-size: 17.5px;
  font-weight: 800;
  line-height: 1.45;
}

.policy__effective {
  margin-top: 34px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 14.5px;
  font-weight: 700;
}

/* ── 스크롤 등장 효과 (main.js 가 html 에 js 클래스를 붙였을 때만 동작) ───── */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.js .reveal .chart__fill {
  transform: scaleX(0);
  transition: transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1) 0.2s;
}

.js .reveal.is-visible .chart__fill {
  transform: scaleX(1);
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal,
  .js .reveal .chart__fill {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .faq__chev,
  .pill-btn,
  .submit-btn,
  .control {
    transition: none;
  }

  .submit-btn__spinner {
    animation-duration: 1.6s;
  }
}

@media print {
  .js .reveal,
  .js .reveal .chart__fill {
    opacity: 1 !important;
    transform: none !important;
  }

  .form-panel {
    position: static;
  }
}
