/* Painted paper system. Presentation only: game state, hit areas and book art stay intact. */
.mb-home.family-home{--paper:#faf5e9;--white:#fffdf6;--ink:#493f32;--muted:#685f50;--orange:#9d4937;--pale:#ecebdc;--line:#cfc4ad;--radius:24px;background-color:var(--paper);background-image:url('../painted/paper.svg');color:var(--ink)}
.mb-home.family-home .wrap{width:min(1160px,calc(100% - 64px))}
.mb-home.family-home .header{padding-block:24px;border-bottom:2px dashed #cfc4ad;gap:24px}
.mb-home.family-home .brandname{color:#695b42;letter-spacing:.1em}
.mb-home.family-home .nav{gap:20px;flex-wrap:wrap}
.mb-home.family-home .nav a{padding-block:10px}
.mb-home.family-home .btn{border:2px solid #817256;border-radius:18px 23px 17px 22px;min-height:52px;max-width:100%;white-space:normal;overflow-wrap:anywhere;padding:14px 22px;gap:12px;font-size:16px;line-height:1.7;box-shadow:0 3px 0 #b9a88b33}
.mb-home.family-home .btn.primary{background:#65704b;color:#fffdf6;border-color:#65704b;background-image:url('../painted/paper.svg')}
.mb-home.family-home .btn.primary:hover{background-color:#505b39}
.mb-home.family-home .btn.light{background:#fffdf6;background-image:url('../painted/paper.svg')}
.mb-home.family-home .btn.light:hover{background-color:#eee9d9}
.mb-home.family-home .btn.orange{background:#9d4937;border-color:#9d4937}
.mb-home.family-home .actions,.mb-home.family-home .parent-actions{display:flex;flex-wrap:wrap;align-items:stretch;gap:16px}
.mb-home.family-home .parent-actions{margin:28px 0 36px}
.mb-home.family-home .parent-actions .btn{margin:0;text-align:left;justify-content:space-between;flex:0 1 auto}
.mb-home.family-home .family-hero{grid-template-columns:minmax(0,.85fr) minmax(0,1.2fr);gap:36px;padding:48px 0 40px;align-items:center}
.mb-home.family-home .family-hero h1{font-size:clamp(38px,4.7vw,64px);line-height:1.5;letter-spacing:.06em;color:#544833}
.mb-home.family-home .family-hero h1 em{color:#9d4937}
.mb-home .painted-hero{margin:0;min-width:0}
.mb-home .painted-hero img{display:block;width:100%;height:auto;border-radius:42% 46% 27% 31% / 17% 21% 15% 19%;mix-blend-mode:multiply}
.mb-home.family-home .section{padding-bottom:72px}
.mb-home.family-home .home-quick-start{padding-top:24px}
.mb-home.family-home .home-quick-grid{gap:20px;margin-top:28px}
.mb-home.family-home .home-quick-card{background:var(--white);border:2px solid #d4c9b3;border-radius:26px 21px 28px 20px;padding:14px 14px 20px;box-shadow:0 5px 0 #b9a88b20}
.mb-home.family-home .home-quick-picture{display:block;width:100%;height:auto;aspect-ratio:1;object-fit:contain;border-radius:18px;mix-blend-mode:multiply}
.mb-home.family-home .home-quick-label{display:block;margin-top:12px;color:#57482f}
.mb-home.family-home .family-door-grid{gap:24px}
.mb-home.family-home .family-door,.mb-home.family-home .library-card,.mb-home.family-home .library-theme,.mb-home.family-home .parent-guide-card{background-color:var(--white);background-image:url('../painted/paper.svg');border:1px solid #cfc4ad;border-radius:23px 29px 20px 26px;box-shadow:0 5px 0 #b9a88b1c}
.mb-home.family-home .family-door{padding:32px;display:flex;flex-direction:column;align-items:flex-start}
.mb-home.family-home .family-door .btn{margin-top:auto}
.mb-home.family-home .family-door p{margin-bottom:24px}
.mb-home.family-home .family-door .door-symbol{color:#9d4937}
.mb-home.family-home .library-card-copy{gap:12px}
.mb-home.family-home .library-card-copy>p{margin:0 0 12px}
.mb-home.family-home .library-card-copy>.btn{margin-top:auto}
.mb-home.family-home .grownups{margin-top:24px;padding-top:36px;border-top:2px dashed #cfc4ad}
.mb-home.family-home .grownups>.eyebrow{margin-bottom:16px}
.mb-home.family-home .parent-lead{margin:20px 0 0}
.mb-home.family-home .parent-notes{display:grid;gap:28px}
.mb-home.family-home .parent-notes h3{margin:0 0 12px}
.mb-home.family-home .parent-notes p{margin:0;line-height:2}
.mb-home.family-home .operator-details{margin-top:32px}
.mb-home.family-home .legacy-links{margin-bottom:36px}
.mb-home.family-home .contact{background:#eae9d9;background-image:url('../painted/paper.svg');border:1px solid #cfc4ad;border-radius:32px 24px 29px 22px;padding:44px;margin-bottom:48px}
.mb-home.family-home .contact>p{margin:24px 0;line-height:2}
.mb-home.family-home .family-return{gap:20px}
.mb-home.family-home .footer{border-top:2px dashed #cfc4ad;padding-top:28px;gap:24px}
.mb-home.family-home .play-card,.mb-home.family-home .game-card{background-color:var(--white);background-image:url('../painted/paper.svg');border-color:#cfc4ad}
/* Paper texture is a local non-interactive background, never an overlay over controls. */
.mb-home.family-home .shape-game,.mb-home.family-home .balloon-game,.mb-home.family-home .tap-scene,.mb-home.family-home .play-stage{background-image:url('../painted/paper.svg');border-color:#cfc4ad}
.mb-home.family-home :is(a,button,summary,input):focus-visible{outline:3px solid #315c85;outline-offset:5px}
@media(max-width:900px){.mb-home.family-home .family-hero{gap:24px}.mb-home.family-home .nav{gap:12px}.mb-home.family-home .family-door{padding:24px}}
@media(max-width:760px){
 .mb-home.family-home .wrap{width:calc(100% - 36px)}
 .mb-home.family-home .header{padding-block:18px;gap:14px}
 .mb-home.family-home .family-hero{grid-template-columns:minmax(0,1fr);padding:32px 0 20px;gap:24px}
 .mb-home.family-home .family-hero h1{font-size:38px;line-height:1.45;margin-bottom:20px}
 .mb-home.family-home .family-hero .actions{margin-top:0;gap:14px}
 .mb-home .painted-hero{max-width:540px;width:100%;margin-inline:auto}
 .mb-home.family-home .section{padding-bottom:48px}
 .mb-home.family-home .home-quick-grid{gap:16px}
 .mb-home.family-home .home-quick-card{padding:10px 10px 16px}
 .mb-home.family-home .parent-actions{flex-direction:column;gap:18px;margin-block:24px 32px}
 .mb-home.family-home .parent-actions .btn{width:100%;padding:16px 18px}
 .mb-home.family-home .grownups{padding-top:28px}
 .mb-home.family-home .contact{margin-inline:0;padding:28px 20px;border-radius:24px}
 .mb-home.family-home .library-grid{gap:28px}
 .mb-home.family-home .family-guide-grid{gap:28px}
}
@media(max-width:380px){.mb-home.family-home .family-hero .actions{flex-direction:column}.mb-home.family-home .contact{margin-inline:-14px;padding-inline:2px}.mb-home.family-home .contact>h2,.mb-home.family-home .contact>p{padding-inline:12px}}

/* A quiet paper theatre on the homepage. All content is visible without JS. */
.mb-home [data-paper-scene]{position:relative;isolation:isolate;margin-bottom:60px}
.mb-home [data-paper-scene]>img{transform:translateY(var(--paper-scroll,0px));transition:none}
.mb-home .paper-cloud{position:absolute;pointer-events:none;z-index:-1;background:#eee8d6;border-radius:61% 39% 58% 42% / 58% 47% 53% 42%;width:34%;height:29%;top:4%;left:-3%;transform:translateY(calc(var(--paper-scroll,0px) * -1)) rotate(-9deg);background-image:url('../painted/paper.svg')}
/* Inset the rotated cloud so it never adds a horizontal page scrollbar. */
.mb-home .paper-cloud--two{width:39%;height:30%;top:66%;left:56%;background-color:#dfe3cf;transform:translateY(var(--paper-scroll,0px)) rotate(13deg)}
.mb-home .paper-revealed{animation:paper-arrive .65s ease-out both}
@keyframes paper-arrive{from{transform:translateY(14px)}to{transform:translateY(0)}}
@media(max-width:760px){.mb-home [data-paper-scene]{margin:8px 8px 0}}
@media(prefers-reduced-motion:reduce){.mb-home [data-paper-scene]>img,.mb-home .paper-cloud{transform:none}.mb-home .paper-revealed{animation:none}}
/* Mobile decorations follow the artwork, not the taller interaction area. */
@media(max-width:760px){.mb-home .paper-cloud{width:28%;height:48px;left:8px;top:4%}.mb-home .paper-cloud--two{left:auto;right:8px;top:32%}}


/* Keep navigation reachable while browsing the long book catalogue. */
.mb-home.family-home[data-family-kind="books"] .header{position:sticky;top:0;z-index:8;background:var(--paper);background-image:url('../painted/paper.svg');padding-block:12px;box-shadow:0 5px 8px #493f3210;max-height:80vh;overflow-y:auto}
.mb-home[data-family-kind="books"] #main-content,.mb-home[data-family-kind="books"] [id]{scroll-margin-top:140px}
@media(prefers-reduced-motion:reduce){.mb-home[data-family-kind="books"]{scroll-behavior:auto}}
