:root{
  --night:#171024;--deep:#261b31;--cream:#fff6e7;--paper:#f9f1e4;--gold:#deb681;
  --blush:#f2c6bd;--muted:#c2afc5;--green:#c0d7ba;--ink:#362c38;
  --ease:cubic-bezier(.2,.8,.2,1);font-synthesis:none;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--night);color:var(--cream);font-family:'Avenir Next',Avenir,'Trebuchet MS',system-ui,sans-serif;-webkit-font-smoothing:antialiased}
button,input{font:inherit}button{cursor:pointer}a{color:inherit}button:focus-visible,a:focus-visible,input:focus-visible,summary:focus-visible,.shelf-zone:focus-visible{outline:3px solid #ffe2a6;outline-offset:4px}
button[disabled]{cursor:not-allowed}
[hidden]{display:none!important}
.shell{min-height:100svh;position:relative;isolation:isolate;overflow:hidden;background:radial-gradient(ellipse 62% 60% at 50% 42%,#422d50 0%,#2c213a 43%,#1b1429 82%)}
.night-sky{position:absolute;inset:0;z-index:-2;pointer-events:none;background-image:radial-gradient(circle at 9% 17%,#ffead1 0 1px,transparent 1.7px),radial-gradient(circle at 23% 58%,#ffead1 0 1.5px,transparent 2px),radial-gradient(circle at 81% 25%,#ffead1 0 1px,transparent 1.8px),radial-gradient(circle at 75% 79%,#ffead1 0 1.1px,transparent 2px),radial-gradient(circle at 58% 12%,#ffead1 0 .8px,transparent 1.5px);background-size:230px 190px,470px 390px,370px 310px,240px 270px,190px 320px;opacity:.65}
.mist{position:absolute;display:block;filter:blur(45px);border-radius:50%;opacity:.25}.mist-one{width:500px;height:330px;left:-200px;top:14%;background:#a177a7}.mist-two{width:600px;height:360px;right:-250px;bottom:0;background:#986879}
.grain{position:fixed;inset:0;pointer-events:none;z-index:15;opacity:.23;mix-blend-mode:soft-light;background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.76' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath filter='url(%23n)' opacity='.65' d='M0 0h180v180H0z'/%3E%3C/svg%3E")}
.topbar{height:90px;display:grid;grid-template-columns:1fr 1fr 1fr;align-items:center;gap:24px;padding:0 clamp(22px,4.3vw,74px);position:relative;z-index:3;border-bottom:1px solid rgba(247,229,213,.12)}
.wordmark{text-decoration:none;white-space:nowrap;font:600 clamp(21px,2.2vw,30px)/1 Georgia,serif;letter-spacing:-.035em}.brand-leaf{color:var(--gold);font-size:23px;margin-right:6px}.brand-dot{color:var(--blush)}.brand-moon{font-size:20px;color:var(--gold);margin-left:9px}.top-note{text-align:center;letter-spacing:.29em;font-size:10px;font-weight:750;color:#d9c0d8;white-space:nowrap}.top-note span{color:var(--gold);margin:0 6px}.back-home{font-size:12px;justify-self:end;color:#f5d9d3;text-decoration:none}.back-home:hover{text-decoration:underline}
.library-content{position:relative;z-index:1;min-height:calc(100svh - 90px);display:flex;align-items:center;flex-direction:column;padding:31px 0 24px}.hero-copy{text-align:center;padding:0 20px}.overline,.gate-eyebrow,.detail-overline{font-size:10px;font-weight:750;letter-spacing:.24em;color:var(--gold);margin:0 0 10px}.small-star{font-size:16px;padding:0 11px}.hero-copy h1{font:400 clamp(38px,4.2vw,61px)/1.02 Georgia,'Times New Roman',serif;letter-spacing:-.04em;margin:0}.hero-copy h1 em{font-weight:400;color:var(--blush)}.hero-description{font-size:14px;line-height:1.5;color:#eadbe7;margin:12px 0 0}
.filter-tabs{display:flex;align-items:center;gap:5px;margin:24px auto -16px;padding:5px;border:1px solid #f4deca3b;background:#281d32ba;border-radius:30px;z-index:3}.filter{border:0;background:transparent;border-radius:100px;padding:9px 14px;color:#dac8d8;font-size:11px;font-weight:750;letter-spacing:.04em;transition:background .3s,color .3s;white-space:nowrap}.filter span{margin-left:4px;font-size:9px;opacity:.6}.filter.active{background:#f4e4d8;color:#3b2636}.filter:not(.active):hover{background:#ffffff1c}
.shelf-zone{width:100%;max-width:1700px;min-height:360px;height:min(43vh,420px);position:relative;z-index:2;touch-action:pan-y;perspective:1550px;perspective-origin:50% 54%;outline-offset:-6px;user-select:none;cursor:grab}.shelf-zone.dragging{cursor:grabbing}.shelf-halo{position:absolute;width:min(740px,78vw);height:300px;left:50%;top:50%;transform:translate(-50%,-44%);border-radius:50%;background:radial-gradient(ellipse,#d7b89a45,#9d6f9040 37%,transparent 72%);filter:blur(18px);pointer-events:none}.stage{position:absolute;left:50%;top:49%;width:0;height:0;transform-style:preserve-3d}.book3d{position:absolute;width:0;height:0;top:0;left:0;transform-style:preserve-3d;will-change:transform}.book-face{position:absolute;top:calc(var(--bh) / -2);height:var(--bh);backface-visibility:hidden;transform-style:preserve-3d;border-radius:2px;overflow:hidden;box-shadow:0 3px 10px #0005}.book-face.spine{width:var(--sw);left:calc(var(--sw) / -2);transform:translateZ(calc(var(--cw) / 2));display:flex;align-items:center;justify-content:center;color:#fff3db;border:1px solid #ffffff35;box-shadow:inset -7px 0 9px #0004,1px 0 0 #0008,0 12px 16px #0003;overflow:hidden}.book-face.spine::after{content:'';position:absolute;inset:0;background:linear-gradient(90deg,#0005,transparent 32%,#fff3 59%,#0006);pointer-events:none}.spine.with-art{background:#f9eed8}.spine.with-art img{width:100%;height:100%;object-fit:fill;display:block}.spine-swatch{position:absolute;inset:0;background:var(--spine-bg)}.spine-label{position:relative;writing-mode:vertical-rl;text-orientation:mixed;transform:rotate(180deg);font:600 clamp(10px,.98vw,14px)/1.1 Georgia,serif;text-align:center;letter-spacing:.04em;white-space:nowrap;text-shadow:0 1px 3px #0008}.spine-glyph{position:absolute;top:13px;font-size:17px;color:#ffecd1}.spine-colophon{position:absolute;bottom:15px;writing-mode:vertical-rl;transform:rotate(180deg);font-size:8px;letter-spacing:.13em;color:#ffffffbc}
.book-face.cover{width:var(--cw);left:calc(var(--cw) / -2);transform:rotateY(90deg) translateZ(calc(var(--sw) / 2));background:#f1dec4;box-shadow:3px 12px 29px #08060fbb,0 0 0 1px #513841}.book-face.cover img{width:100%;height:100%;display:block;object-fit:fill}.cover-placeholder{display:flex;flex-direction:column;justify-content:space-between;align-items:center;text-align:center;gap:9px;width:100%;height:100%;padding:12%;background:linear-gradient(135deg,color-mix(in srgb,var(--cover-bg),#fff 16%),var(--cover-bg) 60%,#24172a);color:#fff5e9;border:9px solid #ffffff1d;font-family:Georgia,serif}.cover-placeholder span{font:700 9px/1.4 system-ui,sans-serif;letter-spacing:.18em}.cover-placeholder strong{font:600 clamp(15px,2.4vh,27px)/1.03 Georgia,serif}.cover-placeholder i{font-size:38px;color:#f7e0a8}.book-face.cover::after{content:'';inset:0;position:absolute;pointer-events:none;background:linear-gradient(95deg,#0005,transparent 20%,#fff1 56%,transparent 85%)}
.shelf-ledge{position:absolute;top:calc(49% + min(42vh,415px)*.44);left:6%;right:6%;height:19px;border-radius:70% 70% 20% 20%;background:linear-gradient(180deg,#c5a080,#82617b 22%,#3d2940 66%,#25172e);box-shadow:0 -7px 30px #e4b7ba15,0 17px 35px #0c0815bd;transform:perspective(500px) rotateX(34deg);pointer-events:none}.shelf-underside{position:absolute;top:calc(49% + min(42vh,415px)*.48);left:8%;right:8%;height:48px;border-radius:50%;background:radial-gradient(ellipse at top,#24142888,transparent 75%);pointer-events:none}
.selected-book{text-align:center;min-height:124px;padding:0 20px;z-index:2;margin-top:-5px}.selected-meta{margin:0 0 10px;font-size:10px;font-weight:750;letter-spacing:.17em;color:var(--gold)}.meta-separator{margin:0 9px;font-size:9px;color:var(--blush)}.selected-book h2{font:400 clamp(27px,3vw,42px)/1.04 Georgia,serif;margin:0;letter-spacing:-.03em}.selected-book>p:nth-of-type(2){font-size:13px;color:#e3d2db;margin:9px 0 12px}.selected-actions{display:flex;justify-content:center;align-items:center;gap:10px;min-height:37px}.primary-pill{border:1px solid #e8c69b;background:#f5e5d0;color:#362636;border-radius:100px;font-size:11px;padding:10px 17px;font-weight:800;letter-spacing:.035em;box-shadow:0 6px 22px #1a101b67;transition:transform .2s}.primary-pill:hover{transform:translateY(-2px)}.primary-pill span{margin-left:12px;font-size:15px}.selection-status{color:#e9c1cb;font-size:12px}
.shelf-navigation{width:min(840px,88vw);display:flex;align-items:center;justify-content:space-between;gap:20px;margin:17px auto 0}.nav-arrow{width:45px;height:45px;border-radius:50%;border:1px solid #ebd5c483;background:#ffffff0d;color:#fbe9db;font-size:25px;line-height:1;transition:background .2s,transform .2s}.nav-arrow:hover{background:#ffffff24;transform:translateY(-2px)}.navigation-guide{text-align:center;display:flex;align-items:center;gap:14px;flex-direction:column}.nav-dots{display:flex;gap:6px;align-items:center;justify-content:center}.nav-dots i{display:block;border-radius:50%;width:4px;height:4px;background:#d1bdc18c;transition:width .25s,background .25s}.nav-dots i.active{width:18px;border-radius:12px;background:var(--gold)}.guide-label{font-size:9px;letter-spacing:.19em;color:#cdbacb}.library-footer{color:#c9b7c6;font-family:Georgia,serif;font-size:12px;margin:26px 0 0;letter-spacing:.025em}.library-footer span{color:var(--gold);padding:0 10px}
.gate{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;z-index:30;padding:15px;overflow-y:auto}.gate-backdrop{position:absolute;inset:0;background:#120a20a8;backdrop-filter:blur(6px)}.gate-card{position:relative;width:min(538px,100%);border-radius:22px;padding:clamp(24px,3.2vw,38px) clamp(24px,3.4vw,43px) 24px;background:linear-gradient(155deg,#fff8ef,#f9eddf 70%,#f3e2da);box-shadow:0 28px 95px #0a0615d9,0 0 0 1px #fdf7e5;max-height:calc(100svh - 30px);overflow:auto;text-align:center;color:#322638}.gate-card:before{content:'';position:absolute;inset:8px;border:1px solid #aa866955;border-radius:17px;pointer-events:none}.gate-ornament{color:#bb9268;font-size:20px;margin-bottom:5px}.gate-ornament span{font-size:30px;margin:0 10px;color:#81637c}.gate-eyebrow{color:#916d7e;margin-bottom:13px;font-size:10px}.gate-card h2{font:400 clamp(34px,4.1vw,49px)/1.04 Georgia,serif;letter-spacing:-.04em;margin:0}.gate-card h2 em{font-weight:400;color:#9f7181}.gate-card>p:nth-of-type(2){font-size:13px;color:#6f5b67;line-height:1.55;margin:16px auto 22px;max-width:45ch}.gate-two{display:grid;grid-template-columns:1fr 1fr;gap:12px;text-align:left}.gate-two label{display:block;font-size:11px;font-weight:800;color:#5d4a57;letter-spacing:.02em}.gate-two label>span{color:#aa6e80}.gate-two input{display:block;margin-top:6px;width:100%;height:40px;border:1px solid #d6bfb9;border-radius:10px;background:#fffcf7;padding:0 11px;color:#2d2230;font-size:12px;min-width:0}.gate-two input::placeholder{color:#9a8890}.social-optional{font-size:11px;text-align:left;margin:15px 0;color:#6b5863}.social-optional summary{cursor:pointer;font-weight:750}.social-optional summary span{font-weight:400;color:#98818c}.social-fields{margin-top:10px}.consent-label{display:flex;align-items:flex-start;gap:10px;text-align:left;color:#584954;font-size:11px;line-height:1.35;cursor:pointer;margin:17px 0 17px}.consent-label input{accent-color:#846585;margin:2px 0 0;width:15px;height:15px;flex-shrink:0}.consent-label small{display:block;color:#937f89;margin-top:3px;font-size:10px}.unlock-button{width:100%;border:0;background:#5b3e60;color:#fff7ee;min-height:48px;border-radius:12px;font-size:13px;font-weight:800;letter-spacing:.025em;box-shadow:0 9px 22px #57415b39;transition:background .2s,transform .2s}.unlock-button:hover{background:#78527c;transform:translateY(-1px)}.unlock-button[disabled]{opacity:.6}.unlock-button span{margin-left:10px;color:#f5cf9b}.form-status{margin:8px 0 0;min-height:0;font-size:11px;color:#a02d53}.form-status:empty{display:none}.gate-foot{color:#927b88;font-family:Georgia,serif;font-size:11px;margin:15px 0 0}.gate-foot span{color:#b5838b}
.book-dialog{position:fixed;inset:0;z-index:40;background:radial-gradient(ellipse at 50% 15%,#fff9ef,#f2e5d8 82%);color:#3b2e38;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;padding-bottom:22px}.book-dialog:after{content:'';position:fixed;inset:0;z-index:-1;pointer-events:none;background-image:radial-gradient(#8f75651d .7px,transparent 1px);background-size:7px 7px}.detail-topbar{height:75px;display:flex;align-items:center;justify-content:space-between;gap:15px;border-bottom:1px solid #ab998e4d;padding:0 clamp(20px,5vw,72px)}.detail-close{border:1px solid #bba79b;border-radius:30px;background:transparent;color:#3a2d38;padding:10px 15px;font-size:12px;font-weight:750}.detail-close span{margin-right:10px}.detail-close:hover{background:#f5e3d8}.detail-brand{font:600 20px Georgia,serif;white-space:nowrap}.detail-brand span{color:#986887;margin-left:5px}.detail-category{font-size:10px;font-weight:750;letter-spacing:.17em;color:#87707c}.detail-intro{text-align:center;padding:18px 20px 7px}.detail-overline{margin-bottom:8px;color:#a17886}.detail-intro h2{font:400 clamp(29px,3.1vw,42px) Georgia,serif;margin:0;letter-spacing:-.035em}.detail-intro>p:last-child{margin:8px 0 0;color:#7b6570;font-size:12px}.spread-wrap{width:min(1080px,calc(100vw - 48px));margin:10px auto 0;perspective:1800px}.open-spread{display:grid;grid-template-columns:1fr 1fr;gap:0;border-radius:10px;box-shadow:0 24px 50px #4e363e48;background:#e7d9cb;transform-style:preserve-3d}.spread-page{min-width:0;aspect-ratio:1/1;background:#fff;padding:14px;position:relative;display:flex;align-items:stretch}.spread-page:before{content:'';position:absolute;top:0;bottom:0;width:16px;z-index:2;pointer-events:none}.left-page{border-radius:10px 0 0 10px;transform-origin:100% 50%;box-shadow:inset -18px 0 18px -19px #39232f91}.left-page:before{right:0;background:linear-gradient(90deg,transparent,#3c2c3a30)}.right-page{border-radius:0 10px 10px 0;transform-origin:0 50%;box-shadow:inset 18px 0 19px -20px #39232f91}.right-page:before{left:0;background:linear-gradient(90deg,#3c2c3a30,transparent)}.page-inner{display:flex;width:100%;height:100%;justify-content:center;align-items:center}.page-inner img{width:100%;height:100%;object-fit:contain}.coloring-page-link{position:relative;display:block;width:100%;height:100%;color:#4c3d48;cursor:zoom-in}.coloring-page-link img{width:100%;height:100%;object-fit:contain;display:block}.image-tap-hint{position:absolute;bottom:7px;left:50%;transform:translateX(-50%);white-space:nowrap;background:#4d3654e8;color:#fff8ee;padding:8px 14px;border-radius:50px;font-size:9px;letter-spacing:.05em;font-weight:750;opacity:0;transition:opacity .2s}.coloring-page-link:hover .image-tap-hint,.coloring-page-link:focus-visible .image-tap-hint{opacity:1}.detail-bottom{width:min(1080px,calc(100vw - 48px));display:flex;justify-content:space-between;align-items:center;gap:20px;margin:22px auto 0}.detail-note{display:flex;flex-direction:column;gap:4px;max-width:360px}.detail-note strong{font:400 italic 19px Georgia,serif;color:#74536f}.detail-note span{font-size:12px;line-height:1.5;color:#766772}.detail-buttons{display:flex;gap:10px;align-items:center;flex-wrap:wrap;justify-content:end}.detail-buttons a{display:inline-flex;align-items:center;justify-content:center;gap:12px;text-decoration:none;border-radius:100px;padding:14px 17px;font-size:12px;font-weight:750;white-space:nowrap;transition:transform .2s}.detail-buttons a:hover{transform:translateY(-2px)}.download-btn{background:#5f4564;color:#fffbf5;box-shadow:0 8px 25px #4d35442d}.amazon-btn{border:1px solid #9f8c87;color:#4a3948}.apple-tip{font-size:11px;color:#826c77;text-align:center;margin:18px 15px 0}.toast{position:fixed;left:50%;bottom:25px;transform:translateX(-50%);background:#382b42;color:#fff6e8;border:1px solid #c59f7f;border-radius:100px;max-width:calc(100vw - 30px);padding:12px 18px;font-size:12px;z-index:60;box-shadow:0 8px 24px #0007}
@media(min-width:1400px) and (min-height:960px){.library-content{padding-top:45px}.shelf-zone{height:440px}.selected-book{margin-top:3px}}
@media(max-width:900px){.topbar{height:77px;padding:0 24px}.top-note{display:none}.topbar{grid-template-columns:1fr 1fr}.shelf-zone{height:380px}.shelf-ledge{top:calc(49% + 158px)}.shelf-underside{top:calc(49% + 174px)}.detail-category{display:none}.detail-topbar{height:65px}}
@media(max-width:600px){.shell{min-height:100svh}.topbar{height:64px;padding:0 16px}.wordmark{font-size:22px}.brand-leaf{font-size:15px;margin-right:2px}.back-home{font-size:10px}.brand-moon{margin-left:3px}.library-content{padding:29px 0 24px;min-height:calc(100svh - 64px)}.overline{font-size:9px}.hero-copy h1{font-size:clamp(34px,9vw,45px)}.hero-description{font-size:12px;padding:0 15px}.filter-tabs{margin:22px auto -6px;gap:0;padding:3px;max-width:calc(100vw - 20px)}.filter{font-size:10px;padding:9px 10px}.filter span{font-size:8px}.shelf-zone{height:310px;min-height:310px;perspective:1200px}.shelf-ledge{top:calc(49% + 132px);left:3%;right:3%}.shelf-underside{top:calc(49% + 143px);left:5%;right:5%}.selected-book{margin-top:-8px;min-height:120px}.selected-meta{font-size:9px}.selected-book h2{font-size:29px}.selected-book>p:nth-of-type(2){font-size:12px;max-width:35ch;margin:7px auto 10px}.shelf-navigation{margin:6px auto 0;width:calc(100vw - 38px)}.nav-arrow{width:41px;height:41px}.guide-label{font-size:8px;white-space:nowrap}.library-footer{font-size:11px;margin-top:25px;text-align:center}.gate{padding:9px}.gate-card{border-radius:17px;padding:24px 20px 18px;max-height:calc(100svh - 18px)}.gate-card h2{font-size:36px}.gate-card>p:nth-of-type(2){font-size:12px;margin:10px auto 17px}.gate-two{grid-template-columns:1fr;gap:9px}.gate-two input{height:37px}.social-fields{grid-template-columns:1fr}.gate-ornament{margin-bottom:2px}.gate-eyebrow{font-size:9px;margin-bottom:10px}.consent-label{margin:11px 0}.unlock-button{min-height:43px}.detail-topbar{padding:0 16px}.detail-brand{font-size:17px}.detail-close{font-size:11px;padding:9px 12px}.detail-intro{padding:21px 17px 8px}.detail-intro h2{font-size:31px}.spread-wrap{width:min(540px,calc(100vw - 28px));margin-top:15px}.open-spread{display:flex;flex-direction:column;gap:12px;background:transparent;box-shadow:none}.spread-page{border-radius:7px;box-shadow:0 12px 33px #3e283833;padding:10px}.spread-page:before{display:none}.detail-bottom{flex-direction:column;align-items:stretch;width:calc(100vw - 28px);gap:14px}.detail-buttons{justify-content:stretch;flex-direction:column}.detail-buttons a{width:100%;padding:13px}.detail-note{text-align:center;max-width:none}.image-tap-hint{opacity:1;font-size:8px}.apple-tip{margin:15px auto 2px;max-width:35ch;line-height:1.4}}
@media(max-width:370px){.filter{padding:8px 8px}.hero-copy h1{font-size:32px}.gate-card h2{font-size:31px}.gate-card{padding-left:16px;padding-right:16px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important}}


/* FernMoon Bookshelf v1.0.1 visual refresh */
body{background:#f4eadb;color:#36261f}
.shell{background:linear-gradient(180deg,rgba(255,250,244,.75),rgba(246,237,226,.78) 55%,rgba(240,230,220,.9)),url("./assets/sunlit-reading-room-bg.webp") center center/cover no-repeat}
.shell::before{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;background:linear-gradient(180deg,rgba(255,247,238,.10),rgba(247,237,226,.04) 35%,rgba(246,236,225,.18) 100%)}
.night-sky,.mist{display:none}
.grain{opacity:.1;mix-blend-mode:multiply}
.topbar{border-bottom:1px solid rgba(74,58,42,.14)}
.wordmark,.back-home,.top-note,.hero-copy h1,.selected-book h2{color:#35261e}
.brand-dot{color:#6f4d40}
.brand-leaf,.brand-moon,.top-note span,.overline,.selected-meta,.library-footer span,.meta-separator{color:#b88650}
.hero-copy h1 em{color:#8d5e57}
.hero-description,.selected-book>p:nth-of-type(2),.guide-label,.library-footer,.selected-meta,.selection-status{color:#6a564b}
.filter-tabs{margin:22px auto 18px;padding:5px;background:rgba(255,248,239,.84);border:1px solid rgba(103,76,53,.18);box-shadow:0 8px 28px rgba(102,74,49,.10);backdrop-filter:blur(8px)}
.filter{color:#6f5648}
.filter span{opacity:.7}
.filter.active{background:#36261f;color:#fff6ea}
.filter:not(.active):hover{background:#f2e1ca}
.shelf-zone{height:min(46vh,455px);min-height:385px;perspective-origin:50% 58%;margin-top:4px}
.shelf-halo{width:min(800px,80vw);height:330px;top:58%;transform:translate(-50%,-44%);background:radial-gradient(ellipse,#e3c49d70,#cb9a7260 38%,transparent 74%);filter:blur(22px)}
.stage{top:58%}
.book-face{box-shadow:0 10px 20px rgba(0,0,0,.18)}
.book-face.spine{box-shadow:inset -7px 0 9px #0003,1px 0 0 #0006,0 14px 22px rgba(0,0,0,.18)}
.book-face.cover{box-shadow:4px 16px 34px rgba(8,6,15,.32),0 0 0 1px rgba(81,56,65,.55)}
.shelf-ledge,.shelf-underside{display:none}
.selected-book{margin-top:4px}
.primary-pill{background:#38271f;color:#fff6ea;border-color:#c69a69;box-shadow:0 12px 30px rgba(88,60,38,.20)}
.primary-pill:hover{background:#4a3227}
.shelf-navigation{margin:12px auto 0}
.nav-arrow{border:1px solid rgba(91,70,50,.26);background:rgba(255,249,242,.66);color:#4b362a;box-shadow:0 8px 24px rgba(88,60,38,.12)}
.nav-arrow:hover{background:rgba(255,250,244,.96)}
.nav-dots i{background:#bda793}
.nav-dots i.active{background:#b88650}
.library-footer{color:#7a6457}
@media(max-width:900px){.shelf-zone{height:360px;min-height:360px}.stage{top:57%}}
@media(max-width:600px){.topbar{background:linear-gradient(180deg,rgba(255,248,239,.88),rgba(255,248,239,.62));backdrop-filter:blur(6px)}.hero-description{padding:0 20px}.filter-tabs{margin:18px auto 16px;max-width:calc(100vw - 24px)}.shelf-zone{height:300px;min-height:300px}.stage{top:56%}.selected-book{margin-top:-2px}}


/* FernMoon Bookshelf v1.0.2: let the reading-room artwork breathe. */
.shell {
  background:
    linear-gradient(180deg,
      rgba(255,249,241,.16) 0%,
      rgba(255,250,245,.095) 39%,
      rgba(245,233,216,.045) 100%),
    url('./assets/sunlit-reading-room-bg.webp') center center / cover no-repeat;
}
/* v1.0.1 applied an additional veil over the whole room. Remove it. */
.shell::before { display:none; }
/* Preserve readability without concealing plants, bookshelves or tabletop. */
.hero-copy { text-shadow: 0 1px 14px rgba(255,249,242,.57); }
.topbar { background:linear-gradient(180deg,rgba(255,249,243,.40),rgba(255,249,243,.06)); }
/* The large gold rectangle was a focus outline on this whole stage. */
.shelf-zone:focus-visible { outline:none; }
/* Keep a visible, unobtrusive cue for users who navigate with the keyboard. */
.shelf-zone:focus-visible + .selected-book .selected-meta {
  text-decoration:underline dotted #a67b4e 2px;
  text-underline-offset:7px;
}
/* Leave room above and below the book while allowing a natural page scroll. */
.shelf-zone {
  height:min(43vh,420px);
  min-height:355px;
}
.stage {top:54%;}
.selected-book {margin-top:33px;min-height:152px;}
.selected-meta {margin-bottom:15px;}
.selected-book h2 {margin-bottom:10px;}
.selected-book > p:nth-of-type(2) {margin:0 0 17px;}
.selected-actions {min-height:43px;}
.shelf-navigation {margin-top:18px;}
@media (max-width:900px) {
  .shelf-zone {height:min(42vh,370px);min-height:330px;}
  .stage {top:53%;}
  .selected-book {margin-top:26px;}
}
@media (max-width:600px) {
  .topbar {background:linear-gradient(180deg,rgba(255,249,242,.57),rgba(255,249,242,.25));}
  .shelf-zone {height:310px;min-height:310px;}
  .stage {top:52%;}
  .selected-book {margin-top:18px;min-height:138px;}
  .selected-meta {margin-bottom:11px;}
  .selected-book h2 {margin-bottom:7px;}
  .selected-book > p:nth-of-type(2) {margin:7px auto 13px;}
  .shelf-navigation {margin-top:12px;}
}


/* FernMoon Bookshelf v1.0.3 refinements */
.shelf-zone{outline:none !important;box-shadow:none !important}
.shelf-zone:focus,.shelf-zone:focus-visible{outline:none !important;box-shadow:none !important}
.book-face.back{width:var(--cw);left:calc(var(--cw) / -2);transform:rotateY(-90deg) translateZ(calc(var(--sw) / 2));background:#eadfcd;box-shadow:-3px 12px 29px #08060f66,0 0 0 1px #51384166}
.book-face.back img{width:100%;height:100%;display:block;object-fit:fill}
.back-placeholder{display:flex;flex-direction:column;justify-content:space-between;align-items:center;text-align:center;gap:8px;width:100%;height:100%;padding:12%;background:linear-gradient(135deg,color-mix(in srgb,var(--cover-bg),#fff 25%),color-mix(in srgb,var(--cover-bg),#000 4%) 68%,#eadfcf);color:#fff9ef;border:9px solid #ffffff1a;font-family:Georgia,serif}
.back-placeholder span{font:700 9px/1.4 system-ui,sans-serif;letter-spacing:.18em}
.back-placeholder strong{font:600 clamp(14px,2.2vh,24px)/1.08 Georgia,serif}
.back-placeholder i{font-size:30px;color:#f7e0a8}
.book-face.back::after{content:'';inset:0;position:absolute;pointer-events:none;background:linear-gradient(265deg,#0003,transparent 18%,#fff2 62%,transparent 84%)}
.spine-label{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%) rotate(-90deg);font:600 clamp(9px,.78vw,13px)/1 Georgia,serif;text-align:center;letter-spacing:.02em;white-space:nowrap;text-shadow:0 1px 3px #0008;max-width:calc(var(--bh) - 72px);overflow:hidden;text-overflow:ellipsis;padding:0 2px}
.spine-colophon{position:absolute;bottom:18px;left:50%;transform:translateX(-50%) rotate(-90deg);font-size:7px;letter-spacing:.14em;color:#ffffffbc;white-space:nowrap;transform-origin:center}
.spine-glyph{top:11px;font-size:15px}
.selected-book{margin-top:18px}
.selected-book h2{margin-bottom:10px}
.selected-book>p:nth-of-type(2){margin-top:8px}
.selection-status{margin-top:10px}
.coloring-page-link.disabled{cursor:default}
.coloring-page-link.disabled .image-tap-hint{opacity:1;background:#5b4a45e8;color:#fff8ee}
.detail-buttons a[hidden]{display:none !important}
@media (max-width: 900px){
  .spine-label{font-size:10px;max-width:calc(var(--bh) - 64px)}
}
@media (max-width: 600px){
  .selected-book{margin-top:16px}
  .spine-label{font-size:9px;max-width:calc(var(--bh) - 54px)}
}


/* FernMoon Bookshelf v1.0.4: authentic vertical spine typography */
.book-face.spine .spine-label {
  position:absolute;
  writing-mode:vertical-rl;
  text-orientation:mixed;
  left:50%; top:47%;
  height:auto;
  max-height:calc(var(--bh) - 116px);
  max-width:calc(var(--sw) - 9px);
  white-space:nowrap;
  text-overflow:ellipsis;
  overflow:hidden;
  transform:translate(-50%,-50%) rotate(180deg);
  font-family:Georgia,'Times New Roman',serif;
  font-size:var(--spine-label-size,11px);
  font-weight:600;
  line-height:1.05;
  letter-spacing:.012em;
  padding:0;
  text-align:center;
}
.book-face.spine .spine-colophon {
  position:absolute; bottom:15px;left:50%;top:auto;
  transform:translateX(-50%) rotate(180deg);
  writing-mode:vertical-rl;
  text-orientation:mixed;
  max-height:52px;
  overflow:hidden;
  white-space:nowrap;
  font-size:7px;
  line-height:1;
  letter-spacing:.08em;
}
.book-face.spine .spine-glyph {top:10px;font-size:15px}
/* Published Little FernMoon editions use their real 8.5 x 11 proportions when open. */
.book-dialog[data-size="portrait"] .spread-page {aspect-ratio:8.5/11}
.book-dialog[data-size="portrait"] .spread-wrap {width:min(870px,calc(100vw - 48px))}
.book-dialog[data-size="portrait"] .detail-bottom {width:min(870px,calc(100vw - 48px))}
@media(max-width:600px) {
  .book-face.spine .spine-label {top:46%;max-height:calc(var(--bh) - 92px);max-width:calc(var(--sw) - 7px)}
  .book-face.spine .spine-colophon {bottom:10px;max-height:44px;font-size:6px}
  .book-face.spine .spine-glyph {top:7px;font-size:12px}
  .book-dialog[data-size="portrait"] .spread-wrap {width:min(480px,calc(100vw - 28px))}
  .book-dialog[data-size="portrait"] .detail-bottom {width:calc(100vw - 28px)}
}


/* v1.0.6: Mobile-only discoverability and Photos sharing.
   Intentionally do not modify desktop or tablet styles. */
.mobile-shelf-controls,.mobile-guide-label,.mobile-save-photo {display:none}
@media(max-width:600px) {
  .mobile-shelf-controls {
    position:absolute;
    inset:0;
    z-index:12;
    display:block;
    pointer-events:none;
    perspective:none;
  }
  .mobile-shelf-arrow {
    position:absolute;
    top:52%;
    transform:translateY(-50%);
    width:44px;
    height:52px;
    border-radius:50%;
    border:1px solid rgba(115,84,62,.32);
    background:rgba(255,249,240,.86);
    color:#463022;
    box-shadow:0 4px 19px rgba(45,31,27,.16), inset 0 1px rgba(255,255,255,.85);
    backdrop-filter:blur(5px);
    -webkit-backdrop-filter:blur(5px);
    pointer-events:auto;
    display:flex;
    justify-content:center;
    align-items:center;
    padding:0 0 4px;
    font:400 33px/1 Georgia,serif;
    touch-action:manipulation;
    -webkit-tap-highlight-color:transparent;
    transition:background-color .2s ease,box-shadow .2s ease,transform .2s ease;
  }
  .mobile-prev {left:max(4px, env(safe-area-inset-left))}
  .mobile-next {right:max(4px, env(safe-area-inset-right))}
  .mobile-shelf-arrow:active {
    background:#fff9ee;
    transform:translateY(-50%) scale(.94);
    box-shadow:0 2px 9px rgba(45,31,27,.2);
  }
  .mobile-shelf-arrow:focus-visible {
    outline:2px solid #816244;
    outline-offset:2px;
  }
  .shelf-navigation {justify-content:center; width:min(100%,calc(100vw - 36px));}
  /* Original nav remains in DOM for desktop/tablet; keep only the dots on phones. */
  .shelf-navigation > .nav-arrow {display:none}
  .navigation-guide {gap:8px;}
  .navigation-guide .guide-label {display:none}
  .mobile-guide-label {
    display:block;
    order:-1;
    color:#614537;
    font:italic 14px/1.25 Georgia,'Times New Roman',serif;
    letter-spacing:.01em;
    text-shadow:0 1px 8px rgba(255,251,242,.85);
    opacity:1;
    transition:opacity .3s ease;
  }
  .shell.mobile-has-browsed .mobile-guide-label {opacity:0}
  .shell.mobile-intro-playing .mobile-shelf-arrow {
    animation:fm-mobile-arrow-greeting 1.1s ease-in-out 1 both;
  }
  @keyframes fm-mobile-arrow-greeting {
    0%,100% {box-shadow:0 4px 19px rgba(45,31,27,.16),inset 0 1px #fff9}
    45% {box-shadow:0 4px 22px rgba(123,84,53,.38),0 0 0 3px rgba(255,250,235,.75)}
  }
  /* Only on phones: a second, native-sharing option. Existing PNG and Amazon links stay. */
  .detail-buttons .mobile-save-photo:not([hidden]) {
    display:inline-flex;
    width:100%;
    align-items:center;
    justify-content:center;
    gap:12px;
    padding:13px 17px;
    border:1px solid #866681;
    border-radius:100px;
    color:#513951;
    background:#fff9f1;
    font-size:12px;
    font-weight:750;
    box-shadow:0 4px 16px rgba(66,38,55,.10);
    touch-action:manipulation;
  }
  .detail-buttons .mobile-save-photo:active{background:#f9e8f2}
  .apple-tip {max-width:44ch}
}
@media(max-width:600px) and (prefers-reduced-motion:reduce) {
  .shell.mobile-intro-playing .mobile-shelf-arrow {animation:none}
  .mobile-guide-label {transition:none}
}

/* v1.0.8: Prevent iOS/WebKit input-focus zoom from persisting into the shelf.
   Leave desktop typography and user pinch-to-zoom accessibility intact. */
@media (max-width:900px), (pointer:coarse) {
  .gate-two input { font-size:16px; }
}

/* v1.0.9: Keep the book-opening action visible right beneath the shelf on phones.
   Mobile-only visual reorder, no overlay, original desktop flow retained. */
@media (max-width:600px) {
  .selected-book {
    display:flex;
    flex-direction:column;
    align-items:center;
  }
  .selected-actions {
    order:-1;
    margin:0 auto 17px;
    width:100%;
  }
  .selected-meta { order:0; }
  .selected-book h2 { order:0; }
  .selected-book > p:nth-of-type(2) { order:0; }
}

/* v1.1.0: concise, always-visible signup email disclosure, replacing optional checkbox. */
.signup-email-notice {
  margin:12px auto 0;
  max-width:46ch;
  text-align:center;
  color:#77616f;
  font-size:12px;
  line-height:1.45;
}
@media (max-width:600px) {
  .signup-email-notice { margin:10px auto 0; font-size:12px; }
}
