/* Improved Color Scheme for Better Visibility and Accessibility */

:root {
    /* Modern, accessible color palette */
    --primary-color: #2563eb;        /* Modern blue - great contrast */
    --primary-dark: #1d4ed8;         /* Darker blue for hovers */
    --primary-light: #3b82f6;        /* Lighter blue for accents */
    
    --secondary-color: #64748b;      /* Balanced gray */
    --success-color: #059669;        /* Professional green */
    --danger-color: #dc2626;         /* Clear red */
    --warning-color: #d97706;        /* Warm orange */
    --info-color: #0891b2;           /* Teal blue */
    
    --light-color: #f8fafc;          /* Very light gray */
    --dark-color: #1e293b;           /* Rich dark blue-gray */
    --text-color: #334155;           /* Readable dark gray */
    --text-muted: #64748b;           /* Muted text */
    --bg-color: #ffffff;             /* Pure white background */
    --border-color: #e2e8f0;         /* Light border */
    
    /* Gradient combinations */
    --hero-gradient: linear-gradient(135deg, #2563eb 0%, #1d4ed8 50%, #1e40af 100%);
    --card-gradient: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

/* Hero Section - Fixed visibility issues */
.hero-section {
    background: var(--hero-gradient) !important;
    color: #ffffff !important;
    position: relative;
    overflow: hidden;
}

/* Ensure all hero text is white and visible */
.hero-section h1,
.hero-section h2,
.hero-section h3,
.hero-section h4,
.hero-section h5,
.hero-section h6,
.hero-section p,
.hero-section .lead,
.hero-section .display-1,
.hero-section .display-2,
.hero-section .display-3,
.hero-section .display-4,
.hero-section .display-5,
.hero-section .display-6 {
    color: #ffffff !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Hero section buttons */
.hero-section .btn-light,
.hero-section .btn-white {
    background-color: rgba(255, 255, 255, 0.95) !important;
    color: var(--primary-color) !important;
    border: none !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease !important;
}

.hero-section .btn-light:hover,
.hero-section .btn-white:hover {
    background-color: #ffffff !important;
    color: var(--primary-dark) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15) !important;
}

.btn-white {
    background-color: #ffffff !important;
    color: var(--primary-color) !important;
    border: 1px solid rgba(37, 99, 235, 0.2) !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-white:hover {
    background-color: rgba(37, 99, 235, 0.05) !important;
    color: var(--primary-dark) !important;
    border-color: var(--primary-color) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.2) !important;
}

.hero-section .btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.8);
    color: #ffffff !important;
    background-color: transparent;
    font-weight: 600;
    transition: all 0.3s ease;
}

.hero-section .btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Improved primary button styles */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border: none;
    color: #ffffff !important;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #1e40af 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
    color: #ffffff !important;
}

.btn-primary:active,
.btn-primary:focus {
    background: var(--primary-dark);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
    color: #ffffff !important;
}

/* Improved secondary button styles */
.btn-secondary {
    background-color: var(--light-color);
    color: var(--text-color) !important;
    border: 2px solid var(--border-color);
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background-color: #f1f5f9;
    border-color: var(--secondary-color);
    color: var(--text-color) !important;
    transform: translateY(-1px);
}

/* Card improvements */
.card {
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    background: var(--bg-color);
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
    border-color: rgba(37, 99, 235, 0.2);
}

.card-header {
    background: var(--card-gradient);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color) !important;
    font-weight: 600;
    border-radius: 0.75rem 0.75rem 0 0 !important;
}

/* Navigation improvements */
.navbar-brand {
    color: var(--primary-color) !important;
    font-weight: 700;
    font-size: 1.5rem;
}

.navbar-nav .nav-link {
    color: var(--text-color) !important;
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 0.375rem;
    margin: 0 0.25rem;
    padding: 0.5rem 1rem !important;
}

.navbar-nav .nav-link:hover {
    background-color: rgba(37, 99, 235, 0.1);
    color: var(--primary-color) !important;
    transform: translateY(-1px);
}

.navbar-nav .nav-link.active {
    background-color: var(--primary-color);
    color: #ffffff !important;
}

/* Typography improvements */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-color) !important;
    font-weight: 600;
    line-height: 1.3;
}

.text-primary {
    color: var(--primary-color) !important;
}

.text-secondary {
    color: var(--secondary-color) !important;
}

.text-muted {
    color: var(--text-muted) !important;
}

/* Link improvements */
a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-dark);
    text-decoration: none;
}

/* Form improvements */
.form-control {
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.1);
    outline: none;
}

.form-label {
    color: var(--text-color) !important;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Badge improvements */
.badge {
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
}

.badge.bg-primary {
    background-color: var(--primary-color) !important;
    color: #ffffff !important;
}

.badge.bg-success {
    background-color: var(--success-color) !important;
    color: #ffffff !important;
}

/* Alert improvements */
.alert {
    border: none;
    border-radius: 0.5rem;
    font-weight: 500;
}

.alert-success {
    background-color: rgba(5, 150, 105, 0.1);
    color: var(--success-color);
    border-left: 4px solid var(--success-color);
}

.alert-danger {
    background-color: rgba(220, 38, 38, 0.1);
    color: var(--danger-color);
    border-left: 4px solid var(--danger-color);
}

.alert-warning {
    background-color: rgba(217, 119, 6, 0.1);
    color: var(--warning-color);
    border-left: 4px solid var(--warning-color);
}

.alert-primary {
    background-color: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
    border-left: 4px solid var(--primary-color);
}

/* Footer improvements */
footer {
    background-color: var(--light-color) !important;
    border-top: 1px solid var(--border-color);
}

footer h5 {
    color: var(--text-color) !important;
    font-weight: 600;
}

footer a {
    color: var(--text-muted) !important;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--primary-color) !important;
}

/* Enhanced Footer Styling */
.footer-section {
    background-color: #ffffff !important;
    border-top: 1px solid var(--border-color) !important;
}

.footer-brand h5 {
    color: var(--primary-color) !important;
    font-weight: 700 !important;
}

.footer-links .footer-link {
    color: var(--text-muted) !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    font-size: 0.95rem !important;
    display: inline-flex !important;
    align-items: center !important;
}

.footer-links .footer-link:hover {
    color: var(--primary-color) !important;
    transform: translateX(5px) !important;
}

.footer-links .footer-link i {
    color: var(--primary-color) !important;
    opacity: 0.7 !important;
    transition: opacity 0.3s ease !important;
}

.footer-links .footer-link:hover i {
    opacity: 1 !important;
}

.social-links-footer .social-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 40px !important;
    height: 40px !important;
    background-color: rgba(37, 99, 235, 0.1) !important;
    color: var(--primary-color) !important;
    border-radius: 50% !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    font-size: 1.1rem !important;
}

.social-links-footer .social-link:hover {
    background-color: var(--primary-color) !important;
    color: #ffffff !important;
    transform: translateY(-2px) scale(1.05) !important;
}

.contact-info .footer-link {
    color: var(--text-muted) !important;
    text-decoration: none !important;
    transition: color 0.3s ease !important;
}

.contact-info .footer-link:hover {
    color: var(--primary-color) !important;
}

.footer-section h6 {
    color: var(--text-color) !important;
    font-weight: 600 !important;
}

.footer-section p {
    color: var(--text-muted) !important;
}

.footer-section hr {
    border-color: var(--border-color) !important;
}

/* Social links improvements (legacy) */
.social-links a {
    width: 45px;
    height: 45px;
    line-height: 45px;
    text-align: center;
    border-radius: 50%;
    background-color: rgba(37, 99, 235, 0.1);
    color: var(--primary-color) !important;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.social-links a:hover {
    background-color: var(--primary-color);
    color: #ffffff !important;
    transform: translateY(-2px) scale(1.05);
}

/* Footer responsive */
@media (max-width: 768px) {
    .footer-section {
        text-align: center !important;
    }
    
    .footer-section .col-md-6 {
        text-align: center !important;
        margin-bottom: 1rem !important;
    }
    
    .social-links-footer {
        justify-content: center !important;
    }
}

/* Responsive improvements */
@media (max-width: 768px) {
    .hero-section {
        padding: 3rem 0 !important;
        text-align: center;
    }
    
    .hero-section .display-4 {
        font-size: 2.25rem !important;
    }
    
    .hero-section .btn {
        margin: 0.5rem 0 !important;
        width: 100%;
        max-width: 300px;
    }
}

/* Accessibility improvements */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0000ff;
        --text-color: #000000;
        --bg-color: #ffffff;
        --border-color: #000000;
    }
}

/* Dark mode preference (for future use) */
@media (prefers-color-scheme: dark) {
    /* This will be used if you decide to add dark mode support */
}

/* Print styles */
@media print {
    .hero-section,
    .btn,
    .navbar,
    footer {
        display: none !important;
    }
    
    * {
        color: #000000 !important;
        background: #ffffff !important;
    }
}