:root {
  --bg: #f6f1e7; --paper: #fffdf8; --ink: #23201a; --muted: #6f6858; --line: #e4dccb;
  --accent: #8c3b2a; --accent-soft: #f3e3dc; --insight: #fbf3d9; --insight-line: #d9bf6a;
  --wood: #3f8a5a; --fire: #c8473a; --earth: #b0832f; --metal: #8b8f98; --water: #2c4f7c;
  --radius: 14px;
  --serif: 'Noto Serif KR', 'Batang', serif;
  --sans: 'Pretendard Variable', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #16140f; --paper: #1f1c16; --ink: #ece6d8; --muted: #a39b88; --line: #36312a;
    --accent: #e08a72; --accent-soft: #3a2620; --insight: #2c2717; --insight-line: #8a7433;
    --wood: #6cbf87; --fire: #ec7a6c; --earth: #d8ab58; --metal: #aab0ba; --water: #8fb3e0;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); line-height: 1.8; font-size: 16px; }
.wrap { max-width: 720px; margin: 0 auto; padding: 16px 16px 80px; }
.top h1 { font-family: var(--serif); font-size: 24px; margin: 18px 0 2px; }
.muted { color: var(--muted); font-size: 14px; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 14px 0; }
h2 { font-family: var(--serif); font-size: 20px; margin: 30px 0 2px; line-height: 1.4; }
h3 { font-size: 16px; margin: 0; line-height: 1.5; }
.sub { color: var(--muted); font-size: 14px; margin: 0 0 8px; }

/* 입력 폼 */
.row { display: flex; flex-wrap: wrap; gap: 10px 14px; margin: 8px 0; align-items: center; }
.row label { font-size: 14px; display: inline-flex; align-items: center; gap: 4px; }
.row .t { font-weight: 700; font-size: 13px; min-width: 56px; color: var(--muted); }
input[type=number], select, input[type=text] { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink); }
input[type=number] { width: 92px; }
button.primary { font: inherit; font-weight: 700; padding: 11px 18px; border-radius: 12px; border: 0; background: var(--accent); color: #fff; cursor: pointer; width: 100%; margin-top: 8px; }
.err { color: #b3261e; font-size: 14px; margin-top: 6px; }

/* 개발용 전환 */
#dev { position: sticky; top: 0; z-index: 10; background: var(--bg); padding: 8px 0; border-bottom: 1px solid var(--line); }
#dev .b { display: flex; gap: 6px; }
#dev button { flex: 1; font: inherit; font-size: 13px; font-weight: 600; padding: 8px 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; }
#dev button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
#dev small { display: block; font-weight: 400; opacity: .8; }

.sumline { font-family: var(--serif); font-size: 18px; margin: 12px 0 2px; }
.bars { display: grid; gap: 8px; margin: 10px 0; }
.bar { display: grid; grid-template-columns: 68px 1fr 80px; align-items: center; gap: 8px; font-size: 14px; }
.bar .track { background: var(--line); border-radius: 999px; height: 14px; overflow: hidden; }
.bar .fill { height: 100%; border-radius: 999px; }
.bar .n { color: var(--muted); font-size: 13px; text-align: right; }
.item { padding: 12px 0; border-top: 1px solid var(--line); }
.item:first-child { border-top: none; }
.item p { margin: 6px 0; }
.item .one { color: var(--muted); font-size: 15px; }
.lockline { margin-top: 4px; font-size: 12px; font-weight: 600; color: var(--accent); }
details { font-size: 13px; color: var(--muted); margin-top: 6px; }
summary { cursor: pointer; }

.glyphs .lab { font-size: 13px; font-weight: 700; margin: 12px 0 6px; }
.g10, .g12 { display: grid; gap: 6px; }
.g10 { grid-template-columns: repeat(5, 1fr); } .g12 { grid-template-columns: repeat(6, 1fr); }
.g { position: relative; border: 1px solid var(--line); border-radius: 10px; text-align: center; padding: 6px 2px 5px; background: var(--paper); line-height: 1.3; }
.g .h { font-family: var(--serif); font-size: 22px; } .g .k { font-size: 11px; color: var(--muted); } .g .m { font-size: 11px; }
.g.on { border: 2px solid var(--accent); background: var(--accent-soft); }
.g .pin { position: absolute; top: -9px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; font-size: 10px; font-weight: 700; padding: 0 6px; border-radius: 999px; white-space: nowrap; }
.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); }

.chips { display: flex; gap: 6px; overflow-x: auto; padding: 4px 2px 8px; }
.chip { flex: 0 0 auto; font: inherit; font-size: 13px; font-weight: 600; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; text-align: center; line-height: 1.3; }
.chip small { display: block; font-weight: 400; color: var(--muted); font-size: 11px; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip[aria-pressed="true"] small { color: #fbe9e2; }
.chip.now::after { content: " · 지금"; font-size: 11px; }
.fieldcard { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 18px; margin: 12px 0; }
.fieldcard h3 { display: inline-block; padding: 3px 16px 4px; margin: 2px 0 6px -4px; transform: rotate(-1.2deg); background: rgba(255, 224, 70, .38); border: 3px solid rgba(245, 190, 20, .75); border-radius: 58% 42% 55% 45% / 52% 60% 40% 48%; font-family: var(--serif); font-size: 17px; }
.hl { font-weight: 700; margin: 2px 0; }
.sm { color: var(--muted); margin: 2px 0 6px; font-size: 15px; }
.qs { border-top: 1px dashed var(--line); margin-top: 8px; padding-top: 6px; font-size: 15px; }
.qs b { color: var(--accent); font-size: 13px; }
.note { font-size: 13px; background: var(--insight); border: 1px solid var(--insight-line); border-radius: 10px; padding: 8px 12px; margin: 8px 0; }
.lockbox { border: 1px dashed var(--insight-line); background: var(--insight); border-radius: 12px; padding: 12px 14px; margin: 10px 0; font-size: 14px; }
.lockbox ul { margin: 6px 0 0; padding-left: 18px; }
textarea.fake { width: 100%; min-height: 80px; font: inherit; padding: 10px; border: 1px dashed var(--insight-line); border-radius: 10px; background: var(--insight); color: var(--muted); resize: none; }
.look { padding: 10px 0; border-top: 1px solid var(--line); }
.look:first-child { border-top: none; }
.tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 0 8px; border-radius: 999px; background: var(--line); color: var(--muted); margin-right: 6px; }
.foot { margin-top: 32px; font-size: 13px; color: var(--muted); }

.more { margin-top: 8px; font-size: 16px; color: var(--ink); }
.more > summary { font-size: 14px; font-weight: 600; color: var(--accent); cursor: pointer; }
.more p { margin: 8px 0; }
.fact { font-size: 14px; color: var(--muted); border-left: 3px solid var(--line); padding-left: 10px; }

.fold { border-top: 1px solid var(--line); padding: 8px 0; }
.fold:first-child { border-top: none; }
.fold > summary { font-size: 15px; font-weight: 600; color: var(--ink); cursor: pointer; }
.fold p { margin: 8px 0; font-size: 15px; color: var(--ink); }

/* 일러스트 */
.art { border-radius: 50%; flex: none; display: block; background: transparent; }
.art.sm { width: 52px; height: 52px; }
.art.h2 { display: inline-block; width: 40px; height: 40px; vertical-align: middle; margin-right: 10px; }
.withart { display: flex; gap: 14px; align-items: flex-start; }
.withart > .art { margin-top: 2px; }
.ftitle { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
.ftitle h3 { margin: 0; }
.pair { display: flex; gap: 12px; margin: 4px 0 10px; }
.pair .art { width: 72px; height: 72px; }
.pair.big { justify-content: center; margin: 6px 0 14px; }
.pair.big .art { width: 132px; height: 132px; }
.hero { display: flex; justify-content: center; margin: 4px 0 8px; }
.hero .art { width: 120px; height: 120px; }
.bar .el { display: inline-flex; align-items: center; gap: 6px; }
.bar .el .art { width: 28px; height: 28px; }
@media (max-width: 420px) { .withart { gap: 10px; } .withart > .art { width: 64px; height: 64px; } }

.art.cell { width: 40px; height: 40px; margin: 2px auto 4px; }
.glyphs .g .art.cell { width: 36px; height: 36px; }

/* 오행 오각형 */
.radar { display: block; width: min(100%, 340px); margin: 6px auto 4px; overflow: visible; color: var(--ink); }
/* 명식 카드 */
.chart { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 12px 0 4px; }
.pillar { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 8px 6px 6px; text-align: center; }
.pillar.me { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
.pillar .ph { font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.pillar.me .ph { color: var(--accent); }
.pillar .pc { border-radius: 10px; padding: 6px 2px 4px; margin-bottom: 6px; background: color-mix(in srgb, var(--ec) 13%, var(--paper)); color: var(--ec); line-height: 1.15; }
.pillar .pc b { display: block; font-family: var(--serif); font-size: 30px; font-weight: 600; }
.pillar .pc small { font-size: 11px; color: var(--muted); }
.pillar .an { display: flex; justify-content: center; }
.pillar .an .art { width: 40px; height: 40px; }
.pillar.empty { border-style: dashed; background: transparent; }
.pillar.empty .pe { font-size: 12px; color: var(--muted); padding: 18px 2px; line-height: 1.5; }
/* 나이대별 흐름 타임라인 */
.chips { display: block; }
.tl-scroll { overflow-x: auto; padding: 4px 2px 10px; margin: 8px -4px 0; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.tl-in { position: relative; padding-top: 22px; }
.tlrow { display: flex; }
.chip.tlb { flex: none; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 8px 4px 9px; border: 1px solid var(--line); border-bottom: 5px solid var(--gc); border-radius: 12px; background: var(--paper); color: var(--ink); font: inherit; cursor: pointer; margin: 0 6px 0 0; }
.chip.tlb b { font-size: 13px; }
.chip.tlb small { font-size: 11px; color: var(--muted); }
.chip.tlb .art { width: 44px; height: 44px; }
.chip.tlb .lockic { height: 44px; display: flex; align-items: center; font-size: 22px; opacity: .55; }
.chip.tlb.lk { background: repeating-linear-gradient(135deg, var(--paper), var(--paper) 8px, var(--bg) 8px, var(--bg) 16px); }
.chip.tlb[aria-pressed="true"] { outline: 3px solid var(--accent); outline-offset: -1px; }
.chip.tlb.now { background: var(--accent-soft); }
.dots { position: absolute; top: 6px; left: 0; right: 0; height: 14px; }
.dot { position: absolute; top: 2px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--muted); opacity: .85; }
.dot.past { background: #b0832f; } .dot.present { background: var(--accent); } .dot.future { background: var(--line); border: 1px solid var(--muted); }
.nowmark { position: absolute; top: 0; height: 26px; width: 0; border-left: 2px dashed var(--accent); z-index: 2; pointer-events: none; }
.nowmark em { position: absolute; top: -2px; left: 4px; font-style: normal; font-size: 11px; font-weight: 700; color: var(--accent); background: var(--paper); padding: 0 4px; border-radius: 6px; white-space: nowrap; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); margin: 2px 2px 6px; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 4px; }
@media (max-width: 420px) { .pillar .pc b { font-size: 26px; } .pillar .pc small { font-size: 10px; } }

.muted.center { text-align: center; margin: 0 0 10px; }
.chip.tlb .gn { font-size: 11px; color: var(--ink); opacity: .8; }
@media (max-width: 420px) { .pillar .pc small { font-size: 11px; } }

.brand { display: inline-block; font-family: var(--serif); font-weight: 700; color: var(--accent); text-decoration: none; margin-top: 10px; }
.note.beta { font-size: 13px; margin: 10px 0; }

.muted a, .foot a { color: var(--accent); }

.periodglyph { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; align-items: center; }
.periodglyph .pair { margin: 0; }
.periodglyph .pair .art { width: 64px; height: 64px; }
.periodglyph .pg h3 { font-size: 16px; }
.periodglyph .pg p { margin: 2px 0 0; }
.periodglyph .fold { grid-column: 1 / -1; }

.focus { margin: 6px 0 4px; font-size: 14.5px; color: var(--ink); background: var(--insight); border-left: 3px solid var(--insight-line); padding: 6px 10px; border-radius: 6px; }
.look .fold > summary { font-size: 14.5px; }

/* 나이 빠른 선택 막대(fixed): 글 흐름 밖에 있어 보이거나 숨겨져도 문서 높이가 바뀌지 않는다 */
.chips.tl-wrap { overflow: visible; display: block; padding: 0; }
.tlbar { position: fixed; top: var(--stick, 0px); left: 0; right: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: 0 6px 10px -8px rgba(0, 0, 0, .35); padding-top: env(safe-area-inset-top, 0px); }
.tlbar[hidden] { display: none; }
.tlbar-in { max-width: 720px; margin: 0 auto; padding: 6px max(16px, env(safe-area-inset-right, 0px)) 6px max(16px, env(safe-area-inset-left, 0px)); }
.tlbar-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; overscroll-behavior-x: contain; }
.tlbar-scroll::-webkit-scrollbar { display: none; }
.tlbar-row { display: flex; gap: 6px; width: max-content; padding-right: 16px; }
.tlbar .chip { padding: 7px 12px; border-bottom: 4px solid var(--gc, var(--line)); border-radius: 12px; white-space: nowrap; }
.tlbar .chip.lk { opacity: .7; }
.tlbar .chip[aria-pressed="true"] { border-bottom-color: #fff; }
#periodpanel { scroll-margin-top: calc(var(--tlbar-h, 56px) + var(--stick, 0px) + 10px); }

.tl-sentinel { height: 1px; margin-bottom: -1px; }

.rng b { color: var(--accent); font-size: 12.5px; margin-right: 4px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
#periodpanel:focus { outline: none; }

.skipto { position: absolute; left: -9999px; }
.skipto:focus { position: static; display: inline-block; margin: 4px 0 2px; font-size: 13px; font-weight: 700; color: var(--accent); }

/* v5 단정형 카드 */
.fieldcard .ans { font-size: 18.5px; font-weight: 800; line-height: 1.45; margin: 10px 0 6px; letter-spacing: -.2px; }
.fieldcard .why { font-size: 15px; margin: 0 0 10px; }
.fieldcard .past { font-size: 14.5px; background: var(--accent-soft); border-radius: 8px; padding: 6px 10px; margin: 4px 0 10px; }
.fieldcard .past b { color: var(--accent); margin-right: 4px; }
.gw p { margin: 4px 0; font-size: 14.5px; }
.gw b { font-size: 12.5px; padding: 1px 7px; border-radius: 999px; margin-right: 4px; }
.gw .g { background: #e3f1e3; color: #2f6b3a; } .gw .w { background: #f7e3dc; color: #8c3b2a; }
.fieldcard .stl { font-size: 13.5px; color: var(--muted); margin: 8px 0 0; }
.ifs { margin-top: 10px; border-top: 1px dashed var(--line); padding-top: 8px; }
.ifh { font-size: 12.5px; font-weight: 800; color: var(--muted); margin-bottom: 2px; }
.if summary { cursor: pointer; font-size: 14.5px; font-weight: 700; padding: 5px 0; }
.if p { margin: 2px 0 8px; font-size: 14.5px; background: var(--insight); border-left: 3px solid var(--insight-line); padding: 6px 10px; border-radius: 6px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .gw .g { background: #23382a; color: #9fd3a8; } :root:not([data-theme="light"]) .gw .w { background: #3a2620; color: #f0a48f; } }

.verdict .vlab { display: inline-block; font-size: 12px; font-weight: 800; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 1px 9px; }
.verdict .vans { font-size: 19px; line-height: 1.45; margin: 6px 0 2px; }
.verdict .why { font-size: 15px; margin: 8px 0 4px; }
.verdict .past { font-size: 14.5px; background: var(--accent-soft); border-radius: 8px; padding: 6px 10px; margin: 8px 0 4px; }
.verdict .past b { color: var(--accent); margin-right: 4px; }
.ycard p { margin: 6px 0; font-size: 15px; }
.ycard .yl { font-size: 12.5px; padding: 1px 8px; border-radius: 999px; background: var(--insight); border: 1px solid var(--insight-line); margin-right: 6px; }

/* 평생 풀이 (v6) — 펼친 채로 스크롤해서 읽는다 */
.life { margin: 8px 0 28px; }
.life.top { background: var(--accent-soft); border-radius: 16px; padding: 18px 18px 14px; }
.life .heroline { font-size: 14px; font-weight: 700; color: var(--accent); margin: 0 0 4px; }
.life.top h2 { font-size: 22px; line-height: 1.4; margin: 0 0 8px; }
.life .lead2 { font-size: 16.5px; line-height: 1.8; margin: 0; }
.life .chap { border-left: 4px solid var(--gc, var(--line)); background: var(--card, #fff); border-radius: 0 12px 12px 0; padding: 10px 14px; margin: 12px 0; }
.life .chh { display: flex; align-items: center; justify-content: space-between; }
.life .chh .age { font-size: 13px; font-weight: 800; color: var(--muted); }
.life .chap h3 { font-size: 17.5px; margin: 2px 0 6px; line-height: 1.45; }
.life .chap p { margin: 6px 0; line-height: 1.8; }
.life .shift { font-size: 14.5px; color: var(--muted); }
.life .mod { font-size: 15px; background: var(--accent-soft); border-radius: 8px; padding: 6px 10px; }
.life .phase { font-size: 14.5px; font-weight: 700; color: var(--accent); }
.life .sub2 { font-size: 16px; margin: 20px 0 6px; }
.life .turn { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin: 8px 0; }
.life .turn .ty { display: block; font-size: 13px; font-weight: 800; color: var(--accent); }
.life .turn p { margin: 4px 0 0; line-height: 1.75; }
.life .trait { padding: 12px 0; border-bottom: 1px solid var(--line); }
.life .trait:last-child { border-bottom: 0; }
.life .trait .tl { font-size: 12.5px; font-weight: 800; color: var(--accent); }
.life .trait h3 { font-size: 17px; margin: 2px 0 6px; line-height: 1.45; }
.life .trait p { margin: 0 0 10px; line-height: 1.8; }
.life .trait p:last-child { margin-bottom: 0; }
.life .ycard2 { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin: 12px 0; }
.life .ycard2 h3 { font-size: 16.5px; margin: 0 0 6px; }
.life .ycard2 p { margin: 5px 0; }
.life .ycard2 .yl { font-size: 12.5px; padding: 1px 8px; border-radius: 999px; background: var(--insight); border: 1px solid var(--insight-line); margin-right: 6px; }
.fold h4 { font-size: 15.5px; margin: 14px 0 6px; }
.evid { font-size: 13px; color: var(--muted); margin-top: 8px; }
.evid ul { margin: 4px 0 0; padding-left: 18px; }
.if .ifq { font-weight: 700; margin: 8px 0 2px; }

.pillar .pm { font-size: 11.5px; color: var(--muted); line-height: 1.35; margin-top: 4px; text-align: center; word-break: keep-all; }

.life .pline { font-size: 15px; margin: 6px 0; }
.life .pline b { font-size: 12.5px; color: var(--muted); margin-right: 6px; }

/* 궁합 */
.match .mhead { display: flex; gap: 14px; align-items: center; margin-bottom: 8px; }
.match .mscore { min-width: 84px; height: 84px; border-radius: 50%; background: var(--accent-soft); display: flex; align-items: baseline; justify-content: center; padding-top: 22px; box-sizing: border-box; }
.match .mscore b { font-size: 32px; color: var(--accent); line-height: 1; }
.match .mscore small { font-size: 13px; margin-left: 2px; }
.match .mgrade { font-size: 20px; margin: 0 0 4px; }
.match .mhead p { margin: 0; }
.match .mtitle { font-weight: 700; font-size: 16px; margin: 8px 0 4px; }
.match .mark { display: inline-block; font-size: 12px; font-weight: 800; border-radius: 999px; padding: 0 8px; margin-left: 6px; }
.match .mg { background: #e3f1e5; color: #2f6b3a; } .match .mn { background: var(--accent-soft); color: var(--muted); } .match .mb { background: #f6dcd6; color: #9b2f1f; }

.gw1 { font-size: 14.5px; margin: 6px 0 0; }
.gw1 .g { font-size: 12.5px; margin-right: 6px; }

/* PDF 저장(인쇄) */
.pdfbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 8px 0 16px; }
.pdfbar p { margin: 0; font-size: 13px; }
@media print {
  @page { margin: 14mm 12mm; }
  body { background: #fff !important; color: #111 !important; font-size: 11pt; }
  .noprint, #form, #dev, #tlbar, .note.beta, .foot, #mform, .match .sub, .tl-scroll, #chips, .skipto, .lockline, button { display: none !important; }
  .wrap { max-width: none !important; padding: 0 !important; }
  .card, .life .chap, .life .turn, .life .ycard2 { box-shadow: none !important; break-inside: avoid; }
  .life .trait, .fieldcard { break-inside: avoid; }
  .life h2, h2 { break-after: avoid; }
  img.art { max-height: 60px; }
  a { color: inherit; text-decoration: none; }
}
.printonly { display: none; }
@media print { .printonly { display: block; } #periodpanel { display: none !important; } .printage { margin: 18px 0 6px; font-size: 14pt; break-after: avoid; } }

/* 피드백 */
.fbrow { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 2px; align-items: center; }
.fbt { font: inherit; font-size: 12.5px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--muted); cursor: pointer; }
.fbt[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); font-weight: 700; }
.fbthanks { font-size: 12px; color: var(--accent); }
.fbnote textarea { width: 100%; box-sizing: border-box; font: inherit; padding: 10px; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: inherit; margin-bottom: 8px; }
@media print { .fbrow, .fbnote { display: none !important; } }
.fbask { display: flex; gap: 6px; margin: 6px 0 2px; }
.fbask input { flex: 1; min-width: 0; font: inherit; font-size: 14px; padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line); background: transparent; color: inherit; }
.fbask button { font: inherit; font-size: 13px; padding: 4px 12px; border-radius: 8px; border: 1px solid var(--accent); background: var(--accent-soft); color: var(--accent); cursor: pointer; }
@media print { .fbask { display: none !important; } }

/* 고민별 단품 잠금 카드 · 지나온 길 확인 버튼 (2026-11-27) */
.buy { margin: 12px 0 4px; padding: 14px; border: 1px dashed var(--accent); border-radius: 12px; background: var(--accent-soft); }
.buy .buylead { margin: 0 0 8px; font-size: 14px; font-weight: 700; color: var(--accent); }
.buy .buyrow { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.buy .buyrow small { display: block; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.buy .buyprice { font-weight: 800; color: var(--accent); }
.buy .buybtn.primary { width: auto; margin: 0; white-space: nowrap; padding: 9px 16px; }
.buy .buyall { margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.buy .linkbtn { font: inherit; font-weight: 700; color: var(--accent); background: none; border: 0; padding: 0 4px 0 0; text-decoration: underline; cursor: pointer; }
.buy .buymsg { margin: 6px 0 0; font-size: 13px; color: var(--ink); }
.buy .buymsg:empty { display: none; }
.trait.locked h3 { margin-bottom: 0; }
.fbrow.chk { padding-top: 8px; border-top: 1px dashed var(--line); }
.fbrow.chk .chkq { font-size: 13px; font-weight: 700; color: var(--ink); margin-right: 2px; }
.fbrow.chk .fbt { font-size: 13px; padding: 4px 12px; }
.fbrow.chk .fbt:disabled { opacity: .4; cursor: default; }
.fbrow.chk .fbthanks { flex-basis: 100%; font-size: 13px; line-height: 1.6; }
.life .turn.ask b { display: block; margin-top: 2px; line-height: 1.6; }
.note.pastnote { font-size: 14px; }

/* 결제(토스 결제위젯) 창 */
.buy .buynote { font-size: .8rem; color: var(--muted, #777); margin: .4rem 0 0; }
body.paying { overflow: hidden; }
.paymodal { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 1000; display: flex; align-items: flex-end; justify-content: center; }
.paybox { background: var(--bg, #fff); width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; border-radius: 16px 16px 0 0; padding: 1.1rem 1rem 1.4rem; position: relative; }
@media (min-width: 640px) { .paymodal { align-items: center; } .paybox { border-radius: 16px; } }
.paybox h3 { margin: 0 2rem .2rem 0; font-size: 1.1rem; }
.paybox .paycov { margin: 0 0 .6rem; font-size: .85rem; color: var(--muted, #777); }
.payclose { position: absolute; top: .5rem; right: .6rem; border: 0; background: none; font-size: 1.6rem; line-height: 1; cursor: pointer; color: inherit; }
.payok { display: block; font-size: .85rem; line-height: 1.5; margin: .6rem 0; }
.payok input { margin-right: .3rem; }
.paygo { width: 100%; padding: .85rem; font-size: 1rem; }
.paygo:disabled { opacity: .45; cursor: not-allowed; }
.paymsg { min-height: 1.2em; font-size: .85rem; color: #c0392b; margin: .5rem 0 0; }
