/* === Base & Utilities === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: #F4A261;
    color: #fff;
}

/* === Scroll Reveal Animations === */
.scroll-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.scroll-reveal.revealed:nth-child(2) { transition-delay: 0.1s; }
.scroll-reveal.revealed:nth-child(3) { transition-delay: 0.2s; }
.scroll-reveal.revealed:nth-child(4) { transition-delay: 0.3s; }
.scroll-reveal.revealed:nth-child(5) { transition-delay: 0.35s; }
.scroll-reveal.revealed:nth-child(6) { transition-delay: 0.4s; }

/* === Floating Card Animations === */
.floating-card-1 {
    animation: floatCard1 4s ease-in-out infinite;
}

.floating-card-2 {
    animation: floatCard2 5s ease-in-out infinite;
}

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

@keyframes floatCard2 {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(10px); }
}

/* === Navbar Scrolled State === */
#navbar.scrolled {
    background-color: rgba(254, 253, 248, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(61, 64, 91, 0.06), 0 8px 30px rgba(61, 64, 91, 0.06);
}

/* === Mobile Menu === */
#mobileMenu {
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* === Custom Focus Styles === */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* === Subtle hover transitions on cards === */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

/* === Image aspect ratio fallbacks === */
img {
    max-width: 100%;
    height: auto;
}

/* === Smooth transitions for all interactive elements === */
a, button {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* === Selection highlight for form elements === */
input::placeholder,
textarea::placeholder {
    color: #c7c8ce;
}

/* === Accessibility: reduced motion === */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .scroll-reveal {
        opacity: 1;
        transform: none;
    }
}
