/* Base styles & custom overrides */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Scroll reveal — progressive enhancement */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar transition */
#navbar.scrolled {
    background: rgba(91, 33, 182, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
}

#navbar.scrolled .nav-logo-text {
    color: white;
}

#navbar.scrolled .nav-link {
    color: rgba(255, 255, 255, 0.85);
}

/* Mobile menu animation */
#mobileMenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
    opacity: 0;
}

#mobileMenu.open {
    max-height: 400px;
    opacity: 1;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #a855f7;
}

/* Form focus styles */
input:focus,
textarea:focus {
    outline: none;
}

/* Selection color */
::selection {
    background: #e9d5ff;
    color: #4c1d95;
}

/* Subtle gradient animations */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

/* Ensure images don't cause layout shift */
img {
    max-width: 100%;
    height: auto;
}
