/* Equal, uncropped image areas for the XStore storefront. */
/* The archive hero is above the fold: never wait for an entrance animation. */
.elementor-element-3fa827a7 .elementor-invisible {
    visibility: visible !important;
}
.elementor-element-3fa827a7 .animated {
    animation: none !important;
    opacity: 1 !important;
}

.category-grid.product-category.content-under {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch;
}

.category-grid.product-category.content-under > a:first-child,
.etheme-product-grid-image > a:first-child,
.content-product .product-image-wrapper > a.product-content-image,
.woocommerce-product-gallery__image > a.woocommerce-main-image {
    display: block !important;
    position: relative;
    box-sizing: border-box;
    width: 100%;
    height: auto !important;
    aspect-ratio: 1 / 1;
    padding: 0 !important;
    min-height: 0 !important;
    flex: none !important;
    align-self: flex-start;
    overflow: hidden;
    background: #fff;
}

.category-grid.product-category.content-under > a:first-child > picture,
.etheme-product-grid-image > a:first-child > picture,
.content-product .product-image-wrapper > a.product-content-image > picture,
.woocommerce-product-gallery__image > a.woocommerce-main-image > picture {
    display: block;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.category-grid.product-category.content-under > a:first-child img,
.etheme-product-grid-image > a:first-child img,
.content-product .product-image-wrapper > a.product-content-image img,
.woocommerce-product-gallery__image > a.woocommerce-main-image img:not(.zoomImg) {
    display: block;
    position: absolute;
    inset: 0;
    box-sizing: border-box;
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain !important;
    object-position: center;
    padding: clamp(8px, 4%, 18px);
    margin: 0;
}

.category-grid.product-category.content-under .categories-mask {
    position: static;
    padding: 16px 8px !important;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.category-grid.product-category.content-under .categories-mask h4 {
    margin-top: 0;
    margin-bottom: 6px;
}

/* A card's outer area follows the image, rather than a previous tall image. */
.etheme-product-grid-image {
    height: auto !important;
    min-height: 0 !important;
}

/* Product detail galleries must not grow to the full desktop column width. */
.single-product .main-images {
    --rsc-gallery-height: clamp(280px, 60vh, 560px);
    height: var(--rsc-gallery-height) !important;
    align-items: stretch;
}

.single-product .main-images .woocommerce-product-gallery__wrapper,
.single-product .main-images .woocommerce-product-gallery__image,
.single-product .main-images .woocommerce-main-image {
    height: var(--rsc-gallery-height) !important;
    min-height: 0 !important;
}

.single-product .main-images .woocommerce-main-image {
    width: 100% !important;
    aspect-ratio: auto;
}

.single-product .images-wrapper .pswp-additional {
    display: block;
    position: relative;
    width: 100%;
    height: 80px;
    background: #fff;
}

.single-product .images-wrapper .pswp-additional picture {
    display: block;
    width: 100%;
    height: 100%;
}

.single-product .images-wrapper .pswp-additional img {
    width: 100% !important;
    height: 100% !important;
    box-sizing: border-box;
    padding: 6px;
    object-fit: contain !important;
}
