/* ── Base & Utilities ── */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: #FF6B6B;
    color: white;
}

/* ── Floating Card Animation ── */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
    animation-duration: 7s;
}

.floating-card:nth-child(3) {
    animation-delay: -4s;
    animation-duration: 5s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

/* ── Navbar Scroll State ── */
#navbar {
    background: transparent;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

/* ── Scroll Reveal ── */
.reveal {
    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);
}

.reveal.visible {
    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; }

/* ── Mobile Menu ── */
#mobileMenu {
    animation: slideDown 0.3s ease;
}

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

.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.mobile-link:last-child {
    border-bottom: none;
}

/* ── Form Focus Styles ── */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* ── Smooth Image Loading ── */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* ── Custom Scrollbar ── */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f5f5f4;
}

::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* ── Responsive Adjustments ── */
@media (max-width: 640px) {
    .floating-card {
        display: none;
    }

    #hero {
        min-height: auto;
        padding-top: 8rem;
        padding-bottom: 4rem;
    }
}

@media (min-width: 641px) and (max-width: 1023px) {
    .floating-card:nth-child(1) {
        top: 4px;
        left: -8px;
    }

    .floating-card:nth-child(2) {
        bottom: 80px;
        left: 8px;
    }

    .floating-card:nth-child(3) {
        bottom: 16px;
        right: 8px;
    }
}
