/* ===============================================
   Catálogo de Películas - Estilos
   =============================================== */

/* Contenedor principal */
.wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.wrap h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 2rem;
    text-align: center;
}

/* ===============================================
   Formulario de filtro
   =============================================== */

.wrap form {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 3rem;
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.wrap form label {
    font-weight: 600;
    color: #ffffff;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

.wrap form select#genero {
    padding: 0.75rem 1.5rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    cursor: pointer;
    min-width: 250px;
    transition: all 0.3s ease;
    font-weight: 500;
    color: #333;
    line-height: 1.5;
    height: auto;
}

.wrap form select#genero:hover {
    border-color: rgba(255, 255, 255, 0.8);
    background-color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.wrap form select#genero:focus {
    outline: none;
    border-color: white;
    background-color: white;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* ===============================================
   Grid de películas
   =============================================== */

.peliculas-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

/* ===============================================
   Item individual de película
   =============================================== */

.pelicula-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pelicula-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.pelicula-item a {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Miniatura de película */
.pelicula-thumb {
    width: 100%;
    height: 350px;
    overflow: hidden;
    background-color: #f0f0f0;
}

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

.pelicula-item:hover .pelicula-thumb img {
    transform: scale(1.05);
}

/* Título de película */
.pelicula-titulo {
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin: 0;
    text-align: center;
}

.pelicula-item:hover .pelicula-titulo {
    color: #007bff;
}

/* ===============================================
   Mensaje cuando no hay películas
   =============================================== */

.wrap > p {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    padding: 2rem;
    background-color: #f9f9f9;
    border-radius: 8px;
    margin-top: 2rem;
}

/* ===============================================
   Responsive Design
   =============================================== */

@media (max-width: 768px) {
    .wrap {
        padding: 1rem;
    }

    .wrap h1 {
        font-size: 2rem;
    }

    .peliculas-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .wrap form {
        flex-direction: column;
        align-items: flex-start;
    }

    .wrap form select#genero {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .peliculas-grid {
        grid-template-columns: 1fr;
    }

    .pelicula-thumb {
        height: 300px;
    }
}