/* Video Section Styles */
.video-section {
    padding: 5rem 2rem;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.video-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.video-block {
    background: white;
    padding: 2.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-left: 5px solid #2d5aa0;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    margin: 0 auto;
    max-width: 600px;
}

.video-title {
    text-align: left;
    color: #2d5aa0;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.video-subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 3rem;
}

.single-video-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.single-video-card {
    display: block;
    max-width: 420px;
    width: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    background: linear-gradient(145deg, #f8f9fa, #ffffff);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.12), 0 3px 8px rgba(0,0,0,0.08);
    border: 2px solid #e8eef7;
}

.single-video-card:hover {
    transform: translateY(-8px);
}

.single-video-image {
    overflow: hidden;
    height: 480px;
    width: 100%;
    max-width: 340px;
    margin: 0 auto;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
}

.single-video-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.single-video-card:hover .single-video-image img {
    transform: scale(1.05);
    filter: brightness(0.8);
}

.play-button-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100;
    pointer-events: none;
}

.play-button-overlay i {
    font-size: 70px !important;
    color: white;
    text-shadow: 0 8px 30px rgba(0,0,0,0.8);
    transition: all 0.3s ease;
    display: block;
}

.single-video-card:hover .play-button-overlay i {
    transform: scale(1.2);
    color: #2d5aa0;
    text-shadow: 0 8px 30px rgba(45, 90, 160, 0.8);
}

.single-video-content {
    padding: 1.5rem 0;
    text-align: center;
}

/* Lego Brick Styles */
.video-lego-brick {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.video-lego-brick i {
    font-size: 24px;
    color: white;
}

.single-video-card:hover .video-lego-brick {
    transform: scale(1.1) rotate(5deg);
}

/* Lego Brick Colors */
.video-lego-red {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.video-lego-blue {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.video-lego-yellow {
    background: linear-gradient(135deg, #f1c40f 0%, #f39c12 100%);
}

.video-lego-green {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
}

.video-lego-orange {
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
}

.video-lego-purple {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

.video-lego-dark-blue {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
}

.single-video-content h4 {
    color: #333;
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.single-video-content p {
    color: #666;
    font-size: 1rem;
}

.watch-link {
    margin-top: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #2d5aa0;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Video Modal Styles with Smooth Animations */
.video-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    transition: background-color 0.4s ease;
}

.video-modal.active {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.9);
}

.video-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: center;
    transform: translate(-50%, -50%) scale(0.7);
    background-color: #1a1a1a;
    padding: 20px;
    border-radius: 15px;
    max-width: 90%;
    max-height: 90vh;
    width: 500px;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.video-modal.active .video-modal-content {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.video-modal.closing .video-modal-content {
    transform: translate(-50%, -50%) scale(0.7);
    opacity: 0;
}

.video-modal.closing {
    background-color: rgba(0, 0, 0, 0);
}

.video-modal-close {
    position: absolute;
    top: -15px;
    right: -15px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    background: #2d5aa0;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 10000;
}

.video-modal-close:hover {
    background: #1e3c6e;
    transform: rotate(180deg) scale(1.1);
}

.video-modal-header {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.video-modal-header h3 {
    color: white;
    margin: 0;
    font-size: 1.5rem;
}

.video-modal-header h3 i {
    color: #2d5aa0;
    margin-right: 10px;
}

.video-modal-player {
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    background: black;
}

.video-modal-player video {
    width: 100%;
    height: auto;
    max-height: 75vh;
    display: block;
    aspect-ratio: 9/16;
    object-fit: contain;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .video-block {
        max-width: 500px;
        padding: 2rem;
    }

    .video-modal-content {
        max-width: 95%;
        width: 420px;
        padding: 15px;
    }

    .video-modal-header h3 {
        font-size: 1.2rem;
    }

    .video-modal-close {
        top: -10px;
        right: -10px;
        width: 35px;
        height: 35px;
        font-size: 30px;
    }

    .video-modal-player video {
        max-height: 70vh;
    }

    .play-button-overlay i {
        font-size: 90px !important;
    }
}

@media (max-width: 576px) {
    .video-section {
        padding: 3rem 1rem;
    }

    .video-block {
        max-width: 100%;
        padding: 1.5rem;
    }

    .single-video-card {
        max-width: 340px;
    }

    .single-video-image {
        height: 420px;
        max-width: 280px;
    }

    .play-button-overlay i {
        font-size: 60px !important;
    }
    
    .single-video-content h4 {
        font-size: 1.1rem;
    }

    .video-modal-content {
        width: 95%;
        max-width: 380px;
    }

    .video-modal-player video {
        max-height: 65vh;
    }
}