/* Custom styles beyond Tailwind */

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

/* Custom selection color */
::selection {
    background-color: #7e22ce;
    color: white;
}

/* Stat cards animation */
.stat-card {
    animation: float 6s ease-in-out infinite;
}

.stat-card:nth-child(2) {
    animation-delay: -1.5s;
}

.stat-card:nth-child(3) {
    animation-delay: -3s;
}

.stat-card:nth-child(4) {
    animation-delay: -4.5s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

/* Service card hover image effect */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #7e22ce, #fbbf24);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.service-card:hover::after {
    transform: scaleX(1);
}

/* Testimonial card hover */
.testimonial-card {
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 80px;
    font-family: Georgia, serif;
    color: #f3e8ff;
    line-height: 1;
    z-index: 0;
    pointer-events: none;
}

.testimonial-card:hover {
    transform: translateY(-4px);
}

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(59, 7, 100, 0.95) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Mobile menu transition */
#mobile-menu {
    animation: slideDown 0.3s ease;
}

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

/* Scroll reveal animations (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.6s ease, transform 0.6s ease;
    }

    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }

    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
}

/* Back to top button */
#back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

/* Focus visible for accessibility */
*:focus-visible {
    outline: 2px solid #7e22ce;
    outline-offset: 2px;
}

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

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

::-webkit-scrollbar-thumb {
    background: #7e22ce;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #6b21a8;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .stat-card {
        animation: none;
    }
}
