/* One cover scale per context. Original proportions and complete artwork are retained.
   The margin-free assets prevent transparent canvases from shrinking individual books. */
:root{--book-thumbnail-height:200px;--book-preview-height:160px}
.fl-cover,.tw-book-cover,.duguli-world .dw-book-cover{height:var(--book-thumbnail-height);width:100%;max-width:100%;display:grid;place-items:center}
.fl-cover>img,.tw-book-cover>img,.duguli-world .dw-book-cover>img,
.pathway-book .pathway-image>img{width:auto;height:var(--book-thumbnail-height);max-width:100%;max-height:none;object-fit:contain;object-position:center}
.fl-cover{margin-block:22px 26px}
.pathway-book .pathway-image{min-height:230px}
.free-library .fl-translation-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:22px}
.free-library .fl-translation{grid-template-columns:1fr;align-content:start;justify-items:center;gap:26px;padding:27px}
.free-library .fl-translation>img{height:var(--book-thumbnail-height);width:auto;max-width:100%;object-fit:contain;align-self:center}
.free-library .fl-translation>div{width:100%}
.free-library main .fl-translation h3{min-height:108px;font-size:25px;overflow-wrap:anywhere}
.product-page:not(.game-page) .gallery-thumb{width:74px;height:70px;flex-shrink:0}
.product-page:not(.game-page) .gallery-thumb[data-image="cover"] img{position:static;inset:auto;width:auto;height:58px;max-width:calc(100% - 8px);max-height:none;object-fit:contain}
.product-page:not(.game-page) .closing-purchase>img[src*="book-thumbnails"]{width:auto;height:225px;max-width:100%;object-fit:contain;justify-self:center}
.product-page .trilogy-paper img[src*="book-thumbnails"]{width:70px;height:105px;object-fit:contain;flex-shrink:0}
.product-page .duguli2-series-paper img[src*="book-thumbnails"],
.product-page .duguli-box-grid img[src*="book-thumbnails"]{width:auto;height:var(--book-thumbnail-height);max-width:100%;max-height:none;object-fit:contain;justify-self:center}
.product-card .product-art.book-art{display:flex;align-items:center;justify-content:center;gap:0;background:#faf4e8;min-height:240px;aspect-ratio:auto}
.product-card .product-art.book-art::before,.product-card .product-art.book-art::after{display:none}
.book-art>img{width:auto;height:var(--book-thumbnail-height);max-width:90%;object-fit:contain;filter:drop-shadow(5px 8px 5px #54331e33)}
.book-art.book-trilogy{position:relative}
.book-trilogy>img{position:absolute;max-width:60%;height:var(--book-thumbnail-height);transform:translateX(-37px) rotate(-10deg)}
.book-trilogy>img:nth-child(2){transform:translateY(-5px);z-index:1}
.book-trilogy>img:nth-child(3){transform:translateX(37px) rotate(10deg);z-index:2}
@media(max-width:1180px){.free-library .fl-translation-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){
 :root{--book-thumbnail-height:144px}
 .product-page:not(.game-page) .mobile-cover-preview{height:var(--book-preview-height);width:100%;max-height:none;object-fit:contain}
 .product-page:not(.game-page) .gallery-thumb{width:57px;height:55px}
 .product-page:not(.game-page) .gallery-thumb[data-image="cover"] img{height:45px}
 .product-page:not(.game-page) .closing-purchase>img[src*="book-thumbnails"]{height:144px;width:95px}
 .free-library main .fl-translation h3{font-size:27px;min-height:90px}
 .pathway-book .pathway-image{min-height:180px}
 .product-card .product-art.book-art{min-height:200px}
 .book-trilogy>img{height:var(--book-thumbnail-height);transform:translateX(-25px) rotate(-10deg)}
 .book-trilogy>img:nth-child(3){transform:translateX(25px) rotate(10deg)}
}
@media(max-width:520px){.free-library .fl-translation-grid{grid-template-columns:1fr}.free-library main .fl-translation h3{min-height:0}.free-library .fl-translation{gap:23px}.product-page .duguli2-series-paper img[src*="book-thumbnails"]{height:144px}}
@media(max-width:370px){:root{--book-thumbnail-height:125px;--book-preview-height:132px}}
