/* Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    display: block;
    max-width: 100%;
}

/* Scroll Reveal */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

/* Navbar transitions */
.nav-text {
    transition: color 0.4s ease;
}

.nav-accent {
    transition: fill 0.4s ease;
}

.nav-btn span {
    transition: all 0.3s ease;
}

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

.mobile-link {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

/* Hero parallax-like subtle effect */
#hero {
    will-change: scroll-position;
}

/* Selection color */
::selection {
    background-color: #c9411e;
    color: #FDF8F0;
}

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

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

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

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

/* Focus styles */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #c9411e;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Loading state for images */
img {
    background-color: #faf0cc;
}
