/* Custom styles for RJ Auto Repairs */

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

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

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

::-webkit-scrollbar-thumb {
    background: #800020;
    border-radius: 5px;
}

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

/* Ensure all text is readable */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

#mobile-menu.active {
    max-height: 500px;
}

/* Hero image hover effect */
.group:hover img {
    transform: scale(1.02);
    transition: transform 0.5s ease;
}

/* Service card hover */
.group:hover {
    transform: translateY(-4px);
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(128, 0, 32, 0.1);
}

/* Back to top button animation */
#back-to-top.visible {
    opacity: 1;
    pointer-events: all;
    transition: opacity 0.3s ease;
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Print styles */
@media print {
    nav,
    #back-to-top,
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .shadow-hard,
    .shadow-hard-hover,
    .shadow-hard-dark {
        box-shadow: 4px 4px 0px 0px currentColor !important;
    }
}

/* Touch device optimizations */
@media (hover: none) {
    .group:hover {
        transform: none;
    }
    
    button:hover,
    a:hover {
        transform: none;
    }
}
