/* Custom styles for Big D Tires */

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

/* Navbar scroll state */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(250, 248, 244, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06);
}

/* Hero text animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#hero > .relative > .max-w-7xl > .grid > div:first-child > * {
    animation: fadeInUp 0.8s ease forwards;
}

#hero > .relative > .max-w-7xl > .grid > div:first-child > *:nth-child(2) {
    animation-delay: 0.1s;
}

#hero > .relative > .max-w-7xl > .grid > div:first-child > *:nth-child(3) {
    animation-delay: 0.2s;
}

#hero > .relative > .max-w-7xl > .grid > div:first-child > *:nth-child(4) {
    animation-delay: 0.3s;
}

#hero > .relative > .max-w-7xl > .grid > div:first-child > *:nth-child(5) {
    animation-delay: 0.4s;
}

/* Service card stagger animation */
.service-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.service-card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Intersection Observer animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

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

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

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

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

/* Selection color */
::selection {
    background-color: #f6c4b0;
    color: #6e2517;
}

/* Mobile menu transition */
#mobile-menu {
    animation: slideDown 0.3s ease forwards;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Button press effect */
button, a {
    -webkit-tap-highlight-color: transparent;
}

button:active, a:active {
    transform: scale(0.98);
}

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

/* Remove outline for mouse users */
:focus:not(:focus-visible) {
    outline: none;
}
