/* Importa a fonte Chakra Petch do Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Chakra+Petch:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700&display=swap');

@import url('https://fonts.googleapis.com/css2?family=Anton&display=swap');

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&display=swap');

/* Estiliza o corpo da página */
body {
    font-family: "Chakra Petch", sans-serif; 
    background: url('marvel.png') no-repeat center center fixed; 
    background-size: cover; 
    display: grid; 
    grid-template-rows: auto 1fr auto auto;
    justify-items: center;
    height: 100vh; 
    max-height: 100vh;
    margin: 0;
    padding: 0;
    color: #ffffff; 
}

/* Estiliza os títulos h1 */
h1 {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 5.5rem; 
    color: #ffffff; 
    text-align: center; 
    letter-spacing: 0.4rem;
}

main {
    flex:1;
    height: 100%;
}

/* Estiliza as seções da página */
section {
    display: flex; 
    flex-direction: column;
    align-items: center;
    margin-bottom: 3rem; 
}

/* Estiliza os inputs dentro das seções */
section input {
    width: 30rem; 
    border: none; 
    padding: 1rem;
    border-radius: 1.5rem;
    margin-bottom: 1rem;
    color: #000000;
    font-size: 1rem;
    box-sizing: border-box;
    background-color: rgba(255, 255, 255, 0.8); 
    transition: all 0.3s ease;
}

section input:hover {
    transform: scale(1.05); 
    border-color: #ffffff; 
}

.button-container {
    display: flex;           
    justify-content: center;  
    gap: 1rem;               
    margin-top: 1rem;      
}

/* Estiliza os botões dentro das seções */
.button-container button {
    padding: 0.8rem 1.2rem;
    border: none;
    border-radius: 1.5rem;
    background-color: #a30000;
    color: #F5F7F8;
    font-size: 1rem;
    cursor: pointer;
    width: 10rem; 
    font-weight: bold; 
    border: 1.5px solid #ffffff;
    transition: all 0.3s ease; 
}

.button-container button:hover {
    background-color: #a30000; 
    transform: scale(1.05);
    border-color: #a30000; 
}

/* Estiliza a caixa de resultados da pesquisa */
.resultados-pesquisa {
    width: 60rem;
    overflow-y: auto;
    margin-top: 1rem;
    padding: 1rem; 
    border-radius: 0.6rem; 
}

/* Estiliza cada item de resultado */
.item-resultado {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 0.6rem; 
    padding: 1rem; 
    margin-bottom: 1rem; 
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
}

/* Estiliza a imagem dentro dos itens de resultado */
.item-resultado img {
    width: 6.8rem; 
    height: 9.3rem; 
    margin-right: 1rem; 
    border-radius: 0.3rem;
    object-fit: cover; 
}

.item-resultado img:hover {
    transform: scale(1.2);
}

/* Estiliza o conteúdo dentro dos itens de resultado */
.resultado-conteudo {
    display: flex; 
    align-items: center;
    width: 100%; 
}

/* Estiliza a descrição dentro dos itens de resultado */
.descricao-resultado {
    display: flex; 
    flex-direction: column; 
    justify-content: center;
    flex: 1;
}

/* Estiliza os títulos dentro dos itens de resultado */
.item-resultado h2 {
    font-size: 1.5rem; 
    color: #222831; 
    margin: 0;
}

/* Estiliza os links dentro dos itens de resultado */
.item-resultado a {
    text-decoration: none; 
    color: #8f0002; 
}

/* Estiliza os links quando são passados o mouse sobre */
.item-resultado a:hover {
    text-decoration: underline; 
}

/* Estiliza a descrição meta dentro dos itens de resultado */
.descricao-meta {
    color: #45474B;
    margin: 0.5rem 0; 
}

/* Estiliza o rodapé da página */
footer {
    background-color: #d6d7d8; 
    color: #222831; 
    text-align: center; 
    padding: 0; 
    width: 100%; 
    font-size: 1rem;
}

.nenhum-filme {
    font-size: 1rem;
    background-color: rgba(0, 0, 0, 0.8); 
    border-radius: 15px;
    padding: 5px 15px;
    display: inline-block; 
}

/* Media Queries para responsividade */

/* Estilo para telas menores que 1000px (Tablets) */
@media screen and (max-width: 1000px) {
    body {
        background: #000000;
    }
    .image-header {
        background: url('marvel.png') no-repeat center center;
        background-size: cover;
        height: 40vh; 
        width: 100%; 
        position: fixed; 
        top: 0; 
        left: 0; 
        z-index: -1; 
    }

    h1 {
        font-size: 4.5rem;
        letter-spacing: 0.3rem;
    }

    section input {
        width: 25rem;
        font-size: 0.9rem;
    }

    .resultados-pesquisa {
        width: 45rem;
    }

    .item-resultado img {
        width: 5.8rem;
        height: 8.3rem;
    }
}

/* Estilo para telas menores que 768px (Celulares) */
@media screen and (max-width: 768px) {

    h1 {
        font-size: 3.5rem;
        letter-spacing: 0.2rem;
    }

    section input {
        width: 20rem;
        font-size: 0.8rem;
    }

    .resultados-pesquisa {
        width: 40rem;
    }

    .item-resultado img {
        width: 4.8rem;
        height: 7.3rem;
    }

    .button-container button {
        width: 8rem;
        font-size: 0.9rem;
    }

    footer {
        padding: 0; 
    }
}

/* Estilo para telas menores que 480px (Celulares muito pequenos) */
@media screen and (max-width: 480px) {
    
    .image-header {
        height: 32vh; 
    }

    h1 {
        font-size: 2.5rem;
        letter-spacing: 0.1rem;
    }

    section input {
        width: 16rem;
        font-size: 0.7rem;
    }

    .resultados-pesquisa {
        width: 25rem;
    }

    .item-resultado img {
        width: 6.5rem;
        height: 8.2rem;
    }

    .button-container button {
        width: 6rem;
        font-size: 0.7rem;
    }

    footer {
        font-size: 0.8rem;
    }


}