        :root {
            --bg-color: #141414;
            --header-bg: linear-gradient(to bottom, rgba(0,0,0,0.7) 10%, rgba(0,0,0,0));
            --text-color: #fff;
            --accent-color: #e50914;
            --card-radius: 4px;
            --transition: 0.3s ease;
        }

        body {
            font-family: 'Roboto', sans-serif;
            background-color: var(--bg-color);
            color: var(--text-color);
            margin: 0;
            padding: 0;
            overflow-x: hidden;
        }

        /* --- NAVIGATION --- */
        nav {
            position: fixed;
            top: 0;
            width: 100%;
            box-sizing: border-box;
            padding: 20px 4%;
            display: flex;
            align-items: center;
            justify-content: space-between;
            z-index: 100;
            background: var(--header-bg);
            transition: background 0.5s;
        }
        
        nav.scrolled {
            background: #141414;
        }

        .logo {
            color: var(--accent-color);
            font-size: 24px;
            font-weight: bold;
            text-transform: uppercase;
            letter-spacing: 2px;
            text-decoration: none;
        }

        .nav-menu {
            display: flex;
            list-style: none;
            margin: 0;
            padding: 0;
            margin-left: 40px;
            flex-grow: 1;
        }

        .nav-item {
            color: #e5e5e5;
            margin-right: 20px;
            cursor: pointer;
            font-size: 14px;
            font-weight: 400;
            transition: color 0.3s;
        }
        
        .nav-item:hover {
            color: #b3b3b3;
        }
        
        .nav-item.active {
            color: #fff;
            font-weight: 700;
        }

        .nav-right {
            display: flex;
            align-items: center;
        }

        .search-container {
            display: flex;
            align-items: center;
            background: #000;
            border: 1px solid #ccc;
            padding: 5px 10px;
            margin-right: 20px;
            border-radius: 4px;
            transition: width 0.3s;
            width: 30px; /* Initially hidden/collapsed */
            overflow: hidden;
            border-color: transparent;
            background: transparent;
        }
        
        .search-container.active {
            width: 250px;
            background: #000;
            border-color: #fff;
        }

        .search-input {
            background: transparent;
            border: none;
            color: #fff;
            padding-left: 10px;
            outline: none;
            width: 100%;
            display: none; /* Hidden by default */
        }

        .search-container.active .search-input {
            display: block;
        }
        
        .search-icon {
            cursor: pointer;
        }

        /* --- HERO SECTION --- */
        .hero {
            height: 80vh;
            width: 100%;
            background-size: cover;
            background-position: center;
            position: relative;
            display: flex;
            align-items: center;
            padding: 0 4%;
            box-sizing: border-box;
        }

        .hero::after {
            content: '';
            position: absolute;
            top: 0; left: 0; width: 100%; height: 100%;
            background: linear-gradient(to top, #141414 0%, transparent 60%);
            z-index: 2;
        }

        .hero-video {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            z-index: 1;
        }

        .hero-content {
            position: relative;
            z-index: 3;
            max-width: 600px;
        }

        .hero-title {
            font-size: 3rem;
            margin-bottom: 0.5rem;
            text-transform: uppercase;
            line-height: 1.1;
        }

        .hero-desc {
            font-size: 1.1rem;
            margin-bottom: 20px;
            text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
            display: -webkit-box;
            -webkit-line-clamp: 3;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .btn {
            background-color: var(--accent-color);
            color: white;
            padding: 10px 24px;
            border: none;
            border-radius: 4px;
            font-size: 1.1rem;
            cursor: pointer;
            font-weight: bold;
            display: inline-flex;
            align-items: center;
            gap: 10px;
            transition: transform 0.2s;
        }
        .btn:hover { transform: scale(1.05); }
        .btn-secondary {
            background-color: rgba(109, 109, 110, 0.7);
            margin-left: 10px;
        }

        /* --- ROWS / CATEGORIES --- */
        .category-rows {
            padding: 0 4%;
            padding-bottom: 50px;
            margin-top: -100px;
            position: relative;
            z-index: 10;
        }

        .row-title {
            font-size: 1.2rem;
            font-weight: 500;
            margin-bottom: 10px;
            margin-top: 30px;
            color: #e5e5e5;
        }

        .row-container {
            display: flex;
            overflow-x: auto;
            gap: 10px;
            padding: 20px 0;
            scrollbar-width: none; /* Firefox */
        }
        .row-container::-webkit-scrollbar { display: none; }

        .movie-card {
            flex: 0 0 auto;
            width: 200px;
            height: 300px;
            border-radius: var(--card-radius);
            position: relative;
            cursor: pointer;
            transition: var(--transition);
            overflow: hidden;
            background: #2f2f2f;
        }

        .movie-card img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: transform 0.3s;
        }

        .movie-card:hover {
            transform: scale(1.05);
            z-index: 20;
            box-shadow: 0 10px 20px rgba(0,0,0,0.5);
        }

        .type-icon {
            position: absolute;
            top: 10px;
            right: 10px;
            background: rgba(0,0,0,0.7);
            color: #fff;
            padding: 5px;
            border-radius: 50%;
            width: 24px;
            height: 24px;
            display: flex;
            justify-content: center;
            align-items: center;
            font-size: 12px;
            z-index: 5;
            box-shadow: 0 2px 5px rgba(0,0,0,0.5);
        }

        /* --- PLACEHOLDER POSTERS --- */
        .poster-placeholder {
            width: 100%;
            height: 100%;
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 10px;
            text-align: center;
            font-weight: bold;
            font-size: 1.5rem;
            background: linear-gradient(135deg, #333, #555);
            color: rgba(255,255,255,0.5);
            text-decoration: none;
        }

        /* --- FULLSCREEN PLAYER --- */
        #player-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: #000;
            z-index: 2000;
            display: none; /* Hidden by default */
            flex-direction: column;
            justify-content: center;
            align-items: center;
        }

        #player-overlay.active {
            display: flex;
        }

        /* --- BOOK READER OVERLAY --- */
        #book-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: #222;
            z-index: 2000;
            display: none;
            flex-direction: column;
        }

        #book-overlay.active {
            display: flex;
        }

        .book-header {
            height: 60px;
            background: #111;
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 0 20px;
            box-shadow: 0 2px 10px rgba(0,0,0,0.5);
            z-index: 10;
        }

        .book-content {
            flex-grow: 1;
            display: flex;
            justify-content: center;
            align-items: flex-start;
            overflow-y: auto;
            padding: 20px;
            background: #333;
            width: 100%; /* Reset width from previous css */
            height: auto;
            margin: 0;
            box-shadow: none;
            border-radius: 0;
            position: relative;
        }
        
        #book-canvas {
            box-shadow: 0 0 20px rgba(0,0,0,0.5);
            background: #fff;
            max-width: 100%;
        }

        .back-btn-book {
            background: rgba(255,255,255,0.1);
            color: #fff;
            border: 1px solid rgba(255,255,255,0.2);
            font-size: 1rem;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 8px 16px;
            border-radius: 4px;
            transition: all 0.3s ease;
            text-decoration: none;
            backdrop-filter: blur(4px);
        }
        .back-btn-book:hover { 
            background: #fff;
            color: #000;
            text-decoration: none;
        }

        .book-controls {
            display: flex;
            align-items: center;
            gap: 15px;
            color: #fff;
            font-size: 1.1rem;
        }

        .book-control-btn {
            background: #444;
            color: #fff;
            border: none;
            width: 36px;
            height: 36px;
            border-radius: 50%;
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
            transition: 0.2s;
        }
        .book-control-btn:hover { background: #666; }

        #book-loader {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            color: #fff;
            font-size: 1.5rem;
            display: none;
        }
        
        .back-btn {
            position: absolute;
            top: 20px;
            left: 20px;
            z-index: 2010;
            background: rgba(0,0,0,0.6);
            color: white;
            border: 1px solid rgba(255,255,255,0.2);
            padding: 10px 24px;
            font-size: 1.1rem;
            cursor: pointer;
            border-radius: 4px;
            display: flex;
            align-items: center;
            gap: 12px;
            backdrop-filter: blur(4px);
            transition: all 0.3s ease;
            font-weight: 500;
        }
        .back-btn:hover { 
            background: white; 
            color: black; 
            transform: scale(1.05);
        }

        .logout-btn {
            background: transparent;
            color: #ccc;
            border: 1px solid #ccc;
            padding: 5px 12px;
            font-size: 0.8rem;
            cursor: pointer;
            border-radius: 4px;
            margin-left: 20px;
            text-transform: uppercase;
            font-weight: bold;
            transition: 0.3s;
        }
        .logout-btn:hover { background: #fff; color: #000; }

        video { 
            width: 100%; 
            max-height: 100vh;
            outline: none;
        }

        /* --- MOBILE --- */
        @media (max-width: 768px) {
            .hero-title { font-size: 2rem; }
            .movie-card { width: 140px; height: 210px; }
            .hero { height: 60vh; }
            nav { padding: 15px; }
            .btn { padding: 8px 16px; font-size: 1rem; }
            .back-btn { top: 10px; left: 10px; padding: 8px 16px; }
        }
        /* --- LOCKED ACCESS --- */
        #login-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: #161616;
            z-index: 9999;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            backdrop-filter: blur(8px);
            transition: opacity 0.5s;
        }

        #login-box {
            background: rgba(0, 0, 0, 0.75);
            padding: 60px 68px 40px;
            border-radius: 4px;
            width: 100%;
            max-width: 450px;
            box-sizing: border-box;
            box-shadow: 0 15px 25px rgba(0,0,0,0.6);
            display: flex;
            flex-direction: column;
        }

        .login-title {
            color: #fff;
            font-size: 32px;
            font-weight: 700;
            margin-bottom: 28px;
            text-align: left;
        }

        .login-input-group {
            position: relative;
            margin-bottom: 16px;
        }

        .login-input {
            width: 100%;
            padding: 16px 20px;
            border-radius: 4px;
            border: 0;
            background: #333;
            color: #fff;
            font-size: 16px;
            box-sizing: border-box;
            outline: none;
            transition: background 0.2s;
        }

        .login-input:focus {
            background: #454545;
        }
        
        /* Floating label effect (optional, keep it simple for now) placeholder logic */
        .login-input::placeholder { color: #8c8c8c; }

        .login-input.input-error {
            border-bottom: 2px solid #e50914;
            border-radius: 4px 4px 0 0; /* Flat bottom for border */
        }

        .login-btn {
            background-color: var(--accent-color);
            color: white;
            padding: 16px;
            border-radius: 4px;
            border: none;
            font-size: 16px;
            font-weight: 700;
            cursor: pointer;
            margin-top: 24px;
            transition: background 0.2s;
            width: 100%;
        }

        .login-btn:hover { background-color: #f40612; }

        .error-message {
            color: #e50914;
            font-size: 13px;
            margin-top: 10px;
            display: none;
            text-align: left;
        }
