/* =========================================
   CONFIGURAÇÕES GERAIS (Foco no Mobile)
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    /* 🚀 A VACINA: Desliga o clarão cinza/azul nativo dos celulares ao clicar */
    -webkit-tap-highlight-color: transparent; 
}

body {
    background-color: #f4f4f9; /* Fundo cinza bem clarinho para destacar os produtos */
    color: #333;
    
    /* A MÁGICA DO MOBILE-FIRST NO COMPUTADOR */
    /* Se alguém abrir no PC, o site não vai esticar feio, vai ficar no centro parecendo um celular */
    max-width: 480px; 
    margin: 0 auto; 
    background-color: #ffffff;
    min-height: 100vh;
    box-shadow: 0px 0px 20px rgba(0,0,0,0.1); /* Sombrinha nas laterais */
}

/* =========================================
   CABEÇALHO E BUSCA INTELIGENTE
   ========================================= */
.header-loja {
    background-color: #ff477e; /* Rosa vibrante da Icesoft (alta conversão) */
    padding: 25px 20px;
    border-bottom-left-radius: 25px;
    border-bottom-right-radius: 25px;
    color: white;
}

.logo-area h1 {
    font-size: 26px;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 800;
}

.busca-area input {
    width: 100%;
    padding: 15px 20px;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    outline: none;
    box-shadow: 0px 4px 10px rgba(0,0,0,0.15); /* Efeito flutuante */
    transition: 0.3s;
}

/* =========================================
   NAVEGAÇÃO EM "STORY" (Categorias)
   ========================================= */
.stories-container {
    display: flex;
    justify-content: space-around;
    padding: 25px 15px;
    border-bottom: 1px solid #eee;
}

.story-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 13px;
    font-weight: 700;
    color: #555;
    cursor: pointer;
}

/* O círculo em volta do emoji parecendo Story */
.story-item::before {
    content: '';
    display: block;
    width: 60px;
    height: 60px;
    background-color: #fff0f3;
    border: 3px solid #ff477e;
    border-radius: 50%;
    margin-bottom: -40px; /* Puxa o emoji para cima do círculo */
    z-index: 0;
}

.story-item {
    z-index: 1; /* Garante que o texto/emoji fique por cima do círculo */
}

/* =========================================
   ÁREA DO CARDÁPIO
   ========================================= */
main#lista-produtos {
    padding: 25px 20px;
}

main#lista-produtos h2 {
    font-size: 22px;
    color: #222;
    margin-bottom: 15px;
}

/* 🚀 NOVO: Efeito de "afundar" suavemente quando o cliente clica no produto */
.produto-card {
    transition: transform 0.15s ease, background-color 0.15s ease !important;
}

.produto-card:active {
    transform: scale(0.97) !important;
    background-color: #f8f9fa !important;
}


/* =========================================
   RODAPÉ DO CARRINHO (ESTILO FIXO)
   ========================================= */
.carrinho-fixo {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%); /* Centraliza no mobile */
    width: 90%;
    max-width: 440px;
    background-color: #333; /* Cor escura para dar contraste com o rosa */
    color: white;
    padding: 15px 25px;
    border-radius: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0px 10px 25px rgba(0,0,0,0.3);
    z-index: 999;
}

.carrinho-info {
    display: flex;
    flex-direction: column;
}

#qtd-itens {
    font-size: 12px;
    opacity: 0.8;
}

#total-carrinho {
    font-size: 18px;
}

.btn-ver-carrinho {
    background-color: #ff477e;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: bold;
    cursor: pointer;
}

/* =========================================
   TELA DE CHECKOUT (MODAL)
   ========================================= */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(0,0,0,0.5); /* Fundo escuro transparente */
    display: flex;
    justify-content: center;
    align-items: flex-end; /* Faz a tela subir por baixo no celular */
    z-index: 1000;
}

.modal-conteudo {
    background-color: #fff;
    width: 100%;
    max-width: 480px;
    height: 85vh; /* Ocupa 85% da tela */
    border-top-left-radius: 25px;
    border-top-right-radius: 25px;
    padding: 20px;
    overflow-y: auto; /* Permite rolar se o carrinho for muito grande */
    animation: subirTela 0.3s ease-out;
}

@keyframes subirTela {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.modal-cabecalho {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

#btn-fechar-modal {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #999;
}

.item-no-carrinho {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed #ccc;
}

.item-no-carrinho button {
    background: #ff4d4d;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
}

.resumo-valores {
    text-align: right;
    font-size: 18px;
    margin: 20px 0;
}

.form-entrega h3 {
    margin-bottom: 10px;
    font-size: 16px;
}

.form-entrega input, .form-entrega textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
}

.btn-sucesso {
    width: 100%;
    background-color: #25D366; /* Verde do WhatsApp */
    color: white;
    border: none;
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 10px;
}

/* =========================================
   ESTILOS DO CARRINHO E BOTÃO DE COMPRA
   ========================================= */
.btn-add {
    background-color: #e91e63;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 15px;
    width: 100%;
    font-weight: bold;
    transition: 0.2s;
}

.btn-add:hover { background-color: #c2185b; }

#carrinho-flutuante {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #fff;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease-in-out;
    z-index: 1000;
}

.carrinho-oculto { transform: translateY(100%); }
.carrinho-visivel { transform: translateY(0); }

.carrinho-info {
    display: flex;
    flex-direction: column;
}

#carrinho-qtd { font-size: 0.85rem; color: #777; }
#carrinho-total { font-size: 1.2rem; font-weight: bold; color: #e91e63; }

.btn-whatsapp {
    background-color: #25D366; /* Verde Oficial do WhatsApp */
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 25px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(37, 211, 102, 0.3);
}

/* =========================================
   ESTILOS DO MODAL DE CHECKOUT
   ========================================= */
.modal-oculto {
    display: none;
}

.modal-visivel {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6); /* Fundo escuro transparente */
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-conteudo {
    background-color: white;
    padding: 25px;
    border-radius: 15px;
    width: 90%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.modal-conteudo input, .modal-conteudo select {
    padding: 12px;
    border: 2px solid #f8bbd0;
    border-radius: 8px;
    font-size: 1rem;
    outline: none;
    font-family: 'Poppins', sans-serif;
}

.modal-conteudo input:focus, .modal-conteudo select:focus {
    border-color: #e91e63;
}

.modal-botoes {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
}

.btn-cancelar {
    padding: 12px;
    flex: 1;
    background: #eeeeee;
    color: #333;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
}

.btn-confirmar {
    padding: 12px;
    flex: 1;
    background: #25D366;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
}

/* =========================================
   NOVO DESIGN DO CHECKOUT (WIZARD)
   ========================================= */
.checkout-passo { display: none; animation: fadeIn 0.3s ease; }
.checkout-passo.ativo { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.secao-checkout { background: white; padding: 20px; border-radius: 15px; box-shadow: 0 2px 8px rgba(0,0,0,0.03); margin-bottom: 15px; }
.secao-checkout h4 { margin: 0 0 15px 0; color: #333; font-size: 1rem; }

/* Inputs Limpos e Claros */
.input-clean { width: 100%; padding: 15px; border: 1px solid #e0e0e0; border-radius: 10px; font-size: 1rem; font-family: 'Inter', sans-serif; outline: none; transition: 0.2s; box-sizing: border-box; margin-bottom: 10px; background: #fafafa; }
.input-clean:focus { border-color: #25D366; background: white; }
.select-clean { appearance: none; background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23666%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E"); background-repeat: no-repeat; background-position: right 15px top 50%; background-size: 12px auto; }

/* Cartões Selecionáveis (Estilo Saipos) */
.card-selecao { display: flex; align-items: center; padding: 15px; border: 1px solid #e0e0e0; border-radius: 10px; margin-bottom: 10px; cursor: pointer; transition: 0.2s; background: white; }
.card-selecao.ativo { border-color: #25D366; background: #f0fdf4; }
.radio-customizado { width: 20px; height: 20px; border: 2px solid #ccc; border-radius: 50%; position: relative; }
.radio-customizado.marcado { border-color: #25D366; }
.radio-customizado.marcado::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 10px; height: 10px; background: #25D366; border-radius: 50%; }

/* Barra de Progresso */
.progresso-container { display: flex; justify-content: space-between; align-items: center; position: relative; padding: 0 10px; }
.progresso-linha { position: absolute; top: 12px; left: 15%; right: 15%; height: 2px; background: #e0e0e0; z-index: 1; }
.progresso-passo { display: flex; flex-direction: column; align-items: center; z-index: 2; gap: 5px; }
.progresso-passo .bolinha { width: 26px; height: 26px; border-radius: 50%; background: #e0e0e0; color: white; display: flex; justify-content: center; align-items: center; font-size: 0.8rem; font-weight: bold; transition: 0.3s; }
.progresso-passo span { font-size: 0.75rem; color: #999; font-weight: 600; }
.progresso-passo.ativo .bolinha { background: #25D366; }
.progresso-passo.ativo span { color: #25D366; }
.progresso-passo.concluido .bolinha { background: #25D366; content: "✓"; color: transparent; position: relative; }
.progresso-passo.concluido .bolinha::after { content: "✓"; color: white; position: absolute; }

/* =========================================
   TELA DE RASTREIO PÓS-COMPRA
   ========================================= */
.timeline-rastreio { display: flex; flex-direction: column; gap: 25px; position: relative; margin-left: 10px; }
.timeline-rastreio::before { content: ''; position: absolute; left: 22px; top: 20px; bottom: 20px; width: 3px; background: #f0f0f0; z-index: 1; border-radius: 5px; }

.step-rastreio { display: flex; align-items: center; gap: 20px; position: relative; z-index: 2; opacity: 0.4; transition: 0.4s ease; }

.icon-rastreio { width: 48px; height: 48px; border-radius: 50%; background: #f0f0f0; display: flex; justify-content: center; align-items: center; font-size: 1.3rem; transition: 0.4s ease; box-shadow: 0 0 0 6px white; }
.text-rastreio { font-weight: 600; color: #888; font-size: 1.05rem; transition: 0.4s ease; }

/* Status Ativo (Piscando) */
.step-rastreio.ativo { opacity: 1; transform: scale(1.05); transform-origin: left center;}
.step-rastreio.ativo .icon-rastreio { background: #ffb74d; color: white; animation: pulseRastreio 1.5s infinite; }
.step-rastreio.ativo .text-rastreio { color: #ff9800; font-weight: bold; }

/* Status Concluído (Verde) */
.step-rastreio.concluido { opacity: 1; }
.step-rastreio.concluido .icon-rastreio { background: #25D366; color: white; }
.step-rastreio.concluido .text-rastreio { color: #25D366; font-weight: bold; }

@keyframes pulseRastreio { 
    0% { box-shadow: 0 0 0 0 rgba(255, 183, 77, 0.4), 0 0 0 6px white; } 
    70% { box-shadow: 0 0 0 12px rgba(255, 183, 77, 0), 0 0 0 6px white; } 
    100% { box-shadow: 0 0 0 0 rgba(255, 183, 77, 0), 0 0 0 6px white; } 
}

/* =========================================
   TAGS DE RECOMENDAÇÃO (UPSELL VISUAL)
   ========================================= */
.tag-recomendacao {
    background: linear-gradient(135deg, #ff477e, #ff8fa3);
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 12px;
    margin-left: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(255, 71, 126, 0.4);
    display: inline-block;
    vertical-align: middle;
    animation: pulsarTag 2s infinite;
}

@keyframes pulsarTag {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* =========================================
   MODAL DE CARRINHO (ESTILO BOTTOM SHEET)
   ========================================= */
@keyframes subirModalCarrinho {
    from { transform: translateY(100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.item-carrinho-cliente {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px dashed #eee;
}

.item-carrinho-cliente:last-child {
    border-bottom: none;
}

.btn-remover-item {
    background: #fff0f4; 
    border: 1px solid #ffb3c6; 
    color: #e91e63; 
    width: 40px; 
    height: 40px; 
    border-radius: 10px; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    cursor: pointer; 
    font-size: 1.2rem; 
    transition: 0.2s;
    flex-shrink: 0;
}

.btn-remover-item:hover {
    background: #ffe0e9;
    transform: scale(1.05);
}