/* Base styles and resets */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

/* Scroll reveal animations - progressive enhancement */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Floating card animations */
@media (prefers-reduced-motion: no-preference) {
    .floating-card-1 {
        animation: float1 4s ease-in-out infinite;
    }
    
    .floating-card-2 {
        animation: float2 5s ease-in-out infinite;
    }
    
    .floating-card-3 {
        animation: float3 3.5s ease-in-out infinite;
    }
}

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

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

@keyframes float3 {
    0%, 100% { transform: translateY(0px) translateX(-32px); }
    50% { transform: translateY(-6px) translateX(-32px); }
}

/* Navbar scroll state */
.navbar-scrolled {
    background: rgba(254, 253, 251, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08) !important;
}

.navbar-transparent {
    background: transparent !important;
    box-shadow: none !important;
}

/* Mobile menu transitions */
#mobileMenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
}

#mobileMenu.open {
    max-height: 400px;
    opacity: 1;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #a85a3f;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #c2704e;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Selection color */
::selection {
    background: #f9ddd3;
    color: #8a4833;
}

/* Prevent layout shift on images */
img {
    max-width: 100%;
    height: auto;
}

/* Ensure hero is visible immediately */
#hero {
    opacity: 1;
}

/* Smooth transitions for all interactive elements */
a, button {
    transition: all 0.3s ease;
}

/* Form focus states */
input:focus,
textarea:focus {
    border-color: #c2704e !important;
    box-shadow: 0 0 0 3px rgba(194, 112, 78, 0.15) !important;
}
