/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; }

/* ── Floating cards animation ── */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}
.floating-card {
    animation: float 4s ease-in-out infinite;
}
.floating-card:nth-child(2) { animation-delay: -1.3s; animation-duration: 4.5s; }
.floating-card:nth-child(3) { animation-delay: -2.6s; animation-duration: 3.8s; }

/* ── Scroll reveal (progressive enhancement — content visible by default) ── */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    .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; }
}

/* ── Service cards hover ── */
.service-card {
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease;
}
.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px -20px rgba(0,0,0,0.5);
}

/* ── Step cards hover ── */
.step-card {
    transition: transform 0.3s ease;
}
.step-card:hover {
    transform: translateY(-4px);
}

/* ── Navbar scroll state ── */
nav.scrolled {
    background: rgba(27, 3, 46, 0.92);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(147, 51, 234, 0.2);
    box-shadow: 0 4px 30px rgba(0,0,0,0.3);
}

/* ── Mobile menu transitions ── */
#mobileMenu.open {
    max-height: 400px;
}
.menu-line.active:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.menu-line.active:nth-child(2) {
    opacity: 0;
}
.menu-line.active:nth-child(3) {
    width: 1.25rem;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ── Mobile link transition ── */
.mobile-link {
    display: block;
    padding: 0.5rem 0;
    font-size: 1.1rem;
}

/* ── Custom scrollbar ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #1a0533; }
::-webkit-scrollbar-thumb { background: #7e22ce; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #9333ea; }

/* ── Selection ── */
::selection { background: rgba(245, 158, 11, 0.3); color: #faf5ff; }
