.product-gallery-frames figure{margin:0}
.product-gallery-frames figure[hidden]{display:none!important}
.product-gallery-frames img{display:block;width:100%;height:auto;aspect-ratio:3/2;object-fit:contain}
.product-gallery-frames figcaption{margin-top:12px}
.product-gallery-controls{display:flex;align-items:center;justify-content:center;gap:12px;margin-top:18px;flex-wrap:wrap}
.product-gallery-controls[hidden]{display:none!important}
.product-gallery [hidden]{display:none!important}
.product-gallery-controls button{width:auto;margin:0;padding:5px 10px;border:1px solid var(--line);border-radius:3px;background:var(--raised);color:var(--pale);font:12px var(--mono);cursor:pointer}
.product-gallery-controls button:hover{border-color:var(--accent);color:var(--accent)}
.product-gallery-dots{display:flex;align-items:center;gap:6px}
.product-gallery-dots button{width:15px;height:15px;padding:0;border-radius:50%;font-size:0}
.product-gallery-dots button[aria-current=true]{background:var(--accent);border-color:var(--accent)}
.product-gallery-open{display:block;position:relative;width:100%;padding:0;border:0;background:transparent;color:var(--pale);cursor:zoom-in;text-align:left}
.product-gallery-open img{display:block;width:100%}
.product-gallery-open span{position:absolute;right:10px;bottom:10px;padding:7px 10px;border:1px solid var(--line);border-radius:3px;background:rgba(12,16,19,.88);font:12px var(--mono)}
.product-gallery-open:hover span,.product-gallery-open:focus-visible span{border-color:var(--accent);color:var(--accent)}
.product-image-viewer{box-sizing:border-box;width:100vw;max-width:100vw;height:100dvh;max-height:100dvh;margin:0;padding:clamp(12px,3vw,32px);border:0;background:#101418;color:#f1f2ef;overflow:auto}
.product-image-viewer::backdrop{background:rgba(0,0,0,.92)}
.product-image-viewer-content{box-sizing:border-box;position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;min-height:100%;padding:42px 0 0}
.product-image-viewer-close{position:fixed;top:clamp(12px,3vw,32px);right:clamp(12px,3vw,32px);z-index:1}
.product-image-viewer button{min-width:44px;min-height:44px;border:1px solid #888;border-radius:3px;background:#20282c;color:#fff;font-size:26px;cursor:pointer}
.product-image-viewer button:hover,.product-image-viewer button:focus-visible{border-color:#fff}
.product-image-viewer-image{display:flex;align-items:center;justify-content:center;flex:1;width:100%;min-height:0}
.product-image-viewer-image img{display:block;max-width:100%;max-height:calc(100dvh - 190px);width:auto;height:auto;object-fit:contain}
.product-image-viewer-caption{max-width:70ch;margin:0;text-align:center;font-size:14px;line-height:1.4}
.product-image-viewer-controls{display:flex;align-items:center;justify-content:center;gap:20px}
.product-image-viewer-controls[hidden]{display:none}
.product-image-viewer-count{min-width:4em;text-align:center;font:13px var(--mono)}
@media(max-width:600px){.product-image-viewer{padding:12px}.product-image-viewer-image img{max-height:calc(100dvh - 165px)}.product-image-viewer-content{padding-top:48px}.product-image-viewer-controls{gap:14px}}

/* Tightly framed native portrait images for Grand Pinball only. */
.product-gallery[data-portrait-gallery] .product-gallery-frames img{aspect-ratio:2/3}
