/* ========== Reset & 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: rgba(13, 148, 136, 0.3);
    color: #F8FAFC;
}

/* ========== Scrollbar ========== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0B1120;
}
::-webkit-scrollbar-thumb {
    background: #1e3a3a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #0D9488;
}

/* ========== Typography ========== */
.font-serif {
    font-family: 'Playfair Display', Georgia, serif;
}
.font-sans {
    font-family: 'Inter', system-ui, sans-serif;
}

/* ========== Section Eyebrow ========== */
.section-eyebrow {
    letter-spacing: 0.25em;
}

/* ========== Reveal Animations ========== */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-left {
    transform: translateX(-40px);
}
.reveal-right {
    transform: translateX(40px);
}
.reveal-up.revealed,
.reveal-left.revealed,
.reveal-right.revealed {
    opacity: 1;
    transform: translate(0, 0);
}

/* ========== Hero Animations ========== */
.hero-eyebrow {
    animation: fadeDown 1s 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero-headline {
    animation: fadeUp 1s 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero-sub {
    animation: fadeUp 1s 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero-cta {
    animation: fadeUp 1s 0.9s cubic-bezier(0.16, 1, 0.3, 1) both;
}

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

@keyframes fadeDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========== Floating Orbs ========== */
@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.05); }
    66% { transform: translate(-20px, 20px) scale(0.95); }
}
@keyframes float-delay {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-25px, 25px) scale(1.03); }
    66% { transform: translate(15px, -15px) scale(0.97); }
}
@keyframes float-slow {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20px, -20px); }
}
.animate-float {
    animation: float 8s ease-in-out infinite;
}
.animate-float-delay {
    animation: float-delay 10s ease-in-out infinite;
}
.animate-float-slow {
    animation: float-slow 12s ease-in-out infinite;
}

/* ========== Scroll Line ========== */
@keyframes scroll-line {
    0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
    50% { opacity: 1; transform: scaleY(1); transform-origin: top; }
    51% { transform-origin: bottom; }
    100% { opacity: 0; transform: scaleY(0); transform-origin: bottom; }
}
.animate-scroll-line {
    animation: scroll-line 2s ease-in-out infinite;
}

/* ========== Buttons ========== */
.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

/* ========== Navbar ========== */
#navbar {
    background: transparent;
}
#navbar.scrolled {
    background: rgba(11, 17, 42, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #2DD4BF;
    transition: width 0.3s ease;
}
.nav-link:hover::after {
    width: 100%;
}
.nav-link:hover {
    color: #2DD4BF !important;
}

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

/* ========== Image aspect ratios ========== */
img {
    display: block;
    max-width: 100%;
}

/* ========== Focus styles ========== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #2DD4BF;
    outline-offset: 2px;
}

/* ========== Responsive tweaks ========== */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }
}

@media (min-width: 1024px) {
    html {
        font-size: 16px;
    }
}
