:root {
    --primary: #22c55e;
    --primary-hover: #16a34a;
    --secondary: #FDC21D; /* Amarelo Queimado */
    --secondary-hover: #E5AE1A;
    --bg: #0a0a0a;
    --card-bg: #1a1a1a;
    --text: #ffffff;
    --text-muted: #a1a1aa;
    --success: #22c55e;
    --warning: #f59e0b;
    --danger: #ef4444;
    --glass-border: rgba(255, 255, 255, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

h1, h2, h3, .logo h2 {
    font-family: 'Outfit', sans-serif !important;
}

body {
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
    padding-top: 100px; /* Mais espaço para a nav flutuante */
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 2.5rem;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 95%;
    max-width: 1200px;
    border-radius: 100px;
    z-index: 2000;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

/* Força o equilíbrio para centralizar os links */
.navbar > a, .nav-auth {
    flex: 1;
    min-width: 200px; /* Garante que ambos os lados ocupem o mesmo espaço mínimo */
}

@media (max-width: 768px) {
    .navbar {
        padding: 0.75rem 1rem;
        top: 0.5rem;
    }
    .navbar > a, .nav-auth {
        min-width: 0;
        flex: 0 1 auto;
    }
    .navbar-links {
        flex: 1;
        gap: 1rem;
    }
    .nav-auth {
        display: none; /* Esconde o selo de segurança no mobile para ganhar espaço */
    }
}

.navbar-links {
    display: flex;
    gap: 3rem;
    flex: 2;
    justify-content: center;
}

.navbar-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-auth {
    display: flex;
    gap: 1.5rem;
    justify-content: flex-end;
    align-items: center;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Glassmorphism utility */
.glass {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 1.5rem;
}

/* Header & Hero */
header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
}

.hero-card {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    padding: 2rem;
    align-items: center;
    margin-bottom: 3rem;
}

.hero-image {
    flex: 1;
    min-width: 300px;
    height: 300px;
    border-radius: 1rem;
    overflow: hidden;
    position: relative;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.hero-image:hover img {
    transform: scale(1.05);
}

.hero-content {
    flex: 1.5;
    min-width: 300px;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--primary);
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ffffff 30%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -1px;
}

.price-tag {
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 1.5rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(to right, var(--primary), #818cf8);
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
    transition: width 1s ease-in-out;
}

/* Raffle Grid */
.raffle-container {
    margin-top: 2rem;
}

.grid-header {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.filter-bar {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
}

.filter-btn {
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    border: 1px solid var(--glass-border);
    background: var(--card-bg);
    color: var(--text-muted);
    font-size: 0.875rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s;
}

.filter-btn:hover {
    border-color: var(--primary);
    color: white;
}

.filter-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
}

.status-legend {
    display: flex;
    gap: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.available { background: var(--success); }
.dot.reserved { background: var(--warning); }
.dot.sold { background: var(--danger); }

.numbers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 0.75rem;
    margin-bottom: 2rem;
    contain: layout style; /* Otimização de renderização */
}

.number-card {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background 0.2s;
    border: 2px solid transparent;
    border-radius: 0.75rem;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.number-card.disponivel {
    background: #1e1e1e;
    color: var(--success);
    border-color: var(--success);
}

.number-card.disponivel:hover {
    background: var(--success);
    color: #000;
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 10px 20px rgba(34, 197, 94, 0.3);
}

.number-card.selected {
    background: linear-gradient(135deg, var(--secondary), #FFD75E);
    color: #000;
    border-color: #fff;
    transform: scale(1.15) rotate(2deg);
    box-shadow: 0 0 30px rgba(253, 194, 29, 0.8);
    z-index: 10;
}

.number-card.reservado {
    background: #f59e0b;
    color: #000;
    border-color: #f59e0b;
}

.number-card.vendido {
    background: #dc2626; /* Mantendo vermelho para vendido para clareza */
    color: rgba(255, 255, 255, 0.9);
    cursor: not-allowed;
    border: none;
}

/* Floating Action Bar */
.action-bar {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s ease;
}

.action-bar.visible {
    visibility: visible;
    opacity: 1;
    bottom: 3rem;
}

.btn {
    padding: 1rem 1.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px; /* Thumb-friendly height */
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.2);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: scale(1.02);
    box-shadow: 0 8px 25px rgba(34, 197, 94, 0.4);
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s;
}

.modal-overlay.open {
    visibility: visible;
    opacity: 1;
}

.modal {
    width: 95%;
    max-width: 500px;
    max-height: 90vh; /* Limita a altura em telas pequenas */
    padding: 2rem;
    position: relative;
    overflow-y: auto; /* Adiciona scroll se necessário */
    margin: 1rem;
}

.modal::-webkit-scrollbar {
    width: 4px;
}

.modal::-webkit-scrollbar-thumb {
    background: var(--secondary);
    border-radius: 10px;
}

.modal h2 {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.form-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 0.5rem;
    color: white;
    outline: none;
}

.form-group input:focus {
    border-color: var(--primary);
}

.pix-instructions {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 1rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.pix-key {
    font-family: monospace;
    background: black;
    padding: 0.5rem;
    border-radius: 0.25rem;
    display: block;
    margin: 1rem 0;
    word-break: break-all;
}

/* --- MODALS (BLINDAGEM UI) --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    display: none; /* Escondido por padrão */
    align-items: center;
    justify-content: center;
    z-index: 100000; /* Mais alto que o cabeçalho */
    padding: 1rem;
}

.modal-overlay.open {
    display: flex; /* Mostra quando tem a classe .open */
}

.modal {
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

/* Admin Styles */
.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 3rem;
}

@media (max-width: 992px) {
    .info-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .info-grid {
        grid-template-columns: 1fr;
    }
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.stat-card {
    padding: 1.5rem;
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.875rem;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.status-pill {
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.status-pill.disponivel { background: rgba(34, 197, 94, 0.2); color: #4ade80; }
.status-pill.reservado { background: rgba(234, 179, 8, 0.2); color: #facc15; }
.status-pill.vendido { background: rgba(239, 68, 68, 0.2); color: #f87171; }

.admin-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.875rem;
}

.btn-success { background: var(--success); color: white; }
.btn-danger { background: var(--danger); color: white; }

/* Animations */
/* Home Page Raffle Cards */
.raffle-grid-home {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.home-card {
    display: flex;
    background: var(--card-bg);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: transform 0.3s;
    border: 1px solid var(--glass-border);
}

.home-card:hover {
    transform: translateY(-5px);
}

.home-card-img {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9; /* PADRÃO PC: Fica tudo alinhado e perfeito */
    overflow: hidden;
    background: #000;
}

.home-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* No PC o cover é melhor para manter o design */
    display: block;
}

/* AJUSTE EXCLUSIVO MOBILE */
@media (max-width: 768px) {
    .home-card-img {
        aspect-ratio: auto !important;
        height: auto !important; /* Libera a altura total */
        min-height: 0;
        display: block; /* Remove o flex que pode estar centralizando e cortando */
    }
    
    .home-card-img img {
        position: relative; /* Remove posicionamento absoluto se houver */
        height: auto !important;
        width: 100% !important;
        object-fit: contain !important;
    }
}

.home-card-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.home-card-title {
    font-weight: 800;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.home-card-desc {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Footer Sections */
.info-section {
    padding: 4rem 0;
    border-top: 1px solid var(--glass-border);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.how-it-works {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
    counter-reset: step;
}

.step-card {
    position: relative;
    padding-left: 4rem;
}

.step-card::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    font-size: 4rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.05);
    line-height: 1;
}

.step-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.step-desc {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Floating WhatsApp */
.whatsapp-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: #25d366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: transform 0.3s;
}

.whatsapp-btn:hover {
    transform: scale(1.1);
}

.whatsapp-btn img {
    width: 35px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    nav, .navbar {
        padding: 0.75rem 1.5rem;
        width: 95%;
        top: 0.5rem;
    }

    .nav-links, .navbar-links {
        display: none;
    }

    h1 {
        font-size: 2.25rem;
        line-height: 1.1;
    }

    .premium-hero {
        padding: 4rem 1rem;
    }

    .premium-hero p {
        font-size: 1rem !important;
    }

    .hero-card {
        padding: 1rem;
        flex-direction: column;
    }

    .hero-image {
        width: 100%;
        height: 200px;
        min-width: unset;
    }

    .numbers-grid {
        grid-template-columns: repeat(5, 1fr); /* 5 colunas no mobile */
        gap: 0.5rem;
    }

    .number-card {
        font-size: 0.875rem;
    }

    .action-bar {
        width: 100%;
        padding: 1.25rem;
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        bottom: 0 !important;
        border-radius: 1.5rem 1.5rem 0 0;
        box-shadow: 0 -10px 25px rgba(0,0,0,0.5);
    }

    .action-bar .btn {
        width: 100%;
    }

    .home-card {
        flex-direction: column;
    }

    .home-card-img {
        width: 100%;
        height: 200px;
    }
}

/* Premium Hero Section */
.premium-hero {
    padding: 8rem 0 0 0; /* Zero absoluto na base */
    text-align: center;
    background: 
        radial-gradient(circle at top, rgba(239, 68, 68, 0.2) 0%, transparent 60%),
        linear-gradient(to bottom, #0a0a0a 0%, transparent 10%, transparent 90%, #0a0a0a 100%);
    position: relative;
    overflow: hidden;
    margin-top: -100px; /* Faz o brilho subir para trás do navbar */
    z-index: 1;
}

.premium-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('https://www.transparenttextures.com/patterns/carbon-fibre.png');
    opacity: 0.1;
    pointer-events: none;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reveal {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Trust Badges */
.trust-badges-container {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 4rem;
    flex-wrap: wrap;
}

.trust-badge-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.trust-badge-item:hover {
    opacity: 1;
}

.trust-badge-icon {
    font-size: 2rem;
}

.trust-badge-text {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Urgency Timer */
.timer-container {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    padding: 0.75rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #f87171;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.timer-dot {
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    animation: pulse 1s infinite;
}

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

/* Copy Button */
.copy-btn {
    padding: 0.5rem 1rem;
    background: var(--secondary);
    color: black;
    border: none;
    border-radius: 0.5rem;
    font-weight: 800;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
    margin-left: 0.5rem;
}

.copy-btn:hover {
    transform: scale(1.05);
    background: #fbbf24;
}

@media (max-width: 480px) {
    .numbers-grid {
        grid-template-columns: repeat(4, 1fr); /* 4 colunas em telas muito pequenas */
    }
}

/* Description Box Scrollable */
.description-box-scroll {
    background: #1a1a1a;
    color: #eee;
    padding: 1.25rem;
    border-radius: 0.75rem;
    max-height: 220px;
    overflow-y: auto;
    font-size: 0.875rem;
    line-height: 1.6;
    margin: 1.25rem 0;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

#raffle-desc {
    white-space: pre-wrap;
}

/* Custom scrollbar para a descrição - Dark Mode */
.description-box-scroll::-webkit-scrollbar {
    width: 6px;
}
.description-box-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}
.description-box-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}
.description-box-scroll::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

/* Toast Notifications */
.toast {
    position: fixed;
    top: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(20, 20, 20, 0.95);
    backdrop-filter: blur(10px);
    color: white;
    padding: 1rem 2rem;
    border-radius: 1rem;
    border: 1px solid var(--glass-border);
    z-index: 999999; /* Garantir que fique acima de TODOS os modais */
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.toast.success { border-left: 4px solid var(--success); }
.toast.error { border-left: 4px solid var(--danger); }
.toast.warning { border-left: 4px solid var(--warning); }

.toast-icon {
    font-size: 1.25rem;
}

/* Admin Layout Restructuring */
.admin-container {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 100vh;
    background: var(--bg);
}

.admin-sidebar {
    background: #0f0f0f;
    border-right: 1px solid var(--glass-border);
    padding: 2rem;
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.admin-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-x: auto;
    flex-wrap: nowrap; /* Garante que nunca quebre linha */
    scrollbar-width: none; 
}
.admin-nav::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.admin-nav-item {
    padding: 1rem;
    border-radius: 0.75rem;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.2s;
    cursor: pointer;
    white-space: nowrap; /* Impede o texto de quebrar */
    flex-shrink: 0; /* Impede o botão de esmagar */
}

.admin-nav-item:hover, .admin-nav-item.active {
    background: rgba(255, 255, 255, 0.05);
    color: white;
}

.admin-nav-item.active {
    border-left: 4px solid var(--secondary);
    background: rgba(245, 158, 11, 0.1);
}

.admin-main {
    padding: 3rem;
}

.admin-view {
    display: none;
}

.admin-view.active {
    display: block;
}

/* Winner Gallery */
.winners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.winner-card {
    background: var(--card-bg);
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    transition: transform 0.3s;
}

.winner-card:hover {
    transform: translateY(-5px);
}

.winner-card-img {
    height: 200px;
    width: 100%;
}

.winner-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.winner-card-content {
    padding: 1.5rem;
}

.winner-card-title {
    font-weight: 800;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.winner-info-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.winner-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--secondary);
    color: black;
    font-weight: 800;
    border-radius: 2rem;
    font-size: 0.75rem;
    margin-bottom: 1rem;
}

/* --- ADMIN RESPONSIVENESS --- */
@media (max-width: 1024px) {
    .admin-container {
        display: block; /* Empilha sidebar e main */
    }

    .admin-sidebar {
        width: 100%;
        height: auto;
        padding: 1rem;
        position: sticky;
        top: 0;
        z-index: 1000;
        border-right: none;
        border-bottom: 1px solid var(--glass-border);
        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(10px);
    }

    .admin-sidebar .logo {
        margin-bottom: 1rem;
        display: flex;
        align-items: center;
        gap: 1rem;
    }

    .admin-nav {
        display: flex;
        flex-direction: row;
        overflow-x: auto;
        gap: 0.5rem;
        padding-bottom: 0.5rem;
        scrollbar-width: none; /* Esconde barra no Firefox */
    }

    .admin-nav::-webkit-scrollbar {
        display: none; /* Esconde barra no Chrome/Safari */
    }

    .admin-nav-item {
        white-space: nowrap;
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
        margin-bottom: 0;
    }

    .admin-main {
        padding: 1rem;
    }

    .admin-stats {
        grid-template-columns: 1fr; /* Um card por linha no mobile */
        gap: 1rem;
    }

    .stat-card {
        padding: 1.5rem;
    }

    .admin-table-container, 
    .glass {
        overflow-x: auto; /* Permite rolar tabelas largas */
    }

    .admin-table {
        min-width: 600px; /* Garante que a tabela não esprema os dados */
    }

    header h1 {
        font-size: 1.5rem;
    }
}
footer {
    background: #0a0a0a;
    border-top: 1px solid var(--glass-border);
    padding: 3rem 0;
    margin-top: 4rem;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.footer-dev {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-dev a {
    color: var(--secondary);
    text-decoration: none;
    font-weight: 700;
    transition: opacity 0.2s;
}

/* PERFORMANCE & ACCESSIBILITY PACK */

/* Se o celular estiver em modo de economia ou o usuário preferir menos movimento */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* Otimização de renderização de imagens */
img {
    content-visibility: auto;
    max-width: 100%;
}

/* Melhora o contraste e legibilidade para todas as idades */
p {
    line-height: 1.6;
    letter-spacing: 0.01em;
}

/* Garantir área de clique mínima para dedos maiores */
button, .btn, a {
    min-height: 44px;
}

/* Suaviza o scroll sem pesar no processador */
html {
    scroll-behavior: smooth;
}

.footer-dev a:hover {
    opacity: 0.8;
}

/* Floating Price Badge on Home Cards */
.home-card-img {
    position: relative;
}

.price-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: var(--primary);
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 2rem;
    font-weight: 900;
    font-size: 0.8rem;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.4);
    z-index: 2;
    border: 2px solid rgba(255,255,255,0.2);
    white-space: nowrap;
}

/* Latest Winner Banner */
.latest-winner-banner {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 1rem;
    border-radius: 1rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 0.9rem;
}

.winner-highlight {
    color: var(--secondary);
    font-weight: 700;
}

/* --- Page Loader --- */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg);
    z-index: 999999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--secondary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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