/* Base styles and custom utilities */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Scroll reveal animations - progressive enhancement, hidden by default via JS */
.scroll-reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Navbar scroll state */
nav.scrolled {
    background: rgba(3, 8, 20, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

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

/* Mobile menu transitions */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobile-menu.open {
    max-height: 500px;
}

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

::-webkit-scrollbar-track {
    background: #060d1f;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #4ade80;
}

/* Selection color */
::selection {
    background: rgba(52, 211, 153, 0.3);
    color: #060d1f;
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .scroll-reveal.revealed {
        opacity: 1;
        transform: none;
    }
    * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

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

/* Image aspect ratio utilities */
.aspect-card {
    aspect-ratio: 4/3;
}

/* Print styles */
@media print {
    nav, #mobile-menu-btn, .scroll-reveal {
        display: none !important;
    }
    body {
        color: #000;
        background: #fff;
    }
}
