@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Inter:wght@400;500;600;700&display=swap');

* {
  box-sizing: border-box;
}

:root {
  --bg: #d8cab9;
  --bg-2: #cdbba6;
  --card: #eee5d9;
  --card-2: #f5eee5;
  --text: #2f2925;
  --text-soft: #5f554c;
  --text-faint: #877b71;
  --line: #d6c7b6;
  --input-bg: #f6efe6;
  --button-bg: #342d29;
  --button-text: #f9f4ee;
  --shadow: 0 14px 34px rgba(76, 58, 44, 0.10);
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  color: var(--text);
}

.page-shell {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 24px 16px 40px;
}

.app-card {
  width: 100%;
  max-width: 430px;
  background: rgba(238, 229, 217, 0.96);
  border: 1px solid rgba(207, 192, 176, 0.85);
  border-radius: 32px;
  box-shadow: var(--shadow);
  padding: 0 22px 26px;
  overflow: hidden;
}

/* 상단 브랜드 바 */
.brand-row {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 0 18px;
  background: linear-gradient(
    180deg,
    rgba(238, 229, 217, 0.98) 0%,
    rgba(238, 229, 217, 0.95) 80%,
    rgba(238, 229, 217, 0) 100%
  );
  backdrop-filter: blur(4px);
}

.logo-wrap {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 16px;
}

.logo-symbol {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.brand {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 24px;
  line-height: 1;
  color: var(--text);
  margin-bottom: 3px;
}

.tagline {
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-faint);
  font-weight: 500;
}

/* 본문 */
.screen-section {
  padding-bottom: 6px;
}

.hero-section {
  padding-top: 10px;
}

.section-kicker {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin: 2px 0 10px;
  font-weight: 600;
}

h1 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 48px;
  line-height: 0.98;
  letter-spacing: -0.03em;
  font-weight: 400;
  margin: 0 0 18px 0;
  color: var(--text);
}

.page-title {
  font-size: 42px;
  line-height: 1.02;
  margin-bottom: 14px;
}

.intro {
  color: var(--text-soft);
  font-size: 17px;
  line-height: 1.75;
  margin: 0 0 18px 0;
}

.intro.compact {
  font-size: 16px;
  line-height: 1.7;
}

.sub-intro {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  margin: 0 0 26px 0;
}

/* 진행률 바 */
.progress-bar {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: rgba(116, 96, 77, 0.14);
  overflow: hidden;
  margin: 8px 0 18px;
}

.progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #8f7154 0%, #5e4736 100%);
}

.progress-33 {
  width: 33.33%;
}

.progress-66 {
  width: 66.66%;
}

.progress-100 {
  width: 100%;
}

/* 폼 */
.form-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

label {
  font-size: 14px;
  color: var(--text-soft);
  font-weight: 600;
}

input:not([type="checkbox"]),
select {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--input-bg);
  color: var(--text);
  font-size: 16px;
  font-family: inherit;
  outline: none;
  transition: all 0.18s ease;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

input::placeholder {
  color: #9a8f84;
}

input:focus,
select:focus {
  border-color: #a98f78;
  box-shadow: 0 0 0 4px rgba(169, 143, 120, 0.16);
}

select {
  background-image:
    linear-gradient(45deg, transparent 50%, #665a50 50%),
    linear-gradient(135deg, #665a50 50%, transparent 50%);
  background-position:
    calc(100% - 22px) calc(50% - 2px),
    calc(100% - 16px) calc(50% - 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 44px;
}

/* 성별 버튼 */
.gender-buttons {
  display: flex;
  gap: 12px;
}

.gender-option {
  flex: 1;
  cursor: pointer;
}

.gender-option input {
  display: none;
}

.gender-option span {
  display: block;
  text-align: center;
  padding: 15px 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--input-bg);
  color: var(--text);
  font-size: 15px;
  transition: all 0.18s ease;
}

.gender-option input:checked + span {
  background: var(--button-bg);
  color: var(--button-text);
  border-color: var(--button-bg);
}

/* 버튼 */
.primary-button {
  display: block;
  width: 100%;
  text-align: center;
  text-decoration: none;
  border: none;
  cursor: pointer;
  background: var(--button-bg);
  color: var(--button-text);
  padding: 18px 20px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  margin-top: 8px;
  box-shadow: 0 10px 24px rgba(47, 42, 39, 0.14);
}

/* 프리뷰 */
.summary-box,
.bonus-box,
.mini-chart {
  background: rgba(255, 255, 255, 0.26);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  margin-bottom: 16px;
}

.summary-box p {
  margin: 0 0 10px 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: var(--text-soft);
  line-height: 1.55;
}

.summary-box p:last-child {
  margin-bottom: 0;
}

.summary-box strong {
  color: var(--text);
  font-size: 13px;
  letter-spacing: 0.02em;
}

.mini-chart-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-soft);
  margin-bottom: 12px;
}

.chart-placeholder {
  height: 160px;
  border-radius: 18px;
  background: linear-gradient(180deg, #eadfd2 0%, #ddd0c0 100%);
  border: 1px solid #d3c1ad;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--text-faint);
  font-size: 14px;
  padding: 16px;
}

.blur-card {
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.26);
  padding: 18px;
  margin-bottom: 14px;
}

.blur-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-soft);
  margin-bottom: 12px;
}

.blur-content {
  height: 72px;
  border-radius: 16px;
  background: linear-gradient(
    90deg,
    rgba(115, 96, 76, 0.18),
    rgba(115, 96, 76, 0.28),
    rgba(115, 96, 76, 0.18)
  );
  filter: blur(6px);
}

.bonus-box h3 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 28px;
  line-height: 1.1;
  margin: 0 0 10px 0;
  font-weight: 400;
  color: var(--text);
}

.bonus-box p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.7;
  font-size: 15px;
}

/* 반응형 - 소형 모바일 */
@media (max-width: 430px) {
  .page-shell {
    padding: 14px 10px 28px;
  }

  .app-card {
    border-radius: 28px;
    padding: 0 18px 22px;
  }

  .brand-row {
    gap: 12px;
    padding: 18px 0 16px;
  }

  .logo-wrap {
    width: 52px;
    height: 52px;
  }

  .brand {
    font-size: 22px;
  }

  .tagline {
    font-size: 13px;
  }

  h1 {
    font-size: 42px;
  }

  .page-title {
    font-size: 36px;
  }

  .intro {
    font-size: 16px;
  }

  .sub-intro {
    font-size: 14px;
  }

  input,
  select {
    font-size: 16px;
  }
}

/* 극소형 모바일 (iPhone SE 등) */
@media (max-width: 375px) {
  .page-shell {
    padding: 10px 6px 20px;
  }

  .app-card {
    border-radius: 24px;
    padding: 0 14px 18px;
  }

  h1 {
    font-size: 36px;
  }

  .page-title {
    font-size: 30px;
  }

  .primary-button {
    padding: 16px 16px;
    font-size: 15px;
  }
}

/* 태블릿/데스크톱 */
@media (min-width: 768px) {
  .page-shell {
    padding: 40px 24px 60px;
    align-items: center;
  }
}

.secondary-button {
  display: block;
  width: 100%;
  text-align: center;
  text-decoration: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-soft);
  padding: 14px 20px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.18s ease;
}

.secondary-button:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: #a98f78;
}