/* Product main image */

.details_sec .surface-lightbox-trigger {
    display: block;
    position: relative;
    cursor: zoom-in;
    text-decoration: none;
}

.details_sec .surface-lightbox-trigger img {
    display: block;
    width: 100%;
    height: auto;
}

.details_sec .surface-zoom-hint {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    padding: 7px 12px;
    border-radius: 5px;
    font-size: 12px;
    font-family: Arial, sans-serif;
}

/* Lightbox container */

.surface-image-lightbox {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.94);
    padding: 55px 65px;
    box-sizing: border-box;
}

.surface-image-lightbox.is-open {
    display: flex;
}

.surface-lb-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    min-width: 0;
}

#surface-lb-image {
    display: block;
    max-width: 100%;
    max-height: calc(100% - 65px);
    width: auto;
    height: auto;
    object-fit: contain;
    transform-origin: center;
    transition: transform 0.15s ease;
}

/* Close button */

.surface-lb-close {
    position: absolute;
    top: 12px;
    right: 22px;
    z-index: 2;
    background: transparent;
    color: #fff;
    border: 0;
    font-size: 42px;
    cursor: pointer;
}

/* Previous / Next */

.surface-lb-prev,
.surface-lb-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    padding: 10px 14px;
    background: rgba(255,255,255,0.12);
    border: 0;
    border-radius: 5px;
    color: #fff;
    font-size: 26px;
    cursor: pointer;
}

.surface-lb-prev {
    left: 12px;
}

.surface-lb-next {
    right: 12px;
}

.surface-lb-prev:hover,
.surface-lb-next:hover {
    background: rgba(255,255,255,0.25);
}

/* Zoom toolbar */

.surface-lb-toolbar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 15px;
    color: #fff;
    font-family: Arial, sans-serif;
}

.surface-lb-toolbar button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    background: #fff;
    color: #111;
    border: 0;
    border-radius: 5px;
    font-size: 22px;
    cursor: pointer;
}

body.surface-lightbox-open {
    overflow: hidden;
}

/* Mobile */

@media (max-width: 767px) {

    .surface-image-lightbox {
        padding: 60px 38px;
    }

    .surface-lb-prev,
    .surface-lb-next {
        font-size: 19px;
        padding: 8px;
    }

    .surface-lb-prev {
        left: 4px;
    }

    .surface-lb-next {
        right: 4px;
    }

    .surface-lb-close {
        right: 14px;
        top: 8px;
    }

    .details_sec .surface-zoom-hint {
        font-size: 11px;
        bottom: 8px;
        right: 8px;
    }
}

/* ======================================
   PRODUCT LIGHTBOX ZOOM CONTROLS FIX
====================================== */

/* Lightbox main content */
.surface-image-lightbox .surface-lb-content {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    padding-bottom: 65px;
    box-sizing: border-box;
}

/* Product image */
.surface-image-lightbox #surface-lb-image {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transform-origin: center center;
    transition: transform 0.2s ease;
}

/* Zoom controls always visible */
.surface-image-lightbox .surface-lb-toolbar {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 0;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.85);
    border-radius: 8px;
    white-space: nowrap;
}

/* Zoom buttons */
.surface-image-lightbox .surface-lb-toolbar button {
    position: relative;
    z-index: 101;
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 5px;
    background: #fff;
    color: #111;
    font-size: 24px;
    cursor: pointer;
}

/* Image counter */
.surface-image-lightbox #surface-image-counter {
    color: #fff;
    font-size: 15px;
    font-weight: 600;
}

/* Mobile responsive */
@media (max-width: 767px) {

    .surface-image-lightbox .surface-lb-content {
        padding-bottom: 65px;
    }

    .surface-image-lightbox .surface-lb-toolbar {
        bottom: 5px;
        gap: 10px;
        padding: 7px 10px;
    }

    .surface-image-lightbox .surface-lb-toolbar button {
        width: 36px;
        height: 36px;
        font-size: 21px;
    }
}