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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    overflow-x: hidden;
}

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Stagger children */
.grid > .scroll-reveal:nth-child(1) { transition-delay: 0.05s; }
.grid > .scroll-reveal:nth-child(2) { transition-delay: 0.1s; }
.grid > .scroll-reveal:nth-child(3) { transition-delay: 0.15s; }
.grid > .scroll-reveal:nth-child(4) { transition-delay: 0.2s; }
.grid > .scroll-reveal:nth-child(5) { transition-delay: 0.25s; }
.grid > .scroll-reveal:nth-child(6) { transition-delay: 0.3s; }

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

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a0f1e;
}
::-webkit-scrollbar-thumb {
    background: #1a2750;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d49a2a;
}

/* Selection */
::selection {
    background: rgba(212, 154, 42, 0.3);
    color: #f5e6b8;
}

/* Select dropdown */
select option {
    background: #111d35;
    color: #fff;
}

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