/* ==========================================================================
   Netflix-Style Fullscreen Video Player (Indistinguishable Netflix Web Player UI/UX)
   ========================================================================== */

:root {
    --nflx-red: var(--bs-primary, #E50914);
    --nflx-bg: #000000;
    --nflx-text-main: #FFFFFF;
    --nflx-text-sub: #B3B3B3;
    --nflx-track-bg: rgba(255, 255, 255, 0.25);
    --nflx-buffer-bg: rgba(255, 255, 255, 0.45);
}

/* --- Document & Viewport Reset --- */
html, body.netflix-player-body {
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    background-color: var(--nflx-bg) !important;
    color: var(--nflx-text-main) !important;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    user-select: none;
    -webkit-user-select: none;
}

/* --- Main Player Container --- */
#netflix-player-container {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    background-color: var(--nflx-bg);
    overflow: hidden;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Inactivity Auto-Hide: Fades controls and hides mouse cursor */
#netflix-player-container.nflx-idle {
    cursor: none !important;
}

#netflix-player-container.nflx-idle .nflx-top-bar,
#netflix-player-container.nflx-idle .nflx-bottom-bar,
#netflix-player-container.nflx-idle .nflx-skip-intro-btn,
#netflix-player-container.nflx-idle .nflx-binge-card {
    opacity: 0 !important;
    pointer-events: none !important;
}

/* --- Video Element & Video.js Overrides --- */
.nflx-video-stage {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

.nflx-video-element,
.nflx-video-stage video,
.nflx-video-stage .video-js,
.nflx-video-stage iframe {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain;
    border: 0;
    outline: none;
    background-color: #000;
}

/* Hide default Video.js control bar so Netflix controls are exclusively used */
.nflx-video-stage .vjs-control-bar,
.nflx-video-stage .vjs-big-play-button {
    display: none !important;
}

/* --- Clickable Screen Overlay --- */
.nflx-click-surface {
    position: absolute;
    inset: 0;
    z-index: 20;
    cursor: pointer;
}

/* --- Center Animated Play/Pause Ripple Indicator --- */
.nflx-center-indicator {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.6);
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.65);
    border: 2px solid rgba(255, 255, 255, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 42px;
    color: #ffffff;
    opacity: 0;
    pointer-events: none;
    z-index: 35;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.nflx-center-indicator.nflx-pop {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.15);
}

/* Seek feedback cues (10s back/forward) */
.nflx-seek-cue {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    opacity: 0;
    pointer-events: none;
    z-index: 35;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.nflx-seek-cue.cue-left {
    left: 15%;
    transform: translateY(-50%) translateX(-20px);
}

.nflx-seek-cue.cue-right {
    right: 15%;
    transform: translateY(-50%) translateX(20px);
}

.nflx-seek-cue.nflx-pop {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

.nflx-seek-cue i {
    font-size: 48px;
    margin-bottom: 4px;
}

.nflx-seek-cue span {
    font-size: 15px;
    font-weight: 700;
}

/* Buffering Spinner */
.nflx-buffering {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    border: 4px solid rgba(255, 255, 255, 0.15);
    border-top-color: var(--nflx-red);
    border-radius: 50%;
    animation: nflx-spin 0.8s linear infinite;
    z-index: 30;
    display: none;
    pointer-events: none;
}

@keyframes nflx-spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* --- Top Header Bar --- */
.nflx-top-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100px;
    padding: 24px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 50;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.6) 45%, transparent 100%);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.nflx-top-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nflx-back-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s ease;
    outline: none;
    padding: 0;
}

.nflx-back-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.1);
}

.nflx-title-wrap {
    display: flex;
    flex-direction: column;
}

.nflx-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nflx-title {
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    line-height: 1.2;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
}

.nflx-vj-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 12px;
    background: var(--nflx-red);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.nflx-vj-badge i {
    font-size: 13px;
}

.nflx-subtitle {
    font-size: 14px;
    color: var(--nflx-text-sub);
    margin-top: 3px;
    font-weight: 500;
}

.nflx-top-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nflx-meta-pill {
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 4px;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 700;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(0, 0, 0, 0.4);
}

/* --- Bottom Control Bar --- */
.nflx-bottom-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0 40px 28px 40px;
    z-index: 50;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.96) 0%, rgba(0, 0, 0, 0.65) 55%, transparent 100%);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

/* Scrubber / Progress Bar */
.nflx-scrubber-container {
    position: relative;
    width: 100%;
    padding: 14px 0;
    cursor: pointer;
    touch-action: none;
    -webkit-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

/* Invisible extended hit area for touchscreens */
.nflx-scrubber-container::before {
    content: '';
    position: absolute;
    top: -14px;
    bottom: -14px;
    left: 0;
    right: 0;
    z-index: 1;
}

.nflx-scrubber-track {
    position: relative;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: var(--nflx-track-bg);
    transition: height 0.15s ease;
    pointer-events: none;
}

.nflx-scrubber-container:hover .nflx-scrubber-track,
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-track {
    height: 8px;
}

.nflx-scrubber-buffer {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-radius: 2px;
    background: var(--nflx-buffer-bg);
    pointer-events: none;
    width: 0%;
    transition: width 0.2s ease;
}

.nflx-scrubber-played {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-radius: 2px;
    background: var(--nflx-red);
    pointer-events: none;
    width: 0%;
}

.nflx-scrubber-thumb {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(-50%, -50%) scale(0);
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--nflx-red);
    box-shadow: 0 0 10px rgba(229, 9, 20, 0.85), 0 0 0 2px rgba(255, 255, 255, 0.3);
    pointer-events: none;
    transition: transform 0.15s ease;
}

.nflx-scrubber-container:hover .nflx-scrubber-thumb,
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-thumb {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* Disable transitions during active dragging for immediate 60fps response */
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-played,
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-thumb,
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-tooltip {
    transition: none !important;
}

/* Floating Hover & Scrub Tooltip */
.nflx-scrubber-tooltip {
    position: absolute;
    bottom: 26px;
    left: 0%;
    transform: translateX(-50%);
    background: rgba(16, 16, 16, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    padding: 4px 10px;
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, visibility 0.15s ease;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
    z-index: 10;
}

.nflx-scrubber-container:hover .nflx-scrubber-tooltip,
.nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Controls Row */
.nflx-controls-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    gap: 16px;
}

.nflx-controls-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nflx-controls-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Standard Player Button */
.nflx-btn {
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 26px;
    padding: 6px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.18s ease, color 0.18s ease, background-color 0.18s ease;
    outline: none;
    position: relative;
}

.nflx-btn:hover {
    color: var(--nflx-red);
    transform: scale(1.15);
}

.nflx-btn:active {
    transform: scale(0.95);
}

/* Play/Pause Button */
.nflx-play-btn {
    font-size: 32px;
}

/* 10s Rewind/Forward Button */
.nflx-seek-btn {
    position: relative;
    font-size: 28px;
}

.nflx-seek-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -46%);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: -0.5px;
    color: #ffffff;
    pointer-events: none;
}

/* Volume Slider Group */
.nflx-volume-group {
    display: flex;
    align-items: center;
    position: relative;
}

.nflx-volume-slider-wrap {
    width: 0;
    overflow: hidden;
    transition: width 0.25s ease, margin 0.25s ease;
    display: flex;
    align-items: center;
    margin-left: 0;
}

.nflx-volume-group:hover .nflx-volume-slider-wrap,
.nflx-volume-slider-wrap:focus-within {
    width: 80px;
    margin-left: 8px;
}

.nflx-volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.35);
    outline: none;
    cursor: pointer;
}

.nflx-volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ffffff;
    cursor: pointer;
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.5);
}

.nflx-volume-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ffffff;
    border: none;
    cursor: pointer;
}

/* Time Display */
.nflx-time-display {
    font-size: 14px;
    font-weight: 500;
    color: #e5e5e5;
    cursor: pointer;
    user-select: none;
    font-variant-numeric: tabular-nums;
    margin-left: 4px;
    transition: color 0.2s ease;
}

.nflx-time-display:hover {
    color: #ffffff;
}

/* Episodes Button (TV Shows) */
.nflx-episodes-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
}

.nflx-episodes-btn:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: #ffffff;
    transform: scale(1.05);
}

.nflx-episodes-btn i {
    font-size: 17px;
}

/* Speed Selector Badge */
.nflx-speed-btn {
    font-size: 13px;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 4px;
    padding: 3px 8px;
    color: #ffffff;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nflx-speed-btn:hover {
    border-color: var(--nflx-red);
    color: var(--nflx-red);
    transform: scale(1.08);
}

/* --- Floating Menus (Subtitles & Speed Dropdowns) --- */
.nflx-dropdown-menu {
    position: absolute;
    bottom: 45px;
    right: 0;
    background: rgba(18, 18, 18, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 8px 0;
    min-width: 160px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    display: none;
    z-index: 70;
}

.nflx-dropdown-menu.nflx-open {
    display: block;
}

.nflx-dropdown-item {
    padding: 8px 16px;
    font-size: 13px;
    color: #d1d1d1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.nflx-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.nflx-dropdown-item.nflx-selected {
    color: var(--nflx-red);
    font-weight: 700;
}

/* --- Skip Intro Button --- */
.nflx-skip-intro-btn {
    position: absolute;
    bottom: 96px;
    right: 40px;
    z-index: 60;
    background: rgba(20, 20, 20, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 10px 24px;
    border-radius: 4px;
    cursor: pointer;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}

.nflx-skip-intro-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #ffffff;
    transform: scale(1.05);
}

.nflx-skip-intro-btn.nflx-visible {
    display: flex;
}

/* --- Netflix Binge Mode Card (Next Episode in X Seconds) --- */
.nflx-binge-card {
    position: absolute;
    bottom: 100px;
    right: 40px;
    z-index: 60;
    width: 320px;
    background: rgba(18, 18, 18, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    display: none;
    flex-direction: column;
    animation: nflx-slide-up 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes nflx-slide-up {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.nflx-binge-card.nflx-visible {
    display: flex;
}

.nflx-binge-header {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nflx-binge-label {
    font-size: 13px;
    font-weight: 700;
    color: #e5e5e5;
}

.nflx-binge-timer {
    color: var(--nflx-red);
    font-weight: 800;
}

.nflx-binge-body {
    display: flex;
    padding: 12px 16px;
    gap: 12px;
    align-items: center;
}

.nflx-binge-thumb {
    width: 80px;
    height: 48px;
    object-fit: cover;
    border-radius: 4px;
    background: #222;
    flex-shrink: 0;
}

.nflx-binge-info {
    overflow: hidden;
}

.nflx-binge-ep-title {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nflx-binge-ep-num {
    font-size: 12px;
    color: var(--nflx-text-sub);
    margin-top: 2px;
}

.nflx-binge-actions {
    display: flex;
    padding: 0 16px 14px 16px;
    gap: 10px;
}

.nflx-binge-play-btn {
    flex: 1;
    background: #ffffff;
    color: #000000;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: background 0.15s ease;
}

.nflx-binge-play-btn:hover {
    background: #e6e6e6;
}

.nflx-binge-cancel-btn {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
}

.nflx-binge-cancel-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* --- Netflix TV Show Episodes Drawer / Modal --- */
.nflx-episodes-drawer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70vh;
    max-height: 520px;
    background: rgba(14, 14, 14, 0.98);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 -15px 45px rgba(0, 0, 0, 0.9);
    z-index: 80;
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nflx-episodes-drawer.nflx-open {
    transform: translateY(0);
}

.nflx-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 36px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nflx-season-select-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nflx-season-select {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    outline: none;
}

.nflx-season-select option {
    background: #181818;
    color: #ffffff;
}

.nflx-drawer-close-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #ffffff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, transform 0.15s ease;
}

.nflx-drawer-close-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

.nflx-drawer-body {
    flex: 1;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 20px 36px;
    display: flex;
    align-items: center;
    gap: 20px;
    scrollbar-width: thin;
    scrollbar-color: var(--nflx-red) transparent;
}

.nflx-drawer-body::-webkit-scrollbar {
    height: 6px;
}

.nflx-drawer-body::-webkit-scrollbar-thumb {
    background: var(--nflx-red);
    border-radius: 3px;
}

/* Episode Card inside Drawer */
.nflx-ep-card {
    flex: 0 0 260px;
    background: rgba(26, 26, 26, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease, box-shadow 0.25s ease;
    height: 100%;
    max-height: 340px;
    display: flex;
    flex-direction: column;
}

.nflx-ep-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.7);
}

.nflx-ep-card.nflx-current {
    border-color: var(--nflx-red);
    box-shadow: 0 0 15px rgba(229, 9, 20, 0.6);
}

.nflx-ep-thumb-wrap {
    position: relative;
    aspect-ratio: 16 / 9;
    width: 100%;
    overflow: hidden;
    background: #111;
}

.nflx-ep-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nflx-ep-current-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--nflx-red);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.nflx-ep-duration-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
}

.nflx-ep-card-body {
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
}

.nflx-ep-title {
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 4px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nflx-ep-desc {
    font-size: 12px;
    color: var(--nflx-text-sub);
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --- Locked / Paywall Screen (Unentitled Gated Content) --- */
.nflx-paywall-screen {
    position: absolute;
    inset: 0;
    z-index: 90;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.nflx-paywall-backdrop-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0.94) 80%, #000000 100%);
}

.nflx-paywall-content {
    position: relative;
    z-index: 2;
    max-width: 580px;
    padding: 40px;
    text-align: center;
    background: rgba(18, 18, 18, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
}

.nflx-paywall-icon {
    font-size: 48px;
    color: var(--nflx-red);
    margin-bottom: 16px;
}

.nflx-paywall-title {
    font-size: 28px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 8px 0;
}

.nflx-paywall-vj {
    font-size: 15px;
    color: var(--nflx-text-sub);
    margin-bottom: 18px;
}

.nflx-paywall-msg {
    font-size: 15px;
    color: #d1d1d1;
    line-height: 1.5;
    margin-bottom: 28px;
}

.nflx-paywall-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nflx-paywall-btn-primary {
    background: var(--nflx-red);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.2s ease, background 0.2s ease;
}

.nflx-paywall-btn-primary:hover {
    background: #c10711;
    transform: scale(1.02);
    color: #ffffff;
}

.nflx-paywall-btn-secondary {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s ease;
}

.nflx-paywall-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.nflx-paywall-back-btn {
    background: transparent;
    color: var(--nflx-text-sub);
    border: none;
    font-size: 14px;
    font-weight: 500;
    margin-top: 10px;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.15s ease;
}

.nflx-paywall-back-btn:hover {
    color: #ffffff;
}

/* --- Mobile Responsive Optimizations (< 768px) --- */
@media (max-width: 767.98px) {
    .nflx-top-bar {
        height: 80px;
        padding: 16px 20px;
    }

    .nflx-back-btn {
        width: 38px;
        height: 38px;
        font-size: 24px;
    }

    .nflx-title {
        font-size: 17px;
    }

    .nflx-subtitle {
        font-size: 12px;
    }

    .nflx-meta-pill {
        display: none;
    }

    .nflx-bottom-bar {
        padding: 0 20px 20px 20px;
    }

    /* Mobile-optimized timeline seeking */
    .nflx-scrubber-container {
        padding: 16px 0;
    }

    .nflx-scrubber-track {
        height: 5px;
    }

    .nflx-scrubber-container:hover .nflx-scrubber-track,
    .nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-track {
        height: 8px;
    }

    .nflx-scrubber-thumb {
        width: 18px;
        height: 18px;
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.95;
    }

    .nflx-scrubber-container.nflx-scrubbing .nflx-scrubber-thumb {
        transform: translate(-50%, -50%) scale(1.35);
        box-shadow: 0 0 14px rgba(229, 9, 20, 1), 0 0 0 3px rgba(255, 255, 255, 0.5);
    }

    .nflx-scrubber-tooltip {
        bottom: 30px;
        font-size: 12px;
        padding: 4px 8px;
    }

    .nflx-btn {
        font-size: 22px;
        padding: 6px;
    }

    .nflx-play-btn {
        font-size: 28px;
    }

    .nflx-seek-btn {
        font-size: 24px;
    }

    .nflx-volume-group {
        display: none; /* Mobile utilizes physical hardware volume keys */
    }

    .nflx-speed-btn {
        display: none;
    }

    .nflx-episodes-btn span {
        display: none;
    }

    .nflx-episodes-btn {
        padding: 6px 10px;
        border-radius: 50%;
    }

    .nflx-skip-intro-btn {
        bottom: 84px;
        right: 20px;
        padding: 8px 16px;
        font-size: 12px;
    }

    .nflx-binge-card {
        right: 16px;
        bottom: 84px;
        width: calc(100vw - 32px);
    }

    .nflx-episodes-drawer {
        height: 80vh;
        max-height: none;
    }

    .nflx-drawer-header {
        padding: 14px 20px;
    }

    .nflx-drawer-body {
        padding: 16px 20px;
        flex-direction: column;
        overflow-x: hidden;
        overflow-y: auto;
        align-items: stretch;
    }

    .nflx-ep-card {
        flex: 0 0 auto;
        flex-direction: row;
        height: 90px;
    }

    .nflx-ep-thumb-wrap {
        width: 120px;
        height: 100%;
        flex-shrink: 0;
    }

    .nflx-ep-desc {
        display: none;
    }
}

/* ==========================================================================
   Enforced Landscape Orientation Mode on Mobile & Tablet Screens
   ========================================================================== */
@media screen and (max-width: 1024px) and (orientation: portrait),
       screen and (max-device-width: 1024px) and (orientation: portrait) {
    html, body.netflix-player-body {
        position: fixed !important;
        width: 100vw !important;
        height: 100vh !important;
        overflow: hidden !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    #netflix-player-container {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        width: 100vh !important;
        width: 100dvh !important;
        height: 100vw !important;
        height: 100dvw !important;
        transform: translate(-50%, -50%) rotate(90deg) !important;
        transform-origin: center center !important;
        overflow: hidden !important;
        z-index: 999999 !important;
    }
}

@media screen and (orientation: landscape) {
    #netflix-player-container {
        transform: none !important;
        width: 100vw !important;
        height: 100vh !important;
        top: 0 !important;
        left: 0 !important;
    }
}

/* ==========================================================================
   Resolution / Quality Picker Styles
   ========================================================================== */
.nflx-quality-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 4px;
    padding: 3px 8px;
    color: #ffffff;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nflx-quality-btn:hover {
    border-color: var(--nflx-red);
    color: var(--nflx-red);
    transform: scale(1.08);
}

.nflx-quality-dropdown {
    min-width: 175px;
    max-height: 280px;
    overflow-y: auto;
    right: 0;
    bottom: 45px;
}

.nflx-dropdown-header {
    padding: 6px 16px 4px 16px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: rgba(255, 255, 255, 0.45);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 4px;
}

.nflx-quality-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.nflx-quality-badge {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.5px;
    padding: 1px 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    text-transform: uppercase;
    margin-left: 6px;
}

.nflx-dropdown-item.nflx-selected .nflx-quality-badge {
    background: var(--nflx-red);
    color: #ffffff;
}

.nflx-check-icon {
    font-size: 14px;
    color: var(--nflx-red);
    display: none;
}

.nflx-dropdown-item.nflx-selected .nflx-check-icon {
    display: inline-block;
}

/* Quality Toast Notification */
.nflx-quality-toast {
    position: absolute;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(15, 15, 15, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    padding: 8px 18px;
    border-radius: 20px;
    z-index: 90;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    gap: 6px;
}

.nflx-quality-toast.nflx-show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* --- Smart TV Play Prompt & Unmute Badge --- */
.nflx-tv-play-prompt {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 45;
    pointer-events: auto;
}

.nflx-tv-play-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(229, 9, 20, 0.95);
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-radius: 50px;
    padding: 16px 36px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.8), 0 0 20px rgba(229, 9, 20, 0.4);
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    outline: none;
}

.nflx-tv-play-btn:hover,
.nflx-tv-play-btn:focus {
    transform: scale(1.06);
    background: #ff0f1e;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9), 0 0 35px rgba(229, 9, 20, 0.8);
    border-color: #ffffff;
}

.nflx-tv-play-text {
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.nflx-tv-hint {
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nflx-tv-unmute-prompt {
    position: absolute;
    bottom: 90px;
    left: 32px;
    z-index: 45;
    pointer-events: auto;
}

.nflx-tv-unmute-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(20, 20, 20, 0.88);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    transition: background 0.2s ease, transform 0.2s ease;
    outline: none;
}

.nflx-tv-unmute-btn:hover,
.nflx-tv-unmute-btn:focus {
    background: rgba(229, 9, 20, 0.95);
    border-color: #ffffff;
    transform: scale(1.05);
}

/* ==========================================================================
   Zero-Buffer Safe Cushion Gate & Data Saver UI (500 kbps Ultra-Smooth Direct Streaming)
   ========================================================================== */

.nflx-low-bw-badge {
    background: rgba(229, 9, 20, 0.22) !important;
    color: #ff4d58 !important;
    border: 1px solid rgba(229, 9, 20, 0.45) !important;
    font-weight: 700 !important;
    letter-spacing: 0.3px;
    animation: nflxPulseGlow 3s ease-in-out infinite;
}

@keyframes nflxPulseGlow {
    0%, 100% {
        box-shadow: 0 0 6px rgba(229, 9, 20, 0.2);
    }
    50% {
        box-shadow: 0 0 14px rgba(229, 9, 20, 0.5);
    }
}

.nflx-buffer-gate {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 48;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nflx-buffer-gate-content {
    background: rgba(14, 14, 14, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 14px;
    padding: 22px 28px;
    min-width: 290px;
    max-width: 360px;
    text-align: center;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 25px rgba(229, 9, 20, 0.15);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.nflx-buffer-gate-spinner {
    position: relative;
    width: 44px;
    height: 44px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nflx-spinner-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--nflx-red);
    border-radius: 50%;
    animation: nflxSpin 0.9s linear infinite;
}

.nflx-buffer-gate-spinner i {
    font-size: 20px;
    color: var(--nflx-red);
}

.nflx-buffer-gate-title {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 4px;
    letter-spacing: 0.4px;
}

.nflx-buffer-gate-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 14px;
    line-height: 1.35;
}

.nflx-buffer-gate-bar-wrap {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 8px;
    position: relative;
}

.nflx-buffer-gate-bar {
    height: 100%;
    background: linear-gradient(90deg, #ff414d 0%, #e50914 100%);
    border-radius: 3px;
    transition: width 0.25s ease-out;
    box-shadow: 0 0 10px rgba(229, 9, 20, 0.7);
}

.nflx-buffer-gate-subtext {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.55);
    letter-spacing: 0.3px;
}


