/* ? video-gallery */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
:root {
    --accent-color: #fd950e;
    --color-white: #fff;
    --color-gray: #a8a8a8;
    --bg-color: #202020;
    --transition: all 0.2s ease;
    --index: calc(1vw + 1vh);
}

ul,
ol,
li {
    list-style: none;
    padding: 0;
    margin: 0;
}
.video-gallery a {
    display: flex;
    height: 100%;
    text-decoration: none;
    color: inherit;
    -webkit-tap-highlight-color: transparent;
    transition: var(--transition);
}
.video-gallery img {
    display: block;
    object-fit: cover;
    max-width: 100%;
    height: auto;
}
.video-gallery button,
.videotube-modal-overlay button {
    font-family: inherit;
    font-style: normal;
    font-weight: inherit;
    color: inherit;
    border: none;
    background: none;
    outline: none;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: var(--transition);
}
.video-gallery button:hover,
.video-gallery button:focus,
.video-gallery button:active,
.videotube-modal-overlay button:hover,
.videotube-modal-overlay button:focus,
.videotube-modal-overlay button:active {
    outline: none;
}
.gallery {
    /* min-height: 800px; */
    padding-bottom: 100px;
}
.video-gallery {
    display: flex;
    /* justify-content: center; */
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
    width: 100%;
    margin: 0 0 30px;
}
.video-gallery::before,
.video-gallery::after {
    display: none;
}
.video-gallery__item {
    width: 260px;
    height: 260px;
    border: 2px solid var(--color-gray);
    position: relative;
    cursor: pointer;
    transition: var(--transition);

    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

.video-gallery__item circle {
    transition: var(--transition);
}
.video-gallery__item:hover circle {
    fill: var(--accent-color);
}
.video-gallery__item-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* ? modal-video-gallery */
.videotube-modal-overlay {
    color: #fff;
    display: none;
    z-index: 995;
    opacity: 0;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    position: fixed;
    background: var(--bg-color);
    text-align: center;
    user-select: none;
}

#videotube-modal-container {
    z-index: 998;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

#videotube-modal {
    text-align: center;
    box-shadow: 0 0 40px #333;
}

#videotube-modal-loading {
    position: fixed;
    z-index: 997;
    font-size: 1.5em;
    top: 49%;
    width: 5%;
    text-align: center;
    left: 45%;
}

#videotube-modal-close {
    position: fixed;
    right: 15px;
    top: 15px;
    padding: 3px 13px;
    z-index: 999;
    font-size: 25px;
    text-shadow: 0 0 10px #fff;
    border-radius: 3px;
    cursor: pointer;
    -webkit-transition-duration: 0.1s;
    -o-transition-duration: 0.1s;
    -moz-transition-duration: 0.1s;
    transition-duration: 0.1s;
}

.modal-video__btn-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 18px;
    height: 18px;
    display: block;
}
.modal-video__btn-close:hover path {
    stroke: var(--accent-color);
}

@media (max-width: 1200px) {
    .video-gallery {
        justify-content: center;
    }
}

/* ? animation .video-gallery__item */
.video-gallery__item {
    opacity: 0;
    transform: scale(0);
    animation: anim-video-item 1s ease calc(var(--i) * 0.1s) forwards;
}
@keyframes anim-video-item {
    0% {
        opacity: 0;
        transform: scale(0);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}
