/* 
 * ApoXtinha - Folha de Estilos Premium (Vanilla CSS)
 * Focado em Mobile-First, com transições suaves e design moderno.
 */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary-color: #0052cc;      /* Azul Royal ApoXtinha */
    --primary-dark: #003d99;
    --primary-light: #e6f0ff;
    --secondary-color: #ffbb00;    /* Amarelo/Dourado */
    --secondary-dark: #d49b00;
    --success-color: #2ecc71;      /* Verde Comprar */
    --success-dark: #27ae60;
    --danger-color: #e74c3c;
    --text-color: #2c3e50;
    --text-muted: #7f8c8d;
    --bg-light: #f8fafe;
    --bg-white: #ffffff;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.12);
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-light);
    color: var(--text-color);
    line-height: 1.5;
    font-size: 16px;
    overflow-x: hidden;
}

/* ----------------------------------------------------
 * Layout & Containers
 * ---------------------------------------------------- */
.app-container {
    max-width: 500px; /* Limite estilo aplicativo mobile */
    margin: 0 auto;
    background-color: var(--bg-white);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.05);
}

.content {
    flex: 1;
    padding-bottom: 90px; /* Espaço para botão fixo inferior */
}

/* ----------------------------------------------------
 * Header & Navbar
 * ---------------------------------------------------- */
.main-header {
    background-color: #ffbb00;
    color: var(--bg-white);
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.menu-toggle, .profile-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: var(--transition-fast);
}

.menu-toggle:hover, .profile-btn:hover {
    background-color: rgba(0, 82, 204, 0.1);
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
    letter-spacing: -0.5px;
    text-transform: uppercase;
}

.logo-img {
    height: 38px;
    max-height: 45px;
    object-fit: contain;
    display: block;
}

.logo-sbt {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    padding: 2px 8px;
    border-radius: 20px 0 20px 20px;
    margin-right: 4px;
    font-weight: 800;
}

.logo-premios {
    color: var(--bg-white);
}

/* ----------------------------------------------------
 * Navigation Drawer (Menu Lateral)
 * ---------------------------------------------------- */
.drawer-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}

.drawer-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.drawer-menu {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100%;
    background-color: var(--bg-white);
    z-index: 999;
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
}

.drawer-menu.active {
    left: 0;
}

.drawer-header {
    background-color: var(--primary-color);
    color: var(--bg-white);
    padding: 20px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.drawer-close {
    background: none;
    border: none;
    color: var(--bg-white);
    font-size: 24px;
    cursor: pointer;
}

.drawer-content {
    padding: 16px;
    flex: 1;
    overflow-y: auto;
}

.drawer-btn-highlight {
    background-color: var(--secondary-color);
    color: var(--bg-white);
    padding: 14px 20px;
    border-radius: var(--border-radius-sm);
    text-decoration: none;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 12px rgba(255, 187, 0, 0.3);
    transition: var(--transition-fast);
}

.drawer-btn-highlight:hover {
    background-color: var(--secondary-dark);
    transform: translateY(-2px);
}

.drawer-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.drawer-link {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 16px;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    border-radius: var(--border-radius-sm);
    background-color: var(--bg-light);
    transition: var(--transition-fast);
}

.drawer-link:hover {
    background-color: var(--primary-light);
    color: var(--primary-color);
}

.drawer-link i {
    font-size: 20px;
    width: 24px;
    text-align: center;
    color: var(--primary-color);
}

/* ----------------------------------------------------
 * Banner & Hero Sorteio
 * ---------------------------------------------------- */
.banner-sorteio {
    width: 100%;
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
}

.banner-slide {
    grid-column: 1 / -1;
    grid-row: 1 / -1;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
    width: 100%;
}

.banner-slide.active {
    opacity: 1;
    visibility: visible;
}

.banner-img {
    width: 100%;
    display: block;
    height: auto;
}

.banner-carousel-indicators {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.banner-carousel-indicators .indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
}

.banner-carousel-indicators .indicator.active {
    background-color: #ffffff;
    transform: scale(1.2);
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.8);
}

.banner-placeholder {
    width: 100%;
    aspect-ratio: 16/10;
    background: linear-gradient(135deg, #003d99, #0052cc, #0073e6);
    color: var(--bg-white);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
    position: relative;
}

.banner-title-large {
    font-size: 32px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 8px;
    text-shadow: 0 4px 10px rgba(0,0,0,0.3);
    color: var(--bg-white);
}

.banner-highlight-yellow {
    color: var(--secondary-color);
}

.banner-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background-color: rgba(0, 0, 0, 0.4);
    color: var(--bg-white);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    backdrop-filter: blur(4px);
}

.banner-info-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background-color: var(--secondary-color);
}

.banner-info-text {
    flex: 1;
    font-size: 16px;
    font-weight: 700;
    color: var(--text-color);
    padding-right: 12px;
}

@keyframes pulse-effect {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.03);
        text-shadow: 0 0 6px rgba(255, 255, 255, 0.5);
    }
    100% {
        transform: scale(1);
    }
}

.pulse-text {
    animation: pulse-effect 2.5s infinite ease-in-out;
    display: inline-block;
    transform-origin: left center;
}

.banner-info-price {
    text-align: right;
}

.banner-info-price span {
    display: block;
    font-size: 14px;
    color: #014b94;
    font-weight: 700;
}

.banner-info-price strong {
    font-size: 24px;
    color: var(--text-color);
    font-weight: 800;
}

/* ----------------------------------------------------
 * Últimos Ganhadores (Carousel)
 * ---------------------------------------------------- */
.ganhadores-section {
    padding: 16px 0;
    background-color: var(--bg-white);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.ganhadores-carousel {
    display: flex;
    overflow: hidden;
    padding: 4px 16px;
    gap: 16px;
    align-items: center;
    position: relative;
}

.ganhadores-track {
    display: flex;
    gap: 12px;
    animation: marquee-scroll 35s linear infinite;
    width: max-content;
}

.ganhadores-track:hover {
    animation-play-state: paused;
}

@keyframes marquee-scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-50% - 6px)); /* Loop perfeito contínuo */
    }
}

.ganhadores-card-badge {
    background-color: var(--primary-light);
    border-radius: var(--border-radius-md);
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 100px;
    text-align: center;
    border: 1px solid rgba(0, 82, 204, 0.1);
    position: sticky;
    left: 0;
    z-index: 10;
    box-shadow: 6px 0 15px rgba(0,0,0,0.06);
}

.ganhadores-card-badge i {
    font-size: 28px;
    color: var(--secondary-color);
    margin-bottom: 4px;
}

.ganhadores-card-badge span {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--primary-color);
}

.ganhador-card {
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 220px;
    border: 1px solid rgba(0,0,0,0.02);
}

.ganhador-icon {
    width: 40px;
    height: 40px;
    background-color: var(--secondary-color);
    color: var(--bg-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.ganhador-info h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-color);
}

.ganhador-info p {
    font-size: 12px;
    color: var(--text-muted);
}

.ganhador-value {
    font-size: 15px;
    font-weight: 800;
    color: var(--success-dark);
}

/* ----------------------------------------------------
 * Super Combos Panel
 * ---------------------------------------------------- */
.combos-panel {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 500px;
    background-color: var(--bg-white);
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
    padding: 16px 16px 8px 16px;
    box-shadow: 0 -8px 30px rgba(0,0,0,0.15);
    z-index: 999;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
}

.panel-title {
    font-size: 16px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
}

.combos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 14px;
}

.combo-option {
    background-color: var(--bg-light);
    border: 2px solid transparent;
    border-radius: var(--border-radius-sm);
    padding: 8px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-fast);
    gap: 2px;
}

.combo-option:hover {
    background-color: var(--primary-light);
}

.combo-option.active {
    background-color: var(--primary-light);
    border-color: var(--primary-color);
}

.combo-info {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.combo-title {
    font-weight: 700;
    font-size: 11px;
    color: var(--primary-color);
    white-space: nowrap;
}

.combo-discount {
    display: none; /* Deixa super limpo e compacto como na imagem */
}

.combo-price {
    font-weight: 800;
    font-size: 12px;
    color: var(--text-color);
}

/* Quantidade Manual Seletor */
.qty-selector-container {
    background-color: var(--bg-light);
    border-radius: var(--border-radius-sm);
    padding: 10px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    border: 1px solid rgba(0,0,0,0.02);
}

.qty-total-label {
    display: flex;
    flex-direction: column;
}

.qty-total-label span {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
}

.qty-total-price {
    font-size: 22px;
    font-weight: 800;
    color: var(--secondary-dark);
}

.qty-controls {
    display: flex;
    align-items: center;
    background-color: var(--bg-white);
    border-radius: var(--border-radius-sm);
    border: 1px solid rgba(0,0,0,0.08);
    overflow: hidden;
}

.qty-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 70px;
    border-left: 1px solid rgba(0,0,0,0.08);
    border-right: 1px solid rgba(0,0,0,0.08);
    background-color: var(--bg-white);
    padding: 2px 0;
}

.qty-display-label {
    font-size: 8px;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    margin-bottom: -4px;
}

/* Espaçador do Rodapé Fixo no final do site */
.combos-panel-spacer {
    height: 20px;
    width: 100%;
}

.qty-btn {
    background-color: #ff0000;
    border: none;
    width: 44px;
    height: 44px;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    transition: var(--transition-fast);
}

.qty-btn:hover {
    background-color: #d60000;
}

.qty-input {
    width: 50px;
    text-align: center;
    font-size: 18px;
    font-weight: 700;
    border: none;
    outline: none;
    background: none;
    color: var(--text-color);
    pointer-events: none;
}

/* Botão de Compra Fixo / Principal */
.btn-primary-buy {
    width: 100%;
    background-color: var(--success-color);
    color: var(--bg-white);
    border: none;
    border-radius: var(--border-radius-md);
    padding: 18px 24px;
    font-size: 18px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-transform: uppercase;
    box-shadow: 0 6px 20px rgba(46, 204, 113, 0.3);
    transition: var(--transition-smooth);
    text-decoration: none;
}

.btn-primary-buy:hover {
    background-color: var(--success-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(46, 204, 113, 0.4);
}

.btn-primary-buy i {
    font-size: 22px;
}

/* ----------------------------------------------------
 * Etapas de Compra (Steps ProgressBar)
 * ---------------------------------------------------- */
.steps-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 16px;
    background-color: var(--bg-light);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.step-item {
    display: flex;
    align-items: center;
}

.step-bubble {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--bg-white);
    border: 2px solid rgba(0,0,0,0.15);
    color: var(--text-muted);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: var(--transition-fast);
}

.step-item.active .step-bubble {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-white);
}

.step-item.completed .step-bubble {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-white);
}

.step-line {
    width: 60px;
    height: 2px;
    background-color: rgba(0,0,0,0.1);
    margin: 0 8px;
}

.step-item.completed + .step-line {
    background-color: var(--primary-color);
}

/* ----------------------------------------------------
 * Resumo da Compra (`resumo.php`) & Cadastro
 * ---------------------------------------------------- */
.page-title {
    text-align: center;
    font-size: 22px;
    font-weight: 800;
    margin: 20px 0 12px;
    color: var(--text-color);
}

.summary-card {
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    padding: 16px;
    margin: 0 16px 20px;
    border: 1px solid rgba(0,0,0,0.02);
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.summary-row:last-child {
    border-bottom: none;
    font-weight: 800;
    font-size: 18px;
    color: var(--text-color);
}

.summary-row span {
    color: var(--text-muted);
    font-weight: 600;
}

.summary-row strong {
    color: var(--text-color);
}

/* Upsell Seção */
.upsell-section {
    padding: 0 16px;
    margin-bottom: 24px;
}

.upsell-title {
    font-size: 15px;
    font-weight: 800;
    margin-bottom: 12px;
    text-transform: uppercase;
    color: var(--primary-color);
    text-align: center;
}

.upsell-card {
    background-color: var(--bg-white);
    border: 2px solid rgba(0,0,0,0.05);
    border-radius: var(--border-radius-md);
    padding: 14px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    margin-bottom: 10px;
    transition: var(--transition-fast);
}

.upsell-card:hover {
    background-color: var(--primary-light);
}

.upsell-card.selected {
    background-color: var(--primary-light);
    border-color: var(--primary-color);
}

.upsell-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.upsell-icon {
    font-size: 20px;
    color: var(--primary-color);
    background-color: var(--bg-light);
    width: 40px;
    height: 40px;
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.upsell-label h4 {
    font-size: 14px;
    font-weight: 700;
}

.upsell-label p {
    font-size: 12px;
    color: var(--success-dark);
    font-weight: 600;
}

.upsell-add-btn {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: none;
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-fast);
}

.upsell-card.selected .upsell-add-btn {
    background-color: var(--primary-color);
    color: var(--bg-white);
}

/* Formulário de Identificação */
.form-section {
    padding: 0 16px;
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 16px;
    position: relative;
}

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text-color);
    text-transform: uppercase;
}

.input-control {
    width: 100%;
    padding: 14px 16px;
    font-size: 15px;
    border: 2px solid rgba(0,0,0,0.08);
    border-radius: var(--border-radius-sm);
    outline: none;
    background-color: var(--bg-light);
    transition: var(--transition-fast);
    color: var(--text-color);
    font-weight: 600;
}

.input-control:focus {
    border-color: var(--primary-color);
    background-color: var(--bg-white);
}

.input-spinner {
    position: absolute;
    right: 16px;
    top: 38px;
    font-size: 18px;
    color: var(--primary-color);
    animation: spin 1s linear infinite;
    display: none;
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}

.form-alert {
    background-color: var(--primary-light);
    border-left: 4px solid var(--primary-color);
    padding: 12px;
    border-radius: 0 var(--border-radius-sm) var(--border-radius-sm) 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

/* ----------------------------------------------------
 * Tela de Pagamento (`pagamento.php`)
 * ---------------------------------------------------- */
.payment-status-box {
    background-color: #f3f9f5;
    border: 1px solid #d4eedd;
    border-radius: var(--border-radius-md);
    padding: 16px;
    margin: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.payment-status-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: var(--text-color);
}

.payment-status-label i {
    color: var(--primary-color);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.6; }
    100% { transform: scale(1); opacity: 1; }
}

.payment-timer {
    background-color: rgba(0, 0, 0, 0.05);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    color: var(--danger-color);
}

.payment-instructions {
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    padding: 20px 16px;
    margin: 0 16px 20px;
}

.instruction-step {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.instruction-step:last-child {
    margin-bottom: 0;
}

.instruction-num {
    width: 28px;
    height: 28px;
    background-color: rgba(0,0,0,0.06);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 14px;
    flex-shrink: 0;
}

.instruction-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-color);
}

.instruction-text strong {
    color: var(--primary-dark);
}

.security-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 16px 24px;
    padding: 12px 16px;
    border-radius: var(--border-radius-sm);
    background-color: #e8f8f0;
    color: #1e7e4c;
    font-size: 13px;
    font-weight: 600;
}

.security-badge i {
    font-size: 24px;
}

/* Copia e Cola / QR Code */
.pix-qr-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background-color: var(--bg-white);
    border: 2px dashed rgba(0,0,0,0.1);
    border-radius: var(--border-radius-md);
    margin: 0 16px 20px;
}

.pix-qr-image {
    width: 200px;
    height: 200px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
}

.pix-copia-cola-text {
    width: 100%;
    background-color: var(--bg-light);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: var(--border-radius-sm);
    padding: 12px;
    font-family: monospace;
    font-size: 11px;
    color: var(--text-muted);
    word-break: break-all;
    max-height: 80px;
    overflow-y: auto;
    margin-bottom: 12px;
    user-select: all;
}

.btn-secondary-action {
    width: 100%;
    background-color: var(--bg-light);
    border: 1px solid rgba(0,0,0,0.08);
    color: var(--text-color);
    padding: 14px;
    border-radius: var(--border-radius-sm);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition-fast);
}

.btn-secondary-action:hover {
    background-color: var(--primary-light);
    color: var(--primary-color);
    border-color: rgba(0, 82, 204, 0.2);
}

/* Barra Fixa Inferior */
.bottom-action-bar {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 500px;
    background-color: var(--bg-white);
    padding: 12px 16px;
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.05);
    z-index: 90;
    border-top: 1px solid rgba(0,0,0,0.05);
}

/* ----------------------------------------------------
 * Meus Títulos & Premiações
 * ---------------------------------------------------- */
.tickets-list-container {
    padding: 0 16px;
}

.search-cpf-box {
    background-color: var(--bg-light);
    border-radius: var(--border-radius-md);
    padding: 20px 16px;
    margin-bottom: 24px;
    border: 1px solid rgba(0,0,0,0.02);
}

.ticket-group-card {
    background-color: var(--bg-white);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: var(--border-radius-md);
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
}

.ticket-group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.ticket-group-header h3 {
    font-size: 15px;
    font-weight: 700;
}

.ticket-badge-status {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.ticket-badge-status.approved {
    background-color: #e8f8f0;
    color: #1e7e4c;
}

.ticket-badge-status.pending {
    background-color: #fff9e6;
    color: #d49b00;
}

.ticket-badge-status.expired {
    background-color: #fde8e8;
    color: var(--danger-color);
}

.tickets-numbers-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ticket-number-pill {
    background-color: var(--bg-light);
    border: 1px solid rgba(0,0,0,0.04);
    padding: 6px 12px;
    border-radius: var(--border-radius-sm);
    font-family: monospace;
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-color);
}

/* Banner de Ganhador Festivo! */
.winner-banner-card {
    background: linear-gradient(135deg, var(--secondary-color), #ff8800);
    color: var(--bg-white);
    border-radius: var(--border-radius-md);
    padding: 24px 16px;
    text-align: center;
    margin-bottom: 20px;
    box-shadow: 0 8px 24px rgba(255, 187, 0, 0.4);
    position: relative;
    overflow: hidden;
    animation: borderGlow 2s infinite alternate;
}

@keyframes borderGlow {
    0% { box-shadow: 0 0 10px rgba(255, 187, 0, 0.4); }
    100% { box-shadow: 0 0 25px rgba(255, 187, 0, 0.8); }
}

.winner-banner-card h2 {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 8px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.winner-banner-card p {
    font-size: 15px;
    font-weight: 600;
}

.winner-banner-ticket {
    display: inline-block;
    background-color: var(--bg-white);
    color: #ff8800;
    font-family: monospace;
    font-size: 24px;
    font-weight: 900;
    padding: 6px 20px;
    border-radius: var(--border-radius-sm);
    margin-top: 12px;
    letter-spacing: 2px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* ----------------------------------------------------
 * Área Administrativa (/admin)
 * ---------------------------------------------------- */
.admin-container {
    max-width: 1000px;
    margin: 40px auto;
    padding: 0 20px;
}

.admin-login-card {
    max-width: 400px;
    margin: 80px auto;
    background-color: var(--bg-white);
    border-radius: var(--border-radius-md);
    padding: 32px 24px;
    box-shadow: var(--shadow-lg);
}

.admin-header-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background-color: var(--primary-color);
    color: var(--bg-white);
    border-radius: var(--border-radius-md);
    margin-bottom: 24px;
}

.admin-grid-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.metric-card {
    background-color: var(--bg-white);
    border-radius: var(--border-radius-md);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(0,0,0,0.04);
}

.metric-card h3 {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.metric-card p {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-color);
}

.admin-card-section {
    background-color: var(--bg-white);
    border-radius: var(--border-radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    border: 1px solid rgba(0,0,0,0.04);
}

.admin-table-wrapper {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 16px;
    text-align: left;
}

.admin-table th, .admin-table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    font-size: 14px;
}

.admin-table th {
    font-weight: 700;
    background-color: var(--bg-light);
    color: var(--text-color);
}

.admin-table tr:hover {
    background-color: var(--bg-light);
}

/* Modais & Notificações */
.notification-toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background-color: var(--text-color);
    color: var(--bg-white);
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.notification-toast.active {
    transform: translateX(-50%) translateY(0);
}

/* ----------------------------------------------------
 * Estilização Premium para Modal de Restrição de Idade & Selos
 * ---------------------------------------------------- */

/* Selo Moderno de Cidade Identificada */
.badge-city {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: var(--primary-light);
    color: var(--primary-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid rgba(0, 82, 204, 0.15);
    box-shadow: 0 2px 6px rgba(0, 82, 204, 0.05);
    animation: scaleIn 0.3s ease-out;
}

.badge-city i {
    font-size: 13px;
    color: var(--primary-color);
}

.badge-city strong {
    color: var(--primary-dark);
}

/* Modal Overlay com Efeito Blur (Glassmorphism) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(15, 23, 42, 0.7); /* Slate Escuro Transparente */
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

/* Modal Card Principal */
.modal-card {
    background-color: var(--bg-white);
    border-radius: var(--border-radius-md);
    width: 100%;
    max-width: 360px;
    padding: 32px 24px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(231, 76, 60, 0.15); /* Borda avermelhada sutil */
    animation: scaleIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Ícone de Restrição Animado */
.modal-icon-container {
    width: 68px;
    height: 68px;
    background-color: rgba(231, 76, 60, 0.08);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    color: var(--danger-color);
    font-size: 32px;
    border: 2px solid rgba(231, 76, 60, 0.15);
    animation: pulseWarning 2s infinite;
}

.modal-title {
    font-size: 21px;
    font-weight: 800;
    color: var(--text-color);
    margin-bottom: 12px;
    letter-spacing: -0.3px;
}

.modal-text {
    font-size: 14px;
    color: var(--text-color);
    line-height: 1.6;
    margin-bottom: 8px;
}

.modal-text strong {
    color: var(--danger-color);
    font-weight: 700;
}

.modal-subtext {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 24px;
}

/* Botão de Fechar Modal */
.btn-modal-close {
    width: 100%;
    padding: 14px 20px;
    background-color: var(--text-color);
    color: var(--bg-white);
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.8px;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
}

.btn-modal-close:hover {
    background-color: #1a252f;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Animações Premium */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleIn {
    from { transform: scale(0.92); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@keyframes pulseWarning {
    0% {
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.3);
    }
    70% {
        box-shadow: 0 0 0 12px rgba(231, 76, 60, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0);
    }
}

/* ----------------------------------------------------
 * Responsividade Desktop Geral
 * ---------------------------------------------------- */
@media (min-width: 501px) {
    .app-container {
        border-radius: 0;
        min-height: 100vh;
        box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
    }
}

/* ----------------------------------------------------
 * Modal de Conta do Usuário e Login
 * ---------------------------------------------------- */
.user-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}

.user-modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.user-modal-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 90%;
    max-width: 420px;
    background-color: var(--bg-white);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 2001;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), visibility 0.3s;
    overflow: hidden;
}

.user-modal-container.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.user-modal-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    position: relative;
}

.user-modal-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-color);
}

.user-modal-close {
    background-color: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #475569;
    font-size: 14px;
    transition: var(--transition-fast);
    position: absolute;
    right: 0;
    top: -4px;
}

.user-modal-close:hover {
    background-color: #cbd5e1;
    color: #0f172a;
}

.user-login-intro {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.5;
}

.user-profile-card {
    background-color: #eaeaea; /* Tom de cinza para destacar os dados */
    border-radius: 12px;
    padding: 20px;
    position: relative;
    margin-top: 10px;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
}

.user-mask-toggle {
    position: absolute;
    top: -12px;
    right: 16px;
    background-color: #fce3b6; /* Tom pêssego/amarelo da foto */
    border: 1px solid #fbd38d;
    width: 36px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.08);
    color: #744210;
    font-size: 14px;
    transition: all var(--transition-fast);
    z-index: 10;
}

.user-mask-toggle:hover {
    background-color: #fbd38d;
    transform: translateY(-1px);
}

.user-profile-main {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.user-profile-avatar {
    width: 48px;
    height: 48px;
    background-color: #c3d4f8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2b6cb0;
    font-size: 22px;
}

.user-profile-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-profile-info h4 {
    font-size: 16px;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
}

.user-profile-info span {
    font-size: 12px;
    color: #64748b;
    font-weight: 600;
}

.user-logout-btn {
    margin-left: auto;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: #fee2e2;
    color: #ef4444;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.user-logout-btn:hover {
    background-color: #fecaca;
    transform: scale(1.05);
}

.user-profile-divider {
    height: 1px;
    background-color: #cbd5e1;
    margin: 16px 0;
}

.user-profile-details {
    display: flex;
    justify-content: space-between;
    gap: 16px;
}

.user-detail-item {
    flex: 1;
}

.user-detail-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.user-detail-value {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #0f172a;
    font-family: monospace;
}

/* ----------------------------------------------------
 * Instant Prizes Section Styles
 * ---------------------------------------------------- */
.instant-prizes-bar {
    background-color: #004b93;
    padding: 14px 16px;
    margin-top: 6px; /* White thin space margin between draw price bar and this bar */
    color: #ffffff;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.instant-prizes-title {
    font-size: 15px;
    font-weight: 800;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.instant-prizes-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.prize-badge {
    border: 2px solid #ffffff;
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
    background: transparent;
    text-align: center;
    min-width: 90px;
    display: inline-block;
    transition: var(--transition-fast);
}

/* Attention-grabbing blinking effect */
@keyframes blink-effect {
    0%, 100% {
        box-shadow: 0 0 4px rgba(255, 255, 255, 0.2);
        border-color: #ffffff;
        background-color: transparent;
        color: #ffffff;
    }
    50% {
        box-shadow: 0 0 12px rgba(255, 187, 0, 0.8);
        border-color: #ffbb00;
        background-color: #ffbb00;
        color: #004b93;
    }
}

.prize-badge.blinking {
    animation: blink-effect 2s infinite ease-in-out;
}

/* Sequential delays for harmony */
.prize-badge.blinking:nth-child(1) { animation-delay: 0s; }
.prize-badge.blinking:nth-child(2) { animation-delay: 0.4s; }
.prize-badge.blinking:nth-child(3) { animation-delay: 0.8s; }
.prize-badge.blinking:nth-child(4) { animation-delay: 1.2s; }

/* Modal de Indicação */
.referral-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    box-sizing: border-box;
    padding: 16px;
}

.referral-modal.active {
    display: flex;
}

.referral-modal-content {
    background: linear-gradient(135deg, #e0f2fe, #f0f9ff);
    border: 2px solid #bae6fd;
    border-radius: 12px;
    width: 100%;
    max-width: 450px;
    padding: 24px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    position: relative;
    text-align: left;
    box-sizing: border-box;
    animation: scaleUp 0.3s ease;
}

@keyframes scaleUp {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.referral-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    font-size: 24px;
    color: #0369a1;
    cursor: pointer;
    background: none;
    border: none;
    font-weight: bold;
    line-height: 1;
    padding: 4px;
    transition: color 0.2s;
}

.referral-modal-close:hover {
    color: #0284c7;
}


