* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'PT Serif', 'Times New Roman', serif; background: #0f0f0f; color: #fff; line-height: 1.6; }

header {
    background: #1a1a1a;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

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

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

.nav-menu a { 
    color: #fff; 
    text-decoration: none; 
    transition: color 0.3s; 
}

.nav-menu a:hover { 
    color: #e50914; 
}

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

.burger span { 
    width: 25px; 
    height: 3px; 
    background: #fff; 
    margin: 4px 0; 
    transition: all 0.4s ease; 
}

/* MOBILE BURGER MENU */
@media (max-width: 768px) {
    .nav-menu {
        display: none;                    /* hidden by default on mobile */
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #1a1a1a;
        flex-direction: column;
        padding: 1.5rem 0;
        gap: 1rem;
        box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    }
    
    .nav-menu.active {
        display: flex;                    /* shown only when active */
    }
    
    .burger {
        display: flex;
    }
    
    .burger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    .burger.active span:nth-child(2) {
        opacity: 0;
    }
    .burger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
}

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

.movie-card { 
    background: #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s ease;
    aspect-ratio: 2 / 3;
}

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

.movie-card img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Media queries for grid */
@media (max-width: 1200px) {
    .movie-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    .movie-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .movie-grid { grid-template-columns: 1fr; }
    .logo { font-size: 1.5rem; }
}

/* Footer */
footer { 
    background: #1a1a1a; 
    padding: 2rem 0; 
    text-align: center; 
    font-size: 0.9rem; 
    margin-top: 3rem; 
}

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