/* 캐릭터형 테마: 휴대폰 앱처럼 보이는 화면. 색은 :root 변수만 바꾸면 전체에 반영돼요.
   판에는 그러데이션·그림자 대신 면 색 하나와 가는 선을 써요. 토리(캐릭터)와 말풍선이 이 테마의 얼굴이에요.
   색 체계(4차): 크림 바탕 하나 · 주색 산호(단추·선택·값) · 보조 둘(복숭아 옅은 면, 꿀색 켜진 등·밤 강조) · 따뜻한 먹색 글자.
   채도·명도를 맞춰서 귀엽되 싸 보이지 않게 해요. 예전 파스텔 이름(--pink·--lav …)은 복숭아·꿀색 둘로 모았어요.
   글자 체계(4차): 둥근 글꼴(Jua)은 '목소리' 자리(상호·제목·큰 숫자·말풍선 이름)에만, 본문·단추는 Pretendard. */
:root {
  --bg: #fff7f0;
  --bg2: #fbeee4;
  --card: #fffdfa;
  --text: #3b2a2a;
  --sub: #6e5a58;
  --faint: #9e8a86;
  --line: #f0e0d4;
  --line-strong: #e5cbbb;
  --night: #ec6a4c;
  --night-2: #d9573a;
  --coral: #ec6a4c;
  --coral-2: #f6a48c;
  --coral-ink: #c94f31;
  --peach: #ffe8dc;
  --butter: #ffd47a;
  --butter-soft: #fff1cf;
  --pink: #ffe8dc;
  --mint: #4c9a78;
  --mint-soft: #fff1cf;
  --lemon: #fff1cf;
  --lav: #ffe8dc;
  --sky: #fff1cf;
  --good: #2f7d5b;
  --warn: #c2462b;
  --wood: #5c9e78; --fire: #e46a4e; --earth: #e2a64a; --metal: #e9e0d6; --metal-fg: #5b4f49; --water: #5378c4;
  --r-xl: 18px;
  --r-l: 14px;
  --cute: "Jua", "Pretendard Variable", Pretendard, sans-serif;
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  --head: var(--cute);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100dvh; font-family: var(--font); color: var(--text); font-size: 16px; line-height: 1.6; letter-spacing: -0.01em; word-break: keep-all; overflow-wrap: anywhere; background: var(--bg); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p { margin: 0; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: not-allowed; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; }

/* 화면 틀: 휴대폰에서는 한 줄, 넓은 화면에서는 위에 메뉴를 두고 넓게 써요 */
.phone { position: relative; max-width: 480px; margin: 0 auto; min-height: 100dvh; background: var(--bg); display: flex; flex-direction: column; }
.boot, .loading { display: grid; place-items: center; align-content: center; gap: 14px; min-height: 70dvh; color: var(--sub); text-align: center; padding: 24px; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; }
.loading.small { min-height: 180px; font-size: 16px; }

/* 샘플 사이트 띠 */
.demo-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 12px; padding: 8px 12px; background: #2b1f2e; color: #fbefe9; font-size: 12.5px; }
.demo-bar .themes { display: inline-flex; gap: 2px; flex-wrap: wrap; justify-content: center; }
.demo-bar .themes a { text-decoration: none; padding: 2px 8px; border-bottom: 2px solid transparent; }
.demo-bar .themes a[aria-current="page"] { border-bottom-color: #ffe08a; color: #ffe08a; font-weight: 800; }
.demo-bar .back { color: #ffd2c2; font-weight: 700; }

/* 위 막대 */
.appbar { position: sticky; top: 0; z-index: 6; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 16px; background: var(--bg); border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 8px; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 20px; white-space: nowrap; min-width: 0; }
.seal { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--coral); color: #fff; font-size: 15px; font-weight: 900; flex: none; }
.who { display: inline-flex; align-items: center; gap: 8px; min-width: 0; border: 1px solid var(--line-strong); background: var(--card); border-radius: 12px; padding: 5px 6px 5px 12px; font-weight: 700; font-size: 14px; }
/* 이름이 길면 줄여서(…) 한 줄로 둬요 */
.who span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who b { flex: none; color: var(--coral-ink); font-size: 12.5px; border-left: 1px solid var(--line); padding-left: 8px; }

/* 아래 탭 막대 */
.tabbar { position: sticky; bottom: 0; z-index: 6; order: 2; margin-top: auto; display: grid; grid-template-columns: repeat(5, 1fr); gap: 2px; padding: 6px 8px calc(8px + env(safe-area-inset-bottom)); background: var(--card); border-top: 1px solid var(--line); }
.tabbar button { display: grid; justify-items: center; gap: 2px; border: 0; background: transparent; color: var(--faint); font-size: 11.5px; font-weight: 700; padding: 6px 0; border-radius: 12px; }
.tabbar svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.tabbar button[aria-current="page"] { color: var(--coral); }
.tabbar button[aria-current="page"] svg { fill: var(--coral-2); fill-opacity: .25; }
.screen { order: 1; }

/* 대화 */
.thread { display: grid; gap: 10px; }
.msg { display: flex; align-items: flex-end; gap: 8px; }
.msg.mine { justify-content: flex-end; }
.av { width: 40px; height: 40px; border-radius: 50%; flex: none; background: var(--peach); }
.bub { max-width: 80%; padding: 10px 14px; border-radius: 20px 20px 20px 6px; background: var(--card); border: 1px solid var(--line); }
.bub > b { display: block; font-size: 12.5px; color: var(--coral-ink); margin-bottom: 2px; }
.bub p b { color: var(--coral-ink); }
.bub p + p { margin-top: 6px; }
.mine .bub { background: var(--coral); border-color: var(--coral); color: #fff; border-radius: 20px 20px 6px 20px; font-weight: 600; }
.bub.dots { display: flex; gap: 5px; padding: 15px 16px; }
.bub.dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--coral-2); animation: blink 1s infinite; }
.bub.dots i:nth-child(2) { animation-delay: .15s; }
.bub.dots i:nth-child(3) { animation-delay: .3s; }
.sample { display: inline-block; margin-top: 6px; font-size: 11.5px; color: var(--faint); border-top: 1px dashed var(--line-strong); padding-top: 4px; }

/* 캐릭터 얼굴·고르는 칸 */
.hero-char { width: 120px; height: 120px; border-radius: 50%; background: var(--card); border: 1px solid var(--line); }
.chips-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chips-row.scroll { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chips-row.scroll::-webkit-scrollbar { display: none; }
.pick { flex: none; border: 1.5px solid var(--coral); background: var(--card); color: var(--coral-ink); border-radius: 14px; padding: 9px 15px; font-weight: 800; font-size: 15px; transition: transform .12s ease; }
.pick small { color: var(--sub); font-weight: 600; margin-left: 4px; }
.pick.ghost { border-style: dashed; border-color: var(--faint); color: var(--sub); }
.pick.go, .pick.on { background: var(--coral); color: #fff; }
.pick.go small, .pick.on small { color: #fff; opacity: .85; }
.pick.own { border-style: dashed; }
a.pick { display: inline-flex; align-items: center; text-decoration: none; }
.pick.small { padding: 7px 12px; font-size: 13.5px; border-radius: 12px; }
.pick:active, .big-btn:active, .round:active, .send:active { transform: scale(.96); }
/* 누름 반응: 단추가 살짝 눌렸다가 돌아와요(transform만) */
.big-btn, .when-go, .prow, .mini-btn, .code-btn { transition: transform .12s ease; }
.when-go:active, .mini-btn:active, .code-btn:active { transform: scale(.95); }
.prow:active { transform: scale(.985); }
.field-row { display: flex; gap: 8px; }
.composer input { flex: 1; min-width: 0; min-height: 50px; border-radius: 16px; border: 1.5px solid var(--line-strong); background: var(--card); padding: 0 16px; font-size: 16px; }
.composer input:focus { outline: none; border-color: var(--coral); }
.send { flex: none; width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--coral); color: #fff; display: grid; place-items: center; }
.send svg { width: 22px; height: 22px; fill: currentColor; }
.send:disabled { opacity: .5; }

/* 화면 공통 */
.screen { padding: 12px 16px 28px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; align-content: start; }
.screen > * { min-width: 0; }
.screen-title { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 28px; padding: 6px 2px 0; }
.card { background: var(--card); border-radius: var(--r-xl); padding: 18px; border: 1px solid var(--line); min-width: 0; }
.card h3 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 20px; margin-bottom: 10px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.card h3 small { font-family: var(--font); font-size: 12.5px; color: var(--faint); font-weight: 600; }
.card p + p { margin-top: 8px; }
.eyebrow { font-size: 12.5px; font-weight: 800; color: var(--coral-ink); }
.hint { font-size: 12.5px; color: var(--faint); margin-top: 8px; }
.mini { font-size: 12.5px; font-weight: 800; color: var(--sub); margin: 10px 0 6px; }
.foot { text-align: center; font-size: 12px; color: var(--faint); padding: 4px 12px; }
.talk { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; }
.talk.center { text-align: center; margin-top: 8px; }
.link { border: 0; background: none; padding: 0; margin-top: 6px; color: var(--coral-ink); font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.says { display: flex; align-items: flex-end; gap: 8px; }
.says .bub { max-width: calc(100% - 48px); }

/* ── 그림(art.js): 토리·열두 달 등·하늘과 언덕 ──
   면 색 하나씩만 칠해요(그러데이션·흐림 없음). 밤·낮은 그림 바깥의 is-night·is-day가 정해요.
   움직임은 transform·opacity만 써요. prefers-reduced-motion이면 아래에서 다 멈춰요. */
.ta { --ink: #3a2f2a; overflow: visible; }
.ta .fur { fill: #fffdf8; }
.ta .ol, .ta .ol-l { stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.ta .ol-l { stroke-width: 1.6; }
.ta .ear-in { fill: #f6b8c0; }
.ta .blush { fill: #f8bfc6; }
.ta .eye { fill: var(--ink); }
.ta .shine { fill: #fff; }
.ta .nose { fill: #ff8a7a; }
.ta .mouth { fill: #c8584a; stroke: var(--ink); stroke-width: 2.2; stroke-linejoin: round; }
.ta .ln-face { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.ta .ln-thin { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ta .belly { fill: #fff1e4; }
.ta .pad { fill: #f8c7cc; }
.ta .moonclip { fill: #f2c75c; stroke: var(--ink); stroke-width: 1.4; }
.ta .mark { fill: none; stroke: #e2553e; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.ta .mark-dot { fill: #e2553e; }
.ta .sp { fill: #ffd36a; }
.ta .stick { stroke: #8a5a3c; stroke-width: 3.5; stroke-linecap: round; }
.scene .post { stroke: #8a5a3c; stroke-width: 5; stroke-linecap: round; }
.scene .post-cap { stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
/* 등(燈) */
.ta .tie { stroke: var(--ink); stroke-width: 1.6; fill: none; }
.ta .cap { fill: var(--ink); }
.ta .paper { stroke: var(--ink); stroke-width: 1.6; }
.ta .tone0 .paper { fill: #ffb49c; } .ta .tone1 .paper { fill: #ffe08a; } .ta .tone2 .paper { fill: #bcd6ff; }
.ta .tone3 .paper { fill: #f9c6cd; } .ta .tone4 .paper { fill: #a8e2c8; }
.ta .litpaper { fill: #ffd25e; opacity: 0; }
.ta .rib { fill: none; stroke: var(--ink); stroke-width: 1; opacity: .3; }
.ta .tassel { fill: #e2553e; }
.ta .lan-n { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 13px; text-anchor: middle; fill: var(--ink); }
.ta .halo { fill: #ffe08a; opacity: 0; }
.ta .lan.lit .litpaper { opacity: 1; }
.ta .lan.lit .halo { opacity: .5; }
.ta .lan.mine .litpaper { opacity: 1; fill: #ff7a59; }
.ta .lan.mine .lan-n { fill: #fff; }
.ta .lan.mine .halo { opacity: .6; fill: #ffd36a; }
.ta .lan.warn .paper { fill: #ece6e1; }
.ta .lan.warn .lan-n { fill: #c84a2c; }
.ta .lan.dim { opacity: .55; }
/* 하늘과 땅: 낮 */
.scene { --sky: #ffe6d6; --sky2: #ffdac8; --far: #cfe9dc; --mid: #a7dec4; --near: #82cfad; --moon: #fff7de; --crater: #f3e0b0; --cloud: #fffaf6; --string: #c98f7a; --wall: #fff3e6; --roof: #5b4a5e; --win: #f3d2a8; --tuft: #5fae8b; --star: #fff3c4; }
/* 밤 */
.scene.is-night { --sky: #231d3b; --sky2: #2c2550; --far: #2c3558; --mid: #2f4b5c; --near: #3a6555; --moon: #fff1c4; --crater: #e6d39d; --string: #9a7b8a; --wall: #e9dccd; --roof: #1b1630; --win: #ffd36a; --tuft: #7fb79c; }
.scene { display: block; width: 100%; height: auto; overflow: hidden; }
.scene .sky { fill: var(--sky); }
.scene .sky2 { fill: var(--sky2); }
.scene .moon { fill: var(--moon); }
.scene .crater { fill: var(--crater); }
.scene .cloud { fill: var(--cloud); }
.scene .hill.far { fill: var(--far); }
.scene .hill.mid { fill: var(--mid); }
.scene .hill.near { fill: var(--near); }
.scene .tuft { fill: none; stroke: var(--tuft); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.scene .wall { fill: var(--wall); }
.scene .roof { fill: var(--roof); }
.scene .win { fill: var(--win); }
.ta .string { fill: none; stroke: #c98f7a; stroke-width: 1.6; }
.scene .string { stroke: var(--string); }
.scene .star { fill: var(--star); }
.scene.is-day .night-only, .scene.is-night .day-only { display: none; }
.scene.is-night .lan:not(.lit):not(.mine) .paper { opacity: .8; }
.hero-scene .pose { display: none; }
.hero-scene[data-pose="base"] .pose-is-base, .hero-scene[data-pose="curious"] .pose-is-curious, .hero-scene[data-pose="happy"] .pose-is-happy,
.hero-scene[data-pose="wow"] .pose-is-wow, .hero-scene[data-pose="cheer"] .pose-is-cheer { display: inline; }
.emblem .b { opacity: .9; }

/* 쉬는 동안의 작은 반복: 눈 깜빡임, 귀, 등 흔들림, 별, 켜진 등 숨쉬기, 토리 까딱임 */
.ta .eyes { transform-box: fill-box; transform-origin: center; animation: blink-eye 4.6s infinite; }
.ta .ear-r { transform-box: fill-box; transform-origin: 50% 100%; animation: ear-wig 3.8s ease-in-out infinite; }
.ta .lan-sw { transform-box: fill-box; transform-origin: 50% 0; animation: swing 3.6s ease-in-out infinite; }
.ta .lans > g:nth-child(even) .lan-sw { animation-delay: -1.8s; }
.ta .lans > g:nth-child(3n) .lan-sw { animation-duration: 4.2s; }
.scene path.star { transform-box: fill-box; transform-origin: center; animation: twinkle 2.6s ease-in-out infinite; }
.scene .star.tw1 { animation-delay: .9s; } .scene .star.tw2 { animation-delay: 1.7s; }
.ta .lan.lit .halo, .ta .lan.mine .halo { animation: halo 2.4s ease-in-out infinite; }
.scene .tori-bob { animation: bob 3s ease-in-out infinite; }
@keyframes blink-eye { 0%, 93%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.12); } }
@keyframes ear-wig { 0%, 70%, 100% { transform: rotate(0); } 78% { transform: rotate(9deg); } 86% { transform: rotate(-4deg); } }
@keyframes swing { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(4deg); } }
@keyframes twinkle { 0%, 100% { opacity: .35; transform: scale(.7); } 50% { opacity: 1; transform: scale(1.1); } }
@keyframes halo { 0%, 100% { opacity: .35; } 50% { opacity: .7; } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }

/* 첫 화면 등장 안무(1.1초 안): 하늘 → 꽃줄(등이 차례로 떨어짐) → 토리 → 제목 → 생일 칸. 화면을 다시 그릴 때는 안 되풀이해요(.animate일 때만) */
.animate .hero-scene .l-sky { animation: fade-in .3s ease-out both; }
.animate .hero-scene .l-far { animation: rise-in .45s .08s cubic-bezier(.2, .9, .3, 1) both; }
.animate .hero-scene .string { animation: fade-in .2s .15s both; }
.animate .hero-scene .lan-drop { animation: drop-in .42s cubic-bezier(.3, 1.45, .5, 1) both; }
.animate .hero-scene .lans > g:nth-child(1) .lan-drop { animation-delay: .2s; } .animate .hero-scene .lans > g:nth-child(2) .lan-drop { animation-delay: .23s; }
.animate .hero-scene .lans > g:nth-child(3) .lan-drop { animation-delay: .26s; } .animate .hero-scene .lans > g:nth-child(4) .lan-drop { animation-delay: .29s; }
.animate .hero-scene .lans > g:nth-child(5) .lan-drop { animation-delay: .32s; } .animate .hero-scene .lans > g:nth-child(6) .lan-drop { animation-delay: .35s; }
.animate .hero-scene .lans > g:nth-child(7) .lan-drop { animation-delay: .38s; } .animate .hero-scene .lans > g:nth-child(8) .lan-drop { animation-delay: .41s; }
.animate .hero-scene .lans > g:nth-child(9) .lan-drop { animation-delay: .44s; } .animate .hero-scene .lans > g:nth-child(10) .lan-drop { animation-delay: .47s; }
.animate .hero-scene .lans > g:nth-child(11) .lan-drop { animation-delay: .5s; } .animate .hero-scene .lans > g:nth-child(12) .lan-drop { animation-delay: .53s; }
.animate .hero-scene .tori-pop { animation: pop-up .42s .45s cubic-bezier(.3, 1.5, .5, 1) both; }
.animate .land-copy { animation: rise-in .35s .55s cubic-bezier(.2, .9, .3, 1) both; }
.animate .screen-landing > .entry { animation: rise-in .35s .75s cubic-bezier(.2, .9, .3, 1) both; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise-in { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes drop-in { from { opacity: 0; transform: translateY(-46px); } to { opacity: 1; transform: none; } }
@keyframes pop-up { from { opacity: 0; transform: translateY(70px); } to { opacity: 1; transform: none; } }

/* 생일을 고르면 그 달 등이 탁 켜져요 */
.ta .lan.mine.just .halo { animation: burst .7s ease-out both, halo 2.4s .7s ease-in-out infinite; }
.ta .lan.mine.just .litpaper { animation: fade-in .25s both; }
@keyframes burst { 0% { opacity: 0; transform: scale(.4); } 40% { opacity: .95; transform: scale(1.25); } 100% { opacity: .6; transform: scale(1); } }
.ta .lan .halo { transform-box: fill-box; transform-origin: center; }

/* 불러오는 동안: 토리가 등을 하나씩 켜요(2.6초마다 처음부터) */
.lighting .litpaper, .lighting .halo { animation: lan-on 2.6s linear infinite; }
.lighting .lans > g:nth-child(1) :is(.litpaper, .halo) { animation-delay: 0s; } .lighting .lans > g:nth-child(2) :is(.litpaper, .halo) { animation-delay: .15s; }
.lighting .lans > g:nth-child(3) :is(.litpaper, .halo) { animation-delay: .3s; } .lighting .lans > g:nth-child(4) :is(.litpaper, .halo) { animation-delay: .45s; }
.lighting .lans > g:nth-child(5) :is(.litpaper, .halo) { animation-delay: .6s; } .lighting .lans > g:nth-child(6) :is(.litpaper, .halo) { animation-delay: .75s; }
.lighting .lans > g:nth-child(7) :is(.litpaper, .halo) { animation-delay: .9s; } .lighting .lans > g:nth-child(8) :is(.litpaper, .halo) { animation-delay: 1.05s; }
.lighting .lans > g:nth-child(9) :is(.litpaper, .halo) { animation-delay: 1.2s; } .lighting .lans > g:nth-child(10) :is(.litpaper, .halo) { animation-delay: 1.35s; }
.lighting .lans > g:nth-child(11) :is(.litpaper, .halo) { animation-delay: 1.5s; } .lighting .lans > g:nth-child(12) :is(.litpaper, .halo) { animation-delay: 1.65s; }
@keyframes lan-on { 0%, 4% { opacity: 0; } 9%, 88% { opacity: 1; } 96%, 100% { opacity: 0; } }
.lighting .halo { opacity: 0; }

/* 결과가 열릴 때: 결론이 아래에서 올라오고, 좋은 달 등이 차례로 켜져요 */
.rise-in { animation: verdict-rise .6s cubic-bezier(.2, 1, .3, 1) both; }
.rise-in .lan.lit .halo, .rise-in .lan.lit .litpaper { animation: burst .7s .35s ease-out both, halo 2.4s 1.05s ease-in-out infinite; }
.rise-in .lan.lit .litpaper { animation: fade-in .3s .35s both; }
@keyframes verdict-rise { from { opacity: 0; transform: translateY(48px) scale(.98); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .ta .eyes, .ta .ear-r, .ta .lan-sw, .scene path.star, .ta .halo, .scene .tori-bob,
  .animate .hero-scene *, .animate .land-copy, .animate .screen-landing > .entry,
  .ta .lan.mine.just .litpaper, .lighting .litpaper, .lighting .halo, .rise-in, .rise-in * { animation: none !important; }
  .lighting .lans > g:nth-child(-n+6) .litpaper { opacity: 1; }
}

/* 첫 화면: 그림 위쪽 하늘에 제목을 얹어요(밤에는 밝은 글씨). 생일 칸까지 휴대폰 첫 화면에 들어와요 */
.screen-landing { padding-top: 0; }
.land-hero { position: relative; display: grid; margin: 0 -16px; }
.land-copy { position: absolute; top: 16px; left: 20px; right: 20px; display: grid; gap: 4px; justify-items: start; text-align: left; color: var(--text); }
.land-hero.is-night .land-copy { color: #fff6ef; }
.land-hero.is-night .land-copy .eyebrow { color: #ffb49c; }
.land-copy h1 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: clamp(28px, 8.2vw, 36px); line-height: 1.18; letter-spacing: -0.02em; }
.land-samples { display: grid; gap: 2px; }
.land-samples .mini { margin-top: 0; }
/* 생일 칸: 토리 말풍선 아래에서 년·월·일·시진을 골라요 */
.entry { display: grid; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.entry-ask .bub { max-width: calc(100% - 48px); }
.entry-note { font-size: 13.5px; font-weight: 700; color: var(--good); }
.ymd { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.ymd.two-col { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
.form-card .flabel { margin: 0 0 -6px; font-size: 14px; font-weight: 700; }
.ymd select, .sijin select, .entry-more input { width: 100%; min-width: 0; min-height: 50px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--card); padding: 0 12px; font-size: 16px; font-weight: 700; color: var(--text); }
.ymd select:focus, .sijin select:focus, .entry-more input:focus { outline: none; border-color: var(--coral); }
.pair-row { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 8px; }
.seg.three { grid-template-columns: repeat(3, 1fr); }
.pair-row .seg span { min-height: 46px; font-size: 15px; }
.sijin { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 10px; font-weight: 800; font-size: 14px; color: var(--sub); }
.sijin > span { white-space: nowrap; }
.entry-more summary { cursor: pointer; font-size: 13.5px; font-weight: 800; color: var(--sub); padding: 2px 2px; }
.entry-more summary small { font-weight: 600; color: var(--faint); margin-left: 4px; }
.entry-more-body { display: grid; gap: 10px; padding-top: 10px; }
.entry-more label { display: grid; gap: 6px; font-weight: 700; font-size: 14px; color: var(--sub); }
.entry .big-btn { margin-top: 2px; }

/* 홈 '앞으로 열두 달' 맛보기: 판 없이 가는 선으로 나눈 두 줄 */
.when { display: grid; gap: 2px; padding: 4px 2px 0; }
.when h2 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 24px; line-height: 1.3; margin-bottom: 6px; }
.when-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; padding: 14px 0; border-top: 1px solid var(--line); }
.when-row:last-child { border-bottom: 1px solid var(--line); }
.when-row .prod-icon { margin: 0; }
.when-row h3 { font-size: 16px; font-weight: 800; line-height: 1.4; }
.when-row p { font-size: 14.5px; color: var(--sub); margin-top: 3px; }
.when-go { display: inline-flex; align-items: center; gap: 10px; margin-top: 10px; min-height: 44px; padding: 0 16px; border: 0; border-radius: 12px; background: var(--coral); color: #fff; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 17px; }
.when-go em { font-style: normal; font-family: var(--font); font-weight: 800; font-size: 14px; white-space: nowrap; }
.when-go:active { transform: scale(.97); }

/* 풀이 목록: 썸네일 + 묻는 말 + 값을 한 줄씩. 판(카드) 없이 가는 선으로만 나눠요 */
.menu { display: grid; gap: 0; }
.menu-title { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; padding: 14px 2px 6px; }
.menu ul { list-style: none; margin: 0; padding: 0; border-top: 1.5px solid var(--text); }
.menu li { border-bottom: 1px solid var(--line); }
.ptext small .badge { margin-left: 6px; }
.prow { width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 12px 0; border: 0; background: none; text-align: left; }
.prow .prod-icon { margin: 0; }
.ptext { display: grid; gap: 1px; min-width: 0; }
.ptext b { font-size: 15.5px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ptext small { font-size: 13px; color: var(--sub); line-height: 1.45; }
.prow em { font-style: normal; font-weight: 800; font-size: 15px; color: var(--coral-ink); white-space: nowrap; }
.prow .chev svg { width: 18px; height: 18px; fill: none; stroke: var(--faint); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; display: block; }
.badge { font-style: normal; color: var(--coral-ink); font-size: 11.5px; font-weight: 800; border: 1px solid currentColor; border-radius: 6px; padding: 0 5px; line-height: 1.5; }

/* 홈 */
.hello { background: var(--peach); border-color: transparent; overflow: hidden; }
/* 홈 맨 위 그림 띠(오늘 날짜 등과 토리): 판 위쪽에 꽉 차게 */
.hello .today-scene { margin: -18px -18px 10px; width: calc(100% + 36px); max-width: none; }
.hello .score-word { font-weight: 400; color: var(--coral-ink); }
.hello-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.hello h2 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 26px; line-height: 1.3; margin-top: 4px; }
.hello-say { position: relative; margin-top: 16px; padding: 13px 15px; border-radius: 16px; background: var(--card); }
.hello-say::before { content: ""; position: absolute; top: -8px; right: 46px; width: 16px; height: 16px; background: inherit; transform: rotate(45deg); border-radius: 3px; }
.hello-say b { position: relative; display: block; font-size: 12.5px; color: var(--coral-ink); margin-bottom: 3px; }
.hello-say p { position: relative; font-size: 15px; line-height: 1.6; }
/* 오늘의 행운: 이름표가 붙은 네 칸(선으로 나눠요) */
.lucky-grid { display: grid; grid-template-columns: 1fr 1fr; margin: 0; border-top: 1px solid var(--line); }
.lucky-grid > div { display: grid; gap: 4px; align-content: start; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.lucky-grid > div:nth-child(odd) { border-right: 1px solid var(--line); padding-right: 10px; }
.lucky-grid > div:nth-child(even) { padding-left: 12px; }
.lucky-grid dt { font-size: 12px; font-weight: 800; color: var(--sub); }
.lucky-grid dd { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; font-weight: 800; font-size: 15px; }
.lk-color { display: inline-flex; align-items: center; gap: 5px; }
.lk-num { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 24px; line-height: 1.1; }
.compat-intro { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center; }
.compat-intro h3 { margin-bottom: 4px; }
.compat-intro p { font-size: 14px; color: var(--sub); line-height: 1.55; }
.compat-intro .prod-icon { margin: 0; }
.fortune-card { display: grid; justify-items: center; text-align: center; gap: 8px; }
.sticker-wall { display: flex; flex-wrap: wrap; gap: 6px; }
.sticker { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 8px; background: var(--lemon); font-weight: 800; font-size: 14px; }
.sticker:nth-child(even) { background: var(--sky); }
.sticker:nth-child(3n) { background: var(--lav); }
.sticker.good { background: var(--mint-soft); color: var(--good); }
.sticker.warn { background: var(--pink); color: var(--warn); }
.sticker.hot { background: var(--peach); color: var(--coral-ink); }
.sahwa-list { display: grid; gap: 10px; list-style: none; padding: 0; margin: 0; }
.sahwa-list li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: start; font-size: 14px; line-height: 1.55; }
.sahwa-list .sticker { white-space: nowrap; }
.dot { width: 13px; height: 13px; border-radius: 50%; display: inline-block; border: 1.5px solid rgba(0, 0, 0, .14); }
.prod-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; padding: 7px; background: var(--bg2); flex: none; }
/* 상품 그림 색: c0~c4마다 진한 색(a)·연한 색(b)·포인트(c) */
.art svg { width: 100%; height: 100%; display: block; overflow: visible; }
.art .a { fill: var(--art-a); } .art .b { fill: var(--art-b); } .art .c { fill: var(--art-c); } .art .w { fill: #fff; }
.art .round { stroke: var(--art-a); stroke-width: 3; stroke-linejoin: round; }
.art .ln { fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; }
.art .ln.dark { stroke: var(--art-a); stroke-width: 3.2; }
.art { --art-a: #ff7a59; --art-b: #ffc0a8; --art-c: #e0483a; }
.c1 .art, .art.c1 { --art-a: #4f86e0; --art-b: #a9cbf5; --art-c: #ffc44d; }
.c2 .art, .art.c2 { --art-a: #ff5f8a; --art-b: #ffb3c7; --art-c: #ff5f8a; }
.c3 .art, .art.c3 { --art-a: #2fb487; --art-b: #a3e6cc; --art-c: #ff7a59; }
.c4 .art, .art.c4 { --art-a: #8a6cf0; --art-b: #cdbdff; --art-c: #ffc44d; }
.me-card { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center; }
.me-card h3 { margin: 2px 0 0; font-size: 19px; }
.me-tiles { display: flex; gap: 6px; }
.tile { display: grid; place-items: center; width: 46px; aspect-ratio: 1; border-radius: 12px; color: #fff; font-weight: 800; font-size: 23px; font-family: "Noto Serif KR", "Batang", serif; }
.tile.big { width: 58px; font-size: 30px; border-radius: 14px; }
.tile.wood { background: var(--wood); } .tile.fire { background: var(--fire); } .tile.earth { background: var(--earth); }
.tile.metal { background: var(--metal); color: var(--metal-fg); } .tile.water { background: var(--water); }
.tile.empty { background: var(--bg2); color: var(--faint); font-family: var(--font); font-size: 15px; }
.ask-top { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.ask-top .av { width: 52px; height: 52px; }
.ask-top b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; }
.ask-top p { font-size: 14px; color: var(--sub); }

/* 운세 */
.date-nav { display: flex; gap: 8px; align-items: center; }
.date-nav input { flex: 1; min-width: 0; min-height: 46px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--card); padding: 0 14px; }
.round { width: 46px; height: 46px; flex: none; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--card); font-size: 22px; line-height: 1; color: var(--coral-ink); font-weight: 800; }
.factors { list-style: none; margin: 0; padding: 0; display: grid; }
.factors li { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.factors li:first-child { border-top: 0; padding-top: 0; }
.up { color: var(--good); } .down { color: var(--warn); }
.flow p { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tag { display: inline-block; padding: 0 7px; border-radius: 6px; font-size: 12.5px; font-weight: 800; background: var(--bg2); color: var(--sub); }

/* 직장운·재회운: 결론, 달 칸, 신호 */
.verdict { border: 1.5px solid var(--coral-2); }
.verdict-line { font-size: 17px; font-weight: 800; line-height: 1.55; margin: 6px 0 4px; }
.verdict-grid { margin: 12px 0 0; display: grid; border-top: 1px solid var(--line); }
.verdict-grid > div { display: grid; grid-template-columns: 7.2em minmax(0, 1fr); gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.verdict-grid dt { font-size: 13px; font-weight: 800; color: var(--sub); padding-top: 2px; }
.verdict-grid dd { margin: 0; display: grid; gap: 1px; }
.verdict-grid dd b { font-size: 16px; }
.verdict-grid dd span { font-size: 13.5px; color: var(--sub); }
.verdict-grid .warn dt { color: var(--warn); }
.mk { font-style: normal; font-size: 13px; margin-left: 2px; }
.mk.star { color: #c58a00; }
.mk.aux { color: var(--warn); }
.legend-note { margin-top: 8px; font-size: 12.5px; color: var(--sub); line-height: 1.6; }
.month-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.mcell { display: grid; gap: 3px; justify-items: center; align-content: start; padding: 8px 3px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-align: center; min-width: 0; }
.mcell b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 16px; }
.mcell small { font-size: 11.5px; color: var(--faint); }
.mcell .tag { font-size: 10.5px; padding: 0 4px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mcell.on { background: var(--peach); }
.mcell .mark { font-size: 20px; line-height: 1; color: var(--sub); }
.mcell.grade.on .mark { color: var(--coral-ink); }
.tag.change { background: var(--sky); color: #2c5a9e; }
.tag.rise { background: var(--mint-soft); color: var(--good); }
.tag.exit { background: var(--lemon); color: #7a5000; }
.tag.caution { background: var(--pink); color: var(--warn); }
.counts { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.mini-list { margin: 8px 0 0; padding-left: 18px; color: var(--sub); font-size: 14px; display: grid; gap: 4px; }
.sustain { margin-top: 12px; font-size: 14.5px; }
.pair-facts { margin: 0 0 6px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pair-facts dt { font-size: 12px; font-weight: 800; color: var(--sub); }
.pair-facts dd { margin: 0; font-weight: 700; font-size: 14.5px; }
/* 신호 한 칸: 왼쪽 색띠 대신 작은 갈래 이름과 가는 선으로 나눠요 */
.sig { padding: 11px 0 10px; border-top: 1px solid var(--line); }
.sig:first-of-type { border-top: 0; }
details.topic .sig:first-of-type, .card > h3 + .sig { border-top: 0; padding-top: 4px; }
.sig-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 6px; }
.sig-title b { font-size: 15px; }
.sig-title small { font-size: 12px; color: var(--faint); }
.sig-kind { font-size: 11.5px; font-weight: 800; color: var(--sub); }
.sig-kind::after { content: "·"; margin-left: 6px; color: var(--faint); }
.sig.reunion .sig-kind, .sig.rise .sig-kind, .sig.base .sig-kind { color: var(--good); }
.sig.caution .sig-kind, .sig.conflict .sig-kind, .sig.ended .sig-kind { color: var(--warn); }
.sig.change .sig-kind, .sig.moving .sig-kind { color: #3c6fc0; }
.sig.exit .sig-kind, .sig.contact .sig-kind { color: #a26c00; }
.sig > p { margin-top: 3px; font-size: 14.5px; }
.sig-fact { display: block; margin-top: 4px; font-size: 12px; color: var(--faint); }
.tag.favorable { background: var(--mint-soft); color: var(--good); }
.tag.unfavorable { background: var(--pink); color: var(--warn); }
.reunion-who p { font-size: 14.5px; }
.reunion-who .text-btn { margin-top: 4px; padding-left: 0; justify-self: start; display: block; }

/* 상담 */
.screen-chat { padding-bottom: 8px; }
.chat-head { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: var(--r-xl); background: var(--sky); }
.chat-head img { width: 64px; height: 64px; border-radius: 50%; background: var(--card); }
.chat-head h1 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 24px; }
.chat-head p { font-size: 13.5px; color: var(--sub); }
.chat-thread { padding: 4px 0; }
.starters { padding-left: 48px; }
.composer { position: sticky; bottom: calc(70px + env(safe-area-inset-bottom)); z-index: 5; display: flex; gap: 8px; padding: 8px 0; background: var(--bg); }

/* 궁합 */
.love { text-align: center; background: var(--pink); border-color: transparent; display: grid; gap: 6px; }
.pair { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 8px; }
.pair small { display: block; color: var(--sub); font-size: 12.5px; }
.bubble-name { display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: top; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 20px; }
.heart svg { width: 36px; height: 36px; fill: var(--coral); stroke: none; }
.love-score b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 72px; line-height: 1; color: var(--coral-ink); }
.love-score { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; }
.love-grade { font-weight: 800; color: var(--good); }
.love h2 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; margin-top: 6px; }
.meter { display: grid; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.meter:first-of-type { border-top: 0; padding-top: 0; }
.meter-head { display: flex; justify-content: space-between; }
.meter p { font-size: 13.5px; color: var(--sub); }
.track { height: 10px; border-radius: 999px; background: var(--bg2); overflow: hidden; }
.fill { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--coral); transition: width .6s cubic-bezier(.2, 1, .3, 1); }
.form-card { display: grid; gap: 12px; }
.form-card label { display: grid; gap: 6px; font-weight: 700; font-size: 14px; color: var(--sub); }
.form-card input, .form-card select { min-width: 0; min-height: 48px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--card); padding: 0 14px; font-size: 16px; color: var(--text); }
.form-card .hint { margin-top: 0; }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1.5px solid var(--line-strong); border-radius: 14px; overflow: hidden; }
.seg label { position: relative; display: block; }
.seg label + label { border-left: 1.5px solid var(--line-strong); }
.seg input { position: absolute; inset: 0; opacity: 0; }
.seg span { display: grid; place-items: center; min-height: 44px; font-weight: 800; color: var(--sub); }
.seg input:checked + span { background: var(--peach); color: var(--coral-ink); }
.seg input:focus-visible + span { outline: 3px solid var(--coral); outline-offset: -3px; }
.big-btn { width: 100%; min-height: 54px; border: 0; border-radius: 16px; background: var(--coral); color: #fff; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 20px; transition: transform .12s ease, opacity .12s ease; }
.big-btn:disabled { opacity: .45; }
.big-btn.soft { background: var(--peach); color: var(--coral-ink); }

/* 더보기 */
.segment { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-bottom: 1px solid var(--line); }
.segment button { border: 0; background: transparent; min-height: 44px; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 17px; color: var(--sub); border-bottom: 3px solid transparent; margin-bottom: -1px; }
.segment button[aria-selected="true"] { color: var(--coral-ink); border-bottom-color: var(--coral); }
.pillar-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.col { position: relative; display: grid; justify-items: center; gap: 5px; padding: 12px 0 10px; border-radius: 16px; background: var(--bg2); }
.col.me { background: var(--peach); box-shadow: inset 0 0 0 2px var(--coral); }
.col small { font-size: 12.5px; font-weight: 700; color: var(--sub); }
.col-label { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 15px; color: var(--sub); }
.crown { position: absolute; top: -9px; background: var(--coral); color: #fff; font-size: 11px; font-weight: 800; border-radius: 6px; padding: 0 6px; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 14px; border-top: 1px solid var(--line); }
.facts span { display: grid; gap: 2px; padding: 10px 4px 0; text-align: center; }
.facts span + span { border-left: 1px solid var(--line); }
.facts small { font-size: 11.5px; color: var(--sub); font-weight: 700; }
.facts b { font-size: 15px; }
.year-rail { display: flex; gap: 0; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.year-rail::-webkit-scrollbar { display: none; }
.year-pill { flex: none; display: grid; justify-items: center; gap: 2px; padding: 10px 12px; min-width: 72px; }
.year-pill + .year-pill { border-left: 1px solid var(--line); }
.year-pill small { font-size: 12px; color: var(--sub); }
.year-pill b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; }
.year-pill.now { background: var(--peach); }
details.topic { padding: 12px 0; border-top: 1px solid var(--line); }
.card > h3 + details.topic, .card > details.topic:first-of-type { border-top: 0; padding-top: 2px; }
details.topic summary { list-style: none; cursor: pointer; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 17px; display: flex; justify-content: space-between; gap: 8px; }
details.topic summary small { font-family: var(--font); font-size: 12.5px; color: var(--faint); }
details.topic summary::-webkit-details-marker { display: none; }
details.topic summary::after { content: "+"; color: var(--coral-ink); }
details.topic[open] summary::after { content: "−"; }
.topic-body { display: grid; gap: 8px; margin-top: 10px; font-size: 14.5px; color: var(--sub); }
.topic-body b { color: var(--text); }
.board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: repeat(4, minmax(78px, auto)); gap: 4px; }
.palace { display: grid; align-content: start; gap: 2px; padding: 7px 6px; border-radius: 10px; background: var(--bg2); min-width: 0; }
.palace .p-name { font-size: 11px; font-weight: 800; color: var(--sub); }
.palace b { font-size: 13px; line-height: 1.3; }
.palace small { font-size: 10.5px; color: var(--faint); line-height: 1.3; }
.palace.life { background: var(--pink); box-shadow: inset 0 0 0 2px var(--coral); }
.palace.body { box-shadow: inset 0 0 0 2px var(--mint); }
.palace.life.body { box-shadow: inset 0 0 0 2px var(--coral), inset 0 0 0 4px var(--mint); }
.palace.now { background: var(--lemon); }
.palace.life.now { background: var(--lemon); }
.marks { display: flex; flex-wrap: wrap; gap: 2px; }
.marks i, .lg.mark { font-style: normal; font-size: 10.5px; font-weight: 800; background: var(--coral); color: #fff; border-radius: 4px; padding: 0 4px; }
.board-center { grid-column: 2 / 4; grid-row: 2 / 4; border-radius: 12px; background: var(--peach); display: grid; place-content: center; text-align: center; gap: 0; }
.board-center b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; }
.board-center span { font-size: 12px; color: var(--sub); margin-bottom: 6px; }
.legend { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; font-size: 12px; color: var(--sub); }
.legend span { display: inline-flex; align-items: center; gap: 4px; }
.lg { display: inline-block; width: 13px; height: 13px; border-radius: 4px; }
.lg.life { background: var(--pink); box-shadow: inset 0 0 0 2px var(--coral); }
.lg.body { box-shadow: inset 0 0 0 2px var(--mint); }
.lg.now { background: var(--lemon); }
.lg.mark { width: auto; height: auto; }
.lg.son-dot { border-radius: 50%; background: var(--mint); width: 9px; height: 9px; }
.lg.match { background: var(--mint-soft); box-shadow: inset 0 0 0 1.5px var(--mint); }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.cal-head h3 { margin: 0; flex: 1; text-align: center; justify-content: center; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-top: 10px; }
.dow { text-align: center; font-size: 12px; font-weight: 800; color: var(--sub); }
.dow.sun, .day.sun b { color: var(--warn); } .dow.sat, .day.sat b { color: #4a7fd6; }
.day { position: relative; display: grid; justify-items: center; align-content: center; gap: 0; min-height: 52px; border: 0; border-radius: 10px; background: var(--bg2); padding: 4px 0; }
.day b { font-size: 15px; line-height: 1.2; }
.day small { font-size: 10px; color: var(--faint); font-weight: 700; }
.day .son { position: absolute; top: 5px; right: 6px; width: 7px; height: 7px; border-radius: 50%; background: var(--mint); }
.day.match { background: var(--mint-soft); box-shadow: inset 0 0 0 1.5px var(--mint); }
.day.today { box-shadow: inset 0 0 0 2px var(--coral); }
.day.picked { background: var(--coral); }
.day.picked b, .day.picked small { color: #fff; }
.good-days { list-style: none; margin: 0; padding: 0; display: grid; }
.good-days li { display: flex; justify-content: space-between; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.good-days li:first-child { border-top: 0; }

/* 알림 */
.toast { position: fixed; left: 50%; top: calc(14px + env(safe-area-inset-top)); transform: translateX(-50%); z-index: 50; width: max-content; max-width: min(90vw, 380px); padding: 11px 18px; border-radius: 14px; background: #3b2a24; color: #fff; font-weight: 700; font-size: 14px; text-align: center; }

/* 움직임: 화면이 바뀔 때만 톡 튀어나와요 */
.animate .pop { animation: pop .45s cubic-bezier(.2, 1.3, .4, 1) both; }
.animate .screen > .pop:nth-child(2) { animation-delay: .04s; }
.animate .screen > .pop:nth-child(3) { animation-delay: .08s; }
.animate .screen > .pop:nth-child(4) { animation-delay: .12s; }
.bounce { animation: bounce 2.6s ease-in-out infinite; }
@keyframes pop { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes blink { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .animate .pop, .bounce, .bub.dots i { animation: none; }
  .fill { transition: none; }
}

/* ── 불러오는 중 점 세 개 ── */
.bub.dots.solo { border: 0; background: transparent; }
/* 고른 값이 맞지 않을 때 칸 아래 안내 */
.field-err { font-size: 13.5px; font-weight: 700; color: var(--warn); padding: 2px 2px; }
.form-card input[aria-invalid="true"], .code-form input[aria-invalid="true"] { border-color: var(--warn); }

/* ── 작은 단추 ── */
.mini-btn { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; border: 1px solid var(--line-strong); border-radius: 12px; padding: 6px 12px; background: var(--card); color: var(--coral-ink); font-weight: 800; font-size: 13.5px; }
.mini-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mini-btn.center { justify-self: center; }
.text-btn { border: 0; background: none; color: var(--sub); font-weight: 700; padding: 10px; justify-self: center; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-strong); }
.chips-row.center { justify-content: center; }
.hero-char.sm { width: 80px; height: 80px; }
.err { color: var(--faint); font-size: 12.5px; font-family: var(--font); }
.err-bub { display: grid; gap: 8px; justify-items: start; }

/* ── 출석 도장 ── */
.stamp-head h3 { margin-bottom: 6px; }
.stamp-talk { margin-top: 10px; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 16px; color: var(--text); }

/* ── 내일 또 와요: 색칠한 상자 대신 점선 한 줄 위에 ── */
.nudge { display: flex; align-items: center; gap: 12px; padding: 14px 2px 4px; border-top: 1px dashed var(--line-strong); }
.nudge .nudge-tori { flex: none; width: 46px; height: 58px; }
.nudge b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 18px; }
.nudge p { font-size: 13.5px; color: var(--sub); }

/* ── 운세 화면 캐릭터 ── */
.fortune-card { position: relative; }
.fortune-char { position: absolute; top: 8px; right: 10px; width: 62px; height: 78px; }

/* ── 상품 페이지 ── */
.back-btn { justify-self: start; display: inline-flex; align-items: center; gap: 2px; border: 0; background: none; padding: 4px 8px 4px 0; font-weight: 800; color: var(--sub); }
.back-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
/* 상품 머리: 그림 띠(토리 + 상품 그림을 품은 큰 등) 아래에 묻는 말·이름·값. 색칠한 상자 없이 */
.prod-hero { position: relative; display: grid; justify-items: center; text-align: center; gap: 4px; padding: 0 4px 6px; }
.prod-scene { position: relative; width: calc(100% + 32px); margin: -4px -16px 6px; }
.prod-scene .prod-icon.big { position: absolute; left: 61.5%; top: 36%; width: 15%; height: auto; aspect-ratio: 1; padding: 0; transform: translate(-50%, -50%); background: transparent; border-radius: 0; }
.prod-ask { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; color: var(--coral-ink) !important; font-size: 16px !important; }
.prod-hero .badge { position: absolute; top: 12px; left: 14px; background: var(--card); }
.prod-icon.big { width: 72px; height: 72px; border-radius: 20px; padding: 11px; margin: 0; background: var(--card); }
.prod-hero h1 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 28px; line-height: 1.25; }
.prod-hero p { color: var(--sub); font-size: 14.5px; }
.price-chip { margin-top: 4px; display: inline-block; color: var(--coral-ink); font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; }
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.points li { position: relative; padding-left: 26px; font-size: 15px; }
.points li::before { content: ""; position: absolute; left: 3px; top: 7px; width: 7px; height: 11px; border: solid var(--good); border-width: 0 2.5px 2.5px 0; transform: rotate(40deg); }
.preview { display: grid; gap: 12px; }
.preview > .mini { margin: 0 2px; }
.deep { display: grid; gap: 14px; }

/* 잠긴 부분: 본문 대신 차례와 결제 단추 하나 */
.lock-card { display: grid; gap: 12px; border: 1.5px dashed var(--line-strong); background: var(--card); }
.lock-head { display: flex; gap: 12px; align-items: center; }
.lock-head b { display: block; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; line-height: 1.35; }
.lock-lan { width: 44px; height: 52px; flex: none; }
.toc { margin: 0; padding: 0; list-style: none; counter-reset: toc; border-top: 1px solid var(--line); }
.toc li { counter-increment: toc; display: grid; grid-template-columns: 1.6em minmax(0, 1fr); gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; color: var(--sub); }
.toc li::before { content: counter(toc); font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; color: var(--coral-ink); }
.lock-card .text-btn { padding: 2px; }
.order-note { border: 1.5px solid var(--mint); }
.order-note p:not(.eyebrow) { font-size: 14px; color: var(--sub); margin-top: 6px; }
.order-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; }
.order-row code, .order-list code { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; font-size: 14px; background: var(--bg2); border-radius: 6px; padding: 3px 8px; overflow-wrap: anywhere; }
.order-row .mini-btn { margin-top: 0; }

/* 맨 아래: 다시 열기·약관·사업자 정보 */
.page-foot { display: grid; gap: 8px; justify-items: center; text-align: center; padding: 10px 4px 4px; margin-top: 4px; border-top: 1px solid var(--line); }
.restore-link { border: 0; background: none; color: var(--coral-ink); font-weight: 800; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; padding: 4px; }
.legal-foot { display: grid; gap: 6px; justify-items: center; }
.legal-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; font-size: 12.5px; }
.legal-links a { color: var(--sub); text-decoration: none; }
.legal-links a b { font-weight: 800; }
.biz { font-size: 11.5px; color: var(--faint); line-height: 1.6; max-width: 34em; }
.biz span { display: inline-block; margin: 0 4px; }

/* ── 아래에서 올라오는 판(결제 확인·다시 열기·공유) ── */
.sheet-backdrop { position: fixed; inset: 0; z-index: 30; background: rgba(40, 20, 15, .45); animation: fade .2s ease; }
.sheet { position: fixed; z-index: 31; left: 50%; bottom: 0; transform: translateX(-50%); width: min(100%, 480px); max-height: 90dvh; overflow-y: auto; display: grid; gap: 14px; padding: 10px 20px calc(20px + env(safe-area-inset-bottom)); border-radius: 24px 24px 0 0; background: var(--card); animation: rise .28s cubic-bezier(.2, 1, .3, 1); }
.grab { justify-self: center; width: 44px; height: 5px; border-radius: 999px; background: var(--line-strong); }
.sheet-head { display: flex; align-items: center; gap: 12px; }
.sheet-head .sheet-tori { width: 58px; height: 72px; flex: none; margin-top: -18px; }
.sheet-head h2 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 23px; line-height: 1.25; }
.sheet-note { text-align: center; font-size: 12.5px; color: var(--faint); margin-top: -6px; }
.sheet-text { font-size: 14px; color: var(--sub); }
.checkout { margin: 0; display: grid; border-top: 1px solid var(--line); }
.checkout > div { display: grid; grid-template-columns: 5.2em minmax(0, 1fr); gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.checkout dt { color: var(--sub); font-weight: 700; }
.checkout dd { margin: 0; }
.checkout dd b { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; color: var(--coral-ink); line-height: 1.2; }
.refund { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 13px; color: var(--sub); }
.agree { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: start; font-size: 14px; font-weight: 700; padding: 10px 12px; border-radius: 14px; background: var(--bg2); }
.agree input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--coral); }
.agree a { color: var(--coral-ink); font-weight: 700; }
.code-form { display: grid; gap: 8px; padding-top: 12px; border-top: 1px dashed var(--line-strong); }
.code-form label { font-size: 13.5px; font-weight: 800; color: var(--sub); }
.code-form input { flex: 1; min-width: 0; min-height: 48px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--card); padding: 0 14px; font-size: 16px; letter-spacing: .04em; text-transform: uppercase; }
.code-form input::placeholder { text-transform: none; letter-spacing: 0; }
.code-btn { flex: none; min-width: 72px; border: 0; border-radius: 14px; background: var(--text); color: var(--card); font-weight: 800; padding: 0 16px; }
.code-btn:disabled { opacity: .5; }
.order-list { list-style: none; margin: -4px 0 0; padding: 0; display: grid; gap: 6px; }
.order-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 12.5px; color: var(--sub); }
/* 앱 안 브라우저 결제 안내(core.js payHere). 브라우저 기본 dialog 창이라 맨 위에 떠요. */
.inapp { width: min(92vw, 380px); max-height: 88dvh; overflow-y: auto; padding: 24px 20px 14px; border: 0; border-radius: var(--r-xl); background: var(--card); color: var(--text); }
.inapp::backdrop { background: rgba(40, 20, 15, .45); }
.inapp h2 { padding-right: 34px; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; line-height: 1.3; word-break: keep-all; }
.inapp p { margin-top: 10px; color: var(--sub); font-size: 14.5px; line-height: 1.6; word-break: keep-all; }
.inapp .inapp-note { font-size: 12.5px; color: var(--faint); }
.inapp-main { width: 100%; min-height: 52px; margin-top: 16px; border: 0; border-radius: 16px; background: var(--coral); color: #fff; font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 19px; }
.inapp-sub { display: block; margin: 6px auto 0; padding: 10px; border: 0; background: none; color: var(--sub); font-weight: 700; font-size: 14px; }
.inapp-close { position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--bg2); color: var(--sub); font-size: 20px; line-height: 1; }
.share-sheet h2 { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 22px; text-align: center; }
.share-preview { justify-self: center; width: min(62vw, 270px); height: auto; aspect-ratio: 1080 / 1350; border-radius: 16px; border: 1px solid var(--line); }
.share-actions { display: grid; gap: 8px; }
.share-actions .big-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.share-actions svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
@keyframes rise { from { transform: translate(-50%, 40px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ── 상담 무료 횟수 ── */
.quota { justify-self: center; font-size: 12.5px; font-weight: 800; color: var(--coral-ink); }

@media (prefers-reduced-motion: reduce) {
  .sheet, .sheet-backdrop { animation: none; }
}

/* ── 3차 디자인 체계: 990원이어도 값비싸 보이게 ──
   1) 글자 단계: 화면 제목 26 · 절 제목 20 · 소제목 16.5 · 본문 15.5 · 보조 13.5 · 작은 이름표 12(자간 넓게). 굵기는 800·700·500 세 단계.
   2) 판: 둥근 판을 겹겹이 쌓지 않고, 절마다 가는 선으로 나눠요. 판이 필요한 곳(오늘 점수·결론·결제 확인)만 모서리 12px 하나로.
   3) 단추: 주 단추는 밤하늘 남색, 값은 주홍. 둘째 단추는 가는 선. 알약 모양은 쓰지 않아요.
   4) 이름표·스티커: 색칠한 상자 대신 글자 색과 가운뎃점(·)으로. */
:root { --on-night: #fff; }
body { font-size: 15.5px; line-height: 1.65; letter-spacing: -0.012em; font-feature-settings: "tnum" 0; }
.land-copy h1, .brand { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; }
.brand { font-size: 21px; }
.seal { background: var(--night); color: var(--on-night); border-radius: 9px; font-size: 14px; }
.screen-title { font-size: 26px; letter-spacing: -0.035em; padding-top: 8px; }
.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .06em; color: var(--coral-ink); }
.mini { font-size: 12px; font-weight: 700; letter-spacing: .05em; color: var(--sub); }
.hint { font-size: 12.5px; color: var(--faint); line-height: 1.55; }
b, strong { font-weight: 700; }

/* 판 → 절: 카드는 배경·테두리 없이 위쪽 가는 선으로 나눠요 */
.card { background: transparent; border: 0; border-top: 1px solid var(--line); border-radius: 0; padding: 20px 2px 4px; }
.card h3 { font-size: 17px; letter-spacing: -0.03em; margin-bottom: 12px; }
.screen { gap: 18px; }
/* 판이 필요한 곳 */
.hello, .verdict, .lock-card, .order-note, .love { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.verdict { border-color: var(--night); border-width: 1.5px; }
.lock-card { background: var(--bg2); border: 1px solid var(--line); }
.form-card { border-top: 0; padding-top: 4px; }

/* 숫자는 자리 맞춤 */
.score-num, .gauge b, .love-score b, .price-chip, .prow em, .checkout dd b, .lucky-grid dd, .when-go em, .lk-num, .mcell b, .day b, .year-pill b { font-variant-numeric: tabular-nums; }

/* 단추 */
.big-btn { background: var(--night); color: var(--on-night); font-family: var(--font); font-weight: 700; font-size: 17px; letter-spacing: -0.02em; border-radius: 12px; min-height: 54px; }
.big-btn.soft { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line-strong); }
.when-go { background: var(--night); color: var(--on-night); font-family: var(--font); font-weight: 700; font-size: 15px; border-radius: 10px; }
.when-go em { color: #f6c4b4; font-weight: 700; }
.pick { border: 1px solid var(--line-strong); color: var(--text); border-radius: 10px; font-weight: 600; font-size: 14.5px; padding: 8px 14px; background: var(--card); }
.pick.go, .pick.on { background: var(--night); border-color: var(--night); color: var(--on-night); }
.pick.ghost { border-style: solid; color: var(--sub); }
.pick small { color: var(--faint); font-weight: 500; }
.mini-btn { border-radius: 10px; color: var(--text); font-weight: 600; border-color: var(--line-strong); }
.send { background: var(--night); color: var(--on-night); border-radius: 12px; }
.round { border-radius: 10px; color: var(--text); font-weight: 600; }
.text-btn { color: var(--sub); font-weight: 600; }

/* 입력칸: 브라우저 기본 모양 대신 사이트 결에 맞춘 고르기 칸 */
.ymd select, .sijin select, .form-card select, .form-card input, .entry-more input, .composer input, .code-form input, .date-nav input {
  -webkit-appearance: none; appearance: none; border: 1px solid var(--line-strong); border-radius: 12px; background-color: var(--card); color: var(--text); font-weight: 600; min-height: 52px;
}
.ymd select, .sijin select, .form-card select {
  padding-right: 34px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%235f5662' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center; background-size: 11px 8px;
}
.ymd select:focus, .sijin select:focus, .form-card select:focus, .form-card input:focus, .composer input:focus, .code-form input:focus { outline: none; border-color: var(--night); box-shadow: inset 0 0 0 1px var(--night); }
.seg { border: 1px solid var(--line-strong); border-radius: 12px; background: var(--card); }
.seg label + label { border-left: 1px solid var(--line); }
.seg span { font-weight: 600; color: var(--sub); }
.seg input:checked + span { background: var(--night); color: var(--on-night); }

/* 대화 말풍선 */
.bub { border-radius: 16px 16px 16px 4px; }
.bub > b { font-size: 12px; letter-spacing: .03em; color: var(--sub); }
.mine .bub { background: var(--night); border-color: var(--night); color: var(--on-night); font-weight: 500; border-radius: 16px 16px 4px 16px; }
.av { background: var(--bg2); }

/* 이름표·스티커 → 글자 */
.sticker-wall { gap: 2px 0; }
.sticker, .sticker:nth-child(even), .sticker:nth-child(3n) { background: none; padding: 0; border-radius: 0; font-weight: 600; font-size: 14.5px; color: var(--text); }
.sticker + .sticker::before { content: "·"; margin: 0 8px; color: var(--faint); font-weight: 400; }
.sticker.good { color: var(--good); } .sticker.warn { color: var(--warn); } .sticker.hot { color: var(--coral-ink); }
.tag, .tag.change, .tag.rise, .tag.exit, .tag.caution, .tag.favorable, .tag.unfavorable { background: none; padding: 0; border-radius: 0; font-size: 12.5px; font-weight: 700; color: var(--sub); }
.tag.rise, .tag.favorable { color: var(--good); } .tag.caution, .tag.unfavorable { color: var(--warn); } .tag.change { color: var(--night); } .tag.exit { color: #8a6418; }
.badge { border-radius: 4px; font-size: 10.5px; letter-spacing: .06em; padding: 0 4px; }

/* 상품 아이콘: 한 벌로 그린 가는 선 아이콘(같은 굵기) */
.prod-icon { width: 44px; height: 44px; border-radius: 12px; padding: 10px; background: var(--bg2); color: var(--text); }
.prod-icon svg { width: 100%; height: 100%; display: block; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.prod-icon svg .dot { fill: var(--coral); stroke: none; }
.prod-scene .prod-icon.big { background: transparent; color: #221c26; padding: 0; }

/* 목록·맛보기 */
.menu-title { font-size: 13px; letter-spacing: .06em; color: var(--sub); padding: 18px 2px 8px; }
.menu ul { border-top: 1px solid var(--text); }
.ptext b { font-size: 15.5px; font-weight: 700; letter-spacing: -0.02em; }
.prow em { font-weight: 700; color: var(--text); }
.when h2 { font-size: 22px; letter-spacing: -0.035em; }
.when-row h3 { font-weight: 700; }

/* 오늘 점수: 도넛 대신 큰 숫자 + 등 열 개(10점마다 하나, 반올림) */
.score-line { display: flex; align-items: baseline; gap: 10px; margin-top: 4px; }
.score-num { font-size: 54px; font-weight: 800; line-height: 1; letter-spacing: -0.05em; color: var(--text); }
.score-num small { font-size: 18px; font-weight: 700; margin-left: 2px; letter-spacing: 0; }
.score-band { font-size: 15px; font-weight: 700; color: var(--coral-ink); }
.meter-lans { display: block; width: 100%; max-width: 330px; height: auto; margin-top: 8px; }
.meter-note { font-size: 12px; color: var(--faint); margin-top: 2px; }
.hello h2 { font-size: 21px; letter-spacing: -0.035em; }
.hello .score-word { color: var(--text); }
.hello-say { background: var(--bg2); border-radius: 12px; }
.hello-say::before { display: none; }
.hello-say b { color: var(--sub); letter-spacing: .04em; }
.talk { font-weight: 700; font-size: 17px; }
.fortune-card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px 18px; }

/* 네 기둥·다섯 기운 */
.col { background: transparent; border: 1px solid var(--line); border-radius: 12px; }
.col.me { background: var(--card); box-shadow: inset 0 0 0 1.5px var(--night); }
.crown { background: var(--night); color: var(--on-night); border-radius: 4px; }
.col-label { font-weight: 700; letter-spacing: .04em; }
.tile { border-radius: 10px; font-weight: 700; }
.el-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.el-bars li { display: grid; grid-template-columns: 2.6em minmax(0, 1fr) 4.2em; gap: 10px; align-items: center; font-size: 14px; }
.el-bars b { font-weight: 700; }
.el-bars .bar { height: 8px; border-radius: 4px; background: var(--bg2); overflow: hidden; }
.el-bars .bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--el, var(--night)); }
.el-bars em { font-style: normal; font-variant-numeric: tabular-nums; color: var(--sub); text-align: right; font-size: 13px; }
.el-bars .wood { --el: var(--wood); } .el-bars .fire { --el: var(--fire); } .el-bars .earth { --el: var(--earth); } .el-bars .metal { --el: #a99f94; } .el-bars .water { --el: var(--water); }

/* 달력·명반: 색칠한 칸 대신 가는 선 격자 */
.day { background: transparent; border-radius: 10px; }
.day.today { box-shadow: inset 0 0 0 1.5px var(--night); }
.day.picked { background: var(--night); }
.day.match { background: var(--bg2); box-shadow: none; }
.day .son { background: var(--coral); width: 5px; height: 5px; }
.lg.son-dot { background: var(--coral); }
.palace { background: transparent; border: 1px solid var(--line); border-radius: 8px; }
.palace.life { background: var(--card); box-shadow: inset 0 0 0 1.5px var(--night); }
.palace.now, .palace.life.now { background: var(--bg2); }
.board-center { background: var(--bg2); }
.marks i, .lg.mark { background: var(--night); color: var(--on-night); }
.lg.life { background: var(--card); box-shadow: inset 0 0 0 1.5px var(--night); }
.lg.now { background: var(--bg2); }
.segment button { font-size: 15px; font-weight: 700; }
.segment button[aria-selected="true"] { color: var(--text); border-bottom-color: var(--night); }
.mcell.on { background: var(--bg2); }
.year-pill.now { background: var(--bg2); }
details.topic summary { font-size: 16px; }
details.topic summary::after { color: var(--sub); }

/* 상담·궁합 머리 */
.chat-head { background: transparent; border-bottom: 1px solid var(--line); border-radius: 0; padding: 4px 2px 14px; }
.chat-head h1 { font-size: 20px; }
.love { text-align: center; }
.love-score b { font-family: var(--font); font-weight: 800; font-size: 64px; letter-spacing: -0.05em; color: var(--text); }
.love-score { font-family: var(--font); font-size: 18px; font-weight: 700; }
.love-grade { color: var(--coral-ink); font-weight: 700; }
.heart svg { fill: var(--coral); }
.fill { background: var(--night); }
.track { height: 8px; border-radius: 4px; }

/* 출석: 이번 주 들른 날마다 등이 켜져요 */
.week-lans { display: block; width: 100%; height: auto; }
.stamp-talk { font-weight: 600; font-size: 14.5px; color: var(--sub); }

/* 리포트처럼: 장 번호 */
.chap-n { display: inline-block; min-width: 1.9em; margin-right: 6px; font-weight: 800; color: var(--coral-ink); font-variant-numeric: tabular-nums; }
.verdict .eyebrow .chap-n { margin-right: 4px; }
.report-head { display: grid; gap: 2px; padding: 4px 2px 0; }
.report-head small { font-size: 12px; color: var(--sub); letter-spacing: .05em; }

/* 결제 확인 판: 영수증처럼 또렷하게 */
.sheet { border-radius: 18px 18px 0 0; gap: 16px; }
.sheet-head h2 { font-size: 21px; letter-spacing: -0.035em; }
.receipt { margin: 0; display: grid; border-top: 1.5px solid var(--text); }
.receipt > div { display: grid; grid-template-columns: 6em minmax(0, 1fr); gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.receipt dt { color: var(--sub); font-weight: 600; }
.receipt dd { margin: 0; }
.receipt .total { border-bottom: 1.5px solid var(--text); align-items: baseline; }
.receipt .total dt { color: var(--text); font-weight: 700; }
.receipt .total dd b { font-size: 26px; font-weight: 800; letter-spacing: -0.04em; color: var(--text); font-variant-numeric: tabular-nums; }
.refund { font-size: 13px; line-height: 1.6; }
.agree { background: transparent; border: 1px solid var(--line-strong); border-radius: 12px; font-weight: 600; }
.agree input { accent-color: var(--night); }
.agree a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.code-btn { background: var(--night); color: var(--on-night); border-radius: 12px; font-weight: 700; }
.toast { background: var(--night); color: var(--on-night); border-radius: 12px; font-weight: 600; }

/* 리포트 머리와 차례 */
.report-head { border-top: 1.5px solid var(--text); padding: 16px 2px 4px; gap: 4px; }
.report-head h2 { font-size: 24px; font-weight: 800; letter-spacing: -0.04em; }
.report-toc { list-style: none; margin: 10px 0 0; padding: 0; display: grid; border-top: 1px solid var(--line); }
.report-toc li { padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--sub); }
.points.compact { gap: 4px; }
.points.compact li { font-size: 14px; color: var(--sub); }
.sheet .points li::before, .points li::before { border-color: var(--night); }

/* 맨 아래 */
.page-foot { border-top: 1px solid var(--line); }
.restore-link { color: var(--text); font-weight: 600; }

/* 불러오는 화면 */
.lantern-loading p { font-family: var(--font); font-weight: 800; font-size: 19px; letter-spacing: -0.03em; }
.loading, .boot { font-family: var(--font); font-weight: 700; font-size: 17px; }


/* ── 4차: 싸 보이지 않는 귀여움 ──
   3차 구조(직접 그린 입력칸·굵기 체계·선 아이콘·영수증·장 번호·큰 점수·공유 카드)는 그대로 두고,
   목소리 자리는 둥근 글꼴로 되돌리고, 면은 복숭아·꿀색 두 가지로만 따뜻하게 칠해요. */
.screen-title, .card h3, .when h2, .hello h2, .report-head h2, .chat-head h1, .menu-title, .segment button, .sheet-head h2, .stamp-head h3, .love h2 {
  font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em;
}
.screen-title { font-size: 28px; }
.card h3 { font-size: 19.5px; margin-bottom: 10px; }
.hello h2 { font-size: 23px; line-height: 1.32; }
.when h2 { font-size: 24px; }
.menu-title { font-size: 18px; letter-spacing: 0; color: var(--text); padding: 20px 2px 8px; }
.segment button { font-size: 17px; }
.sheet-head h2 { font-size: 24px; }
.report-head h2 { font-size: 26px; }
/* 큰 숫자·값·장 번호도 목소리예요 */
.score-num, .love-score b, .receipt .total dd b, .lk-num, .chap-n, .price-chip, .score-num small, .love-score { font-family: var(--cute); font-weight: 400; letter-spacing: -0.02em; }
.score-num { font-size: 64px; }
.score-num small { font-size: 20px; }
.score-band { font-family: var(--cute); font-weight: 400; font-size: 19px; }
.receipt .total dd b { font-size: 30px; color: var(--coral-ink); }
.love-score b { font-size: 72px; color: var(--coral-ink); }
.price-chip { font-size: 26px; }
.prow em { font-family: var(--cute); font-weight: 400; font-size: 17px; color: var(--coral-ink); }
.lantern-loading p, .loading, .boot { font-family: var(--cute); font-weight: 400; }
.bub > b, .hello-say b { font-family: var(--cute); font-weight: 400; font-size: 14px; letter-spacing: 0; color: var(--coral-ink); }
.eyebrow { letter-spacing: .02em; }
/* 첫 화면 질문의 '내 달'만 주색으로(밤에는 꿀색) */
.hl { color: var(--coral); }
.land-hero.is-night .hl { color: var(--butter); }
/* 따뜻한 면 두 가지 */
.hello { background: var(--peach); border-color: transparent; }
.hello-say { background: var(--card); }
.lock-card { background: var(--butter-soft); border-color: transparent; }
.verdict { border-color: var(--coral); }
.prod-icon { background: var(--peach); color: var(--coral-ink); }
.av { background: var(--peach); }
.big-btn { border-radius: 16px; font-size: 17.5px; letter-spacing: -0.02em; }
.when-go { border-radius: 12px; }
.when-go em { color: #fff; opacity: .92; }
.pick { border-radius: 12px; }
.seg { border-radius: 14px; }
/* 말풍선 옆 토리 얼굴(art.js toriFace): 그림과 같은 토리 */
.tori-face { width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--peach); overflow: hidden; }
.ask-top .tori-face { width: 52px; height: 52px; }
/* 토리가 곳곳에서 고개를 내밀어요: 열두 달 머리, 리포트 머리 */
.when { position: relative; }
.when .peek { position: absolute; right: 2px; top: -6px; width: 64px; height: 80px; }
.report-head { position: relative; }
.report-head .report-tori { position: absolute; right: 0; top: 4px; width: 62px; height: 78px; }
.report-head h2, .report-head small { padding-right: 66px; }
@media (prefers-reduced-motion: no-preference) {
  .when .peek, .report-head .report-tori { animation: bob 3.2s ease-in-out infinite; }
}


/* ── 2차: 그림 자리 ── */
.tori-svg { display: block; }
.tori-sm { width: 64px; height: 80px; }
.tori-mid { width: 110px; height: 138px; }
.lantern-loading { gap: 10px; padding: 0 0 24px; min-height: 70dvh; align-content: start; }
.lantern-loading .loading-scene { width: 100%; max-width: 480px; }
.lantern-loading p { font-family: var(--cute); font-weight: 400; letter-spacing: -0.01em; font-size: 20px; color: var(--text); }
.lantern-loading small { font-family: var(--font); font-size: 13.5px; color: var(--sub); }
.month-strip { display: block; width: calc(100% + 8px); margin: 2px -4px 0; height: auto; }
.when-strip { margin: 2px 0 4px; }
.strip-note { font-size: 12.5px; color: var(--sub); text-align: center; margin: 0 0 4px; }
.verdict .month-strip { margin-top: 4px; }

/* ══ 5차: 토리의 등불 마을 ══════════════════════════════════════
   세계: 달토끼 토리가 밤마다 열두 달 등에 불을 켜는 마을. 칠한 그림(img/)이 주인공이에요.
   색: 밤 남보라(장면·오늘 점수 판) · 등불 금색(켜진 것) · 산호(누르는 단추) · 종이 크림(바탕). 밝은 화면 하나로 그려요.
   글꼴: 제목 Jua(두 색), 토리 말 Hi Melody(손글씨), 본문 Pretendard.
   PC(900px 이상)는 위 메뉴 + 넓은 판이고, 단이 둘 이상이면 단마다 제 줄을 따로 쌓아요(행을 나눠 써서 빈칸이 생기지 않게). */
:root {
  --bg: #fffaf3; --bg2: #fff3e6; --card: #ffffff; --text: #2e2745; --sub: #625a78; --faint: #9a93ab;
  --line: #f0e3d4; --line-strong: #e8d6c3;
  --night: #ff7656; --night-2: #e2563a; --coral: #ff7656; --coral-2: #ff9a7c; --coral-ink: #d24f33;
  --peach: #ffe9de; --butter: #ffc24d; --butter-soft: #fff4d6; --mint: #3fae84; --good: #2f8f68; --warn: #c2462b;
  --ink-night: #2a2350; --ink-night-2: #3a3170; --night-text: #fff6e8; --gold-soft: #ffdf94;
  --hand: "Hi Melody", "Pretendard Variable", cursive;
  --shadow: 0 12px 32px -16px rgba(96, 58, 30, .32);
  --shadow-lift: 0 18px 40px -18px rgba(96, 58, 30, .42);
  --r-xl: 24px; --r-l: 18px;
  color-scheme: light;
}
body { background: var(--bg); }
img { height: auto; }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.nowrap { white-space: nowrap; }
.wrap { width: min(100% - 32px, 1240px); margin-inline: auto; }
.phone { max-width: none; display: block; min-height: 100dvh; padding-bottom: 92px; }
.hand { font-family: var(--hand); font-size: 20px; line-height: 1.35; color: var(--coral-ink); letter-spacing: 0; font-weight: 400; }
.bubble { position: relative; display: inline-block; background: var(--bg2); border-radius: 20px; padding: 10px 16px; font-family: var(--hand); font-size: 19px; line-height: 1.35; color: var(--ink-night); letter-spacing: 0; }
.bubble::after { content: ""; position: absolute; left: -8px; bottom: 14px; border: 9px solid transparent; border-right-color: var(--bg2); border-left: 0; }
.tori-face { width: 44px; height: 44px; border-radius: 50%; background: var(--butter-soft); object-fit: cover; flex: none; }
.obj-art { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center bottom; }
.tori-img { display: block; height: auto; }
@keyframes float5 { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes lamp-on { 0% { background: rgba(255, 246, 232, .2); box-shadow: none; } 100% { background: var(--butter); box-shadow: 0 0 14px rgba(255, 194, 77, .85); } }

/* 단추 */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 26px; border: 0; border-radius: 999px; font-weight: 800; font-size: 17px; white-space: nowrap; cursor: pointer; }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.btn-main, .big-btn { background: var(--coral); color: #fff; box-shadow: inset 0 -4px 0 rgba(160, 40, 10, .22), 0 10px 22px -10px rgba(226, 86, 58, .7); }
.btn-soft { background: #fff; color: var(--ink-night); box-shadow: inset 0 0 0 2px var(--line-strong); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 14.5px; }
.big-btn { width: 100%; min-height: 56px; border: 0; border-radius: 999px; font-family: var(--font); font-weight: 800; font-size: 17.5px; letter-spacing: -0.01em; }
.big-btn:disabled { background: #e9ddd2; color: #fff; box-shadow: none; }
.mini-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--bg2); color: var(--ink-night); font-weight: 800; font-size: 14px; }
.mini-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }
.pick { border: 0; border-radius: 999px; background: #fff; color: var(--ink-night); box-shadow: inset 0 0 0 1.5px var(--line-strong); padding: 9px 16px; font-weight: 800; }
.pick small { color: var(--faint); }
.pick.go, .pick.on { background: var(--coral); color: #fff; box-shadow: none; }
.pick.ghost, .pick.own { box-shadow: inset 0 0 0 1.5px var(--line-strong); border: 0; }
.pick.small { border-radius: 999px; }
.link { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; border: 0; background: none; padding: 0; font-weight: 800; font-size: 14.5px; color: var(--coral-ink); }
.link svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; }

/* 판 */
.card { background: var(--card); border: 0; border-radius: var(--r-xl); padding: 22px 20px; box-shadow: var(--shadow); }
.card h3 { font-family: var(--cute); font-size: 21px; color: var(--ink-night); }
.eyebrow { font-size: 13px; font-weight: 800; color: var(--coral-ink); letter-spacing: .02em; }
.screen { width: 100%; padding: 0; display: block; }
.screen-title { font-family: var(--cute); font-size: 30px; color: var(--ink-night); padding: 6px 2px 0; }

/* 위 막대 */
.demo-bar { position: relative; z-index: 21; }
.top { position: sticky; top: 0; z-index: 20; background: rgba(255, 250, 243, .94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 14px; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 9px; border: 0; background: none; padding: 0; min-width: 0; text-align: left; }
.logo .tori-face { width: 40px; height: 40px; }
.logo-name { display: grid; font-family: var(--cute); font-size: 22px; line-height: 1.05; color: var(--ink-night); white-space: nowrap; }
.logo-name small { font-family: var(--hand); font-size: 13.5px; color: var(--coral-ink); margin-top: 2px; }
.top-go { margin-left: auto; }
.nav { display: none; }
.top .who { margin-left: auto; }
.appbar { display: none; }

/* 휴대폰 아래 탭: 떠 있는 둥근 막대 */
.tabbar { position: fixed; z-index: 25; left: 50%; bottom: calc(12px + env(safe-area-inset-bottom)); transform: translateX(-50%); width: min(100% - 24px, 420px); margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 2px; padding: 6px; border: 0; border-radius: 26px; background: rgba(255, 255, 255, .96); box-shadow: 0 18px 30px -12px rgba(60, 40, 80, .35), 0 0 0 1px var(--line); }
.tabbar button { padding: 7px 0 5px; border-radius: 18px; color: var(--faint); font-size: 11.5px; }
.tabbar button[aria-current="page"] { background: var(--ink-night); color: var(--night-text); }
.tabbar button[aria-current="page"] svg { fill: none; stroke: var(--butter); }
.composer { bottom: calc(92px + env(safe-area-inset-bottom)); }

/* ── 첫 화면 ── */
.landing { display: block; }
.hero { position: relative; overflow: hidden; color: var(--night-text); background: var(--ink-night) url(./img/hero-night.webp) 34% 40% / cover no-repeat; }
.hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(42, 35, 80, .55) 0%, rgba(42, 35, 80, .12) 45%, rgba(42, 35, 80, .38) 100%); }
.hero .wrap { position: relative; display: grid; padding: 30px 0 28px; }
.hero-copy { position: relative; z-index: 2; display: grid; gap: 12px; justify-items: start; }
.hero .hand { color: var(--gold-soft); font-size: 21px; }
.hero h1 { font-family: var(--cute); font-weight: 400; font-size: clamp(36px, 10vw, 60px); line-height: 1.12; letter-spacing: -0.02em; text-shadow: 0 2px 18px rgba(20, 14, 50, .45); }
.hero .gold, .home-head .gold { color: var(--butter); }
.hero .lead { font-size: 16.5px; line-height: 1.65; color: rgba(255, 246, 232, .92); max-width: 30em; text-shadow: 0 1px 10px rgba(20, 14, 50, .5); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.trust { display: flex; flex-wrap: wrap; gap: 8px 14px; margin: 6px 0 0; padding: 0; list-style: none; font-size: 13.5px; font-weight: 700; color: rgba(255, 246, 232, .9); }
.trust li { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.trust svg { width: 16px; height: 16px; fill: none; stroke: var(--butter); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.hero-tori { position: relative; z-index: 6; justify-self: end; width: 168px; margin: 8px 6px -34px 0; animation: float5 3.6s ease-in-out infinite; filter: drop-shadow(0 10px 18px rgba(10, 6, 30, .45)); }
.entry { position: relative; z-index: 5; display: grid; gap: 14px; border-top: 0; padding: 22px 20px; color: var(--text); }
.entry-ask { display: flex; align-items: flex-end; gap: 10px; }
.entry-ask .tori-face { width: 60px; height: 60px; }
.entry-note { font-size: 13.5px; font-weight: 700; color: var(--good); }
.ymd select, .entry-more input, .form-card select, .form-card input { min-height: 52px; border: 0; border-radius: 16px; background: var(--bg); box-shadow: inset 0 0 0 1.5px var(--line-strong); padding: 0 12px; font-weight: 700; }
.ymd select:focus, .entry-more input:focus { box-shadow: inset 0 0 0 2px var(--coral); }
.seg { padding: 5px; gap: 6px; border: 0; border-radius: 18px; background: var(--bg); box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.seg label span { min-height: 44px; border-radius: 13px; font-weight: 800; color: var(--sub); }
.seg input:checked + span { background: var(--ink-night); color: var(--night-text); box-shadow: 0 6px 14px -8px rgba(42, 35, 80, .9); }
.pair-row { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
.sijin-field { display: grid; gap: 8px; }
.sijin-field .label { font-weight: 800; font-size: 15px; color: var(--ink-night); }
.sijin-field .label small { font-weight: 600; font-size: 12.5px; color: var(--faint); margin-left: 4px; }
.sijin-chips { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.sijin-chips button { display: grid; place-items: center; align-content: center; gap: 1px; min-height: 52px; padding: 4px 2px; border: 0; border-radius: 14px; background: var(--bg); box-shadow: inset 0 0 0 1.5px var(--line); line-height: 1.15; }
.sijin-chips b { font-size: 15px; color: var(--ink-night); }
.sijin-chips small { font-size: 11px; color: var(--faint); font-weight: 600; }
.sijin-chips .unknown { grid-column: 1 / -1; grid-auto-flow: column; gap: 8px; min-height: 44px; }
.sijin-chips button[aria-checked="true"] { background: var(--butter-soft); box-shadow: inset 0 0 0 2px var(--butter); }
.sijin-chips button[aria-checked="true"] small { color: #8a5a00; }
.entry-more summary { font-weight: 800; color: var(--sub); }
.entry .safe { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 13px; color: var(--faint); }
.entry .safe svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
.land-samples { display: grid; gap: 6px; }
.sec { padding: 40px 0 8px; }
.sec-head { display: grid; gap: 6px; margin-bottom: 18px; }
.sec-head h2 { font-family: var(--cute); font-weight: 400; font-size: 27px; line-height: 1.25; color: var(--ink-night); }
.sec-head h2 .c { color: var(--coral-ink); }
.sec-head p { color: var(--sub); font-size: 15px; }
.steps { display: grid; gap: 12px; }
.step { display: grid; grid-template-columns: 96px 1fr; align-items: center; gap: 14px; padding: 14px 18px 14px 10px; }
.step .tori-img { width: 96px; max-height: 120px; object-fit: contain; }
.step .n { font-family: var(--cute); font-size: 14px; color: var(--coral-ink); }
.step h3 { margin: 0; font-size: 20px; }
.step p { font-size: 14.5px; color: var(--sub); margin-top: 2px; }

/* 풀이 목록 */
.goods-grid { display: grid; gap: 26px; }
.goods-col { display: flex; flex-direction: column; gap: 12px; }
.goods-title { font-family: var(--cute); font-weight: 400; font-size: 19px; color: var(--ink-night); margin: 0 0 2px; }
.offer { display: grid; grid-template-columns: 80px minmax(0, 1fr) auto; align-items: center; gap: 14px; width: 100%; padding: 12px 16px 12px 10px; border: 0; border-radius: 22px; background: #fff; box-shadow: var(--shadow); text-align: left; transition: transform .15s ease, box-shadow .15s ease; }
.offer:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.offer .art { width: 80px; height: 80px; border-radius: 20px; background: var(--bg2); overflow: hidden; padding: 4px 4px 0; }
.offer .t { display: grid; gap: 3px; min-width: 0; }
.offer b { font-size: 16.5px; line-height: 1.35; color: var(--ink-night); }
.offer small { font-size: 13.5px; color: var(--sub); font-weight: 600; }
.offer .price { font-family: var(--cute); font-size: 20px; color: var(--coral-ink); white-space: nowrap; }
.badge { display: inline-block; padding: 1px 7px; border-radius: 999px; background: var(--coral); color: #fff; font-style: normal; font-size: 10.5px; font-weight: 900; letter-spacing: .04em; vertical-align: 1px; }
.offer.feature { background: var(--ink-night); }
.offer.feature b { color: #fff; }
.offer.feature small { color: rgba(255, 246, 232, .75); }
.offer.feature .art { background: rgba(255, 255, 255, .1); }
.offer.feature .price { color: var(--butter); }
.goods-grid.compact { gap: 16px; }
.goods-grid.compact .goods-title { font-size: 16px; }
.goods-grid.compact .offer { grid-template-columns: 56px minmax(0, 1fr) auto; gap: 10px; padding: 8px 12px 8px 6px; box-shadow: none; background: var(--bg); border-radius: 18px; }
.goods-grid.compact .offer .art { width: 56px; height: 56px; border-radius: 14px; }
.goods-grid.compact .offer b { font-size: 14.5px; }
.goods-grid.compact .offer small { font-size: 12.5px; }
.goods-grid.compact .offer .price { font-size: 15.5px; }

/* 꼬리말 */
.site-foot { margin-top: 56px; position: relative; color: var(--night-text); background: var(--ink-night) url(./img/footer-hill.webp) center 30% / cover no-repeat; }
.site-foot::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(42, 35, 80, .88), rgba(42, 35, 80, .6)); }
.site-foot .wrap { position: relative; display: grid; gap: 14px; padding: 34px 0 40px; }
.site-foot .hand { color: var(--gold-soft); font-size: 22px; }
.site-foot .restore-link { margin-top: 8px; border: 0; background: rgba(255, 255, 255, .12); color: var(--night-text); border-radius: 999px; padding: 8px 14px; font-weight: 800; }
.site-foot .sf-legal, .site-foot .sf-legal * { color: rgba(255, 246, 232, .78); }
.site-foot .sf-legal a { color: var(--night-text); font-weight: 700; }
.site-foot .foot { font-size: 12.5px; line-height: 1.6; margin-top: 8px; }
.page-foot { display: none; }

/* 불러오기 */
.lantern-loading { min-height: calc(100dvh - 40px); display: grid; place-items: center; align-content: center; gap: 16px; text-align: center; color: var(--night-text); background: var(--ink-night) url(./img/hero-night.webp) 50% 30% / cover no-repeat; position: relative; padding: 40px 20px; }
.lantern-loading::before { content: ""; position: absolute; inset: 0; background: rgba(32, 26, 66, .6); }
.lantern-loading > * { position: relative; }
.lantern-loading .loading-tori { width: 190px; animation: float5 3s ease-in-out infinite; }
.lantern-loading h2 { font-family: var(--cute); font-weight: 400; font-size: 26px; line-height: 1.3; }
.lantern-loading p { font-size: 15px; color: rgba(255, 246, 232, .85); font-family: var(--font); }
.lamps { display: grid; grid-template-columns: repeat(6, 22px); gap: 12px 14px; justify-content: center; }
.lamp { display: block; width: 22px; height: 28px; border-radius: 9px; background: rgba(255, 246, 232, .2); animation: lamp-on .3s ease forwards; }
.lamp:nth-child(1) { animation-delay: .1s; } .lamp:nth-child(2) { animation-delay: .25s; } .lamp:nth-child(3) { animation-delay: .4s; } .lamp:nth-child(4) { animation-delay: .55s; }
.lamp:nth-child(5) { animation-delay: .7s; } .lamp:nth-child(6) { animation-delay: .85s; } .lamp:nth-child(7) { animation-delay: 1s; } .lamp:nth-child(8) { animation-delay: 1.15s; }
.lamp:nth-child(9) { animation-delay: 1.3s; } .lamp:nth-child(10) { animation-delay: 1.45s; } .lamp:nth-child(11) { animation-delay: 1.6s; } .lamp:nth-child(12) { animation-delay: 1.75s; }
.loading.small { gap: 10px; }
.loading .tori-sm, .loading .tori-mid { width: 110px; animation: float5 3s ease-in-out infinite; }

/* ── 홈 ── */
.home-head { position: relative; overflow: hidden; color: var(--night-text); background: var(--ink-night) url(./img/hero-night.webp) 40% 35% / cover no-repeat; }
.home-head::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(42, 35, 80, .78) 0%, rgba(42, 35, 80, .35) 70%, rgba(42, 35, 80, .2) 100%); }
.home-head .wrap { position: relative; display: grid; gap: 8px; padding: 26px 0 96px; }
.home-head h1 { font-family: var(--cute); font-weight: 400; font-size: clamp(34px, 9vw, 52px); line-height: 1.12; }
.home-head .date { font-weight: 700; font-size: 14.5px; color: rgba(255, 246, 232, .85); }
.home-head .hand { color: var(--gold-soft); }
.home-head .head-tori { position: absolute; right: 2px; bottom: 0; width: 128px; animation: float5 3.6s ease-in-out infinite; filter: drop-shadow(0 10px 16px rgba(10, 6, 30, .5)); }
.dash { display: grid; gap: 16px; margin-top: -72px; position: relative; z-index: 3; }
.dcol { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.me-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: center; }
.me-tiles { display: flex; gap: 6px; }
.h-me h2 { font-family: var(--cute); font-weight: 400; font-size: 22px; line-height: 1.25; color: var(--ink-night); }
.me-facts { font-size: 13.5px; color: var(--sub); line-height: 1.6; margin-top: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.chip { padding: 5px 12px; border-radius: 999px; background: var(--bg2); font-size: 13.5px; font-weight: 800; color: var(--ink-night); white-space: nowrap; }
.h-today { background: var(--ink-night); color: var(--night-text); overflow: hidden; }
.h-today .eyebrow { color: var(--gold-soft); }
.h-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.h-today .score-block { margin-top: 6px; }
.h-today .score-num { color: #fff; }
.h-today .score-band { background: rgba(255, 255, 255, .14); color: var(--night-text); }
.h-today .meter-note { color: rgba(255, 246, 232, .6); }
.h-today-tori { width: 96px; flex: none; margin: -6px -6px 0 0; }
.h-band { font-family: var(--cute); font-weight: 400; font-size: 21px; line-height: 1.35; margin-top: 10px; color: #fff; }
.h-msg { margin-top: 12px; padding: 14px 16px; border-radius: 16px; background: rgba(255, 255, 255, .08); font-size: 15px; line-height: 1.65; }
.h-msg b { display: block; font-family: var(--hand); font-size: 19px; color: var(--gold-soft); font-weight: 400; margin-bottom: 2px; }
.luck { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 12px 0 0; }
.luck div { padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .08); }
.luck dt { font-size: 11.5px; color: rgba(255, 246, 232, .65); font-weight: 700; }
.luck dd { margin: 2px 0 0; font-weight: 800; font-size: 14.5px; line-height: 1.35; }
.h-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.h-today .mini-btn { background: rgba(255, 255, 255, .12); color: #fff; }
.when { background: var(--card); border-radius: var(--r-xl); padding: 22px 20px; box-shadow: var(--shadow); }
.when .peek { width: 64px; height: auto; top: -18px; right: 10px; }
.when-row .prod-icon, .when-row .art { width: 64px; height: 64px; border-radius: 18px; background: var(--bg2); overflow: hidden; padding: 3px 3px 0; }
.when-go { border-radius: 999px; background: var(--coral); font-family: var(--font); font-weight: 800; font-size: 15.5px; box-shadow: inset 0 -3px 0 rgba(160, 40, 10, .2); }
.h-fortunes { display: grid; gap: 14px; }
.h-fortune { display: grid; gap: 10px; }
.h-fortune .head { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 12px; align-items: center; }
.h-fortune .head .obj-art { width: 70px; height: 70px; border-radius: 20px; background: var(--bg2); padding: 4px 4px 0; }
.h-fortune h3 { margin: 0; }
.h-fortune .tag { font-weight: 800; font-size: 14px; color: var(--coral-ink); margin-top: 3px; }
.h-fortune .body { align-self: start; font-size: 15px; line-height: 1.7; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.h-fortune .mini-btn { justify-self: start; }
.el-bars { margin: 6px 0 0; }
.flow-list { display: grid; gap: 10px; }
.flow-list > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 16px; background: var(--bg); }
.flow-list b { color: var(--ink-night); font-size: 15px; display: block; }
.flow-list small { color: var(--sub); font-size: 13px; font-weight: 600; }
.fav { padding: 3px 10px; border-radius: 999px; background: var(--bg2); color: var(--sub); font-weight: 800; font-size: 12.5px; white-space: nowrap; }
.fav.favorable { background: #e3f6ee; color: var(--good); }
.fav.unfavorable { background: #ffe7e1; color: var(--warn); }
.ask-card .av { width: 52px; height: 52px; }
.stamp-card, .nudge { background: var(--card); border-radius: var(--r-xl); box-shadow: var(--shadow); padding: 20px; }
.nudge .nudge-tori { width: 84px; }
.hello { display: none; }

/* ── PC 오른쪽 판이 있는 화면(운세·상담·궁합·더보기) ── */
.page { display: block; padding-top: 20px; }
.page-main { display: grid; gap: 14px; min-width: 0; }
.page-side { display: none; }
.rail-hi { display: grid; justify-items: center; text-align: center; gap: 6px; background: var(--ink-night); color: var(--night-text); }
.rail-hi .rail-tori { width: 120px; animation: float5 3.6s ease-in-out infinite; }
.rail-hi .hand { color: var(--gold-soft); }
.date-nav { display: grid; grid-template-columns: 46px minmax(0, 1fr) 46px; gap: 8px; align-items: center; }
.date-pick { position: relative; display: grid; place-items: center; min-height: 46px; border-radius: 16px; background: #fff; box-shadow: inset 0 0 0 1.5px var(--line-strong); font-weight: 800; color: var(--ink-night); cursor: pointer; }
.date-pick input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; border: 0; }
.round { width: 46px; height: 46px; border-radius: 50%; border: 0; background: #fff; box-shadow: inset 0 0 0 1.5px var(--line-strong); font-size: 20px; font-weight: 800; color: var(--ink-night); }

/* ── 상품 화면 ── */
.prod-wrap { display: grid; gap: 16px; padding-top: 16px; }
.prod-hero { position: relative; overflow: hidden; display: grid; justify-items: center; text-align: center; gap: 6px; padding: 54px 20px 28px; border-radius: 28px; color: var(--night-text); background: var(--ink-night) url(./img/hero-night.webp) 70% 30% / cover no-repeat; }
.prod-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(42, 35, 80, .45), rgba(42, 35, 80, .8)); }
.prod-hero > * { position: relative; }
.prod-hero .obj-art { width: 200px; height: auto; animation: float5 3.6s ease-in-out infinite; filter: drop-shadow(0 12px 20px rgba(10, 6, 30, .5)); }
.prod-hero .back-btn { position: absolute; left: 14px; top: 14px; display: inline-flex; align-items: center; gap: 4px; border: 0; background: rgba(255, 255, 255, .12); color: var(--night-text); border-radius: 999px; padding: 6px 12px 6px 8px; font-weight: 800; font-size: 14px; }
.prod-hero .back-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; }
.prod-ask { font-family: var(--hand); font-size: 21px; color: var(--gold-soft); }
.prod-hero h1 { font-family: var(--cute); font-weight: 400; font-size: 38px; line-height: 1.1; }
.prod-desc { color: rgba(255, 246, 232, .85); font-size: 15px; }
.price-chip { display: inline-block; margin-top: 4px; font-family: var(--cute); font-size: 28px; color: var(--butter); background: none; padding: 0; }
.prod-body { display: grid; gap: 14px; min-width: 0; }
.lock-card { background: var(--card); box-shadow: var(--shadow); }
.lock-card .big-btn { margin-top: 12px; }
.sheet { border-radius: 28px 28px 0 0; padding-top: 12px; }
.sheet .receipt { border-radius: 18px; background: var(--bg); padding: 12px 16px; }
.sheet .receipt .total dd b { font-family: var(--cute); font-size: 24px; color: var(--coral-ink); font-weight: 400; }
.sheet-tori { width: 72px; }
.report-head .report-tori { width: 70px; height: auto; }

/* ── 넓은 화면(PC) ── */
@media (min-width: 900px) {
  .wrap { width: min(100% - 64px, 1240px); }
  .phone { padding-bottom: 0; }
  .tabbar { display: none; }
  .composer { bottom: 0; }
  .top .wrap { height: 72px; }
  .nav { display: flex; align-items: center; gap: 4px; margin-left: 24px; }
  .nav button { padding: 9px 16px; border: 0; border-radius: 999px; background: none; font-weight: 800; font-size: 15px; color: var(--sub); white-space: nowrap; }
  .nav button:hover { background: var(--bg2); color: var(--ink-night); }
  .nav button[aria-current="page"] { background: var(--ink-night); color: var(--night-text); }
  /* 첫 화면: 왼쪽 말·단추 / 가운데 토리 / 오른쪽 생일 칸 */
  .hero { background-position: 40% 45%; }
  .hero .wrap { grid-template-columns: minmax(0, 1fr) minmax(380px, 440px); align-items: center; gap: 40px; padding: 56px 0 64px; min-height: 640px; }
  .hero-copy { max-width: 470px; gap: 14px; }
  .hero h1 { font-size: clamp(46px, 4.6vw, 64px); }
  .hero .lead { font-size: 18px; }
  .hero-tori { position: absolute; left: 41%; bottom: 0; width: 220px; margin: 0; justify-self: auto; }
  .entry { grid-column: 2; grid-row: 1; }
  .sec { padding-top: 64px; }
  .sec-head h2 { font-size: 34px; }
  .goods-grid { grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
  .goods-grid.compact { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(3, 1fr); gap: 18px; }
  .step { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 22px 18px; }
  .step .tori-img { width: 130px; max-height: 160px; }
  .site-foot .wrap { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; }
  /* 홈: 세 단 */
  .home-head .wrap { padding: 40px 0 120px; }
  .home-head .head-tori { width: 170px; right: 31%; bottom: 84px; }
  .dash { grid-template-columns: 320px minmax(0, 1fr) 340px; align-items: start; gap: 20px; margin-top: -88px; }
  .dcol.c3 { position: sticky; top: 92px; }
  .h-fortunes { grid-template-columns: 1fr 1fr; }
  .luck { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  /* 운세·상담·궁합·더보기: 가운데 읽는 판 + 오른쪽 판 */
  .page { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; padding-top: 28px; }
  .page-side { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 92px; }
  /* 상품: 왼쪽 그림판 고정 / 오른쪽 내용 */
  .prod-wrap { grid-template-columns: 400px minmax(0, 1fr); gap: 28px; align-items: start; padding-top: 28px; }
  .prod-hero { position: sticky; top: 96px; padding: 64px 28px 40px; }
  .prod-hero .obj-art { width: 240px; }
  .sheet { bottom: auto; top: 50%; transform: translate(-50%, -50%); border-radius: 28px; width: min(100% - 40px, 520px); max-height: 88dvh; }
  .sheet .grab { display: none; }
}
@media (min-width: 900px) and (max-width: 1180px) {
  .dash { grid-template-columns: 300px minmax(0, 1fr); }
  .dcol.c3 { grid-column: 1 / -1; position: static; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .h-fortunes { grid-template-columns: 1fr; }
  .hero-tori { display: none; }
  .page { grid-template-columns: minmax(0, 1fr) 300px; }
}
@media (max-width: 899px) {
  .top-go { display: none; }
  /* 휴대폰 홈: 단을 풀고 오늘 점수부터 */
  .dcol { display: contents; }
  .dash .h-today { order: 1; } .dash .when { order: 2; } .dash .h-me { order: 3; } .dash .h-fortunes { order: 4; }
  .dash .h-oh { order: 5; } .dash .h-flow { order: 6; } .dash .ask-card { order: 7; } .dash .h-next { order: 8; } .dash .stamp-card { order: 9; } .dash .nudge { order: 10; }
}
@media (max-width: 370px) {
  .sijin-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero h1 { font-size: 34px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-tori, .home-head .head-tori, .prod-hero .obj-art, .lantern-loading .loading-tori, .rail-hi .rail-tori, .loading .tori-sm, .loading .tori-mid { animation: none; }
  .lamp { animation: none; background: var(--butter); }
}
.prod-hero .badge { left: auto; right: 16px; top: 18px; background: var(--coral); color: #fff; }
.prod-hero .prod-ask { color: var(--gold-soft) !important; font-family: var(--hand); font-size: 21px !important; }
.prod-hero p.prod-desc { color: rgba(255, 246, 232, .85); font-size: 15px; }
.h-today .score-band { padding: 3px 12px; border-radius: 999px; font-size: 16px; }
.toast { top: calc(78px + env(safe-area-inset-top)); }
@media (max-width: 520px) { .sijin-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); } .sijin-chips small { font-size: 11.5px; } }
/* 5차: 신살·성향 스티커는 알약 표 하나로(점으로 잇던 3차 글줄을 되돌려요). 좋음은 초록, 조심은 주홍, 나머지는 크림 */
.sticker-wall { display: flex; flex-wrap: wrap; gap: 6px; }
.sticker, .sticker:nth-child(even), .sticker:nth-child(3n) { display: inline-flex; align-items: center; padding: 5px 12px; border-radius: 999px; background: var(--bg2); font-weight: 800; font-size: 13.5px; line-height: 1.3; color: var(--ink-night); white-space: nowrap; }
.sticker + .sticker::before { content: none; }
.sticker.good { background: #e3f6ee; color: var(--good); }
.sticker.warn { background: #ffe7e1; color: var(--warn); }
.sticker.hot { background: var(--butter-soft); color: #8a5a00; }
.card .mini { font-size: 12.5px; font-weight: 800; color: var(--faint); margin: 12px 0 6px; }

/* ══ 6차: 토리의 등불 달력 ══════════════════════════════════════
   판매자 10/12 "너무 베꼈어"로 다시 세운 틀이에요. 화면 뼈대는 열두 달 등이에요.
   첫 화면은 등 고리(태어난 달 등을 누르면 시작) + 끈에 매달린 생일 꼬리표, 홈은 오늘의 등 → 열두 달 등 길 → 토리 수첩, 내 사주는 장마다 넘기는 수첩.
   피하는 것(다른 사이트 한 곳에만 있는 얼굴): 첫 화면 3단, 토끼 얼굴 로고, 알약 메뉴, 손글씨 머리글 + 두 색 제목, 카드 대시보드, 떠 있는 둥근 탭바, 2열 파스텔 타일.
   글꼴: 제목·토리 말 'Tori Dongle'(dongle.css, 크기 맞춤) + 본문 Pretendard. 색: 밤 · 등불 · 감빛 · 한지. */
:root {
  --night-sky: #1f1a3d; --night-sky-2: #2c2656; --moon: #fff3d6;
  --lamp: #ffbe3d; --lamp-2: #ffd98a; --lamp-soft: #fff1cc; --gam: #f0643c; --gam-ink: #c9481f;
  --hanji: #fbf6ec; --hanji-2: #f3ead8; --ink: #2a2440;
  --bg: var(--hanji); --bg2: var(--hanji-2); --text: var(--ink); --sub: #6b6480; --faint: #a39cb4; --line: #e9dfcb; --line-strong: #dccfb6;
  --coral: var(--gam); --coral-2: #f58a68; --coral-ink: var(--gam-ink); --butter: var(--lamp); --butter-soft: var(--lamp-soft);
  --ink-night: var(--night-sky); --night-text: var(--moon); --gold-soft: var(--lamp-2);
  --cute: "Tori Dongle", "Pretendard Variable", Pretendard, sans-serif;
  --hand: var(--cute);
  --shadow: 0 1px 0 rgba(60, 40, 20, .04);
  --r-xl: 16px;
}
body { background: var(--hanji); }
.card { border-radius: 16px; box-shadow: none; border: 1px solid var(--line); padding: 20px 18px; }
.card h3 { font-size: 22px; }
.eyebrow { color: var(--gam-ink); }
.btn-main, .big-btn { background: var(--gam); color: #fff; border-radius: 12px; box-shadow: 0 5px 0 var(--gam-ink); font-family: var(--cute); font-size: 24px; font-weight: 400; letter-spacing: 0; }
.big-btn:disabled { box-shadow: none; }
.big-btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--gam-ink); }
.pick { border-radius: 10px; background: var(--hanji-2); box-shadow: none; }
.pick.go, .pick.on { background: var(--ink); color: var(--lamp-2); }
.mini-btn { border-radius: 10px; }
.chip, .sticker, .sticker:nth-child(even), .sticker:nth-child(3n) { border-radius: 6px; }

/* 등 그림 */
.lp-rope { fill: none; stroke: #8f7a5b; stroke-width: 2; opacity: .85; }
.lp-tie { stroke: #8f7a5b; stroke-width: 1.6; }
.lp-cap { fill: #3a2f2a; }
.lp-paper { fill: #f6e6c4; stroke: #3a2f2a; stroke-width: 1.8; }
.lp-rib { fill: none; stroke: #3a2f2a; stroke-opacity: .22; stroke-width: 1.4; }
.lp-tassel { fill: var(--gam); }
.lp-n { font: 400 30px var(--cute); text-anchor: middle; fill: #5b4a3c; }
.lp-glow { fill: var(--lamp); opacity: 0; }
.lp-label { font: 700 13px var(--font); text-anchor: middle; fill: var(--sub); }
.lp.on .lp-paper, .lp-paper.on { fill: var(--lamp); }
.lp.on .lp-glow { opacity: .45; }
.lp.mine .lp-paper { fill: var(--gam); }
.lp.mine .lp-n { fill: #fff; }
.lp.mine .lp-glow { opacity: .6; fill: var(--lamp-2); }
.lp.q .lp-paper { fill: #efe6d6; }
.lp.q .lp-n { fill: #b3a593; }
.lp.warn .lp-paper { fill: #f3d2c6; }
.lp.warn .lp-n { fill: var(--gam-ink); }
.arc .lp { cursor: pointer; outline: none; }
.arc .lp:hover .lp-paper, .arc .lp:focus .lp-paper { fill: var(--lamp-2); }
.arc .lp.mine:hover .lp-paper { fill: var(--gam); }
.big-n { font: 400 64px var(--cute); text-anchor: middle; fill: var(--ink); }
.big-u { font: 700 15px var(--font); text-anchor: middle; fill: var(--ink); }
.mark-lamp { width: 20px; height: 32px; flex: none; }

/* 위 막대: 밤색 한 줄 */
.top { background: var(--night-sky); border-bottom: 0; backdrop-filter: none; color: var(--moon); }
.top .wrap { height: 56px; }
.logo-name { font-size: 30px; color: #fff; line-height: 1; }
.logo-name small { display: none; }
.top-note { margin-left: auto; font-weight: 700; font-size: 13.5px; color: var(--lamp-2); }
.top .who { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .18); color: #fff; border-radius: 10px; }
.top .who b { color: var(--lamp-2); border-color: rgba(255, 255, 255, .2); }

/* 아래 탭: 바닥에 붙은 밤색 막대 */
.phone { padding-bottom: 70px; }
.tabbar { left: 0; right: 0; bottom: 0; transform: none; width: auto; border-radius: 0; padding: 4px 4px calc(6px + env(safe-area-inset-bottom)); background: var(--night-sky); box-shadow: none; gap: 0; }
.tabbar button { color: rgba(255, 243, 214, .55); border-radius: 0; padding: 7px 0 4px; }
.tabbar button[aria-current="page"] { background: none; color: var(--lamp); }
.tabbar button[aria-current="page"] svg { stroke: var(--lamp); fill: rgba(255, 190, 61, .25); }
.composer { bottom: calc(66px + env(safe-area-inset-bottom)); }

/* ── 첫 화면: 등 고리 ── */
.landing { display: block; }
.ring { position: relative; overflow: hidden; color: #fff; background: radial-gradient(120% 70% at 50% 100%, #3b3470 0%, var(--night-sky) 62%); padding: 26px 0 0; }
.ring::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 46%; background: url(./img/footer-hill.webp) center bottom / cover no-repeat; opacity: .55; -webkit-mask-image: linear-gradient(transparent, #000 45%); mask-image: linear-gradient(transparent, #000 45%); }
.ring .wrap { position: relative; display: grid; justify-items: center; text-align: center; }
.ring h1 { font: 400 46px/1.05 var(--cute); letter-spacing: 0; }
.ring h1 em { font-style: normal; color: var(--lamp); text-shadow: 0 0 18px rgba(255, 190, 61, .55); }
.ring .lead { margin-top: 8px; font-size: 14.5px; color: rgba(255, 243, 214, .82); max-width: 27em; }
.arc { width: 108%; max-width: 1100px; margin-top: 4px; }
.arc-svg { display: block; width: 100%; height: auto; }
.tori-seat { position: relative; margin-top: -96px; display: grid; justify-items: center; }
.tori-seat .hero-tori { width: 150px; animation: float5 3.4s ease-in-out infinite; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .45)); }
.say { position: relative; margin-bottom: 8px; padding: 6px 16px 4px; border-radius: 14px; background: var(--moon); color: var(--ink); font: 400 24px/1.15 var(--cute); max-width: 22em; text-wrap: balance; }
.say::after { content: ""; position: absolute; left: 50%; bottom: -7px; margin-left: -7px; border: 7px solid transparent; border-top-color: var(--moon); border-bottom: 0; }
.tag-wrap { position: relative; display: grid; justify-items: center; width: 100%; padding: 0 0 36px; }
.tag-wrap::before { content: ""; width: 2px; height: 26px; background: #b59e7a; }
.ltag { position: relative; width: min(100%, 760px); padding: 30px 18px 20px; background: var(--hanji); color: var(--ink); border-radius: 10px 10px 18px 18px; box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .6); text-align: left; display: grid; gap: 14px; border: 0; }
.ltag::before { content: ""; position: absolute; left: 50%; top: 10px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--night-sky); box-shadow: inset 0 0 0 3px #b59e7a; }
.tag-title { font: 400 32px/1.05 var(--cute); text-align: center; }
.tag-title b { color: var(--gam-ink); font-weight: 400; }
.tag-text { font-size: 15px; }
.ltag .ymd select { background: transparent; border-radius: 0; box-shadow: none; border-bottom: 2px solid var(--ink); padding: 0 6px; }
.ltag .ymd select:focus { box-shadow: none; border-bottom-color: var(--gam); outline: none; }
.ltag .seg { background: transparent; box-shadow: none; padding: 0; gap: 6px; }
.ltag .seg label span { background: var(--hanji-2); border-radius: 10px; }
.ltag .seg input:checked + span { background: var(--ink); color: var(--lamp-2); box-shadow: none; }
.sijin-chips button { border-radius: 10px; background: var(--hanji-2); box-shadow: none; }
.sijin-chips b { font: 400 22px/1 var(--cute); }
.sijin-chips button[aria-checked="true"] { background: var(--lamp-soft); box-shadow: inset 0 0 0 2px var(--lamp); }
.ltag .safe { text-align: center; font-size: 12.5px; color: var(--faint); display: block; }
.entry-more summary { color: var(--sub); }

/* 등 줄에 매단 꼬리표들(상품) */
.shelf { padding: 40px 0 10px; }
.shelf h2 { font: 400 40px/1.05 var(--cute); color: var(--ink); }
.shelf .sub { color: var(--sub); font-size: 14.5px; margin-top: 2px; }
.strings { display: grid; gap: 26px; margin-top: 18px; }
.string { position: relative; padding-left: 22px; display: grid; gap: 10px; align-content: start; }
.string::before { content: ""; position: absolute; left: 6px; top: 6px; bottom: 30px; width: 2px; background: #c9b48f; }
.string h3 { font: 400 26px/1 var(--cute); color: var(--gam-ink); margin: 0; }
.hang { position: relative; display: grid; grid-template-columns: 60px minmax(0, 1fr) auto; gap: 12px; align-items: center; width: 100%; padding: 8px 14px 8px 6px; background: #fff; border: 1px solid var(--line); border-radius: 6px 16px 16px 6px; text-align: left; color: var(--ink); }
.hang::before { content: ""; position: absolute; left: -16px; top: 50%; width: 14px; height: 2px; background: #c9b48f; }
.hang::after { content: ""; position: absolute; left: -20px; top: 50%; width: 8px; height: 8px; margin-top: -3px; border-radius: 50%; background: var(--lamp); box-shadow: 0 0 8px var(--lamp); }
.hang:hover { border-color: var(--lamp); }
.hang .art { width: 60px; height: 60px; display: block; }
.hang .t { display: grid; gap: 2px; min-width: 0; }
.hang b { font-size: 15.5px; line-height: 1.35; }
.hang small { font-size: 12.5px; color: var(--sub); font-weight: 600; }
.hang .won { font: 400 24px/1 var(--cute); color: var(--gam-ink); white-space: nowrap; }
.badge { border-radius: 4px; background: var(--gam); }
.strings.compact { gap: 16px; margin-top: 8px; }
.strings.compact .string h3 { font-size: 21px; }
.strings.compact .hang { grid-template-columns: 46px minmax(0, 1fr) auto; padding: 6px 10px 6px 4px; }
.strings.compact .hang .art { width: 46px; height: 46px; }
.strings.compact .hang b { font-size: 14px; }
.strings.compact .hang .won { font-size: 20px; }

/* 꼬리말: 밤색 한 줄(손글씨 인사 없이) */
.site-foot { margin-top: 48px; background: var(--night-sky); }
.site-foot::before { content: none; }
.site-foot .wrap { padding: 26px 0 30px; gap: 10px; }
.sf-brand { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font: 400 26px/1 var(--cute); color: #fff; }
.site-foot .restore-link { margin: 0 0 0 auto; border-radius: 10px; font-family: var(--font); font-size: 13px; }

/* 불러오기 */
.lantern-loading { background: radial-gradient(120% 70% at 50% 100%, #3b3470 0%, var(--night-sky) 62%); }
.lantern-loading::before { content: none; }
.lantern-loading h2 { font-size: 32px; }

/* ── 홈 ── */
.today-band { background: var(--night-sky); color: #fff; padding: 18px 0 24px; }
.today-band .wrap { position: relative; display: grid; grid-template-columns: 116px minmax(0, 1fr); gap: 6px 14px; align-items: center; }
.today-band .big { width: 116px; }
.big-svg { display: block; width: 100%; height: auto; filter: drop-shadow(0 0 22px rgba(255, 190, 61, .55)); }
.greet-box { min-width: 0; }
.today-band .date { font-size: 12.5px; font-weight: 700; color: rgba(255, 243, 214, .7); }
.greet { font: 400 34px/1.05 var(--cute); }
.band-line { margin-top: 4px; font-size: 13.5px; color: rgba(255, 243, 214, .9); }
.band { display: inline-block; margin-right: 6px; padding: 1px 8px; border-radius: 4px; background: var(--lamp); color: var(--ink); font-weight: 800; font-size: 12.5px; }
.today-band .msg { grid-column: 1 / -1; font-size: 14.5px; color: rgba(255, 243, 214, .9); margin-top: 6px; }
.lucky-line { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12.5px; color: var(--sub); }
.lucky-line b { color: var(--ink); }
.today-band .lucky-line { grid-column: 1 / -1; color: rgba(255, 243, 214, .7); }
.today-band .lucky-line b { color: var(--lamp-2); font-weight: 700; }
.band-acts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.today-band .mini-btn { background: rgba(255, 255, 255, .1); color: #fff; }
.band-tori { display: none; }
.home-body { padding-top: 6px; }
.road { padding: 20px 0 6px; }
.road h2 { font: 400 36px/1.05 var(--cute); }
.road .sub { color: var(--sub); font-size: 14px; }
.road-scroll { overflow-x: auto; margin: 10px -16px 0; padding: 0 16px; scrollbar-width: none; }
.road-svg { display: block; width: 1030px; max-width: none; height: auto; }
.teasers { display: grid; gap: 10px; margin-top: 8px; }
.teaser { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 4px 12px; align-items: center; padding: 12px 14px; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.teaser .art { width: 56px; height: 56px; display: block; }
.teaser h3 { font: 400 22px/1.1 var(--cute); }
.teaser p { font-size: 14px; color: var(--sub); }
.teaser .open { grid-column: 1 / -1; min-height: 48px; margin-top: 8px; border: 0; border-radius: 10px; background: var(--gam); color: #fff; font: 400 26px/1 var(--cute); display: flex; align-items: center; justify-content: center; gap: 8px; }
.teaser .open em { font-style: normal; font-size: 22px; opacity: .9; }
.teaser .open.alt { background: var(--ink); color: var(--lamp-2); }
.lower { display: grid; gap: 16px; margin-top: 20px; }
.side { display: grid; gap: 14px; align-content: start; }
.book { background: #fff; border: 1px solid var(--line); border-radius: 4px 16px 16px 4px; box-shadow: inset 10px 0 0 var(--hanji-2); min-width: 0; }
.book-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 0 26px; }
.book-head h2 { font: 400 32px/1 var(--cute); }
.book-art { width: 44px; height: 52px; }
.book-tabs { display: flex; gap: 2px; padding: 8px 16px 0 26px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.book-tabs button { padding: 8px 10px; border: 0; background: none; font-weight: 800; font-size: 14.5px; color: var(--faint); border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.book-tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--lamp); }
.book-page { padding: 14px 16px 6px 26px; display: grid; gap: 10px; background: repeating-linear-gradient(transparent 0 27px, #f3ebdc 27px 28px); }
.book-page p { font-size: 15px; line-height: 1.75; }
.book-more { margin: 4px 16px 16px 26px; }
.keys { display: flex; flex-wrap: wrap; gap: 6px; }
.keys span { padding: 3px 10px; border-radius: 6px; background: var(--lamp-soft); font-size: 13px; font-weight: 800; color: #7a5200; }
.tea { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 10px 12px; align-items: center; }
.tea-img { width: 76px; height: auto; }
.tea h3 { margin: 0 0 2px; font-size: 26px; }
.tea p { font-size: 13.5px; color: var(--sub); }
.tea .chips-row { grid-column: 1 / -1; flex-wrap: wrap; }
.stamp-card, .nudge { border: 1px solid var(--line); box-shadow: none; border-radius: 16px; }

/* 네 기둥 표 */
.pillar-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pg-col { display: grid; justify-items: center; align-content: start; gap: 4px; padding: 8px 2px; border-radius: 12px; }
.pg-col.me { background: var(--lamp-soft); box-shadow: inset 0 0 0 2px var(--lamp); }
.pg-label { font-size: 12px; font-weight: 800; color: var(--sub); }
.pg-col .tile { width: min(100%, 56px); }
.pg-god { display: grid; justify-items: center; text-align: center; line-height: 1.2; min-height: 30px; }
.pg-god b { font-size: 13px; color: var(--ink); }
.pg-god i { font-style: normal; font-size: 10.5px; color: var(--faint); font-weight: 600; }
.pg-stage { font-size: 11.5px; color: var(--sub); font-weight: 700; }
.pillar-grid:not(.full) .pg-col { padding: 4px 2px; }

/* ── 내 사주 수첩 ── */
.saju-book { display: grid; gap: 14px; }
.book-cover { padding: 20px 18px; border-radius: 4px 16px 16px 4px; background: var(--night-sky); color: #fff; box-shadow: inset 10px 0 0 #3b3470; }
.book-cover .eyebrow { color: var(--lamp-2); }
.book-cover h1 { font: 400 40px/1.05 var(--cute); margin-top: 2px; }
.book-cover .me-facts { color: rgba(255, 243, 214, .75); margin-top: 6px; font-size: 13px; }
.book-toc { position: sticky; top: 56px; z-index: 6; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 8px 0; margin: 0 -16px; padding-inline: 16px; background: var(--hanji); border-bottom: 1px solid var(--line); }
.book-toc button { flex: none; display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border: 0; border-radius: 8px; background: var(--hanji-2); font-weight: 800; font-size: 13px; color: var(--ink); white-space: nowrap; }
.book-toc button span { font: 400 18px/1 var(--cute); color: var(--gam-ink); }
.book-toc button.locked { color: var(--faint); }
.book-toc svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2; }
.chapters { display: grid; gap: 14px; }
.chapter { display: grid; gap: 12px; padding: 18px 16px 20px; background: #fff; border: 1px solid var(--line); border-radius: 4px 16px 16px 4px; box-shadow: inset 6px 0 0 var(--hanji-2); scroll-margin-top: 110px; }
.ch-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: center; padding-bottom: 10px; border-bottom: 1px dashed var(--line-strong); }
.ch-n { font: 400 40px/1 var(--cute); color: var(--lamp); -webkit-text-stroke: 1px var(--gam-ink); }
.ch-head h2 { font: 400 30px/1 var(--cute); }
.ch-head p { font-size: 13px; color: var(--sub); margin-top: 2px; }
.chapter p { font-size: 15px; line-height: 1.75; }
.lead-text { font-size: 16px !important; font-weight: 600; }
.me-hero { display: flex; align-items: center; gap: 14px; }
.me-line { font: 400 28px/1.1 var(--cute); }
.two-list { display: grid; gap: 12px; }
.two-list h3, .sub-h { font: 400 22px/1 var(--cute); color: var(--gam-ink); margin: 4px 0 6px; }
.facts3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 0; }
.facts3 div { padding: 10px 8px; border-radius: 10px; background: var(--hanji); text-align: center; }
.facts3 dt { font-size: 11.5px; color: var(--sub); font-weight: 700; }
.facts3 dd { margin: 2px 0 0; font-weight: 800; font-size: 14px; }
.note { padding: 12px 14px; border-radius: 12px; background: var(--hanji); }
.note h3 { font: 400 24px/1 var(--cute); margin-bottom: 4px; }
.note h3 small { font-family: var(--font); font-size: 12.5px; color: var(--sub); font-weight: 700; }
.year-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.year-chips span { padding: 3px 10px; border-radius: 6px; background: var(--lamp-soft); font-weight: 800; font-size: 13.5px; color: #7a5200; }
.watch { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.watch li { display: flex; gap: 10px; padding: 8px 12px; border-radius: 10px; background: var(--hanji); font-size: 14.5px; }
.watch b { flex: none; }
.watch span { color: var(--sub); }
.year-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.year-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; padding: 10px 12px; border-radius: 10px; background: var(--hanji); }
.year-list small { grid-column: 1 / -1; color: var(--sub); font-size: 12.5px; }
.fav { border-radius: 6px; }
.stars { display: grid; gap: 6px; }
.star { border-radius: 10px; background: var(--hanji); padding: 0 12px; }
.star summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 9px 0; cursor: pointer; list-style: none; }
.star summary::-webkit-details-marker { display: none; }
.star summary b { font-size: 14.5px; }
.star summary span { font-size: 13px; color: var(--sub); }
.star.good summary b { color: var(--good); }
.star.warn summary b { color: var(--warn); }
.star p { font-size: 14px !important; padding: 0 0 10px; color: var(--ink); }
.book-end { display: grid; gap: 10px; padding-top: 4px; }
.book-end .chips-row { flex-wrap: wrap; }
.screen-more .segment { position: relative; z-index: 7; background: var(--hanji); }

/* ── PC ── */
@media (min-width: 900px) {
  .phone { padding-bottom: 0; }
  .top .wrap { height: 64px; }
  .nav { gap: 22px; margin-left: 36px; }
  .nav button { padding: 20px 0 17px; border-radius: 0; background: none; color: rgba(255, 243, 214, .7); border-bottom: 3px solid transparent; }
  .nav button:hover { background: none; color: #fff; }
  .nav button[aria-current="page"] { background: none; color: #fff; border-bottom-color: var(--lamp); }
  .ring { padding-top: 34px; }
  .ring h1 { font-size: 72px; }
  .ring .lead { font-size: 16.5px; }
  .tori-seat { margin-top: -150px; }
  .tori-seat .hero-tori { width: 190px; }
  .ltag { padding: 34px 32px 24px; }
  .ltag .sijin-chips { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .strings { grid-template-columns: 1fr 1fr; gap: 32px; }
  .strings.compact { grid-template-columns: 1fr; }
  .shelf h2 { font-size: 52px; }
  .site-foot .wrap { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 24px; }
  .sf-legal { text-align: right; }
  .today-band { padding: 30px 0 34px; }
  .today-band .wrap { grid-template-columns: 170px minmax(0, 1fr) 190px; gap: 8px 28px; }
  .today-band .big { width: 170px; grid-row: 1 / span 4; }
  .greet { font-size: 52px; }
  .today-band .msg, .today-band .lucky-line, .band-acts { grid-column: 2; }
  .band-tori { display: block; grid-column: 3; grid-row: 1 / span 4; width: 170px; justify-self: end; animation: float5 3.6s ease-in-out infinite; }
  .road-scroll { overflow: visible; margin: 10px 0 0; padding: 0; }
  .road-svg { width: 100%; }
  .teasers { grid-template-columns: 1fr 1fr; gap: 16px; }
  .lower { grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
  .lower .side { position: sticky; top: 84px; }
  .two-list { grid-template-columns: 1fr 1fr; }
  /* 내 사주 수첩: 왼쪽 목차 고정 + 오른쪽 장 */
  .screen-more .page-main { display: block; }
  .saju-book { grid-template-columns: 220px minmax(0, 1fr); align-items: start; gap: 18px 22px; }
  .book-cover { grid-column: 1 / -1; }
  .book-toc { position: sticky; top: 84px; flex-direction: column; overflow: visible; margin: 0; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
  .book-toc button { justify-content: flex-start; background: none; padding: 8px; }
  .book-toc button:hover { background: var(--hanji); }
  .chapters { min-width: 0; }
  .chapter { padding: 22px 24px 24px; scroll-margin-top: 90px; }
  .pg-col .tile { width: 64px; }
}
@media (min-width: 900px) and (max-width: 1180px) {
  .today-band .wrap { grid-template-columns: 150px minmax(0, 1fr); }
  .band-tori { display: none; }
  .lower { grid-template-columns: minmax(0, 1fr) 300px; }
  .saju-book { grid-template-columns: 190px minmax(0, 1fr); }
}
@media (max-width: 520px) {
  .ltag .sijin-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
/* 6차: 5차 첫 화면 규칙(가운데 절대 위치 토리, 좁은 PC에서 숨김)을 등 고리 자리에 맞게 되돌려요 */
.tori-seat .hero-tori { position: relative; left: auto; bottom: auto; margin: 0; justify-self: center; display: block; z-index: 1; }
.book-page[hidden] { display: none; }
.band { margin-right: 8px; vertical-align: 1px; }
.chapter .me-line { font: 400 28px/1.1 var(--cute); }
.pg-god { min-height: 44px; align-content: start; }
.pg-god i { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.segment button { font-family: var(--font); font-size: 15px; font-weight: 800; letter-spacing: 0; }
.segment button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--lamp); }
.saju-book .lock-card .toc li { grid-template-columns: minmax(0, 1fr); }
.saju-book .lock-card .toc li::before { content: none; }
@media (min-width: 900px) { .stars { grid-template-columns: 1fr 1fr; align-items: start; } }
/* 휴대폰: 등 고리가 짧아서 토리 말풍선이 양끝 등을 가리지 않게 고리 아래로 내려요 */
@media (max-width: 899px) {
  .tori-seat { margin-top: -18px; }
  .tori-seat .hero-tori { width: 128px; }
  .say { font-size: 22px; max-width: 18em; }
}
@media (max-width: 899px) { .say { max-width: 68%; } }
@media (max-width: 374px) { .say { font-size: 21px; } }
.arc { width: min(108%, 100vw); }
