/*
 Theme Name:   FabUI
 Theme URI:    https://fabulous.gr
 Description:  Custom child theme for Divi by Fabulous Design Studio
 Author:       Fabulous Design Studio
 Author URI:   https://fabulous.gr
 Template:     Divi
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  http://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  fabui
*/

/* =Theme customization starts here
-------------------------------------------------------------- */

/* Single product image — magnifying glass overlay on hover */
.woocommerce-product-gallery__image {
    position: relative;
    cursor: zoom-in;
}

.woocommerce-product-gallery__image::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.15)
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E")
        center / 40px no-repeat;
}

.woocommerce-product-gallery__image:hover::after {
    opacity: 1;
}

/* Hide the default WooCommerce magnifying glass trigger icon (top-right) */
.woocommerce-product-gallery__trigger {
    display: none !important;
}

/* Fix distorted CDN product images — preserve natural aspect ratio */
.woocommerce-product-gallery__image img,
.woocommerce-product-gallery .flex-viewport img {
    object-fit: contain !important;
    width: 100% !important;
    height: auto !important;
}

/* Lightbox / PhotoSwipe — prevent distortion */
.pswp__img {
    object-fit: contain !important;
}
