﻿
/*image Zoom===================================================================*/

/** {
    outline: 1px solid red;
}
*/

.product-gallery {
    display: flex;
    aspect-ratio: 5 / 7;
    overflow: hidden; /* ✅ kills any tiny overflow */
    max-width: 100%;
}

    .product-gallery > [class*="col-"] {
        display: flex;
        flex-direction: column;
        height: 100%;
    }

.product-gallery,
.main-image-wrapper {
    overflow: hidden;
}

.product-gallery-height {
    max-height: calc(100vh - 80px);
}

.thumb {
    cursor: pointer;
    border: 2px solid transparent;
    width: 100%;
    aspect-ratio: 5 / 7;
    object-fit: cover;
    flex: 0 0 auto;
}

    .thumb.active {
        border-color: #cccccc;
        box-shadow: 0 0 5px rgb(125, 125, 125, 0.50);
    }

.thumbnail-column {
    overflow-y: auto;
    gap: 8px;
    max-width: 100%;
}

    .thumbnail-column::-webkit-scrollbar {
        width: 10px;
    }

    .thumbnail-column::-webkit-scrollbar-track {
        background: rgb(255, 255, 255, 0.90);
    }

    .thumbnail-column::-webkit-scrollbar-thumb {
        background: rgb(212, 172, 119, 0.30);
        border-radius: 5px;
    }

        .thumbnail-column::-webkit-scrollbar-thumb:hover {
            background: rgb(212, 172, 119, 0.80);
        }



/* Base image */
.main-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    max-width: 100%;
    display: block;
    overflow: hidden;
    cursor:zoom-in;
}

.main-image-wrapper {
    height: 100%;
}

.lightbox-overlay {
    cursor: zoom-out;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    z-index: 1050;
    overflow: auto;
}

    .lightbox-overlay.active {
        display: block;
        overflow-x: hidden;
    }

.lightbox-image {
    display: block;
    margin: 0 auto;
    width: 100%;
    height: auto;
    max-width: 2000px;
    max-height: none;
    cursor: zoom-out;
}

.lightbox-scroll {
    text-align: center;
}


.mobile-hint {
    display: none;
}

/* ✅ MOBILE FIX */
@media (max-width: 768px) {

    .desktop-hint {
        display: none;
    }

    .mobile-hint {
        display: block;
        margin-top: 4px;
        line-height: 1.3;
    }

    .lightbox-overlay {
        overflow: hidden;
    }

    .lightbox-scroll {
        overflow: auto;
        width: 100%;
        height: 100%;
        -webkit-overflow-scrolling: touch;
    }

    .lightbox-image {
        display: block;
        width: 200%;
        margin: auto;
        max-width: none;
        height: auto;
        margin: 0;
    }
}

.lightbox-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    font-size: 40px;
    color: dimgrey;
    cursor: pointer;
    padding: 20px;
    user-select: none;
    z-index: 1060;
}

    .lightbox-nav.left {
        left: 10px;
    }

    .lightbox-nav.right {
        right: 10px;
    }

.lightbox-hint {
    position: fixed;
    top: 15px;
    right: 20px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    font-family: Arial, sans-serif;
    background: rgba(0, 0, 0, 0.4);
    padding: 6px 10px;
    border-radius: 4px;
    z-index: 1060;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox-overlay.active .lightbox-hint {
    opacity: 1;
}

.thumb.placeholder {
    opacity: 0.1;
    cursor: default;
    border: none;
}

.carousel-item img {
    display: block;
}

    .carousel-item img[src=""] {
        display: none;
    }

.carousel-item.invalid {
    pointer-events: none;
    display: none;
}

    .carousel-item.invalid img {
        opacity: 0.1;
    }

#mobileCarousel img {
    cursor: pointer;
}

.lightbox-counter {
    position: fixed;
    top: 15px;
    left: 20px;
    color: rgba(255,255,255,0.85);
    font-size: 14px;
    background: rgba(0,0,0,0.4);
    padding: 6px 10px;
    border-radius: 4px;
    z-index: 1060;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

.lightbox-overlay::-webkit-scrollbar {
    width: 10px;
}

.lightbox-overlay::-webkit-scrollbar-track {
    background: rgb(255, 255, 255, 0.90);
}

.lightbox-overlay::-webkit-scrollbar-thumb {
    background: rgb(124, 124, 124, 0.20);
    border-radius: 5px;
}

    .lightbox-overlay::-webkit-scrollbar-thumb:hover {
        background: rgb(0, 0, 0, 0.90);
    }
