/* Enhanced Visibility and Contrast Fixes */

/* Ensure all text has proper contrast */
body {
    color: #1a1a2e !important;
}

/* Fix card header text visibility */
.card-header.bg-gradient {
    background: linear-gradient(135deg, #1e40af 0%, #5b21b6 100%) !important;
    color: #ffffff !important;
}

.card-header.bg-gradient h5,
.card-header.bg-gradient .card-title {
    color: #ffffff !important;
}

/* Fix light background text issues */
.bg-light, .bg-secondary {
    color: #1a1a2e !important;
}

.bg-light h1, .bg-light h2, .bg-light h3, .bg-light h4, .bg-light h5, .bg-light h6,
.bg-secondary h1, .bg-secondary h2, .bg-secondary h3, .bg-secondary h4, .bg-secondary h5, .bg-secondary h6 {
    color: #1a1a2e !important;
}

.bg-light p, .bg-secondary p {
    color: #374151 !important;
}

/* Improve badge contrast */
.badge.bg-warning {
    color: #1a1a2e !important;
}

.badge.bg-info {
    background-color: #0ea5e9 !important;
    color: #ffffff !important;
}

.badge.bg-secondary {
    background-color: #475569 !important;
    color: #ffffff !important;
}

/* Fix text-muted for better visibility */
.text-muted {
    color: #4b5563 !important;
}

/* Improve small text readability */
small, .small {
    color: #374151 !important;
}

/* Fix dropdown visibility */
.dropdown-menu {
    background-color: #ffffff !important;
    border: 1px solid #e5e7eb !important;
}

.dropdown-item {
    color: #1f2937 !important;
}

.dropdown-item:hover {
    background-color: #f3f4f6 !important;
    color: #1e40af !important;
}

/* Fix nav link visibility */
.nav-link {
    color: #1f2937 !important;
}

.nav-link:hover {
    color: #1e40af !important;
}

/* Improve button text visibility */
.btn-outline-primary {
    color: #1e40af !important;
    border-color: #1e40af !important;
    background-color: transparent !important;
}

.btn-outline-primary:hover {
    color: #ffffff !important;
    background-color: #1e40af !important;
}

.btn-outline-secondary {
    color: #374151 !important;
    border-color: #6b7280 !important;
}

.btn-outline-secondary:hover {
    color: #ffffff !important;
    background-color: #6b7280 !important;
}

/* Hero section text improvements */
.hero-section h1,
.hero-section .display-4,
.hero-section .display-5 {
    color: #ffffff !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-section p,
.hero-section .lead {
    color: #ffffff !important;
    opacity: 0.95;
}

/* Card text improvements */
.card-body {
    color: #1f2937 !important;
}

.card-body h5,
.card-body h4,
.card-body h3 {
    color: #111827 !important;
}

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

/* Fix footer visibility */
footer {
    background-color: #111827 !important;
}

footer p, footer span, footer a {
    color: #d1d5db !important;
}

footer a:hover {
    color: #60a5fa !important;
}

footer h5, footer h6 {
    color: #ffffff !important;
}

/* Fix course card headers */
.card .card-header {
    background: linear-gradient(135deg, #1e40af 0%, #5b21b6 100%) !important;
    color: #ffffff !important;
}

.card .card-header h5,
.card .card-header .card-title {
    color: #ffffff !important;
}

.card .card-header small {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* Improve list visibility */
li {
    color: #374151;
}

ul.list-unstyled li {
    color: #374151;
}

/* Fix breadcrumb visibility */
.breadcrumb-item a {
    color: #1e40af !important;
}

.breadcrumb-item.active {
    color: #4b5563 !important;
}

/* Course detail improvements */
.border-start.border-danger {
    border-left-width: 4px !important;
}

/* Fix progress bar visibility */
.progress {
    background-color: #e5e7eb !important;
}

/* Filter buttons improvement */
.btn-toolbar .btn-outline-primary {
    color: #1e40af !important;
    border-color: #3b82f6 !important;
}

.btn-toolbar .btn-outline-primary:hover,
.btn-toolbar .btn-outline-primary.active {
    color: #ffffff !important;
    background-color: #1e40af !important;
}

/* Improve alert visibility */
.alert-info {
    background-color: #dbeafe !important;
    border-color: #93c5fd !important;
    color: #1e40af !important;
}

.alert-warning {
    background-color: #fef3c7 !important;
    border-color: #fcd34d !important;
    color: #92400e !important;
}

.alert-success {
    background-color: #d1fae5 !important;
    border-color: #6ee7b7 !important;
    color: #065f46 !important;
}

.alert-danger {
    background-color: #fee2e2 !important;
    border-color: #fca5a5 !important;
    color: #991b1b !important;
}

/* Fix dark text on dark backgrounds */
.bg-dark {
    background-color: #1f2937 !important;
}

.bg-dark h1, .bg-dark h2, .bg-dark h3, .bg-dark h4, .bg-dark h5, .bg-dark h6,
.bg-dark p, .bg-dark span, .bg-dark a, .bg-dark li {
    color: #ffffff !important;
}

/* Primary background text */
.bg-primary {
    background-color: #1e40af !important;
}

.bg-primary h1, .bg-primary h2, .bg-primary h3, .bg-primary h4, .bg-primary h5, .bg-primary h6,
.bg-primary p, .bg-primary span {
    color: #ffffff !important;
}

/* Card pricing visibility */
.card-footer .h5,
.card-footer .text-primary {
    color: #1e40af !important;
}

/* Tab and pill navigation */
.nav-tabs .nav-link {
    color: #374151 !important;
}

.nav-tabs .nav-link.active {
    color: #1e40af !important;
    border-color: #1e40af !important;
}

.nav-pills .nav-link {
    color: #374151 !important;
}

.nav-pills .nav-link.active {
    background-color: #1e40af !important;
    color: #ffffff !important;
}

/* Form labels and inputs */
.form-label {
    color: #1f2937 !important;
}

.form-control {
    color: #1f2937 !important;
}

.form-control::placeholder {
    color: #9ca3af !important;
}

/* Ensure icon visibility */
.text-primary {
    color: #1e40af !important;
}

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

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

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

.text-info {
    color: #0284c7 !important;
}

/* CTA section improvements */
.bg-gradient.text-white {
    background: linear-gradient(135deg, #1e40af 0%, #7c3aed 100%) !important;
}

.bg-gradient.text-white h3,
.bg-gradient.text-white p {
    color: #ffffff !important;
}
