/* The gallery's first paint and initialized slider use the same track height. */
.fe-stable-gallery #continut>div.product>.woocommerce-product-gallery{
  display:grid;grid-template-columns:minmax(0,1fr);
  grid-template-rows:var(--fe-balanced-height) auto;align-content:start;row-gap:0;
}
.fe-stable-gallery .woocommerce-product-gallery>.flex-viewport,
.fe-stable-gallery .woocommerce-product-gallery>.woocommerce-product-gallery__wrapper{
  grid-area:1/1;min-width:0;height:var(--fe-balanced-height)!important;
}
/* Before WooCommerce wraps the track, render only the active first slide. */
.fe-stable-gallery .woocommerce-product-gallery>.woocommerce-product-gallery__wrapper>.woocommerce-product-gallery__image:not(:first-child){display:none}
.fe-stable-gallery .woocommerce-product-gallery>.woocommerce-product-gallery__wrapper>.woocommerce-product-gallery__image:first-child{width:100%}
.fe-stable-gallery-thumbs #continut>div.product>.woocommerce-product-gallery{row-gap:12px}
/* Reserve the thumbnail rows before the slider creates their markup. */
.fe-stable-gallery-thumbs .woocommerce-product-gallery::after{
  content:"";display:block;grid-area:2/1;width:100%;
  aspect-ratio:5 / var(--fe-cls-thumb-rows);max-height:154px;pointer-events:none;
}
.fe-stable-gallery .woocommerce-product-gallery>.flex-control-thumbs{
  grid-area:2/1;align-self:start;margin:0!important;
}
/* Preserve the observed compact desktop photo height on the panel page. */
@media(min-width:901px){.fe-stable-gallery.postid-50{--fe-balanced-height:240px}}
