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

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

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(94, 234, 212, 0.2);
    color: #f0fdf9;
}

/* Reveal animations - progressive enhancement */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Hero reveals - always visible, no JS needed */
#hero .reveal {
    opacity: 1;
    transform: none;
}

#hero .reveal:nth-child(1) { transition-delay: 0.1s; }
#hero .reveal:nth-child(2) { transition-delay: 0.2s; }
#hero .reveal:nth-child(3) { transition-delay: 0.3s; }
#hero .reveal:nth-child(4) { transition-delay: 0.4s; }

/* Navbar */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(2, 12, 27, 0.92);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(94, 234, 212, 0.08);
}

/* Mobile menu */
.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #5eead4;
    transition: width 0.3s ease;
}

.mobile-link:hover::after {
    width: 100%;
}

/* Image hover effects */
img {
    display: block;
}

/* Subtle grain overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    z-index: 9999;
}

/* Smooth focus styles */
a:focus-visible, button:focus-visible {
    outline: 1px solid rgba(94, 234, 212, 0.5);
    outline-offset: 4px;
}

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

::-webkit-scrollbar-track {
    background: #020c1b;
}

::-webkit-scrollbar-thumb {
    background: rgba(94, 234, 212, 0.2);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(94, 234, 212, 0.4);
}

/* Line clamp utility */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
