/* ==========================================================================
   TEMA: BacRoyale — alinhado ao bacbo-autobet 3.0.4
   Paleta: #ffffff, #f4f7fb, #0161EC (azul), #E01519 (vermelho)
   ========================================================================== */

/* ===================================
   FUNDOS E BACKGROUNDS
   =================================== */

body {
    background: linear-gradient(180deg, #ffffff 0%, #f4f7fb 100%) !important;
    color: #16202e !important;
}

html {
    background: linear-gradient(180deg, #ffffff 0%, #f4f7fb 100%) !important;
}

.background-overlay {
    background: radial-gradient(circle at 50% 50%, rgba(1, 97, 236, 0.06) 0%, transparent 50%),
                linear-gradient(180deg, #ffffff 0%, #f4f7fb 100%);
}

/* ===================================
   TEXTO GERAL (tema claro)
   =================================== */

.section,
.card,
.game-card,
.news-card,
.stats-card,
.dashboard-container,
.main-content-wrapper,
.menu-item,
h1, h2, h3, h4, h5, h6,
p,
.section-title,
.section-subtitle {
    color: #16202e;
}

.text-muted,
.section-description {
    color: #EEEEF0!important;
}

/* ===================================
   CARDS E CONTAINERS
   =================================== */

.card, .game-card, .news-card, .stats-card {
    background: #ffffff !important;
    border: 1px solid #e3e8ef;
    box-shadow: 0 2px 10px rgba(16, 32, 46, 0.06);
}

.card:hover {
    border-color: rgba(1, 97, 236, 0.35);
    box-shadow: 0 4px 16px rgba(1, 97, 236, 0.12);
}

/* ===================================
   BOTÕES
   =================================== */

.btn-primary {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    border: none;
    box-shadow: 0 4px 15px rgba(1, 97, 236, 0.28);
    color: #ffffff !important;
    font-weight: 700;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #3d8bff, #0161EC) !important;
    box-shadow: 0 6px 22px rgba(1, 97, 236, 0.4);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(1, 97, 236, 0.08) !important;
    border: 1px solid #e3e8ef !important;
    color: #0161EC !important;
    box-shadow: none;
}

.btn-secondary:hover {
    background: rgba(1, 97, 236, 0.15) !important;
    border-color: #0161EC !important;
    box-shadow: 0 0 10px rgba(1, 97, 236, 0.18);
}

/* ===================================
   HEADER E NAVEGAÇÃO
   =================================== */

.header {
    background: rgba(255, 255, 255, 0.96) !important;
    border-bottom: 1px solid #e3e8ef !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 2px 8px rgba(16, 32, 46, 0.05);
    color: #16202e;
}

.header .menu-item,
.header .user-balance,
.header .balance-toggle {
    color: #16202e !important;
}

.menu-item.active {
    background: rgba(1, 97, 236, 0.08);
    border-left: 3px solid #0161EC;
    color: #0161EC !important;
}

.menu-item:hover {
    background: rgba(1, 97, 236, 0.05);
}

/* ===================================
   BADGES E LABELS
   =================================== */

.badge-premium, .badge-gold {
    background: linear-gradient(135deg, #0161EC, #0149b3);
    color: #ffffff;
    font-weight: 700;
}

.badge-success, .badge-green {
    background: linear-gradient(135deg, #0161EC, #0149b3);
    color: #ffffff;
}

/* ===================================
   INPUTS E FORMS
   =================================== */

input, textarea, select {
    background: #f1f4f9;
    border-color: #e3e8ef !important;
    color: #16202e;
}

input:focus, textarea:focus, select:focus {
    border-color: #0161EC !important;
    box-shadow: 0 0 0 3px rgba(1, 97, 236, 0.12) !important;
    background: #ffffff;
}

.form-input:focus {
    border-color: #0161EC;
}

/* ===================================
   PROGRESS BARS E LOADERS
   =================================== */

.progress-bar {
    background: linear-gradient(90deg, #0149b3, #0161EC);
}

.loading-spinner i {
    color: #0161EC;
}

/* ===================================
   NOTIFICAÇÕES E ALERTAS
   =================================== */

.alert-success {
    background: rgba(1, 97, 236, 0.06);
    border-left: 4px solid #0161EC;
    color: #0149b3;
}

.alert-warning {
    background: rgba(214, 158, 46, 0.08);
    border-left: 4px solid #d69e2e;
    color: #b07d10;
}

.alert-error {
    background: rgba(224, 21, 25, 0.08);
    border-left: 4px solid #E01519;
    color: #E01519;
}

/* ===================================
   TOOLTIPS E POPOVERS
   =================================== */

.tooltip {
    background: #ffffff;
    border: 1px solid #e3e8ef;
    color: #16202e;
}

/* ===================================
   SCROLLBARS
   =================================== */

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #0161EC, #0149b3);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #3d8bff, #0161EC);
}

::-webkit-scrollbar-track {
    background: #f4f7fb;
}

/* ===================================
   FOOTER
   =================================== */

.site-footer {
    background: #ffffff !important;
    border-top: 1px solid #e3e8ef !important;
    border-radius: 0 !important;
    box-shadow: 0 -2px 12px rgba(16, 32, 46, 0.04) !important;
    color: #46556b !important;
}

.site-footer p,
.site-footer .footer-text p.text-justify {
    color: #000000 !important;
}

.site-footer .footer-text p.text-justify strong,
.site-footer .footer-text p.text-justify b {
    color: #000000 !important;
}

.site-footer .responsible-gaming-link,
.site-footer .responsible-text {
    color: #000000 !important;
}

.site-footer .age-badge {
    border-color: #0161EC !important;
    background: rgba(1, 97, 236, 0.08) !important;
    color: #0161EC !important;
}

/* ===================================
   DESTAQUE E ANIMAÇÕES
   =================================== */

@keyframes gold-glow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(1, 97, 236, 0.25);
    }
    50% {
        box-shadow: 0 0 20px rgba(1, 97, 236, 0.45);
    }
}

.glow-gold {
    animation: gold-glow 2s ease-in-out infinite;
}

@keyframes accent-glow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(1, 97, 236, 0.2);
    }
    50% {
        box-shadow: 0 0 20px rgba(1, 97, 236, 0.4);
    }
}

.glow-green {
    animation: accent-glow 2s ease-in-out infinite;
}

/* ===================================
   GRADIENTES DE TEXTO
   =================================== */

.text-gradient-gold {
    background: linear-gradient(135deg, #0161EC, #E01519);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

.text-gradient-green {
    background: linear-gradient(135deg, #3d8bff, #0161EC);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===================================
   AJUSTES ESPECÍFICOS
   =================================== */

.btn-deposit {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    box-shadow: 0 4px 15px rgba(1, 97, 236, 0.3);
    color: #ffffff !important;
    font-weight: 700;
}

.btn-deposit:hover {
    background: linear-gradient(135deg, #3d8bff, #0161EC) !important;
    box-shadow: 0 6px 22px rgba(1, 97, 236, 0.45);
}

.user-balance {
    background: rgba(1, 97, 236, 0.06) !important;
    border: 1px solid rgba(1, 97, 236, 0.25) !important;
    color: #0161EC !important;
}

.user-balance:hover {
    background: rgba(1, 97, 236, 0.1) !important;
    border-color: rgba(1, 97, 236, 0.4) !important;
    box-shadow: 0 0 12px rgba(1, 97, 236, 0.15);
}

.balance-toggle {
    color: #0161EC !important;
}

.balance-toggle:hover {
    color: #0149b3 !important;
}

.login-logo, .header-logo {
    filter: drop-shadow(0 0 6px rgba(1, 97, 236, 0.25));
}

.bottom-menu-item.active {
    color: #0161EC !important;
}

.bottom-menu-item.active i {
    color: #0161EC !important;
}

i.fa-star, i.fa-crown, i.fa-trophy, i.fa-coins {
    color: #0161EC !important;
}

.text-gold, .gold-text {
    color: #0161EC !important;
}

.border-gold {
    border-color: rgba(1, 97, 236, 0.35) !important;
}

/* ===================================
   CORREÇÕES GLOBAIS — texto em fundo claro
   (legado usava --text-light = branco)
   =================================== */

.form-label,
.card-subtitle,
.stats-header h3,
.stats-header h4,
.game-session-header h2,
.bacbo-header h2,
.section-title,
.section-subtitle,
.analises-header h4,
.suggestions-header h4,
.history-header h3 {
    color: #16202e !important;
}

#historyContainerMobile .history-header h3,
#historyContainerDesktop .history-header h3 {
    color: #ffffff !important;
}

.user-balance,
.user-balance i,
.balance-toggle {
    color: #0161EC !important;
}

.card-subtitle,
.text-muted,
.game-description {
    color: #46556b !important;
}

/* Seções com fundo levemente diferenciado (não tudo branco puro) */
.section {
    background: transparent;
}

.inicio-section-new {
    background: linear-gradient(180deg, #f4f7fb 0%, #eef2f8 100%);
}

.content-section {
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 2px 12px rgba(16, 32, 46, 0.06);
}

.useful-links {
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 2px 12px rgba(16, 32, 46, 0.06);
}

.ranking-ativos-section {
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 2px 12px rgba(16, 32, 46, 0.06);
}

/* Game session — fundo e layout */
.game-session {
    background: linear-gradient(180deg, #f4f7fb 0%, #eef2f8 100%);
}

#game-session .history-container,
.game-session .history-container {
    box-shadow: 0 2px 12px rgba(16, 32, 46, 0.12);
}

#historyContainerMobile.history-container,
#historyContainerDesktop.history-container,
#historyContainerMobile,
#historyContainerDesktop {
    background: #EEEEF0!important;
    border-color: #6a7585 !important;
}

#game-session .sinais-welcome {
    color: #7b8794;
}

#game-session .sinais-welcome i {
    color: #0161EC;
    opacity: 0.65;
}

#game-session .sinais-message {
    border: 1px solid #e3e8ef;
    background: #f7f9fc;
    backdrop-filter: none;
}

#game-session .sinais-entry {
    background: rgba(1, 97, 236, 0.06);
    border-color: rgba(1, 97, 236, 0.22);
    box-shadow: none;
}

#game-session .sinais-entry[data-target="V"] {
    background: rgba(224, 21, 25, 0.06);
    border-color: rgba(224, 21, 25, 0.22);
}

#game-session .sinais-entry[data-target="A"] {
    background: rgba(1, 97, 236, 0.06);
    border-color: rgba(1, 97, 236, 0.22);
}

#game-session .sinais-finalization {
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.22);
}

#game-session .sinais-gale {
    background: rgba(214, 158, 46, 0.08);
    border-color: rgba(214, 158, 46, 0.28);
}

#game-session .sinais-loss {
    background: rgba(224, 21, 25, 0.08);
    border-color: rgba(224, 21, 25, 0.25);
}

#game-session .sinais-msg-title--entry,
#game-session .sinais-msg-signal-line,
#game-session .sinais-msg-meta,
#game-session .sinais-msg-body {
    color: #16202e;
}

#game-session .sinais-msg-signal-line {
    color: #46556b;
}

#game-session .sinais-msg-header--entry {
    border-bottom-color: #e3e8ef;
}

#game-session .sinais-chat-body {
    scrollbar-color: rgba(1, 97, 236, 0.35) transparent;
}

#game-session .sinais-chat-body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(1, 97, 236, 0.45), rgba(1, 97, 236, 0.15));
}

/* Modal termo de responsabilidade (login) */
body.login-page #termModal .modal-content {
    background: #ffffff;
    border: 1px solid #e3e8ef;
    width: min(480px, 92vw);
    max-width: 480px;
    height: auto;
    max-height: 90vh;
    box-shadow: 0 12px 40px rgba(16, 32, 46, 0.18);
}

body.login-page #termModal .modal-header {
    background: linear-gradient(135deg, rgba(1, 97, 236, 0.08), rgba(224, 21, 25, 0.04));
    border-bottom: 1px solid #e3e8ef;
}

body.login-page #termModal .modal-header h3,
body.login-page #termModal .redirect-info h4,
body.login-page #termModal .redirect-info p,
body.login-page #termModal .redirect-icon {
    color: #16202e;
}

body.login-page #termModal .redirect-icon {
    color: #0161EC;
}

body.login-page #termModal .modal-close {
    color: #46556b;
}

body.login-page #termModal .modal-close:hover {
    background: rgba(1, 97, 236, 0.08);
    color: #0161EC;
}

body.login-page #termModal .btn-secondary {
    background: #f1f4f9 !important;
    border: 1px solid #e3e8ef !important;
    color: #46556b !important;
}

/* ===================================
   PAINEL ADMIN — tema claro (contraste)
   admin.css usa --text-light (#fff) herdado do tema escuro
   =================================== */

.admin-container {
    color: #16202e;
}

.admin-container .admin-title,
.admin-container .admin-subtitle,
.admin-container .section-header h2,
.admin-container .users-header h2,
.admin-container .chart-header h3,
.admin-container .charts-row .chart-header h3,
.admin-container .stat-number,
.admin-container .dashboard-stats .stat-info h3,
.admin-container .current-banner-section h3,
.admin-container .banner-info-card .info-content h4,
.admin-container .empty-state h3,
.admin-container .banner-preview label,
.admin-container .modal-header h3,
.admin-container .user-info h4,
.admin-container .permissions-section h4,
.admin-container .permission-title,
.admin-container .form-group label,
.admin-container .content-table th,
.admin-container .users-table th,
.admin-container .info-row span:last-child,
.admin-container #editAssinaturaModal .info-row span:last-child {
    color: #16202e !important;
}

.admin-container .admin-subtitle,
.admin-container .stat-label,
.admin-container .dashboard-stats .stat-info p,
.admin-container .content-table td,
.admin-container .users-table td,
.admin-container .banner-info-card .info-content ul li,
.admin-container .banner-details p,
.admin-container .empty-state p,
.admin-container .info-label,
.admin-container .permission-desc,
.admin-container .file-input-name,
.admin-container .form-help {
    color: #46556b !important;
}

.admin-container .admin-nav-btn:not(.active),
.admin-container .btn-back-dashboard,
.admin-container .search-box input,
.admin-container .btn-refresh,
.admin-container .action-btn,
.admin-container .pagination-btn:not(.active),
.admin-container .form-group .form-input,
.admin-container .file-input-label,
.admin-container .premium-date-field .form-input,
.admin-container .banner-topo-dia-lbl {
    color: #16202e !important;
}

.admin-container .search-box input,
.admin-container .form-group .form-input,
.admin-container .premium-date-field .form-input {
    background: #f1f4f9 !important;
    border-color: #e3e8ef !important;
}

.admin-container .search-box input:focus,
.admin-container .form-group .form-input:focus,
.admin-container .premium-date-field .form-input:focus {
    background: #ffffff !important;
    border-color: #0161EC !important;
    box-shadow: 0 0 0 3px rgba(1, 97, 236, 0.12) !important;
}

.admin-container .search-box input::placeholder,
.admin-container .form-group .form-input::placeholder {
    color: #EEEEF0!important;
}

.admin-container .admin-nav-btn:not(.active) {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
}

.admin-container .admin-nav-btn:not(.active):hover {
    background: rgba(1, 97, 236, 0.06) !important;
    border-color: rgba(1, 97, 236, 0.35) !important;
    color: #0161EC !important;
    box-shadow: 0 4px 12px rgba(1, 97, 236, 0.12) !important;
}

.admin-container .admin-nav-btn.active {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    border-color: #0161EC !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(1, 97, 236, 0.28) !important;
}

.admin-container .admin-nav-btn.active i,
.admin-container .section-header h2 i,
.admin-container .admin-title i,
.admin-container .users-header h2 i,
.admin-container .chart-header i,
.admin-container .charts-row .chart-header i,
.admin-container .current-banner-section h3 i,
.admin-container .modal-header i {
    color: #0161EC !important;
}

.admin-container .admin-nav-btn.active i {
    color: #ffffff !important;
}

.admin-container .btn-back-dashboard {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
    color: #0161EC !important;
}

.admin-container .btn-back-dashboard:hover {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    border-color: #0161EC !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(1, 97, 236, 0.28) !important;
}

.admin-container .content-table-container,
.admin-container .users-table-container {
    background: #ffffff;
    border-color: #e3e8ef !important;
    box-shadow: 0 2px 10px rgba(16, 32, 46, 0.06);
}

.admin-container .content-table,
.admin-container .users-table {
    background: #ffffff !important;
}

.admin-container .content-table thead,
.admin-container .users-table thead {
    background: #f4f7fb !important;
}

.admin-container .content-table tbody tr:hover,
.admin-container .users-table tbody tr:hover {
    background: rgba(1, 97, 236, 0.04) !important;
}

.admin-container .content-table th,
.admin-container .content-table td,
.admin-container .users-table th,
.admin-container .users-table td {
    border-bottom-color: #e3e8ef !important;
}

.admin-container .admin-navigation {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
    box-shadow: 0 2px 10px rgba(16, 32, 46, 0.06);
}

.admin-container .stat-card,
.admin-container .chart-container,
.admin-container .dashboard-stats .stat-card,
.admin-container .charts-row .chart-container,
.admin-container .banner-info-card,
.admin-container .banner-preview-card,
.admin-container .empty-state {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
    box-shadow: 0 2px 10px rgba(16, 32, 46, 0.06);
}

.admin-container .stat-card::before,
.admin-container .chart-container::before,
.admin-container .dashboard-stats .stat-card::before,
.admin-container .charts-row .chart-container::before {
    background: linear-gradient(90deg, #0161EC, #0149b3) !important;
}

.admin-container .stat-icon {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    color: #ffffff !important;
}

.admin-container .action-btn:hover {
    background: #0161EC !important;
    border-color: #0161EC !important;
    color: #ffffff !important;
}

.admin-container .pagination-btn:hover {
    background: rgba(1, 97, 236, 0.08) !important;
    border-color: rgba(1, 97, 236, 0.35) !important;
    color: #0161EC !important;
}

.admin-container .pagination-btn.active {
    background: linear-gradient(135deg, #0161EC, #0149b3) !important;
    border-color: #0161EC !important;
    color: #ffffff !important;
}

.admin-container .modal-content {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
    box-shadow: 0 12px 40px rgba(16, 32, 46, 0.18);
}

.admin-container .modal-header,
.admin-container .modal-footer {
    border-color: #e3e8ef !important;
}

.admin-container .user-info,
.admin-container .permission-item {
    background: #f7f9fc !important;
    border-color: #e3e8ef !important;
}

.admin-container .file-input-label {
    background: #f7f9fc !important;
    border-color: #e3e8ef !important;
}

.admin-container .file-input-label:hover {
    background: rgba(1, 97, 236, 0.06) !important;
    border-color: rgba(1, 97, 236, 0.35) !important;
}

.admin-container .file-input-name {
    background: #f1f4f9 !important;
    border-color: #e3e8ef !important;
}

.admin-container .modal-close {
    color: #EEEEF0!important;
}

.admin-container .modal-close:hover {
    color: #0161EC !important;
    background: rgba(1, 97, 236, 0.08) !important;
}

.admin-container .toggle-label {
    background: #e3e8ef !important;
    border-color: #cbd5e1 !important;
}

.admin-container .toggle-switch input[type="checkbox"]:checked + .toggle-label {
    background: #0161EC !important;
    border-color: #0161EC !important;
}

.admin-container .banner-info-card .info-content ul li::before {
    color: #0161EC !important;
}

.admin-container .banner-details a {
    color: #0161EC !important;
}

.admin-container code {
    background: rgba(1, 97, 236, 0.08);
    color: #0149b3;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Modais e overlays do admin (fora de .admin-container) */
body.admin-page .modal-content {
    background: #ffffff !important;
    border-color: #e3e8ef !important;
    box-shadow: 0 12px 40px rgba(16, 32, 46, 0.18);
}

body.admin-page .modal-header,
body.admin-page .modal-footer {
    border-color: #e3e8ef !important;
}

body.admin-page .modal-header h3,
body.admin-page .user-info h4,
body.admin-page .permissions-section h4,
body.admin-page .permission-title,
body.admin-page .form-group label,
body.admin-page .info-row span:last-child,
body.admin-page #editAssinaturaModal .info-row span:last-child,
body.admin-page .banner-preview label {
    color: #16202e !important;
}

body.admin-page .info-label,
body.admin-page .permission-desc,
body.admin-page .form-help,
body.admin-page .file-input-name {
    color: #46556b !important;
}

body.admin-page .form-group .form-input,
body.admin-page .premium-date-field .form-input {
    background: #f1f4f9 !important;
    border-color: #e3e8ef !important;
    color: #16202e !important;
}

body.admin-page .form-group .form-input:focus,
body.admin-page .premium-date-field .form-input:focus {
    background: #ffffff !important;
    border-color: #0161EC !important;
    box-shadow: 0 0 0 3px rgba(1, 97, 236, 0.12) !important;
}

body.admin-page .form-group .form-input::placeholder {
    color: #EEEEF0!important;
}

body.admin-page .user-info,
body.admin-page .permission-item {
    background: #f7f9fc !important;
    border-color: #e3e8ef !important;
}

body.admin-page .file-input-label {
    background: #f7f9fc !important;
    border-color: #e3e8ef !important;
    color: #16202e !important;
}

body.admin-page .file-input-label:hover {
    background: rgba(1, 97, 236, 0.06) !important;
    border-color: rgba(1, 97, 236, 0.35) !important;
}

body.admin-page .file-input-name {
    background: #f1f4f9 !important;
    border-color: #e3e8ef !important;
}

body.admin-page .modal-header i {
    color: #0161EC !important;
}

body.admin-page .modal-close {
    color: #EEEEF0!important;
}

body.admin-page .modal-close:hover {
    color: #0161EC !important;
    background: rgba(1, 97, 236, 0.08) !important;
}

body.admin-page .toggle-label {
    background: #e3e8ef !important;
    border-color: #cbd5e1 !important;
}

body.admin-page .toggle-switch input[type="checkbox"]:checked + .toggle-label {
    background: #0161EC !important;
    border-color: #0161EC !important;
}

body.admin-page .banner-topo-dia-lbl {
    color: #16202e !important;
}

body.admin-page .loading-spinner {
    color: #ffffff !important;
}

body.admin-page .loading-spinner i {
    color: #0161EC !important;
}

/* Reforço final — body admin sempre legível */
body.admin-page {
    color: #16202e !important;
}
