@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Montserrat:wght@400;500;600;700;800;900&subset=cyrillic,cyrillic-ext&display=swap');

/* ==========================================================================
   CineStream CSS - Premium Dark Mode Styling & Animations
   ========================================================================== */

:root {
    --bg-primary: #08080c;
    --bg-secondary: #0f0f18;
    --bg-tertiary: #171725;
    --accent-purple: #8b5cf6;
    --accent-purple-light: #a78bfa;
    --accent-purple-glow: rgba(139, 92, 246, 0.4);
    --accent-rose: #f43f5e;
    --accent-rose-glow: rgba(244, 63, 94, 0.4);
    --text-primary: #f3f4f6;
    --text-muted: #9ca3af;
    --text-dark: #6b7280;
    --white: #ffffff;
    --glass-bg: rgba(15, 15, 24, 0.75);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-glow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --card-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s ease;
}

/* Light Theme Variables Override */
body.light-theme {
    --bg-primary: #f1f5f9;
    --bg-secondary: #ffffff;
    --bg-tertiary: #e2e8f0;
    --accent-purple: #7c3aed;
    --accent-purple-light: #6d28d9;
    --accent-purple-glow: rgba(124, 58, 237, 0.15);
    --accent-rose: #e11d48;
    --accent-rose-glow: rgba(225, 29, 72, 0.15);
    --text-primary: #0f172a;
    --text-muted: #475569;
    --text-dark: #64748b;
    --white: #0f172a;
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(15, 23, 42, 0.08);
    --glass-glow: 0 8px 32px 0 rgba(148, 163, 184, 0.1);
    --card-shadow: 0 8px 30px rgba(148, 163, 184, 0.12);
}

/* Header buttons & Notifications style */
.header-action-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: var(--transition-fast);
    width: 46px;
    height: 46px;
    border-radius: 50%;
}

.header-action-btn:hover {
    color: var(--accent-purple-light);
    background: rgba(255, 255, 255, 0.05);
}

body.light-theme .header-action-btn:hover {
    background: rgba(15, 23, 42, 0.05);
}

.notif-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 7px;
    height: 7px;
    background-color: var(--accent-rose);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--accent-rose-glow);
}

/* ==========================================================================
   Base & Layout Reset
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-purple) var(--bg-secondary);
}

body {
    font-family: 'Inter', 'Montserrat', 'Segoe UI', Roboto, Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    line-height: 1.5;
    position: relative;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', 'Inter', 'Segoe UI', Roboto, Arial, sans-serif;
    color: var(--white);
    font-weight: 700;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    outline: none;
}

input {
    font-family: inherit;
    outline: none;
    border: none;
}

/* Custom Webkit Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-purple);
}

/* ==========================================================================
   Background Ambient Glowing Effects
   ========================================================================== */
.bg-glow {
    position: fixed;
    width: 60vw;
    height: 60vh;
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    opacity: 0.15;
    filter: blur(150px);
}

.bg-glow-1 {
    background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
    top: -20vh;
    left: -10vw;
}

.bg-glow-2 {
    background: radial-gradient(circle, var(--accent-rose) 0%, transparent 70%);
    bottom: -20vh;
    right: -10vw;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    padding: 1rem 0;
    background: linear-gradient(to bottom, rgba(8, 8, 12, 0.95) 0%, rgba(8, 8, 12, 0) 100%);
    transition: var(--transition-smooth);
}

.app-header.scrolled {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.75rem 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

.app-header.header-hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 1.8rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.6rem;
    font-family: 'Montserrat', 'Inter', sans-serif;
    font-weight: 800;
    color: var(--white);
    letter-spacing: -0.5px;
    flex-shrink: 0;
}

.logo-img {
    height: 42px;
    width: auto;
    object-fit: contain;
    display: block;
    transition: var(--transition-smooth);
}

.logo-img:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 8px var(--accent-purple-glow));
}

body.light-theme .logo-img:hover {
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.35));
}

.logo-img-footer {
    height: 60px;
    width: auto;
    object-fit: contain;
}

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

.main-nav ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin: 0;
    padding: 0;
}

.main-nav ul li {
    display: flex;
    align-items: center;
}

.nav-link {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0 1.1rem;
    height: 40px;
    box-sizing: border-box;
    white-space: nowrap;
    border-radius: 10px;
    transition: var(--transition-fast);
    text-decoration: none;
    line-height: 1;
}

.nav-link span {
    white-space: nowrap;
}

.nav-link i {
    font-size: 0.9rem;
}

.nav-link:hover, .nav-link.active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.08);
}

.nav-link.active {
    background: rgba(139, 92, 246, 0.18);
    color: var(--accent-purple-light);
    border: 1px solid rgba(139, 92, 246, 0.3);
    font-weight: 600;
}

/* Search Box Container */
.search-box {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    padding: 0 1.2rem;
    height: 40px;
    box-sizing: border-box;
    white-space: nowrap;
    border-radius: 30px;
    width: 260px;
    transition: var(--transition-smooth);
}

.search-box:focus-within {
    width: 330px;
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--accent-purple);
    box-shadow: 0 0 15px var(--accent-purple-glow);
}

.search-icon {
    color: var(--text-muted);
    font-size: 1.0rem;
    margin-right: 0.6rem;
    transition: var(--transition-fast);
}

.search-box:focus-within .search-icon {
    color: var(--accent-purple-light);
}

.search-box input {
    background: none;
    color: var(--white);
    font-size: 0.95rem;
    width: 100%;
}

.search-box input::placeholder {
    color: var(--text-dark);
}

.clear-search {
    color: var(--text-muted);
    font-size: 0.85rem;
    display: none;
}

.clear-search:hover {
    color: var(--accent-rose);
}

/* User Profile Header Element */
.user-profile {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0 1rem;
    height: 40px;
    box-sizing: border-box;
    white-space: nowrap;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    position: relative;
    cursor: pointer;
}

.profile-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-purple);
}

.username {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
}

/* ==========================================================================
   Buttons UI Design
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.75rem 1.6rem;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5), 0 0 10px rgba(244, 63, 94, 0.2);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-watchlist-round {
    display: none !important;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    color: var(--white);
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: var(--transition-smooth);
}

.btn-watchlist-round:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--accent-purple);
    color: var(--accent-purple-light);
    transform: scale(1.08);
    box-shadow: 0 0 15px var(--accent-purple-glow);
}

/* ==========================================================================
   Hero Spotlight Section
   ========================================================================== */
.hero-section {
    position: relative;
    height: 80vh;
    min-height: 550px;
    width: 100%;
    display: flex;
    align-items: center;
    padding: 0 4rem;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center 20%;
    z-index: 1;
    transition: background-image 0.5s ease-in-out;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(8, 8, 12, 0.95) 0%, rgba(8, 8, 12, 0.8) 30%, rgba(8, 8, 12, 0) 100%),
                linear-gradient(to top, rgba(8, 8, 12, 1) 0%, rgba(8, 8, 12, 0.4) 50%, rgba(8, 8, 12, 0) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    transform: translateY(20px);
    animation: heroFadeIn 0.8s forwards cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes heroFadeIn {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.hero-tag {
    align-self: flex-start;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(139, 92, 246, 0.2);
    border: 1px solid rgba(139, 92, 246, 0.4);
    padding: 0.35rem 0.8rem;
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-purple-light);
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.1;
    font-weight: 800;
    font-family: 'Montserrat', 'Inter', sans-serif;
    letter-spacing: -1px;
}

.hero-meta {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.hero-rating {
    color: #fbbf24;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 700;
}

.hero-year, .hero-duration {
    color: var(--text-muted);
}

.hero-genre {
    background: rgba(255, 255, 255, 0.08);
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.hero-description {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.5rem;
}

/* ==========================================================================
   Movie Carousel Row Sections
   ========================================================================== */
.main-content {
    padding-bottom: 5rem;
}

.movie-row-section {
    padding: 2rem 4rem 1rem 4rem;
    position: relative;
}

.row-title {
    font-size: 1.4rem;
    margin-bottom: 1.2rem;
    font-weight: 600;
    letter-spacing: -0.3px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.row-title::after {
    content: '';
    display: block;
    width: 4px;
    height: 1.2rem;
    background: linear-gradient(to bottom, var(--accent-purple), var(--accent-rose));
    order: -1;
    border-radius: 4px;
}

.slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.movie-slider {
    display: flex;
    gap: 1.2rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 0.75rem 0.25rem 1.5rem 0.25rem;
    width: 100%;
}

.movie-slider::-webkit-scrollbar {
    display: none; /* Hide scrollbars in sliders for netflix look */
}

/* Slider buttons */
.slider-btn {
    position: absolute;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(15, 15, 24, 0.8);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(8px);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    z-index: 10;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
}

.slider-btn:hover {
    background: var(--accent-purple);
    border-color: var(--accent-purple-light);
    box-shadow: 0 0 15px var(--accent-purple-glow);
    transform: scale(1.1);
}

.slider-wrapper:hover .slider-btn {
    opacity: 1;
    pointer-events: auto;
}

.prev-btn {
    left: -20px;
}

.next-btn {
    right: -20px;
}

/* ==========================================================================
   Movie Card UI Design
   ========================================================================== */
.movie-card {
    flex: 0 0 auto;
    width: 200px;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: var(--glass-glow);
}

.movie-card:hover {
    transform: translateY(-8px) scale(1.03);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6), 0 0 15px var(--accent-purple-glow);
}

.card-poster {
    width: 100%;
    height: 280px;
    position: relative;
    overflow: hidden;
}

.movie-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    text-transform: uppercase;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
    user-select: none;
    pointer-events: none;
    letter-spacing: 0.5px;
    font-family: 'Inter', sans-serif;
}

.badge-vip {
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.badge-pay {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.badge-free {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #34d399;
}

.card-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.movie-card:hover .card-poster img {
    transform: scale(1.06);
}

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(15, 15, 24, 0.95) 0%, rgba(15, 15, 24, 0.4) 60%, rgba(15, 15, 24, 0) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1rem;
    opacity: 0;
    transition: var(--transition-fast);
}

.movie-card:hover .card-overlay {
    opacity: 1;
}

.card-play-btn {
    align-self: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    transform: scale(0.8);
    opacity: 0;
    box-shadow: 0 4px 15px var(--accent-purple-glow);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
}

.movie-card:hover .card-play-btn {
    transform: scale(1);
    opacity: 1;
}

.card-play-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.8);
}

.card-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.3rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.card-rating {
    color: #fbbf24;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.2rem;
}

.card-bottom-info {
    padding: 0.75rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    background: var(--bg-secondary);
}

.card-bottom-title {
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-primary);
}

.card-bottom-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.movie-card:hover .card-bottom-info {
    opacity: 0.8;
}

/* ==========================================================================
   Pages & Section-specific layouts
   ========================================================================== */
.search-results-section, .all-movies-section, .watchlist-section {
    padding: 6.5rem 4rem 2rem 4rem;
    min-height: 70vh;
}

/* Section Header Layout */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.8rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
}

.all-movies-section .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.1rem;
}

.section-header h2 {
    font-size: 1.8rem;
    font-weight: 800;
}

.section-header h2 span {
    color: var(--accent-purple-light);
}

.btn-close-search {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-weight: 600;
    border: 1px solid var(--glass-border);
    transition: var(--transition-fast);
}

.btn-close-search:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
}

/* Movies Grid */
.movies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 2rem 1.5rem;
    width: 100%;
}

.movies-grid .movie-card {
    width: 100%;
}

/* Horizontal Scrollable Filters UI Chips with Nav Arrows */
.genre-filter-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    gap: 8px;
}

.genre-scroll-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.18);
    border: 1px solid rgba(139, 92, 246, 0.4);
    color: var(--accent-purple-light);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    z-index: 5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.genre-scroll-btn:hover {
    background: var(--accent-purple);
    color: #ffffff;
    border-color: var(--accent-purple-light);
    box-shadow: 0 0 14px var(--accent-purple-glow);
    transform: scale(1.08);
}

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

body.light-theme .genre-scroll-btn {
    background: rgba(139, 92, 246, 0.1);
    color: var(--accent-purple);
    border-color: rgba(139, 92, 246, 0.3);
}

.genre-filter-container {
    display: flex;
    gap: 0.6rem;
    overflow-x: auto;
    white-space: nowrap;
    width: 100%;
    padding-bottom: 8px;
    padding-top: 4px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

.genre-filter-container::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.genre-chip {
    flex-shrink: 0 !important;
    padding: 0.5rem 1.15rem;
    border-radius: 24px;
    font-size: 0.88rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    user-select: none;
}

.genre-chip:hover, .genre-chip.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent-purple) 0%, #d946ef 100%);
    border-color: rgba(217, 70, 239, 0.6);
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.45);
}

/* Empty/No results messages */
.no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 5rem 0;
    gap: 1rem;
    color: var(--text-muted);
}

.no-results i {
    font-size: 4rem;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.6;
}

.no-results p {
    font-size: 1.1rem;
}

/* Helper Utilities */
.hidden {
    display: none !important;
}

/* ==========================================================================
   Details Modal UI Design
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 200;
    background: rgba(5, 5, 8, 0.85);
    backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.modal-overlay:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
}

.modal-container {
    width: 95%;
    max-width: 1100px;
    background: rgba(15, 15, 24, 0.95);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.85);
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
}

.modal-container::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: var(--bg-url);
    background-size: cover;
    background-position: center;
    filter: blur(40px) brightness(0.2);
    opacity: 0.45;
    z-index: 0;
    pointer-events: none;
}

.modal-overlay:not(.hidden) .modal-container {
    transform: translateY(0) scale(1);
}

.modal-close-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(15, 15, 24, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    z-index: 20;
    transition: var(--transition-fast);
}

.modal-close-btn:hover {
    background: var(--accent-rose);
    color: var(--white);
    transform: rotate(90deg);
}

/* Modal Split Columns Layout */
.modal-content-layout {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 3.5rem;
    padding: 3rem;
    overflow-y: auto;
    max-height: 100%;
}

.modal-col-left {
    flex: 1.1;
    min-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

.modal-col-right {
    flex: 1.3;
    min-width: 340px;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Left Column elements */
.modal-poster-wrapper {
    width: 250px;
    height: 360px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.modal-poster-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-info-block {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.modal-title {
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--white);
    letter-spacing: -0.5px;
    line-height: 1.25;
}

.modal-rating-stars-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
}

.modal-rating-score {
    font-size: 1.35rem;
    font-weight: 800;
    color: #fbbf24;
}

.modal-stars {
    color: #fbbf24;
    display: flex;
    gap: 0.25rem;
    font-size: 1.1rem;
}

.modal-meta-badges {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.meta-badge {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 0.35rem 0.85rem;
    border-radius: 6px;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.modal-description {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.modal-credits {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    padding-top: 1.25rem;
}

.credit-item {
    font-size: 0.85rem;
    line-height: 1.4;
}

.credit-label {
    color: var(--text-dark);
    font-weight: 600;
    margin-right: 0.5rem;
}

.credit-value {
    color: var(--text-muted);
}

/* Right Column elements */
.modal-price-container {
    display: flex;
    align-items: center;
}

.modal-price-badge {
    background: rgba(139, 92, 246, 0.12);
    border: 1px solid rgba(139, 92, 246, 0.25);
    color: var(--accent-purple-light);
    font-size: 1.15rem;
    font-weight: 800;
    padding: 0.4rem 1.25rem;
    border-radius: 8px;
    letter-spacing: 0.5px;
}

.modal-main-buttons {
    display: flex;
    gap: 1.25rem;
}

.modal-main-buttons .btn {
    flex: 1;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    transition: var(--transition-smooth);
}

.btn-play-gradient {
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%) !important;
    color: var(--white) !important;
}

.btn-play-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.4) !important;
}

.btn-buy-orange {
    background: var(--accent-purple) !important;
    color: var(--white) !important;
}

.btn-buy-orange:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.35) !important;
}

.modal-sub-actions {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.btn-outline-trailer {
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.04);
    color: var(--white);
    font-weight: 600;
    padding: 0.8rem;
    border-radius: 10px;
    transition: var(--transition-fast);
    text-align: center;
}

.btn-outline-trailer:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.3);
}

.modal-action-icons {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1.5rem;
}

.action-icon-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
    flex: 1;
    text-align: center;
}

.action-icon-item i {
    font-size: 1.25rem;
    transition: var(--transition-fast);
}

.action-icon-item span {
    font-size: 0.72rem;
    font-weight: 500;
    white-space: nowrap;
}

.action-icon-item:hover {
    color: var(--white);
}

.action-icon-item:hover i {
    transform: translateY(-2px);
    color: var(--accent-purple-light);
}

/* Recommendations Section */
.modal-recommendations-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.rec-header {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--accent-purple-light);
    position: relative;
    padding-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rec-indicator {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 55px;
    height: 3px;
    background: var(--accent-purple-light);
    border-radius: 2px;
}

.rec-thumbnails {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    scrollbar-width: thin;
}

.rec-thumbnail-card {
    width: 76px;
    height: 108px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    flex-shrink: 0;
    transition: var(--transition-fast);
}

.rec-thumbnail-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rec-thumbnail-card:hover {
    transform: scale(1.08);
    border-color: var(--accent-purple-light);
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

.info-label {
    color: var(--text-dark);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.info-value {
    color: var(--text-primary);
    font-weight: 500;
}

/* ==========================================================================
   Premium Custom Video Player Overlay & Controls
   ========================================================================== */
.player-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 300;
    background: #000000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.player-overlay:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
}

.player-close-btn {
    position: absolute;
    top: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(20, 20, 20, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    z-index: 320;
    transition: var(--transition-smooth);
    opacity: 0.6;
}

.player-close-btn:hover {
    background: var(--accent-rose);
    transform: rotate(90deg);
    opacity: 1;
    box-shadow: 0 0 15px rgba(244, 63, 94, 0.5);
}

.video-container {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.video-container video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000000;
}

/* Controls container overlay */
.video-controls-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 310;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.7) 50%, rgba(0, 0, 0, 0) 100%);
    padding: 2rem 2.5rem 1.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    pointer-events: auto;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

/* Auto-hide controls when user is inactive */
.video-container.paused .video-controls-container,
.video-container:hover .video-controls-container {
    transform: translateY(0);
    opacity: 1;
}

.video-container.playing.user-inactive .video-controls-container {
    transform: translateY(100%);
    opacity: 0;
}

.video-container.playing.user-inactive .player-close-btn {
    opacity: 0;
    pointer-events: none;
}

/* Timeline/Progress Bar */
.timeline-container {
    height: 16px;
    display: flex;
    align-items: center;
    cursor: pointer;
    width: 100%;
}

.timeline {
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    width: 100%;
    position: relative;
    transition: height 0.1s ease;
}

.timeline-container:hover .timeline {
    height: 6px;
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    border-radius: 4px;
    background: linear-gradient(to right, var(--accent-purple), var(--accent-rose));
    position: absolute;
    top: 0;
    left: 0;
    box-shadow: 0 0 8px var(--accent-purple-glow);
}

.timeline-handle {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--white);
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(-50%, -50%) scale(0);
    box-shadow: 0 2px 6px rgba(0,0,0,0.4), 0 0 10px var(--accent-purple-glow);
    transition: transform 0.1s ease;
}

.timeline-container:hover .timeline-handle {
    transform: translate(-50%, -50%) scale(1.3);
}

/* Control buttons bar */
.controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.controls-left, .controls-right {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.control-btn {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
    padding: 0.25rem;
}

.control-btn:hover {
    color: var(--accent-purple-light);
    transform: scale(1.1);
}

.control-btn i {
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* Volume controls */
.volume-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.volume-slider {
    width: 0;
    height: 3px;
    -webkit-appearance: none;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 3px;
    transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s;
    opacity: 0;
}

.volume-container:hover .volume-slider,
.volume-slider:focus {
    width: 80px;
    opacity: 1;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--white);
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Time counter */
.time-display {
    font-size: 0.85rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    user-select: none;
}

/* Playback Speed Menu Controls */
.speed-control-container {
    position: relative;
}

.speed-menu {
    position: absolute;
    bottom: calc(100% + 1rem);
    right: 0;
    background: rgba(15, 15, 24, 0.95);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    width: 100px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    z-index: 330;
}

.speed-option {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem;
    text-align: center;
    border-radius: 4px;
    width: 100%;
    transition: var(--transition-fast);
}

.speed-option:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
}

.speed-option.active {
    background: var(--accent-purple);
    color: var(--white);
}

/* Giant play overlay clicker */
.video-overlay-play-btn {
    position: absolute;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.15);
    border: 2px solid var(--accent-purple);
    color: var(--accent-purple-light);
    font-size: 2.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 25px var(--accent-purple-glow);
    z-index: 305;
    pointer-events: none;
    opacity: 0;
    transform: scale(0.7);
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.video-container.paused:hover .video-overlay-play-btn {
    opacity: 1;
    transform: scale(1);
}

/* Loading buffer spinner */
.video-loader {
    position: absolute;
    z-index: 306;
    pointer-events: none;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(139, 92, 246, 0.2);
    border-top-color: var(--accent-purple);
    border-radius: 50%;
    animation: spin 1s infinite linear;
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.1);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Theatre Mode toggled layout */
.video-container.theatre {
    width: 90%;
    height: 80%;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    box-shadow: 0 25px 60px rgba(0,0,0,0.8);
}

/* ==========================================================================
   Footer Styling
   ========================================================================== */
.app-footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--glass-border);
    padding: 3rem 0;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.6rem;
    font-family: 'Montserrat', 'Inter', sans-serif;
    font-weight: 800;
    color: var(--white);
}

.footer-logo span span {
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-info {
    color: var(--text-muted);
    font-size: 0.9rem;
    max-width: 500px;
    line-height: 1.5;
}

.footer-links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: var(--text-dark);
    font-size: 0.85rem;
    font-weight: 500;
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--accent-purple-light);
}

.copyright {
    font-size: 0.75rem;
    color: var(--text-dark);
    margin-top: 0.5rem;
}

@media (max-width: 1250px) {
    .header-left, .header-right {
        gap: 1.25rem;
    }
    
    .main-nav ul {
        gap: 0.8rem;
    }
    
    .search-box {
        width: 180px;
    }
    
    .search-box:focus-within {
        width: 220px;
    }
}

@media (max-width: 1100px) {
    .username {
        display: none;
    }
    
    .header-package-btn {
        display: none;
    }
}

@media (max-width: 950px) {
    .main-nav .nav-link span {
        display: none;
    }
    
    .main-nav .nav-link {
        padding: 0.5rem;
    }
}

/* ==========================================================================
   Responsive Styling (Adaptive UI)
   ========================================================================== */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-section {
        padding: 0 2rem;
        height: 70vh;
    }
    
    .movie-row-section {
        padding: 1.5rem 2rem 0.5rem 2rem;
    }
    
    .search-results-section, .all-movies-section, .watchlist-section {
        padding: 6rem 2rem 2rem 2rem;
    }
}

@media (max-width: 768px) {
    .header-left {
        gap: 1.2rem;
    }
    
    .main-nav {
        display: none; /* Can toggle in a real burger, let's keep headers neat or adapt navigation below */
    }
    
    .search-box {
        width: 180px;
    }
    
    .search-box:focus-within {
        width: 200px;
    }

    .all-movies-section {
        padding: 5.5rem 1rem 2rem 1rem !important;
    }

    .all-movies-section .section-header {
        gap: 0.8rem;
        margin-bottom: 1.2rem;
        padding-bottom: 0.8rem;
    }

    .all-movies-section .section-header h2 {
        font-size: 1.45rem;
    }

    .genre-filter-container {
        gap: 0.5rem;
        padding-bottom: 6px;
    }

    .genre-chip {
        padding: 0.45rem 1rem;
        font-size: 0.82rem;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-section {
        height: 60vh;
    }
    
    .hero-content {
        gap: 0.8rem;
    }
    
    .modal-content-layout {
        flex-direction: column;
        gap: 2rem;
        padding: 2rem 1.5rem;
    }
    
    .modal-col-left, .modal-col-right {
        min-width: 100%;
    }
    
    .modal-poster-wrapper {
        width: 180px;
        height: 260px;
        margin: 0 auto;
    }
    
    .modal-title {
        font-size: 1.8rem;
        text-align: center;
    }

    .modal-rating-stars-row {
        justify-content: center;
    }

    .modal-meta-badges {
        justify-content: center;
    }
    
    .modal-main-buttons {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .modal-action-icons {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    
    .controls-bar {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .video-controls-container {
        padding: 1rem 1.5rem;
    }
    
    .volume-slider {
        width: 50px;
    }
    
    .movies-grid {
        grid-template-columns: repeat(auto-fill, minmax(105px, 1fr));
        gap: 1rem 0.75rem;
    }
    
    .movie-card {
        width: 105px;
    }
    
    .movies-grid .movie-card {
        width: 100%;
    }
    
    .card-poster {
        height: 150px;
    }

    .movie-slider {
        gap: 0.8rem !important;
        padding: 0.5rem 0.25rem 1rem 0.25rem !important;
    }

    .card-bottom-info {
        padding: 0.5rem !important;
    }
    
    .card-title {
        font-size: 0.8rem !important;
        margin-bottom: 0.15rem !important;
    }
    
    .card-meta {
        font-size: 0.65rem !important;
    }
    
    .card-bottom-title {
        font-size: 0.75rem !important;
    }
    
    .card-add-btn {
        opacity: 1 !important;
        width: 26px !important;
        height: 26px !important;
        font-size: 0.75rem !important;
        top: 6px !important;
        left: 6px !important;
    }
    
    .movie-badge {
        top: 6px !important;
        right: 6px !important;
        font-size: 0.55rem !important;
        padding: 0.15rem 0.4rem !important;
    }
}

@media (max-width: 480px) {
    .header-container {
        padding: 0 1rem;
    }
    

    
    .username {
        display: none;
    }
    
    .hero-section {
        height: 55vh;
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-actions {
        flex-wrap: wrap;
    }
    
    .movie-row-section {
        padding: 1.5rem 1rem 0.5rem 1rem;
    }
    
    .slider-btn {
        display: none !important; /* Touch scrolling is fine on mobile */
    }
}

/* ==========================================================================
   New Layout Additions: Card watchlist buttons, Hero thumbnails, Light-theme overrides
   ========================================================================== */

/* Floating watchlist button on cards */
.card-add-btn {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(15, 15, 24, 0.75);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(8px);
    color: #ffffff; /* Always white on dark posters */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    z-index: 10;
    transition: var(--transition-smooth);
    opacity: 0;
    pointer-events: auto;
}

.movie-card:hover .card-add-btn,
.card-add-btn.added {
    opacity: 1;
}

.card-add-btn:hover {
    transform: scale(1.15);
    background: var(--accent-purple);
    border-color: var(--accent-purple-light);
    color: #ffffff;
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

.card-add-btn.added {
    background: var(--accent-purple);
    border-color: var(--accent-purple-light);
    color: #ffffff;
}

/* Hero spotlight thumbnail previews */
.hero-thumbnails {
    position: absolute;
    bottom: 2.5rem;
    right: 4rem;
    display: flex;
    gap: 1rem;
    z-index: 4;
}

.hero-thumb {
    width: 100px;
    height: 60px;
    border-radius: 8px;
    background-size: cover;
    background-position: center;
    border: 2px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.hero-thumb::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    transition: var(--transition-fast);
}

.hero-thumb.active {
    border-color: var(--accent-purple);
    box-shadow: 0 0 15px var(--accent-purple-glow);
    transform: scale(1.08) translateY(-4px);
}

.hero-thumb.active::after {
    background: rgba(0, 0, 0, 0);
}

.hero-thumb:hover::after {
    background: rgba(0, 0, 0, 0.15);
}

@media (max-width: 1024px) {
    .hero-thumbnails {
        right: 2rem;
    }
}

@media (max-width: 768px) {
    .hero-thumbnails {
        display: none; /* Hide thumbnails on mobile to make room */
    }
}

/* Light Theme overrides for modal and background glow */
body.light-theme .bg-glow {
    opacity: 0.08;
}

body.light-theme .modal-container {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 20px 50px rgba(148, 163, 184, 0.15);
}

body.light-theme .modal-container::before {
    filter: blur(40px) brightness(0.9);
    opacity: 0.15;
}

body.light-theme .meta-badge {
    background: rgba(15, 23, 42, 0.05);
    border: 1px solid rgba(15, 23, 42, 0.05);
    color: var(--text-muted);
}

body.light-theme .btn-outline-trailer {
    border: 1px solid rgba(15, 23, 42, 0.15);
    background: rgba(15, 23, 42, 0.03);
    color: var(--text-primary);
}

body.light-theme .btn-outline-trailer:hover {
    background: rgba(15, 23, 42, 0.06);
}

body.light-theme .modal-action-icons {
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

body.light-theme .modal-credits {
    border-top: 1px dashed rgba(15, 23, 42, 0.1);
}

body.light-theme .rec-thumbnail-card {
    border: 1px solid rgba(15, 23, 42, 0.08);
}

body.light-theme .hero-overlay {
    background: linear-gradient(to right, var(--bg-primary) 0%, rgba(241, 245, 249, 0.75) 30%, rgba(241, 245, 249, 0) 100%),
                linear-gradient(to top, var(--bg-primary) 0%, rgba(241, 245, 249, 0.35) 50%, rgba(241, 245, 249, 0) 100%);
}

/* Double-check light theme details */
body.light-theme .app-header {
    background: linear-gradient(to bottom, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.92) 50%, rgba(255, 255, 255, 0.7) 75%, rgba(255, 255, 255, 0) 100%);
    box-shadow: 0 4px 25px rgba(15, 23, 42, 0.04);
}

body.light-theme .app-header.scrolled {
    background: var(--glass-bg);
    box-shadow: 0 4px 25px rgba(15, 23, 42, 0.08);
    border-bottom: 1px solid rgba(15, 23, 42, 0.05);
}

/* ==========================================================================
   New Layout Additions: Registration Screen, E-Wallet, Rent Checkout
   ========================================================================== */

/* Auth Screen Styling */
.auth-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(5, 5, 8, 0.9);
    backdrop-filter: blur(25px);
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

body.light-theme .auth-overlay {
    background: rgba(241, 245, 249, 0.9);
}

.auth-card {
    width: 90%;
    max-width: 420px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    padding: 3rem 2.5rem;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    animation: authCardFade 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes authCardFade {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-logo {
    display: flex;
    justify-content: center;
}

.auth-logo-img {
    height: 56px;
    object-fit: contain;
}

.auth-card h2 {
    font-size: 1.8rem;
    font-weight: 800;
}

.auth-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: left;
    margin-bottom: 1rem;
}

.input-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-with-icon {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    position: relative;
    transition: var(--transition-fast);
}

body.light-theme .input-with-icon {
    background: rgba(15, 23, 42, 0.03);
}

.input-with-icon:focus-within {
    border-color: var(--accent-purple);
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

.input-with-icon i {
    color: var(--text-muted);
    margin-right: 0.75rem;
}

.country-code {
    font-weight: 700;
    color: var(--text-primary);
    margin-right: 0.5rem;
    user-select: none;
}

.input-with-icon input {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 0.95rem;
    width: 100%;
}


.btn-auth-submit {
    width: 100%;
    padding: 0.85rem;
    border-radius: 10px;
    font-size: 1rem;
}

/* Wallet widget in Navbar */
.header-wallet {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.9rem;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 30px;
    cursor: pointer;
    font-weight: 700;
    color: var(--accent-purple-light);
    position: relative;
    transition: var(--transition-fast);
}

.header-wallet:hover {
    background: rgba(139, 92, 246, 0.2);
    border-color: var(--accent-purple);
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

/* Wallet TopUp Amount Pill Buttons */
.btn-pill-amount {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--white);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-pill-amount:hover, .btn-pill-amount.active {
    background: rgba(16, 185, 129, 0.2);
    border-color: #10b981;
    color: #10b981;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.25);
}

/* QPay Payment Tabs & App Grid */
.payment-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 1rem;
    width: 100%;
}

.payment-tab-btn {
    flex: 1;
    padding: 0.6rem 0.5rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.payment-tab-btn.active {
    background: rgba(139, 92, 246, 0.15);
    border-color: var(--accent-purple-light);
    color: var(--white);
}

.qpay-qr-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #ffffff;
    padding: 1.1rem;
    border-radius: 16px;
    margin-bottom: 0.8rem;
    position: relative;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

.qpay-qr-img {
    width: 150px;
    height: 150px;
    object-fit: contain;
}

.qpay-apps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 0.5rem;
    width: 100%;
}

.qpay-app-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 0.6rem 0.4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.qpay-app-card:hover {
    background: rgba(139, 92, 246, 0.2);
    border-color: var(--accent-purple-light);
    transform: translateY(-2px);
}

.qpay-app-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #fff;
}

.qpay-app-name {
    font-size: 0.72rem;
    font-weight: 600;
    color: #ffffff;
    text-align: center;
}

.wallet-balance {
    font-size: 0.9rem;
    font-family: 'Montserrat', 'Inter', sans-serif;
}

/* Wallet Dropdown Panel */
.wallet-dropdown {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    width: 280px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    z-index: 150;
    cursor: default;
}

.wallet-dropdown h3 {
    font-size: 1.1rem;
    font-weight: 700;
    text-align: left;
    margin-bottom: -0.25rem;
}

.wallet-phone {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: left;
}

.wallet-balance-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

body.light-theme .wallet-balance-box {
    background: rgba(15, 23, 42, 0.02);
}

.wallet-balance-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.wallet-balance-val {
    font-size: 1.3rem;
    font-weight: 800;
    font-family: 'Montserrat', 'Inter', sans-serif;
    color: var(--accent-purple-light);
}

.wallet-transactions {
    text-align: left;
}

.wallet-transactions h4 {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
}

.tx-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 120px;
    overflow-y: auto;
}

.tx-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    padding: 0.4rem 0.5rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
    border-left: 3px solid var(--text-dark);
}

.tx-item.green {
    border-left-color: #10b981;
    color: var(--text-primary);
}

.tx-item.red {
    border-left-color: var(--accent-rose);
    color: var(--text-primary);
}

.btn-logout {
    width: 100%;
    padding: 0.5rem;
    border-radius: 8px;
    font-size: 0.85rem;
    gap: 0.4rem;
    border: 1px solid var(--glass-border);
}

/* Rent Modal Container styles */
.rent-container {
    width: 90%;
    max-width: 400px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
}

body.light-theme .rent-container {
    background-color: var(--bg-secondary);
    border-color: var(--glass-border);
}

/* Role Cards styling for Admin Modal - Theme Adaptive */
.role-card-box {
    padding: 12px 6px;
    text-align: center;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.25s ease;
    user-select: none;
}
.role-card-box i {
    font-size: 1.25rem;
    display: block;
    margin-bottom: 5px;
}
.role-card-box .role-card-title {
    font-weight: 700;
    font-size: 0.85rem;
    display: block;
    color: var(--text-main);
}
.role-card-box .role-card-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
}
.role-card-box:hover {
    border-color: rgba(139, 92, 246, 0.5);
    transform: translateY(-2px);
}
.role-card-box.active {
    background: rgba(139, 92, 246, 0.22) !important;
    border-color: #8b5cf6 !important;
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.35) !important;
}

body.light-theme .role-card-box {
    background: rgba(15, 23, 42, 0.04);
    border-color: rgba(0, 0, 0, 0.1);
}
body.light-theme .role-card-box .role-card-title {
    color: #0f172a;
}
body.light-theme .role-card-box .role-card-sub {
    color: #64748b;
}
body.light-theme .role-card-box.active {
    background: rgba(139, 92, 246, 0.14) !important;
    border-color: #7c3aed !important;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.2) !important;
}
body.light-theme .role-card-box.active .role-card-title {
    color: #5b21b6 !important;
}
body.light-theme .role-card-box.active .role-card-sub {
    color: #6d28d9 !important;
}

/* Styled Select Input - Theme Adaptive */
.styled-role-select {
    width: 100%;
    padding: 0.75rem 0.9rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
    outline: none;
    cursor: pointer;
    transition: all 0.2s ease;
}
.styled-role-select option {
    background: #0f172a;
    color: #ffffff;
}
body.light-theme .styled-role-select {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    color: #0f172a;
}
body.light-theme .styled-role-select option {
    background: #ffffff;
    color: #0f172a;
}

.rent-icon-box {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.15);
    border: 2px solid var(--accent-purple);
    color: var(--accent-purple-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    box-shadow: 0 0 15px var(--accent-purple-glow);
}

.rent-container h2 {
    font-size: 1.5rem;
    font-weight: 800;
}

.rent-container p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.rent-details {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    text-align: left;
}

body.light-theme .rent-details {
    background: rgba(15, 23, 42, 0.02);
}

.rent-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.rent-row.bold {
    font-weight: 700;
    font-size: 0.95rem;
}

.rent-details hr {
    border: none;
    border-top: 1px solid var(--glass-border);
    margin: 0.25rem 0;
}

.red-text {
    color: var(--accent-rose);
    font-weight: 700;
}

.rent-actions {
    display: flex;
    gap: 0.75rem;
    width: 100%;
    margin-top: 0.5rem;
}

.rent-actions .btn {
    flex: 1;
    padding: 0.7rem;
    font-size: 0.9rem;
    border-radius: 10px;
}

/* ==========================================================================
   New Layout Additions: Profile Page, User Avatar Uploads, Profile Dropdown
   ========================================================================== */

/* Redesigned Theme Color variables matching main design */
:root {
    --accent-teal: var(--accent-purple-light);
    --accent-teal-glow: var(--accent-purple-glow);
    --bg-dark-card: #11111f;
}

/* Header navbar profile widget custom styles */
.header-profile-avatar-container {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--accent-teal);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent-teal-glow);
    transition: var(--transition-fast);
}

.header-profile-avatar-container:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px var(--accent-teal-glow);
}

.header-avatar-letter {
    color: #08080c;
    font-weight: 800;
    font-size: 1.15rem;
    font-family: 'Montserrat', 'Inter', sans-serif;
    user-select: none;
}

.user-profile .profile-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Navbar Package Button */
.header-package-btn {
    border: 1px solid var(--accent-teal);
    color: var(--accent-teal);
    background: none;
    font-size: 0.9rem;
    font-weight: 700;
    padding: 0.45rem 1.25rem;
    border-radius: 20px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: var(--transition-smooth);
}

.header-package-btn:hover {
    background: rgba(139, 92, 246, 0.1);
    box-shadow: 0 0 10px var(--accent-teal-glow);
    transform: translateY(-1px);
}

/* Redesigned Profile Dropdown (Text-only, no icons) */
.profile-dropdown {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    width: 180px;
    background: rgba(15, 15, 24, 0.95);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    z-index: 150;
    cursor: default;
}

.profile-dropdown-item {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0.6rem 1rem;
    text-align: left;
    border-radius: 8px;
    width: 100%;
    cursor: pointer;
    transition: var(--transition-fast);
    font-family: 'Inter', sans-serif;
}

.profile-dropdown-item:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
}

.profile-dropdown hr {
    border: none;
    border-top: 1px solid var(--glass-border);
    margin: 0.25rem 0;
}

.profile-dropdown-item.logout-item {
    color: #ff4757;
}

.profile-dropdown-item.logout-item:hover {
    background: rgba(255, 71, 87, 0.1);
}

/* Redesigned Profile Section */
.profile-section {
    padding: 6.5rem 4rem 4rem 4rem;
    min-height: 80vh;
}

.profile-header-block {
    margin-bottom: 2rem;
}

.profile-header-block h2 {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}


.profile-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2.5rem;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

/* Profile Left Card Styles */
.profile-card-left {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: var(--card-shadow);
    height: fit-content;
}

.profile-avatar-wrapper {
    position: relative;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 2px solid var(--accent-teal);
    box-shadow: 0 0 15px var(--accent-teal-glow);
    margin-bottom: 1rem;
}

.profile-avatar-letter-circle {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--accent-teal);
    display: flex;
    align-items: center;
    justify-content: center;
}

#profile-page-avatar-letter {
    font-size: 3.2rem;
    font-weight: 800;
    color: #08080c;
    font-family: 'Montserrat', 'Inter', sans-serif;
    user-select: none;
}

.profile-page-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.profile-card-left h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.5rem;
    font-family: 'Montserrat', 'Inter', sans-serif;
}

.profile-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 0.3rem 0.8rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #94a3b8;
}

.profile-status-badge.active-user .status-dot {
    background: #10b981;
}

.profile-status-badge.active-user span {
    color: #10b981;
}

/* Profile Stats grid */
.profile-stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    width: 100%;
    margin-bottom: 1.5rem;
}

.profile-stat-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.stat-num {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--white);
    font-family: 'Montserrat', 'Inter', sans-serif;
}

.stat-lbl {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Subscribe and Logout Left Card buttons */
.btn-subscribe {
    width: 100%;
    background: var(--accent-teal);
    color: #08080c;
    border: none;
    font-weight: 700;
    padding: 0.75rem;
    border-radius: 10px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.2);
}

.btn-subscribe:hover {
    background: #c4b5fd;
    box-shadow: 0 0 15px var(--accent-teal-glow);
    transform: translateY(-1px);
}

.btn-logout-dark {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--white);
    font-weight: 600;
    padding: 0.7rem;
    border-radius: 10px;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    transition: var(--transition-fast);
}

.btn-logout-dark:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--accent-rose);
    border-color: rgba(244, 63, 94, 0.2);
}

/* Profile Right Cards layout */
.profile-card-right {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

.profile-card-block {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--card-shadow);
}

/* Profile Settings Block */
.settings-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.settings-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 0;
    border-bottom: 1px dashed var(--glass-border);
}

.settings-row:last-child {
    border-bottom: none;
}

.settings-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
}

.theme-settings-toggle {
    display: flex;
    background: rgba(0, 0, 0, 0.25);
    padding: 0.25rem;
    border-radius: 30px;
    border: 1px solid var(--glass-border);
}

body.light-theme .theme-settings-toggle {
    background: rgba(15, 23, 42, 0.05);
}

.theme-select-btn {
    background: none;
    border: none;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: var(--transition-fast);
}

.theme-select-btn:hover {
    color: var(--text-primary);
}

.theme-select-btn.active {
    background: var(--accent-purple);
    color: #ffffff;
    box-shadow: 0 4px 10px var(--accent-purple-glow);
}

.notif-settings-toggles {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.settings-switch-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.settings-switch-container input[type="checkbox"] {
    position: relative;
    width: 44px;
    height: 24px;
    appearance: none;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    outline: none;
    cursor: pointer;
    transition: background 0.3s ease;
}

body.light-theme .settings-switch-container input[type="checkbox"] {
    background: rgba(15, 23, 42, 0.1);
}

.settings-switch-container input[type="checkbox"]::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ffffff;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.settings-switch-container input[type="checkbox"]:checked {
    background: var(--accent-purple);
}

.settings-switch-container input[type="checkbox"]:checked::before {
    transform: translateX(20px);
    background: #ffffff;
}

.switch-label {
    font-weight: 500;
    transition: var(--transition-fast);
}

.settings-switch-container input[type="checkbox"]:checked ~ .switch-label {
    color: var(--text-primary);
}

/* Registration Info Block */
.info-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px dashed var(--glass-border);
    padding-bottom: 0.75rem;
    margin-bottom: 1.5rem;
}

.info-card-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
}

.info-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-dark);
}

/* Collapsible Registration Info Block */
.profile-card-block.info-card.collapsed {
    padding-bottom: 1.25rem;
}

.profile-card-block.info-card.collapsed .info-card-header {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.profile-card-block.info-card.collapsed .info-grid,
.profile-card-block.info-card.collapsed .wallet-transactions {
    display: none !important;
}

/* Toggle chevron styling */
.info-toggle-arrow {
    font-size: 1.15rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: transform 0.3s ease, color 0.2s ease;
    padding: 0.5rem;
    margin: -0.5rem;
}

.info-toggle-arrow:hover {
    color: var(--accent-purple-light);
}

.profile-card-block.info-card:not(.collapsed) .info-toggle-arrow {
    transform: rotate(180deg);
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.info-grid-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.info-grid-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-grid-value {
    font-size: 0.95rem;
    color: var(--white);
    font-weight: 500;
}

.info-grid-link {
    font-size: 0.95rem;
    color: var(--accent-teal);
    font-weight: 600;
    transition: var(--transition-fast);
    text-decoration: none;
    width: fit-content;
}

.info-grid-link:hover {
    color: #c4b5fd;
    text-shadow: 0 0 10px rgba(139, 92, 246, 0.3);
}

.info-grid-balance-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.info-grid-balance-row .toggle-balance-btn {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.info-grid-balance-row .toggle-balance-btn:hover {
    color: var(--accent-teal);
}

/* Security Block styles */
.security-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--accent-rose);
    margin-bottom: 0.75rem;
}

.security-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

.btn-delete-account {
    background: none;
    border: 1px solid var(--accent-rose);
    color: var(--accent-rose);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.55rem 1.25rem;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: var(--transition-fast);
}

.btn-delete-account:hover {
    background: rgba(244, 63, 94, 0.1);
    box-shadow: 0 0 10px rgba(244, 63, 94, 0.2);
}

/* Custom styles for transaction log history below registration grid */
.info-card .wallet-transactions {
    margin-top: 2rem;
    border-top: 1px dashed var(--glass-border);
    padding-top: 1.5rem;
}

.info-card .wallet-transactions h4 {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}

/* Package Modal Styling */
.package-container {
    width: 90%;
    max-width: 560px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    animation: authCardFade 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.package-icon-box {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.15);
    border: 2px solid var(--accent-teal);
    color: var(--accent-teal);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    box-shadow: 0 0 15px var(--accent-teal-glow);
}

.package-container h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--white);
}

.package-container p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.package-options {
    width: 100%;
}

.package-option-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 1.5rem 1.25rem 1.25rem 1.25rem;
    text-align: left;
    position: relative;
    cursor: pointer;
    transition: var(--transition-fast);
}

.package-option-card.active {
    border-color: var(--accent-teal);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.15);
    background: rgba(139, 92, 246, 0.04);
}

.package-badge {
    position: absolute;
    top: -12px;
    right: 14px;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.2rem 0.65rem;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
    letter-spacing: 0.5px;
    white-space: nowrap;
    z-index: 2;
}

.package-option-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--white);
    margin-top: 0.2rem;
    margin-bottom: 0.35rem;
    line-height: 1.3;
}

.package-price {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--accent-teal);
    font-family: 'Montserrat', 'Inter', sans-serif;
    margin-bottom: 0.4rem;
    display: flex;
    align-items: baseline;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.package-price span {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
    white-space: nowrap;
}

.package-option-desc {
    font-size: 0.78rem !important;
    line-height: 1.45 !important;
    color: var(--text-muted);
}

.package-wallet-info {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: left;
}

.package-wallet-info .rent-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
}

.package-wallet-info .rent-row.bold {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--accent-teal);
}

.package-actions {
    display: flex;
    gap: 0.75rem;
    width: 100%;
}

.package-actions .btn {
    flex: 1;
    padding: 0.75rem;
    font-size: 0.9rem;
    border-radius: 10px;
}

/* Responsive Styles for redesigned profile container */
@media (max-width: 868px) {
    .profile-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

@media (max-width: 480px) {
    .profile-section {
        padding: 6rem 1.5rem 2rem 1.5rem;
    }
    .info-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* ==========================================================================
   Mobile Bottom Navigation & Sizing Overrides
   ========================================================================== */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: rgba(15, 15, 24, 0.95);
    backdrop-filter: blur(15px);
    border-top: 1px solid var(--glass-border);
    justify-content: space-around;
    align-items: center;
    z-index: 200;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
}

@media (max-width: 768px) {
    body {
        padding-bottom: 60px; /* Space for bottom nav bar */
    }
    
    .mobile-bottom-nav {
        display: flex;
    }
    
    .mobile-bottom-nav .nav-link {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        color: var(--text-muted) !important;
        font-size: 0.7rem !important;
        font-weight: 500 !important;
        gap: 0.2rem !important;
        flex: 1 !important;
        height: 100% !important;
        padding: 0 !important;
        background: none !important;
        border: none !important;
        border-radius: 0 !important;
    }
    
    .mobile-bottom-nav .nav-link i {
        font-size: 1.15rem !important;
        margin: 0 !important;
    }
    
    .mobile-bottom-nav .nav-link.active {
        color: var(--accent-purple-light) !important;
        text-shadow: 0 0 10px var(--accent-purple-glow) !important;
    }
    
    /* Header layout overrides for spacing */
    .app-header {
        padding: 0.9rem 0 !important;
    }

    .header-left {
        gap: 1rem !important;
    }
    
    .logo-img {
        height: 46px !important;
    }
    
    .main-nav {
        display: none !important;
    }
    
    .search-box {
        width: 150px !important;
        padding: 0.45rem 0.9rem !important;
    }
    
    .search-box:focus-within {
        width: 180px !important;
    }
    
    .header-package-btn {
        display: none !important;
    }
    
    .header-right {
        gap: 1.2rem !important;
    }
    
    .header-action-btn {
        width: 44px !important;
        height: 44px !important;
        font-size: 1.35rem !important;
    }
    
    .header-profile-avatar-container {
        width: 40px !important;
        height: 40px !important;
    }
    
    .user-profile {
        padding: 0.2rem !important;
        background: none !important;
        border: none !important;
    }
    
    .profile-dropdown {
        top: calc(100% + 0.5rem) !important;
        right: 0 !important;
        width: 160px !important;
    }
}

@media (max-width: 480px) {
    .app-header {
        padding: 0.6rem 0 !important;
    }

    .header-left {
        gap: 0.6rem !important;
    }
    
    .logo-img {
        height: 38px !important;
    }

    .search-box {
        width: 105px !important;
        padding: 0.3rem 0.6rem !important;
    }
    
    .search-box:focus-within {
        width: 125px !important;
    }
    
    .header-right {
        gap: 0.6rem !important;
    }
    
    .header-action-btn {
        width: 36px !important;
        height: 36px !important;
        font-size: 1.1rem !important;
    }
    
    .header-profile-avatar-container {
        width: 34px !important;
        height: 34px !important;
    }
    
    .auth-card,
    .rent-container,
    .package-container {
        padding: 2rem 1.25rem !important;
    }
}

/* ==========================================================================
   Notifications Dropdown Styles
   ========================================================================== */
.notif-dropdown {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    width: 300px;
    background: rgba(15, 15, 24, 0.95);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    z-index: 150;
    cursor: default;
    animation: authCardFade 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.notif-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 0.5rem;
    margin-bottom: 0.25rem;
}

.notif-dropdown-header span {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--white);
    font-family: 'Montserrat', 'Inter', sans-serif;
}

.notif-clear-all {
    font-size: 0.7rem;
    color: var(--accent-purple-light);
    font-weight: 600;
    cursor: pointer;
    background: none;
    border: none;
    transition: var(--transition-fast);
}

.notif-clear-all:hover {
    color: #c4b5fd;
    text-shadow: 0 0 8px var(--accent-purple-glow);
}

.notif-list {
    max-height: 250px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-right: 0.25rem;
}

.notif-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.6rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    transition: var(--transition-fast);
    text-align: left;
}

.notif-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(139, 92, 246, 0.2);
}

.notif-item.unread {
    border-left: 3px solid var(--accent-purple-light);
    background: rgba(139, 92, 246, 0.03);
}

.notif-icon-box {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.notif-item.unread .notif-icon-box {
    background: rgba(139, 92, 246, 0.25);
    color: #ffffff;
    box-shadow: 0 0 8px var(--accent-purple-glow);
}

.notif-item-content {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.notif-item-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--white);
}

.notif-item-desc {
    font-size: 0.7rem;
    color: var(--text-muted);
    line-height: 1.3;
}

.notif-item-time {
    font-size: 0.65rem;
    color: var(--text-dark);
    margin-top: 0.1rem;
}

.notif-empty {
    text-align: center;
    padding: 1.5rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.notif-empty i {
    font-size: 1.5rem;
    color: var(--text-dark);
}

/* ==========================================================================
   Light Theme Dropdowns Overrides
   ========================================================================== */
body.light-theme .notif-dropdown,
body.light-theme .profile-dropdown {
    background: rgba(255, 255, 255, 0.98);
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.1);
}

body.light-theme .profile-dropdown-item {
    color: var(--text-primary);
}

body.light-theme .profile-dropdown-item:hover {
    background: rgba(15, 23, 42, 0.04);
}

body.light-theme .notif-item {
    background: rgba(15, 23, 42, 0.02);
    border-color: rgba(15, 23, 42, 0.04);
}

body.light-theme .notif-item:hover {
    background: rgba(15, 23, 42, 0.04);
    border-color: rgba(124, 58, 237, 0.15);
}

body.light-theme .notif-clear-all:hover {
    color: var(--accent-purple);
    text-shadow: none;
}

/* ==========================================================================
   Admin Control Panel Styles
   ========================================================================== */
.admin-section {
    padding: 6.5rem 4rem 4rem 4rem;
    min-height: 80vh;
}

.btn-close-admin {
    background: none;
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: var(--transition-fast);
}

.btn-close-admin:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
}

.admin-tabs {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 0.75rem;
}

.admin-tab-btn {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 0.6rem 1.25rem;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-smooth);
}

.admin-tab-btn:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
}

.admin-tab-btn.active {
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    color: var(--white);
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.2);
}

.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    box-shadow: var(--card-shadow);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(139, 92, 246, 0.1);
    color: var(--accent-purple-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.stat-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-number {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--white);
    font-family: 'Montserrat', 'Inter', sans-serif;
}

.admin-block {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
}

.admin-block h3 {
    margin-bottom: 1rem;
    font-size: 1.15rem;
    font-weight: 700;
}

.admin-split-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .admin-split-layout {
        grid-template-columns: 1.2fr 0.8fr;
    }
}

.admin-list-card, .admin-form-card {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    height: fit-content;
}

.card-header-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}

.admin-table-wrapper {
    overflow-x: auto;
    width: 100%;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.85rem;
}

.admin-table th, .admin-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--glass-border);
    vertical-align: middle;
}

.admin-table th {
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.admin-table tbody tr {
    transition: var(--transition-fast);
}

.admin-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.01);
}

.admin-table td img {
    border-radius: 4px;
    object-fit: cover;
}

.admin-table td .btn-action {
    background: none;
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    border-radius: 6px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.admin-table td .btn-action:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
}

.admin-table td .btn-action.btn-delete:hover {
    color: var(--accent-rose);
    border-color: rgba(244, 63, 94, 0.2);
    background: rgba(244, 63, 94, 0.1);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    margin-bottom: 1.25rem;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
}

.form-group input, .form-group textarea, .form-group select {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 0.65rem 0.9rem;
    border-radius: 8px;
    color: var(--white);
    font-size: 0.9rem;
    transition: var(--transition-fast);
}

.form-group input:focus, .form-group textarea:focus {
    border-color: var(--accent-purple);
    box-shadow: 0 0 8px var(--accent-purple-glow);
    outline: none;
}

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-row-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
}

.form-actions .btn {
    flex: 1;
    padding: 0.65rem;
    border-radius: 8px;
    font-size: 0.9rem;
}

/* Code Explorer Styling */
.code-explorer-container {
    background: #0d0e15;
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 600px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.code-explorer-header {
    background: #151622;
    padding: 0.75rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.file-tabs {
    display: flex;
    gap: 0.5rem;
}

.file-tab-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.file-tab-btn:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
}

.file-tab-btn.active {
    color: var(--accent-purple-light);
    background: rgba(139, 92, 246, 0.1);
}

.code-display-wrapper {
    flex: 1;
    overflow: auto;
    padding: 1.5rem;
}

.code-pre {
    margin: 0;
    font-family: 'Consolas', 'Fira Code', 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    color: #e2e8f0;
    text-align: left;
    white-space: pre;
}

/* Light Theme Admin Styling overrides */
body.light-theme .admin-tab-btn {
    background: rgba(15, 23, 42, 0.02);
}

body.light-theme .admin-tab-btn:hover {
    background: rgba(15, 23, 42, 0.04);
    color: var(--text-primary);
}

body.light-theme .admin-tab-btn.active {
    color: var(--white);
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
}

body.light-theme .stat-card,
body.light-theme .admin-block,
body.light-theme .admin-list-card,
body.light-theme .admin-form-card {
    background: var(--bg-secondary);
    border-color: rgba(15, 23, 42, 0.08);
}

body.light-theme .stat-number {
    color: var(--text-primary);
}

body.light-theme .admin-table tbody tr:hover {
    background: rgba(15, 23, 42, 0.02);
}

body.light-theme .form-group input,
body.light-theme .form-group textarea,
body.light-theme .form-group select {
    background: rgba(15, 23, 42, 0.02);
    border-color: rgba(15, 23, 42, 0.1);
    color: var(--text-primary);
}

body.light-theme .code-explorer-container {
    background: #f8fafc;
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
}

body.light-theme .code-explorer-header {
    background: #f1f5f9;
    border-bottom-color: rgba(15, 23, 42, 0.08);
}

body.light-theme .code-pre {
    color: #1e293b;
}

body.light-theme .file-tab-btn:hover {
    color: var(--text-primary);
    background: rgba(15, 23, 42, 0.04);
}

body.light-theme .file-tab-btn.active {
    color: var(--accent-purple);
    background: rgba(139, 92, 246, 0.1);
}

@media (max-width: 768px) {
    .admin-section {
        padding: 5.5rem 1.5rem 5rem 1.5rem;
    }
    
    .admin-tabs {
        overflow-x: auto;
        padding-bottom: 0.5rem;
        gap: 0.5rem;
    }
    
    .admin-tab-btn {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
        flex-shrink: 0;
    }
}

/* SMS Toast Notification */
.sms-toast {
    position: fixed;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 15, 24, 0.85);
    border: 1px solid rgba(139, 92, 246, 0.3);
    backdrop-filter: blur(12px);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), 0 0 15px rgba(139, 92, 246, 0.2);
    z-index: 9999;
    width: 90%;
    max-width: 400px;
    transition: top 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.sms-toast.show {
    top: 20px;
}

.sms-toast-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-rose) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.2rem;
}

.sms-toast-content {
    flex: 1;
}

.sms-toast-title {
    display: block;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--accent-purple-light);
    margin-bottom: 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sms-toast-body {
    display: block;
    font-size: 0.9rem;
    color: var(--white);
}

/* Auth Card Custom Welcome Badge & Lock Circle */
.auth-card {
    position: relative;
}

.auth-badge-required {
    position: absolute;
    top: 25px;
    left: 25px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #10b981;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.auth-badge-required::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #10b981;
    box-shadow: 0 0 8px #10b981;
}

.auth-icon-circle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-purple-light);
    font-size: 1.5rem;
    margin: 0.5rem auto 1.5rem auto;
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.15);
}

.step-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    color: var(--white);
    text-align: center;
}

.step-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1.5rem;
    text-align: center;
}

/* ==========================================================================
   d-ertunts Alignment Styles (Iframe Embed, Paywall Banner, Episodes & Modals)
   ========================================================================== */

/* Iframe Embed in Video Container */
#embed-iframe {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    background: #000;
}

/* Paywall Buy Banner Overlay inside Video Player (d-ertunts style) */
.player-buy-banner {
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 95px;
    z-index: 320;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 1rem 1.5rem;
    background: rgba(15, 15, 24, 0.88);
    backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    pointer-events: auto;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.buy-banner__title {
    margin: 0 0 4px;
    font-size: 1.15rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
}

.buy-banner__desc {
    margin: 0;
    font-size: 0.85rem;
    color: #b7bec9;
    line-height: 1.4;
}

.buy-banner__btns {
    flex-shrink: 0;
    display: flex;
    gap: 12px;
}

.buy-banner__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 999px;
    border: none;
    background: #10b981;
    color: #ffffff;
    font: 700 0.88rem/1 Inter, sans-serif;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.buy-banner__btn:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.buy-banner__btn--outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: none;
}

.buy-banner__btn--outline:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: none;
}

@media (max-width: 650px) {
    .player-buy-banner {
        left: 10px;
        right: 10px;
        bottom: 85px;
        flex-direction: column;
        align-items: stretch;
        padding: 1rem;
        gap: 12px;
    }
    .buy-banner__btns {
        flex-direction: column;
        gap: 8px;
    }
    .buy-banner__btn {
        justify-content: center;
        padding: 10px 16px;
    }
}

/* Modal Episodes List (Series & Short Dramas) */
.modal-episodes-section {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--glass-border);
}

.episodes-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.episodes-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 220px;
    overflow-y: auto;
    padding-right: 4px;
}

.episode-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.episode-item:hover {
    background: rgba(139, 92, 246, 0.15);
    border-color: var(--accent-purple-light);
    transform: translateX(3px);
}

.episode-item.active {
    background: rgba(139, 92, 246, 0.25);
    border-color: var(--accent-purple);
}

.episode-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--white);
}

.episode-badge {
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 700;
}

.episode-badge.free {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.episode-badge.locked {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Package Options 4-grid Layout */
.package-options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin: 1.5rem 0;
    width: 100%;
}

@media (max-width: 550px) {
    .package-options-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.package-option-card.gold {
    border-color: rgba(251, 191, 36, 0.4);
    background: rgba(251, 191, 36, 0.04);
}

.package-option-card.gold.active {
    border-color: #fbbf24;
    box-shadow: 0 0 18px rgba(251, 191, 36, 0.25);
}

.package-option-card.gold .package-badge {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.package-option-card.gold .package-price {
    color: #fbbf24;
}

/* Info Document Modal (Terms & Privacy) */
.info-doc-container {
    width: 90%;
    max-width: 650px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.2rem 2rem;
    box-shadow: var(--card-shadow);
    position: relative;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
}

.info-doc-body h2 {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 1.25rem;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 10px;
}

.doc-text-content {
    overflow-y: auto;
    max-height: 50vh;
    padding-right: 8px;
    line-height: 1.6;
    color: #c8d0dd;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.doc-text-content h4 {
    color: var(--white);
    font-size: 1.05rem;
    margin: 1rem 0 0.4rem 0;
}

.doc-actions {
    display: flex;
    justify-content: flex-end;
}

/* Loyal VIP Pink Frame & Badge (3+ Renewals) */
.loyal-vip-pink-frame {
    border: 3px solid transparent !important;
    border-radius: 50% !important;
    background-image: linear-gradient(#0f172a, #0f172a), linear-gradient(135deg, #ec4899, #f43f5e, #d946ef, #a855f7) !important;
    background-origin: border-box !important;
    background-clip: content-box, border-box !important;
    box-shadow: 0 0 16px rgba(236, 72, 153, 0.85), 0 0 28px rgba(217, 70, 239, 0.5) !important;
    animation: pinkVipGlowPulse 2.5s infinite alternate ease-in-out !important;
    position: relative;
}

body.light-theme .loyal-vip-pink-frame {
    background-image: linear-gradient(#ffffff, #ffffff), linear-gradient(135deg, #ec4899, #f43f5e, #d946ef, #a855f7) !important;
}

@keyframes pinkVipGlowPulse {
    0% {
        box-shadow: 0 0 12px rgba(236, 72, 153, 0.7), 0 0 24px rgba(217, 70, 239, 0.4);
    }
    100% {
        box-shadow: 0 0 24px rgba(236, 72, 153, 0.95), 0 0 38px rgba(217, 70, 239, 0.7);
    }
}

.loyal-vip-pink-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: linear-gradient(135deg, #ec4899 0%, #d946ef 100%);
    color: #ffffff !important;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.3px;
    box-shadow: 0 0 14px rgba(236, 72, 153, 0.6);
    margin-top: 6px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* ==========================================================================
   Device Limit Management & Alert Notice CSS
   ========================================================================== */
.device-card {
    background: rgba(20, 20, 32, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
}

.device-count-badge {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple-light);
    border: 1px solid rgba(139, 92, 246, 0.3);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 700;
}

.device-alert-box {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.14) 0%, rgba(239, 68, 68, 0.08) 100%);
    border: 1px solid rgba(245, 158, 11, 0.35);
    border-radius: 12px;
    padding: 1rem 1.2rem;
    margin-top: 1rem;
    margin-bottom: 1.2rem;
}

.device-alert-icon {
    font-size: 1.4rem;
    color: #f59e0b;
    flex-shrink: 0;
    margin-top: 2px;
}

.device-alert-text {
    font-size: 0.88rem;
    color: var(--white);
    line-height: 1.5;
}

.device-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.device-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    padding: 0.85rem 1.1rem;
    transition: var(--transition-fast);
}

.device-item:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(139, 92, 246, 0.25);
}

.device-info {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.device-icon-wrapper {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.device-details {
    display: flex;
    flex-direction: column;
}

.device-name {
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.current-device-tag {
    font-size: 0.68rem;
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
    padding: 1px 7px;
    border-radius: 4px;
    font-weight: 700;
}

.device-time {
    font-size: 0.76rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.btn-remove-device {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
    padding: 0.35rem 0.75rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
}

.btn-remove-device:hover {
    background: rgba(239, 68, 68, 0.85);
    color: #ffffff;
}

body.light-theme .device-card {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

body.light-theme .device-alert-text {
    color: #1e293b;
}

body.light-theme .device-item {
    background: #f8fafc;
    border-color: #e2e8f0;
}

body.light-theme .device-name {
    color: #1e293b;
}

body.light-theme .device-alert-box {
    background: rgba(245, 158, 11, 0.08);
    border-color: rgba(245, 158, 11, 0.25);
}

/* ==========================================================================
   Referral & Bonus Program System CSS
   ========================================================================== */
.referral-card {
    background: rgba(20, 20, 32, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
}

.referral-bonus-badge {
    background: rgba(236, 72, 153, 0.15);
    color: #ec4899;
    border: 1px solid rgba(236, 72, 153, 0.35);
    padding: 0.3rem 0.85rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
}

.referral-banner-box {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.12) 0%, rgba(168, 85, 247, 0.1) 100%);
    border: 1px solid rgba(236, 72, 153, 0.3);
    border-radius: 14px;
    padding: 1.1rem 1.3rem;
    margin-top: 1rem;
    margin-bottom: 1.2rem;
}

.referral-icon-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
}

.referral-text-content {
    font-size: 0.88rem;
    color: var(--white);
    line-height: 1.5;
}

.referral-text-content strong {
    color: #f472b6;
    display: block;
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
}

.referral-input-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
    margin-bottom: 1.2rem;
}

@media (max-width: 768px) {
    .referral-input-group {
        grid-template-columns: 1fr;
    }
}

.referral-field label {
    display: block;
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
    font-weight: 600;
}

.referral-code-box, .referral-link-box {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 0.4rem 0.6rem 0.4rem 0.9rem;
}

.referral-code-box .code-text {
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: var(--accent-purple-light);
    flex: 1;
}

.referral-link-box input {
    background: none;
    border: none;
    color: var(--white);
    font-size: 0.82rem;
    flex: 1;
    outline: none;
}

.btn-copy-code, .btn-copy-link {
    background: rgba(139, 92, 246, 0.2);
    color: var(--accent-purple-light);
    border: 1px solid rgba(139, 92, 246, 0.35);
    padding: 0.4rem 0.85rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition-fast);
}

.btn-copy-code:hover, .btn-copy-link:hover {
    background: var(--accent-purple);
    color: #ffffff;
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

.referral-redeem-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 1rem 1.2rem;
    margin-bottom: 1.2rem;
}

.referral-redeem-box label {
    display: block;
    font-size: 0.83rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.redeem-input-row {
    display: flex;
    gap: 0.6rem;
}

.redeem-input-row input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 0.5rem 0.9rem;
    color: var(--white);
    font-size: 0.9rem;
    outline: none;
}

.referral-status-msg {
    margin-top: 0.5rem;
    font-size: 0.82rem;
    font-weight: 600;
}

.referral-status-msg.success {
    color: #34d399;
}

.referral-status-msg.error {
    color: #f87171;
}

.referral-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 0.9rem;
}

.ref-stat-item {
    text-align: center;
    padding: 0.4rem;
}

.ref-stat-val {
    display: block;
    font-size: 1.15rem;
    font-weight: 800;
    color: #ec4899;
}

.ref-stat-lbl {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 2px;
}

body.light-theme .referral-card {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

body.light-theme .referral-text-content {
    color: #1e293b;
}

body.light-theme .referral-code-box, body.light-theme .referral-link-box, body.light-theme .redeem-input-row input {
    background: #f8fafc;
    border-color: #e2e8f0;
    color: #0f172a;
}

body.light-theme .referral-link-box input {
    color: #0f172a;
}


