/* =============================================
   A.S.A Small Engine and Bicycle Repair
   Custom Styles
   ============================================= */

/* Base Reset & Smooth Scrolling */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

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

::-webkit-scrollbar-track {
    background: #1c1917;
}

::-webkit-scrollbar-thumb {
    background: #d07047;
    border-radius: 6px;
}

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

/* Selection Color */
::selection {
    background: #d07047;
    color: #faf7f2;
}

/* =============================================
   Animations
   ============================================= */

/* Float Animation for Decorative Elements */
@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

@keyframes float-delayed {
    0%, 100% {
        transform: translateY(0px) rotate(12deg);
    }
    50% {
        transform: translateY(-15px) rotate(17deg);
    }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-delayed 5s ease-in-out infinite;
    animation-delay: 1s;
}

/* Marquee Animation */
@keyframes marquee {
    0% {
        transform: translateX(0%);
    }
    100% {
        transform: translateX(-50%);
    }
}

.animate-marquee {
    animation: marquee 30s linear infinite;
}

/* Scroll Reveal Animations (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    }
    
    .reveal.revealed {
        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;
    }
    
    .reveal-delay-5 {
        transition-delay: 0.5s;
    }
}

/* Fallback: ensure content is visible even without JS */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* =============================================
   Navigation
   ============================================= */

/* Active nav link highlighting */
.nav-link.active {
    color: #d07047;
}

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

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

/* =============================================
   Service Cards
   ============================================= */

.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #d07047, #facc15);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease-out;
}

.service-card:hover::before {
    transform: scaleX(1);
}

/* =============================================
   Testimonial Cards
   ============================================= */

.testimonial-card {
    position: relative;
}

.testimonial-card::after {
    content: '"';
    position: absolute;
    top: -10px;
    right: 20px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 8rem;
    color: #f9ece4;
    line-height: 1;
    pointer-events: none;
    z-index: 0;
}

/* =============================================
   Form Styles
   ============================================= */

input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(208, 112, 71, 0.2);
}

/* =============================================
   Back to Top Button
   ============================================= */

#back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

/* =============================================
   Responsive Adjustments
   ============================================= */

@media (max-width: 768px) {
    .testimonial-card::after {
        font-size: 5rem;
        top: 5px;
        right: 10px;
    }
}

/* =============================================
   Print Styles
   ============================================= */

@media print {
    nav,
    #back-to-top,
    .animate-marquee,
    .animate-float,
    .animate-float-delayed {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .bg-charcoal,
    .bg-terracotta-500 {
        background: #f0f0f0 !important;
    }
    
    .text-cream,
    .text-charcoal {
        color: black !important;
    }
}
