/* 루나레터 — 밤의 달나라 우체국. 우표와 항공우편 봉투가 주인공이고 나머지는 조용하게. */
:root {
  --mist: #E9F0F4;      /* 바탕 — 새벽 안개 */
  --ink: #20304F;       /* 글 — 남색 잉크 */
  --night: #1A2746;     /* 밤하늘 */
  --moon: #F5D77A;      /* 달 */
  --red: #D8453B;       /* 항공우편 빨강 */
  --blue: #2F5DA8;      /* 항공우편 파랑 */
  --pine: #3E7C6B;      /* 초록 잉크(해 볼 일) */
  --paper: #FFFDF8;     /* 편지지 */
  --rule: #CBD7E2;
  --soft: #596883;
  --serif: 'Gowun Batang', 'Nanum Myeongjo', 'AppleMyungjo', 'Batang', serif;
  --sans: -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', 'Noto Sans KR', sans-serif;
  --air: repeating-linear-gradient(-45deg, var(--red) 0 13px, var(--paper) 13px 21px, var(--blue) 21px 34px, var(--paper) 34px 42px);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--mist); color: var(--ink); font: 17px/1.7 var(--sans); word-break: keep-all; overflow-wrap: break-word; }
h1, h2, h3, .serif { font-family: var(--serif); font-weight: 700; line-height: 1.4; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(30px, 5.4vw, 50px); line-height: 1.28; }
h2 { font-size: clamp(24px, 3.4vw, 32px); }
h3 { font-size: 20px; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
a { color: inherit; text-underline-offset: 3px; }
img, svg { max-width: 100%; height: auto; }
button, input, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
.night :focus-visible { outline-color: var(--moon); }
.wrap { width: min(1080px, 100% - 40px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 40px); margin-inline: auto; }
.note { font-size: 15px; color: var(--soft); line-height: 1.65; }
.small { font-size: 15px; }
.nowrap { white-space: nowrap; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: var(--paper); padding: 8px 14px; z-index: 50; }

/* 머리 */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 700 22px/1 var(--serif); }
.brand svg { width: 32px; height: 32px; flex: none; }
.top nav { display: flex; gap: 20px; font-size: 16px; }
.top nav a { text-decoration: none; padding: 8px 0; white-space: nowrap; }
.top nav a:hover { text-decoration: underline; }

/* 밤하늘 머리 화면 */
.night { background: var(--night); color: #F2F5FB; position: relative; overflow: hidden; }
.night .note { color: #B8C4DC; }
.hero { padding: 26px 0 150px; position: relative; }
.hero .big-moon { position: absolute; right: 30px; top: -8px; width: 330px; pointer-events: none; }
.hero p.lead { font-size: 19px; max-width: 30em; margin: 18px 0 0; color: #DCE4F3; position: relative; }
.hero h1 { position: relative; max-width: 13em; }

/* 항공우편 봉투 */
.airmail { background: var(--air); padding: 11px; border-radius: 8px; box-shadow: 0 2px 0 rgba(26, 39, 70, .12), 0 18px 40px -18px rgba(26, 39, 70, .45); }
.airmail > .in { background: var(--paper); border-radius: 3px; padding: clamp(20px, 4vw, 40px); }
.pull { margin-top: -122px; position: relative; }
.airmail > .in { position: relative; }
.env-head { padding-right: 230px; min-height: 92px; }
.env-head .stamp-slot { position: absolute; right: clamp(20px, 4vw, 40px); top: clamp(20px, 4vw, 40px); width: 190px; }
@media (min-width: 761px) { #birth .line:nth-child(-n+2) { margin-right: 230px; } }
.from { font-size: 15px; color: var(--soft); line-height: 1.6; }
.from b { font: 700 19px/1.4 var(--serif); color: var(--ink); display: block; }
.stamp-slot { position: relative; min-height: 226px; }
.stamp-slot .empty { border: 2px dashed #B5C3D3; border-radius: 4px; height: 226px; display: grid; place-content: center; text-align: center; color: var(--soft); font-size: 15px; line-height: 1.6; padding: 10px; }
.stamp { display: block; width: 100%; filter: drop-shadow(0 2px 2px rgba(26, 39, 70, .22)); }
.stamp-slot .stamp { transform: rotate(2.5deg); }
.stamp-slot.hit .stamp { animation: hit .42s cubic-bezier(.2, 1.3, .5, 1); }
@keyframes hit { from { transform: rotate(-7deg) scale(1.5); opacity: 0; } to { transform: rotate(2.5deg) scale(1); opacity: 1; } }
.postmark { position: absolute; left: -62px; top: 92px; width: 130px; opacity: .55; transform: rotate(-14deg); pointer-events: none; }

/* 봉투 위의 주소 줄(입력) */
.lines { display: grid; gap: 4px; margin-top: 10px; }
.line { display: grid; grid-template-columns: 116px 1fr; gap: 14px; align-items: center; border-bottom: 1.5px solid var(--rule); padding: 12px 0; }
.line > .lab { font: 700 18px/1.3 var(--serif); }
.line > div { min-width: 0; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.line input[type=text], .line select, .field input, .field select, .field textarea { border: 1.5px solid #B8C6D6; background: #fff; border-radius: 6px; padding: 11px 12px; font-size: 18px; min-height: 50px; min-width: 0; }
.line input.nm { width: min(260px, 100%); }
.line input.yy { width: 92px; } .line input.mm, .line input.dd { width: 66px; } .line input.mi { width: 66px; }
.line input[aria-invalid=true], .line select[aria-invalid=true], .field input[aria-invalid=true] { border-color: var(--red); background: #FFF6F4; }
.line select { max-width: 100%; }
.seg { display: inline-flex; border: 1.5px solid #B8C6D6; border-radius: 6px; overflow: hidden; background: #fff; }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; inset: 0; }
.seg span { display: block; padding: 11px 17px; font-size: 17px; line-height: 1.5; }
.seg label + label span { border-left: 1.5px solid #D8E1EA; }
.seg input:checked + span { background: var(--ink); color: #fff; }
.seg input:focus-visible + span { box-shadow: inset 0 0 0 3px var(--moon); }
.err { color: #B3271E; font-size: 15.5px; margin: 8px 0 0; line-height: 1.5; }
.hint { color: var(--soft); font-size: 15px; margin: 8px 0 0; line-height: 1.55; }
.agree { display: flex; gap: 11px; align-items: flex-start; margin: 22px 0 18px; font-size: 16px; line-height: 1.6; }
.agree input { width: 23px; height: 23px; margin: 2px 0 0; flex: none; accent-color: var(--ink); }
.hp { position: absolute; left: -9999px; }

/* 단추 */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 11px 24px; border-radius: 6px; border: 2px solid var(--ink); background: transparent; color: var(--ink); font-weight: 700; text-decoration: none; cursor: pointer; line-height: 1.35; text-align: center; }
.btn:hover { background: rgba(32, 48, 79, .07); }
.btn.main { background: var(--red); border-color: var(--red); color: #fff; font-size: 19px; min-height: 60px; }
.btn.main:hover { background: #BF352C; border-color: #BF352C; }
.btn.ink { background: var(--ink); color: #fff; }
.btn.ink:hover { background: #2E4370; }
.btn.wide { width: 100%; }
.btn.s { min-height: 44px; padding: 7px 15px; font-size: 16px; border-width: 1.5px; }
.btn[disabled] { opacity: .55; cursor: default; }
.night .btn { border-color: #F2F5FB; color: #F2F5FB; }
.plain { background: none; border: 0; padding: 8px 2px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; color: var(--soft); }
.btns { display: flex; flex-wrap: wrap; gap: 10px; }

/* 구역 */
section.part { padding: 74px 0 0; }
section.part > .wrap > h2, section.part > .narrow > h2 { margin-bottom: 14px; }
.lead { font-size: 18.5px; }
.parade { display: flex; gap: 14px; overflow-x: auto; padding: 6px 20px 20px; margin: 26px calc(50% - 50vw) 0; scrollbar-width: none; justify-content: safe center; }
.parade::-webkit-scrollbar { display: none; }
.parade a { flex: none; width: 138px; text-decoration: none; }
.parade a:nth-child(odd) { transform: rotate(-1.6deg); }
.parade a:nth-child(even) { transform: rotate(1.4deg) translateY(8px); }

/* 편지 세 통 */
.letters { display: grid; gap: 18px; margin-top: 28px; }
.letter-row { display: grid; grid-template-columns: 148px 1fr auto; gap: 10px 26px; align-items: center; background: var(--paper); padding: 24px 28px; border-left: 10px solid transparent; border-image: var(--air) 10; border-radius: 0; }
.letter-row h3 { font-size: 24px; }
@media (min-width: 761px) { .letter-row .envelope { grid-row: 1 / span 2; } .letter-row ul { grid-column: 2 / -1; } }
.letter-row ul { margin: 10px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 16px; color: #3F4F70; }
.letter-row ul li::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--moon); box-shadow: 0 0 0 1.5px #C69F2E; margin: 0 8px 3px 0; }
.letter-row .price { text-align: right; min-width: 150px; }
.price b { font: 700 27px/1.2 var(--serif); display: block; white-space: nowrap; }
.price .note { display: block; margin-bottom: 8px; }
.price b + .btn, .price .note + .btn { margin-top: 10px; }
.envelope { width: 148px; aspect-ratio: 148 / 104; position: relative; }

/* 편지지 */
.sheet { background: var(--paper); padding: clamp(26px, 6vw, 58px) clamp(22px, 7vw, 68px); margin: 0 0 20px; position: relative; scroll-margin-top: 76px; }
.sheet + .sheet { border-top: 0; }
.sheet h2 { font-size: clamp(24px, 3.6vw, 31px); margin-bottom: 20px; }
.sheet .body { font: 400 18.5px/1.95 var(--serif); }
.sheet .body p { margin-bottom: 1.15em; }
.sheet .tag { font-size: 15.5px; color: var(--soft); margin: -12px 0 18px; }
.tip { margin-top: 26px; padding: 18px 20px 18px 22px; border-left: 5px solid var(--pine); background: #EEF5F1; }
.tip b { display: block; color: #2C6252; font: 700 17px/1.4 var(--serif); margin-bottom: 4px; }
.tip.care { border-color: var(--red); background: #FCF1EE; }
.tip.care b { color: #A8332A; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.two .tip { margin-top: 0; }
.portrait { width: 92px; height: 92px; border-radius: 50%; overflow: hidden; float: right; margin: -6px 0 12px 20px; box-shadow: 0 0 0 4px #fff, 0 0 0 5.5px var(--rule); }
.portrait svg { display: block; width: 100%; }
.sign { text-align: right; font: 400 18px/1.6 var(--serif); margin-top: 30px; }

/* 편지 표지 */
.cover { margin: 0 0 20px; }
.cover > .in { display: grid; grid-template-columns: 1fr auto; gap: 24px; min-height: 340px; padding: clamp(22px, 5vw, 48px); }
.cover .addr { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.cover .who { font: 700 22px/1.4 var(--serif); margin: 0; }
.cover h1 { font-size: clamp(29px, 5vw, 43px); margin-top: 6px; }
.cover .stamps { position: relative; align-self: start; display: grid; gap: 14px; width: 190px; }
.cover .stamps .stamp { transform: rotate(2.5deg); }
.cover .stamps.pair { width: 270px; grid-template-columns: 1fr 1fr; }
.cover .stamps.pair .stamp + .stamp { transform: rotate(-2.5deg); }
.cover .pm { position: absolute; left: -54px; bottom: -26px; width: 130px; opacity: .55; transform: rotate(-14deg); pointer-events: none; z-index: 1; }

/* 사주 한 장 */
.pillars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 6px 0 24px; text-align: center; }
.pillar { border: 1.5px solid var(--rule); border-radius: 8px; padding: 14px 6px 12px; background: #fff; }
.pillar.me { border: 2.5px solid var(--red); padding: 13px 5px 11px; }
.pillar .w { font-size: 15px; color: var(--soft); line-height: 1.4; }
.pillar .h { font: 700 33px/1.18 var(--serif); margin: 6px 0 4px; }
.pillar .k { font-size: 16px; font-weight: 700; }
.pillar .a { font-size: 14.5px; color: var(--soft); }
.bars { display: grid; gap: 9px; }
.bar { display: grid; grid-template-columns: 50px 1fr 46px; gap: 12px; align-items: center; font-size: 16px; }
.bar i { display: block; height: 16px; border-radius: 3px; }
.bar .t { background: #EDF1F5; border-radius: 3px; overflow: hidden; }
.bar .n { text-align: right; font-variant-numeric: tabular-nums; }

/* 열두 달 하늘 */
.sky { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.sky > * { background: #fff; border: 1.5px solid var(--rule); border-radius: 8px; padding: 13px 14px; text-align: left; color: inherit; text-decoration: none; }
.sky .mo { font: 700 18px/1.3 var(--serif); display: flex; align-items: center; justify-content: space-between; gap: 6px; }
svg.wx { width: 24px; height: 24px; vertical-align: -6px; }
.sky svg.wx { width: 32px; height: 32px; flex: none; }
.sky .tt { font-size: 15.5px; line-height: 1.5; margin-top: 6px; display: block; }
.wxs { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 15.5px; color: var(--soft); margin: 16px 0 0; }
.wxs span { display: inline-flex; align-items: center; gap: 7px; }
.wxs svg { width: 25px; height: 25px; }

/* 달 엽서 */
.postcard { display: grid; grid-template-columns: 1fr 112px; gap: 22px; align-items: start; margin-bottom: 18px; }
.postcard .mnum { font: 700 clamp(38px, 7vw, 58px)/1 var(--serif); letter-spacing: -.03em; }
.postcard .when { font-size: 15.5px; color: var(--soft); margin-top: 8px; display: flex; align-items: center; gap: 8px; }
.postcard .when svg { width: 24px; }

/* 날짜 달력 */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal-head b { font: 700 23px/1 var(--serif); }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.cal .dow { text-align: center; font-size: 15px; color: var(--soft); padding: 4px 0; }
.cal button { border: 1.5px solid var(--rule); background: #fff; border-radius: 6px; min-height: 62px; padding: 5px 2px; cursor: pointer; display: grid; justify-items: center; align-content: center; gap: 2px; font-size: 16px; }
.cal button svg { width: 23px; height: 23px; }
.cal button[aria-pressed=true] { border-color: var(--ink); background: var(--ink); color: #fff; }
.daybox { margin-top: 18px; padding: 20px 22px; background: #EFF4F8; border-radius: 8px; }
.daybox h3 { margin-bottom: 8px; }

.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.tabs button { border: 1.5px solid var(--rule); background: #fff; border-radius: 24px; padding: 9px 18px; min-height: 46px; cursor: pointer; }
.tabs button[aria-selected=true] { background: var(--ink); color: #fff; border-color: var(--ink); }

.luck { display: grid; gap: 14px; }
.luck > div { border: 1.5px solid var(--rule); border-radius: 8px; padding: 18px 20px; background: #fff; }
.luck > .now { border: 2.5px solid var(--red); }
.luck .age { font-size: 15.5px; color: var(--soft); }
.luck h3 { margin: 2px 0 8px; }

.duo { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px, 4vw, 44px); max-width: 520px; margin: 0 auto 26px; text-align: center; }
.duo b { display: block; margin-top: 8px; font: 700 19px/1.4 var(--serif); }
.gauge { display: grid; grid-template-columns: 1fr auto; gap: 4px 14px; padding: 13px 0; border-top: 1.5px solid var(--rule); align-items: center; }
.gauge .d { display: flex; gap: 5px; }
.gauge .d i { width: 17px; height: 17px; border-radius: 50%; border: 1.5px solid #C69F2E; }
.gauge .d i.on { background: var(--moon); }
.gauge .note { grid-column: 1 / -1; }

/* 편지 읽는 화면 */
.readbar { position: sticky; top: 0; z-index: 10; background: var(--night); color: #fff; }
.readbar .wrap { display: flex; align-items: center; gap: 14px; min-height: 58px; }
.readbar a { text-decoration: none; }
.readbar b { font-family: var(--serif); flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.readbar .btn.s { border-color: #8FA0C4; color: #fff; min-height: 42px; }
.toc { background: var(--paper); padding: 24px 26px; margin: 22px 0; }
.toc ol { margin: 12px 0 0; padding: 0 0 0 1.4em; columns: 2; column-gap: 34px; font-size: 16.5px; }
.toc li { break-inside: avoid; padding: 3px 0; }
.seal-scene { text-align: center; padding: 44px 0 70px; }
.seal-env { width: min(440px, 88%); margin: 26px auto 30px; display: block; }
.seal-env { overflow: visible; }
.seal-env .flap { transform-origin: 220px 113px; transition: transform .5s ease-in; }
.seal-env .sheet-in { transition: transform .7s ease-out; }
.seal-env.up .sheet-in { transform: translateY(-96px); }
.seal-env.open .flap { transform: scaleY(-1) translateY(-2%); }
.seal-env .wax { transition: opacity .25s; }
.seal-env.open .wax { opacity: 0; }

/* 편지함 */
.stampcard { display: grid; grid-template-columns: 270px 1fr; gap: clamp(24px, 5vw, 60px); align-items: center; padding: 22px 0 60px; }
.stampcard .stamp { transform: rotate(-2deg); }
.stampcard .nick { font: 700 clamp(27px, 4.4vw, 40px)/1.35 var(--serif); margin: 4px 0 12px; }
.traits { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.traits li { padding-left: 30px; position: relative; }
.traits li::before { content: ''; position: absolute; left: 2px; top: 6px; width: 17px; height: 17px; border-radius: 50%; background: var(--moon); }
.traits li::after { content: ''; position: absolute; left: 8px; top: 3px; width: 15px; height: 15px; border-radius: 50%; background: var(--night); }
.teaser { position: relative; max-height: 250px; overflow: hidden; }
.teaser::after { content: ''; position: absolute; inset: auto 0 0; height: 120px; background: linear-gradient(rgba(255, 253, 248, 0), var(--paper)); }
.people { display: grid; gap: 14px; margin-top: 20px; }
.person { background: var(--paper); display: grid; grid-template-columns: 84px 1fr auto; gap: 18px; align-items: center; padding: 16px 20px; border-radius: 8px; }
.person .stamp { width: 84px; }
.person h3 { font-size: 19px; }
.person p { margin: 2px 0 0; font-size: 16px; }
.keep { background: var(--paper); padding: 26px 28px; border-radius: 8px; }
.code { font: 700 30px/1.3 ui-monospace, 'Consolas', monospace; letter-spacing: .14em; }
.panel { background: var(--paper); border-radius: 8px; padding: 26px 28px; }
.doc .headrow + .alertbox { margin-top: 22px; }
.alertbox { background: #FFF4E2; border-left: 5px solid #E0A52C; padding: 14px 18px; font-size: 16px; }
.back-bar { background: var(--moon); color: var(--night); }
.back-bar .wrap { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; justify-content: space-between; padding: 10px 0; }

/* 창 */
dialog { border: 0; border-radius: 10px; padding: 0; width: min(520px, 100% - 28px); color: inherit; background: var(--paper); max-height: calc(100dvh - 28px); }
dialog::backdrop { background: rgba(20, 30, 55, .62); }
dialog .in { padding: 28px 26px 26px; }
dialog h2 { font-size: 25px; margin-bottom: 12px; }
dialog.wide { width: min(700px, 100% - 28px); }
.field { display: block; margin: 16px 0; }
.field > span { display: block; font-weight: 700; margin-bottom: 6px; }
.field input { width: 100%; }
.field .nowrap input { padding: 11px 9px; }
.sum { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-block: 1.5px solid var(--rule); font-size: 18px; }
.toast { position: fixed; left: 50%; bottom: 30px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 14px 22px; border-radius: 8px; z-index: 90; max-width: calc(100% - 32px); box-shadow: 0 10px 30px rgba(20, 30, 55, .3); }

/* 도움 글(띠·일주) */
.crumb { font-size: 15.5px; color: var(--soft); margin: 6px 0 20px; }
.grid12 { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: 22px; }
.grid12 a { text-decoration: none; text-align: center; font-size: 16.5px; }
.grid12 a b { display: block; margin-top: 6px; }
.grid12 a:hover .stamp { transform: translateY(-4px); }
.grid12 .stamp { transition: transform .18s; }
.headrow { display: grid; grid-template-columns: 230px 1fr; gap: 40px; align-items: center; }
table { width: 100%; border-collapse: collapse; font-size: 16.5px; }
th, td { text-align: left; padding: 11px 10px; border-bottom: 1.5px solid var(--rule); vertical-align: top; }
th { white-space: nowrap; }
.doc h2 { margin: 42px 0 12px; font-size: 24px; }
.doc h3 { margin: 24px 0 8px; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin-bottom: 6px; }
details.q { border-bottom: 1.5px solid var(--rule); padding: 4px 0; }
details.q summary { cursor: pointer; font: 700 18.5px/1.6 var(--serif); padding: 13px 30px 13px 0; list-style: none; position: relative; }
details.q summary::-webkit-details-marker { display: none; }
details.q summary::after { content: ''; position: absolute; right: 8px; top: 23px; width: 10px; height: 10px; border: solid var(--ink); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); transition: transform .2s; }
details.q[open] summary::after { transform: rotate(-135deg); top: 28px; }
details.q > div { padding: 0 0 18px; }

footer.foot { margin-top: 90px; padding: 34px 0 46px; border-top: 1.5px solid var(--rule); font-size: 15px; color: var(--soft); line-height: 1.75; }
footer.foot .links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-bottom: 14px; }
footer.foot a { color: inherit; }
.bizbox summary { cursor: pointer; }
.biz { margin: 6px 0 0; }
.doc table th { width: 170px; }

@media (max-width: 760px) {
  body { font-size: 16.5px; }
  .hero { padding: 12px 0 140px; }
  .hero .big-moon { width: min(136px, 36vw); right: -2px; top: -14px; }
  .hero p.lead { font-size: 17.5px; margin-top: 38px; }
  .env-head { padding-right: 132px; min-height: 160px; }
  .env-head .stamp-slot { width: 118px; right: 20px; top: 20px; }
  .line input.yy { width: 78px; } .line input.mm, .line input.dd { width: 54px; }
  .line .row { gap: 8px; } .line input[type=text], .line select { padding: 11px 10px; }
  .stamp-slot { min-height: 140px; } .stamp-slot .empty { height: 140px; font-size: 13.5px; padding: 6px; }
  .postmark { width: 78px; left: -26px; top: 58px; }
  .line { grid-template-columns: 1fr; gap: 6px; padding: 12px 0 14px; }
  .airmail { padding: 8px; }
  .seg span { padding: 11px 14px; font-size: 16.5px; }
  section.part { padding-top: 58px; }
  .letter-row { grid-template-columns: 84px 1fr; gap: 12px 18px; padding: 20px; }
  .letter-row .envelope { width: 84px; }
  .letter-row .price { grid-column: 1 / -1; text-align: left; display: flex; align-items: center; justify-content: space-between; gap: 14px; }
  .price .note { margin: 0; }
  .letter-row .price .btn { margin-top: 0; }
  .letter-row ul { grid-column: 1 / -1; }
  .stampcard { grid-template-columns: 1fr; padding-bottom: 44px; }
  .stampcard .stamp { width: 220px; margin: 0 auto; }
  .cover > .in { min-height: 300px; padding: 22px 20px; gap: 14px; }
  .cover .addr { gap: 26px; }
  .cover .stamps { width: 118px; } .cover .stamps.pair { width: 108px; grid-template-columns: 1fr; gap: 6px; }
  .cover .pm { width: 84px; left: -24px; bottom: -16px; }
  .sky { grid-template-columns: 1fr 1fr; }
  .two { grid-template-columns: 1fr; }
  .postcard { grid-template-columns: 1fr 88px; gap: 14px; }
  .toc ol { columns: 1; }
  .sheet .body { font-size: 18px; line-height: 1.9; }
  .pillars { gap: 6px; } .pillar .h { font-size: 27px; } .pillar .a { font-size: 13.5px; } .pillar .w { font-size: 13.5px; }
  .person { grid-template-columns: 70px 1fr; } .person .stamp { width: 70px; } .person .btns { grid-column: 1 / -1; }
  .grid12 { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .headrow { grid-template-columns: 1fr; gap: 20px; } .headrow .stamp { width: 190px; }
  .cal { gap: 3px; } .cal button { min-height: 54px; font-size: 15px; } .cal button svg { width: 19px; height: 19px; }
  .readbar .wrap { gap: 8px; } .readbar .btn.s { padding: 6px 10px; font-size: 15px; }
  .top nav { gap: 14px; font-size: 15.5px; }
  .top nav:has(#navMe:not([hidden])) #navFind, .top nav:has(#navMe:not([hidden])) a[href='/sample'] { display: none; }
  th, td { padding: 10px 6px; } .doc table th { width: 112px; white-space: normal; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
@media print {
  @page { size: A4; margin: 18mm 16mm; }
  body { background: #fff; font-size: 12pt; }
  .readbar, .toc, .noprint, footer.foot, .top, .tabs, .cal, .cal-head, .daybox, .toast { display: none !important; }
  .cover { break-after: page; box-shadow: none; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cover > .in { min-height: 120mm; }
  .sheet { padding: 0 0 14mm; margin: 0; background: #fff; }
  .sheet .body { font-size: 12.5pt; line-height: 1.85; }
  .sheet h2, .postcard { break-after: avoid; }
  .tip, .luck > div, .pillars, .bars, .sky > *, .duo { break-inside: avoid; }
  .sheet[data-kind=days] { display: none; }
  .tabpane[hidden] { display: block !important; }
  .tabpane::before { content: attr(data-label); font-weight: 700; }
  .pillar, .tip, .bar i, .gauge .d i { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
