/* ============================================
   Freeman's Tire & Wheel — Custom Styles
   Clean Minimalist | Terracotta + Sand
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    margin: 0;
    overflow-x: hidden;
}

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f5f3ef;
}
::-webkit-scrollbar-thumb {
    background: #c75b39;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a0452a;
}

/* --- Selection --- */
::selection {
    background: #c75b39;
    color: #faf9f7;
}

/* --- Hero Animations --- */
.hero-tag {
    animation: fadeUp 0.8s ease forwards;
}

.hero-heading {
    display: inline-block;
    animation: slideUp 0.9s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

.hero-heading:nth-child(1) { animation-delay: 0.1s; }
.hero-heading:nth-child(2) { animation-delay: 0.25s; }
.hero-heading:nth-child(3) { animation-delay: 0.4s; }

.hero-line {
    animation: expandWidth 0.8s ease forwards 0.6s;
    transform-origin: left;
    opacity: 0;
}

.hero-text {
    animation: fadeUp 0.8s ease forwards 0.7s;
    opacity: 0;
}

.hero-cta {
    animation: fadeUp 0.8s ease forwards 0.85s;
    opacity: 0;
}

.hero-image-main {
    animation: scaleIn 1.2s cubic-bezier(0.23, 1, 0.32, 1) forwards 0.2s;
    transform: scale(0.95);
    opacity: 0;
}

.hero-float-card {
    animation: floatIn 0.8s ease forwards 1s;
    opacity: 0;
}

.hero-secondary-img {
    animation: fadeUp 0.8s ease forwards 0.5s;
    opacity: 0;
}

/* --- Section Animations --- */
.section-tag,
.section-heading,
.section-desc {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.service-card {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.about-tag,
.about-heading,
.about-line,
.about-text,
.about-values {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.cta-tag,
.cta-heading,
.cta-desc,
.cta-buttons {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.location-tag,
.location-heading,
.location-line,
.location-info,
.location-hours {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Scroll-triggered states */
.revealed .section-tag,
.revealed .section-heading,
.revealed .section-desc {
    opacity: 1;
    transform: translateY(0);
}

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

.revealed .about-tag,
.revealed .about-heading,
.revealed .about-line,
.revealed .about-text,
.revealed .about-values {
    opacity: 1;
    transform: translateY(0);
}

.revealed .cta-tag,
.revealed .cta-heading,
.revealed .cta-desc,
.revealed .cta-buttons {
    opacity: 1;
    transform: translateY(0);
}

.revealed .location-tag,
.revealed .location-heading,
.revealed .location-line,
.revealed .location-info,
.revealed .location-hours {
    opacity: 1;
    transform: translateY(0);
}

/* --- Keyframes --- */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        transform: translateY(110%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes expandWidth {
    from {
        width: 0;
        opacity: 0;
    }
    to {
        width: 6rem;
        opacity: 1;
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes floatIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scrollIndicator {
    0% {
        top: -16px;
    }
    100% {
        top: 48px;
    }
}

.animate-scroll-indicator {
    animation: scrollIndicator 1.5s ease-in-out infinite;
}

/* --- Service Card Delays --- */
.service-card:nth-child(1) { transition-delay: 0.05s; }
.service-card:nth-child(2) { transition-delay: 0.1s; }
.service-card:nth-child(3) { transition-delay: 0.15s; }
.service-card:nth-child(4) { transition-delay: 0.2s; }
.service-card:nth-child(5) { transition-delay: 0.25s; }
.service-card:nth-child(6) { transition-delay: 0.3s; }

/* --- About Delays --- */
.about-tag { transition-delay: 0.1s; }
.about-heading { transition-delay: 0.2s; }
.about-line { transition-delay: 0.3s; }
.about-text { transition-delay: 0.4s; }
.about-values { transition-delay: 0.5s; }

/* --- CTA Delays --- */
.cta-tag { transition-delay: 0.1s; }
.cta-heading { transition-delay: 0.2s; }
.cta-desc { transition-delay: 0.3s; }
.cta-buttons { transition-delay: 0.4s; }

/* --- Location Delays --- */
.location-tag { transition-delay: 0.1s; }
.location-heading { transition-delay: 0.2s; }
.location-line { transition-delay: 0.3s; }
.location-info { transition-delay: 0.4s; }

/* --- Navbar Scroll State --- */
.navbar-scrolled {
    background: rgba(250, 249, 247, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.05);
}

.navbar-scrolled .logo-text {
    color: #2d261f;
}

/* --- Mobile Menu --- */
.mobile-link {
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.mobile-menu-open .mobile-link {
    opacity: 1;
    transform: translateX(0);
}

.mobile-menu-open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu-open .mobile-link:nth-child(2) { transition-delay: 0.2s; }
.mobile-menu-open .mobile-link:nth-child(3) { transition-delay: 0.3s; }

/* --- Hamburger Animation --- */
#mobile-menu-btn.active #line1 {
    transform: rotate(45deg) translate(4px, 4px);
}

#mobile-menu-btn.active #line2 {
    opacity: 0;
}

#mobile-menu-btn.active #line3 {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.5rem;
}

/* --- Select Dropdown Styling --- */
select option {
    background: #faf9f7;
    color: #2d261f;
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .service-card,
    .section-tag,
    .section-heading,
    .section-desc,
    .about-tag,
    .about-heading,
    .about-line,
    .about-text,
    .about-values,
    .cta-tag,
    .cta-heading,
    .cta-desc,
    .cta-buttons,
    .location-tag,
    .location-heading,
    .location-line,
    .location-info,
    .location-hours {
        opacity: 1;
        transform: none;
    }
}

/* --- Responsive Adjustments --- */
@media (max-width: 767px) {
    .hero-heading {
        font-size: 2.5rem !important;
    }
    
    @media (min-width: 480px) {
        .hero-heading {
            font-size: 3rem !important;
        }
    }
    
    @media (min-width: 640px) {
        .hero-heading {
            font-size: 3.5rem !important;
        }
    }
}

@media (min-width: 768px) {
    .hero-heading {
        font-size: 3.5rem;
    }
}

@media (min-width: 1024px) {
    .hero-heading {
        font-size: 4rem;
    }
}

@media (min-width: 1280px) {
    .hero-heading {
        font-size: 4.5rem;
    }
}

@media (min-width: 1536px) {
    .hero-heading {
        font-size: 5.5rem;
    }
}
