:root {
    --bg-color: #0d0f12;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --primary-color: #00e5ff;
    --primary-hover: #00b4d8;
    --text-light: #f8f9fa;
    --text-muted: #adb5bd;
    --danger-color: #ef233c;
    --success-color: #06d6a0;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-light);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    background-image: radial-gradient(circle at 10% 20%, rgba(0, 229, 255, 0.05) 0%, transparent 40%),
                      radial-gradient(circle at 90% 80%, rgba(0, 180, 216, 0.05) 0%, transparent 40%);
    background-attachment: fixed;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    background: rgba(13, 15, 18, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--card-border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-brand a {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-light);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-brand .highlight {
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-link {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-link:hover {
    color: var(--primary-color);
}

.btn-logout {
    color: var(--text-muted);
}

/* Hero */
.hero {
    text-align: center;
    margin: 4rem 0;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -1px;
}

.hero .highlight {
    color: var(--primary-color);
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-muted);
}

/* Auth & Admin Cards */
.auth-container, .admin-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.glass-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(20px);
    padding: 3rem;
    border-radius: 20px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
}

.admin-card {
    max-width: 600px;
}

.glass-card h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.glass-card p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-muted);
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.1);
}

/* Custom File Upload */
.file-upload-wrapper {
    position: relative;
    width: 100%;
    height: 3rem;
}

.file-upload-wrapper input[type="file"] {
    position: absolute;
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    outline: none;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.file-custom {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px dashed var(--card-border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    padding: 0 1rem;
    color: var(--text-muted);
    z-index: 1;
    transition: all 0.3s;
}

.file-upload-wrapper input[type="file"]:hover + .file-custom {
    border-color: var(--primary-color);
    color: var(--text-light);
}

.hint {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Buttons */
.btn-primary {
    display: inline-block;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: #000;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 1rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 229, 255, 0.3);
}

/* Movies Grid */
.movie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.movie-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    border-color: rgba(0, 229, 255, 0.3);
}

.movie-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background: #1a1d24;
    overflow: hidden;
}

.movie-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.movie-card:hover .movie-thumb img {
    transform: scale(1.05);
}

.placeholder-thumb {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

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

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

.btn-play-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 1.5rem;
    padding-left: 5px; /* Visual center for play icon */
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

.movie-info {
    padding: 1.5rem;
}

.movie-info h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-light);
}

.movie-info p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 5rem 0;
    color: var(--text-muted);
    font-size: 1.2rem;
}

/* Flashes */
.flash-messages {
    margin-bottom: 2rem;
}

.alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-weight: 600;
}

.alert-danger {
    background: rgba(239, 35, 60, 0.1);
    color: #ff4d6d;
    border: 1px solid rgba(239, 35, 60, 0.2);
}

.alert-success {
    background: rgba(6, 214, 160, 0.1);
    color: #06d6a0;
    border: 1px solid rgba(6, 214, 160, 0.2);
}

/* Navbar Responsive & Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--text-light);
    border-radius: 3px;
    transition: all 0.3s;
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(13, 15, 18, 0.95);
        padding: 1.5rem;
        border-bottom: 1px solid var(--card-border);
    }
    .nav-links.active {
        display: flex;
    }
    .user-dropdown {
        position: static !important;
        width: 100% !important;
        box-shadow: none !important;
        border: none !important;
        margin-top: 1rem;
    }
}

/* User Dropdown */
.user-menu-container {
    position: relative;
}
.profile-icon {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}
.profile-icon:hover {
    background: rgba(255, 255, 255, 0.2);
}
.profile-icon svg {
    width: 20px;
    height: 20px;
}
.user-dropdown {
    position: absolute;
    top: 120%;
    right: 0;
    background: var(--bg-color);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    width: 200px;
    display: none;
    flex-direction: column;
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
    z-index: 1000;
}
.user-dropdown.show {
    display: flex;
}
.dropdown-header {
    padding: 1rem;
    border-bottom: 1px solid var(--card-border);
    color: var(--text-muted);
    font-size: 0.85rem;
    word-break: break-all;
}
.dropdown-item {
    padding: 1rem;
    text-decoration: none;
    color: var(--text-light);
    transition: background 0.2s;
}
.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
}
.text-danger {
    color: var(--danger-color);
}
