/* Theater Mode */
.anime__video__player.theater-mode {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    border-radius: 0;
    background: #000;
}

.anime__video__player.theater-mode iframe,
.anime__video__player.theater-mode .plyr {
    height: 100vh !important;
}

/* Cinematic Player Aspect Ratio */
.anime__video__player {
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Source Selector & Control Panel */
.source-btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.source-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.source-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.source-btn.active {
    background: #e53637;
    border-color: #e53637;
    box-shadow: 0 0 20px rgba(229, 54, 55, 0.4);
}

#theater-mode.active i {
    color: #e53637;
}

/* Custom Plyr Theme Colors */
:root {
    --plyr-color-main: #e53637;
    --plyr-video-background: #000;
    --plyr-menu-background: rgba(11, 12, 42, 0.95);
    --plyr-menu-color: #fff;
}

/* Episode List Styling */
#episode-list {
    max-height: 400px;
    overflow-y: auto;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

#episode-list a {
    display: inline-block;
    padding: 10px 15px;
    margin: 5px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
    transition: all 0.3s;
}

#episode-list a:hover {
    background: #e53637;
    transform: scale(1.05);
}

/* Hero Video Background */
.hero-video-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    opacity: 0.3;
}

.hero-video-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.9));
    z-index: 1;
}

.hero-video-bg iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 100vh;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

/* Premium Source Buttons */
.glass-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    backdrop-filter: blur(8px);
    outline: none !important;
}

.glass-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.glass-btn.active {
    background: #e53637;
    border-color: #e53637;
    box-shadow: 0 0 20px rgba(229, 54, 55, 0.5);
}

/* Premium Episode Grid */
.episode-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    max-height: 500px;
    overflow-y: auto;
    padding-right: 5px;
}

.ep-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.ep-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.ep-card.active-ep {
    border-color: #e53637;
    background: rgba(229, 54, 55, 0.1);
}

.ep-thumb {
    height: 110px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.ep-num {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
}

.ep-play {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.3s;
}

.ep-card:hover .ep-play {
    opacity: 1;
}

.ep-play i {
    font-size: 24px;
    color: #fff;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.ep-meta {
    padding: 10px;
}

.ep-meta h6 {
    font-size: 14px;
    margin-bottom: 4px;
    line-height: 1.3;
}