/**
 * Netflix-Style Video Series CSS
 * Cinematic, immersive, and responsive.
 */



.video-section {
    /*background: #f7fafc;*/
    color: #1a202c;
    padding: 60px 0;
    overflow: hidden;
    min-height: 100vh;
}

body.dark .video-section {
    background: #141414;
    color: #fff;
}

body.dark .episode-card {
    background: rgba(255, 255, 255, 0.03);
    border-color: transparent;
}

body.dark .episode-card.active {
    background: rgba(230, 126, 34, 0.15);
    border-color: #E67E22;
}

body.dark .episode-card:hover {
    background: rgba(255, 255, 255, 0.08);
}

body.dark .episode-card-mini {
    background: #181818;
    border-color: transparent;
}

.video-section .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4%;
}

/* 1. Hero Flex Layout */
.hero-flex-layout {
    display: flex;
    gap: 30px;
    margin-bottom: 50px;
    align-items: flex-start;
}

.episode-sidebar {
    flex: 0 0 320px;
    display: flex;
    flex-direction: column;
    height: 550px;
    /* Match player height approximately */
}

.episode-list {
    flex: 1;
    overflow-y: auto;
    padding-left: 10px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Custom Scrollbar for Sidebar */
.episode-list::-webkit-scrollbar {
    width: 6px;
}

.episode-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.episode-list::-webkit-scrollbar-thumb {
    background: #E67E22;
    border-radius: 10px;
}

.hero-main-player {
    flex: 1;
    min-width: 0;
}

/* Cinematic Hero Player */
.video-hero-container {
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    position: relative;
    aspect-ratio: 16/9;
}

.hero-cover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    cursor: pointer;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.5s ease;
}

.hero-cover:hover {
    transform: scale(1.02);
}

.play-overlay {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    transition: all 0.3s ease;
}

.play-overlay i {
    font-size: 40px;
    color: #fff;
    margin-left: 5px;
}

.hero-cover:hover .play-overlay {
    background: #E67E22;
    border-color: #E67E22;
    transform: scale(1.1);
}

.hero-player-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hero-player-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.hero-meta {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 40px 30px;
    background: linear-gradient(to top, rgba(20, 20, 20, 0.9), rgba(20, 20, 20, 0));
    z-index: 10;
    pointer-events: none;
}

.hero-series-name {
    font-size: 42px;
    font-weight: 800;
    margin: 0;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-branding {
    display: inline-block;
    color: #E67E22;
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

/* 2. Episode Cards (Sidebar Style) */
.episode-row-title {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.episode-row-title i {
    color: #E67E22;
}

.episode-card {
    display: flex;
    gap: 12px;
    padding: 8px;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #edf2f7;
}

.episode-card.active {
    background: rgba(230, 126, 34, 0.1);
    border-color: #E67E22;
}

.episode-card:hover {
    background: rgba(255, 255, 255, 0.08);
}

.episode-thumb {
    flex: 0 0 120px;
    aspect-ratio: 16/9;
    background-size: cover;
    background-position: center;
    border-radius: 4px;
}

.episode-info {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
}

.episode-name {
    font-size: 15px;
    margin: 0;
    color: #1a202c;
    line-height: 1.3;
}

body.dark .episode-name {
    color: #fff;
}

/* 3. Archive Tray (Bottom) */
.other-series-tray {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding-bottom: 20px;
    scrollbar-width: thin;
}

.episode-card-mini {
    flex: 0 0 280px;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #edf2f7;
    transition: transform 0.3s ease;
}

.episode-card-mini:hover {
    transform: translateY(-5px);
}

.episode-card-mini .episode-thumb {
    width: 100%;
}

.episode-card-mini .episode-info {
    padding: 12px;
}

/* 4. Small Screen Optimizations */
@media (max-width: 992px) {
    .video-section .container {
        padding: 0 15px !important;
        /* Force override */
    }

    .hero-flex-layout {
        flex-direction: column;
        gap: 20px;
        align-items: stretch !important;
        /* Force children to take full width */
    }

    .episode-sidebar {
        flex: none;
        width: 100% !important;
        height: auto;
    }

    .hero-main-player {
        width: 100% !important;
        flex: none;
    }

    .episode-list {
        flex-direction: row;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 15px;
        height: auto;
        gap: 12px;
        scrollbar-width: none;
    }

    .episode-list::-webkit-scrollbar {
        display: none;
    }

    .episode-card {
        flex: 0 0 180px;
        flex-direction: column;
        padding: 8px;
    }

    .episode-thumb {
        flex: none;
        width: 100%;
        margin-bottom: 8px;
    }

    .hero-series-name {
        font-size: 24px;
    }

    .video-hero-container {
        width: 100% !important;
        aspect-ratio: 16/9;
    }
}

@media (max-width: 600px) {
    .play-overlay {
        width: 60px;
        height: 60px;
    }

    .play-overlay i {
        font-size: 24px;
    }

    .hero-meta {
        padding: 15px;
        background: linear-gradient(to top, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0));
    }

    .hero-series-name {
        font-size: 18px;
        line-height: 1.2;
    }

    .hero-branding {
        font-size: 14px;
        margin-bottom: 5px;
    }

    .episode-card {
        flex: 0 0 150px;
    }

    .video-hero-container {
        margin-bottom: 25px;
        border-radius: 8px;
    }
}