/* Custom styles for Eclair Affaire */

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

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

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

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

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

/* Selection color */
::selection {
    background: #047857;
    color: #FDF8F0;
}

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

.navbar-scrolled .nav-link {
    color: #064E3B !important;
}

/* Reveal animations */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal[data-reveal-delay="1"] {
    transition-delay: 0.1s;
}

.reveal[data-reveal-delay="2"] {
    transition-delay: 0.2s;
}

.reveal[data-reveal-delay="3"] {
    transition-delay: 0.3s;
}

.reveal[data-reveal-delay="4"] {
    transition-delay: 0.4s;
}

/* Scroll-triggered reveal (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal:not(.revealed) {
        opacity: 1;
        transform: none;
    }
}

/* Mobile menu transitions */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: auto !important;
}

.mobile-menu-close {
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Hero text shadow for readability */
.hero-text-shadow {
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

/* Button hover glow */
.btn-glow:hover {
    box-shadow: 0 0 30px rgba(16, 185, 129, 0.3) !important;
}

/* Image hover zoom */
.img-zoom {
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.img-zoom:hover {
    transform: scale(1.05);
}

/* Form focus styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

/* Decorative gradient border */
.gradient-border {
    position: relative;
}

.gradient-border::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.3), rgba(4, 120, 87, 0.1));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* Loading state for buttons */
.btn-loading {
    position: relative;
    color: transparent !important;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 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;
    }
}
