/* ==================== RESET AND BASE STYLES ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Light Theme Colors */
    --primary-blue: #2563eb;
    --dark-blue: #1e40af;
    --light-blue: #3b82f6;
    --accent-orange: #f59e0b;
    --dark-orange: #d97706;

    /* Background Colors */
    --bg-white: #ffffff;
    --bg-light: #f8fafc;
    --bg-gray: #f1f5f9;
    --bg-card: #ffffff;

    /* Text Colors */
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --text-white: #ffffff;

    /* Border Colors */
    --border-light: #e2e8f0;
    --border-gray: #cbd5e1;
    --border-dark: #94a3b8;

    /* Shadow Colors */
    --shadow-light: rgba(0, 0, 0, 0.1);
    --shadow-medium: rgba(0, 0, 0, 0.15);
    --shadow-dark: rgba(0, 0, 0, 0.25);

    /* Typography */
    --font-primary: 'Inter', sans-serif;
    --font-heading: 'Poppins', sans-serif;

    /* Spacing */
    --container-padding: 0 2rem;
    --section-padding: 6rem 0;

    /* Effects */
    --border-radius: 12px;
    --border-radius-lg: 16px;
    --shadow-sm: 0 2px 4px var(--shadow-light);
    --shadow-md: 0 4px 6px var(--shadow-light);
    --shadow-lg: 0 10px 15px var(--shadow-medium);
    --shadow-xl: 0 20px 25px var(--shadow-dark);
}

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

body {
    font-family: var(--font-primary);
    background: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--container-padding);
}

/* ==================== MOVING ROAD BACKGROUND ==================== */
.road-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
    background: linear-gradient(180deg, #e2e8f0 0%, #f1f5f9 100%);
}

.road-strip {
    position: absolute;
    bottom: 30%;
    width: 200%;
    height: 4px;
    background: repeating-linear-gradient(90deg,
            var(--border-gray) 0px,
            var(--border-gray) 40px,
            transparent 40px,
            transparent 80px);
    opacity: 0.3;
}

.strip-1 {
    bottom: 32%;
}

.strip-2 {
    bottom: 28%;
}

.road-vehicles {
    position: absolute;
    bottom: 25%;
    width: 100%;
    height: 100px;
    z-index: -1;
}

.road-vehicle {
    position: absolute;
    width: 120px;
    height: 60px;
    opacity: 0.5;
}

.vehicle-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* ==================== NAVIGATION ==================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo,
.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo img,
.nav-brand img,
.brand-logo {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.accent {
    color: var(--accent-orange);
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
    padding: 0.5rem 0;
}

.nav-link:hover {
    color: var(--primary-blue);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-blue);
    transition: width 0.3s ease;
}

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

.admin-link {
    background: var(--primary-blue);
    color: var(--text-white) !important;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    border: none;
}

.admin-link:hover {
    background: var(--dark-blue);
    transform: translateY(-1px);
}

.admin-link::after {
    display: none;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: 0.3s;
}

/* ==================== HERO SECTION ==================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg,
            rgba(37, 99, 235, 0.05) 0%,
            rgba(245, 158, 11, 0.05) 100%);
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--container-padding);
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.business-toggle {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.toggle-btn {
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--border-gray);
    background: var(--bg-white);
    color: var(--text-secondary);
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.toggle-btn.active,
.toggle-btn:hover {
    background: var(--primary-blue);
    color: var(--text-white);
    border-color: var(--primary-blue);
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.title-line {
    display: block;
    opacity: 0;
    transform: translateY(50px);
}

.accent-text {
    color: var(--accent-orange);
}

.hero-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 500px;
    opacity: 0;
    transform: translateY(30px);
}

.hero-search {
    margin-bottom: 2rem;
    opacity: 0;
    transform: translateY(30px);
}

.search-container {
    display: flex;
    background: var(--bg-white);
    border: 2px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.search-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    outline: none;
    font-size: 1rem;
    background: transparent;
}

.search-btn {
    padding: 1rem 1.5rem;
    background: var(--primary-blue);
    color: var(--text-white);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: var(--dark-blue);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(30px);
}

.btn {
    padding: 1rem 2rem;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-blue);
    color: var(--text-white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--dark-blue);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--bg-white);
    color: var(--text-primary);
    border: 2px solid var(--border-gray);
}

.btn-secondary:hover {
    background: var(--bg-gray);
    border-color: var(--primary-blue);
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* Hero Stats */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    opacity: 0;
    transform: translateX(50px);
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-blue);
    display: block;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

/* ==================== SECTIONS ==================== */
section {
    padding: var(--section-padding);
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ==================== BRANDS SECTION ==================== */
.brands-section {
    background: var(--bg-white);
}

.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.brand-card {
    background: var(--bg-white);
    border: 2px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.brand-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-blue);
}

.brand-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-light);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.brand-card:hover .brand-logo {
    transform: scale(1.1);
    background: var(--primary-blue);
}

.logo-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.brand-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.brand-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.brand-stats {
    display: flex;
    justify-content: space-around;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ==================== PARTS SECTION ==================== */
.parts-section {
    background: var(--bg-gray);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.category-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s ease;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-blue);
}

.card-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-blue), var(--light-blue));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: var(--text-white);
    transition: all 0.3s ease;
}

.category-card:hover .card-icon {
    transform: scale(1.1) rotate(5deg);
}

.category-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.category-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.parts-count {
    font-weight: 600;
    color: var(--accent-orange);
    font-size: 0.9rem;
}

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-blue), var(--dark-blue));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.category-card:hover .card-overlay {
    opacity: 0.95;
}

.view-parts {
    color: var(--text-white);
    font-weight: 600;
    font-size: 1.1rem;
}

/* ==================== FEATURED PARTS ==================== */
.featured-parts {
    background: var(--bg-white);
}

.parts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.part-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.part-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.part-image {
    position: relative;
    height: 200px;
    background: var(--bg-gray);
    overflow: hidden;
}

.part-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.part-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--accent-orange);
    color: var(--text-white);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.part-info {
    padding: 1.5rem;
}

.part-info h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.part-compatibility {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.part-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 1rem;
}

/* ==================== CARS SECTION ==================== */
.cars-section {
    background: var(--bg-gray);
}

.cars-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.car-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.car-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.car-image {
    position: relative;
    height: 220px;
    background: var(--bg-gray);
    overflow: hidden;
}

.car-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.car-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--primary-blue);
    color: var(--text-white);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.car-info {
    padding: 1.5rem;
}

.car-info h4 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.car-details {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.car-details span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.car-price {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--accent-orange);
    margin-bottom: 1rem;
}

/* ==================== FEATURES SECTION ==================== */
.features {
    background: var(--bg-white);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.feature-item {
    text-align: center;
    padding: 2rem;
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--accent-orange), var(--dark-orange));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: var(--text-white);
    box-shadow: 0 10px 30px rgba(245, 158, 11, 0.3);
    transition: all 0.3s ease;
}

.feature-item:hover .feature-icon {
    transform: scale(1.1);
}

.feature-item h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-item p {
    color: var(--text-secondary);
}

/* ==================== CONTACT SECTION ==================== */
.contact-section {
    background: var(--bg-gray);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-white);
    font-size: 1.2rem;
}

.contact-details h4 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.contact-details p {
    color: var(--text-secondary);
}

.contact-form {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
}

.contact-form h3 {
    font-family: var(--font-heading);
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--border-light);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--bg-white);
    color: var(--text-primary);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-blue);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* ==================== FOOTER ==================== */
.footer {
    background: var(--text-primary);
    color: var(--text-white);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-logo i {
    color: var(--primary-blue);
    font-size: 1.8rem;
}

.footer-section p {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-white);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--accent-orange);
    transform: translateY(-2px);
}

.footer-section h4 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-white);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--primary-blue);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-dark);
    color: var(--text-muted);
}

/* ==================== RESPONSIVE DESIGN ==================== */
@media (max-width: 768px) {

    .nav-logo img,
    .nav-brand img,
    .brand-logo {
        height: 45px;
    }

    .nav-menu {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 2rem;
        gap: 1rem;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        border-top: 1px solid var(--border-light);
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        transform: translateY(0);
    }

    .business-toggle {
        justify-content: center;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {

    .nav-logo img,
    .nav-brand img,
    .brand-logo {
        height: 40px;
    }

    :root {
        --container-padding: 0 1rem;
        --section-padding: 4rem 0;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .brands-grid,
    .categories-grid,
    .parts-grid,
    .cars-grid {
        grid-template-columns: 1fr;
    }

    .hero-stats {
        grid-template-columns: 1fr;
    }
}

/* ==================== UTILITY CLASSES ==================== */
.scroll-reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

.scroll-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.text-center {
    text-align: center;
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-orange));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-blue);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--dark-blue);
}

/* ===== HOMEPAGE LAYOUT FIX ===== */
/* Added to fix collapsed layout issues */

* {
    box-sizing: border-box;
}

html,
body {
    height: 100%;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

/* Fix hero section spacing */
.hero {
    min-height: 100vh;
    padding: 120px 0 80px;
    position: relative;
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
}

/* Ensure proper container widths */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Fix section spacing */
section {
    padding: 80px 0;
    position: relative;
    width: 100%;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px;
    z-index: 10;
    position: relative;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Fix button spacing */
.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}

/* Fix stats grid spacing */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin: 4rem auto 0;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    max-width: 1000px;
    z-index: 10;
    position: relative;
}

.stat-item {
    text-align: center;
    padding: 1rem;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: #2563eb;
    margin-bottom: 0.5rem;
    line-height: 1;
}

/* Fix grids */
.parts-grid,
.cars-grid,
.categories-grid,
.brands-grid {
    display: grid;
    gap: 2rem;
    margin: 3rem 0;
}

.parts-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.cars-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

.categories-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.brands-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* Responsive fixes */
@media (max-width: 768px) {
    .hero {
        padding: 100px 0 60px;
        min-height: 80vh;
    }

    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        padding: 1.5rem;
        margin: 2rem auto 0;
    }

    .stat-number {
        font-size: 2rem;
    }

    .parts-grid,
    .cars-grid,
    .categories-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .brands-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    section {
        padding: 60px 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero-stats {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .brands-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== END LAYOUT FIX ===== */