/* Custom CSS Variables */
:root {
    --primary: #007BFF;
    --secondary: #20C997;
    --accent: #28A745;
    --neutral-50: #F8F9FA;
    --neutral-900: #212529;
}

/* Custom Utilities */
.hero-overlay {
    background: linear-gradient(135deg, rgba(0, 123, 255, 0.8) 0%, rgba(0, 86, 179, 0.6) 100%);
}

/* Card Shadows and Transitions */
.card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Custom Animations */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.animate-slide-in {
    animation: slideInUp 0.6s ease-out forwards;
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus States for Accessibility */
.focus-ring:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Custom Button Styles */
.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #0056b3 100%);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 123, 255, 0.3);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary) 0%, #17a085 100%);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #17a085 0%, #138f75 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(32, 201, 151, 0.3);
}

/* Hero Background Overlay */
.hero-bg-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 123, 255, 0.85) 0%, rgba(0, 86, 179, 0.65) 100%);
    z-index: 1;
}

/* Form Enhancements */
.form-input {
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
}

.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
    transform: translateY(-1px);
}

.form-input:invalid {
    border-color: #ef4444;
}

.form-input:valid {
    border-color: var(--accent);
}

/* Loading States */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Mobile Menu Animation */
.mobile-menu-enter {
    animation: slideDown 0.3s ease-out forwards;
}

.mobile-menu-exit {
    animation: slideUp 0.3s ease-out forwards;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* Testimonial Cards */
.testimonial-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid rgba(0, 123, 255, 0.1);
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    border-color: rgba(0, 123, 255, 0.3);
    box-shadow: 0 10px 25px rgba(0, 123, 255, 0.1);
}

/* Stats Counter Animation */
.stat-number {
    font-variant-numeric: tabular-nums;
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .card-hover {
        border: 2px solid currentColor;
    }
    
    .btn-primary,
    .btn-secondary {
        border: 2px solid currentColor;
    }
}

/* Print Styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .bg-primary,
    .bg-secondary,
    .bg-accent {
        background: white !important;
        color: black !important;
        border: 1px solid black !important;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0056b3;
}

/* Modal Animations */
.modal-enter {
    animation: modalFadeIn 0.3s ease-out forwards;
}

.modal-exit {
    animation: modalFadeOut 0.3s ease-out forwards;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes modalFadeOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.9);
    }
}

/* Error States */
.error-message {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.success-message {
    color: var(--accent);
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Responsive Image Enhancements */
.responsive-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.responsive-image:hover {
    transform: scale(1.05);
}

/* Skip Link for Accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}
