/* ===== BASE & RESET ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(94, 234, 212, 0.3);
    color: #f0f3fa;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0f172a;
}
::-webkit-scrollbar-thumb {
    background: #1e2748;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #2f3d6b;
}

/* ===== NAVBAR ===== */
#navbar {
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
}

#navbar.scrolled {
    background: rgba(8, 14, 26, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(94, 234, 212, 0.08);
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.3);
}

.nav-link {
    position: relative;
}

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

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

/* ===== MOBILE MENU ===== */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

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

#bar1.open {
    transform: translateY(5px) rotate(45deg);
}

#bar2.open {
    opacity: 0;
    transform: scaleX(0);
}

#bar3.open {
    transform: translateY(-5px) rotate(-45deg);
    width: 1.5rem;
}

/* ===== REVEAL ANIMATIONS ===== */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 0;
        transform: translateY(40px);
    }
    
    .reveal-left {
        transform: translateX(-40px);
    }
    
    .reveal-right {
        transform: translateX(40px);
    }
    
    .reveal-up.revealed,
    .reveal-left.revealed,
    .reveal-right.revealed {
        opacity: 1;
        transform: none;
    }
}

/* ===== DELAYS ===== */
.delay-75  { transition-delay: 75ms;  }
.delay-100 { transition-delay: 100ms; }
.delay-150 { transition-delay: 150ms; }
.delay-200 { transition-delay: 200ms; }

/* ===== BUTTONS ===== */
a, button {
    -webkit-tap-highlight-color: transparent;
}

/* ===== FORM STYLES ===== */
select option {
    background: #0f172a;
    color: #f0f3fa;
}

/* ===== FOCUS VISIBLE ===== */
:focus-visible {
    outline: 2px solid rgba(94, 234, 212, 0.6);
    outline-offset: 2px;
}

/* ===== RESPONSIVE TWEAKS ===== */
@media (max-width: 767px) {
    .font-serif {
        word-break: break-word;
    }
}

/* ===== PRINT ===== */
@media print {
    #navbar, #mobileMenu { display: none !important; }
    body { background: white; color: black; }
}
