/* =========================================================================
   styles.css — 프라움 비뇨의학과 리드 수집 랜딩페이지
   테마 색은 .shell[style] 컨테이너에 CSS 변수로 주입됨
   ========================================================================= */

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background:
    radial-gradient(1200px 600px at 50% -10%, #2b2f3a 0%, #1a1c22 55%, #131419 100%);
  color: #fff;
}

#root { min-height: 100%; }

/* ───────────────────────── 스테이지 / 디바이스 프레임 ───────────────────────── */
.stage {
  display: flex; justify-content: center;
  padding: 30px 16px 64px;
}
.shell {
  width: 100%; max-width: 460px;
  background: var(--surface);
  color: var(--ink);
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.04);
  font-family: var(--font);
  position: relative;
}
/* 모바일에선 디바이스 라운드 제거하고 풀폭 */
@media (max-width: 520px) {
  .stage { padding: 0 0 40px; }
  .shell { max-width: 100%; border-radius: 0; box-shadow: none; }
}

/* 모바일 폰트 조정 */
@media (max-width: 520px) {
  .hero h1 { font-size: 17px; }
  .hero-sub { font-size: 12px; }
  .hero-photo { right: -20px; }
}

/* 소형폰 (390px 이하) */
@media (max-width: 390px) {
  .hero h1 { font-size: 15px; }
  .hero-sub { font-size: 11.5px; }
  .hero-photo { right: -15px; }
  .stat-num { font-size: 16px; }
  .stat-label { font-size: 9.5px; }
}

/* 초소형폰 (360px 이하) */
@media (max-width: 360px) {
  .hero h1 { font-size: 14px; }
  .hero-sub { font-size: 11px; }
  .hero-photo { right: -10px; }
  .topbar { font-size: 11px; gap: 5px; }
  .topbar .sub { font-size: 10px; }
}

/* ───────────────────────── 상단 바 ───────────────────────── */
.topbar {
  background: var(--bg);
  color: var(--hero-ink);
  padding: 12px 18px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 13px; font-weight: 600; letter-spacing: -0.2px;
}
.topbar .lock { color: var(--accent); }
.topbar strong { margin-right: -4px; }
.topbar strong, .topbar strong + span { white-space: nowrap; }
.topbar .sub { color: var(--hero-ink-soft); font-weight: 500; font-size: 11px; }
.topbar.light { border-bottom: 1px solid var(--line); }

/* A 시안: 최상단 띠 + 버튼 골드 (#C5934E) */
.shell-A .topbar { background: #C5934E; color: #ffffff; border-bottom: none; }
.shell-A .topbar .lock, .shell-A .topbar .sub { color: #ffffff; }
.shell-A .btn-primary { background: #C5934E; box-shadow: 0 10px 22px -10px #C5934E; }
.shell-A .btn-call { background: #C5934E; }

/* 긴급성 배너 */
.urgency {
  background: var(--danger);
  color: #fff; text-align: center;
  padding: 8px 16px; font-size: 12px; font-weight: 600; letter-spacing: -0.2px;
}

/* ───────────────────────── 히어로 ───────────────────────── */
.hero {
  background: var(--bg);
  color: var(--hero-ink);
  padding: 26px 22px 0;
  position: relative; overflow: hidden;
  min-height: 250px;
  display: flex; align-items: flex-end;
}
.hero.light { background: var(--surface-2); }
.hero-grid { display: block; position: relative; width: 100%; }
.hero-text {
  position: relative; z-index: 1; min-width: 0;
  padding-bottom: 24px; padding-left: 22px; padding-right: 92px;
  max-width: 100%;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.2px;
  color: var(--accent); margin-bottom: 12px;
  padding: 4px 10px; border-radius: 20px;
  background: var(--accent-soft);
}
.hero h1 {
  font-size: 21px; line-height: 1.38; font-weight: 800;
  letter-spacing: -0.6px; margin-bottom: 12px;
  word-break: keep-all; overflow-wrap: break-word;
}
.hero h1 .em { color: var(--accent); }
.hero-sub { font-size: 13.5px; line-height: 1.6; color: var(--hero-ink-soft); margin-bottom: 14px; word-break: keep-all; }
.hero-cred {
  font-size: 12px; color: var(--hero-ink-soft);
  display: flex; align-items: center; gap: 6px; line-height: 1.5; flex-wrap: wrap;
  padding-right: 0;
}
.hero-cred .tick { color: var(--accent); flex-shrink: 0; }
.hero-cred .cred-break { flex-basis: 100%; width: 100%; height: 0; margin: 0; }
.hero-cred .cred-tag {
  font-size: 10.5px; font-weight: 700; color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  padding: 2.5px 8px; border-radius: 999px; white-space: nowrap; letter-spacing: -0.01em;
}

.hero-photo {
  position: absolute; right: -30px; bottom: -132px; z-index: 0;
  width: 332px; pointer-events: none;
}
.hero-photo-img {
  width: 100%; height: auto; display: block;
}

/* 신뢰 스탯 (히어로 하단) */
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  background: var(--bg-soft);
}
.hero.light + .stats { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat { padding: 14px 8px; text-align: center; position: relative; }
.stat + .stat::before {
  content: ""; position: absolute; left: 0; top: 22%; bottom: 22%;
  width: 1px; background: rgba(255,255,255,0.12);
}
.hero.light + .stats .stat + .stat::before { background: var(--line); }
.stat-num { font-size: 19px; font-weight: 800; color: var(--accent); letter-spacing: -0.5px; }
.stat-label { font-size: 10.5px; color: var(--hero-ink-soft); margin-top: 3px; letter-spacing: -0.2px; }
.hero.light + .stats .stat-label { color: var(--ink-soft); }

/* ───────────────────────── 진행 바 ───────────────────────── */
.progress {
  padding: 16px 20px 6px;
  background: var(--surface);
}
.progress-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}
.progress-step { font-size: 12px; font-weight: 700; color: var(--ink); letter-spacing: -0.2px; }
.progress-step .cur { color: var(--accent); }
.progress-pct { font-size: 12px; font-weight: 700; color: var(--accent); }
.progress-track {
  height: 7px; border-radius: 99px; background: var(--surface-2);
  overflow: hidden;
}
.progress-fill {
  height: 100%; border-radius: 99px;
  background: linear-gradient(90deg, var(--accent-deep), var(--accent));
  transition: width .45s cubic-bezier(.4,0,.2,1);
}

/* 스텝 도트 */
.dots { display: flex; gap: 6px; justify-content: center; padding: 10px 0 2px; }
.dot-i { width: 6px; height: 6px; border-radius: 50%; background: var(--line); transition: all .3s; }
.dot-i.done { background: var(--accent); }
.dot-i.cur { width: 18px; border-radius: 99px; background: var(--accent); }

/* ───────────────────────── 본문 카드 ───────────────────────── */
.body { padding: 18px 18px 24px; background: var(--surface); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 20px 20px;
  box-shadow: 0 6px 24px -16px rgba(0,0,0,0.25);
}

.q-head { margin-bottom: 18px; }
.q-tag {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: -0.1px;
  color: var(--accent-ink); background: var(--accent-soft);
  padding: 4px 11px; border-radius: 20px; margin-bottom: 14px;
}
.q-title {
  font-size: 20px; font-weight: 800; line-height: 1.38; letter-spacing: -0.5px;
  color: var(--ink); text-wrap: pretty;
}
.q-hint { font-size: 12.5px; color: var(--ink-faint); margin-top: 8px; line-height: 1.5; }

/* 옵션 — 리스트 */
.opts { display: flex; flex-direction: column; gap: 9px; margin: 18px 0 6px; }
.opt {
  display: flex; align-items: center; gap: 13px;
  padding: 15px 16px;
  border: 1.5px solid var(--line); border-radius: 13px;
  cursor: pointer; background: var(--surface);
  font-size: 15px; font-weight: 500; color: var(--ink);
  transition: border-color .12s, background .12s, transform .08s;
  text-align: left; width: 100%; font-family: inherit;
}
.opt:hover { border-color: var(--accent); }
.opt:active { transform: scale(.99); }
.opt.sel { border-color: var(--accent); background: var(--accent-soft); }
.radio {
  width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--ink-faint); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  transition: border-color .12s;
}
.opt.sel .radio { border-color: var(--accent); }
.radio::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); transform: scale(0); transition: transform .15s; }
.opt.sel .radio::after { transform: scale(1); }
.check { border-radius: 6px; }
.check::after { border-radius: 2px; }

/* 옵션 — 그리드 */
.opts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 18px 0 6px; }
.opt-g {
  border: 1.5px solid var(--line); border-radius: 13px;
  padding: 16px 8px; text-align: center; cursor: pointer;
  font-size: 14.5px; font-weight: 600; color: var(--ink); background: var(--surface);
  transition: border-color .12s, background .12s, transform .08s;
  font-family: inherit;
}
.opt-g:hover { border-color: var(--accent); }
.opt-g:active { transform: scale(.98); }
.opt-g.sel { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }

/* ───────────────────────── 버튼 ───────────────────────── */
.btn-row { display: flex; gap: 10px; margin-top: 18px; }
.btn {
  height: 54px; border: none; border-radius: 14px;
  font-size: 15.5px; font-weight: 700; cursor: pointer; font-family: inherit;
  letter-spacing: -0.3px; transition: filter .15s, transform .08s;
  display: flex; align-items: center; justify-content: center; gap: 7px;
}
.btn:active { transform: scale(.98); }
.btn-primary {
  flex: 1; color: #fff;
  background: linear-gradient(100deg, var(--accent-deep), var(--accent));
  box-shadow: 0 10px 22px -10px var(--accent);
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-ghost {
  flex: 0 0 32%; color: var(--accent-ink);
  background: var(--surface); border: 1.5px solid var(--line);
}
.btn-ghost:hover { border-color: var(--accent); }
.btn-block { width: 100%; }

/* ───────────────────────── 인트로 (step 0) ───────────────────────── */
.intro { padding: 18px 18px 24px; background: var(--surface); }
.intro-cta { margin-bottom: 14px; }
.intro-mini {
  text-align: center; font-size: 12px; color: var(--ink-faint);
  margin-top: 11px; display: flex; align-items: center; justify-content: center; gap: 7px;
}
.intro-mini .pin { color: var(--accent); }

.trust {
  margin-top: 6px;
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; background: var(--surface-2);
}
.trust-h { font-size: 12px; font-weight: 700; color: var(--ink-soft); margin-bottom: 11px; letter-spacing: -0.2px; }
.trust-list { display: flex; flex-direction: column; gap: 9px; }
.trust-i { font-size: 13px; color: var(--ink); display: flex; align-items: flex-start; gap: 10px; line-height: 1.4; }
.trust-i .tick {
  color: var(--accent); flex-shrink: 0; font-weight: 800;
  width: 18px; height: 18px; border-radius: 50%; background: var(--accent-soft);
  display: flex; align-items: center; justify-content: center; font-size: 10px;
}

/* 유의사항 (접이식) */
.notice {
  margin-top: 14px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface-2); overflow: hidden;
}
.notice summary {
  list-style: none; cursor: pointer; padding: 13px 16px;
  font-size: 12.5px; font-weight: 700; color: var(--ink-soft);
  display: flex; align-items: center; justify-content: space-between;
}
.notice summary::-webkit-details-marker { display: none; }
.notice summary .chev { transition: transform .2s; color: var(--ink-faint); }
.notice[open] summary .chev { transform: rotate(180deg); }
.notice-body { padding: 0 16px 14px; }
.notice-body p { font-size: 11.5px; color: var(--ink-faint); line-height: 1.85; }

/* ───────────────────────── 입력 폼 ───────────────────────── */
.warn { font-size: 11.5px; color: var(--danger); line-height: 1.55; margin: -4px 0 16px; }
.field { margin-bottom: 16px; }
.field-label { font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 7px; display: block; }
.field-label .opt-mk { color: var(--ink-faint); font-weight: 400; }
.input {
  width: 100%; height: 54px;
  border: 1.5px solid var(--line); border-radius: 13px;
  padding: 0 16px; font-size: 15px; color: var(--ink); background: var(--surface);
  outline: none; font-family: inherit; transition: border-color .12s;
}
.input:focus { border-color: var(--accent); }
.input::placeholder { color: var(--ink-faint); }
.phone-wrap { display: flex; gap: 9px; }
.phone-prefix {
  width: 62px; height: 54px; flex-shrink: 0;
  background: var(--surface-2); border: 1.5px solid var(--line); border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: var(--ink-soft);
}
.time-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; }
.time-i {
  border: 1.5px solid var(--line); border-radius: 11px;
  padding: 11px 4px; text-align: center; cursor: pointer;
  font-size: 12px; color: var(--ink-soft); line-height: 1.5; font-weight: 500;
  transition: border-color .12s, background .12s; font-family: inherit;
}
.time-i:hover { border-color: var(--accent); }
.time-i.sel { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-ink); }

.privacy-note {
  background: var(--surface-2); border-radius: 12px;
  padding: 13px 15px; font-size: 11.5px; color: var(--ink-soft);
  line-height: 1.6; margin-bottom: 15px;
  display: flex; gap: 9px; align-items: flex-start;
}
.privacy-note .lock { color: var(--accent); flex-shrink: 0; }
.consent {
  display: flex; align-items: flex-start; gap: 9px;
  font-size: 12px; color: var(--ink-faint); line-height: 1.5; margin-top: 13px;
}
.consent input { margin-top: 1px; flex-shrink: 0; width: 16px; height: 16px; accent-color: var(--accent); }

/* ───────────────────────── 완료 화면 ───────────────────────── */
.complete { padding: 30px 20px 30px; background: var(--surface); text-align: center; }
.complete-badge {
  width: 66px; height: 66px; border-radius: 50%; margin: 0 auto 18px;
  background: linear-gradient(135deg, var(--accent-deep), var(--accent));
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 12px 28px -10px var(--accent);
}
.complete-badge svg { width: 32px; height: 32px; }
.complete-title { font-size: 21px; font-weight: 800; color: var(--ink); letter-spacing: -0.5px; line-height: 1.35; margin-bottom: 9px; text-wrap: pretty; }
.complete-sub { font-size: 13.5px; color: var(--ink-soft); line-height: 1.6; margin-bottom: 22px; text-wrap: pretty; }

.summary {
  text-align: left; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; margin-bottom: 16px; background: var(--surface-2);
}
.summary-h { font-size: 12px; font-weight: 700; color: var(--accent-ink); margin-bottom: 12px; }
.summary-row { display: flex; gap: 12px; font-size: 13px; line-height: 1.5; padding: 5px 0; }
.summary-row .k { color: var(--ink-faint); flex: 0 0 70px; }
.summary-row .v { color: var(--ink); font-weight: 600; flex: 1; }

.action-btns { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.btn-call { height: 54px; border: none; border-radius: 14px; background: var(--accent); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit; text-decoration: none; display: flex; align-items: center; justify-content: center; gap: 8px; }
.btn-kakao { height: 54px; border: none; border-radius: 14px; background: #FEE500; color: #3a1d1d; font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit; display: flex; align-items: center; justify-content: center; gap: 8px; }

.info-card {
  text-align: left; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 12px; padding: 14px 16px;
}
.info-row { font-size: 12.5px; color: var(--ink-soft); line-height: 1.85; display: flex; gap: 9px; }
.info-row .ic { color: var(--accent); flex-shrink: 0; }

/* ───────────────────────── 페이드 전환 ───────────────────────── */
.fade-step { animation: fadeUp .35s cubic-bezier(.4,0,.2,1); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .fade-step { animation: none; } }
