/* ===== GLOBAL ===== */
body, html {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background: #0a0a0a;
    color: white;
    overflow-x: hidden; /* Remove scroll horizontal global */
    min-height: 100vh; /* Garante que o fundo cubra toda a tela */
}

/* ===== CABEÇALHO ===== */
header {
    background: #101010;
    padding: 12px 18px 6px;
    position: sticky;
    top: 0;
    border-bottom: 1px solid #1f1f1f;
    z-index: 1000;
}

.topo {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

header h1 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #e8e8e8;
}

.insta-btn {
    position: absolute;
    right: 12px;
}

.insta-btn img {
    width: 28px;
    height: 28px;
    opacity: 0.85;
    transition: 0.2s;
}

.insta-btn img:hover {
    opacity: 1;
}

nav {
    margin-top: 8px;
    text-align: center;
}

nav a {
    color: #00eaff;
    margin: 0 8px;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: 0.2s;
}

nav a:hover {
    color: #00b8cc;
}

/* ===== CATEGORIAS ===== */
.categoria {
    width: 100%;
    padding: 24px 20px;
}

.categoria h2 {
    max-width: 1400px;
    margin: 0 auto 14px;
    font-size: 18px;
    text-align: left;
}

/* ===== GRID HORIZONTAL ===== */
.categoria-container {
    max-width: 1400px;
    margin: auto;
}

.grid-scroll {
    display: flex;
    overflow-x: auto;
    gap: 16px;
    padding-bottom: 8px;
    scroll-behavior: smooth;
}

.grid-scroll::-webkit-scrollbar {
    height: 6px;
}

.grid-scroll::-webkit-scrollbar-track {
    background: #111;
    border-radius: 3px;
}

.grid-scroll::-webkit-scrollbar-thumb {
    background: #00eaff;
    border-radius: 3px;
}

/* ===== PRODUTO ===== */
.produto {
    background: #141414;
    border-radius: 10px;
    padding: 10px;
    cursor: pointer;
    transition: 0.2s;
    border: 1px solid #141414;
    min-width: 200px;
    flex-shrink: 0;
    text-align: center;
}

.produto:hover {
    border: 1px solid #00eaff; /* azul uniforme */
    background: #181818;
}

.produto img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    border-radius: 8px;
    background: transparent;
}

/* ===== NOMES E PREÇOS UNIFORMES AZUIS ===== */
.produto p,
.produto span {
    color: #00eaff; /* azul uniforme */
    font-weight: 500;
}

.produto p {
    margin: 6px 0 4px;
    font-size: 14px;
}

.produto span {
    display: block;
    font-size: 13px;
}

/* ===== PÁGINA PRODUTO ===== */
.pagina-produto {
    max-width: 760px;
    margin: 32px auto;
    background: #141414;
    padding: 18px;
    border-radius: 12px;
    text-align: center;
}

.pagina-produto img {
    width: 100%;
    max-width: 420px;
    border-radius: 10px;
}

.pagina-produto h2 {
    font-size: 20px;
    margin: 16px 0 8px;
}

.pagina-produto p {
    font-size: 16px;
    margin: 8px 0;
}

.botao, .btn-pagar {
    display: inline-block;
    margin: 8px 5px;
    padding: 10px 18px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    cursor: pointer;
    transition: 0.3s;
}

.botao {
    background-color: #00eaff;
    color: #0a0a0a;
    font-size: 22px;
}

.botao:hover {
    background-color: #00b8cc;
    color: #fff;
}

/* ===== FRETE E PAGAMENTO PIX ===== */
.frete-container {
    margin: 20px auto 0;
    padding: 24px;
    max-width: 400px;
    text-align: center;
    border-radius: 14px;
    border: 1px solid #222;
    background: linear-gradient(145deg, #1c1c1c, #111);
    box-shadow: 0 6px 18px rgba(0,0,0,0.6);
    transition: 0.4s;
}

.frete-container:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.8);
}

.frete-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 18px;
    color: #00eaff;
}

.frete-container input {
    padding: 12px;
    border-radius: 10px;
    border: 1px solid #333;
    width: 160px;
    max-width: 100%;
    text-align: center;
    margin-bottom: 14px;
    background: #1f1f1f;
    color: #fff;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s;
}

.frete-container input:focus {
    border-color: #00eaff;
    box-shadow: 0 0 8px rgba(0,234,255,0.5);
    outline: none;
}

.frete-container button {
    background: #00eaff;
    color: #0a0a0a;
    padding: 14px 28px;
    font-weight: 700;
    font-size: 20px;
    border-radius: 10px;
    cursor: pointer;
    margin-bottom: 12px;
    transition: 0.3s;
}

.frete-container button:hover {
    background: #00b8cc;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,184,204,0.5);
}

.frete-container p {
    margin: 10px 0;
    font-size: 16px;
    font-weight: 600;
    color: #00eaff;
}

/* Botão PIX */
.btn-pagar {
    background: linear-gradient(145deg, #00eaff, #00b8cc);
    color: #0a0a0a;
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: bold;
    font-size: 16px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0,234,255,0.4);
    transition: all 0.3s;
}

.btn-pagar:hover {
    background: linear-gradient(145deg, #00b8cc, #00a3b3);
    transform: scale(1.05);
    box-shadow: 0 6px 18px rgba(0,184,204,0.6);
}

/* ===== BOTÃO "JÁ PAGUEI" — AJUSTADO ===== */
#btn-confirmar {
    background: linear-gradient(135deg, #ff2ae0, #b300ff);
    color: white !important;
    border: none;
    padding: 14px 26px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 10px;
    cursor: pointer;
    width: 100%;
    max-width: 380px;
    margin: 18px auto 0;
    display: block;
    text-align: center;
    box-shadow: 0 6px 20px rgba(255, 0, 214, 0.4);
    transition: 0.25s ease-in-out;
    position: relative;
    z-index: 9999;
}

#btn-confirmar:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 26px rgba(255, 0, 214, 0.6);
}

/* Garante que SEMPRE pode ser clicado */
#btn-confirmar,
#btn-confirmar * {
    pointer-events: auto !important;
}

/* ===== RESPONSIVO ===== */
@media (max-width: 768px) {
    body {
        padding-bottom: 20px; /* Reduz espaço vazio abaixo */
    }

    header {
        padding: 10px 15px 4px;
    }

    .topo {
        position: relative;
    }

    header h1 {
        font-size: 18px;
    }

    .insta-btn img {
        width: 26px;
        height: 26px;
    }

    nav a {
        font-size: 13px;
        margin: 0 6px;
    }

    .categoria {
        padding: 20px 15px;
    }

    .categoria h2 {
        font-size: 16px;
        margin-bottom: 12px;
    }

    .produto {
        min-width: 180px;
        padding: 12px;
        box-sizing: border-box; /* Inclui padding no cálculo de largura */
        overflow: hidden; /* Evita elementos saindo do container */
    }

    .produto img {
        height: 180px; /* Aumentado para melhor visibilidade */
        object-fit: cover; /* Evita distorção, corta se necessário */
        border-radius: 8px;
        max-width: 100%; /* Garante que não exceda a largura do container */
    }

    .produto p {
        font-size: 14px; /* Reduzido ligeiramente para caber melhor */
        margin: 8px 0 6px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap; /* Evita nomes saindo da tela */
        max-width: 100%; /* Garante que não exceda */
    }

    .produto span {
        font-size: 14px;
    }

    .botao, .btn-pagar {
        width: 100%;
        padding: 12px;
        font-size: 16px;
    }

    .frete-container label {
        font-size: 32px;
    }

    .frete-container input {
        width: 100%;
        padding: 14px;
        font-size: 32px;
    }

    .frete-container button {
        padding: 16px 30px;
        font-size: 34px;
    }

    .btn-pagar {
        padding: 18px 35px;
        font-size: 34px;
    }

    /* Página Produto */
    .pagina-produto {
        padding: 24px 20px;
        margin: 20px auto;
    }

    .pagina-produto img {
        max-width: 100%;
    }

    .pagina-produto h2 {
        font-size: 24px;
        margin: 20px 0 12px;
    }

    .pagina-produto p {
        font-size: 18px;
        margin: 10px 0;
    }

    .botao, .btn-pagar {
        padding: 14px 20px;
        font-size: 18px;
    }

    .frete-container {
        padding: 28px 20px;
    }

    .frete-container input {
        padding: 16px;
    }

    .frete-container button {
        padding: 18px 32px;
    }

    .frete-container p {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 16px;
    }

    .insta-btn img {
        width: 24px;
        height: 24px;
    }

    nav a {
        font-size: 12px;
        margin: 0 4px;
    }

    .categoria h2 {
        font-size: 15px;
    }

    .produto img {
        height: 160px;
    }

    .produto p {
        font-size: 14px;
    }

    .produto span {
        font-size: 13px;
    }
}

/* ===== MODAL PIX ===== */
.pix-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.85);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.pix-box {
    background: #141414;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 380px;
    text-align: center;
    border: 1px solid #00eaff;
}

.pix-box h2 {
    margin-top: 0;
}

#pix-qrcode {
    width: 230px;
    margin: 15px 0;
}

#pix-copia-cola {
    width: 100%;
    height: 90px;
    background: #1b1b1b;
    color: #eee;
    border: 1px solid #00eaff;
    border-radius: 6px;
    padding: 10px;
    margin-bottom: 10px;
}

.copiar-btn,
.fechar-btn {
    width: 100%;
    padding: 12px;
    margin-top: 8px;
    background: #00eaff;
    border: none;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
}

.fechar-btn {
    background: #d63f3f;
    color: white;
}

.fechar-btn:hover {
    background: #ff4b4b;
}
/* ===========================
   MOBILE MÉDIO (580x858)
   =========================== */
@media (max-width: 600px) {

    /* Header */
    header h1 {
        font-size: 16px;
    }

    nav a {
        font-size: 12px;
        margin: 0 4px;
    }

    /* Categoria */
    .categoria {
        padding: 14px 12px;
    }

    .categoria h2 {
        font-size: 15px;
        margin-bottom: 12px;
    }

    /* 🔥 GRID AJUSTADO */
    .grid-scroll {
        display: grid;
        grid-template-columns: repeat(2, 1fr); /* 🔥 2 colunas */
        gap: 12px;
        overflow-x: hidden;
    }

    /* Produto */
    .produto {
        min-width: unset;
        width: 100%;
        padding: 8px;
        border-radius: 10px;
    }

    /* Imagem */
    .produto img {
        height: 130px;   /* 🔥 tamanho ideal */
        object-fit: contain;
    }

    /* Texto */
    .produto p {
        font-size: 13px;
        margin: 6px 0 4px;
    }

    .produto span {
        font-size: 12px;
    }
}
