/* Direct Contrast Fix - Applied via CSS */

/* Force remove all previous color overrides */
* {
    color: initial !important;
}

/* Base text colors with high contrast */
body {
    color: #111827 !important;
    background-color: #FFFFFF !important;
}

/* Fix purple gradient backgrounds */
body[style*="background: linear-gradient"] {
    background: #FFFFFF !important;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    color: #000000 !important;
}

/* Paragraphs and text */
p, div, span, li {
    color: #1F2937 !important;
}

/* Fix all gray text to be darker */
[class*="text-gray"],
[style*="color: rgb(156"],
[style*="color: rgb(209"],
[style*="color: rgb(229"] {
    color: #374151 !important;
}

/* Navigation */
.nav-links a,
nav a {
    color: #1F2937 !important;
    font-weight: 600 !important;
}

.nav-links a:hover {
    color: #4F46E5 !important;
}

/* Module cards */
.module-card {
    background: #FFFFFF !important;
    border: 2px solid #1F2937 !important;
}

.module-card h3 {
    color: #000000 !important;
}

.module-card p {
    color: #374151 !important;
}

.module-card .level,
.module-card .xp {
    background: #F3F4F6 !important;
    color: #1F2937 !important;
    border: 1px solid #9CA3AF !important;
}

/* Buttons */
.btn, button {
    font-weight: 600 !important;
}

.btn-primary {
    background-color: #1D4ED8 !important;
    color: #FFFFFF !important;
}

.btn-secondary {
    background-color: #374151 !important;
    color: #FFFFFF !important;
}

/* Links */
a:not(.btn):not(.nav-links a) {
    color: #1D4ED8 !important;
    text-decoration: underline !important;
}

/* Forms */
input, textarea, select {
    color: #000000 !important;
    background: #FFFFFF !important;
    border: 2px solid #374151 !important;
}

::placeholder {
    color: #6B7280 !important;
    opacity: 1 !important;
}

/* Hero sections with gradients */
.hero {
    background: #1F2937 !important;
}

.hero * {
    color: #FFFFFF !important;
}

/* Small text */
small, .text-sm, .text-xs {
    font-size: 14px !important;
    color: #374151 !important;
}

/* Focus states */
:focus {
    outline: 3px solid #1D4ED8 !important;
    outline-offset: 2px !important;
}

/* Stats */
.stat-value {
    color: #000000 !important;
    font-weight: 700 !important;
}

.stat-label {
    color: #374151 !important;
}

/* Cards */
.card {
    background: #FFFFFF !important;
    border: 1px solid #374151 !important;
}

/* Dashboard specific */
.dashboard-container {
    background: #FFFFFF !important;
}

/* Remove all text shadows */
* {
    text-shadow: none !important;
}

/* Ensure minimum font sizes */
* {
    font-size: max(1em, 14px) !important;
}