/* Base & Typography */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', Georgia, serif;
}

/* Navbar transitions */
.nav-wave-primary {
    stroke: #a8e6cf;
    transition: stroke 0.5s ease;
}
.nav-wave-secondary {
    stroke: #a8e6cf;
    transition: stroke 0.5s ease;
}
.nav-logo-text {
    color: #f0f4f8;
    transition: color 0.5s ease;
}

/* Scrolled navbar state */
header.scrolled .nav-wave-primary,
header.scrolled .nav-wave-secondary {
    stroke: #0a2e5c;
}
header.scrolled .nav-logo-text {
    color: #0a1a28;
}
header.scrolled .menu-line {
    background: #0a1a28;
}
header.scrolled .nav-link {
    color: rgba(10, 26, 40, 0.7);
}
header.scrolled .nav-link:hover {
    color: #0a1a28;
}
header.scrolled .mobile-nav-menu-btn {
    border-color: rgba(10, 26, 40, 0.3);
}
header.scrolled .mobile-nav-menu-btn svg {
    stroke: #0a2e5c;
}

/* Scroll Reveal */
.reveal-up, .reveal-left {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-up {
    transform: translateY(0);
}
.reveal-left {
    transform: translateX(0);
}

/* Staggered delays */
.reveal-up:nth-child(2) { transition-delay: 0.1s; }
.reveal-up:nth-child(3) { transition-delay: 0.2s; }
.reveal-up:nth-child(4) { transition-delay: 0.3s; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .reveal-up, .reveal-left {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html { scroll-behavior: auto; }
    .animate-scroll { animation: none; }
    .animate-float { animation: none; }
}

/* Floating animation */
@keyframes float {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-20px) scale(1.05); }
}
.animate-float {
    animation: float 6s ease-in-out infinite;
}

/* Scroll marquee */
@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
.animate-scroll {
    display: flex;
    gap: 1rem;
    animation: scroll 40s linear infinite;
    width: max-content;
}
.animate-scroll:hover {
    animation-play-state: paused;
}

/* Mobile menu animations */
.mobile-nav-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}
#mobile-menu.open .mobile-nav-link {
    opacity: 1;
    transform: translateY(0);
}
#mobile-menu.open .mobile-nav-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-nav-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-nav-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-nav-link:nth-child(4) { transition-delay: 0.25s; }

/* Menu button */
.menu-line {
    background: #f0f4f8;
    transition: all 0.3s ease;
}
#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
}

/* Focus styles */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
    outline: 2px solid #6bbfa6;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Selection */
::selection {
    background: rgba(107, 191, 166, 0.3);
    color: #0a1a28;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f0f4f8;
}
::-webkit-scrollbar-thumb {
    background: #a8b8cc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #7c94b2;
}
