.library .hero .welcome{display:block;position:relative;isolation:isolate;padding-bottom:7px}
[data-painted] .library .welcome::before{content:"";position:absolute;inset:-5px -9px;z-index:-1;border-radius:12px;background:var(--wash-light);box-shadow:0 0 10px 4px var(--wash-light);pointer-events:none}
.library .welcome h1{position:absolute;left:0;bottom:calc(100% + var(--friend-title-lift,20px));margin:0;white-space:nowrap;text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:.17em;font-size:clamp(28px,3.6vw,40px)}
.library .welcome .narrators{align-items:flex-end;gap:16px;flex-wrap:nowrap}
.library .welcome .narrator-section{margin:0}
html{-webkit-touch-callout:none}
body{-webkit-user-select:none;user-select:none}
input,textarea,[contenteditable=true]{-webkit-user-select:text;user-select:text;-webkit-touch-callout:default}
img,a{-webkit-user-drag:none}
@media(hover:hover){button:hover{filter:drop-shadow(0 0 5px #ffe59a99)}}

.friend-door{display:block;width:92px;height:96px;margin:0 auto 4px;perspective:400px}
.friend-door .door-leaf{width:100%;height:100%;object-fit:contain;transform-origin:25% 50%;transition:transform .45s ease,filter .2s ease}
.door-opening .door-leaf{transform:rotateY(-72deg);filter:brightness(.75)}
[data-meet]:hover .door-leaf{filter:drop-shadow(0 0 5px #fff0ab)}
@media(hover:hover) and (pointer:fine){
 html,body,body *{cursor:var(--room-cursor),auto!important}
 button:hover,button:hover *,a:hover,a:hover *,summary:hover{cursor:var(--room-cursor-hover),pointer!important}
 [data-meet]:hover,[data-meet]:hover *{cursor:url('/room-accessories/knock-cursor-hover.png') 12 10,pointer!important}
 input,textarea,[contenteditable=true]{cursor:text!important}
}
@media(prefers-reduced-motion:reduce){.friend-door .door-leaf{transition:none}}

/* The upper room uses banner edges; the lower shelf geometry is untouched. */
@media(min-width:901px){
 [data-full-room] .library .hero{position:relative;flex:1 1 0;min-height:0}
 [data-full-room] .library .hero>.welcome{position:absolute;translate:none;left:calc(var(--banner-left,4vw) + 9px);top:var(--friends-top,12px);height:var(--friends-height,240px);width:calc(44.4% - var(--banner-left,4vw) - 30px);padding:0 4px 4px;display:flex;flex-direction:column}
 [data-painted] .library .welcome::before{inset:0 -9px}
 .library .welcome h1{position:static;font-size:34px;line-height:1.15;letter-spacing:-1.2px;text-align:center;margin:8px -4px 10px;white-space:nowrap}
 .library .welcome .narrator-section{flex:1;min-height:0}
 .library .welcome .narrators{display:grid;grid-template-columns:132px repeat(3,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));gap:6px;height:100%;align-items:center}
 .library .welcome [data-meet]{grid-column:1;grid-row:1 / 3;align-self:stretch;display:flex;flex-direction:column;justify-content:end;min-height:0;font-size:13px}
 .library .welcome [data-person]{font-size:14px;min-width:0}
 .library .welcome [data-person] .portrait{width:100%;max-width:68px;margin:auto;aspect-ratio:1}
 .friend-door{width:100%;height:100%;min-height:0;margin:0 auto 3px}
 [data-full-room] .library .hero>.feature{position:absolute;translate:none;left:44.4%;right:calc(var(--banner-right,4vw) + 9px);top:var(--friends-top,12px);height:var(--friends-height,240px);display:grid;grid-template-columns:minmax(0,1fr) 218.4px;align-items:center;gap:14px;padding:0}
 [data-full-room] .library .feature-copy{align-self:center;padding:0;width:218.4px;max-width:none}
 [data-full-room] .library #featured-cover{align-self:center;translate:none;width:100%;max-width:none;margin:0}
}
#directory-list img{display:block;object-fit:cover;object-position:center top;margin:0 auto;background:#e7dfcc;aspect-ratio:1}
#directory-list h3{text-align:center}
@media(min-width:901px){[data-full-room] .library .hero>.feature{width:auto;min-width:0}}

#book-front-matter{display:grid;grid-template-columns:1fr 1fr;width:100%;height:100%;min-height:300px;background:#fff9ec;border-radius:8px;box-shadow:0 10px 35px #49321633;overflow:hidden;transform-origin:left center}
#book-front-matter section{padding:22px;overflow:auto;min-width:0;display:flex;flex-direction:column;justify-content:center}
.blurb-page{border-right:1px solid #d5c8aa;background:linear-gradient(90deg,#fff9ec 96%,#e7dbc3)}
.blurb-page small{font:700 19px Georgia;color:#49664e}
.blurb-page p{font:24px/1.5 Georgia;margin:16px 0}
.narrator-page{align-items:center;text-align:center}
.narrator-page img{width:110px;height:110px;object-fit:cover;object-position:center top;border-radius:50%;background:#e7dfcc}
.narrator-page h3{font:700 24px Georgia;margin:10px 0}
.narrator-page p{font:16px/1.4 Georgia;margin:0 0 12px}
#listen-introduction{background:#244c3d;color:#fff8e8;border-radius:24px;min-height:44px;padding:10px 18px}
@media(max-width:600px){#book-front-matter{grid-template-columns:1fr;max-height:65dvh;overflow:auto}#book-front-matter section{overflow:visible}.blurb-page p{font-size:20px}}
#reader .opening-cover{translate:-50% -50%}
.opening-cover.cover-paused .cover-inside{display:none}
.opening-cover.cover-paused .cover-front{backface-visibility:visible;-webkit-backface-visibility:visible}
.narrator-page img{width:150px;height:150px;flex:none}
#reader .opening-cover{z-index:3;pointer-events:auto}
#reader-stage:has(.cover-paused:not([hidden])) #book-front-matter{pointer-events:none}
.cover-inside{padding:24px;display:flex;align-items:center;background:#fff9ec}
.cover-inside p{font:20px/1.5 Georgia;color:var(--ink)}
@media(min-width:901px){[data-full-room] .library .feature-copy{padding-bottom:6px}}
