/* Cox Fencing — Custom Styles */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fef7f5;
}
::-webkit-scrollbar-thumb {
    background: #e87070;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c43b3b;
}

/* Navbar scroll state */
nav.scrolled {
    background: rgba(254, 247, 245, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 20px rgba(138, 37, 37, 0.08);
}

nav.scrolled .font-display {
    color: #5a1818 !important;
}

/* Mobile menu transitions */
#mobileMenu.open {
    opacity: 1 !important;
    pointer-events: all !important;
}

#mobileMenu.closed {
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Service card stagger animation */
.service-card {
    opacity: 0;
    transform: translateY(30px);
}

@media (prefers-reduced-motion: no-preference) {
    .service-card.revealed {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.6s ease, transform 0.6s ease;
    }
}

@media (prefers-reduced-motion: reduce) {
    .service-card {
        opacity: 1;
        transform: none;
    }
}

/* Gallery hover */
@media (prefers-reduced-motion: no-preference) {
    .rounded-2xl img,
    .rounded-3xl img {
        transition: transform 0.7s ease;
    }
}

@media (prefers-reduced-motion: reduce) {
    .rounded-2xl img,
    .rounded-3xl img {
        transition: none;
    }
}

/* Selection color */
::selection {
    background: #f9d0d0;
    color: #5a1818;
}

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

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