/* Studio product previews and an explicit full-artwork view. */
#pgrid .pimg.readable-preview{position:relative;height:220px;padding:12px 12px 50px;background:#fbfaf9}
#pgrid .pimg.readable-preview img.product-preview{display:block;position:static;width:100%;height:100%;object-fit:contain;transform:none}
#pgrid .pimg img.readable-motif{position:absolute;bottom:8px;right:10px;width:64px;height:32px;object-fit:contain;background:white;border:1px solid #e8e4df;border-radius:4px;padding:3px}
.readable-label{position:absolute;bottom:15px;left:12px;font-size:10px;color:#777}
#pgrid[data-view=motif] .pimg.readable-preview img.readable-motif{position:static;display:block;width:100%;height:100%;border:0;background:none;padding:0;border-radius:0}
#pgrid[data-view=motif] .pimg.readable-preview img.product-preview{position:absolute;bottom:8px;right:10px;width:64px;height:32px;border:1px solid #e8e4df;border-radius:4px;background:white;padding:3px}
.readable-product-motif{padding:14px;margin:0 0 16px;border:1px solid #e1dfdc;border-radius:12px;background:white}
.readable-product-motif h3{font-size:17px;margin:0 0 12px}
.readable-motif-button{display:block;width:100%;border:0;background:white;color:#202126;cursor:zoom-in;padding:0}
.readable-motif-button img{display:block;width:100%;height:auto;max-height:300px;object-fit:contain}
.readable-motif-button span{display:block;padding:12px;text-decoration:underline;font-size:14px}
.motif-zoom-dialog{width:min(1200px,96vw);max-width:96vw;max-height:94dvh;border:0;border-radius:14px;padding:16px;box-sizing:border-box;background:white;color:#202126}
.motif-zoom-dialog::backdrop{background:rgba(0,0,0,.7)}
.motif-zoom-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.motif-zoom-bar strong{margin-right:auto}
.motif-zoom-bar button{min-width:44px;min-height:44px;padding:8px 12px;border:1px solid #ccc;background:white;border-radius:8px;cursor:pointer}
.motif-zoom-dialog p{font-size:13px;color:#60646b}
.motif-zoom-scroll{overflow:auto;max-height:70dvh;overscroll-behavior:contain;touch-action:pan-x pan-y pinch-zoom}
.motif-zoom-scroll img{display:block;width:100%;max-width:none;height:auto}
.mug-faces{display:none;width:100%;height:100%;object-fit:contain;max-height:none!important;transform:none!important}
#pgrid .pimg.photo-preview .mug-faces{display:block}
#pgrid .pimg.photo-preview img.product-preview{display:none}
#pgrid[data-view=motif] .pimg.readable-preview .mug-faces{display:none}
#pgrid[data-view=motif] .pimg.readable-preview img.product-preview{display:block}
.hero-product-preview{display:none;width:100%;max-height:260px;object-fit:contain;border-radius:12px}
.hero-slide-wrap.photo-preview #heroMug{display:none}
.hero-slide-wrap.photo-preview .hero-product-preview{display:block}
/* A generous, consistent studio frame with one product and a separate back view. */
#pgrid .pcard{position:relative}
#pgrid .pimg,#pgrid .pimg.readable-preview{height:280px;padding:8px 14px 38px;background:radial-gradient(ellipse at 50% 48%,#fff 30%,#f5f3ef 100%);overflow:hidden}
#pgrid .pimg.photo-preview .mug-faces{height:100%;width:100%;object-fit:contain}
.preview-turn{position:absolute;top:12px;right:12px;z-index:2;width:40px;height:40px;border:1px solid #dedbd5;border-radius:50%;background:rgba(255,255,255,.94);color:#343735;font-size:24px;cursor:pointer;box-shadow:0 2px 5px #00000008}
.preview-turn[hidden]{display:none}
.preview-turn:hover,.preview-turn[aria-pressed=true]{background:#e8efe9;border-color:#819a88}
.preview-turn:focus-visible,.mug-gallery button:focus-visible{outline:3px solid #367653;outline-offset:3px}
#pgrid[data-view=motif] .preview-turn{display:none}
#pgrid .readable-label{font-size:11px;color:#60635e;left:16px;bottom:14px}
#pgrid .pimg img.readable-motif{width:58px;height:30px;background:#fff;right:14px;bottom:8px}
.detail-mug-photo{display:none!important}
.mimg.studio-preview{background:radial-gradient(ellipse,#fff 35%,#f5f3ef);border-radius:16px;min-height:320px}
.mimg.studio-preview #mImg,.mimg.studio-preview #productZoomLens{display:none!important}
.mimg.studio-preview .detail-mug-photo{display:block!important;width:100%!important;height:340px!important;object-fit:contain!important;transform:none!important;max-width:none!important;max-height:none!important}
.mug-gallery{display:flex;justify-content:center;gap:8px;margin:12px 0 20px}
.mug-gallery[hidden]{display:none}
.mug-gallery button{font:inherit;font-size:13px;min-height:42px;padding:8px 16px;border:1px solid #d9ded9;border-radius:8px;background:white;cursor:pointer}
.mug-gallery button[aria-pressed=true]{color:#285e40;background:#eaf1e9;border-color:#7e9985}
.hero-product-preview{max-height:320px;background:radial-gradient(ellipse,#fff,#f5f3ef)}
@media(max-width:760px){#pgrid .pimg,#pgrid .pimg.readable-preview{height:240px;padding:8px 10px 38px}}
@media(max-width:520px){#pgrid .pimg,#pgrid .pimg.readable-preview{height:300px;padding:8px 16px 38px}.mimg.studio-preview .detail-mug-photo{height:280px!important}.mimg.studio-preview{min-height:280px}}
.mimg.studio-preview{display:flex!important;flex-direction:column;align-items:center;justify-content:center;padding:16px!important}.mimg .mug-gallery{flex-shrink:0;width:100%;margin:8px 0 0}.mimg.studio-preview .detail-mug-photo{flex-shrink:0}.mimg .mug-gallery button{height:auto!important;width:auto!important;flex:0 1 auto}

#moverlay .mimg.studio-preview{background:radial-gradient(ellipse,#fff 35%,#f5f3ef)!important}#moverlay .mimg.studio-preview{height:auto!important;min-height:440px!important}@media(max-width:760px){#moverlay .mimg.studio-preview{min-height:0!important;padding:12px!important}#moverlay .mimg.studio-preview .detail-mug-photo{height:270px!important}}

/* Default catalogue view is always the physical product, never the flat art. */
#pgrid:not([data-view=motif]) .pimg img.readable-motif{display:none!important}
#pgrid:not([data-view=motif]) .pimg.photo-preview img.product-preview{display:none!important}
#pgrid:not([data-view=motif]) .pimg.photo-preview img.mug-faces{display:block!important}
#pgrid[data-view=motif] .pimg.readable-preview img.readable-motif{display:block!important}
#pgrid[data-view=motif] .pimg.readable-preview img.product-preview,#pgrid[data-view=motif] .pimg .mug-faces{display:none!important}
#pgrid .readable-label::after{content:'Hrnek s potiskem'}
#pgrid[data-view=motif] .readable-label::after{content:'Celý motiv'}
@media(min-width:1500px){#pgrid .pimg,#pgrid .pimg.readable-preview{height:320px;padding:8px 10px 32px}}

/* A readable, uncropped print accompanies the physical product by default. */
#pgrid .card-full-motif{padding:12px 16px 16px;background:#fff;border-top:1px solid #eee9e3}
#pgrid .card-full-motif-caption{display:block;margin-bottom:8px;font-size:11px;font-weight:600;color:#66635e}
#pgrid .card-full-motif img{display:block;position:static;width:100%;height:116px;max-height:none;object-fit:contain;object-position:center;transform:none;background:#fff}
#pgrid[data-view=motif] .card-full-motif{display:none}
#pgrid .readable-label::after{content:'Na výrobku'}
@media(max-width:520px){#pgrid .card-full-motif img{height:132px}}
