:root {
            /* Theme Config - Dark (Default) */
            --bg-dark: url("https://gpsite.github.io/gpmedia/img/catalog/darkcatalog.png");
            --bg-light: url("https://gpsite.github.io/gpmedia/img/catalog/lightcatalog.png");

            --glass: rgba(255, 255, 255, 0.08);
            --glass-strong: rgba(20, 20, 20, 0.6);
            --glass-border: rgba(255, 255, 255, 0.12);
            --text-primary: #ffffff;
            --text-secondary: rgba(255, 255, 255, 0.6);
            --accent: #60a5fa;
            /* Blueish to match previous movie theme */
            --accent-glow: rgba(96, 165, 250, 0.4);

            --pill-bg: rgba(255, 255, 255, 0.08);
            --pill-hover: rgba(255, 255, 255, 0.15);

            --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.1);
            --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.3);

            --transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);

            --header-padding: clamp(15px, 2.5vw, 40px);
        }

        [data-theme="light"] {
            --glass: rgba(255, 255, 255, 0.75);
            --glass-strong: rgba(255, 255, 255, 0.9);
            --glass-border: rgba(0, 0, 0, 0.06);
            --text-primary: #3f6cb6;
            --text-secondary: #365e96;
            --accent: #2563eb;
            --accent-glow: rgba(37, 99, 235, 0.2);
            --pill-bg: rgba(0, 0, 0, 0.04);
            --pill-hover: rgba(0, 0, 0, 0.08);
            --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
            --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.15);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            -webkit-font-smoothing: antialiased;
        }

        body {
            font-family: 'Outfit', sans-serif;
            min-height: 100vh;
            display: flex;
            flex-direction: column;
            background-color: #000;
            color: var(--text-primary);
            overflow-x: hidden;
        }

        body.no-scroll {
            overflow: hidden;
        }

        body.blur-active main,
        body.blur-active header,
        body.blur-active .hero-container {
            filter: blur(8px);
            transition: filter 0.3s ease;
            pointer-events: none;
        }

        /* Dynamic Background Layer */
        .bg-layer {
            position: fixed;
            inset: 0;
            background-size: cover;
            background-position: center;
            background-repeat: no-repeat;
            z-index: -2;
            transition: background-image 0.8s ease;
            filter: saturate(40%);
        }

        [data-theme="dark"] .bg-layer {
            background-image: var(--bg-dark);
        }

        [data-theme="light"] .bg-layer {
            background-image: var(--bg-light);
            filter: brightness(1.02);
        }

        /* --- NAVIGATION --- */
        header {
            width: 100%;
            padding: var(--header-padding);
            padding-bottom: 20px;
            display: flex;
            justify-content: center;
            z-index: 100;
            position: fixed;
            /* Fixed nav like Movies page? Or relative like Games? Games is relative. Movies was fixed. Let's go Fixed for better UX with Hero scroll */
            top: 0;
            transition: background 0.3s;
        }

        header.scrolled .nav-pill {
            background: rgba(20, 20, 20, 0.8);
            backdrop-filter: blur(20px);
        }

        [data-theme="light"] header.scrolled .nav-pill {
            background: rgba(255, 255, 255, 0.8);
        }

        /* Unified Navbar Pill */
        .nav-pill {
            display: flex;
            align-items: center;
            background: var(--glass);
            border: 1px solid var(--glass-border);
            border-radius: 100px;
            padding: 6px;
            backdrop-filter: blur(16px);
            box-shadow: var(--shadow-lg);
            width: 100%;
            max-width: 900px;
            gap: 8px;
            transition: var(--transition);
        }

        .nav-item {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 10px 24px;
            color: var(--text-primary);
            text-decoration: none;
            font-weight: 600;
            border-radius: 100px;
            transition: var(--transition);
            white-space: nowrap;
            cursor: pointer;
        }

        .nav-item:hover,
        .nav-item.active {
            background: var(--pill-hover);
        }

        .nav-item i {
            width: 18px;
            height: 18px;
        }

        .search-container {
            flex: 1;
            position: relative;
            display: flex;
            align-items: center;
            background: var(--pill-bg);
            border-radius: 100px;
            padding: 2px;
            transition: var(--transition);
        }

        .search-container:focus-within {
            background: var(--pill-hover);
            box-shadow: 0 0 0 2px var(--accent-glow);
        }

        .search-input {
            width: 100%;
            border: none;
            background: transparent;
            color: var(--text-primary);
            font-family: inherit;
            font-size: 1rem;
            padding: 10px 16px;
            outline: none;
        }

        .search-input::placeholder {
            color: var(--text-secondary);
        }

        /* --- HERO SECTION --- */
        .hero-container {
            width: 100%;
            max-width: 1600px;
            margin: 120px auto 40px;
            /* Offset for fixed header */
            padding: 0 var(--header-padding);
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .hero-box {
            position: relative;
            width: 100%;
            border-radius: 24px;
            overflow: hidden;
            background: var(--glass);
            border: 1px solid var(--glass-border);
            box-shadow: var(--shadow-lg);
            display: flex;
            align-items: center;
            min-height: 60vh;
        }

        .hero-bg {
            position: absolute;
            inset: 0;
            background-size: cover;
            background-position: center 20%;
            transition: var(--transition);
        }

        .hero-overlay-gradient {
            position: absolute;
            inset: 0;
            background: linear-gradient(to right, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.6) 50%, transparent 100%);
            z-index: 1;
        }

        [data-theme="light"] .hero-overlay-gradient {
            background: linear-gradient(to right, rgba(240, 240, 240, 0.9) 0%, rgba(240, 240, 240, 0.7) 50%, transparent 100%);
        }

        .hero-content {
            position: relative;
            z-index: 10;
            max-width: 600px;
            padding: 60px;
        }

        @media (max-width: 768px) {
            .hero-content {
                padding: 30px;
            }

            .hero-overlay-gradient {
                background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.5) 60%, transparent 100%);
            }

            [data-theme="light"] .hero-overlay-gradient {
                background: linear-gradient(to top, rgba(240, 240, 240, 0.95) 0%, rgba(240, 240, 240, 0.7) 60%, transparent 100%);
            }
        }

        .hero-title {
            font-size: clamp(2rem, 4vw, 3.5rem);
            font-weight: 800;
            margin-bottom: 16px;
            line-height: 1.1;
            /* text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5); */
        }

        .hero-meta {
            display: flex;
            align-items: center;
            gap: 16px;
            margin-bottom: 24px;
            font-size: 1.1rem;
            color: var(--text-secondary);
            font-weight: 500;
        }

        .hero-desc {
            font-size: 1.05rem;
            line-height: 1.6;
            margin-bottom: 32px;
            color: var(--text-primary);
            opacity: 0.9;
            display: -webkit-box;
            -webkit-line-clamp: 3;
            line-clamp: 3;
            -webkit-box-orient: vertical;
            overflow: hidden;
            max-width: 500px;
        }

        .hero-btn {
            background: var(--text-primary);
            color: var(--glass-strong);
            /* Inverse for contrast */
            border: none;
            padding: 14px 32px;
            border-radius: 100px;
            font-size: 1.1rem;
            font-weight: 700;
            cursor: pointer;
            display: inline-flex;
            align-items: center;
            gap: 10px;
            transition: var(--transition);
            box-shadow: 0 0 20px rgba(120, 120, 120, 0.2);
        }

        [data-theme="dark"] .hero-btn {
            color: #000;
            background: #fff;
        }

        [data-theme="light"] .hero-btn {
            color: #fff;
            background: #000;
        }

        .hero-btn:hover {
            transform: scale(1.05);
            box-shadow: 0 0 30px var(--accent-glow);
        }

        /* Loading Pulse */
        .loading-pulse {
            animation: pulse 1.5s infinite;
            opacity: 0.7;
        }

        @keyframes pulse {

            0%,
            100% {
                opacity: 0.4;
            }

            50% {
                opacity: 0.8;
            }
        }

        /* --- MAIN GRID --- */
        main {
            width: 100%;
            max-width: 1600px;
            margin: 0 auto;
            padding: 0 var(--header-padding) 60px;
            z-index: 10;
        }

        .section-divider {
            display: flex;
            align-items: center;
            gap: 20px;
            margin: 10px 0 24px;
        }

        .diamond {
            width: 8px;
            height: 8px;
            background: var(--accent);
            transform: rotate(45deg);
            box-shadow: 0 0 10px var(--accent);
        }

        .divider-line {
            flex: 1;
            height: 2px;
            background: linear-gradient(90deg, var(--accent) 0%, transparent 100%);
            border-radius: 1px;
        }

        .divider-text {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--text-primary);
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .movie-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
            /* Matches movies aspect better than games square */
            gap: 24px;
        }

        .movie-card {
            position: relative;
            background: var(--glass);
            border-radius: 12px;
            overflow: hidden;
            border: 1px solid var(--glass-border);
            aspect-ratio: 2/3;
            cursor: pointer;
            transition: var(--transition);
        }

        .movie-card:hover {
            transform: translateY(-8px);
            box-shadow: var(--shadow-lg);
            border-color: var(--accent);
            z-index: 2;
        }

        .movie-card img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
        }

        .movie-info-mini {
            position: absolute;
            bottom: 0;
            left: 0;
            width: 100%;
            padding: 30px 12px 12px;
            background: linear-gradient(to top, rgba(0, 0, 0, 0.95), transparent);
            opacity: 0;
            transition: var(--transition);
            display: flex;
            flex-direction: column;
            gap: 4px;
        }

        .movie-card:hover .movie-info-mini {
            opacity: 1;
        }

        .movie-title {
            font-weight: 700;
            font-size: 1rem;
            color: #fff;
            line-height: 1.2;
        }

        .movie-year {
            font-size: 0.85rem;
            color: var(--text-secondary);
        }

        /* --- MODALS (Favorites / Watched) --- */
        .modal {
            position: fixed;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background: rgba(20, 20, 20, 0.9);
            backdrop-filter: blur(24px);
            border: 1px solid var(--glass-border);
            padding: 24px;
            border-radius: 24px;
            width: 90%;
            max-width: 500px;
            max-height: 80vh;
            z-index: 2000;
            display: none;
            flex-direction: column;
            gap: 16px;
            box-shadow: var(--shadow-lg);
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        .modal.active {
            display: flex;
            opacity: 1;
        }

        .modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding-bottom: 12px;
            border-bottom: 1px solid var(--glass-border);
        }

        .modal-title {
            font-size: 1.5rem;
            font-weight: 700;
        }

        .modal-close {
            background: transparent;
            border: none;
            color: var(--text-secondary);
            cursor: pointer;
        }

        .modal-close:hover {
            color: #fff;
        }

        .list-container {
            display: flex;
            flex-direction: column;
            gap: 12px;
            overflow-y: auto;
            padding-right: 4px;
        }

        .list-item {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 10px;
            border-radius: 12px;
            background: var(--pill-bg);
            transition: var(--transition);
            cursor: pointer;
        }

        .list-item:hover {
            background: var(--pill-hover);
        }

        .list-item img {
            width: 40px;
            height: 60px;
            border-radius: 4px;
            object-fit: cover;
        }

        .list-item-info {
            flex: 1;
        }

        .list-item-title {
            font-weight: 600;
            font-size: 1rem;
        }

        .list-item-remove {
            background: transparent;
            border: none;
            color: #ef4444;
            cursor: pointer;
            padding: 8px;
            opacity: 0.6;
        }

        .list-item-remove:hover {
            opacity: 1;
        }


        /* --- OVERLAY --- */
        .overlay {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.95);
            backdrop-filter: blur(10px);
            z-index: 5000;
            display: none;
            justify-content: center;
            align-items: center;
            opacity: 0;
            transition: opacity 0.3s ease;
            padding: 20px;
        }

        .overlay.active {
            opacity: 1;
        }

        .overlay-content {
            width: 100%;
            max-width: 1200px;
            height: 95vh;
            background: #111;
            border-radius: 16px;
            overflow-y: auto;
            position: relative;
            box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
            display: flex;
            flex-direction: column;
            border: 1px solid var(--glass-border);
        }

        /* Scrollbar */
        .overlay-content::-webkit-scrollbar {
            width: 8px;
        }

        .overlay-content::-webkit-scrollbar-thumb {
            background: #333;
            border-radius: 4px;
        }

        .video-wrapper {
            width: 100%;
            aspect-ratio: 16/9;
            background: #000;
            flex-shrink: 0;
            position: relative;
        }

        .video-loader {
            position: absolute;
            inset: 0;
            display: none;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            background: #000;
            z-index: 10;
        }

        .spinner {
            width: 50px;
            height: 50px;
            border: 3px solid rgba(255, 255, 255, 0.1);
            border-top-color: var(--accent);
            border-radius: 50%;
            animation: spin 1s linear infinite;
            margin-bottom: 20px;
        }

        @keyframes spin {
            to {
                transform: rotate(360deg);
            }
        }

        .loader-text {
            color: #fff;
            font-size: 14px;
            letter-spacing: 1px;
            text-transform: uppercase;
            opacity: 0.8;
            font-weight: 500;
            text-align: center;
        }

        .loader-sub {
            margin-top: 8px;
            color: var(--text-secondary);
            font-size: 13px;
            max-width: 300px;
            text-align: center;
            line-height: 1.4;
        }

        .video-container {
            width: 100%;
            height: 100%;
        }

        .video-container iframe {
            width: 100%;
            height: 100%;
            border: none;
            opacity: 0;
            transition: opacity 0.8s ease;
        }

        .overlay-details {
            padding: 30px;
            flex-grow: 1;
        }

        .overlay-header {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            margin-bottom: 20px;
            gap: 20px;
        }

        .overlay-title {
            font-size: 2rem;
            font-weight: 700;
            line-height: 1.1;
        }

        .overlay-meta {
            color: var(--accent);
            font-weight: 600;
            margin-top: 5px;
        }

        .overlay-controls {
            display: flex;
            gap: 12px;
            flex-shrink: 0;
        }

        .control-btn {
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.2);
            color: #fff;
            width: 44px;
            height: 44px;
            border-radius: 50%;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
        }

        .control-btn:hover {
            background: rgba(255, 255, 255, 0.2);
            transform: translateY(-2px);
        }

        .control-btn.active {
            background: var(--accent);
            border-color: var(--accent);
            color: #fff;
        }

        .control-btn i,
        .control-btn svg {
            width: 20px;
            height: 20px;
        }


        /* TV Panel Styles */
        .tv-panel {
            margin-top: 30px;
            background: rgba(255, 255, 255, 0.05);
            padding: 20px;
            border-radius: 12px;
            border: 1px solid var(--glass-border);
        }

        .tv-panel h3 {
            font-size: 1.1rem;
            margin-bottom: 15px;
            color: #ddd;
        }

        .season-tabs {
            display: flex;
            gap: 10px;
            margin-bottom: 15px;
            overflow-x: auto;
            padding-bottom: 10px;
        }

        .season-tab {
            background: rgba(0, 0, 0, 0.3);
            border: 1px solid var(--glass-border);
            color: var(--text-secondary);
            padding: 8px 16px;
            border-radius: 8px;
            cursor: pointer;
            white-space: nowrap;
            transition: all 0.2s;
        }

        .season-tab:hover {
            background: rgba(255, 255, 255, 0.1);
            color: #fff;
        }

        .season-tab.active {
            background: #fff;
            color: #000;
            font-weight: 700;
        }

        .episode-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
            gap: 10px;
        }

        .episode-btn {
            background: rgba(0, 0, 0, 0.3);
            border: 1px solid var(--glass-border);
            color: #fff;
            aspect-ratio: 1;
            border-radius: 8px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            transition: all 0.2s;
        }

        .episode-btn:hover {
            background: rgba(255, 255, 255, 0.1);
        }

        .episode-btn.active {
            background: var(--accent);
            border-color: var(--accent);
        }

        /* Related */
        .related-section {
            margin-top: 40px;
        }

        .related-title {
            font-size: 1.2rem;
            margin-bottom: 15px;
            font-weight: 600;
        }

        .related-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
            gap: 16px;
        }

        .related-card {
            cursor: pointer;
            transition: opacity 0.2s;
            aspect-ratio: 2/3;
        }

        .related-card:hover {
            opacity: 0.7;
        }

        .related-card img {
            width: 100%;
            height: 100%;
            border-radius: 8px;
            object-fit: cover;
        }

        /* Responsive */
        @media (max-width: 768px) {
            .nav-pill {
                flex-direction: column;
                gap: 12px;
                padding: 16px;
                border-radius: 24px;
            }

            .nav-item {
                width: 100%;
                justify-content: center;
            }

            .search-container {
                width: 100%;
            }

            .hero-title {
                font-size: 2.5rem;
            }

            .hero-container {
                height: 75vh;
            }

            .overlay-content {
                height: 100%;
                border-radius: 0;
            }

            .movie-grid {
                grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
            }
        }