@font-face{font-family:LetterHand;src:url('assets/fonts/letter-hand.woff2') format('woff2');font-display:swap;font-weight:400}
@font-face{font-family:LetterSerif;src:url('assets/fonts/letter-serif.woff2?v=43') format('woff2');font-display:swap;font-weight:400}
:root{color-scheme:light;--cream:#f8f2ea;--ink:#573a2a;--title:#75432e;--rust:#a75134;--gold:#bd8955;--serif:LetterSerif,"Noto Serif TC","Noto Serif CJK TC","Songti TC",PMingLiU,serif;--hand:LetterHand,"BiauKai","DFKai-SB","KaiTi",var(--serif);--sunset-position:50% 50%;--sunset-text-left:0px;--sunset-text-top:0px}
*,*::before,*::after{box-sizing:border-box}
html{min-width:280px;scroll-behavior:auto;background:#ede1d1;overflow-x:clip;scrollbar-width:none;-webkit-text-size-adjust:100%;text-size-adjust:100%}
html::-webkit-scrollbar{display:none}
body{margin:0;color:var(--ink);background:#ede1d1 url('assets/paper.webp') center/540px;font-family:var(--serif);font-weight:400;-webkit-text-size-adjust:100%;text-rendering:optimizeLegibility;min-height:100svh}
button{font:inherit;touch-action:manipulation;cursor:pointer;-webkit-tap-highlight-color:transparent}
button:focus-visible{outline:2px solid #955738;outline-offset:5px}
button:disabled{cursor:default}
[hidden]{display:none!important}
.shell{width:100%;max-width:600px;margin-inline:auto}
.cover{height:100svh;min-height:540px;max-height:1100px;position:relative;isolation:isolate;container-type:size;overflow:hidden;text-align:center;color:#fff3df;background:#3e2415}
.cover-plane{position:absolute;left:50%;top:50%;width:max(100cqw,46.04978355cqh);height:max(100cqh,217.15628672cqw);transform:translate(-50%,-50%);container-type:inline-size}
.cover-photo{display:block;width:100%;height:100%;object-fit:fill}
.cover::after{content:"";position:absolute;inset:0;pointer-events:none;z-index:0;background:linear-gradient(180deg,#170d052e 0%,transparent 42%,transparent 75%,#24140826)}
.cover-header{position:absolute;z-index:1;top:6.5%;left:14px;right:14px;text-shadow:0 1px 9px #241408b3}
.eyebrow{font:400 11px/1.45 Georgia,"Times New Roman",serif;letter-spacing:.25em}
.cover .eyebrow{font-size:11px;letter-spacing:.28em}
.cover-divider{display:block;width:70px;height:21px;margin:12px auto 10px;color:#edcca6}
.cover h1{font:400 clamp(29px,7.8cqw,43px)/1.48 var(--hand);letter-spacing:.055em;margin:0 auto 17px}
.cover h1 span{display:block}
.cover-header p{font-size:clamp(13px,3.65cqw,18px);line-height:1.8;letter-spacing:.05em;margin:0}
.cover-address{position:absolute;left:29.5%;top:58.1%;width:28%;transform:rotate(-3.3deg);transform-origin:0 50%;color:#6b402a;font:400 5.5cqw/1.25 var(--hand);text-align:left;white-space:nowrap}
.cover-address svg{display:block;width:96%;height:auto;margin-top:3%}
.open-button{position:absolute;z-index:2;bottom:11%;left:50%;transform:translateX(-50%);min-height:48px;padding:8px 23px 10px 26px;display:flex;align-items:center;gap:14px;border:1px solid #f4d4ad;border-radius:999px;background:#75472ba8;box-shadow:0 4px 22px #23110932,inset 0 0 0 1px #68412833;color:#fff7e9;font:400 20px/1.4 var(--hand);letter-spacing:.12em;white-space:nowrap;transition:background .2s,box-shadow .2s}
.open-button svg{width:14px;height:18px}
.open-button:active{background:#9b613cd6}
.reader{padding:12px 10px max(12px,env(safe-area-inset-bottom));overflow-x:clip;overflow-y:visible}
.sheet-stack{position:relative;isolation:isolate;filter:drop-shadow(0 6px 8px #75543520)}
.sheet-stack::before,.sheet-stack::after{content:"";position:absolute;inset:3px 2px -3px;z-index:-2;background:#e6d6be url('assets/paper.webp') center/440px;box-shadow:0 1px 1px #8b654a33;transform:rotate(-.45deg);clip-path:polygon(.2% .15%,99.7% 0,100% 99.5%,99.6% 100%,.3% 99.7%,0 .8%)}
.sheet-stack::after{inset:1px 3px -5px;z-index:-3;transform:rotate(.35deg);opacity:.8}
.paper{position:relative;isolation:isolate;min-width:0;width:100%;overflow:hidden;background:var(--cream) url('assets/paper.webp') center/480px;clip-path:polygon(.3% .25%,3% .12%,7% .2%,13% .06%,19% .19%,25% .08%,33% .17%,41% 0,48% .13%,57% .07%,64% .19%,72% .09%,81% .16%,87% .06%,94% .17%,99.7% .1%,99.82% 9%,99.65% 18%,99.87% 29%,99.72% 39%,99.9% 51%,99.69% 62%,99.86% 74%,99.7% 86%,99.86% 99.75%,94% 99.88%,86% 99.7%,77% 99.91%,68% 99.79%,59% 99.97%,48% 99.83%,39% 99.95%,31% 99.8%,20% 99.96%,11% 99.8%,.22% 99.88%,.09% 89%,.24% 76%,.08% 63%,.2% 50%,.05% 39%,.19% 28%,0 17%,.19% 8%)}
.stationery{display:flex;flex-direction:column;min-height:calc(100svh - 110px);--art-height:190px;--art:url('assets/page-1.webp');box-shadow:inset 0 0 18px #ad7d3e13;touch-action:pan-y pinch-zoom}
.stationery::before{content:"";pointer-events:none;position:absolute;inset:0;z-index:-1;background:radial-gradient(ellipse at 0 0,#d9b27c15,transparent 45%),radial-gradient(ellipse at 100% 100%,#b8844030,transparent 40%);box-shadow:inset 1px 0 3px #b9986b44,inset -1px 0 3px #bd9c6c33}
.paper-corner{position:absolute;pointer-events:none;top:0;left:0;width:100%;height:130px;z-index:0;background-image:var(--art);background-position:center top;background-size:100% auto;background-repeat:no-repeat;mix-blend-mode:multiply;mask-image:linear-gradient(#000 65%,transparent);-webkit-mask-image:linear-gradient(#000 65%,transparent)}
.folio{position:absolute;z-index:2;top:25px;right:88px;font:400 12px/1.4 Georgia,"Times New Roman",serif;letter-spacing:.1em;color:#7d634b}
.paper-copy{position:relative;z-index:1;padding:57px 28px 19px}
.paper h2{font:400 32px/1.4 var(--hand);color:var(--title);letter-spacing:.08em;margin:0;outline:none}
.flourish{display:block;width:min(88%,266px);height:27px;margin:1px 0 14px -2px;color:var(--gold)}
.bodycopy{font-size:17px;line-height:1.85;letter-spacing:.027em;overflow-wrap:anywhere;line-break:strict;word-break:normal}
.bodycopy p{margin:0 0 1.12em;white-space:normal}
.bodycopy p:last-child{margin-bottom:0}
.paper-art{flex:0 0 var(--art-height);height:var(--art-height);width:100%;margin-top:auto;background-image:var(--art);background-position:center bottom;background-size:100% auto;background-repeat:no-repeat;mask-image:linear-gradient(transparent 0,#000 29%,#000 100%);-webkit-mask-image:linear-gradient(transparent 0,#000 29%,#000 100%)}
.theme-1{--art:url('assets/page-1.webp');--art-height:190px}
.theme-2{--art:url('assets/page-2.webp');--art-height:146px}
.theme-3{--art:url('assets/page-3.webp');--art-height:180px}
.theme-4{--art:url('assets/page-4.webp');--art-height:183px}
.theme-5{--art:url('assets/page-5.webp');--art-height:188px}
.theme-6{--art:url('assets/page-6.webp');--art-height:196px}
.theme-7{--art:url('assets/page-7.webp');--art-height:145px}
.theme-2 .flourish{color:#a78b69}.theme-3 .flourish{color:#b79061}.theme-4 .flourish{color:#ac8156}.theme-5 .flourish{color:#c28a51}.theme-6 .flourish{color:#9b9c73}.theme-7 .flourish{color:#bf9065}
.final{touch-action:pan-y pinch-zoom;clip-path:none;background:transparent;container-type:inline-size}
.sheet-stack.is-final::before,.sheet-stack.is-final::after{display:none}
.sunset-frame{position:relative;margin:0;width:100%;isolation:isolate;overflow:hidden;border-radius:2px}
.sunset-photo{display:block;width:100%;height:auto;aspect-ratio:3/4;object-fit:cover;object-position:var(--sunset-position);filter:none}
.sky-glow{position:absolute;z-index:0;top:0;left:0;width:91%;height:49%;pointer-events:none;background:radial-gradient(ellipse at 22% 16%,#fff6e2a1 0%,#fff4e16b 47%,#fff2df19 69%,transparent 86%)}
.final-message{position:absolute;z-index:1;top:var(--sunset-text-top);left:var(--sunset-text-left);width:70%;padding:4.7cqw 0 0 6.4cqw;color:#573e2d;text-shadow:0 1px 3px #fff2dc63}
.final .eyebrow{font-size:clamp(10px,2.65cqw,14px);letter-spacing:.17em}
.final .final-message h2{font-size:clamp(17px,6.8cqw,39px);line-height:1.38;letter-spacing:.02em;color:#6d3926;margin-top:2.6cqw;white-space:nowrap}
.final .flourish{width:53cqw;height:6cqw;margin:0 0 3.3cqw 9.9cqw;color:#b37b4b}
.final-copy{font-size:clamp(13px,4.15cqw,22px);line-height:1.65;letter-spacing:.01em}
.final-copy p{margin:0}
.final .blessing{font:400 clamp(16px,5cqw,28px)/1.45 var(--hand);color:#98492d;white-space:nowrap;margin-top:2.2cqw}
.final .signature{font-size:clamp(11px,3.35cqw,19px);line-height:1.55;letter-spacing:.055em;margin-top:2.9cqw;white-space:nowrap}
.final-folio{top:auto;bottom:13px;right:15px;color:#fff6e8;text-shadow:0 1px 4px #2c251f;letter-spacing:.12em}
.final-message.is-below{position:relative;inset:auto;width:100%;padding:24px 26px 28px;background:var(--cream) url('assets/paper.webp') center/480px;text-shadow:none}
.reader-footer{padding:15px 3px 0}
.navigation{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:12px}
.page-button{display:flex;align-items:center;justify-content:center;gap:9px;min-height:45px;width:max-content;min-width:105px;max-width:100%;border:1px solid #ad895e7a;border-radius:999px;background:#fbf5e9cc;padding:9px 15px;color:#714c34;font-size:14px;line-height:1.4;box-shadow:0 2px 5px #69462507;transition:background .2s}
.page-button svg{width:11px;height:17px;flex-shrink:0}
.page-button:last-child{justify-self:end}
.page-button:active{background:#e9d7bf}
.page-button:disabled{opacity:.75}
.progress-dots{display:flex;align-items:center;gap:6px;height:12px}
.progress-dots i{width:3px;height:3px;border-radius:50%;background:#c0a585;transition:background .3s,transform .3s}
.progress-dots i.on{background:#865335;transform:scale(1.6)}
.reading-note{text-align:center;font:400 11px/1.5 var(--serif);letter-spacing:.17em;color:#9a795b;margin:10px 0 0}
.audio-row{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:8px 12px;margin-top:14px}
.sound-button{border:0;background:transparent;border-bottom:1px solid #bea07e;color:#7d573d;font-size:13px;line-height:1.5;padding:6px;min-height:36px}
.audio-status{font-size:12px;color:#8b6a4d;line-height:1.6;text-align:center}
.turn-next{animation:page-next .66s cubic-bezier(.22,.65,.31,1) both;transform-origin:4% 50%}
.turn-prev{animation:page-prev .66s cubic-bezier(.22,.65,.31,1) both;transform-origin:96% 50%}
@keyframes page-next{from{opacity:.15;transform:perspective(1400px) rotateY(-9deg) translateX(9px)}to{opacity:1;transform:none}}
@keyframes page-prev{from{opacity:.15;transform:perspective(1400px) rotateY(9deg) translateX(-9px)}to{opacity:1;transform:none}}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.noscript-note{padding:20px;text-align:center;background:var(--cream)}
@media(min-width:601px){.shell{padding-block:18px}.cover{height:min(100svh - 36px,900px);min-height:640px;box-shadow:0 12px 45px #6543222b}.reader{padding:0 10px 18px}.stationery{min-height:calc(100svh - 132px);--art-height:250px}.paper-copy{padding:70px 49px 22px}.paper h2{font-size:37px}.bodycopy{font-size:19px;line-height:1.9;letter-spacing:.035em}.folio{top:30px;right:116px}.paper-corner{height:175px}.theme-2,.theme-7{--art-height:205px}.theme-1{--art-height:275px}.final-folio{right:18px;top:auto}.reading-note{margin-top:12px}}
@media(max-width:360px){.reader{padding:8px 8px 12px}.paper-copy{padding:51px 23px 16px}.paper h2{font-size:29px}.bodycopy{font-size:16px;line-height:1.84;letter-spacing:.015em}.folio{font-size:11px;top:22px;right:74px}.paper-corner{height:110px}.stationery{min-height:calc(100svh - 91px)}.theme-1{--art-height:172px}.theme-2{--art-height:118px}.theme-3{--art-height:148px}.theme-4{--art-height:150px}.theme-5{--art-height:154px}.theme-6{--art-height:160px}.theme-7{--art-height:118px}.flourish{height:25px;margin-bottom:12px}.page-button{min-width:95px;min-height:44px;padding:9px 12px;gap:7px;font-size:13px}.navigation{gap:9px}.progress-dots{gap:5px}.reader-footer{padding-inline:1px}.cover h1{font-size:27px;letter-spacing:.025em}.cover .eyebrow{font-size:10px}.cover-header p{font-size:12.5px;letter-spacing:.02em}.cover-divider{margin:9px auto}.cover-header{top:6.2%}.open-button{font-size:18px;min-height:46px;bottom:9.5%}.final-folio{right:13px;top:auto}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
@media print{body{background:white}.cover,.reader-footer{display:none!important}.reader,.paper{display:block!important}.paper{break-after:page;clip-path:none;min-height:240mm}.paper-art{height:55mm}.shell{max-width:none}.sheet-stack{filter:none}}

/* Keep the sender's line breaks while allowing long phrases to wrap on narrow screens. */
.bodycopy .letter-line {
  display: block;
  text-wrap: pretty;
}
.bodycopy .keep-together {
  white-space: nowrap;
}

@media (max-width: 600px) {
  .bodycopy .letter-line {
    text-wrap: wrap;
  }

  /* Keep each clause together when it fits, including the closing punctuation. */
  .bodycopy .mobile-phrase {
    display: inline-block;
    max-width: 100%;
  }
}

@media (max-width: 410px) {
  .paper-copy {
    padding-inline: clamp(13px, calc(19vw - 50px), 28px);
  }
}

@media (max-width: 360px) {
  .bodycopy {
    letter-spacing: .01em;
  }
}
