.SpyG-gallery {
    overflow: hidden;
    text-align: center
}

.SpyG-slides-wrap {
    position: relative;
    width: 100%;
    height: 100%;
    perspective: 1000px;
    overflow: visible;
    text-align: center;
    transform-style: preserve-3d;
    transform: perspective(1000px)
}

.SpyG-slide {
    top: 0;
    left: 0;
    position: absolute;
    transform-origin: center center;
    text-align: center;
    display: inline-block;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center center;
    will-change: transform;
    cursor: zoom-in
}

.SpyG-slide canvas {
    width: 100%;
    height: 100%;
    text-align: center
}

.SpyG-slide.pop {
    opacity: 1;
    animation: pop .3s 1;
    transform: scale(1) translateZ(-3000px)
}

@keyframes pop {
    0% {
        background-size: 0 0
    }

    to {
        background-size: 100% 100%
    }
}

.spyG-overlay {
    contain: size;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    justify-content: center;
    align-items: center;
    background-color: #000c;
    z-index: 9999;
    cursor: pointer
}

.spyG-overlay canvas {
    max-width: 100%;
    max-height: 100%
}

.SpyG-close {
    font-size: 46px;
    font-weight: 700;
    transform: rotate(45deg);
    color: #fff;
    background-color: #000;
    width: 50px;
    height: 50px;
    text-align: center;
    line-height: 50px;
    border-radius: 100%;
    position: fixed;
    left: calc(97% - 15px);
    top: 15px;
    cursor: pointer
}

@media (max-width: 768px) {
    .SpyG-slide.pop {
        transform: scale(1) translateZ(-5000px)
    }

    .zoomCopy canvas {
        height: auto
    }

    .bg_zoom {
        background-color: #fff
    }

    .bg_zoom .SpyG-slide {
        margin-top: 15px;
        width: 90%;
        max-height: none;
        background-position: top
    }

    .bg_zoom .SpyG-slide canvas {
        max-height: none;
        top: 0;
        width: 100%
    }

    .SpyG-slide canvas {
        max-height: 600px
    }

    .SpyG-close {
        left: auto;
        right: 15px;
        top: auto;
        bottom: 15px;
        z-index: 1000000
    }
}