/* =========================================================================
   결(結) 사주연구소 — style.css
   한지 위에 놓인 먹글씨 · 단청 인주 · 오행 5색
   ========================================================================= */

/* ---------- 1. 토큰 ---------- */
:root {
  --paper: #F7F2E7;
  --paper-2: #FDFAF3;
  --paper-3: #F1EADA;
  --ink: #1E2429;
  --ink-soft: #4B555D;
  --ink-mute: #6B747B;
  --line: #E4DAC6;
  --line-soft: #EDE6D6;
  --accent: #A9502F;
  --accent-2: #C4673F;
  --accent-soft: #F3E2D6;
  --navy: #22384A;
  --cta-bg: #22384A;
  --cta-fg: #F7F2E7;

  --e-wood: #3D7A57;
  --e-fire: #BF5340;
  --e-earth: #A8813F;
  --e-metal: #7E858C;
  --e-water: #33628A;

  --t-wood: rgba(61, 122, 87, .10);
  --t-fire: rgba(191, 83, 64, .10);
  --t-earth: rgba(168, 129, 63, .13);
  --t-metal: rgba(126, 133, 140, .12);
  --t-water: rgba(51, 98, 138, .10);

  --shadow-s: 0 1px 2px rgba(46, 38, 24, .05);
  --shadow-m: 0 10px 30px -18px rgba(46, 38, 24, .35), 0 2px 6px rgba(46, 38, 24, .04);
  --shadow-l: 0 30px 60px -34px rgba(46, 38, 24, .45), 0 4px 14px rgba(46, 38, 24, .05);

  --font-display: 'Hahmlet', 'Nanum Myeongjo', 'AppleMyungjo', 'Batang', 'Noto Serif KR', serif;
  --font-body: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', 'Noto Sans KR', system-ui, sans-serif;

  --r-s: 10px;
  --r-m: 16px;
  --r-l: 22px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #14171A;
    --paper-2: #1A1E22;
    --paper-3: #20252A;
    --ink: #F0EAE0;
    --ink-soft: #C2BCB2;
    --ink-mute: #8B867E;
    --line: rgba(255, 255, 255, .10);
    --line-soft: rgba(255, 255, 255, .06);
    --accent: #D9784F;
    --accent-2: #E08B62;
    --accent-soft: rgba(217, 120, 79, .14);
    --navy: #C9D6E2;
    --cta-bg: #232A31;
    --cta-fg: #F0EAE0;

    --e-wood: #7FB79A;
    --e-fire: #E28873;
    --e-earth: #D3A860;
    --e-metal: #B6BBC0;
    --e-water: #7FA9CE;

    --t-wood: rgba(127, 183, 154, .13);
    --t-fire: rgba(226, 136, 115, .13);
    --t-earth: rgba(211, 168, 96, .13);
    --t-metal: rgba(182, 187, 192, .12);
    --t-water: rgba(127, 169, 206, .13);

    --shadow-s: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow-m: 0 12px 30px -20px rgba(0, 0, 0, .8);
    --shadow-l: 0 30px 60px -30px rgba(0, 0, 0, .9);
  }
}

/* ---------- 2. 기본 ---------- */
* { box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--paper);
  background-image:
    radial-gradient(circle at 12% 8%, rgba(169, 80, 47, .045), transparent 42%),
    radial-gradient(circle at 88% 22%, rgba(51, 98, 138, .05), transparent 46%),
    radial-gradient(circle at 50% 100%, rgba(168, 129, 63, .05), transparent 55%);
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.72;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
  overflow-wrap: break-word;
}

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.28; letter-spacing: -0.01em; margin: 0; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
s { color: var(--ink-mute); }
.muted { color: var(--ink-mute); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 12px 18px; border-radius: 0 0 var(--r-s) 0;
}
.skip:focus { left: 0; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 3. 헤더 ---------- */
.site-head {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
@supports not (background: color-mix(in srgb, red 50%, blue)) {
  .site-head { background: var(--paper); }
}
.head-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 66px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; }
.seal {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  background: var(--accent);
  color: #FBF7EF;
  font-family: var(--font-display);
  font-size: 17px; line-height: 1;
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
}
.brand-txt { display: inline-flex; align-items: baseline; gap: 6px; }
.brand-txt b { font-family: var(--font-display); font-size: 18px; font-weight: 700; letter-spacing: .02em; }
.brand-txt span { font-size: 12.5px; color: var(--ink-mute); letter-spacing: .12em; }
.nav { display: flex; gap: 26px; }
.nav a {
  font-size: 14px; color: var(--ink-soft); letter-spacing: .01em;
  padding: 6px 0; position: relative;
}
.nav a::after {
  content: ''; position: absolute; left: 0; right: 100%; bottom: 2px; height: 1px;
  background: var(--accent); transition: right .25s ease;
}
.nav a:hover { color: var(--ink); }
.nav a:hover::after { right: 0; }

/* ---------- 4. 히어로 ---------- */
.hero { padding: 76px 0 56px; }
.hero-grid {
  display: grid; grid-template-columns: 1.15fr .85fr;
  gap: 56px; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent); font-weight: 600;
}
.eyebrow .dot {
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.hero h1 {
  margin: 18px 0 20px;
  font-size: clamp(2.15rem, 5.2vw, 3.5rem);
  font-weight: 700; line-height: 1.22;
}
.hero h1 em {
  font-style: normal; position: relative; color: var(--accent);
  background-image: linear-gradient(var(--accent-soft), var(--accent-soft));
  background-repeat: no-repeat; background-size: 100% 26%; background-position: 0 88%;
  padding: 0 .08em;
}
.lead { color: var(--ink-soft); font-size: 16.5px; max-width: 33em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-meta {
  display: flex; flex-wrap: wrap; gap: 18px; margin-top: 26px;
  font-size: 13px; color: var(--ink-mute);
}
.hero-meta li { display: inline-flex; align-items: center; gap: 7px; }
.hero-meta li::before {
  content: ''; width: 4px; height: 4px; border-radius: 50%; background: var(--ink-mute); opacity: .6;
}

.hero-visual { position: relative; display: grid; place-items: center; }
.hero-visual::before {
  content: ''; position: absolute; inset: -12% -6%;
  background: radial-gradient(circle at 45% 45%, var(--accent-soft), transparent 62%);
  opacity: .8; filter: blur(6px); z-index: 0;
}
.sample-card {
  position: relative; z-index: 1;
  width: 100%; max-width: 350px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--r-l);
  padding: 20px 22px 18px;
  box-shadow: var(--shadow-l);
  transform: rotate(-1.4deg);
}
.sample-top {
  display: flex; flex-direction: column; gap: 3px;
  font-size: 11px; letter-spacing: .12em; color: var(--ink-mute);
  padding-bottom: 14px; border-bottom: 1px solid var(--line-soft);
}
.sample-top span:last-child {
  font-family: var(--font-display); letter-spacing: .06em; color: var(--ink-soft); font-size: 12px;
}
.sample-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 16px 0 12px;
}
.sample-col {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  border-right: 1px solid var(--line-soft);
}
.sample-col:last-child { border-right: 0; }
.sc-label { font-size: 10.5px; color: var(--ink-mute); letter-spacing: .1em; margin-bottom: 4px; }
.sc-char {
  font-family: var(--font-display);
  font-size: 26px; line-height: 1.32; font-weight: 600;
}
.sample-foot {
  display: flex; align-items: center; gap: 6px;
  padding-top: 12px; border-top: 1px solid var(--line-soft);
}
.mini-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.sample-foot-txt { margin-left: 10px; font-size: 10.5px; letter-spacing: .12em; color: var(--ink-mute); }
.stamp {
  position: absolute; z-index: 2; right: 2%; bottom: -14px;
  width: 52px; height: 52px; display: grid; place-items: center;
  background: var(--accent); color: #FBF7EF;
  font-family: var(--font-display); font-size: 26px;
  border-radius: 6px; transform: rotate(6deg);
  box-shadow: var(--shadow-m); opacity: .95;
}

/* 오행 색 */
.e-wood { color: var(--e-wood); }
.e-fire { color: var(--e-fire); }
.e-earth { color: var(--e-earth); }
.e-metal { color: var(--e-metal); }
.e-water { color: var(--e-water); }
.mini-dot.e-wood, .dot-wood { background: var(--e-wood); }
.mini-dot.e-fire, .dot-fire { background: var(--e-fire); }
.mini-dot.e-earth, .dot-earth { background: var(--e-earth); }
.mini-dot.e-metal, .dot-metal { background: var(--e-metal); }
.mini-dot.e-water, .dot-water { background: var(--e-water); }

/* ---------- 5. 섹션 공통 ---------- */
.section { padding: 84px 0; }
.section-head { margin-bottom: 34px; }
.section-head .num {
  display: block;
  font-family: var(--font-display); font-size: 12px; letter-spacing: .22em;
  color: var(--accent); margin-bottom: 10px;
}
.section-head h2 { font-size: clamp(1.55rem, 3.4vw, 2.15rem); }
.section-head p { margin-top: 10px; color: var(--ink-soft); max-width: 46em; }

/* ---------- 6. 버튼 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-body); font-size: 15px; font-weight: 600;
  padding: 13px 22px; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  text-align: center;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--ink); color: var(--paper); box-shadow: var(--shadow-m); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: var(--shadow-l); }
.btn-accent { background: var(--accent); color: #FBF7EF; box-shadow: var(--shadow-m); }
.btn-accent:hover { transform: translateY(-1px); }
.btn-outline { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-outline:hover { border-color: var(--ink); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink-soft); }
.btn-ghost:hover { color: var(--ink); border-color: var(--ink-mute); }
.btn-lg { width: 100%; padding: 17px 24px; font-size: 16px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- 7. 계산기 폼 ---------- */
.calc-card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--r-l);
  padding: 30px 32px 24px;
  box-shadow: var(--shadow-m);
  max-width: 760px;
}
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; min-width: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field label, .field .label {
  font-size: 13px; font-weight: 600; color: var(--ink-soft); letter-spacing: .01em;
}
.opt {
  font-weight: 500; font-size: 11px; color: var(--ink-mute);
  border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; margin-left: 3px;
  vertical-align: 1px;
}
input[type="text"], select {
  width: 100%; height: 48px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-s);
  padding: 0 14px;
  color: var(--ink); font-family: var(--font-body); font-size: 15px;
  transition: border-color .18s ease, box-shadow .18s ease;
  appearance: none; -webkit-appearance: none;
}
input[type="text"]::placeholder { color: var(--ink-mute); }
input[type="text"]:focus, select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' viewBox='0 0 14 8'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%23838C92' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}
.select-wrap { position: relative; display: flex; align-items: center; }
.select-wrap .unit {
  position: absolute; right: 34px; font-size: 13px; color: var(--ink-mute); pointer-events: none;
}
.date-row { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; }
.date-row select { padding-left: 12px; }

.segmented {
  display: inline-flex; padding: 3px; gap: 2px;
  background: var(--paper-3); border: 1px solid var(--line);
  border-radius: 11px; height: 48px;
}
.segmented label { flex: 1; display: flex; }
.segmented input { position: absolute; opacity: 0; pointer-events: none; }
.segmented span {
  flex: 1; display: grid; place-items: center;
  padding: 0 16px; border-radius: 8px;
  font-size: 14px; color: var(--ink-soft); cursor: pointer;
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
  white-space: nowrap;
}
.segmented input:checked + span {
  background: var(--paper-2); color: var(--ink); font-weight: 600;
  box-shadow: var(--shadow-s), inset 0 0 0 1px var(--line);
}
.segmented input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.check {
  display: inline-flex; align-items: center; gap: 9px; height: 48px;
  font-size: 14px; color: var(--ink-soft); cursor: pointer;
}
.check input {
  appearance: none; -webkit-appearance: none;
  width: 20px; height: 20px; border: 1px solid var(--line); border-radius: 6px;
  background: var(--paper); cursor: pointer; position: relative; transition: background .15s ease, border-color .15s ease;
}
.check input:checked { background: var(--accent); border-color: var(--accent); }
.check input:checked::after {
  content: ''; position: absolute; left: 6px; top: 2.5px;
  width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(43deg);
}
.hint { font-size: 12.5px; color: var(--ink-mute); line-height: 1.6; }
.form-error {
  background: var(--accent-soft); color: var(--accent);
  border-radius: var(--r-s); padding: 11px 14px; font-size: 13.5px; margin-bottom: 16px;
}
.privacy-note { text-align: center; font-size: 12px; color: var(--ink-mute); margin-top: 12px; }

/* ---------- 8. 결과 ---------- */
.result-section {
  background: linear-gradient(180deg, transparent, var(--paper-3) 12%, var(--paper-3) 88%, transparent);
  padding-top: 70px;
}
.result-head { text-align: center; margin-bottom: 30px; }
.result-head h2 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); margin: 12px 0 8px; }
.result-sub { color: var(--ink-soft); font-size: 14.5px; line-height: 1.7; }
.result-sub .dot-sep { margin: 0 .45em; color: var(--ink-mute); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 16px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; color: var(--ink-soft);
  background: var(--paper-2); border: 1px solid var(--line);
  padding: 5px 12px; border-radius: 999px;
}
.chip .dt { width: 7px; height: 7px; border-radius: 50%; }

.pillars-wrap { margin-bottom: 26px; }
.pillars {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--paper-2);
  border: 1px solid var(--line); border-radius: var(--r-l);
  overflow: hidden; box-shadow: var(--shadow-m);
}
.pillar {
  padding: 18px 10px 16px;
  border-right: 1px solid var(--line-soft);
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  min-width: 0;
}
.pillar:last-child { border-right: 0; }
.pillar.is-day { background: var(--accent-soft); }
.pillar-label { font-size: 11px; letter-spacing: .14em; color: var(--ink-mute); }
.pillar.is-day .pillar-label { color: var(--accent); font-weight: 600; }
.char {
  width: 100%; max-width: 84px;
  border-radius: 12px; padding: 8px 4px 7px;
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  border: 1px solid transparent;
}
.char-hanja { font-family: var(--font-display); font-size: 32px; line-height: 1.2; font-weight: 600; }
.char-kr { font-size: 11px; color: var(--ink-mute); letter-spacing: .08em; }
.char-elem { font-size: 10.5px; letter-spacing: .06em; margin-top: 2px; }
.char.t-wood { background: var(--t-wood); }
.char.t-fire { background: var(--t-fire); }
.char.t-earth { background: var(--t-earth); }
.char.t-metal { background: var(--t-metal); }
.char.t-water { background: var(--t-water); }
.pillar-sipsung {
  font-size: 11px; color: var(--ink-soft);
  border: 1px solid var(--line); border-radius: 999px; padding: 2px 9px;
  background: var(--paper);
}
.pillar.is-day .pillar-sipsung { border-color: var(--accent); color: var(--accent); }
.pillar-empty { color: var(--ink-mute); font-size: 13px; padding: 22px 0; }
.pillar-note { text-align: center; font-size: 12.5px; color: var(--ink-mute); margin-top: 12px; }

.result-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 18px; margin-bottom: 18px; }
.card {
  background: var(--paper-2); border: 1px solid var(--line);
  border-radius: var(--r-l); padding: 24px 26px;
  box-shadow: var(--shadow-s);
  min-width: 0;
}
.card-head { margin-bottom: 18px; }
.card-head h3 { font-size: 17px; }
.card-head p { font-size: 12.5px; color: var(--ink-mute); margin-top: 4px; }

.ohang-body { display: flex; align-items: center; gap: 22px; }
.donut-wrap { position: relative; width: 168px; height: 168px; flex: none; }
.donut { width: 100%; height: 100%; transform: rotate(-90deg); }
.donut-track { fill: none; stroke: var(--line-soft); stroke-width: 22; }
.donut-seg { fill: none; stroke-width: 22; stroke-linecap: butt; transition: stroke-dasharray .7s cubic-bezier(.2, .7, .3, 1); }
.donut-center {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 0;
}
.dc-num { font-family: var(--font-display); font-size: 28px; font-weight: 600; line-height: 1; }
.dc-label { font-size: 10.5px; letter-spacing: .16em; color: var(--ink-mute); margin-top: 4px; }
.ohang-bars { flex: 1; display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.ohang-bar { display: grid; grid-template-columns: 46px 1fr 30px; align-items: center; gap: 10px; }
.ob-name { font-size: 12.5px; color: var(--ink-soft); display: flex; align-items: center; gap: 6px; }
.ob-name .dt { width: 7px; height: 7px; border-radius: 50%; }
.ob-track { height: 7px; background: var(--line-soft); border-radius: 999px; overflow: hidden; }
.ob-fill { display: block; height: 100%; border-radius: 999px; width: 0; transition: width .7s cubic-bezier(.2, .7, .3, 1); }
.ob-num { font-size: 12.5px; color: var(--ink-mute); text-align: right; font-variant-numeric: tabular-nums; }

.daewoon-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.dw-item {
  border: 1px solid var(--line-soft); border-radius: 12px;
  padding: 10px 6px 9px; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  background: var(--paper);
}
.dw-age { font-size: 10.5px; color: var(--ink-mute); }
.dw-hanja { font-family: var(--font-display); font-size: 19px; font-weight: 600; letter-spacing: .02em; }
.dw-sipsung { font-size: 10px; color: var(--ink-mute); }
.daewoon-note { font-size: 11.5px; color: var(--ink-mute); margin-top: 14px; line-height: 1.6; }

/* 풀이 */
.reading { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.reading .card { padding: 26px 28px; }
.read-label {
  display: inline-block; font-size: 11px; letter-spacing: .14em; color: var(--accent);
  margin-bottom: 8px;
}
.reading h3 { font-size: 19px; margin-bottom: 12px; }
.reading p { color: var(--ink-soft); font-size: 14.8px; line-height: 1.8; }
.read-bullets { margin-top: 14px; display: flex; flex-direction: column; gap: 7px; }
.read-bullets li {
  position: relative; padding-left: 13px; font-size: 13.5px; color: var(--ink-soft);
}
.read-bullets li::before {
  content: ''; position: absolute; left: 0; top: .72em;
  width: 4px; height: 4px; border-radius: 50%; background: var(--accent); opacity: .7;
}
.reading .span-2 { grid-column: span 2; }

.year-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 16px; }
.year-card {
  border: 1px solid var(--line); border-radius: 14px; padding: 14px 15px;
  background: var(--paper);
}
.year-top { display: flex; align-items: baseline; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.year-num { font-family: var(--font-display); font-size: 17px; font-weight: 600; }
.year-hanja { font-family: var(--font-display); font-size: 13px; color: var(--ink-mute); }
.year-badge {
  font-size: 10.5px; padding: 1px 7px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--ink-soft); margin-left: auto;
}
.year-title { font-size: 13.5px; font-weight: 600; color: var(--ink); margin-bottom: 3px; }
.year-text { font-size: 12.5px; color: var(--ink-soft); line-height: 1.65; }
.year-tag { font-size: 11.5px; color: var(--ink-mute); margin-top: 7px; }

.result-cta {
  margin-top: 22px; padding: 26px 30px;
  border-radius: var(--r-l);
  background: var(--cta-bg);
  color: var(--cta-fg);
  display: flex; align-items: center; justify-content: space-between; gap: 22px;
  flex-wrap: wrap;
}
.result-cta h3 { font-size: 18px; color: var(--cta-fg); }
.result-cta p { font-size: 13.5px; color: var(--cta-fg); opacity: .72; margin-top: 6px; max-width: 38em; }
.disclaimer { text-align: center; font-size: 11.5px; color: var(--ink-mute); margin-top: 26px; }

/* ---------- 9. 리포트 ---------- */
.reports { background: linear-gradient(180deg, transparent, var(--paper-3) 10%, var(--paper-3) 90%, transparent); }
.report-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: stretch; }
.report-card {
  position: relative; display: flex; flex-direction: column;
  background: var(--paper-2); border: 1px solid var(--line);
  border-radius: var(--r-l); padding: 26px 24px 22px;
  box-shadow: var(--shadow-s);
  transition: transform .2s ease, box-shadow .2s ease;
}
.report-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-m); }
.report-card.is-featured { border-color: var(--accent); box-shadow: var(--shadow-m); }
.badge {
  position: absolute; top: -11px; left: 22px;
  background: var(--accent); color: #FBF7EF;
  font-size: 11px; letter-spacing: .06em; font-weight: 600;
  padding: 3px 10px; border-radius: 999px;
}
.report-card h3 { font-size: 18.5px; line-height: 1.4; margin-bottom: 8px; }
.report-meta { font-size: 12px; color: var(--ink-mute); }
.price { margin: 14px 0 16px; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.price strong { font-family: var(--font-display); font-size: 25px; font-weight: 700; color: var(--ink); letter-spacing: -.01em; }
.price s { font-size: 13px; }
.report-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.report-list li {
  position: relative; padding-left: 18px; font-size: 13.5px; color: var(--ink-soft); line-height: 1.55;
}
.report-list li::before {
  content: ''; position: absolute; left: 2px; top: .58em;
  width: 9px; height: 5px; border-left: 1.5px solid var(--accent); border-bottom: 1.5px solid var(--accent);
  transform: rotate(-45deg);
}
.report-for {
  font-size: 12.5px; color: var(--ink-mute); line-height: 1.6;
  padding: 12px 0 18px; margin-top: auto;
  border-top: 1px dashed var(--line);
}

.toc { margin-top: 26px; background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r-l); padding: 24px 26px; }
.toc-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.toc-head h3 { font-size: 16px; }
.toc-tabs { display: inline-flex; gap: 4px; background: var(--paper-3); padding: 3px; border-radius: 999px; border: 1px solid var(--line); }
.toc-tab {
  border: 0; background: transparent; padding: 7px 15px; border-radius: 999px;
  font-size: 12.5px; color: var(--ink-soft); cursor: pointer; white-space: nowrap;
}
.toc-tab.is-active { background: var(--ink); color: var(--paper); font-weight: 600; }
.toc-panel { display: none; }
.toc-panel.is-active { display: block; }
.toc-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 26px; }
.toc-list li {
  display: grid; grid-template-columns: 26px 1fr; gap: 10px;
  font-size: 13.5px; color: var(--ink-soft); padding: 7px 0;
  border-bottom: 1px solid var(--line-soft);
}
.toc-list .toc-no { font-family: var(--font-display); font-size: 12px; color: var(--accent); }
.toc-list small { display: block; font-size: 12px; color: var(--ink-mute); margin-top: 2px; }

/* ---------- 10. FAQ ---------- */
.faq-list { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 19px 4px; font-size: 15px; font-weight: 600; color: var(--ink);
  font-family: var(--font-body);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+'; font-family: var(--font-body); font-weight: 400; font-size: 20px;
  color: var(--accent); line-height: 1; margin-top: 2px; transition: transform .2s ease;
  flex: none;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-body { padding: 0 4px 20px; }
.faq-body p { font-size: 14px; color: var(--ink-soft); max-width: 60em; }

/* ---------- 11. 푸터 ---------- */
.site-foot {
  border-top: 1px solid var(--line);
  background: var(--paper-3);
  padding: 48px 0 calc(24px + env(safe-area-inset-bottom));
  margin-top: 20px;
}
.foot-grid { display: grid; grid-template-columns: 1.4fr .8fr .9fr 1.1fr; gap: 30px; }
.foot-brand p { font-size: 13px; color: var(--ink-mute); margin-top: 12px; line-height: 1.7; }
.foot-col h4 { font-size: 12px; letter-spacing: .12em; color: var(--ink-mute); margin-bottom: 12px; font-family: var(--font-body); font-weight: 600; }
.foot-col a, .foot-col p { display: block; font-size: 13px; color: var(--ink-soft); line-height: 1.8; }
.foot-col a:hover { color: var(--accent); }
.foot-info p { font-size: 12px; line-height: 1.8; color: var(--ink-mute); }
.foot-bottom {
  margin-top: 36px; padding-top: 18px; border-top: 1px solid var(--line-soft);
  display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  font-size: 11.5px; color: var(--ink-mute);
}

/* ---------- 12. 모달 ---------- */
.modal { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-end; justify-content: center; }
.modal[hidden] { display: none; }
.modal-backdrop {
  position: absolute; inset: 0; background: rgba(24, 20, 14, .5);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  animation: fade .2s ease;
}
.modal-panel {
  position: relative; width: 100%; max-width: 560px;
  max-height: 92vh; overflow-y: auto; overscroll-behavior: contain;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 22px 22px 0 0;
  padding: 26px 24px calc(26px + env(safe-area-inset-bottom));
  box-shadow: var(--shadow-l);
  animation: rise .28s cubic-bezier(.2, .8, .3, 1);
}
@media (min-width: 720px) {
  .modal { align-items: center; }
  .modal-panel { border-radius: 22px; padding-bottom: 26px; max-height: 88vh; }
}
@keyframes rise { from { transform: translateY(22px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.modal-x {
  position: absolute; top: 14px; right: 14px;
  width: 34px; height: 34px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 50%; background: var(--paper);
  cursor: pointer; color: var(--ink-soft);
}
.modal-x svg { width: 16px; height: 16px; }
.modal-x:hover { color: var(--ink); }

.modal-head { margin-bottom: 20px; padding-right: 34px; }
.modal-head .eyebrow { font-size: 11px; }
.modal-head h3 { font-size: 21px; margin: 8px 0 6px; }
.modal-head p { font-size: 13px; color: var(--ink-mute); }

.prod-pick { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.prod-opt {
  display: flex; align-items: flex-start; gap: 12px;
  border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px;
  cursor: pointer; background: var(--paper);
  transition: border-color .15s ease, background .15s ease;
}
.prod-opt input { position: absolute; opacity: 0; pointer-events: none; }
.prod-opt .po-radio {
  width: 17px; height: 17px; border-radius: 50%; border: 1px solid var(--ink-mute); flex: none;
  position: relative; margin-top: 3px;
}
.prod-opt input:checked ~ .po-radio { border-color: var(--accent); }
.prod-opt input:checked ~ .po-radio::after {
  content: ''; position: absolute; inset: 3px; border-radius: 50%; background: var(--accent);
}
.prod-opt:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.po-body { flex: 1; min-width: 0; }
.po-name { font-size: 13.5px; font-weight: 600; display: block; }
.po-meta { font-size: 11.5px; color: var(--ink-mute); }
.po-price { font-family: var(--font-display); font-size: 15px; font-weight: 600; white-space: nowrap; margin-top: 1px; }

.mfield { margin-bottom: 14px; }
.mfield label { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-soft); margin-bottom: 6px; }
.mfield input, .mfield textarea {
  width: 100%; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-s);
  padding: 12px 13px; font-family: var(--font-body); font-size: 14px; color: var(--ink);
}
.mfield textarea { min-height: 84px; resize: vertical; line-height: 1.6; }
.mfield input:focus, .mfield textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft);
}
.mfield .ro {
  background: var(--paper-3); color: var(--ink-soft); font-size: 13px;
  border-radius: var(--r-s); padding: 11px 13px; border: 1px solid transparent;
  white-space: pre-line; line-height: 1.7;
}
.mrow { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mnote {
  font-size: 11.5px; color: var(--ink-mute); line-height: 1.65;
  background: var(--paper-3); border-radius: var(--r-s); padding: 11px 13px; margin: 4px 0 16px;
}
.merror { color: var(--accent); font-size: 12.5px; margin-top: 8px; }

.summary-box {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-m);
  padding: 16px; margin-bottom: 16px;
}
.summary-box pre {
  margin: 0; font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px; line-height: 1.8; white-space: pre-wrap; color: var(--ink-soft);
}
.success-mark {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); margin-bottom: 14px;
}
.success-mark svg { width: 24px; height: 24px; }
.modal-actions { display: flex; flex-direction: column; gap: 8px; }

/* ---------- 13. 토스트 ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(26px + env(safe-area-inset-bottom));
  transform: translateX(-50%) translateY(10px);
  background: var(--ink); color: var(--paper);
  font-size: 13px; padding: 11px 18px; border-radius: 999px;
  box-shadow: var(--shadow-l); z-index: 80; opacity: 0;
  transition: opacity .2s ease, transform .2s ease;
  max-width: calc(100% - 32px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 14. 등장 애니메이션 ---------- */
.reveal { animation: fadeUp .5s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* ---------- 15. 반응형 ---------- */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 34px; }
  .hero-visual { order: -1; }
  .sample-card { transform: rotate(-1deg); max-width: 320px; }
  .sample-foot-txt { display: none; }
  .result-grid { grid-template-columns: 1fr; }
  .reading { grid-template-columns: 1fr; }
  .reading .span-2 { grid-column: auto; }
  .report-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 15.5px; }
  .wrap { padding: 0 18px; }
  .head-inner { height: 58px; }
  .nav { gap: 14px; }
  .nav a { font-size: 13px; }
  .brand-txt span { display: none; }
  .hero { padding: 40px 0 34px; }
  .hero h1 { margin: 14px 0 14px; }
  .lead { font-size: 15.5px; }
  .section { padding: 60px 0; }
  .calc-card { padding: 22px 18px 18px; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .date-row { grid-template-columns: 1.25fr 1fr 1fr; gap: 8px; }
  .date-row select { padding-left: 10px; padding-right: 32px; font-size: 14px; background-position: right 10px center; }

  .pillars { border-radius: var(--r-m); }
  .pillar { padding: 14px 5px 13px; gap: 7px; }
  .char { max-width: 68px; padding: 6px 2px; }
  .char-hanja { font-size: 24px; }
  .char-kr { font-size: 10px; }
  .pillar-sipsung { font-size: 10px; padding: 1px 6px; }
  .card { padding: 20px 18px; }
  .ohang-body { gap: 14px; }
  .donut-wrap { width: 128px; height: 128px; }
  .dc-num { font-size: 22px; }
  .ohang-bar { grid-template-columns: 40px 1fr 24px; gap: 8px; }
  .year-grid { grid-template-columns: 1fr; }
  .result-cta { padding: 22px 20px; }
  .toc-list { grid-template-columns: 1fr; }
  .toc-head { align-items: flex-start; }
  .foot-grid { grid-template-columns: 1fr; gap: 24px; }
  .foot-bottom { flex-direction: column; }
  .mrow { grid-template-columns: 1fr; }
  .hero-meta { gap: 12px; font-size: 12px; }
  .result-sub .date-part { display: block; }
  .result-sub .dot-sep { display: none; }
}
