/* Enhanced Styles for Ultimate Website Experience */
/* Advanced CSS with cutting-edge visual effects */

/* CSS Custom Properties */
:root {
    --primary-gradient: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #60a5fa 100%);
    --secondary-gradient: linear-gradient(135deg, #f59e0b 0%, #f97316 50%, #ea580c 100%);
    --accent-gradient: linear-gradient(135deg, #10b981 0%, #059669 50%, #047857 100%);
    --dark-gradient: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --shadow-light: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.5s ease;
    --border-radius: 20px;
    --border-radius-large: 30px;
}

/* High Contrast Mode */
.high-contrast {
    --primary: #000000;
    --secondary: #ffffff;
    --accent: #ffff00;
    --dark: #ffffff;
    --light: #000000;
}

/* Keyboard Navigation Styles */
.keyboard-navigation *:focus {
    outline: 3px solid #f59e0b !important;
    outline-offset: 2px !important;
}

/* Advanced Animations */
@keyframes float {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg); 
    }
    25% { 
        transform: translateY(-10px) rotate(2deg); 
    }
    50% { 
        transform: translateY(-20px) rotate(0deg); 
    }
    75% { 
        transform: translateY(-10px) rotate(-2deg); 
    }
}

@keyframes pulse-glow {
    0%, 100% { 
        box-shadow: 0 0 20px rgba(245, 158, 11, 0.5); 
    }
    50% { 
        box-shadow: 0 0 40px rgba(245, 158, 11, 0.8), 0 0 60px rgba(245, 158, 11, 0.3); 
    }
}

@keyframes slide-in-left {
    from { 
        transform: translateX(-100px); 
        opacity: 0; 
    }
    to { 
        transform: translateX(0); 
        opacity: 1; 
    }
}

@keyframes slide-in-right {
    from { 
        transform: translateX(100px); 
        opacity: 0; 
    }
    to { 
        transform: translateX(0); 
        opacity: 1; 
    }
}

@keyframes scale-in {
    from { 
        transform: scale(0.5); 
        opacity: 0; 
    }
    to { 
        transform: scale(1); 
        opacity: 1; 
    }
}

@keyframes morph-shape {
    0% { 
        border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; 
    }
    25% { 
        border-radius: 47% 53% 40% 60% / 45% 45% 55% 55%; 
    }
    50% { 
        border-radius: 53% 47% 55% 45% / 49% 51% 49% 51%; 
    }
    75% { 
        border-radius: 40% 60% 47% 53% / 55% 45% 45% 55%; 
    }
    100% { 
        border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; 
    }
}

/* Enhanced Card Styles */
.enhanced-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-medium);
    transition: all var(--transition-medium) cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.enhanced-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left var(--transition-slow);
}

.enhanced-card:hover::before {
    left: 100%;
}

.enhanced-card:hover {
    transform: translateY(-15px) scale(1.03);
    box-shadow: var(--shadow-heavy);
    border-color: rgba(245, 158, 11, 0.5);
}

/* Gradient Text Effects */
.gradient-text-animated {
    background: var(--secondary-gradient);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Advanced Button Styles */
.btn-3d {
    position: relative;
    background: var(--secondary-gradient);
    border: none;
    border-radius: 50px;
    padding: 15px 30px;
    color: #333;
    font-weight: bold;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all var(--transition-medium);
    box-shadow: 0 5px 15px rgba(245, 158, 11, 0.4);
    overflow: hidden;
}

.btn-3d::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left var(--transition-slow);
}

.btn-3d:hover::before {
    left: 100%;
}

.btn-3d:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.6);
}

.btn-3d:active {
    transform: translateY(0);
    box-shadow: 0 5px 15px rgba(245, 158, 11, 0.4);
}

/* Glass Morphism Effects */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-medium);
    transition: all var(--transition-medium);
}

.glass-card:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

/* Advanced Navigation Styles */
.nav-enhanced {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    transition: all var(--transition-medium);
}

.nav-enhanced.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-medium);
}

.nav-link-enhanced {
    position: relative;
    color: #333;
    text-decoration: none;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 25px;
    transition: all var(--transition-medium);
}

.nav-link-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary-gradient);
    border-radius: 25px;
    opacity: 0;
    transform: scale(0.8);
    transition: all var(--transition-medium);
    z-index: -1;
}

.nav-link-enhanced:hover::before {
    opacity: 1;
    transform: scale(1);
}

.nav-link-enhanced:hover {
    color: #1e3a8a;
    transform: translateY(-2px);
}

/* Enhanced Table Styles */
.table-enhanced {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-medium);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.table-enhanced thead {
    background: var(--primary-gradient);
    color: white;
}

.table-enhanced th {
    padding: 20px;
    font-weight: 600;
    text-align: left;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
}

.table-enhanced td {
    padding: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: background-color var(--transition-fast);
}

.table-enhanced tbody tr:hover {
    background-color: rgba(59, 130, 246, 0.05);
    transform: scale(1.01);
    transition: all var(--transition-fast);
}

/* Advanced Chart Container */
.chart-enhanced {
    background: white;
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow-heavy);
    border: 1px solid rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.chart-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--secondary-gradient);
}

/* Floating Elements Enhancement */
.floating-enhanced {
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.1));
}

.floating-enhanced:nth-child(2) {
    animation-delay: 2s;
    animation-duration: 8s;
}

.floating-enhanced:nth-child(3) {
    animation-delay: 4s;
    animation-duration: 10s;
}

/* Advanced Statistics Cards */
.stat-card-enhanced {
    background: white;
    border-radius: var(--border-radius);
    padding: 30px;
    text-align: center;
    box-shadow: var(--shadow-medium);
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: all var(--transition-medium);
    position: relative;
    overflow: hidden;
}

.stat-card-enhanced::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--secondary-gradient);
    transform: scaleX(0);
    transition: transform var(--transition-medium);
}

.stat-card-enhanced:hover::after {
    transform: scaleX(1);
}

.stat-card-enhanced:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-heavy);
}

/* Enhanced Form Elements */
.form-enhanced {
    background: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow-medium);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.input-enhanced {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 25px;
    font-size: 16px;
    transition: all var(--transition-medium);
    background: rgba(255, 255, 255, 0.9);
}

.input-enhanced:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
}

/* Advanced Loading States */
.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .enhanced-card {
        margin: 10px;
        border-radius: 15px;
    }
    
    .btn-3d {
        padding: 12px 24px;
        font-size: 14px;
    }
    
    .table-enhanced {
        font-size: 14px;
    }
    
    .table-enhanced th,
    .table-enhanced td {
        padding: 15px 10px;
    }
}

@media (max-width: 480px) {
    .stat-card-enhanced {
        padding: 20px;
    }
    
    .chart-enhanced {
        padding: 20px;
    }
    
    .form-enhanced {
        padding: 20px;
    }
}

/* Print Styles */
@media print {
    .enhanced-card,
    .glass-card,
    .floating-enhanced {
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .btn-3d,
    .nav-link-enhanced {
        display: none;
    }
}

/* High Contrast Mode Enhancements */
.high-contrast .enhanced-card {
    background: black;
    color: white;
    border: 2px solid white;
}

.high-contrast .glass-card {
    background: black;
    border: 2px solid white;
}

.high-contrast .btn-3d {
    background: white;
    color: black;
    border: 2px solid black;
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .floating-enhanced,
    .floating-enhanced:nth-child(2),
    .floating-enhanced:nth-child(3) {
        animation: none;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --glass-bg: rgba(0, 0, 0, 0.3);
        --glass-border: rgba(255, 255, 255, 0.1);
    }
    
    .enhanced-card {
        background: rgba(30, 41, 59, 0.95);
        color: white;
        border-color: rgba(255, 255, 255, 0.1);
    }
    
    .table-enhanced {
        background: rgba(30, 41, 59, 0.95);
        color: white;
    }
    
    .table-enhanced tbody tr:hover {
        background-color: rgba(59, 130, 246, 0.1);
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: var(--secondary-gradient);
    border-radius: 10px;
    border: 2px solid #f1f1f1;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-gradient);
}

/* Focus Visible Enhancement */
*:focus-visible {
    outline: 3px solid #f59e0b;
    outline-offset: 2px;
}

/* Selection Styles */
::selection {
    background: rgba(245, 158, 11, 0.3);
    color: #1e3a8a;
}

::-moz-selection {
    background: rgba(245, 158, 11, 0.3);
    color: #1e3a8a;
}

/* High Contrast Mode - Additional Tailwind Classes */
.high-contrast .bg-white {
    background: #000000 !important;
}

.high-contrast .bg-gray-50,
.high-contrast .bg-gray-100,
.high-contrast .bg-gray-200 {
    background: #333333 !important;
}

.high-contrast .bg-gray-300,
.high-contrast .bg-gray-400 {
    background: #666666 !important;
}

.high-contrast .bg-gray-500,
.high-contrast .bg-gray-600,
.high-contrast .bg-gray-700,
.high-contrast .bg-gray-800,
.high-contrast .bg-gray-900 {
    background: #000000 !important;
}

.high-contrast .bg-blue-50,
.high-contrast .bg-blue-100,
.high-contrast .bg-blue-200 {
    background: #333333 !important;
}

.high-contrast .bg-green-50,
.high-contrast .bg-green-100,
.high-contrast .bg-green-200 {
    background: #333333 !important;
}

.high-contrast .bg-orange-50,
.high-contrast .bg-orange-100,
.high-contrast .bg-orange-200 {
    background: #333333 !important;
}

/* High Contrast Mode - Text Colors */
.high-contrast .text-white {
    color: #ffffff !important;
}

.high-contrast .text-black {
    color: #000000 !important;
}

.high-contrast .text-gray-100,
.high-contrast .text-gray-200,
.high-contrast .text-gray-300,
.high-contrast .text-gray-400 {
    color: #ffffff !important;
}

.high-contrast .text-gray-500,
.high-contrast .text-gray-600,
.high-contrast .text-gray-700,
.high-contrast .text-gray-800,
.high-contrast .text-gray-900 {
    color: #ffffff !important;
}

.high-contrast .text-blue-100,
.high-contrast .text-blue-200,
.high-contrast .text-blue-300,
.high-contrast .text-blue-400,
.high-contrast .text-blue-500,
.high-contrast .text-blue-600,
.high-contrast .text-blue-700,
.high-contrast .text-blue-800,
.high-contrast .text-blue-900 {
    color: #ffffff !important;
}

.high-contrast .text-green-100,
.high-contrast .text-green-200,
.high-contrast .text-green-300,
.high-contrast .text-green-400,
.high-contrast .text-green-500,
.high-contrast .text-green-600,
.high-contrast .text-green-700,
.high-contrast .text-green-800,
.high-contrast .text-green-900 {
    color: #ffffff !important;
}

.high-contrast .text-orange-100,
.high-contrast .text-orange-200,
.high-contrast .text-orange-300,
.high-contrast .text-orange-400,
.high-contrast .text-orange-500,
.high-contrast .text-orange-600,
.high-contrast .text-orange-700,
.high-contrast .text-orange-800,
.high-contrast .text-orange-900 {
    color: #ffffff !important;
}

/* High Contrast Mode - Borders */
.high-contrast .border-gray-100,
.high-contrast .border-gray-200,
.high-contrast .border-gray-300,
.high-contrast .border-gray-400,
.high-contrast .border-gray-500,
.high-contrast .border-gray-600,
.high-contrast .border-gray-700,
.high-contrast .border-gray-800,
.high-contrast .border-gray-900 {
    border-color: #ffffff !important;
}

.high-contrast .border-blue-100,
.high-contrast .border-blue-200,
.high-contrast .border-blue-300,
.high-contrast .border-blue-400,
.high-contrast .border-blue-500,
.high-contrast .border-blue-600,
.high-contrast .border-blue-700,
.high-contrast .border-blue-800,
.high-contrast .border-blue-900 {
    border-color: #ffffff !important;
}

/* High Contrast Mode - Shadows */
.high-contrast .shadow-sm,
.high-contrast .shadow,
.high-contrast .shadow-md,
.high-contrast .shadow-lg,
.high-contrast .shadow-xl,
.high-contrast .shadow-2xl {
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3) !important;
}

/* High Contrast Mode - Backdrop Blur */
.high-contrast .backdrop-blur-sm,
.high-contrast .backdrop-blur,
.high-contrast .backdrop-blur-md,
.high-contrast .backdrop-blur-lg,
.high-contrast .backdrop-blur-xl,
.high-contrast .backdrop-blur-2xl,
.high-contrast .backdrop-blur-3xl {
    backdrop-filter: none !important;
    background: rgba(0, 0, 0, 0.95) !important;
}

/* High Contrast Mode - Specific Component Overrides */
.high-contrast .hero-gradient {
    background: linear-gradient(135deg, #000000 0%, #333333 100%) !important;
}

.high-contrast .hero-gradient h1,
.high-contrast .hero-gradient h2,
.high-contrast .hero-gradient h3,
.high-contrast .hero-gradient p {
    color: #ffffff !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8) !important;
}

.high-contrast .hero-gradient a {
    background: #ffffff !important;
    color: #000000 !important;
    border: 3px solid #000000 !important;
}

.high-contrast .hero-gradient a:hover {
    background: #ffff00 !important;
    color: #000000 !important;
}

/* High Contrast Mode - Statistics Section */
.high-contrast .stat-counter {
    color: #ffffff !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8) !important;
}

.high-contrast .stat-label {
    color: #cccccc !important;
}

/* High Contrast Mode - Chart Container */
.high-contrast .chart-container {
    background: #000000 !important;
    border: 3px solid #ffffff !important;
}

/* High Contrast Mode - Floating Elements */
.high-contrast .floating {
    background: #000000 !important;
    border: 2px solid #ffffff !important;
    color: #ffffff !important;
}

/* High Contrast Mode - Enhanced Cards */
.high-contrast .enhanced-card,
.high-contrast .glass-card,
.high-contrast .card-hover {
    background: #000000 !important;
    color: #ffffff !important;
    border: 3px solid #ffffff !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3) !important;
}

/* High Contrast Mode - Contact Form */
.high-contrast .contact-form input,
.high-contrast .contact-form textarea,
.high-contrast .contact-form select {
    background: #000000 !important;
    color: #ffffff !important;
    border: 3px solid #ffffff !important;
}

.high-contrast .contact-form input:focus,
.high-contrast .contact-form textarea:focus,
.high-contrast .contact-form select:focus {
    border-color: #ffff00 !important;
    box-shadow: 0 0 20px rgba(255, 255, 0, 0.5) !important;
}

/* High Contrast Mode - Accessibility Improvements */
.high-contrast .sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* High Contrast Mode - Print Styles */
@media print {
    .high-contrast * {
        background: #ffffff !important;
        color: #000000 !important;
        border-color: #000000 !important;
    }
    
    .high-contrast .contrast-toggle {
        display: none !important;
    }
}

/* Base Text Colors - Ensure text is visible by default */
body {
    color: #1e293b;
}

/* Ensure specific text elements are visible by default */
.text-white {
    color: #1e293b !important;
}

.text-gray-100,
.text-gray-200,
.text-gray-300,
.text-gray-400,
.text-gray-500,
.text-gray-600,
.text-gray-700,
.text-gray-800,
.text-gray-900 {
    color: #334155 !important;
}

/* Ensure headings are visible */
h1, h2, h3, h4, h5, h6 {
    color: #0f172a;
}

.text-2xl,
.text-3xl,
.text-4xl,
.text-5xl,
.text-6xl {
    color: #0f172a !important;
}

/* Ensure paragraphs and body text are visible */
p {
    color: #334155;
}

.text-base,
.text-lg,
.text-xl {
    color: #334155 !important;
}

/* Ensure links are visible */
a {
    color: #1e3a8a;
}
