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

body {
    overflow-x: hidden;
}

/* Scroll Reveal Animations */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Default state for reduced motion - all visible */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* Stagger children */
.scroll-reveal:nth-child(1) { transition-delay: 0ms; }
.scroll-reveal:nth-child(2) { transition-delay: 100ms; }
.scroll-reveal:nth-child(3) { transition-delay: 200ms; }
.scroll-reveal:nth-child(4) { transition-delay: 300ms; }
.scroll-reveal:nth-child(5) { transition-delay: 400ms; }
.scroll-reveal:nth-child(6) { transition-delay: 500ms; }

/* Default hidden state for JS-enhanced reveal */
.scroll-reveal[data-reveal="true"] {
    opacity: 0;
    transform: translateY(30px);
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal[data-reveal="true"] {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal.revealed[data-reveal="true"] {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar glass effect */
.navbar-scrolled {
    background: rgba(253, 251, 247, 0.92) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(196, 112, 75, 0.08), 0 4px 20px rgba(0, 0, 0, 0.04);
}

.navbar-transparent {
    background: transparent !important;
    box-shadow: none !important;
}

/* Mobile menu transitions */
#mobile-menu {
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

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

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

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

/* Selection color */
::selection {
    background: #F5B49A;
    color: #5E3322;
}
