/* 명식 命式 — 화면 시안의 토큰을 그대로 옮겼다.
   규칙: UI 크롬은 먹빛·한지 무채색. 채도는 오행에만 준다. */

:root {
  --paper:     #EDECE8;
  --surface:   #F8F8F6;
  --surface-2: #E2E1DA;
  /* 본문 대비를 올렸다. 이전 값(#56564E/#8B8A80)은 모바일 야외에서 너무 흐렸다. */
  --ink:       #14140F;
  --ink-2:     #3A3A33;
  --ink-3:     #66655C;
  --rule:      #CBCAC1;
  --rule-soft: #DBDAD2;

  --wood:  #2C7A57;
  --fire:  #BC4034;
  --earth: #A2761A;
  --metal: #64707E;
  --water: #2E4A75;

  --wood-bg:  #2c7a5714;
  --fire-bg:  #bc403414;
  --earth-bg: #a2761a14;
  --metal-bg: #64707e14;
  --water-bg: #2e4a7514;

  --year: var(--fire);
  --year-bg: var(--fire-bg);

  --sans: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", Pretendard, "Malgun Gothic", "Noto Sans KR", system-ui, sans-serif;
  --myeongjo: "AppleMyungjo", "Nanum Myeongjo", "Noto Serif KR", Batang, 바탕, "Songti SC", SimSun, serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --shadow: 0 1px 2px #1b1b1810, 0 8px 24px #1b1b180d;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #121311;  --surface: #1B1C19;  --surface-2: #272824;
    --ink: #F2F1EB;    --ink-2: #C6C5BB;    --ink-3: #979589;
    --rule: #3B3C35;   --rule-soft: #2C2D28;
    --wood: #5CBE8C;   --fire: #EE7A6E;     --earth: #DDAE4D;
    --metal: #A6B2C1;  --water: #7FA5DE;
    --wood-bg: #5cbe8c1a; --fire-bg: #ee7a6e1a; --earth-bg: #ddae4d1a;
    --metal-bg: #a6b2c11a; --water-bg: #7fa5de1a;
    --shadow: 0 1px 2px #00000040, 0 8px 24px #00000030;
  }
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

.shell { max-width: 460px; margin: 0 auto; min-height: 100vh; background: var(--surface); }

.appbar {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 18px 20px 14px; border-bottom: 1px solid var(--rule-soft);
  position: sticky; top: 0; background: var(--surface); z-index: 5;
}
.wordmark { font-family: var(--myeongjo); font-size: 18px; letter-spacing: .02em; }
.wordmark small { font-size: 11px; color: var(--ink-3); margin-left: 5px; letter-spacing: .06em; }
.appbar .step { font-family: var(--mono); font-size: 11px; color: var(--ink-3); letter-spacing: .06em; }

.body { padding: 22px 20px 60px; display: flex; flex-direction: column; gap: 22px; }

.screen { display: none; flex-direction: column; gap: 22px; }
.screen.is-active { display: flex; }

/* ─── 입력 ─────────────────────────────────────── */

.lede { font-family: var(--myeongjo); font-size: 22px; line-height: 1.45; margin: 0; text-wrap: balance; }
.sub { margin: -14px 0 0; color: var(--ink-2); font-size: 14.5px; }

.field { display: flex; flex-direction: column; gap: 7px; }
.field > label, .field > .legend { font-size: 13px; font-weight: 600; letter-spacing: .01em; color: var(--ink-2); }
.field .opt { color: var(--ink-3); }

.input, .segmented, select.input {
  background: var(--paper); border: 1px solid var(--rule); border-radius: 9px;
}
.input {
  font: inherit; color: var(--ink); padding: 12px 13px; width: 100%;
  font-variant-numeric: tabular-nums; appearance: none;
}
.input::placeholder { color: var(--ink-3); }
select.input { padding-right: 30px; }

.row { display: flex; gap: 10px; }
.row > * { flex: 1; min-width: 0; }

.segmented { display: flex; padding: 3px; gap: 3px; }
.segmented button {
  appearance: none; border: 0; background: transparent; color: var(--ink-2);
  font: inherit; font-size: 13.5px; padding: 9px 4px; flex: 1; border-radius: 6px; cursor: pointer;
  transition: background .16s ease, color .16s ease;
}
.segmented button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }

.hint {
  display: flex; gap: 9px; align-items: flex-start;
  font-size: 12.5px; line-height: 1.55; color: var(--ink-2);
  background: var(--water-bg); border-left: 2px solid var(--water);
  padding: 10px 12px; border-radius: 0 7px 7px 0;
}
.hint b { color: var(--ink); font-weight: 600; }

.checkline { display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.checkline input { accent-color: var(--ink); width: 15px; height: 15px; }

.cta {
  appearance: none; border: 0; width: 100%;
  background: var(--ink); color: var(--paper);
  font: inherit; font-size: 15px; font-weight: 600; padding: 15px; border-radius: 10px; cursor: pointer;
  transition: transform .12s ease, opacity .16s ease;
}
.cta:hover { opacity: .88; }
.cta:active { transform: translateY(1px); }
.cta[disabled] { opacity: .45; cursor: default; transform: none; }
.cta.ghost { background: transparent; color: var(--ink); border: 1px solid var(--rule); }

.err {
  font-size: 13px; color: var(--fire); background: var(--fire-bg);
  border-left: 2px solid var(--fire); padding: 10px 12px; border-radius: 0 7px 7px 0;
}

/* ─── 오늘 ─────────────────────────────────────── */

.today {
  background: var(--paper); border: 1px solid var(--rule); border-radius: 13px;
  padding: 13px 15px; display: flex; gap: 13px; align-items: flex-start;
}
.today-pillar { flex: none; width: 42px; text-align: center; border-right: 1px solid var(--rule-soft); padding-right: 12px; }
.today-pillar .g { font-family: var(--myeongjo); font-size: 21px; line-height: 1.2; display: block; }
.today-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.today-date { font-family: var(--mono); font-size: 10.5px; letter-spacing: .1em; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.today-line { font-size: 14.5px; line-height: 1.65; text-wrap: pretty; }

/* ─── 명식 ─────────────────────────────────────── */

.chart { background: var(--paper); border: 1px solid var(--rule); border-radius: 14px; overflow: hidden; }
.chart-head {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 13px 15px 11px; border-bottom: 1px solid var(--rule); gap: 10px;
}
.chart-head .who { font-size: 13px; color: var(--ink-2); }
.chart-head .who b { color: var(--ink); font-weight: 600; }
.chart-head .when { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; text-align: right; }

table.pillars { width: 100%; border-collapse: collapse; text-align: center; }
table.pillars th {
  font-size: 11px; font-weight: 500; letter-spacing: .08em; color: var(--ink-3);
  padding: 9px 0 7px; border-bottom: 1px solid var(--rule-soft);
}
table.pillars td { padding: 0; vertical-align: middle; }
table.pillars .rowlabel {
  font-size: 10px; color: var(--ink-3); letter-spacing: .1em; width: 34px;
  writing-mode: vertical-rl; padding: 8px 0;
}
.glyph { font-family: var(--myeongjo); font-size: 30px; line-height: 1.15; display: block; padding-top: 10px; }
/* 한자 아래 한글 독음 — 한자를 못 읽어도 무엇인지 알 수 있게 */
.glyph-ko {
  display: block; font-size: 11.5px; font-weight: 600; color: var(--ink-2);
  letter-spacing: .02em; margin-top: 2px;
}
.tenGod { font-size: 11.5px; color: var(--ink-3); display: block; padding: 3px 0 11px; letter-spacing: .04em; }
.cell-daymaster { background: var(--surface-2); }
.cell-daymaster .tenGod { color: var(--ink-2); font-weight: 600; }

.e-wood { color: var(--wood); }
.e-fire { color: var(--fire); }
.e-earth { color: var(--earth); }
.e-metal { color: var(--metal); }
.e-water { color: var(--water); }

.tally { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--rule); }
.tally div { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 11px 0 12px; }
.tally div + div { border-left: 1px solid var(--rule-soft); }
.tally .el { font-size: 14px; font-weight: 600; display: flex; align-items: baseline; gap: 2px; }
.tally .el small { font-family: var(--myeongjo); font-size: 11px; opacity: .55; font-weight: 400; }
.tally .n { font-family: var(--mono); font-size: 15px; font-variant-numeric: tabular-nums; line-height: 1; }
.tally .bar { width: 26px; height: 3px; border-radius: 2px; background: currentColor; }
.tally .bar.zero { background: transparent; box-shadow: inset 0 0 0 1px var(--rule); }
.tally .zeroed { color: var(--ink-3); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chart .chips { padding: 0 15px 14px; }
.chip { font-size: 12.5px; font-weight: 500; padding: 4px 9px; border-radius: 999px; border: 1px solid currentColor; letter-spacing: .02em; }
.chip.plain { color: var(--ink-2); border-color: var(--rule); }

.warnbox {
  font-size: 12px; line-height: 1.55; color: var(--ink-2);
  background: var(--earth-bg); border-left: 2px solid var(--earth);
  padding: 10px 12px; border-radius: 0 7px 7px 0;
  display: flex; flex-direction: column; gap: 5px;
}
.warnbox b { color: var(--ink); }

/* ─── 세운 ─────────────────────────────────────── */

.sectionhead { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.sectionhead h2 { margin: 0; font-family: var(--myeongjo); font-size: 18px; font-weight: 500; }
.sectionhead span { font-size: 11.5px; color: var(--ink-3); }

.yearcard {
  background: var(--year-bg); border: 1px solid var(--rule); border-radius: 14px;
  padding: 15px; display: flex; flex-direction: column; gap: 13px;
}
.year-top { display: flex; gap: 14px; align-items: stretch; }
.year-pillar {
  flex: none; width: 62px; background: var(--paper); border: 1px solid var(--rule);
  border-radius: 10px; text-align: center; display: flex; flex-direction: column; justify-content: center;
}
.year-pillar .glyph { padding-top: 8px; font-size: 27px; }
.year-pillar .tenGod { padding-bottom: 8px; }
.year-pillar .divider { height: 1px; background: var(--rule-soft); margin: 0 8px; }
.year-meta { display: flex; flex-direction: column; gap: 5px; min-width: 0; justify-content: center; }
.year-num { font-family: var(--mono); font-size: 22px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; line-height: 1; color: var(--year); }
.year-name { font-size: 17px; font-weight: 600; display: flex; align-items: baseline; gap: 5px; }
.year-name small { font-family: var(--myeongjo); font-size: 13px; font-weight: 400; opacity: .7; }
.yearcard > p { margin: 0; font-size: 15px; line-height: 1.75; text-wrap: pretty; }

.months-wrap { display: flex; flex-direction: column; gap: 9px; }
.months { display: flex; gap: 5px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.m {
  flex: none; width: 46px; background: var(--paper); border: 1px solid var(--rule);
  border-radius: 8px; padding: 7px 0 0; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 1px;
}
.m.hi { background: var(--surface-2); border-color: var(--ink-3); }
.m .mn { font-family: var(--mono); font-size: 9.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.m .mg { font-family: var(--myeongjo); font-size: 14px; line-height: 1.25; }
.m .mko { font-size: 10px; font-weight: 600; color: var(--ink-2); margin-top: 1px; }
.m .mbar { width: 100%; height: 3px; margin-top: 5px; background: currentColor; border-radius: 0 0 7px 7px; }

/* ─── 분야 카드 ─────────────────────────────────── */

.cards { display: flex; flex-direction: column; gap: 11px; }

details.card { background: var(--paper); border: 1px solid var(--rule); border-radius: 13px; overflow: hidden; }
details.card[open] { background: var(--surface-2); }
details.card.locked { opacity: .96; }

summary.card-head {
  list-style: none; cursor: pointer; padding: 15px 15px 14px;
  display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: start;
}
summary.card-head::-webkit-details-marker { display: none; }

.card-title { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.card-kicker { font-size: 10.5px; letter-spacing: .1em; }
.card-title h3 { margin: 0; font-family: var(--myeongjo); font-size: 19px; font-weight: 500; letter-spacing: .01em; }
.card-oneline { font-size: 14.5px; color: var(--ink-2); line-height: 1.55; text-wrap: pretty; }

.mini { display: grid; grid-template-columns: repeat(4, 17px); gap: 3px; flex: none; padding-top: 3px; }
.mini span {
  font-family: var(--myeongjo); font-size: 13px; line-height: 17px; text-align: center;
  color: var(--ink-3); opacity: .35; border-radius: 3px;
}
.mini span.lit { opacity: 1; font-weight: 600; }
.mini span.lit.e-wood { background: var(--wood-bg); }
.mini span.lit.e-fire { background: var(--fire-bg); }
.mini span.lit.e-earth { background: var(--earth-bg); }
.mini span.lit.e-metal { background: var(--metal-bg); }
.mini span.lit.e-water { background: var(--water-bg); }

.card-body {
  padding: 14px 15px 16px; display: flex; flex-direction: column; gap: 14px;
  border-top: 1px solid var(--rule-soft); margin-top: 2px;
}
.card-body p { margin: 0; font-size: 15.5px; line-height: 1.75; text-wrap: pretty; }

.subhead {
  font-size: 12px; letter-spacing: .06em; color: var(--ink-2);
  border-top: 1px dashed var(--rule); padding-top: 12px;
}

.why {
  background: var(--surface); border: 1px solid var(--rule-soft); border-radius: 9px;
  padding: 12px 13px; display: flex; flex-direction: column; gap: 8px;
}
.why-label { font-family: var(--mono); font-size: 10px; letter-spacing: .14em; color: var(--ink-3); }
.why ul { margin: 0; padding-left: 15px; display: flex; flex-direction: column; gap: 5px; }
.why li { font-size: 13.5px; line-height: 1.65; color: var(--ink-2); }

.yearblock {
  background: var(--year-bg); border-left: 2px solid var(--year); border-radius: 0 8px 8px 0;
  padding: 11px 13px; display: flex; flex-direction: column; gap: 6px;
}
.yb-label { font-family: var(--mono); font-size: 10px; letter-spacing: .14em; color: var(--year); }
.card-body .yearblock p { font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }

.disclaimer-inline { font-size: 11.5px; color: var(--ink-3); line-height: 1.5; }

.toggle-cue { font-size: 11.5px; color: var(--ink-3); display: flex; align-items: center; gap: 5px; margin-top: 2px; }
.toggle-cue::after {
  content: ""; width: 5px; height: 5px;
  border-right: 1.2px solid currentColor; border-bottom: 1.2px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px); transition: transform .2s ease;
}
details[open] .toggle-cue::after { transform: rotate(-135deg) translate(-1px, -1px); }
details[open] .toggle-cue .cue-open { display: none; }
details:not([open]) .toggle-cue .cue-close { display: none; }

.lockline { font-size: 11.5px; color: var(--ink-3); display: flex; align-items: center; gap: 5px; margin-top: 2px; }

/* ─── 결제 ─────────────────────────────────────── */

.paywall {
  border: 1px solid var(--ink); border-radius: 14px; padding: 18px 16px;
  display: flex; flex-direction: column; gap: 13px; background: var(--paper);
}
.paywall h3 { margin: 0; font-family: var(--myeongjo); font-size: 19px; font-weight: 500; }
.paywall p { margin: 0; font-size: 13px; line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }
.paywall .price {
  font-family: var(--mono); font-size: 27px; font-variant-numeric: tabular-nums;
  letter-spacing: -.02em; line-height: 1;
}
.paywall .price small { font-size: 13px; color: var(--ink-3); margin-left: 4px; letter-spacing: 0; }
.paywall ul { margin: 0; padding-left: 16px; display: flex; flex-direction: column; gap: 4px; }
.paywall li { font-size: 13px; color: var(--ink-2); }
.terms { font-size: 11.5px; color: var(--ink-3); line-height: 1.55; }

.footnote {
  font-size: 12.5px; color: var(--ink-3); line-height: 1.7;
  border-top: 1px solid var(--rule-soft); padding-top: 14px; text-wrap: pretty;
}

.spinner {
  width: 15px; height: 15px; border: 2px solid var(--rule); border-top-color: var(--ink);
  border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; vertical-align: -2px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── 모드 전환 · 폼 ─────────────────────────────── */

.switcher { display: flex; background: var(--surface-2); border-radius: 999px; padding: 3px; gap: 2px; }
.switcher button {
  appearance: none; border: 0; background: transparent; color: var(--ink-2);
  font: inherit; font-size: 13.5px; padding: 9px 18px; border-radius: 999px; cursor: pointer; flex: 1;
  transition: background .18s ease, color .18s ease;
}
.switcher button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }

.pane { display: none; flex-direction: column; gap: 22px; }
.pane.is-active { display: flex; }

.personbox {
  border: 1px solid var(--rule); border-radius: 13px; padding: 15px;
  display: flex; flex-direction: column; gap: 18px; background: var(--paper);
}
.personbox-label {
  font-family: var(--myeongjo); font-size: 15px;
  padding-bottom: 2px; border-bottom: 1px solid var(--rule-soft);
}
.personbox .person { display: contents; }
#form-reading .person { display: flex; flex-direction: column; gap: 22px; }

/* ─── 궁합 ───────────────────────────────────────── */

.pairhead {
  display: flex; align-items: center; gap: 16px;
  border: 1px solid var(--rule); border-radius: 14px; padding: 16px; background: var(--paper);
}
.pair-glyphs { font-family: var(--myeongjo); font-size: 30px; display: flex; gap: 7px; align-items: center; flex: none; }
.pair-dot { color: var(--ink-3); font-size: 18px; }
.pair-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pair-label { font-family: var(--myeongjo); font-size: 19px; line-height: 1.3; text-wrap: balance; }
.pair-names { font-size: 12px; color: var(--ink-3); }

.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.minichart {
  border: 1px solid var(--rule); border-radius: 12px; padding: 12px 10px; background: var(--paper);
  display: flex; flex-direction: column; align-items: center; gap: 9px;
}
.minichart-name {
  font-size: 11.5px; color: var(--ink-2); max-width: 100%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.minichart-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px 2px; width: 100%; }
.minichart-grid .mg { font-family: var(--myeongjo); font-size: 17px; text-align: center; line-height: 1.2; }
.minichart-tally {
  display: flex; gap: 5px; font-family: var(--mono); font-size: 10px;
  font-variant-numeric: tabular-nums; flex-wrap: wrap; justify-content: center;
}
.minichart-tally .zeroed { color: var(--ink-3); opacity: .5; }

.tone-good { color: var(--wood); }
.tone-tension { color: var(--fire); }
.tone-neutral { color: var(--ink-3); }

.tonebar { flex: none; width: 3px; align-self: stretch; border-radius: 2px; background: currentColor; min-height: 34px; }
summary.card-head:has(.tonebar) { grid-template-columns: 1fr 3px; }

a { color: inherit; text-underline-offset: 2px; }

/* ─── 공유 ───────────────────────────────────────── */

.sharebox {
  border: 1px solid var(--rule); border-radius: 13px; padding: 15px;
  display: flex; flex-direction: column; gap: 12px; background: var(--paper);
}
.sharebox-head { display: flex; flex-direction: column; gap: 4px; }
.sharebox h3 { margin: 0; font-family: var(--myeongjo); font-size: 17px; font-weight: 500; }
.sharebox p { margin: 0; font-size: 12.5px; line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }

.share-links { display: flex; gap: 8px; flex-wrap: wrap; }
.share-links > * { flex: 1 1 calc(50% - 4px); }
.sharebtn.kakao {
  background: #FEE500; border-color: #F0D800; color: #191600; font-weight: 600;
}
.sharebtn.kakao:hover { background: #F5DC00; }
.sharebtn {
  flex: 1; appearance: none; border: 1px solid var(--rule); background: var(--surface);
  color: var(--ink); font: inherit; font-size: 13.5px; padding: 11px 8px;
  border-radius: 9px; cursor: pointer; text-align: center; text-decoration: none;
  transition: background .16s ease;
}
.sharebtn:hover { background: var(--surface-2); }
.share-url { font-size: 12.5px; font-family: var(--mono); }
.share-hint { font-size: 11.5px; color: var(--ink-3); line-height: 1.55; }

/* 공유 링크로 들어온 사람이 보는 카드 */
.sharecard {
  border: 1px solid var(--rule); border-radius: 16px; padding: 26px 20px;
  background: var(--paper); display: flex; flex-direction: column;
  align-items: center; gap: 14px; text-align: center;
}
.share-grid { display: grid; grid-template-columns: repeat(4, 42px); gap: 6px 4px; }
.share-grid span { font-family: var(--myeongjo); font-size: 30px; line-height: 1.2; }
.share-grid .ko { font-family: var(--sans); font-size: 11px; font-weight: 600; color: var(--ink-2); line-height: 1.4; }
.share-pair { display: flex; align-items: center; gap: 12px; font-family: var(--myeongjo); font-size: 40px; }
.share-pair i { font-style: normal; font-size: 20px; color: var(--ink-3); }
.share-badge {
  font-size: 11.5px; color: var(--ink-2); border: 1px solid var(--rule);
  border-radius: 999px; padding: 4px 12px;
}
.share-headline {
  margin: 0; font-family: var(--myeongjo); font-size: 21px; font-weight: 500;
  line-height: 1.45; text-wrap: balance;
}
.share-lines {
  display: flex; flex-direction: column; gap: 5px;
  font-size: 12.5px; color: var(--ink-2); font-variant-numeric: tabular-nums;
}

/* ─── 하단 사업자 정보 ───────────────────────────── */

.sitefoot {
  border-top: 1px solid var(--rule);
  padding: 22px 20px 34px;
  display: flex; flex-direction: column; gap: 12px;
  background: var(--paper);
}
.sitefoot-links { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12.5px; }
.sitefoot-links a { color: var(--ink-2); text-decoration: none; }
.sitefoot-links a:hover { color: var(--ink); text-decoration: underline; }
.sitefoot-links b { font-weight: 600; color: var(--ink); }

".sitefoot-biz {
  display: flex; flex-wrap: wrap; gap: 3px 12px;
  font-size: 12px; color: var(--ink-3); line-height: 1.7;
}
.sitefoot-note { font-size: 11px; color: var(--ink-3); line-height: 1.6; text-wrap: pretty; }

/* ─── 약관·방침 문서 ─────────────────────────────── */

.doc { gap: 0; }
.doc h1 { font-family: var(--myeongjo); font-size: 26px; font-weight: 500; margin: 0 0 4px; }
.doc h2 {
  font-family: var(--myeongjo); font-size: 17px; font-weight: 500;
  margin: 30px 0 10px; padding-top: 16px; border-top: 1px solid var(--rule-soft);
}
.doc h2:first-of-type { border-top: 0; padding-top: 0; }
.doc p { margin: 0 0 12px; font-size: 15px; line-height: 1.8; color: var(--ink-2); text-wrap: pretty; }
.doc p b, .doc li b { color: var(--ink); font-weight: 600; }
.doc ul, .doc ol { margin: 0 0 12px; padding-left: 20px; display: flex; flex-direction: column; gap: 7px; }
.doc li { font-size: 15px; line-height: 1.75; color: var(--ink-2); }
.doc li ul { margin: 8px 0 0; }
.doc-meta { font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); margin-bottom: 24px; }

.doc-callout {
  background: var(--earth-bg); border-left: 2px solid var(--earth);
  padding: 12px 14px; border-radius: 0 8px 8px 0; margin: 0 0 14px;
}

.doc-table {
  width: 100%; border-collapse: collapse; margin: 0 0 14px;
  font-size: 13px; display: block; overflow-x: auto;
}
.doc-table th, .doc-table td {
  border: 1px solid var(--rule); padding: 8px 10px; text-align: left;
  vertical-align: top; line-height: 1.55;
}
.doc-table th { background: var(--surface-2); font-weight: 600; font-size: 12.5px; white-space: nowrap; }
.doc-table td { color: var(--ink-2); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
