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

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

body {
    margin: 0;
    overflow-x: hidden;
}

::selection {
    background: #A8D5C8;
    color: #0A1628;
}

img {
    display: block;
    max-width: 100%;
}

/* ── Scroll Reveal ── */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal.revealed {
    opacity: 1;
    transform: none;
}

/* ── Hero Animations ── */
.hero-anim {
    opacity: 1;
    transform: translateY(0);
    animation: heroFadeIn 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.hero-anim:nth-child(2) { animation-delay: 0.15s; }
.hero-anim:nth-child(3) { animation-delay: 0.3s; }
.hero-anim:nth-child(4) { animation-delay: 0.45s; }

@keyframes heroFadeIn {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-img-anim {
    opacity: 1;
    animation: heroImgIn 1.1s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.2s forwards;
    opacity: 0;
}

@keyframes heroImgIn {
    from {
        opacity: 0;
        transform: scale(0.97);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ── Navbar ── */
.nav-scrolled {
    background: rgba(10, 22, 40, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(168, 213, 200, 0.08);
}

.nav-scrolled #navbar {
    border-bottom: 1px solid rgba(168, 213, 200, 0.06);
}

/* ── Mobile Menu ── */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: all !important;
}

/* ── Reduced Motion ── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html {
        scroll-behavior: auto;
    }
    .reveal {
        opacity: 1;
        transform: none;
    }
    .hero-anim {
        opacity: 1;
        transform: none;
        animation: none;
    }
    .hero-img-anim {
        opacity: 1;
        animation: none;
    }
}

/* ── Focus Styles ── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #A8D5C8;
    outline-offset: 2px;
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0A1628;
}
::-webkit-scrollbar-thumb {
    background: #2D3D66;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #4D679A;
}
