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

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Scroll Reveal Animations — progressive enhancement, works without JS */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

    /* Hero animations */
    .hero-anim {
        opacity: 0;
        transform: translateY(20px);
        animation: heroFadeIn 0.8s ease forwards;
    }

    .hero-anim:nth-child(1) { animation-delay: 0.1s; }
    .hero-anim:nth-child(2) { animation-delay: 0.25s; }
    .hero-anim:nth-child(3) { animation-delay: 0.4s; }
    .hero-anim:nth-child(4) { animation-delay: 0.55s; }

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

    .hero-image {
        opacity: 0;
        transform: translateX(30px);
        animation: heroImageSlide 1s ease 0.3s forwards;
    }

    @keyframes heroImageSlide {
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }

    .hero-scroll {
        opacity: 0;
        animation: heroFadeIn 0.8s ease 1s forwards;
    }
}

/* Navbar */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: currentColor;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Mobile menu transitions */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Subtle image hover effects */
.group:hover img {
    filter: brightness(1.02);
}

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

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

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

::-webkit-scrollbar-thumb {
    background: #d9e0ef;
    border-radius: 3px;
}

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

/* Selection color */
::selection {
    background: rgba(200, 169, 97, 0.2);
    color: #0d1423;
}
