/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: white;
    font-family: 'Lato', sans-serif;
}

button:active {
    transform: scale(0.95);
    opacity: 0.8;
}


h1,
h2,
h3 {
    font-family: 'Playfair Display', serif;
}

/* ================= HEADER ================= */
.headerLoja {
    position: sticky;
    top: 0;
    z-index: 1000;
    /* garante que fique acima do conteúdo */

    display: flex;
    min-height: 6rem;
    width: 100%;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 0 1rem;
    background-color: yellow;

}

.logoHeaderLoja {
    flex: 0 0 auto;
    height: 4.5rem;
}

.logoHeaderLoja img {
    max-width: 100%;
    max-height: 100%;
}

.h1headerLoja {
    flex: 1 1 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.botaoCarrinho {
    display: flex;
    gap: 0.5rem;
}

.botaoCarrinho a {
    padding: 8px 14px;
    background-color: blue;
    border-radius: 15px;
    cursor: pointer;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.botaoCarrinho a:hover {
    background-color: darkblue;
    transform: scale(1.03);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}


.botaoCarrinho button {
    padding: 8px 14px;
    background-color: blue;
    border-radius: 15px;
    cursor: pointer;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.botaoCarrinho button:hover {
    background-color: darkblue;
    transform: scale(1.03);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}

/* ================= PRODUTOS ================= */
.produtos {
    display: flex;
    justify-content: center;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px;
}

.produto {
    display: flex;
    flex-direction: column;
    width: 300px;
    min-height: 480px;
    background: #fff;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    gap: 1rem;
    /* box-shadow: 0 0 6px rgba(0,0,0,0.15); */
    box-shadow: 0 0 1px;
}

.espacoImg {
    width: 100%;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.espacoImg img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.espacoNomeProduto {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    /* border: solid 1px black; */

}

.espacoBtnAdd {
    width: 100%;

}

.espacoBtnAdd button {
    width: 100%;
    padding: 15px;
    cursor: pointer;
    color: white;
    background: blue;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
}

.botoesQuantidade {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-flow: row wrap;
    height: 50px;
    width: 100%;
    gap: 20px;
    /* border: solid 1px red; */
}

.botoesQuantidade button {
    width: 50px;
    border-radius: 10px;
    color: white;
    background-color: blue;
    cursor: pointer;


}



/* ================= BOTÕES FINAIS ================= */
.botoesFinais {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.finalizar button {
    padding: 10px;
    border: none;
    background: #25D366;
    color: white;
    cursor: pointer;
    border-radius: 5px;
}

.limparCarrinho button {
    padding: 10px;
    border: none;
    background: red;
    color: white;
    cursor: pointer;
    border-radius: 5px;
}

/* ================= TOOLTIP ================= */
.tooltip {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 120%;
    left: 50%;
    transform: translateX(-50%);
    background: black;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    transition: opacity 0.3s;
}

#lixo {
    position: relative;
    padding: 10px 20px;
    cursor: pointer;
}

#lixo:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

/* ================= VOLTAR ================= */
.VoltarInicio {
    display: flex;
    align-items: center;
    height: 2.5rem;
}

.VoltarInicio a {
    padding: 10px 15px;
    background-color: blue;
    border-radius: 15px;
    cursor: pointer;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.VoltarInicio a:hover {
    background-color: darkblue;
    transform: scale(1.03);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}

/* ================= FORM ================= */
.formulario input,
.formulario select {
    display: block;
    width: 100%;
    margin: 10px 0;
    padding: 10px;
}



/* carrinho */
#listaCarrinho {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    padding: 20px;
    justify-content: flex-start;
}

/* botão remover */
.btn-remover {
    width: 100%;
    padding: 15px;
    cursor: pointer;
    color: white;
    background: #d32f2f;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    transition: 0.3s;
}

.btn-remover:hover {
    background: #b71c1c;
    transform: scale(1.02);
}

/* total */
.totalCarrinho {
    width: 100%;
    font-size: 1.3rem;
    font-weight: bold;
    padding: 15px;
    margin-top: 20px;
    border-top: 2px solid #ddd;
}



/* card formulario final */
.cardFinal {
    display: flex;
    justify-content: center;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px;
}

.formularioCardFinal {
    display: flex;
    flex-direction: column;
    width: 300px;
    min-height: 480px;
    background: #fff;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    gap: 1rem;
    /* box-shadow: 0 0 6px rgba(0,0,0,0.15); */
    box-shadow: 0 0 1px;
    justify-content: auto;
    align-items: center;
}

.espacoFrom {
    display: flex;
    flex-direction: column;
    width: 300px;
    min-height: 240px;
    background: #fff;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    gap: 1rem;
    /* box-shadow: 0 0 6px rgba(0,0,0,0.15); */

    justify-content: auto;
    align-items: center;
}

.espacoBtnZap {
    display: flex;
    flex-direction: column;
    width: 300px;
    min-height: 240px;
    background: #fff;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    gap: 1rem;
    /* box-shadow: 0 0 6px rgba(0,0,0,0.15); */

    justify-content: flex-end;
    align-items: center;
}

.espacoImg {
    width: 100%;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.espacoImg img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.espacoNomeProduto {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.espacoBtnAdd {
    width: 100%;
}

.espacoBtnAdd button {
    width: 100%;
    padding: 15px;
    cursor: pointer;
    color: white;
    background: blue;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
}

/* ================= RESPONSIVO MOBILE ONLY ================= */
@media (max-width: 600px) {

    /* Header */
    .headerLoja {
        flex-direction: column;
        align-items: center;
        gap: 8px;
        padding: 10px;
        text-align: center;
    }

    .logoHeaderLoja {
        height: 3.2rem;
    }

    .h1headerLoja h1 {
        font-size: 1.2rem;
    }

    .botaoCarrinho {
        width: 100%;
        justify-content: center;
        gap: 8px;
    }

    /* Produtos */
    .produtos {
        padding: 10px;
        justify-content: center;
    }

    .produto {
        width: 100%;
        min-height: auto;
    }

    .espacoImg {
        height: 160px;
    }

    /* Botões */
    .espacoBtnAdd button {
        font-size: 0.95rem;
        padding: 14px;
    }

    /* Carrinho */
    #listaCarrinho {
        justify-content: center;
    }

    /* Cards carrinho */
    #listaCarrinho .produto {
        width: 100%;
    }

    /* Total */
    .totalCarrinho {
        font-size: 1.1rem;
        text-align: center;
    }

    /* Form final */
    .cardFinal {
        flex-direction: column;
        align-items: center;
    }

    .formularioCardFinal,
    .espacoFrom,
    .espacoBtnZap {
        width: 100%;
        min-height: auto;
    }

    /* Inputs */
    .formulario input,
    .formulario select {
        font-size: 0.95rem;
    }

    /* Botões finais */
    .finalizar button,
    .limparCarrinho button {
        width: 100%;
        font-size: 0.95rem;
    }

}
