.abode-product-gallery{display:grid;grid-template-columns:minmax(0,1fr);gap:12px;min-width:0;max-width:100%;position:relative}
.apg-viewer{position:relative;grid-row:1;min-width:0;width:100%;aspect-ratio:1/1;overflow:hidden;background:#fff}
.apg-main-trigger{position:relative;display:block;width:100%;height:100%;padding:0;border:0;background:#fff;cursor:zoom-in;line-height:0;aspect-ratio:1}
.apg-main-trigger:hover,.apg-main-trigger:focus{background:#fff}
.apg-main-image{position:absolute;inset:0;width:100%;height:100%;display:block;object-fit:contain;aspect-ratio:1;max-height:none}
.apg-zoom-icon{position:absolute;bottom:12px;right:12px;line-height:1;font-size:21px;color:#333;background:#ffffffdf;padding:8px;border-radius:50%;box-shadow:0 1px 8px #0002}
.apg-thumbs{display:flex;gap:9px;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain;scrollbar-width:thin;scroll-snap-type:x proximity;padding:2px 2px 6px}
.apg-thumb{flex:0 0 74px;width:74px;height:74px;display:flex;align-items:center;justify-content:center;padding:2px;border:2px solid transparent;background:#fff;border-radius:2px;cursor:pointer;scroll-snap-align:start}
.apg-thumb.is-active{border-color:#333}
.apg-thumb img{display:block;width:100%;height:100%;object-fit:cover;aspect-ratio:1}
.apg-arrow{position:absolute;top:50%;transform:translateY(-50%);z-index:2;width:34px;height:45px;padding:0;border:0;border-radius:2px;background:#ffffffd9;color:#333;font-size:34px;line-height:1;cursor:pointer}
.apg-arrow:hover,.apg-arrow:focus{background:#fff;color:#111}
.apg-prev{left:0}.apg-next{right:0}
@media(min-width:768px){
.abode-product-gallery:not(.apg-thumbs-bottom):not(.apg-thumbs-right){grid-template-columns:82px minmax(0,1fr);gap:12px}
.abode-product-gallery:not(.apg-thumbs-bottom):not(.apg-thumbs-right) .apg-viewer{grid-column:2;grid-row:1}
.abode-product-gallery:not(.apg-thumbs-bottom):not(.apg-thumbs-right) .apg-thumbs{grid-column:1;grid-row:1;flex-direction:column;overflow-x:hidden;overflow-y:auto;align-self:start;max-height:560px;scroll-snap-type:y proximity}
.abode-product-gallery:not(.apg-thumbs-bottom):not(.apg-thumbs-right) .apg-thumb{flex:0 0 74px}
.abode-product-gallery.apg-thumbs-right{grid-template-columns:minmax(0,1fr) 82px;gap:12px}
.abode-product-gallery.apg-thumbs-right .apg-viewer{grid-column:1;grid-row:1}
.abode-product-gallery.apg-thumbs-right .apg-thumbs{grid-column:2;grid-row:1;flex-direction:column;overflow-x:hidden;overflow-y:auto;align-self:start;max-height:560px;scroll-snap-type:y proximity}
.abode-product-gallery.apg-thumbs-right .apg-thumb{flex:0 0 74px}
}
.apg-lightbox[hidden]{display:none!important}
.apg-lightbox{position:fixed!important;inset:0;z-index:999999;background:rgba(0,0,0,.94);display:flex;align-items:center;justify-content:space-around;gap:6px;padding:45px 12px;box-sizing:border-box}
.apg-lightbox-image{object-fit:contain;max-width:calc(100vw - 105px);max-height:calc(100vh - 90px);width:auto;height:auto}
.apg-lightbox-close,.apg-lightbox-prev,.apg-lightbox-next{background:transparent!important;color:#fff!important;border:0!important;cursor:pointer;padding:8px;font-size:39px;line-height:1}
.apg-lightbox-close{position:absolute;right:12px;top:10px;z-index:1;font-size:36px}
.apg-lightbox-prev,.apg-lightbox-next{flex:0 0 37px}
body.apg-lightbox-open{overflow:hidden}
@media(max-width:767px){.apg-thumb{flex-basis:66px;width:66px;height:66px}.apg-lightbox-image{max-width:calc(100vw - 88px)}.apg-lightbox-prev,.apg-lightbox-next{flex-basis:28px}}
