/* EcoSupp Social Videos Carousel Widget Styles */
/* File: assets/css/social-videos.css */

.ecosupp-social-videos-wrapper {
    width: 100%;
    position: relative;
}

/* Video Container */
.video-item {
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.video-container {
    position: relative;
    width: 100%;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Video Format Controls */
.video-format-landscape {
    aspect-ratio: 16/9;
}

.video-format-portrait {
    aspect-ratio: 9/16;
}

.video-format-square {
    aspect-ratio: 1/1;
}

.video-format-auto {
    height: auto;
}

/* Video Thumbnail */
.video-thumbnail {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-container:hover .video-thumbnail img {
    transform: scale(1.05);
}

/* Video Overlay */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-container:hover .video-overlay {
    opacity: 1;
}

/* Play Button */
.play-button {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 24px;
    transition: all 0.3s ease;
}

.play-button:hover {
    background: #fff;
    transform: scale(1.1);
}

/* Platform Icon */
.platform-icon {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 14px;
    z-index: 2;
}

.platform-youtube {
    background: rgba(255, 0, 0, 0.9);
}

.platform-facebook {
    background: rgba(24, 119, 242, 0.9);
}

.platform-instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.platform-tiktok {
    background: rgba(0, 0, 0, 0.9);
}

/* Video Info */
.video-info {
    padding: 15px 0;
    text-align: center;
}

.video-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0 0 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-description {
    font-size: 14px;
    color: #666;
    margin: 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Carousel Navigation */
.social-videos-carousel .swiper-button-prev,
.social-videos-carousel .swiper-button-next {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-top: 0;
}

.social-videos-carousel .swiper-button-prev:hover,
.social-videos-carousel .swiper-button-next:hover {
    background: #fff;
    transform: scale(1.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.social-videos-carousel .swiper-button-prev::after,
.social-videos-carousel .swiper-button-next::after {
    display: none;
}

.social-videos-carousel .swiper-button-prev i,
.social-videos-carousel .swiper-button-next i {
    font-size: 20px;
}

.social-videos-carousel .swiper-button-prev {
    left: 20px;
}

.social-videos-carousel .swiper-button-next {
    right: 20px;
}

/* Pagination */
.social-videos-carousel .swiper-pagination {
    position: relative;
    bottom: 0;
    margin-top: 30px;
}

.social-videos-carousel .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background: #ddd;
    opacity: 1;
    margin: 0 4px !important;
    transition: all 0.3s ease;
}

.social-videos-carousel .swiper-pagination-bullet-active {
    background: #333;
    width: 24px;
    border-radius: 4px;
}

/* Loading State */
.video-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    background: #f5f5f5;
    border-radius: 8px;
}

.video-loading::after {
    content: '';
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #333;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .video-container {
        border-radius: 6px;
    }
    
    .play-button {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    .platform-icon {
        width: 25px;
        height: 25px;
        font-size: 12px;
        top: 8px;
        right: 8px;
    }
    
    .video-title {
        font-size: 14px;
    }
    
    .video-description {
        font-size: 13px;
    }
    
    .video-info {
        padding: 12px 0;
    }
    
    .social-videos-carousel .swiper-button-prev,
    .social-videos-carousel .swiper-button-next {
        width: 40px;
        height: 40px;
    }
    
    .social-videos-carousel .swiper-button-prev i,
    .social-videos-carousel .swiper-button-next i {
        font-size: 16px;
    }
    
    .social-videos-carousel .swiper-button-prev {
        left: 10px;
    }
    
    .social-videos-carousel .swiper-button-next {
        right: 10px;
    }
}

@media (max-width: 480px) {
    .video-info {
        padding: 10px 0;
    }
    
    .video-title {
        font-size: 13px;
        margin-bottom: 6px;
    }
    
    .video-description {
        font-size: 12px;
    }
}

/* WoodMart Theme Compatibility */
.woodmart-dark .video-title {
    color: #fff;
}

.woodmart-dark .video-description {
    color: #ccc;
}

.woodmart-dark .social-videos-carousel .swiper-pagination-bullet {
    background: #666;
}

.woodmart-dark .social-videos-carousel .swiper-pagination-bullet-active {
    background: #fff;
}

.woodmart-dark .social-videos-carousel .swiper-button-prev,
.woodmart-dark .social-videos-carousel .swiper-button-next {
    background: rgba(42, 42, 42, 0.9);
    color: #fff;
}

.woodmart-dark .social-videos-carousel .swiper-button-prev:hover,
.woodmart-dark .social-videos-carousel .swiper-button-next:hover {
    background: #2a2a2a;
}

/* RTL Support */
.rtl .platform-icon {
    right: auto;
    left: 10px;
}

.rtl .social-videos-carousel .swiper-button-prev {
    right: 20px;
    left: auto;
}

.rtl .social-videos-carousel .swiper-button-next {
    left: 20px;
    right: auto;
}

/* Lightbox Integration */
.video-lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.video-lightbox-overlay.active {
    opacity: 1;
    visibility: visible;
}

.video-lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

.video-lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    width: 30px;
    height: 30px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #333;
    font-size: 16px;
    transition: all 0.3s ease;
}

.video-lightbox-close:hover {
    background: #f0f0f0;
    transform: scale(1.1);
}