/* Catalogue page (books.php) art direction. Loaded after the shared storefront styles. */
.store-catalogue{--muted:#4b6259}
.store-catalogue .store-wrap{width:min(1320px,calc(100% - 80px))}

.store-catalogue .store-footer .store-logo img{width:170px;height:auto}

/* Banner */
.catalogue-hero{position:relative;overflow:hidden;background:radial-gradient(circle at 1px 1px,#17604a14 1px,transparent 1.6px) 0 0/26px 26px,radial-gradient(50% 120% at 85% 30%,#ffe9a8 0,#fff3cf 40%,transparent 72%),radial-gradient(45% 120% at 0 0,#d9f0e3 0,transparent 70%),#fbf6e9;border-bottom:1px solid #ece4cd}
.catalogue-hero-inner{display:grid;grid-template-columns:minmax(0,1fr) 420px;gap:40px;align-items:center;min-height:280px;padding-block:40px}
.store-catalogue .catalogue-intro{display:block;padding:0}
.catalogue-kicker{display:inline-flex;align-items:center;gap:8px;margin:0 0 16px!important;padding:6px 14px 6px 10px;font-size:13px;font-weight:700;color:var(--green);background:#fffdf6;border:1px solid #e4dcc2;border-radius:100px}
.catalogue-kicker svg{width:17px;height:17px;color:#c18a22;fill:#ffd667;stroke-width:1.3}
.store-catalogue .catalogue-intro h1{font-size:clamp(38px,4vw,56px);font-weight:600;line-height:1.05;letter-spacing:-.03em;color:#183a31;text-wrap:balance}
.store-catalogue .catalogue-intro>p:not(.catalogue-kicker){max-width:600px;margin:14px 0 0;font-size:17px;line-height:1.6;color:#3d594f;text-wrap:pretty}
.catalogue-perks{display:flex;flex-wrap:wrap;gap:8px 22px;list-style:none;margin:20px 0 0;padding:0;font-size:14px;font-weight:600;color:#4b6259}
.catalogue-perks li{display:flex;align-items:center;gap:7px}
.catalogue-perks svg{width:18px;height:18px;padding:3px;border-radius:50%;background:#d7efe2;color:var(--green);stroke-width:2.6}
.catalogue-hero-art{position:relative;height:230px}
.catalogue-hero-art img{position:absolute;top:50%;width:170px;aspect-ratio:1;object-fit:cover;border-radius:4px 10px 10px 4px;box-shadow:inset 0 0 0 1px #0000000f,3px 3px 0 #f6efdc,5px 5px 0 #d8ccb0,10px 18px 28px #1d3a2c40}
.catalogue-hero-art img:nth-child(1){left:6%;transform:translateY(-50%) rotate(-10deg) scale(.9)}
.catalogue-hero-art img:nth-child(2){left:31%;z-index:2;transform:translateY(-54%) rotate(1deg)}
.catalogue-hero-art img:nth-child(3){right:2%;transform:translateY(-46%) rotate(9deg) scale(.9)}
.catalogue-hero-spark{position:absolute;right:30%;top:0;z-index:3;width:30px;height:30px;color:#c18a22}
.catalogue-hero-spark svg{width:100%;height:100%;fill:#ffd667;stroke-width:1.1}

/* Filters */
.store-catalogue .catalogue-main{padding-top:28px;padding-bottom:72px}
.store-catalogue .catalogue-filters{margin-top:-58px;position:relative;z-index:2;padding:18px 22px 6px;background:#fff;border:1px solid #e9e3d0;border-radius:24px;box-shadow:0 16px 36px #3e4a2a14;scroll-margin-top:100px}
.store-catalogue .filter-main{display:flex;align-items:center;gap:14px}
.store-catalogue .search-field{flex:1;max-width:none;height:52px;min-height:52px;padding:0 18px;border:1px solid #d4e2d8;border-radius:14px;background:#fbfdfb;transition:border-color .2s,box-shadow .2s}
.store-catalogue .search-field:focus-within{border-color:var(--green);box-shadow:0 0 0 4px #176d541a}
.store-catalogue .search-field input{font-size:16px}
.store-catalogue .sort-field{flex:none;height:52px;gap:6px;padding:0 6px 0 16px;border:1px solid #d4e2d8;border-radius:14px;background:#fbfdfb;font-size:13px;font-weight:600;color:var(--muted)}
.store-catalogue .sort-field select{max-width:none;min-height:48px;padding-right:6px;font-size:14px;font-weight:700;color:var(--ink)}
.store-catalogue .filter-chip-line{display:flex;align-items:center;gap:12px;margin-top:14px}
.store-catalogue .filter-chip-line>span{flex:0 0 64px;font-size:12px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:#8a7a52}
.store-catalogue .filter-chips{gap:8px;padding:3px 2px}
.store-catalogue .filter-chips a{min-height:38px;padding:8px 15px;font-size:14px;font-weight:600;border:1px solid #dbe5dd;background:#fff;color:var(--ink);transition:background .2s,border-color .2s,color .2s}
.store-catalogue .filter-chips a:hover{border-color:#9fc0ac;background:#f1f8f3}
.store-catalogue .filter-chips a[aria-current=true]{background:var(--green);border-color:var(--green);color:#fff}
.store-catalogue .theme-chips{-webkit-mask-image:linear-gradient(90deg,#000 calc(100% - 48px),transparent);mask-image:linear-gradient(90deg,#000 calc(100% - 48px),transparent);padding-right:40px}
.store-catalogue .theme-next{width:38px;height:38px;border-color:#dbe5dd;transition:background .2s}
.store-catalogue .theme-next:hover{background:#f1f8f3}
.store-catalogue .theme-next svg{width:18px;height:18px}
.store-catalogue .catalogue-results{display:flex;align-items:center;gap:16px;min-height:0;margin:14px -22px 0;padding:12px 22px;border-top:1px solid #efe9d8}
.store-catalogue .catalogue-results p{font-size:14px;font-weight:700;color:var(--ink)}
.store-catalogue .catalogue-results .clear-filters{font-size:14px;font-weight:700;color:var(--green);text-decoration:underline;text-underline-offset:4px}
.results-note{margin-left:auto;font-size:13px;color:#6a7f75}

/* Grid */
.store-catalogue .catalogue-empty{margin:28px 0 0}
.store-catalogue .catalogue-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:40px 26px;margin-top:32px}
.store-catalogue .book-card .book-art{padding:16px;border-radius:22px;transition:background .25s}
.store-catalogue .book-card .book-info{padding-top:16px}
.store-catalogue .catalogue-grid .book-info h3{font-size:19px;line-height:1.3;color:#183a31}
.store-catalogue .book-card .book-meta{margin:6px 0 10px!important;font-size:14px;color:#5b6d63}
.store-catalogue .book-card .book-choose{margin-top:auto;font-size:14px;gap:7px}
.store-catalogue .see-inside{bottom:24px;right:24px;width:38px;height:38px;border:0;background:#fffdf6f2;box-shadow:0 3px 10px #152c3326;transition:transform .2s,background .2s}
.store-catalogue .see-inside:hover{transform:scale(1.08);background:#fff}
.store-catalogue .see-inside svg{width:18px;height:18px;color:var(--green)}

/* Load more + formats */
.store-catalogue .catalogue-more{display:flex;flex-direction:column;align-items:center;gap:12px;margin-top:44px}
.store-catalogue .catalogue-more[hidden]{display:none}
.store-catalogue .catalogue-more p{font-size:13px;font-weight:600;color:#6a7f75}
.store-catalogue .catalogue-more .button{min-height:52px;padding:12px 28px;font-size:15px;gap:14px}
.store-catalogue .catalogue-offer{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:36px;align-items:center;margin-top:64px;padding:36px 40px;text-align:left;background:radial-gradient(60% 140% at 100% 0,#fff1c4 0,transparent 70%),#f1f7f0;border:1px solid #dfe9dc;border-radius:28px}
.store-catalogue .catalogue-offer .eyebrow{margin-bottom:10px!important;font-size:12px}
.store-catalogue .catalogue-offer .eyebrow svg{width:20px;height:20px;color:#a16c24}
.store-catalogue .catalogue-offer h2{font-size:clamp(26px,2.4vw,34px);line-height:1.15;max-width:460px}
.store-catalogue .catalogue-offer-copy>p:not(.eyebrow){margin:10px 0 6px;max-width:460px;font-size:15px;color:var(--muted)}
.store-catalogue .catalogue-offer .text-link{font-size:14px;color:var(--green)}
.catalogue-formats{display:grid;grid-template-columns:repeat(3,152px);gap:14px;list-style:none;margin:0;padding:0}
.catalogue-formats li{display:flex;flex-direction:column;align-items:center;padding:12px 12px 16px;background:#fff;border:1px solid #e6e0cc;border-radius:20px;text-align:center}
.catalogue-formats img{width:100%;aspect-ratio:1;object-fit:contain;border-radius:12px}
.catalogue-formats span{margin-top:8px;font-family:Fredoka,sans-serif;font-size:17px;font-weight:500;color:#183a31}
.catalogue-formats strong{font-size:16px;color:var(--green)}
.catalogue-formats small{font-size:11px;font-weight:600;color:#6a7f75}

@media(min-width:761px) and (max-width:1100px){
 .store-catalogue .store-wrap{width:calc(100% - 48px)}
 .catalogue-hero-inner{grid-template-columns:minmax(0,1fr) 300px;gap:24px}
 .catalogue-hero-art{height:190px}.catalogue-hero-art img{width:128px}
 .store-catalogue .catalogue-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
 .store-catalogue .catalogue-offer{grid-template-columns:1fr;padding:30px}
 .catalogue-formats{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:760px){
 .store-catalogue .store-wrap{width:calc(100% - 32px)}
 .store-catalogue .store-footer .store-logo img{width:144px}
 .catalogue-hero-inner{display:block;min-height:0;padding-block:24px 74px}
 .catalogue-hero-art{display:none}
 .catalogue-kicker{font-size:12px;margin-bottom:12px!important}
 .store-catalogue .catalogue-intro h1{font-size:clamp(30px,8.4vw,40px)}
 .store-catalogue .catalogue-intro>p:not(.catalogue-kicker){font-size:15px;margin-top:10px}
 .catalogue-perks{gap:6px 14px;margin-top:14px;font-size:12.5px}.catalogue-perks svg{width:16px;height:16px}
 .store-catalogue .catalogue-main{padding-top:0;padding-bottom:48px}
 .store-catalogue .catalogue-filters{margin-top:-52px;padding:12px 12px 4px;border-radius:20px;scroll-margin-top:80px}
 .store-catalogue .filter-main{gap:8px}
 .store-catalogue .search-field{height:46px;min-height:46px;padding:0 13px;gap:9px}
 .store-catalogue .search-field input{font-size:15px}
 .store-catalogue .sort-field{height:46px;padding:0 2px 0 10px}.store-catalogue .sort-field span{display:none}
 .store-catalogue .sort-field select{min-height:42px;font-size:13px;max-width:118px}
 .store-catalogue .filter-chip-line{gap:8px;margin-top:10px}
 .store-catalogue .filter-chip-line>span{flex-basis:46px;font-size:10.5px}
 .store-catalogue .filter-chips a{min-height:36px;padding:7px 12px;font-size:13px}
 .store-catalogue .theme-chips{padding-right:24px;-webkit-mask-image:linear-gradient(90deg,#000 calc(100% - 32px),transparent);mask-image:linear-gradient(90deg,#000 calc(100% - 32px),transparent)}
 .store-catalogue .catalogue-results{margin:10px -12px 0;padding:10px 12px;gap:12px}
 .store-catalogue .catalogue-results p,.store-catalogue .catalogue-results .clear-filters{font-size:13px}
 .results-note{font-size:12px}

 .store-catalogue .catalogue-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px 14px;margin-top:24px}
 .store-catalogue .book-card .book-art{padding:10px;border-radius:18px}
 .store-catalogue .catalogue-grid .book-info h3{font-size:16px}
 .store-catalogue .book-card .book-meta{font-size:12.5px;margin:4px 0 8px!important;white-space:normal}
 .store-catalogue .book-card .book-choose{font-size:13px}
 .store-catalogue .see-inside{bottom:16px;right:16px;width:34px;height:34px}
 .store-catalogue .catalogue-offer{grid-template-columns:1fr;gap:22px;margin-top:44px;padding:24px 18px;border-radius:22px}
 .catalogue-formats{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
 .catalogue-formats li{padding:8px 6px 12px;border-radius:16px}
 .catalogue-formats span{font-size:15px}.catalogue-formats strong{font-size:14px}
}
@media(max-width:360px){
 .catalogue-perks li:last-child{display:none}
 .store-catalogue .catalogue-grid .book-info h3{font-size:15px}
}

/* Second polish pass: icons, motion and a tighter mobile filter card. */
.store-catalogue .filter-chip-line>span{display:flex;align-items:center;gap:7px;flex-basis:84px}
.store-catalogue .filter-chip-line>span svg{width:17px;height:17px;flex:none;color:#c18a22}
.store-catalogue .sort-field>svg{width:16px;height:16px;color:var(--green)}
.store-catalogue .filter-chips a{transition:background .2s,border-color .2s,color .2s,transform .2s}
.store-catalogue .filter-chips a:hover{transform:translateY(-1px)}
.results-icon{display:grid;place-items:center;width:30px;height:30px;flex:none;border-radius:10px;background:#e3f3e9;color:var(--green)}
.results-icon svg{width:17px;height:17px}
.store-catalogue .catalogue-results{gap:10px;justify-content:flex-start}
.store-catalogue .catalogue-results .clear-filters{margin-left:6px}
.store-catalogue .catalogue-empty{display:flex;align-items:flex-start;gap:16px;padding:22px 24px;border:1px solid #f0e2b4;border-radius:20px;background:#fff6dc}
.store-catalogue .catalogue-empty[hidden]{display:none}
.empty-icon{display:grid;place-items:center;width:46px;height:46px;flex:none;border-radius:50%;background:#fff;color:#a16c24;box-shadow:0 3px 10px #6d5a2014}
.empty-icon svg{width:22px;height:22px}
.store-catalogue .catalogue-empty h2{font-size:22px}
.catalogue-formats li{transition:transform .3s cubic-bezier(.2,.8,.25,1),box-shadow .3s}
.catalogue-formats li:hover{transform:translateY(-5px);box-shadow:0 14px 26px #3e4a2a17}
@keyframes catalogue-fan{from{opacity:0;translate:0 26px}}
@keyframes catalogue-card{from{opacity:0;translate:0 14px}}
@media(prefers-reduced-motion:no-preference){
 .catalogue-hero-art img{animation:catalogue-fan .8s cubic-bezier(.2,.8,.25,1.1) both,store-float 6s 1.2s ease-in-out infinite;transition:transform .5s cubic-bezier(.2,.8,.25,1)}
 .catalogue-hero-art img:nth-child(1){animation-delay:.1s,1.4s}
 .catalogue-hero-art img:nth-child(3){animation-delay:.2s,2.4s}
 .catalogue-hero-art:hover img:nth-child(1){transform:translateY(-50%) rotate(-15deg) scale(.9) translateX(-12px)}
 .catalogue-hero-art:hover img:nth-child(3){transform:translateY(-46%) rotate(14deg) scale(.9) translateX(12px)}
 .catalogue-hero-spark{animation:catalogue-twinkle 3.2s ease-in-out infinite}
 .store-catalogue .catalogue-grid .book-card:not([hidden]){animation:catalogue-card .5s cubic-bezier(.2,.7,.2,1) backwards}
 .store-catalogue .catalogue-grid .book-card:nth-child(4n+2){animation-delay:.05s}
 .store-catalogue .catalogue-grid .book-card:nth-child(4n+3){animation-delay:.1s}
 .store-catalogue .catalogue-grid .book-card:nth-child(4n){animation-delay:.15s}
}
@keyframes store-float{50%{translate:0 -8px}}
@keyframes catalogue-twinkle{0%,100%{transform:scale(1) rotate(0)}50%{transform:scale(.72) rotate(18deg)}}
@media(max-width:760px){
 /* Search gets the full row; sort shares the results row. */
 .store-catalogue .catalogue-filters{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:8px;padding-bottom:0}
 .store-catalogue .filter-main{display:contents}
 .store-catalogue .search-field{grid-column:1/-1;grid-row:1}
 .store-catalogue .filter-age{grid-column:1/-1;grid-row:2}
 .store-catalogue .filter-theme{grid-column:1/-1;grid-row:3}
 .store-catalogue .catalogue-results{grid-column:1/-1;grid-row:4;display:grid;grid-template-columns:26px max-content;column-gap:8px;row-gap:4px;min-height:52px;margin:10px -12px 0;padding:8px 12px}
 .store-catalogue .catalogue-results .clear-filters{grid-column:1/-1;margin-left:0}
 .store-catalogue .sort-field{grid-column:2;grid-row:4;align-self:center;z-index:1;height:40px;margin-top:10px;padding:0 0 0 8px;border:0;background:transparent;gap:4px}
 .store-catalogue .sort-field select{max-width:none;min-height:40px;font-size:13px}
 .store-catalogue .filter-chip-line>span{gap:5px}
 .store-catalogue .filter-chip-line>span svg{width:15px;height:15px}
 .store-catalogue .filter-chip-line>span{flex-basis:62px}
 .results-icon{width:26px;height:26px;border-radius:8px}.results-icon svg{width:15px;height:15px}
 .store-catalogue .catalogue-empty{padding:16px;gap:12px}.empty-icon{width:38px;height:38px}
}
/* Both directions remain discoverable. Disabled arrows identify the ends. */
.store-catalogue .filter-theme {display:flex;align-items:center;gap:10px;min-width:0;}
.store-catalogue .theme-chips {min-width:0;flex:1;padding:4px 8px;mask-image:none;-webkit-mask-image:none;}
.store-catalogue .theme-chips.has-next {mask-image:linear-gradient(90deg,#000 calc(100% - 24px),transparent);}
.store-catalogue .theme-chips.has-previous {mask-image:linear-gradient(90deg,transparent,#000 24px);}
.store-catalogue .theme-chips.has-previous.has-next {mask-image:linear-gradient(90deg,transparent,#000 24px,#000 calc(100% - 24px),transparent);}
.store-catalogue :is(.theme-prev,.theme-next) {display:none;flex:none;width:38px;height:38px;border:1px solid #bdd1c2;border-radius:50%;background:white;color:var(--green);place-items:center;cursor:pointer;}
.js-store.store-catalogue :is(.theme-prev,.theme-next),.js-store .store-catalogue :is(.theme-prev,.theme-next) {display:grid;}
.store-catalogue .theme-prev svg {transform:rotate(180deg);}
.store-catalogue :is(.theme-prev,.theme-next):disabled {opacity:.35;cursor:default;}
.store-catalogue :is(.theme-prev,.theme-next):hover:not(:disabled) {background:#e7f4ed;}
@media(max-width:600px){.store-catalogue .filter-theme{gap:5px;}.store-catalogue .filter-theme>span{display:none;}.store-catalogue :is(.theme-prev,.theme-next){width:32px;height:32px;}}

/* Custom sort dropdown (built by bookstore.js from the native select). */
.sort-menu{position:relative;flex:none}
.sort-trigger{display:flex;align-items:center;gap:8px;height:52px;padding:0 14px 0 16px;border:1px solid #d4e2d8;border-radius:14px;background:#fbfdfb;color:var(--ink);font-size:14px;cursor:pointer;transition:border-color .2s,box-shadow .2s,background .2s}
.sort-trigger:hover{border-color:#9fc0ac;background:#fff}
.sort-menu.is-open .sort-trigger{border-color:var(--green);box-shadow:0 0 0 4px #176d541a;background:#fff}
.sort-trigger>svg{width:16px;height:16px;color:var(--green)}
.sort-trigger>svg:last-child{width:18px;height:18px;color:#6a7f75;transition:transform .25s}
.sort-menu.is-open .sort-trigger>svg:last-child{transform:rotate(180deg)}
.sort-trigger-label{font-size:13px;font-weight:600;color:var(--muted)}
.sort-trigger strong{font-weight:700}
.sort-options{position:absolute;right:0;top:calc(100% + 8px);z-index:30;width:260px;margin:0;padding:6px;list-style:none;background:#fff;border:1px solid #e3eae3;border-radius:18px;box-shadow:0 22px 48px #1d3a2c29,0 2px 6px #1d3a2c12;opacity:0;visibility:hidden;transform:translateY(-8px) scale(.97);transform-origin:top right;transition:opacity .18s,transform .22s cubic-bezier(.2,.9,.25,1.1),visibility 0s linear .22s}
.sort-menu.is-open .sort-options{opacity:1;visibility:visible;transform:none;transition-delay:0s}
.sort-options:focus{outline:none}
.sort-options li{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border-radius:12px;cursor:pointer;transition:background .15s}
.sort-options li.is-active{background:#eef6f0}
.sort-options li span{display:flex;flex-direction:column;line-height:1.3}
.sort-options li strong{font-size:14px;font-weight:700;color:var(--ink)}
.sort-options li small{font-size:12px;color:#6a7f75}
.sort-options li svg{width:18px;height:18px;color:var(--green);opacity:0;transform:scale(.6);transition:opacity .2s,transform .2s}
.sort-options li[aria-selected=true] svg{opacity:1;transform:none}
.sort-options li[aria-selected=true] strong{color:var(--green)}
.sort-options:focus-visible li.is-active{box-shadow:inset 0 0 0 2px #8e52c3}
@media(max-width:760px){
 .store-catalogue .sort-menu{grid-column:2;grid-row:4;align-self:center;z-index:2;margin-top:10px}
 .sort-trigger{height:40px;padding:0 8px;border:0;background:transparent;gap:5px;font-size:13px}
 .sort-trigger:hover,.sort-menu.is-open .sort-trigger{background:#eef6f0;box-shadow:none}
 .sort-trigger-label{display:none}
 .sort-options{width:min(260px,calc(100vw - 48px))}
}
@media(prefers-reduced-motion:reduce){.sort-options,.sort-trigger>svg:last-child{transition:none}}
@media(max-width:360px){
 .store-catalogue .sort-menu,.store-catalogue .sort-field{grid-column:1/-1;grid-row:5;justify-self:end;margin:0 0 6px}
}
