/* ── Custom overrides & extras ── */

html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── Scroll animations ── */
.scroll-animate {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.scroll-animate.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Navbar scrolled state ── */
#navbar.scrolled {
    background: rgba(250, 245, 249, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(107, 58, 110, 0.08);
}

/* ── Custom select arrow ── */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236B3A6E' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* ── Smooth focus outlines ── */
input:focus, textarea:focus, select:focus {
    outline: none;
}

/* ── Selection color ── */
::selection {
    background: rgba(245, 197, 99, 0.35);
    color: #3d1d40;
}

/* ── Mobile menu animation ── */
#mobile-menu {
    animation: slideDown 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* ── Back to top button animation ── */
#back-to-top.is-visible {
    opacity: 1;
    pointer-events: auto;
    translate: 0;
}

/* ── Responsive tweaks ── */
@media (max-width: 640px) {
    .scroll-animate {
        transform: translateY(20px);
    }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .scroll-animate {
        opacity: 1;
        transform: none;
        transition: none;
    }
    #back-to-top { transition: none; }
    .group:hover img { transform: none; }
}
