/* Product Gallery Splide Styles */
.product-gallery-splide {
    position: relative;
    max-width: 100%;
    overflow: hidden;
    margin-bottom: 0 !important;
}

.product-gallery-splide .splide__slide {
    position: relative;
    overflow: hidden;
}

.product-gallery-slide {
    position: relative;
      overflow: hidden;
}

.product-gallery-slide--video {
    background: #000;
}


/* Fullscreen Button */
.product-gallery-fullscreen {
    position: absolute;
    right: 12px;
    bottom: 12px;
    width: 2rem;
    height: 2rem;
    background: rgba(234, 234, 234, 0.6);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
    z-index: 10;
}

.product-gallery-fullscreen:hover {
    background: rgba(234, 234, 234, 0.7);
}

.product-gallery-fullscreen svg {
    width: 1rem;
    height: 1rem;
}


/* Splide Navigation Arrows */
.product-gallery-splide .splide__arrows {
    display: flex;
}

.product-gallery-splide .splide__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.product-gallery-splide .splide__arrow:hover {
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.product-gallery-splide .splide__arrow--prev {
    left: 12px;
}

.product-gallery-splide .splide__arrow--next {
    right: 12px;
}

.product-gallery-splide .splide__arrow svg {
    width: 20px;
    height: 20px;
    color: #333;
}

.product-gallery-splide .splide__arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Thumbnails Gallery */
.product-gallery-thumbnails-splide {
    margin-top: 0;
}

.product-gallery-thumbnail {
    position: relative;
    width: 100%;
    height: 100%;
    padding-bottom: 75%;
    overflow: hidden;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.product-gallery-thumbnail:hover {
    border-color: #007cba;
}

.product-gallery-thumbnail.is-active {
    border-color: #007cba;
}

.product-gallery-thumbnail--video {
    background: #000;
}

.product-gallery-thumbnail-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Video Thumbnail Overlay */

.product-gallery-thumbnail--video:after{
    content: '';
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg id='SVGRepo_bgCarrier' stroke-width='0'%3E%3C/g%3E%3Cg id='SVGRepo_tracerCarrier' stroke-linecap='round' stroke-linejoin='round'%3E%3C/g%3E%3Cg id='SVGRepo_iconCarrier'%3E%3Cpath opacity='0.5' fill-rule='evenodd' clip-rule='evenodd' d='M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z' fill='%231C274C'%3E%3C/path%3E%3Cpath d='M15.4137 13.059L10.6935 15.8458C9.93371 16.2944 9 15.7105 9 14.7868V9.21316C9 8.28947 9.93371 7.70561 10.6935 8.15419L15.4137 10.941C16.1954 11.4026 16.1954 12.5974 15.4137 13.059Z' fill='%231C274C'%3E%3C/path%3E%3C/g%3E%3C/svg%3E");
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 60px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform: translate(-50%, -50%);
    z-index: 1;
    filter: brightness(10.5);
}

.product-gallery-thumbnail--video .product-gallery-thumbnail-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
}

.product-gallery-thumbnail-play-icon {
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #333;
}

/* Fullscreen Modal */
.product-gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
}

.product-gallery-modal.is-active {
    display: block;
}

.product-gallery-modal__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
}

.product-gallery-modal__content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.product-gallery-modal__close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
    z-index: 10;
}

.product-gallery-modal__close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.product-gallery-modal__slider {
    width: 100%;
    max-width: 90vw;
    max-height: 90vh;
}

.product-gallery-modal-slide {
    position: relative;
    width: 100%;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-gallery-modal-slide--video {
    background: #000;
}

.product-gallery-modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Modal Navigation */
.product-gallery-modal .splide__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease;
    z-index: 2;
}

.product-gallery-modal .splide__arrow:hover {
    background: rgba(255, 255, 255, 0.2);
}

.product-gallery-modal .splide__arrow--prev {
    left: 20px;
}

.product-gallery-modal .splide__arrow--next {
    right: 20px;
}

/* Video Extension Styles */
.splide__video__wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    background: #000;
}

.splide__video__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #333;
    transition: all 0.3s ease;
    z-index: 1;
}

.splide__video__play:hover {
    background: white;
    transform: translate(-50%, -50%) scale(1.1);
}

.splide__video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.splide__track--nav>.splide__list>.splide__slide,
.splide__track--nav>.splide__list>.splide__slide.is-active {
    border: 0;
}

.product-detail__images .splide__arrow--prev svg,
.product-gallery-modal__content .splide__arrow--prev svg {
    transform: scaleX(1);
}

.product-detail__images .splide__arrow {
    width: 2rem;
    height: 2rem;
}

.product-detail__images .splide__arrow svg {
    width: 1.5rem;
    height: 1.5rem;
}
/* Responsive Design */
@media (max-width: 768px) {
    .product-gallery-splide .splide__arrow {
        width: 36px;
        height: 36px;
    }

    .product-gallery-splide .splide__arrow svg {
        width: 16px;
        height: 16px;
    }

    .product-gallery-modal__close {
        top: 10px;
        right: 10px;
        width: 36px;
        height: 36px;
    }

    .product-gallery-modal .splide__arrow {
        width: 40px;
        height: 40px;
    }

    .product-gallery-modal .splide__arrow--prev {
        left: 10px;
    }

    .product-gallery-modal .splide__arrow--next {
        right: 10px;
    }

    .splide__video__play {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .product-gallery-modal__content {
        padding: 1rem;
    }

    .product-gallery-modal-slide {
        height: 70vh;
    }
}