/* Main wrapper to contain carousel and navigation */
.vcarousel-wrapper {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
    overflow: hidden;
}

/* Swiper container style */
.vcarousel-container {
    width: 100%;
    height: auto;
    padding-bottom: 50px; /* Space for pagination */
}

/* Video item container for lazy-loading and aspect ratio */
.vcarousel-item {
    position: relative;
    width: 100%;
    height: 0;
    padding-top: 56.25%; /* 16:9 Aspect Ratio (9 / 16 * 100%) */
    background-color: #000;
    cursor: pointer;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.vcarousel-item:hover {
    transform: scale(1.03);
}

/* Thumbnail and iframe styles */
.vcarousel-thumbnail,
.vcarousel-item iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.vcarousel-thumbnail {
    background-size: cover;
    background-position: center;
    transition: filter 0.3s ease;
}

.vcarousel-thumbnail:hover {
    filter: brightness(0.8);
}

/* Play button overlay */
.vcarousel-play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.vcarousel-item:hover .vcarousel-play-button {
    transform: translate(-50%, -50%) scale(1.1);
    background-color: rgba(255, 0, 0, 0.8);
}

.vcarousel-play-button svg {
    width: 30px;
    height: 30px;
    margin-left: 5px; /* Adjust for triangular shape */
}

/* Navigation buttons (optional) */
.swiper-button-next.vcarousel-btn-next,
.swiper-button-prev.vcarousel-btn-prev {
    color: #fff;
    background-color: rgba(0, 0, 0, 0.5);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    top: calc(50% - 20px);
    transition: background-color 0.3s ease;
}

.swiper-button-next.vcarousel-btn-next:hover,
.swiper-button-prev.vcarousel-btn-prev:hover {
    background-color: rgba(0, 0, 0, 0.8);
}
.swiper-button-next.vcarousel-btn-next:after,
.swiper-button-prev.vcarousel-btn-prev:after {
    font-size: 18px;
}

/* Swiper Breakpoints */
/* Mobile: 1 video per slide */
.vcarousel-container .swiper-slide {
    width: 100%;
}

/* Tablet: 2 videos per slide */
@media (min-width: 768px) {
    .vcarousel-container .swiper-slide {
        width: 50%;
    }
}

/* Desktop: 3 videos per slide */
@media (min-width: 1024px) {
    .vcarousel-container .swiper-slide {
        width: 33.333%;
    }
}
