:root {
    --bg-color: #141414;
    --card-bg: #1f1f1f;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --primary-color: #e50914;
    /* Netflix Red accent */
    --whatsapp-green: #25D366;
    /* Official WhatsApp Green */
    --whatsapp-dark: #128C7E;
    --container-width: 1200px;
    --radius: 8px;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    padding-bottom: 20px;
    overflow-x: hidden;
    /* Prevent horizontal scroll */
}

a {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}

/* Header */
header {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.7) 10%, transparent);
    padding: 20px 4%;
    position: absolute;
    /* Float over content */
    width: 100%;
    top: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-scrolled {
    background-color: var(--bg-color);
    position: fixed;
}

.logo {
    color: var(--primary-color);
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -1px;
    text-transform: uppercase;
    text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.5);
}

/* Container */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Section Titles */
.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 40px 0 20px;
    padding-left: 10px;
    border-left: 4px solid var(--primary-color);
    color: var(--text-primary);
}

/* Grids */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 20px;
}

/* Mobile optimizations for grid */
@media (max-width: 600px) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
        /* 2 columns on mobile */
        gap: 12px;
    }
}

/* Cards */
.card {
    background: var(--card-bg);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: var(--shadow);
    position: relative;
    height: 100%;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.card img {
    width: 100%;
    aspect-ratio: 2/3;
    object-fit: cover;
    display: block;
}

.card-info {
    padding: 12px;
}

.card-title {
    font-size: 0.95rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.card-year {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Detail Page - Hero */
.hero {
    position: relative;
    height: 70vh;
    /* Taller hero */
    min-height: 500px;
    background-size: cover;
    background-position: center top;
    display: flex;
    align-items: flex-end;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.2) 0%, rgba(20, 20, 20, 0.8) 60%, var(--bg-color) 100%);
}

.hero-content {
    position: relative;
    z-index: 10;
    padding: 0 20px 40px;
    /* Reduced padding for mobile */
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
    text-align: center;
    /* Center align for mobile friendliness */
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 4rem);
    /* Responsive font size */
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.meta-info {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
    font-size: 1.1rem;
    color: #eee;
    font-weight: 500;
}

.rating-badge {
    background: #fab81e;
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: bold;
}

/* Call to Action Buttons */
.btn-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--whatsapp-green);
    color: white;
    padding: 16px 32px;
    font-size: 1.2rem;
    border-radius: 50px;
    /* Rounded pill shape */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 0 20px rgba(37, 211, 102, 0.4);
    /* Green glow */
    transition: all 0.3s ease;
    width: 100%;
    max-width: 400px;
    margin: 10px auto;
}

.btn-cta:hover {
    background-color: var(--whatsapp-dark);
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(37, 211, 102, 0.6);
}

.btn-cta i {
    margin-right: 10px;
    /* Space for icon if added later */
}

/* Content Blocks */
.content-wrapper {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.content-block {
    margin-bottom: 40px;
    background: #181818;
    padding: 25px;
    border-radius: 12px;
}

.content-block h2 {
    color: var(--text-primary);
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.content-block p {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1rem;
}

.tag-list {
    margin-top: 10px;
}

.tag {
    display: inline-block;
    background: #333;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    margin-right: 8px;
    margin-bottom: 8px;
    color: #ccc;
}

/* Trailer Video */
.video-responsive {
    position: relative;
    padding-bottom: 56.25%;
    /* 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    background: #000;
}

.video-responsive iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Footer */
footer {
    border-top: 1px solid #333;
    background: #000;
    padding: 60px 20px;
    text-align: center;
    color: var(--text-secondary);
    margin-top: 60px;
}

footer p {
    font-size: 0.9rem;
    margin-bottom: 10px;
}

/* Mobile specific styling */
@media (max-width: 768px) {
    .hero {
        height: 60vh;
    }

    .hero-content {
        padding: 0 20px 30px;
    }

    .btn-cta {
        padding: 14px 24px;
        font-size: 1rem;
        width: 100%;
        /* Full width on mobile */
    }


    /* Admin Panel Futuristic Styles */
    .admin-container {
        max-width: 800px;
        margin: 40px auto;
        padding: 0 20px;
    }

    .glass-panel {
        background: rgba(255, 255, 255, 0.05);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 16px;
        padding: 40px;
        box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    }

    .form-group {
        margin-bottom: 25px;
    }

    .form-group label {
        display: block;
        margin-bottom: 8px;
        color: var(--text-secondary);
        font-size: 0.9rem;
        text-transform: uppercase;
        letter-spacing: 1px;
    }

    .form-group input {
        width: 100%;
        padding: 15px;
        background: rgba(0, 0, 0, 0.3);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        color: white;
        font-size: 1rem;
        transition: all 0.3s ease;
    }

    .form-group input:focus {
        outline: none;
        border-color: var(--primary-color);
        box-shadow: 0 0 15px rgba(229, 9, 20, 0.3);
        background: rgba(0, 0, 0, 0.5);
    }

    .admin-section-title {
        font-size: 1.2rem;
        color: var(--primary-color);
        margin: 30px 0 20px;
        display: flex;
        align-items: center;
        gap: 10px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        padding-bottom: 10px;
    }

    .btn-save {
        background: linear-gradient(45deg, var(--primary-color), #ff4757);
        color: white;
        padding: 15px 40px;
        border: none;
        border-radius: 50px;
        font-size: 1.1rem;
        font-weight: bold;
        cursor: pointer;
        width: 100%;
        margin-top: 20px;
        text-transform: uppercase;
        letter-spacing: 1px;
        transition: all 0.3s ease;
        box-shadow: 0 5px 20px rgba(229, 9, 20, 0.4);
    }

    .btn-save:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(229, 9, 20, 0.6);
    }

    .status-badge {
        background: rgba(37, 211, 102, 0.2);
        color: #25D366;
        padding: 5px 10px;
        border-radius: 12px;
        font-size: 0.8rem;
        margin-left: 10px;
    }
}

/* --- MOBILE & RESPONSIVE FIXES --- */

/* Header Mobile Layout */
@media (max-width: 768px) {
    header {
        position: relative;
        /* Stop floating on mobile to prevent overlap issues */
        background: var(--bg-color);
        padding: 15px;
    }

    .header-content {
        flex-wrap: wrap;
    }

    .logo {
        font-size: 1.5rem;
    }

    /* Force search bar to break line on mobile if valid */
    .search-bar {
        order: 3;
        width: 100%;
        margin: 15px 0 0 0;
        max-width: 100%;
        display: block !important;
        /* Force show */
    }

    .mobile-menu-icon {
        order: 2;
    }

    .desktop-nav {
        top: 100%;
        z-index: 999;
    }
}

/* Grid Mobile Fix */
@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }

    .grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .card-info {
        padding: 8px;
    }

    .card-title {
        font-size: 0.85rem;
    }
}

/* Banner Responsive 16:9 Force */
.site-banner {
    width: 100%;
    display: flex;
    /* Centers child */
    justify-content: center;
}

.site-banner a {
    display: block;
    width: 100%;
    max-width: 100%;
    /* Ensure it doesn't overflow */
    position: relative;
    /* Option 1: Modern CSS */
    aspect-ratio: 16 / 9;
    /* Option 2: Fallback if needed, but aspect-ratio is safe for modern web */
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.site-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Fix for Search Grid Images (The big image bug) */
.grid .card img {
    height: auto;
    aspect-ratio: 2/3;
    width: 100%;
    object-fit: cover;
}

/* Ensure grid items don't stretch weirdly */
.grid .card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.site-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Ensures 16:9 fill without distortion */
    object-position: center;
    border-radius: 8px;
}