/* Cover-first shelves. The full reader package stays on each edition's page. */
#catalogBooks,.populated-shelf .cards{grid-template-columns:repeat(5,minmax(0,1fr));column-gap:32px;row-gap:36px;align-items:start}
#catalogBooks>.card,.populated-shelf .card{display:block;grid-row:auto;min-width:0;padding:0;border:0}
#catalogBooks .card-copy,#catalogBooks .card-actions,#catalogBooks .card-editorial,
.populated-shelf .card-copy,.populated-shelf .card-actions,.populated-shelf .card-editorial{display:none}
#catalogBooks .cover-stage,.populated-shelf .cover-stage{height:auto;aspect-ratio:2/3;max-height:none;padding:0;background:transparent;overflow:visible;transition:transform .2s ease}
#catalogBooks .cover-stage img,.populated-shelf .cover-stage img{display:block;width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain;filter:drop-shadow(3px 5px 4px #302a2426)}
#catalogBooks .cover-stage .book,.populated-shelf .cover-stage .book{width:100%;max-width:100%;flex-basis:100%;transform:none}
#catalogBooks .empty-state{grid-column:1/-1}
#catalog .demo-note,.populated-shelf .shelf-note{display:none}
.catalog-filters{margin:24px 0 16px;border-top:1px solid var(--line);border-bottom:1px solid var(--line)}
.catalog-filters>summary{cursor:pointer;min-height:48px;padding:14px 0;font-size:14px}
.catalog-filters>summary:focus-visible{outline:3px solid var(--gold);outline-offset:4px}
.catalog-filters .search-tools{margin-top:0}
.catalog-filters .form-help{margin-bottom:20px}
#catalog #resultsCount{margin:16px 0 24px;color:#756d61}
#catalog #resetSearch{margin-top:28px}
@media(hover:hover){
  #catalogBooks .cover-stage:hover,.populated-shelf .cover-stage:hover{transform:translateY(-4px)}
}
@media(prefers-reduced-motion:reduce){
  #catalogBooks .cover-stage,.populated-shelf .cover-stage{transition:none}
}
.hero-monthly-shelf{max-width:1480px;padding-left:3%;padding-right:3%}
#collection .featured-five-banner{margin:4px 0 22px;padding:22px 18px;background:#8d4035;color:#fff5e7;border-top:3px double #d1b17a;border-bottom:3px double #d1b17a;text-align:center}
#collection .featured-five-banner h2{margin:0;font:400 clamp(28px,4vw,42px)/1.15 Georgia,'Times New Roman',serif;letter-spacing:.2px;color:inherit}
#collection .featured-five-banner #monthTheme{margin:10px 0 0;font:400 clamp(15px,2vw,19px)/1.5 Georgia,'Times New Roman',serif;letter-spacing:.2px;color:inherit}
.edition-opening{max-width:1280px;gap:48px;align-items:center}
.edition-art{padding:32px 18px 22px;min-width:0}
.edition-art .story-edition-cover-link{width:min(100%,440px)}
.edition-art img{width:100%;max-width:440px;height:auto;object-fit:contain}
.story-cover{padding:24px 16px}
.story-cover .story-edition-cover-link{max-width:400px}
.story-cover .catalog-edition-cover{display:block;width:100%;height:auto;max-width:100%;object-fit:contain}
.recommendation-card img{width:136px;height:218px;max-width:42%;object-fit:contain}
.author-collection-card img{width:132px;height:212px;max-width:42%;object-fit:contain}
#roulette .roulette-result{grid-template-columns:160px minmax(0,1fr);max-width:660px;width:100%;gap:24px}
@media(max-width:999px){
  #catalogBooks,.populated-shelf .cards{grid-template-columns:repeat(4,minmax(0,1fr));column-gap:24px;row-gap:30px}
}
@media(max-width:719px){
  #catalogBooks,.populated-shelf .cards{grid-template-columns:repeat(3,minmax(0,1fr));column-gap:18px;row-gap:24px}
}
@media(max-width:920px){
  .edition-opening{gap:28px}
}
@media(max-width:650px){
  .edition-art{padding:22px 8px 18px}
  .edition-art .story-edition-cover-link{width:min(100%,340px)}
  .edition-art img{max-width:340px}
  .story-cover .story-edition-cover-link{max-width:340px}
  .story-cover{padding:20px 8px}
  .recommendation-card img,.author-collection-card img{width:112px;height:180px}
  #roulette .roulette-result{grid-template-columns:140px minmax(0,1fr);gap:20px}
}
@media(max-width:359px){
  #catalogBooks,.populated-shelf .cards{column-gap:12px;row-gap:20px}
}
@media(max-width:400px){
  #roulette .roulette-result{grid-template-columns:minmax(0,1fr);text-align:center}
  #roulette .roulette-result-cover{width:170px;max-width:100%;margin:auto}
  #roulette .roulette-result h3{font-size:27px}
}
/* On phones, show all five together in balanced, upright rows. */
@media(max-width:719px){
  #collection .hero-monthly-shelf{padding-left:6%;padding-right:6%}
  #collection .month-toolbar{justify-content:center;text-align:center;gap:8px 12px}
  #collection #monthTheme{flex-basis:100%}
}
