/* ===================================================
   DEVIDES DELIVERY - VISUAL DARK & GREEN
   =================================================== */
:root {
    color-scheme: dark; /* site ja e escuro: impede o modo escuro forcado do celular de alterar as cores */
    --bg-page: #0a0a0a;
    --bg-card: #141414;
    --bg-card-hover: #1a1a1a;
    --bg-header: rgba(10, 10, 10, 0.92);
    --bg-input: #1a1a1a;
    --border-color: #262626;
    --border-accent: rgba(34, 197, 94, 0.4);

    --accent: #22c55e;
    --accent-hover: #4ade80;
    --accent-light: #bbf7d0;
    --accent-gradient: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);

    --text-primary: #f5f5f5;
    --text-secondary: #a3a3a3;
    --text-muted: #737373;

    --whatsapp-green: #25d366;
    --whatsapp-hover: #1ebe5b;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;

    --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.35);
    --shadow-accent: 0 4px 14px rgba(34, 197, 94, 0.22);

    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    --header-h: 60px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-page);
    color: var(--text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    padding-bottom: 90px;
}

h1, h2, h3, .brand-name, .drawer-title, .product-price, .mobile-cart-total {
    font-family: var(--font-heading);
    letter-spacing: -0.3px;
}

button {
    font-family: inherit;
}

/* ===================================================
   CABECALHO (logo + carrinho)
   =================================================== */
.header {
    background-color: var(--bg-header);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 50;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    height: var(--header-h);
    padding: 0 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: inherit;
    min-width: 0;
}

.brand-logo-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
    background: #000;
    flex-shrink: 0;
}

.brand-name {
    font-size: 1rem;
    font-weight: 800;
    color: #ffffff;
    text-transform: uppercase;
    line-height: 1.08;
    letter-spacing: 0.6px;
    white-space: nowrap;
}

.brand-name span {
    display: block;
    color: #fbbf24;
}

.cart-header-btn {
    position: relative;
    height: 44px;
    min-width: 44px;
    padding: 0 16px;
    border-radius: 999px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
    transition: border-color 0.15s ease, color 0.15s ease;
}

.cart-header-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.cart-counter {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--accent);
    color: #0a0a0a;
    font-size: 0.72rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-counter.vazio {
    display: none;
}

/* ===================================================
   AREA PRINCIPAL: CHAMADA + BUSCA
   =================================================== */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px 24px;
}

.hero {
    max-width: 720px;
    margin: 0 auto;
    padding: 32px 0 6px;
    text-align: center;
}

.hero-title {
    font-size: clamp(1.6rem, 5vw, 2.5rem);
    font-weight: 800;
    line-height: 1.15;
    color: #ffffff;
}

.hero-title span {
    color: var(--accent);
}

.hero-sub {
    max-width: 520px;
    margin: 10px auto 22px;
    font-size: 0.98rem;
    color: var(--text-secondary);
}

.search-box {
    position: relative;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.search-box input {
    width: 100%;
    height: 54px;
    padding: 0 20px 0 50px;
    font-size: 16px; /* 16px evita o zoom automatico do iPhone */
    font-family: inherit;
    color: #ffffff;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    outline: none;
    box-shadow: var(--shadow-card);
    transition: border-color 0.2s, box-shadow 0.2s;
    -webkit-appearance: none;
    appearance: none;
}

.search-box input::placeholder {
    color: var(--text-muted);
}

.search-box input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.15);
}

/* Dentro de uma categoria a chamada some e a busca fica compacta */
body.vista-categoria .hero-title,
body.vista-categoria .hero-sub {
    display: none;
}

body.vista-categoria .hero {
    padding-top: 16px;
}

/* ===================================================
   CATEGORIAS PRINCIPAIS (pagina inicial)
   =================================================== */
.loja-secao {
    margin-top: 30px;
}

.secao-topo {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 14px;
}

.secao-titulo {
    font-size: 1.2rem;
    font-weight: 800;
    color: #ffffff;
}

.secao-contagem {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.cat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.cat-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 8px 8px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: #ffffff;
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease;
}

.cat-tile:hover {
    transform: translateY(-3px);
    border-color: var(--border-accent);
}

.cat-tile-media {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: var(--radius-md);
    background: #000000;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cat-tile-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cat-tile-emoji {
    font-size: 2.6rem;
    line-height: 1;
}

.cat-tile-name {
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
}

.cat-tile-soon {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 1;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.75);
    color: var(--accent-light);
    font-size: 0.66rem;
    font-weight: 700;
}

/* ===================================================
   NAVEGACAO DENTRO DA CATEGORIA (chips fixos no topo)
   =================================================== */
.nav-categorias {
    position: sticky;
    top: var(--header-h);
    z-index: 30;
    margin-top: 8px;
    padding: 10px 0 8px;
    background: var(--bg-page);
    border-bottom: 1px solid var(--border-color);
}

.nav-categorias[hidden] {
    display: none;
}

.chips-row {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.chips-row::-webkit-scrollbar {
    display: none;
}

.chips-row + .chips-row {
    margin-top: 8px;
}

.cat-btn,
.sub-btn {
    flex-shrink: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    color: var(--text-secondary);
    white-space: nowrap;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.15s ease;
}

.cat-btn {
    padding: 9px 16px;
    font-size: 0.86rem;
}

.sub-btn {
    padding: 6px 13px;
    font-size: 0.8rem;
}

.cat-btn:hover,
.sub-btn:hover {
    color: #ffffff;
    border-color: var(--accent);
}

.cat-btn.active,
.sub-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #0a0a0a;
}

.entrando {
    animation: aparecer 0.25s ease;
}

@keyframes aparecer {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===================================================
   PRODUTOS: GRADE E CARDS
   =================================================== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.section-title {
    grid-column: 1 / -1;
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--accent);
    margin-top: 14px;
}

.section-title:first-child {
    margin-top: 0;
}

.product-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.product-card:hover {
    transform: translateY(-3px);
    border-color: var(--border-accent);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.45);
}

.product-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #000000;
    overflow: hidden;
}

.product-image-container img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain; /* nunca corta a embalagem */
}

/* Produto ainda sem foto: espaco reservado com a logo da loja, na mesma proporcao dos outros */
.product-image-container.no-photo {
    background: radial-gradient(circle at 50% 40%, #1f1f1f 0%, #0c0c0c 75%);
}

.product-image-container.no-photo img {
    position: absolute;
    inset: 0;
    width: 46%;
    height: 46%;
    margin: auto;
    border-radius: 50%;
    object-fit: cover;
    opacity: 0.45;
}

.product-volume-tag {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background: rgba(10, 10, 10, 0.85);
    color: var(--accent-light);
    font-size: 0.72rem;
    padding: 2px 8px;
    border-radius: 999px;
    font-weight: 700;
}

.product-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 2px;
    padding: 12px;
}

.product-title {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.3;
    color: #ffffff;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-volume {
    font-size: 0.8rem;
    font-weight: 600;
    color: #fbbf24;
    letter-spacing: 0.2px;
}

.product-volume:empty {
    display: none;
}

.product-price {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--accent);
    margin: auto 0 10px;
    padding-top: 8px;
    white-space: nowrap;
}

.product-actions {
    margin-top: 0;
}

.add-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 40px;
    padding: 0 14px;
    background: var(--accent);
    color: #0a0a0a;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.86rem;
    font-weight: 800;
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
}

.add-btn:hover {
    background: var(--accent-hover);
}

.add-btn:active {
    transform: scale(0.97);
}

.product-card .add-btn,
.product-card .qty-control {
    width: 100%;
}

.qty-control {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    height: 40px;
    padding: 0 4px;
    border: 1px solid var(--accent);
    border-radius: var(--radius-sm);
    background: #0f1a13;
}

.qty-btn {
    background: none;
    border: none;
    width: 34px;
    height: 32px;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--accent);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background 0.15s;
}

.qty-btn:hover {
    background: rgba(34, 197, 94, 0.15);
}

.qty-number {
    font-weight: 700;
    font-size: 0.95rem;
    min-width: 20px;
    text-align: center;
    color: #ffffff;
}

.loja-vazio {
    text-align: center;
    padding: 44px 16px;
    color: var(--text-muted);
}

.loja-vazio strong {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}


/* ===================================================
   GAVETA LATERAL DO CARRINHO (CHECKOUT RESPONSIVO)
   =================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    z-index: 100;
    display: none;
    justify-content: flex-end;
}

.modal-overlay.open {
    display: flex;
}

.cart-drawer {
    background: var(--bg-card);
    width: 100%;
    max-width: 480px;
    height: 100%;
    height: 100dvh; /* Adapta perfeitamente à barra do Safari iOS e Android */
    display: flex;
    flex-direction: column;
    box-shadow: -4px 0 25px rgba(0, 0, 0, 0.7);
    animation: slideIn 0.22s ease-out;
    border-left: 1px solid var(--border-color);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

.drawer-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #0f0f0f;
    flex-shrink: 0;
}

.drawer-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffffff;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 4px 8px;
    line-height: 1;
    transition: color 0.15s;
}

.close-btn:hover {
    color: #ffffff;
}

.drawer-body {
    padding: 16px 20px;
    overflow-y: auto;
    flex: 1;
    -webkit-overflow-scrolling: touch;
}

.cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.cart-empty {
    text-align: center;
    padding: 50px 16px;
    color: var(--text-secondary);
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
    gap: 10px;
}

.cart-item-name {
    font-weight: 600;
    font-size: 0.92rem;
    color: #ffffff;
    line-height: 1.25;
}

.cart-item-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.cart-item-price {
    font-weight: 800;
    font-size: 0.95rem;
    min-width: 65px;
    text-align: right;
    color: var(--accent);
    font-family: var(--font-heading);
}

/* ===================================================
   FORMULÁRIO DE ENTREGA
   =================================================== */
.checkout-section-title {
    font-size: 0.9rem;
    font-weight: 700;
    margin: 18px 0 10px 0;
    color: var(--accent);
    border-top: 1px solid var(--border-color);
    padding-top: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    /* 16px previne zoom automático incômodo no iPhone */
    font-size: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    outline: none;
    background: var(--bg-input);
    color: #ffffff;
    font-family: inherit;
    transition: border-color 0.15s;
}

@media (min-width: 768px) {
    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 0.9rem;
    }
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--accent);
}

.form-group select option {
    background: #141414;
    color: #ffffff;
}

.form-row {
    display: flex;
    gap: 10px;
}

.form-row .form-group {
    flex: 1;
}

.form-row .form-group.col-small {
    flex: 0.38;
}

.radio-group {
    display: flex;
    gap: 16px;
    margin-top: 4px;
    flex-wrap: wrap;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.88rem;
    cursor: pointer;
    color: #ffffff;
}

/* ===================================================
   RODAPÉ DO CARRINHO & TOTAIS
   =================================================== */
.drawer-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--border-color);
    background: #0f0f0f;
    flex-shrink: 0;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
}

.summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.summary-row.total {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px dashed var(--border-color);
}

.summary-row.total span:last-child {
    color: var(--accent);
}

.whatsapp-submit-btn {
    width: 100%;
    background: var(--whatsapp-green);
    color: #ffffff;
    border: none;
    border-radius: var(--radius-md);
    padding: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
    transition: background 0.15s, transform 0.15s;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.whatsapp-submit-btn:hover {
    background: var(--whatsapp-hover);
    transform: translateY(-1px);
}

.whatsapp-submit-btn:disabled {
    background: #334155;
    color: #64748b;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* ===================================================
   BARRA FLUTUANTE MOBILE (INFERIOR)
   =================================================== */
.mobile-cart-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #0f0f0f;
    border-top: 1px solid var(--border-color);
    padding: 10px 16px;
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 -4px 15px rgba(0,0,0,0.6);
    z-index: 40;
}

@media (min-width: 768px) {
    .mobile-cart-bar {
        display: none !important;
    }
}

.mobile-cart-info {
    display: flex;
    flex-direction: column;
}

.mobile-cart-total {
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--accent);
    line-height: 1.1;
}

.mobile-cart-count {
    font-size: 0.76rem;
    color: var(--text-secondary);
}

.mobile-cart-btn {
    background: var(--accent-gradient);
    color: #0a0a0a;
    border: none;
    padding: 10px 18px;
    border-radius: var(--radius-md);
    font-weight: 800;
    font-size: 0.88rem;
    cursor: pointer;
}

/* ===================================================
   VERIFICAÇÃO DE IDADE (+18)
   =================================================== */
.age-overlay {
    position: fixed;
    inset: 0;
    background: rgba(8, 9, 11, 0.96);
    backdrop-filter: blur(6px);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
}

.age-box {
    background: var(--bg-card);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card), var(--shadow-accent);
    max-width: 400px;
    width: 100%;
    padding: 28px 22px 22px;
    text-align: center;
    margin: auto;
}

.age-logo {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
    margin-bottom: 14px;
}

.age-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 20px;
}

.age-btn {
    display: block;
    width: 100%;
    padding: 13px 14px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    margin-bottom: 10px;
    transition: filter 0.15s, transform 0.15s, border-color 0.15s;
}

.age-yes {
    background: var(--accent-gradient);
    color: #0a0a0a;
    border: none;
    box-shadow: var(--shadow-accent);
}

.age-yes:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.age-no {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.age-no:hover {
    color: #ffffff;
    border-color: var(--text-secondary);
}

.age-note {
    font-size: 0.74rem;
    color: var(--text-muted);
    margin-top: 6px;
}

/* ===================================================
   BOTÃO FLUTUANTE DE WHATSAPP
   =================================================== */
.whatsapp-float {
    position: fixed;
    right: 16px;
    bottom: 20px;
    bottom: max(20px, env(safe-area-inset-bottom));
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--whatsapp-green);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.45);
    z-index: 45;
    text-decoration: none;
    transition: background 0.15s, transform 0.15s;
}

.whatsapp-float:hover {
    background: var(--whatsapp-hover);
    transform: scale(1.06);
}

/* Quando a barra do carrinho (mobile) está visível, o botão sobe para não ficar por cima */
.mobile-cart-bar[style*="flex"] ~ .whatsapp-float {
    bottom: 88px;
}

@media (min-width: 768px) {
    .mobile-cart-bar[style*="flex"] ~ .whatsapp-float {
        bottom: 20px;
    }
}

/* ===================================================
   RODAPÉ DA PÁGINA
   =================================================== */
.site-footer {
    text-align: center;
    padding: 30px 16px;
    color: var(--text-muted);
    font-size: 0.82rem;
    border-top: 1px solid var(--border-color);
    margin-top: 40px;
    background: #0b0c0e;
}

.site-footer a {
    color: var(--accent);
    text-decoration: underline;
    font-size: 0.8rem;
}



/* ===================================================
   RESPONSIVIDADE
   =================================================== */

/* --- TABLETS E TELAS MEDIAS --- */
@media (min-width: 601px) and (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 14px;
    }
}

/* --- DESKTOP: 6 categorias lado a lado --- */
@media (min-width: 900px) {
    .cat-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 14px;
    }
}

@media (min-width: 1100px) {
    .products-grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (min-width: 1440px) {
    .main-container,
    .header-container {
        max-width: 1350px;
    }
}

/* --- CELULARES --- */
@media (max-width: 600px) {
    .header-container {
        padding: 0 12px;
    }

    .cart-label {
        display: none;
    }

    .cart-header-btn {
        width: 44px;
        padding: 0;
    }

    .main-container {
        padding: 0 12px 20px;
    }

    .hero {
        padding-top: 22px;
    }

    .hero-sub {
        font-size: 0.92rem;
        margin-bottom: 18px;
    }

    .search-box input {
        height: 50px;
    }

    .loja-secao {
        margin-top: 26px;
    }

    .cat-grid {
        gap: 8px;
    }

    .cat-tile {
        padding: 6px 6px 12px;
        gap: 8px;
        border-radius: var(--radius-md);
    }

    .cat-tile-emoji {
        font-size: 2rem;
    }

    .cat-tile-name {
        font-size: 0.8rem;
    }

    .cat-tile-soon {
        top: 10px;
        right: 10px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .product-info {
        padding: 10px;
    }

    .product-title {
        font-size: 0.86rem;
    }

    .product-price {
        font-size: 1.15rem;
        margin: auto 0 8px;
    }

    .add-btn,
    .qty-control {
        height: 38px;
        font-size: 0.8rem;
    }

    /* Carrinho em tela cheia no celular */
    .cart-drawer {
        max-width: 100%;
    }
}

/* --- CELULARES MUITO PEQUENOS --- */
@media (max-width: 340px) {
    .cat-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .brand-name {
        font-size: 0.95rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}


/* ===== AVISO DE INSTALAR O APP ===== */
.install-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #17181d;
    border-bottom: 1px solid var(--border-accent);
    color: var(--text-primary);
    font-size: 0.9rem;
}
.install-banner[hidden] { display: none; }
.install-text { flex: 1; }
.install-btn {
    background: var(--accent-gradient);
    color: #0f0f0f;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-weight: 700;
    cursor: pointer;
}
.install-close {
    background: transparent;
    color: var(--text-secondary);
    border: none;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
}

/* ===== ESCOLHA DE SABOR (Gelo de Sabor) ===== */
.sabor-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    z-index: 110;
    display: none;
    align-items: flex-end;
    justify-content: center;
}

.sabor-overlay.open {
    display: flex;
}

.sabor-sheet {
    background: var(--bg-card);
    width: 100%;
    max-width: 480px;
    max-height: 85vh;
    max-height: 85dvh;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
    border-bottom: none;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    animation: subirSabor 0.2s ease-out;
}

.sabor-topo {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 16px 12px;
    border-bottom: 1px solid var(--border-color);
}

.sabor-titulo {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.sabor-sub {
    margin: 4px 0 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.sabor-lista {
    overflow-y: auto;
    padding: 4px 16px;
}

.sabor-linha {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.sabor-linha:last-child {
    border-bottom: none;
}

.sabor-nome {
    color: var(--text-primary);
    font-weight: 600;
}

.sabor-pronto {
    margin: 12px 16px 16px;
    padding: 14px;
    border: none;
    border-radius: var(--radius-md);
    background: var(--accent-gradient);
    color: #111111;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
}

@keyframes subirSabor {
    from { transform: translateY(24px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
/* ===== ENTREGA / RETIRADA (escolha em dois botoes) ===== */
.radio-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.radio-label {
    justify-content: center;
    padding: 12px 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    font-weight: 600;
    font-size: 0.86rem;
    text-align: center;
    transition: border-color 0.15s, background 0.15s;
}

.radio-label:has(input:checked) {
    border-color: var(--accent);
    background: #0f1a13;
}

.form-group .radio-label input {
    width: auto;
    accent-color: var(--accent);
}

/* --- CATEGORIAS: sem espaco vazio, qualquer quantidade de categorias fica centralizada/preenchida --- */
.cat-grid {
    --cat-gap: 12px;
    --cat-cols: 3;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--cat-gap);
}

.cat-tile {
    flex: 0 0 calc((100% - (var(--cat-cols) - 1) * var(--cat-gap)) / var(--cat-cols));
    max-width: calc((100% - (var(--cat-cols) - 1) * var(--cat-gap)) / var(--cat-cols));
    min-width: 0;
    box-sizing: border-box;
}

@media (min-width: 900px) {
    .cat-grid {
        --cat-gap: 14px;
        flex-wrap: nowrap;
    }

    .cat-tile {
        flex: 1 1 0;
        max-width: none;
    }
}

@media (max-width: 600px) {
    .cat-grid {
        --cat-gap: 8px;
    }
}

@media (max-width: 340px) {
    .cat-grid {
        --cat-cols: 2;
    }
}

/* ===================================================
   MOTION: EFEITO DE ROLAGEM
   So vale quando o motion.js liga a classe "motion" no <html>.
   Usa a propriedade "translate" para nao brigar com o "transform" do hover.
   =================================================== */
.motion .reveal:not(.in):not(.reveal-ja) {
    opacity: 0;
    translate: 0 26px;
}

.motion .secao-topo.reveal:not(.in):not(.reveal-ja) {
    translate: -18px 0;
}

.motion .reveal.in {
    animation: revelarSubindo 0.65s cubic-bezier(0.22, 0.8, 0.3, 1) both;
    animation-delay: var(--reveal-delay, 0ms);
}

.motion .secao-topo.reveal.in {
    animation-name: revelarLado;
}

@keyframes revelarSubindo {
    from {
        opacity: 0;
        translate: 0 26px;
    }
    to {
        opacity: 1;
        translate: none;
    }
}

@keyframes revelarLado {
    from {
        opacity: 0;
        translate: -18px 0;
    }
    to {
        opacity: 1;
        translate: none;
    }
}

/* Entrada da chamada principal ao abrir o site */
.motion .hero-title,
.motion .hero-sub,
.motion .search-box {
    animation: revelarSubindo 0.7s cubic-bezier(0.22, 0.8, 0.3, 1) both;
}

.motion .hero-sub {
    animation-delay: 0.1s;
}

.motion .search-box {
    animation-delay: 0.2s;
}


/* ===================================================
   HORARIO DE FUNCIONAMENTO (selo na pagina inicial + janela)
   =================================================== */
.horario-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto 16px;
    padding: 8px 14px;
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 600;
    text-align: left;
    color: var(--text-primary);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}

.horario-chip[hidden] {
    display: none;
}

.horario-chip:hover {
    border-color: var(--border-accent);
    background: var(--bg-card-hover);
}

.horario-chip:focus-visible,
.horario-overlay .close-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.horario-dot {
    width: 9px;
    height: 9px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--accent);
    animation: horarioPulso 2s ease-out infinite;
}

.horario-chip.fechado .horario-dot {
    background: #ef4444;
    animation: none;
}

.horario-chip.fechando .horario-dot,
.horario-chip.retirada .horario-dot {
    background: #f59e0b;
    animation: none;
}

@keyframes horarioPulso {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

.horario-chip-ver {
    font-weight: 500;
    color: var(--text-muted);
}

.horario-chip-seta {
    flex-shrink: 0;
    color: var(--text-muted);
}

.horario-overlay {
    position: fixed;
    inset: 0;
    z-index: 105;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
}

.horario-overlay.open {
    display: flex;
}

.horario-box {
    width: 100%;
    max-width: 420px;
    margin: auto;
    padding: 18px 18px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card), var(--shadow-accent);
    animation: horarioEntrar 0.22s ease-out;
}

@keyframes horarioEntrar {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

.horario-topo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.horario-titulo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    font-weight: 800;
    color: #ffffff;
}

.horario-titulo svg {
    flex-shrink: 0;
    color: var(--accent);
}

.horario-status {
    margin-bottom: 14px;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--accent);
}

.horario-status.fechado {
    color: #f87171;
}

.horario-status.fechando,
.horario-status.retirada {
    color: #fbbf24;
}

.horario-lista {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.horario-linha {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
}

.horario-linha.hoje {
    border-color: var(--accent);
    background: rgba(34, 197, 94, 0.08);
}

.horario-dia {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: #ffffff;
}

.horario-hoje-tag {
    padding: 2px 8px;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #0a0a0a;
    background: var(--accent);
    border-radius: 999px;
}

.horario-horas {
    font-weight: 600;
    text-align: right;
    color: var(--text-primary);
}

.horario-linha.fechado .horario-horas {
    color: #f87171;
}

.horario-linha.retirada .horario-horas {
    color: #fbbf24;
}

@media (max-width: 480px) {
    .horario-chip {
        font-size: 0.84rem;
    }

    .horario-chip-ver {
        display: none;
    }
}

/* Entra junto com o resto da chamada, quando o efeito de movimento esta ligado */
.motion .horario-chip {
    animation: revelarSubindo 0.7s cubic-bezier(0.22, 0.8, 0.3, 1) both;
}


/* --- Produto com preco pendente (aparece, mas nao da pra adicionar ao carrinho) --- */
.add-btn:disabled,
.add-btn:disabled:hover,
.add-btn:disabled:active {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
}

.product-price.pendente {
    font-size: 0.82rem;
    font-weight: 600;
    opacity: 0.8;
}

/* ===== Instagram (discreto) ===== */
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.insta-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    background: transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.insta-btn:hover,
.insta-btn:focus-visible {
    color: #fbbf24;
    border-color: rgba(251, 191, 36, 0.5);
}

.footer-social {
    margin-top: 6px;
    font-size: 0.82rem;
}

.footer-social a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-social a:hover {
    color: #fbbf24;
}