/* ── Base ── */
*, *::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;
}

img {
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f8fafc;
}
::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* ── Navbar ── */
#navbar {
    background: transparent;
    transition: background 0.5s ease, padding 0.5s ease, box-shadow 0.5s ease;
}

#navbar.scrolled {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    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%;
}

/* ── Hero Animations ── */
.hero-subtitle {
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.3s;
}

.hero-title {
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.6s;
}

.hero-desc {
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.9s;
}

.hero-cta {
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 1.2s;
}

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

/* ── Scroll Line ── */
.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.5);
        transform-origin: top;
    }
    50% {
        opacity: 0.8;
        transform: scaleY(1);
    }
}

/* ── Reveal Animations (below fold only) ── */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    /* Stagger children */
    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
}

/* Always visible for reduced motion */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* ── Menu Items ── */
.menu-item {
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    transition: padding-left 0.3s ease;
}

.menu-item:hover {
    padding-left: 0.75rem;
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item h3 {
    transition: color 0.3s ease;
}

.menu-item:hover h3 {
    color: #0d9488;
}

/* ── Buttons ── */
.hero-btn-primary,
.hero-btn-secondary {
    position: relative;
    overflow: hidden;
}

.hero-btn-primary::before,
.hero-btn-secondary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.hero-btn-primary:hover::before,
.hero-btn-secondary:hover::before {
    opacity: 1;
}

/* ── Mobile Menu ── */
#mobile-menu {
    animation: slideDown 0.3s ease forwards;
}

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

.mobile-link {
    position: relative;
    transition: color 0.3s ease;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background: #2dd4bf;
    transition: width 0.3s ease;
}

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

/* ── Image Hover ── */
.overflow-hidden {
    position: relative;
}

.overflow-hidden::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(13, 148, 136, 0);
    transition: background 0.5s ease;
}

.overflow-hidden:hover::after {
    background: rgba(13, 148, 136, 0.05);
}

/* ── Selection ── */
::selection {
    background: #ccfbf1;
    color: #134e4a;
}

/* ── Focus ── */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #2dd4bf;
    outline-offset: 4px;
    border-radius: 2px;
}
