/* Base styles and custom properties */
:root {
    --burgundy-50: #fdf2f4;
    --burgundy-100: #fce7eb;
    --burgundy-200: #fad0d9;
    --burgundy-300: #f6a5b7;
    --burgundy-400: #ed688b;
    --burgundy-500: #dc3d5e;
    --burgundy-600: #be1f3d;
    --burgundy-700: #9f1430;
    --burgundy-800: #83132d;
    --burgundy-900: #6e132e;
    --burgundy-950: #3d0711;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FDF8F5;
}
::-webkit-scrollbar-thumb {
    background: #be1f3d;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #9f1430;
}

/* Selection color */
::selection {
    background: #fce7eb;
    color: #6e132e;
}

/* Hero animations - only for content below fold or after initial paint */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Apply hero animations only after first paint - progressive enhancement */
.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

/* Service card hover effects */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #be1f3d, #dc3d5e);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

/* Mobile menu animations */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* Mobile menu open state */
#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }

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

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

/* Focus visible styles */
:focus-visible {
    outline: 2px solid #be1f3d;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    header, footer, #backToTop, .service-card::before {
        display: none !important;
    }
    body {
        color: #000 !important;
        background: #fff !important;
    }
    .bg-burgundy-900, .bg-burgundy-950 {
        background: #fff !important;
        color: #000 !important;
    }
}
