/* Custom styles for Keith's Tire Service */

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

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

/* Reveal animations (progressive enhancement - hidden by default, shown via JS) */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Service card hover effect */
.service-card {
    transform: translateY(0);
}

@media (prefers-reduced-motion: no-preference) {
    .service-card:hover {
        transform: translateY(-4px);
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f5f0e8;
}
::-webkit-scrollbar-thumb {
    background: #b9d0bc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #8ab58e;
}

/* Navbar scroll state */
.navbar-scrolled {
    box-shadow: 0 1px 20px rgba(8, 23, 10, 0.06);
}

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

#mobile-menu.open {
    max-height: 500px;
    padding-top: 0;
}

/* Menu button animation */
.menu-line {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-btn.active .menu-line:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}
.menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}
.menu-btn.active .menu-line:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(92, 148, 96, 0.15);
}

/* Print styles */
@media print {
    header, footer, #contact-form, #form-success {
        display: none !important;
    }
    body {
        color: #0f2913;
        background: white;
    }
}
