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

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

/* Scroll Reveal Animation */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    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);
}

/* Hero Animations */
.hero-anim {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-anim.animated {
    opacity: 1;
    transform: translateY(0);
}

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

/* Navbar */
.nav-logo-text {
    transition: color 0.3s ease;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: #c9a84c;
    transition: width 0.3s ease;
}

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

/* Navbar scrolled state */
.nav-scrolled .nav-logo-text {
    color: #1e3a5f;
}

.nav-scrolled .nav-link {
    color: #1e3a5f;
}

/* Mobile menu */
.mobile-link {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.2s 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; }

/* Subtle hover lift on collection cards */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* Custom selection color */
::selection {
    background: #c9a84c;
    color: #0d1f3c;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Fade-in for images */
img {
    transition: opacity 0.4s ease;
}

img[loading="lazy"] {
    opacity: 0;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .scroll-reveal,
    .hero-anim {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .group:hover .group-hover\:scale-105 {
        transform: none;
    }
}
