/* ==========================================================================
   CONFIGURAÇÕES GLOBAIS E VARIÁVEIS
   ========================================================================== */
:root {
    --primary-color: #28a745;
    --warning-color: #f39c12; /* Cor para o botão comprar e destaques */
    --success-color: #28a745;
    --whatsapp-color: #4cc366;
    --bg-body: #f4f7f9;
    --text-main: #1a1a1a;
    --text-muted: #707b8e;
    --card-bg: #ffffff;
    --card-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
    
    /* Bordas Arredondadas */
    --border-radius-pill: 50px; 
    --border-radius-lg: 25px;   /* Padronizado para Box principal e Cards */
    --border-radius-md: 20px;   /* Para itens internos */
}

body {
    background-color: var(--bg-body);
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    margin: 0;
    padding-bottom: 40px; /* Espaço para não colar no fim da tela */
    -webkit-tap-highlight-color: transparent;
    letter-spacing: -0.2px;
}

/* CONTAINER MAIS LARGO: 
   Aumentado de 500px para 600px para não parecer tão curto em aparelhos modernos */
.container-main {
    max-width: 600px; 
    margin: 0 auto;
    padding: 0 15px;
}

/* BOX ENVOLVENTE PRINCIPAL (O "Wrapper" solicitado) */
.content-wrapper-card {
    background: var(--card-bg);
    border-radius: var(--border-radius-lg);
    border: 1px solid rgba(0,0,0,0.03);
    overflow: hidden; /* Garante que nada saia da borda arredondada */
}

/* ==========================================================================
   MENU SUPERIOR (ESTILO APP)
   ========================================================================== */
.menu-fixo-container {
    padding: 12px 15px;
    background: var(--bg-body);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.menu-arredondado {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-around;
    padding: 8px;
    border-radius: var(--border-radius-md);
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.nav-link-app {
    text-decoration: none;
    color: #94a3b8;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.nav-link-app i {
    font-size: 1.4rem;
    margin-bottom: 2px;
}

.nav-link-app.active, 
.nav-link-app:hover {
    color: var(--primary-color);
}

/* ==========================================================================
   CARDS E CAMPANHAS
   ========================================================================== */
.card-rifa-principal {
    background: var(--card-bg);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    display: block;
    margin-bottom: 20px;
    transition: transform 0.2s ease;
}

.card-rifa-principal img {
    width: 100%;
    object-fit: cover;
    max-height: 280px; /* Evita que a imagem fique gigante no celular */
}

.bg-light-custom {
    background: #f8f9fa;
    padding: 15px;
}

.badge-price {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: var(--primary-color);
    color: #fff;
    padding: 5px 15px;
    border-radius: var(--border-radius-pill);
    font-weight: 800;
    font-size: 14px;
    box-shadow: 0 4px 10px rgba(40, 167, 69, 0.2);
}

/* Lista Horizontal Mobile */
.campanha-item-horizontal {
    background: #fdfdfd;
    border-radius: var(--border-radius-md);
    display: flex;
    align-items: center;
    padding: 10px;
    margin-bottom: 12px;
    border: 1px solid #f0f0f0;
}

.campanha-item-horizontal img {
    width: 65px;
    height: 65px;
    border-radius: 12px;
    object-fit: cover;
}

/* ==========================================================================
   BOX SUPORTE (REFERÊNCIA FOTO)
   ========================================================================== */
.suporte-box-container {
    background: #eef2f7;
    border-radius: var(--border-radius-md);
    padding: 15px;
}

.btn-whatsapp {
    background: var(--whatsapp-color);
    color: #fff !important;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    border: none;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

/* ==========================================================================
   GANHADORES (ESTILO PREMIUM)
   ========================================================================== */
.ganhador-card-premium {
    background: #fdfdfd;
    border: 1px solid #f0f0f0;
    border-radius: var(--border-radius-md);
    padding: 12px;
}

.ganhador-thumb img {
    width: 75px;
    height: 75px;
    border-radius: 15px;
    object-fit: cover;
}

/* ==========================================================================
   BOTÕES E COMPONENTES
   ========================================================================== */
.btn-warning {
    background-color: var(--warning-color) !important;
    color: white !important;
    border-radius: 10px !important;
    font-weight: 700;
    border: none;
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.2);
}

.btn-danger {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    border-radius: var(--border-radius-pill) !important;
    padding: 12px 25px !important;
    font-weight: 700 !important;
    box-shadow: 0 8px 20px rgba(40, 167, 69, 0.15);
}

.text-danger {
    color: var(--primary-color) !important;
}

.bg-danger {
    background-color: var(--primary-color) !important;
}

.bg-danger.bg-opacity-10 {
    background-color: rgba(40, 167, 69, 0.1) !important;
}

.btn-outline-danger {
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-outline-danger:hover {
    background-color: var(--primary-color) !important;
    color: #fff !important;
}

.spinner-border.text-danger {
    color: var(--primary-color) !important;
}

.section-title-box {
    display: flex;
    align-items: center;
}

/* Ajustes para telas muito pequenas */
@media (max-width: 380px) {
    .nav-link-app span { display: none; } /* Esconde texto do menu se o celular for minúsculo */
    .nav-link-app i { margin-bottom: 0; font-size: 1.6rem; }
}

/* ==========================================================================
   INDEX — SEÇÕES (diff-strip, suporte, ganhadores)
   ========================================================================== */

/* Wrapper da index */
.idx-wrapper {
    max-width: 600px;
    margin: 0 auto;
    padding: 0 16px 24px;
}

/* Diferenciais strip */
.diff-strip {
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: #fff;
    border-radius: 20px;
    padding: 16px 12px;
    margin-bottom: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}
.diff-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #1a1a1a;
}
.diff-item i      { font-size: 1.3rem; color: var(--primary-color); }
.diff-item strong { display: block; font-size: 14px; font-weight: 800; line-height: 1; }
.diff-item span   { display: block; font-size: 10px; color: #888; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; margin-top: 2px; }
.diff-sep         { width: 1px; height: 32px; background: #eee; }

/* Suporte */
.suporte-section {
    background: linear-gradient(135deg, #0d1f0d 0%, #1a3a1a 100%);
    border-radius: 24px;
    margin-bottom: 16px;
    padding: 20px;
    border: 1px solid rgba(76,195,102,0.2);
}
.suporte-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}
.suporte-icon-wrap {
    width: 44px; height: 44px;
    border-radius: 14px;
    background: rgba(76,195,102,0.2);
    display: flex; align-items: center; justify-content: center;
    color: #4cc366;
    font-size: 1.4rem;
    flex-shrink: 0;
}
.suporte-title { font-size: 14px; font-weight: 800; color: #fff; margin: 0; }
.suporte-sub   { font-size: 11px; color: rgba(255,255,255,0.45); margin: 2px 0 0; }
.suporte-btns  { display: flex; gap: 10px; }

.btn-wa {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: #4cc366;
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    text-decoration: none;
    padding: 12px;
    border-radius: 14px;
    transition: background .2s, transform .15s;
}
.btn-wa:hover          { background: #3eb058; color: #fff; transform: translateY(-1px); }
.btn-wa-outline        { background: transparent; border: 2px solid rgba(76,195,102,0.5); color: #4cc366; }
.btn-wa-outline:hover  { background: rgba(76,195,102,0.12); color: #4cc366; }

/* Ganhadores */
.winners-section { margin-bottom: 16px; }
.winners-header  {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    padding: 0 4px;
}
.winners-trophy { font-size: 2rem; line-height: 1; }
.winners-title  { font-size: 16px; font-weight: 800; color: #1a1a1a; margin: 0; }
.winners-sub    { font-size: 11px; color: #aaa; margin: 2px 0 0; }

.winner-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border-radius: 18px;
    padding: 14px;
    margin-bottom: 10px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    animation: fadeSlideIn .4s ease both;
}
@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}
.winner-rank { font-size: 11px; font-weight: 800; color: #ccc; min-width: 22px; text-align: center; }
.winner-card:nth-child(1) .winner-rank { color: #f5c518; }
.winner-card:nth-child(2) .winner-rank { color: #b0b8c1; }
.winner-card:nth-child(3) .winner-rank { color: #cd7f32; }

.winner-thumb {
    width: 56px; height: 56px;
    border-radius: 14px;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid #f5f5f5;
}
.winner-info  { flex: 1; min-width: 0; }
.winner-name  { font-size: 13px; font-weight: 800; color: #1a1a1a; margin: 0 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.winner-prize { font-size: 10px; color: #999; text-transform: uppercase; font-weight: 700; letter-spacing: .5px; margin: 0 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.winner-meta  { display: flex; gap: 10px; flex-wrap: wrap; }
.winner-meta span { font-size: 10px; color: #888; font-weight: 600; display: flex; align-items: center; gap: 4px; }
.winner-meta i    { color: var(--primary-color); font-size: 10px; }
.winner-badge-check { font-size: 1.1rem; color: #4cc366; flex-shrink: 0; }

.winners-empty { text-align: center; padding: 40px 20px; background: #fff; border-radius: 20px; border: 1px dashed #e0e0e0; color: #bbb; }
.winners-empty i { font-size: 2rem; display: block; margin-bottom: 10px; }
.winners-empty p { font-size: 13px; margin: 0; }

/* ==========================================================================
   COTAS PREMIADAS (compartilhado entre index e campanha)
   ========================================================================== */
.cota-section-header {
    display: flex; align-items: center; gap: 14px;
    background: linear-gradient(135deg, #fffbe6, #fff8d0);
    border: 1px solid #f0d060;
    border-radius: 18px; padding: 14px 16px; margin-bottom: 18px;
}
.cota-section-icon  { font-size: 2rem; line-height: 1; }
.cota-section-title { font-size: 15px; font-weight: 800; color: #7a5c00; margin: 0 0 2px; }
.cota-section-sub   { font-size: 11px; color: #a07820; margin: 0; }

.cota-card {
    display: flex; align-items: stretch;
    border-radius: 16px; overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,.07);
}
.cota-disponivel { border: 1.5px solid #f0d060; }
.cota-ganho      { border: 1.5px solid #d0d0d0; opacity: .7; }

.cota-numero-wrap {
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    padding: 14px 16px; min-width: 100px;
    background: linear-gradient(135deg, #b8860b, #ffd700);
    gap: 2px;
}
.cota-ganho .cota-numero-wrap { background: #c8c8c8; }

.cota-label-top {
    font-size: 8px; font-weight: 800; letter-spacing: 1px;
    color: rgba(0,0,0,.45); text-transform: uppercase;
}
.cota-numero {
    font-family: 'Courier New', monospace;
    font-size: 20px; font-weight: 900; color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,.25);
    letter-spacing: 2px;
}
.cota-ganho .cota-numero { text-decoration: line-through; color: #eee; }

.cota-divider {
    width: 12px; flex-shrink: 0;
    background:
        radial-gradient(circle at 0 50%, transparent 6px, #fff 6px) top/12px 12px repeat-y,
        radial-gradient(circle at 100% 50%, transparent 6px, #fff 6px) top/12px 12px repeat-y;
    margin: 0 -1px;
    position: relative; z-index: 1;
}
.cota-disponivel .cota-divider { background:
    radial-gradient(circle at 0 50%, transparent 6px, #fffde8 6px) top/12px 12px repeat-y,
    radial-gradient(circle at 100% 50%, transparent 6px, #fffde8 6px) top/12px 12px repeat-y;
}
.cota-ganho .cota-divider { background:
    radial-gradient(circle at 0 50%, transparent 6px, #f5f5f5 6px) top/12px 12px repeat-y,
    radial-gradient(circle at 100% 50%, transparent 6px, #f5f5f5 6px) top/12px 12px repeat-y;
}

.cota-descricao-wrap {
    flex: 1; display: flex; flex-direction: column; justify-content: center;
    padding: 12px 16px; gap: 4px;
    background: #fffde8;
}
.cota-ganho .cota-descricao-wrap { background: #f5f5f5; }

.cota-descricao {
    font-size: 13px; font-weight: 700; color: #333; line-height: 1.3;
}
.cota-ganho .cota-descricao { color: #999; }

.cota-status-badge {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 10px; font-weight: 800; letter-spacing: .4px;
    padding: 3px 10px; border-radius: 20px; width: fit-content;
}
.badge-disponivel { background: #d4f5df; color: #1a7a3a; }
.badge-ganho      { background: #e8e8e8; color: #888; }

.cota-ganhador {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 11px; font-weight: 700; color: #b8860b;
    background: #fff8d0; border: 1px solid #f0d060;
    border-radius: 20px; padding: 3px 10px; width: fit-content;
}

/* ==========================================================================
   RODAPÉ LEGAL
   ========================================================================== */
.footer-legal {
    background-color: #1a1a1a;
    padding: 28px 20px 20px;
    margin-top: 0;
}

.footer-legal-text {
    font-size: 10px;
    color: #888;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto 10px;
    text-align: center;
}

.footer-legal-link {
    color: #aaa;
    text-decoration: none;
}

.footer-legal-link:hover {
    color: #fff;
}

.footer-social-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #ccc;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: color 0.2s;
}

.footer-social-link:hover        { color: #fff; }
.footer-social-whatsapp:hover    { color: #4cc366; }

.footer-copy {
    font-size: 10px;
    color: #555;
    margin: 10px 0 0;
}
