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

body {
    overflow-x: hidden;
}

/* Custom selection color */
::selection {
    background-color: #D4A843;
    color: #1B2A4A;
}

/* Navbar transitions */
.nav-link-text {
    color: #1B2A4A;
}

.nav-link-text-muted {
    color: #a37520;
}

/* Navbar scroll state */
.navbar-scrolled .nav-link-text {
    color: #1B2A4A;
}

/* Mobile menu animations */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

.mobile-menu-open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu-open .mobile-link:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu-open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu-open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu-open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
.mobile-menu-open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* Hamburger animation */
.menu-line {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-btn.active .menu-line:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
    width: 1.5rem;
}

/* Scroll reveal animations */
.section-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .section-reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }

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

/* Hero entrance - always visible, no JS needed */
#hero h1,
#hero p,
#hero a,
#hero .inline-flex {
    animation: heroFadeIn 0.8s ease forwards;
}

#hero h1 { animation-delay: 0.1s; opacity: 0; }
#hero p { animation-delay: 0.25s; opacity: 0; }
#hero a { animation-delay: 0.4s; opacity: 0; }
#hero .inline-flex { animation-delay: 0.05s; opacity: 0; }

@keyframes heroFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Smooth image loading */
img {
    background-color: #f0f3f9;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #2d4d94;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #D4A843;
    outline-offset: 2px;
}

/* Mobile menu overlay */
.mobile-menu {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}
