.add-to-cart {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 15px;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
    margin-top: 10px;
}

.add-to-cart:hover {
    background-color: #218838;
}

/* Estilo do balão do carrinho */
/* 🔹 Balão do Carrinho com Altura Máxima e Scroll Interno */
#cart-balloon {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 320px;
    max-height: 500px;
    overflow-y: auto;
    background: white;
    border-radius: 12px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
    padding: 15px;
    display: none;
    z-index: 1000;
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1rem;
    margin-bottom: 10px;
}

.cart-header button {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
}

#cart-items {
    max-height: 150px;
    overflow-y: auto;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

/* Estilo do botão de remover item */
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
    padding: 5px;
    margin: 5px 0;
    border-radius: 5px;
}

.remove-item {
    background: none;
    border: none;
    color: red;
    font-size: 1rem;
    cursor: pointer;
}

/* Botão de limpar carrinho */
.clear-cart {
    width: 100%;
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 10px;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 5px;
}

.clear-cart:hover {
    background-color: #b02a37;
}

.checkout-button {
    width: 100%;
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
}

.checkout-button:hover {
    background-color: #0056b3;
}

/* Botão flutuante para abrir o carrinho */
#cart-toggle {
    position: fixed;
    bottom: 20px;
    right: 10px;
    max-width: 90%;
    background: #28a745;
    color: white;
    border: none;
    padding: 12px 15px;
    font-size: 1rem;
    border-radius: 50px;
    cursor: pointer;
    z-index: 1001;
    white-space: nowrap;
    transition: 0.3s;
}

#cart-toggle:hover {
    background: #218838;
}

#cart-count {
    font-weight: bold;
}


#endereco-container {
    background: #ffffff;
    border-radius: 8px;
    padding: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

#endereco-container label {
    font-weight: bold;
    display: block;
    margin-top: 8px;
    font-size: 0.9rem;
}

#endereco-container input,
#endereco-container select {
    width: 100%;
    padding: 8px;
    font-size: 0.9rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-top: 3px;
    box-sizing: border-box;
    transition: border-color 0.3s ease-in-out;
}

#endereco-container input:focus,
#endereco-container select:focus {
    border-color: #007bff;
    outline: none;
}

/* Estilos para o Container de Frete */
/* Estilização do método de entrega */
#metodo-entrega-container {
    margin-bottom: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

#metodo-entrega-container label {
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
}

#metodo-entrega {
    width: 100%;
    max-width: 250px;
    padding: 8px;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    transition: border-color 0.3s ease-in-out;
}

#metodo-entrega:focus {
    border-color: #007bff;
    outline: none;
}

/* Oculta o container de frete e o campo de CEP inicialmente */
#frete-container {
    margin-top: 10px;
    padding: 0 10px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

#cep-destino {
    width: 100%;
    max-width: 200px;
    padding: 8px;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-bottom: 10px;
    box-sizing: border-box;
    transition: border-color 0.3s ease-in-out;
}

#cep-destino:focus {
    border-color: #007bff;
    outline: none;
}

/* Estilização do botão de calcular frete */
#calcular-frete {
    display: inline-block;
    background: #007bff;
    color: #fff;
    padding: 10px 15px;
    font-size: 1rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.3s;
}

#calcular-frete:hover {
    background: #0056b3;
}

/* Estilização da resposta do frete */
#resultado-frete {
    margin-top: 10px;
    font-size: 0.95rem;
    font-weight: bold;
    color: #333;
    min-height: 20px;
    /* para evitar 'pulo' de layout */
}

/* 🔹 Personalizando a barra de rolagem */
#cart-balloon::-webkit-scrollbar {
    width: 8px;
}

#cart-balloon::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 8px;
}

#cart-balloon::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 8px;
}

#cart-balloon::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

/* 🔹 Responsividade para telas menores */
@media (max-width: 768px) {
    #cart-balloon {
        width: 90%;
        right: 5%;
        max-height: 400px;
        /* Reduz a altura máxima em telas menores */
    }
}

@media (max-width: 480px) {
    #cart-balloon {
        width: 85%;
        right: 2.5%;
        max-height: 350px;
        /* Ajuste para celulares pequenos */
    }
}