/**
 * Comprehensive Accessibility Contrast Fixes
 * WCAG AA compliant contrast ratios
 */

/* Navigation links - ensure proper contrast */
.nav-link,
a[href*="/events"],
a[href*="/kategorien"],
a[href*="/staedte"],
a[href*="/blog"],
a[href*="/impressum"] {
    color: #004085 !important; /* Dark blue for better contrast */
    font-weight: 500 !important;
}

.nav-link:hover {
    color: #002752 !important;
    text-decoration: underline !important;
}

/* Fix button contrast */
.btn-auth,
button[onclick*="openAuthModal"] {
    background-color: #004085 !important;
    color: #ffffff !important;
    border: 2px solid #004085 !important;
    font-weight: 600 !important;
}

.btn-auth:hover,
button[onclick*="openAuthModal"]:hover {
    background-color: #002752 !important;
    border-color: #002752 !important;
}

/* Fix author section */
h3:contains("Über den Autor"),
h3 {
    color: #212529 !important;
    font-weight: 600 !important;
}

div[style*="background: #f8f9fa"] {
    background: #ffffff !important;
    border: 1px solid #dee2e6 !important;
    color: #212529 !important;
}

div[style*="background: #f8f9fa"] p {
    color: #212529 !important;
}

/* Fix loading text */
.section-placeholder p,
p[style*="text-align:center;padding:20px"] {
    color: #495057 !important;
    font-weight: 500 !important;
}

.section-placeholder {
    background-color: #f8f9fa !important;
}

/* Fix light gray links */
a[style*="color: rgb(204, 204, 204)"] {
    color: #004085 !important;
}

/* Cookie banner contrast */
#cookie-consent-banner {
    background-color: #ffffff !important;
    color: #212529 !important;
    border-top: 3px solid #004085 !important;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.15) !important;
}

#cookie-consent-banner a {
    color: #004085 !important;
    text-decoration: underline !important;
    font-weight: 500 !important;
}

#cookie-consent-banner button {
    background-color: #004085 !important;
    color: #ffffff !important;
    font-weight: 600 !important;
    border: none !important;
}

/* Dark mode specific contrast fixes */
body.dark-mode {
    background-color: #121212 !important;
    color: #e0e0e0 !important;
}

body.dark-mode .section-placeholder {
    background-color: #1e1e1e !important;
}

body.dark-mode .section-placeholder p {
    color: #b0b0b0 !important;
}

body.dark-mode a {
    color: #69b7ff !important;
}

body.dark-mode .nav-link {
    color: #69b7ff !important;
}

body.dark-mode button {
    background-color: #1976d2 !important;
    color: #ffffff !important;
}

body.dark-mode #cookie-consent-banner {
    background-color: #1e1e1e !important;
    color: #e0e0e0 !important;
    border-top-color: #1976d2 !important;
}

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

p, div, span, a, button {
    font-size: max(1em, 16px) !important;
}

/* High contrast for form elements */
input, select, textarea {
    border: 2px solid #495057 !important;
    color: #212529 !important;
    background-color: #ffffff !important;
    font-size: 16px !important;
}

input:focus, select:focus, textarea:focus {
    border-color: #004085 !important;
    outline: 3px solid #69b7ff !important;
    outline-offset: 2px !important;
}