/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #FF7F50;
    color: white;
}

/* Hero Animations */
.hero-anim {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.8s ease forwards;
}

.hero-anim:nth-child(1) { animation-delay: 0.1s; }
.hero-anim:nth-child(2) { animation-delay: 0.3s; }
.hero-anim:nth-child(3) { animation-delay: 0.5s; }
.hero-anim:nth-child(4) { animation-delay: 0.7s; }

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reveal on Scroll */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered reveals */
.reveal:nth-child(1) { transition-delay: 0.1s; }
.reveal:nth-child(2) { transition-delay: 0.2s; }
.reveal:nth-child(3) { transition-delay: 0.3s; }
.reveal:nth-child(4) { transition-delay: 0.4s; }

/* Navbar Scroll State */
nav.scrolled {
    background-color: rgba(250, 250, 250, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(54, 69, 79, 0.08);
}

/* Mobile Menu */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

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

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }

/* Menu Animation */
.menu-line {
    transform-origin: center;
}

#menu-btn.active .menu-line:first-child {
    transform: rotate(45deg) translate(3px, 3px);
}

#menu-btn.active .menu-line:last-child {
    transform: rotate(-45deg) translate(3px, -3px);
}

/* Smooth focus styles */
input:focus,
textarea:focus {
    outline: none;
}

/* Image optimization */
img {
    display: block;
    max-width: 100%;
}

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

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

::-webkit-scrollbar-thumb {
    background: #36454F;
    border-radius: 3px;
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-anim {
        animation-duration: 0.6s;
    }
}
