/*
=====================================
VIDEO COMPONENTS STYLES
=====================================
*/

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--space-xl);
    margin-top: var(--space-2xl);
}

.video-card {
    background: var(--color-bg-primary);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.video-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(255, 255, 255, 0.1);
}

.video-thumbnail {
    width: 100%;
    height: 200px;
    background-color: var(--color-bg-dark);
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.play-button {
    width: 60px;
    height: 60px;
    background: hsla(var(--neutral-light-h), var(--neutral-light-s), var(--neutral-light-l), 0.85);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-interactive);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.video-card:hover .play-button {
    background: var(--color-interactive-primary);
    transform: scale(1.15);
    box-shadow: var(--color-interactive-primary), var(--color-interactive-primary);
    border-color: rgba(255, 255, 255, 0.3);
}

.video-info {
    padding: var(--space-lg);
}

.video-title {
    font-weight: 600;
    margin-bottom: var(--space-xs);
    color: var(--color-text-primary);
}

.video-description {
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
    margin-bottom: 0;
}

/* Modal / Lightbox */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: hsla(var(--neutral-dark-h), var(--neutral-dark-s), var(--neutral-dark-l), 0.9);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: var(--space-md);
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--color-bg-primary);
    border-radius: var(--border-radius-lg);
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
}

.modal-video {
    width: 100%;
    height: 450px;
    background: var(--space);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--paper);
}

.modal-info {
    padding: var(--space-lg);
}

.modal-close {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-size: var(--font-size-lg);
    transition: background 0.3s ease;
}

.modal-close:hover {
    background: var(--accent);
    color: var(--ink);
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
}

@media (max-width: 480px) {
    .video-card {
        margin: 0 calc(-1 * var(--space-sm));
    }
}

@media (max-width: 600px) {
    .modal-content {
        max-width: calc(100% - 2 * var(--space-md));
        border-radius: var(--border-radius);
    }

    .modal-video {
        height: min(56vw, 320px);
    }

    .modal-info {
        padding: var(--space-md);
    }

    .modal-close {
        top: var(--space-sm);
        right: var(--space-sm);
    }
}