/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    color: #ffffff;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-logo h1 {
    color: #e50914;
    font-size: 2rem;
    font-weight: bold;
}

.nav-logo i {
    margin-right: 10px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.nav-link:hover {
    color: #e50914;
}

.nav-search {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-search input {
    padding: 8px 15px;
    border: none;
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    outline: none;
    width: 200px;
    transition: all 0.3s ease;
}

.nav-search input:focus {
    background: rgba(255, 255, 255, 0.2);
    width: 250px;
}

.nav-search button {
    background: #e50914;
    border: none;
    color: white;
    padding: 8px 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s ease;
}

.nav-search button:hover {
    background: #cc0812;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: #ffffff;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><rect fill="%23333" width="1200" height="800"/><text x="600" y="400" text-anchor="middle" fill="%23666" font-size="48">Movie Background</text></svg>');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.hero-content {
    z-index: 2;
    max-width: 800px;
    padding: 0 20px;
}

.hero-content h2 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: #cccccc;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.cta-button {
    background: linear-gradient(45deg, #e50914, #cc0812);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(229, 9, 20, 0.4);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(0,0,0,0.8), rgba(0,0,0,0.4));
}

/* Movies Section */
.movies-section {
    padding: 80px 0;
    background: rgba(0, 0, 0, 0.5);
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    color: #e50914;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: linear-gradient(45deg, #e50914, #cc0812);
}

.movies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.movie-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.movie-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(229, 9, 20, 0.3);
    border-color: #e50914;
}

.movie-poster {
    width: 100%;
    height: 400px;
    object-fit: cover;
    background: linear-gradient(45deg, #333, #555);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 1.2rem;
    position: relative;
}

.movie-info {
    padding: 1.5rem;
}

.movie-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #ffffff;
}

.movie-description {
    color: #cccccc;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.movie-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.movie-category {
    background: #e50914;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    text-transform: uppercase;
}

.movie-duration {
    color: #888;
    font-size: 0.9rem;
}

/* Categories Section */
.categories-section {
    padding: 80px 0;
    background: rgba(0, 0, 0, 0.3);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.category-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.category-card:hover {
    transform: translateY(-5px);
    background: linear-gradient(135deg, rgba(229, 9, 20, 0.2), rgba(229, 9, 20, 0.1));
    border-color: #e50914;
}

.category-card i {
    font-size: 3rem;
    color: #e50914;
    margin-bottom: 1rem;
}

.category-card h3 {
    font-size: 1.5rem;
    color: #ffffff;
}

/* Upload Section */
.upload-section {
    padding: 80px 0;
    background: rgba(0, 0, 0, 0.5);
}

.upload-form {
    max-width: 600px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #ffffff;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    outline: none;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #e50914;
    background: rgba(255, 255, 255, 0.15);
}

.form-group input[type="file"] {
    padding: 8px;
}

.upload-btn {
    background: linear-gradient(45deg, #e50914, #cc0812);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    font-weight: bold;
    text-transform: uppercase;
}

.upload-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(229, 9, 20, 0.4);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    margin: 2% auto;
    width: 90%;
    max-width: 800px;
    background: rgba(30, 30, 30, 0.95);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.close {
    position: absolute;
    top: 15px;
    right: 25px;
    color: #ffffff;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1;
    transition: color 0.3s ease;
}

.close:hover {
    color: #e50914;
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 20px 20px 0 0;
}

.movie-info {
    padding: 2rem;
}

.movie-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #ffffff;
}

.movie-info p {
    color: #cccccc;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.movie-meta {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.movie-meta .category {
    background: #e50914;
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.movie-meta .duration {
    color: #888;
    font-size: 1rem;
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.9);
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

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

.footer-section h3 {
    color: #e50914;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.footer-section h4 {
    color: #ffffff;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #cccccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: #e50914;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #888;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-search {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-content h2 {
        font-size: 2.5rem;
    }
    
    .hero-content p {
        font-size: 1.2rem;
    }
    
    .movies-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1.5rem;
    }
    
    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 1.5rem;
    }
    
    .modal-content {
        width: 95%;
        margin: 5% auto;
    }
    
    .upload-form {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .movies-grid {
        grid-template-columns: 1fr;
    }
    
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .movie-poster {
        height: 300px;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .cta-button {
        width: 100%;
        margin-left: 0 !important;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #e50914;
    animation: spin 1s ease-in-out infinite;
}

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

/* Scroll Animation */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Admin and Extras */
.delete-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #ff0000;
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0,0,0,0.5);
    transition: transform 0.2s;
}

.delete-btn:hover {
    transform: scale(1.1);
    background: #cc0000;
}

.views-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Admin Dashboard */
.admin-dashboard {
    padding: 40px 0;
    background: #111;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    text-align: center;
}

.stat-card {
    background: #222;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #333;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: #e50914;
}

.stat-card i {
    font-size: 2rem;
    color: #e50914;
    margin-bottom: 10px;
}

.stat-card h3 {
    color: #fff;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
}

.stat-value.highlight {
    color: #e50914;
}
