/* ===== CUSTOM STYLES ===== */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Scroll reveal base — content is visible by default */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Only animate when JS is active and user prefers motion */
.js-active .reveal {
    opacity: 0;
    transform: translateY(30px);
}

.js-active .reveal.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays */
.js-active .reveal:nth-child(1) { transition-delay: 0ms; }
.js-active .reveal:nth-child(2) { transition-delay: 80ms; }
.js-active .reveal:nth-child(3) { transition-delay: 160ms; }
.js-active .reveal:nth-child(4) { transition-delay: 240ms; }
.js-active .reveal:nth-child(5) { transition-delay: 320ms; }
.js-active .reveal:nth-child(6) { transition-delay: 400ms; }

/* Navbar states */
#navbar.scrolled {
    background: rgba(254, 252, 251, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(123, 45, 59, 0.08), 0 4px 20px rgba(123, 45, 59, 0.06);
}

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

/* Hamburger animation */
#menu-toggle.active #bar1 {
    transform: rotate(45deg) translate(4px, 4px);
}
#menu-toggle.active #bar2 {
    opacity: 0;
}
#menu-toggle.active #bar3 {
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Selection color */
::selection {
    background: rgba(123, 45, 59, 0.15);
    color: #4a1721;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none !important; transition: none !important; }
    .reveal * { transition: none !important; }
    .group img { transition: none !important; }
    .group:hover img { transform: none !important; }
}

/* Smooth image loading */
img {
    background-color: rgba(123, 45, 59, 0.05);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fdf8f9;
}
::-webkit-scrollbar-thumb {
    background: #e89aad;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c45568;
}
