/* Video Gallery Module CSS */

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* Video Card */
.video-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: none;
}

.video-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Video Thumbnail */
.video-thumbnail {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
    background: #000;
}

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

.video-card:hover .video-image {
    transform: scale(1.05);
}

/* Video Play Button */
.video-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(220, 53, 69, 0.9);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    cursor: pointer;
    z-index: 2;
}

.video-play-btn:hover {
    background: var(--primary-color);
    transform: translate(-50%, -50%) scale(1.1);
}

.video-play-btn i {
    margin-left: 2px; /* Play icon alignment */
}

/* Video Duration */
.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 2;
}

/* Video Content */
.video-content {
    padding: 1.25rem;
}

.video-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.video-title a:hover {
    color: var(--primary-color);
}

.video-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.video-meta .news-date,
.video-meta .news-views {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Video Overlay Effects */
.video-thumbnail::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        transparent 60%,
        rgba(0, 0, 0, 0.3) 100%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.video-card:hover .video-thumbnail::before {
    opacity: 1;
}

/* Dark Mode */
body.dark-mode .video-card {
    background: var(--card-bg);
    border-color: #404040;
}

body.dark-mode .video-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Responsive Design */
@media (max-width: 991.98px) {
    .video-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 1.25rem;
    }
    
    .video-content {
        padding: 1rem;
    }
    
    .video-play-btn {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }
}

@media (max-width: 575.98px) {
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    .video-content {
        padding: 1rem;
    }
    
    .video-title {
        font-size: 0.95rem;
    }
    
    .video-meta {
        font-size: 0.75rem;
    }
}