/* Custom styles for The Tire Tree */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0f172a;
}
::-webkit-scrollbar-thumb {
    background: #14b8a6;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #0d9488;
}

/* Selection color */
::selection {
    background: rgba(20, 184, 166, 0.3);
    color: #f0fdfa;
}

/* Animation keyframes */
@keyframes spin-slow {
    from { transform: rotate(45deg); }
    to { transform: rotate(405deg); }
}

.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}

/* Navbar transition */
#navbar.scrolled {
    background: rgba(2, 6, 23, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(20, 184, 166, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #14b8a6, #0d9488);
    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: all 0.3s ease;
}

#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; }

/* Hamburger animation */
.menu-line {
    transition: all 0.3s ease;
}

#mobileMenuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
#mobileMenuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}
#mobileMenuBtn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.25rem;
}

/* Intersection Observer animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Hero parallax */
#hero {
    perspective: 1000px;
}

/* Button hover glow */
button:hover, a:hover {
    cursor: pointer;
}

/* Focus styles for accessibility */
input:focus, select:focus, textarea:focus {
    outline: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .service-card {
        padding: 2rem;
    }
}
