/* Stats Page CSS - Override main dark theme for better readability */

/* Override the main styles.css completely for stats page */
html, body {
    background-color: #f8f9fc !important;
    color: #212529 !important;
}

body {
    background-color: #f8f9fc !important;
    color: #212529 !important;
}

.stats-card {
    background: #fff;
    border: 1px solid #e3e6f0;
    border-radius: 0.35rem;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    transition: all 0.3s;
}

.stats-card:hover {
    box-shadow: 0 0.25rem 2rem 0 rgba(58, 59, 69, 0.2);
}

.border-left-primary {
    border-left: 0.25rem solid #4e73df !important;
}

.border-left-success {
    border-left: 0.25rem solid #1cc88a !important;
}

.border-left-info {
    border-left: 0.25rem solid #36b9cc !important;
}

.border-left-warning {
    border-left: 0.25rem solid #f6c23e !important;
}

.text-gray-300 {
    color: #dddfeb !important;
}

.text-gray-800 {
    color: #5a5c69 !important;
}

.card {
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    border: 1px solid #e3e6f0;
    background: #fff;
    color: #5a5c69;
}

.card-header {
    background-color: #f8f9fc;
    border-bottom: 1px solid #e3e6f0;
    color: #5a5c69;
}

.table {
    color: #5a5c69;
    background-color: #fff;
}

.table th {
    border-top: none;
    font-weight: 600;
    color: #5a5c69;
    background-color: #f8f9fc;
}

.table td {
    color: #5a5c69;
}

.badge {
    font-size: 0.75rem;
}

.table-sm th,
.table-sm td {
    padding: 0.5rem;
}

.alert {
    color: #5a5c69;
}

.text-muted {
    color: #6c757d !important;
}

.text-primary {
    color: #4e73df !important;
}

.text-success {
    color: #1cc88a !important;
}

.text-danger {
    color: #e74a3b !important;
}

.text-warning {
    color: #f6c23e !important;
}

.text-info {
    color: #36b9cc !important;
}

/* Force dark text for important elements */
.card-body {
    color: #5a5c69 !important;
}

.font-weight-bold {
    color: #5a5c69 !important;
}

h1, h2, h3, h4, h5, h6 {
    color: #5a5c69 !important;
}

.text-xs {
    color: #858796 !important;
}

/* Fix badge colors */
.badge-secondary {
    background-color: #6c757d;
    color: #fff;
}

.badge-warning {
    background-color: #f6c23e;
    color: #212529;
}

.badge-danger {
    background-color: #e74a3b;
    color: #fff;
}

.badge-dark {
    background-color: #343a40;
    color: #fff;
}

.badge-success {
    background-color: #1cc88a;
    color: #fff;
}

.badge-light {
    background-color: #f8f9fa;
    color: #212529;
}

.badge-info {
    background-color: #36b9cc;
    color: #fff;
}

/* Force ALL text to be dark - aggressive override */
*, *::before, *::after {
    color: #212529 !important;
}

/* Even more aggressive overrides */
body, html, div, span, p, td, th, h1, h2, h3, h4, h5, h6, small, strong {
    color: #212529 !important;
}

/* Override for specific color classes */
.text-success {
    color: #1cc88a !important;
}

.text-danger {
    color: #e74a3b !important;
}

.text-warning {
    color: #f6c23e !important;
}

.text-info {
    color: #36b9cc !important;
}

.text-primary {
    color: #4e73df !important;
}

.text-muted {
    color: #6c757d !important;
}

.text-light {
    color: #f8f9fa !important;
}

.text-dark {
    color: #343a40 !important;
}

/* Top bar override - keep dark theme for navigation */
#topbar {
    background-color: #213743 !important;
    box-shadow: 1px 1px 10px rgba(0, 0, 0, 0.5) !important;
}

#topbar,
#topbar h4,
#topbar small,
#topbar .text-light,
#topbar .btn,
#topbar a {
    color: #fff !important;
}

#topbar .text-muted {
    color: #adb5bd !important;
}

/* Keep buttons in topbar properly styled */
#topbar .btn-success {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: #fff !important;
}

#topbar .btn-outline-light {
    border-color: #fff !important;
    color: #fff !important;
}

#topbar .btn-outline-light:hover {
    background-color: #fff !important;
    color: #213743 !important;
}

/* Nuclear option - force everything to be visible */
.table,
.table td,
.table th,
.table tr,
.table tbody,
.table thead,
.card,
.card-body,
.card-header {
    color: #212529 !important;
    background-color: #fff !important;
}

.table-bordered td,
.table-bordered th {
    border: 1px solid #dee2e6 !important;
}

.table thead th {
    background-color: #e9ecef !important;
    color: #212529 !important;
    border-bottom: 2px solid #dee2e6 !important;
}

/* Fix any inheritance issues */
.container-xl,
.container-xl *,
.row,
.row *,
.col,
.col * {
    color: #212529 !important;
}

/* Override any Bootstrap text utilities */
.text-xs,
.font-weight-bold,
.h5,
.mb-0 {
    color: #212529 !important;
}

/* Final override - make absolutely sure content area text is dark */
.container-xl:not(#topbar .container-xl),
.container-xl:not(#topbar .container-xl) *:not(.btn):not(.badge) {
    color: #212529 !important;
}

/* Force white background for content cards */
.container-xl .card,
.container-xl .table,
.container-xl .alert {
    background-color: #fff !important;
}

/* Override inherited styles from main CSS */
.container-xl .table td,
.container-xl .table th {
    border-color: #dee2e6 !important;
    background-color: #fff !important;
    color: #212529 !important;
}

/* Force all table row backgrounds to be white or high contrast */
.table tbody tr,
.table tbody tr td,
.table tbody tr th {
    background-color: #fff !important;
    color: #212529 !important;
}

/* Override any Bootstrap table row coloring */
.table-success,
.table-success td,
.table-success th {
    background-color: #d4edda !important;
    color: #155724 !important;
    border-color: #c3e6cb !important;
}

.table-danger,
.table-danger td,
.table-danger th {
    background-color: #f8d7da !important;
    color: #721c24 !important;
    border-color: #f5c6cb !important;
}

.table-warning,
.table-warning td,
.table-warning th {
    background-color: #fff3cd !important;
    color: #856404 !important;
    border-color: #ffeaa7 !important;
}

.table-info,
.table-info td,
.table-info th {
    background-color: #d1ecf1 !important;
    color: #0c5460 !important;
    border-color: #bee5eb !important;
}

/* Force alternating row colors to be visible */
.table-striped tbody tr:nth-of-type(odd),
.table-striped tbody tr:nth-of-type(odd) td {
    background-color: #f8f9fa !important;
    color: #212529 !important;
}

.table-striped tbody tr:nth-of-type(even),
.table-striped tbody tr:nth-of-type(even) td {
    background-color: #fff !important;
    color: #212529 !important;
}

/* Override any yellow/cream table backgrounds completely */
.table tbody tr[style*="background"],
.table tbody td[style*="background"] {
    background-color: #fff !important;
    color: #212529 !important;
}

/* NUCLEAR OPTION: Force every single element in content area to be high contrast */
/* Exclude topbar from these overrides */
.container-xl:not(#topbar .container-xl) * {
    color: #212529 !important;
    background-color: transparent !important;
}

/* Reset card and table backgrounds */
.container-xl .card,
.container-xl .table,
.container-xl .card-body,
.container-xl .card-header {
    background-color: #fff !important;
}

/* Force specific high contrast for table elements */
.container-xl .table,
.container-xl .table *,
.container-xl table,
.container-xl table * {
    color: #212529 !important;
    font-weight: 500 !important;
}

.container-xl .table thead th {
    background-color: #e9ecef !important;
    color: #212529 !important;
    font-weight: 700 !important;
}

.container-xl .table tbody td {
    background-color: #fff !important;
    color: #212529 !important;
}

/* Override any specific text color utilities in content area */
.container-xl .text-success {
    color: #198754 !important;
    font-weight: 600 !important;
}

.container-xl .text-danger {
    color: #dc3545 !important;
    font-weight: 600 !important;
}

.container-xl .text-warning {
    color: #fd7e14 !important;
    font-weight: 600 !important;
}

.container-xl .text-muted {
    color: #6c757d !important;
    font-weight: 500 !important;
}

/* Ensure badges have proper contrast */
.container-xl .badge {
    font-weight: 700 !important;
    padding: 0.375rem 0.75rem !important;
}

.container-xl .badge-success {
    background-color: #198754 !important;
    color: #fff !important;
}

.container-xl .badge-danger {
    background-color: #dc3545 !important;
    color: #fff !important;
}

.container-xl .badge-warning {
    background-color: #fd7e14 !important;
    color: #fff !important;
}

.container-xl .badge-secondary {
    background-color: #6c757d !important;
    color: #fff !important;
}

/* Remove any transparency or opacity that might cause visibility issues */
.container-xl * {
    opacity: 1 !important;
}

/* Final override for any stubborn light colored elements */
.container-xl [style*="color: #fff"],
.container-xl [style*="color: white"],
.container-xl [style*="color: #f"],
.container-xl [style*="color: rgb(255"],
.container-xl [class*="text-light"],
.container-xl [class*="text-white"] {
    color: #212529 !important;
}

/* Force minimum font weight for better visibility */
.container-xl {
    font-weight: 500 !important;
}

/* Override any inherited light backgrounds */
.container-xl [style*="background-color: #fff"],
.container-xl [style*="background-color: white"],
.container-xl [style*="background-color: #f"],
.container-xl [style*="background: #f"],
.container-xl [class*="bg-light"],
.container-xl [class*="bg-white"] {
    background-color: #fff !important;
    color: #212529 !important;
}

/* Ensure good contrast for any remaining yellow/cream backgrounds */
.container-xl [style*="background-color: #ff"],
.container-xl [style*="background-color: yellow"],
.container-xl [style*="background-color: cream"] {
    background-color: #fff !important;
    color: #212529 !important;
} 
