/* ============================================
   A & A Auto Collision Repair — Custom Styles
   ============================================ */

/* --- Custom Properties --- */
:root {
    --color-navy-950: #0a1628;
    --color-navy-900: #0f1f3d;
    --color-navy-800: #162a52;
    --color-gold-400: #d4a84b;
    --color-gold-300: #e0bc6a;
    --color-gold-500: #b8923f;
    --font-playfair: 'Playfair Display', Georgia, serif;
    --font-inter: 'Inter', system-ui, sans-serif;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: var(--font-inter);
    background-color: var(--color-navy-950);
    color: #ffffff;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

/* --- Loader --- */
#page-loader {
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#page-loader.loaded {
    opacity: 0;
    visibility: hidden;
}

.loader-icon {
    animation: loaderPulse 1.2s ease-in-out infinite;
}

@keyframes loaderPulse {
    0%, 100% { opacity: 0.4; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1); }
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--color-navy-950);
}
::-webkit-scrollbar-thumb {
    background: var(--color-navy-800);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--color-gold-400);
}

/* --- Navigation --- */
#navbar {
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease, box-shadow 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(10, 22, 40, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(212, 168, 75, 0.1);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-gold-400);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--color-gold-400);
}

.nav-cta {
    box-shadow: 0 0 20px rgba(212, 168, 75, 0.2);
}

.nav-cta:hover {
    box-shadow: 0 0 30px rgba(212, 168, 75, 0.4);
}

/* --- Mobile Menu --- */
#mobile-menu {
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

.mobile-menu-link {
    transform: translateY(20px);
    opacity: 0;
    transition: transform 0.4s ease, opacity 0.4s ease;
}

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

#mobile-menu.open .mobile-menu-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-menu-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-menu-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-menu-link:nth-child(4) { transition-delay: 0.25s; }
#mobile-menu.open .mobile-menu-link:nth-child(5) { transition-delay: 0.3s; }
#mobile-menu.open .mobile-menu-link:nth-child(6) { transition-delay: 0.35s; }

/* --- Hamburger --- */
#mobile-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

#mobile-menu-btn.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#mobile-menu-btn.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

#mobile-menu-btn.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 6;
}

/* --- Hero --- */
.hero-bg {
    will-change: transform;
}

.hero-overlay {
    background-image: linear-gradient(
        to right,
        rgba(10, 22, 40, 0.97) 0%,
        rgba(10, 22, 40, 0.75) 50%,
        rgba(10, 22, 40, 0.4) 100%
    );
}

.hero-scroll-indicator {
    animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
    0%, 100% { transform: translate(-50%, 0); opacity: 0.5; }
    50% { transform: translate(-50%, 8px); opacity: 1; }
}

.scroll-line {
    background: linear-gradient(to bottom, var(--color-gold-400), transparent);
}

/* --- Section Labels --- */
.section-label {
    display: block;
}

/* --- Buttons --- */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    background: var(--color-gold-400);
    color: var(--color-navy-950);
    font-family: var(--font-inter);
    font-weight: 600;
    font-size: 0.9375rem;
    border: none;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    background: var(--color-gold-300);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(212, 168, 75, 0.3);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    background: transparent;
    color: #ffffff;
    font-family: var(--font-inter);
    font-weight: 500;
    font-size: 0.9375rem;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    border-color: var(--color-gold-400);
    color: var(--color-gold-400);
    transform: translateY(-2px);
}

/* --- Service Cards --- */
.service-card {
    background: var(--color-navy-900);
    border: 1px solid rgba(255,255,255,0.05);
    padding: 2rem;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--color-gold-400), transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

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

.service-card:hover {
    border-color: rgba(212, 168, 75, 0.2);
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

/* --- About --- */
.about-image-wrapper {
    position: relative;
}

.about-image-accent {
    z-index: -1;
}

.about-image-strip {
    z-index: -1;
}

.about-feature {
    display: flex;
    align-items: center;
    gap: 12px;
}

.about-feature-icon {
    flex-shrink: 0;
}

/* --- Process Steps --- */
.process-step {
    position: relative;
}

.process-step-line {
    background: linear-gradient(to right, rgba(212, 168, 75, 0.3), transparent);
}

/* --- Gallery --- */
.gallery-item {
    overflow: hidden;
    aspect-ratio: 1;
    cursor: pointer;
}

.gallery-img {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* --- Contact Form --- */
.form-input {
    background: var(--color-navy-950);
    border: 1px solid rgba(255,255,255,0.1);
    color: #ffffff;
    font-family: var(--font-inter);
    font-size: 0.9375rem;
    padding: 14px 16px;
    border-radius: 0;
    transition: all 0.3s ease;
    width: 100%;
    outline: none;
}

.form-input::placeholder {
    color: rgba(255,255,255,0.25);
}

.form-input:focus {
    border-color: var(--color-gold-400);
    box-shadow: 0 0 0 3px rgba(212, 168, 75, 0.1);
}

.form-input option {
    background: var(--color-navy-950);
}

/* --- Reveal Animations --- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.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; }
.reveal-delay-6 { transition-delay: 0.6s; }

/* --- Hero Entrance --- */
#hero-label {
    animation: heroFadeUp 0.8s ease forwards;
    animation-delay: 0.5s;
    opacity: 0;
}

#hero-headline {
    animation: heroFadeUp 0.8s ease forwards;
    animation-delay: 0.7s;
    opacity: 0;
}

#hero-sub {
    animation: heroFadeUp 0.8s ease forwards;
    animation-delay: 0.9s;
    opacity: 0;
}

#hero-cta {
    animation: heroFadeUp 0.8s ease forwards;
    animation-delay: 1.1s;
    opacity: 0;
}

#hero-stat-1 {
    animation: heroFadeLeft 0.6s ease forwards;
    animation-delay: 1.3s;
    opacity: 0;
}

#hero-stat-2 {
    animation: heroFadeLeft 0.6s ease forwards;
    animation-delay: 1.5s;
    opacity: 0;
}

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

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

/* --- Responsive --- */
@media (max-width: 767px) {
    html {
        scroll-padding-top: 70px;
    }

    .hero-stats {
        display: none !important;
    }

    #hero-headline {
        font-size: 2.75rem !important;
    }

    .about-image-wrapper {
        margin-bottom: 2rem;
    }

    .about-badge {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        display: inline-block;
        margin-top: 1rem;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    #hero-headline {
        font-size: 4rem !important;
    }
}

@media (min-width: 1024px) {
    #hero-headline {
        font-size: 5.5rem !important;
    }
}
