/* ═══════════════════════════════════════════════════════════ */
/*  COP 31 · Ekosfer — Custom CSS                              */
/* ═══════════════════════════════════════════════════════════ */

:root {
    --color-primary: 16 163 74;      /* emerald-600 */
    --color-primary-dark: 21 128 61; /* emerald-700 */
    --color-accent: 234 88 12;       /* orange-600 */
    --color-amber: 245 158 11;       /* amber-500 */
}

html, body {
    font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.font-display {
    font-family: 'Plus Jakarta Sans', 'Inter', ui-sans-serif, system-ui, sans-serif;
    letter-spacing: -0.015em;
}

/* ─── Scroll Animations ───────────────────────────────────── */
.scroll-animate {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}
.scroll-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ─── Header scroll state ─────────────────────────────────── */
#site-header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

/* ─── Selection ───────────────────────────────────────────── */
::selection {
    background-color: rgb(var(--color-primary) / 0.25);
    color: rgb(15 23 42);
}

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

/* ─── Smooth focus ring ───────────────────────────────────── */
a:focus-visible, button:focus-visible {
    outline: 2px solid rgb(var(--color-primary));
    outline-offset: 3px;
    border-radius: 4px;
}

/* ─── Reduced motion ──────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .scroll-animate, .scroll-animate.visible {
        opacity: 1;
        transform: none;
        transition: none;
    }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ─── Mobile menu animation ───────────────────────────────── */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
#mobile-menu.open {
    max-height: 500px;
}

/* ─── Subtle pulse for hero badge ─────────────────────────── */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}
.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
