/**
 * DrivinStats Custom Styles - FIXED VERSION
 * Combines: Single Vehicle, Search/Archive, and Compare pages
 * 
 * FIXES:
 * 1. Homepage background image visibility
 * 2. Compare mode checkbox styling
 * 3. Remove button styling in compare page
 */

/* ===================================
   ASTRA THEME OVERRIDES
   =================================== */

/* Hide Astra default header */
#masthead,
.site-header {
    display: none !important;
}

/* Force full-width for vehicle pages */
.drivinstats-single-vehicle .site-content,
.drivinstats-vehicle-archive .site-content,
body.page-template-page-compare .site-content {
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
}

.drivinstats-single-vehicle .ast-container,
.drivinstats-vehicle-archive .ast-container,
body.page-template-page-compare .ast-container {
    max-width: 100% !important;
    padding: 0 !important;
}

.drivinstats-single-vehicle #primary,
.drivinstats-vehicle-archive #primary,
body.page-template-page-compare #primary {
    margin: 0 !important;
    padding: 0 !important;
}

.drivinstats-single-vehicle .entry-content,
.drivinstats-vehicle-archive .entry-content,
body.page-template-page-compare .entry-content {
    margin: 0 !important;
    padding: 0 !important;
}

/* Hide Astra page title */
.drivinstats-single-vehicle .entry-header,
.drivinstats-vehicle-archive .entry-header,
body.page-template-page-compare .entry-header {
    display: none !important;
}

/* ===================================
   CUSTOM HEADER & NAVIGATION
   =================================== */

.drivinstats-header {
    background: #fff;
    border-bottom: 1px solid #d2d2d7;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.drivinstats-nav {
    padding: 0;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo-img {
    height: 40px;
    width: auto;
}

.logo-text {
    font-size: 24px;
    font-weight: 700;
    color: #1d1d1f;
    letter-spacing: -0.5px;
}

.main-nav {
    display: flex;
    gap: 40px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav li {
    margin: 0;
}

.main-nav a {
    color: #1d1d1f;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s;
    padding: 8px 0;
    display: block;
}

.main-nav a:hover,
.main-nav a.active {
    color: #1A355D;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 2px;
    background: #1d1d1f;
    transition: all 0.3s;
}

.mobile-menu {
    display: none !important; /* Force hidden by default */
    background: #fff;
    border-top: 1px solid #d2d2d7;
}

.mobile-menu.active {
    display: block !important; /* Only show when active class added */
}

.mobile-menu ul {
    list-style: none;
    margin: 0;
    padding: 20px 40px;
}

.mobile-menu li {
    margin: 0;
}

.mobile-menu a {
    color: #1d1d1f;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    padding: 12px 0;
    display: block;
    border-bottom: 1px solid #f5f5f7;
}

.mobile-menu a:hover {
    color: #1A355D;
}

/* Responsive Header */
@media (max-width: 968px) {
    .main-nav {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-container {
        padding: 16px 20px;
    }
}

/* ===================================
   GLOBAL STYLES
   =================================== */

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f5f5f7;
    color: #1d1d1f;
    line-height: 1.6;
}

/* Remove default Astra margins on vehicle pages */
.drivinstats-single-vehicle .entry-content,
.drivinstats-vehicle-archive .ast-container {
    max-width: 100%;
    padding: 0;
    margin: 0;
}

/* ===================================
   HOMEPAGE STYLES - FIXED
   =================================== */

/* Prevent Customizer interference */
body.home .customize-partial-edit-shortcut,
body.home .customize-partial-edit-shortcut-button {
    display: none !important;
}

/* Hide mobile menu by default on all pages */
.mobile-menu {
    display: none !important;
    background: #fff;
    border-top: 1px solid #d2d2d7;
}

.mobile-menu.active {
    display: block !important;
}

/* Clean Hero Section */
.homepage-hero-clean {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: #f5f5f7;
}

/* FIX #1: Background image - CLEARLY VISIBLE */
.hero-background-image {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    background-image: url('https://drivinstats.com/wp-content/uploads/2025/12/Random_cars.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.6; /* Made much more visible - was 0.25 */
}

.hero-overlay-clean {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(255,255,255,0.4) 0%, rgba(245,245,247,0.5) 100%); /* Light overlay so text is still readable */
    z-index: 2;
}

.hero-content-clean {
    position: relative;
    z-index: 3;
    max-width: 900px;
    padding: 80px 40px;
}

.hero-title-main {
    font-size: 64px;
    font-weight: 700;
    color: #1d1d1f;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 24px;
}

.hero-subtitle-main {
    font-size: 21px;
    color: #6e6e73;
    margin-bottom: 48px;
    font-weight: 400;
}

.btn-explore-vehicles {
    display: inline-block;
    padding: 18px 48px;
    background: #1A355D;
    color: #fff !important;
    font-size: 18px;
    font-weight: 600;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s;
    box-shadow: 0 8px 24px rgba(26, 53, 93, 0.3);
}

.btn-explore-vehicles:hover {
    background: #142845;
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(26, 53, 93, 0.4);
    color: #fff !important;
}

/* Homepage Footer */
.homepage-footer {
    background: #fff;
    border-top: 1px solid #d2d2d7;
    padding: 60px 40px;
    text-align: center;
}

.footer-content-main {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-text-main {
    color: #6e6e73;
    font-size: 14px;
    margin-bottom: 10px;
}

.footer-tagline-main {
    color: #1d1d1f;
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 12px;
}

/* Responsive - Clean Homepage */
@media (max-width: 768px) {
    .homepage-hero-clean {
        min-height: 500px;
    }

    .hero-title-main {
        font-size: 40px;
    }

    .hero-subtitle-main {
        font-size: 18px;
    }

    .btn-explore-vehicles {
        padding: 16px 36px;
        font-size: 16px;
    }

    .hero-content-clean {
        padding: 60px 20px;
    }

    .homepage-footer {
        padding: 40px 20px;
    }
}

/* ===================================
   SINGLE VEHICLE PAGE STYLES
   =================================== */

/* Vehicle Header Section */
.vehicle-header {
    background: #fff;
    padding: 40px 40px 30px;
    border-bottom: 1px solid #d2d2d7;
}

.vehicle-header-container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Breadcrumb */
.breadcrumb {
    margin-bottom: 20px;
}

.breadcrumb a {
    color: #1A355D;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: #142845;
}

.breadcrumb span {
    color: #6e6e73;
    margin: 0 8px;
}

/* Vehicle Title Section */
.vehicle-title-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 30px;
    flex-wrap: wrap;
}

.title-left {
    flex: 1;
    min-width: 300px;
}

.vehicle-brand-badge {
    display: inline-block;
    background: #1A355D;
    color: #fff;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
}

.vehicle-title {
    font-size: 48px;
    font-weight: 700;
    color: #1d1d1f;
    line-height: 1.2;
    letter-spacing: -1.5px;
    margin-bottom: 12px;
}

.vehicle-subtitle {
    font-size: 18px;
    color: #6e6e73;
    margin-bottom: 0;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-action {
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
    border: none;
    font-family: inherit;
}

.btn-action.primary {
    background: #1A355D;
    color: #fff;
}

.btn-action.primary:hover {
    background: #142845;
}

.btn-action.secondary {
    background: #fff;
    color: #1d1d1f;
    border: 1px solid #d2d2d7;
}

.btn-action.secondary:hover {
    background: #f5f5f7;
}

/* Image Gallery */
.gallery-section {
    background: #1d1d1f;
    position: relative;
    overflow: hidden;
}

.gallery-container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    height: 600px;
}

.gallery-wrapper {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
}

.gallery-slide {
    min-width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1d1d1f;
    color: #fff;
    font-size: 24px;
    font-weight: 500;
}

.gallery-slide img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Gallery Controls */
.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s;
    color: #1d1d1f;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-arrow:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1);
}

.arrow-left {
    left: 30px;
}

.arrow-right {
    right: 30px;
}

.gallery-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    padding: 0;
}

.dot.active {
    background: #fff;
    width: 30px;
    border-radius: 5px;
}

/* Specifications Section */
.specs-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 40px;
}

.spec-category {
    background: #fff;
    border-radius: 18px;
    padding: 30px;
    margin-bottom: 20px;
    transition: all 0.3s;
}

.spec-category:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.category-title {
    font-size: 24px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f5f5f7;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.collapse-icon {
    font-size: 18px;
    color: #6e6e73;
    transition: transform 0.3s;
}

.category-title.collapsed .collapse-icon {
    transform: rotate(-90deg);
}

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

.spec-item {
    padding: 16px;
    background: #f5f5f7;
    border-radius: 10px;
    transition: all 0.3s;
}

.spec-item:hover {
    background: #ececef;
}

.spec-label {
    font-size: 13px;
    color: #6e6e73;
    margin-bottom: 6px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.spec-value {
    font-size: 17px;
    color: #1d1d1f;
    font-weight: 600;
}

.spec-value.winner {
    color: #2E7D32;
}

.spec-value.winner::after {
    content: " ⭐";
}

/* ===================================
   SEARCH/ARCHIVE PAGE STYLES
   =================================== */

/* Hero Section */
.search-hero {
    background: linear-gradient(135deg, #1A355D 0%, #142845 100%);
    padding: 80px 40px 60px;
    text-align: center;
    color: #fff;
}

.search-hero h1 {
    font-size: 56px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1.5px;
    color: #fff !important;
}

.search-hero p {
    font-size: 20px;
    margin-bottom: 40px;
    opacity: 0.95;
    color: #fff !important;
}

.search-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 18px 24px;
    font-size: 17px;
    border: none;
    border-radius: 12px;
    background: #fff;
    color: #1d1d1f;
    font-family: inherit;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    text-align: center;
}

.search-input::placeholder {
    color: #86868b;
}

.search-input:focus {
    outline: none;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
    text-align: left;
}

/* Filters Section */
.filters-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.filters-title {
    font-size: 28px;
    font-weight: 600;
    color: #1d1d1f;
}

.clear-filters {
    padding: 10px 20px;
    background: transparent;
    border: 1px solid #d2d2d7;
    border-radius: 20px;
    font-size: 14px;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.clear-filters:hover {
    background: #f5f5f7;
    color: #1A355D;
    border-color: #1A355D;
}

/* Cascading Dropdowns */
.dropdowns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dropdown-container {
    position: relative;
}

.dropdown-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #6e6e73;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dropdown-button {
    width: 100%;
    padding: 14px 16px;
    background: #fff;
    border: 1px solid #d2d2d7;
    border-radius: 10px;
    font-size: 15px;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: inherit;
    text-align: left;
}

.dropdown-button:hover {
    border-color: #1A355D;
    background: #fff;
}

.dropdown-button:focus {
    outline: none;
    border-color: #1A355D;
    background: #fff;
}

.dropdown-button:disabled {
    background: #f5f5f7;
    color: #9a9a9e;
    cursor: not-allowed;
}

.dropdown-button.active {
    border-color: #1A355D;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(26, 53, 93, 0.1);
}

.dropdown-arrow {
    font-size: 12px;
    color: #6e6e73;
    transition: transform 0.3s;
}

.dropdown-button.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #d2d2d7;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    max-height: 300px;
    overflow-y: auto;
    z-index: 100;
    display: none;
}

.dropdown-menu.active {
    display: block;
}

.dropdown-item {
    padding: 12px 16px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
    color: #1d1d1f;
}

.dropdown-item:hover {
    background: #f5f5f7;
    color: #1A355D;
}

.dropdown-item.selected {
    background: #1A355D;
    color: #fff;
}

/* Additional Filter Pills */
.additional-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.filter-pill {
    padding: 10px 20px;
    background: #fff;
    border: 1px solid #d2d2d7;
    border-radius: 20px;
    font-size: 14px;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.filter-pill:hover {
    border-color: #1A355D;
    background: #f5f5f7;
    color: #1A355D;
}

.filter-pill.active {
    background: #1A355D;
    color: #fff;
    border-color: #1A355D;
}

/* Results Info */
.results-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 16px;
}

.results-count {
    font-size: 16px;
    color: #6e6e73;
}

.sort-select {
    padding: 10px 16px;
    border: 1px solid #d2d2d7;
    border-radius: 20px;
    font-size: 14px;
    color: #1d1d1f;
    background: #fff;
    cursor: pointer;
    font-family: inherit;
}

/* Vehicle Grid */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.vehicle-card {
    background: #fff;
    border-radius: 18px;
    overflow: hidden;
    transition: all 0.3s;
    text-decoration: none;
    color: inherit;
    display: block;
    position: relative;
    border: 2px solid transparent;
}

.vehicle-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.vehicle-image {
    height: 200px;
    background: linear-gradient(135deg, #e3e3e8 0%, #f5f5f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6e6e73;
    font-size: 18px;
    font-weight: 600;
    overflow: hidden;
    position: relative;
}

/* SVG Car Placeholder - when no image */
.vehicle-image:not(:has(img))::before {
    content: '';
    position: absolute;
    width: 160px;
    height: 80px;
    background-image: url("data:image/svg+xml,%3Csvg fill='currentColor' viewBox='0 -43.92 122.88 122.88' xmlns='http://www.w3.org/2000/svg'%3E%3Cstyle%3E.st0%7Bfill-rule:evenodd;clip-rule:evenodd%7D%3C/style%3E%3Cpath class='st0' d='M99.42 13.57c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm-20.37-8.57c-.59 1.27-1.06 2.69-1.42 4.23-.82 2.57.39 3.11 3.19 2.06 2.06-1.23 4.12-2.47 6.18-3.7 1.05-.74 1.55-1.47 1.38-2.19-.34-1.42-3.08-2.16-5.33-2.6-2.86-.57-2.66-.69-4-2zm-55.19 14.31c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zm75.56 0c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zM46.14 12.5c2.77-2.97 5.97-4.9 9.67-6.76 8.1-4.08 13.06-3.58 21.66-3.58l-2.89 7.5c-1.21 1.6-2.58 2.73-4.66 2.84H46.14zm-22.28 1.07c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm16.96-3.27c3.52-2.19 7.35-4.15 11.59-5.82 12.91-5.09 22.78-6 36.32-1.9 4.08 1.55 8.16 3.1 12.24 4.06 4.03.96 21.48 1.88 21.91 4.81l-4.31 5.15c1.57 1.36 2.85 3.03 3.32 5.64-.13 1.61-.57 2.96-1.33 4.04-1.29 1.85-5.07 3.76-7.11 2.67-.65-.35-1.02-1.05-1.01-2.24.06-23.9-28.79-21.18-26.62 2.82H35.48C44.8 5.49 5.04 5.4 12.1 28.7 9.62 31.38 3.77 27.34 0 18.75c1.03-1.02 2.16-1.99 3.42-2.89-.06-.05.06.19-.15-.17-.21-.36.51-1.87 1.99-2.74 7.76-4.55 26.47-4.43 35.56-2.65z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.35;
}

/* Fuel Type Color Backgrounds */
.vehicle-card[data-fuel-type*="Electric"] .vehicle-image,
.vehicle-card[data-fuel-type*="electric"] .vehicle-image {
    background: linear-gradient(135deg, #c8e6c9 0%, #e8f5e9 100%);
}

.vehicle-card[data-fuel-type*="Electric"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="electric"] .vehicle-image::before {
    background-image: url("data:image/svg+xml,%3Csvg fill='%232e7d32' viewBox='0 -43.92 122.88 122.88' xmlns='http://www.w3.org/2000/svg'%3E%3Cstyle%3E.st0%7Bfill-rule:evenodd;clip-rule:evenodd%7D%3C/style%3E%3Cpath class='st0' d='M99.42 13.57c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm-20.37-8.57c-.59 1.27-1.06 2.69-1.42 4.23-.82 2.57.39 3.11 3.19 2.06 2.06-1.23 4.12-2.47 6.18-3.7 1.05-.74 1.55-1.47 1.38-2.19-.34-1.42-3.08-2.16-5.33-2.6-2.86-.57-2.66-.69-4-2zm-55.19 14.31c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zm75.56 0c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zM46.14 12.5c2.77-2.97 5.97-4.9 9.67-6.76 8.1-4.08 13.06-3.58 21.66-3.58l-2.89 7.5c-1.21 1.6-2.58 2.73-4.66 2.84H46.14zm-22.28 1.07c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm16.96-3.27c3.52-2.19 7.35-4.15 11.59-5.82 12.91-5.09 22.78-6 36.32-1.9 4.08 1.55 8.16 3.1 12.24 4.06 4.03.96 21.48 1.88 21.91 4.81l-4.31 5.15c1.57 1.36 2.85 3.03 3.32 5.64-.13 1.61-.57 2.96-1.33 4.04-1.29 1.85-5.07 3.76-7.11 2.67-.65-.35-1.02-1.05-1.01-2.24.06-23.9-28.79-21.18-26.62 2.82H35.48C44.8 5.49 5.04 5.4 12.1 28.7 9.62 31.38 3.77 27.34 0 18.75c1.03-1.02 2.16-1.99 3.42-2.89-.06-.05.06.19-.15-.17-.21-.36.51-1.87 1.99-2.74 7.76-4.55 26.47-4.43 35.56-2.65z'/%3E%3C/svg%3E");
    opacity: 0.5;
}

.vehicle-card[data-fuel-type*="Hybrid"] .vehicle-image,
.vehicle-card[data-fuel-type*="hybrid"] .vehicle-image {
    background: linear-gradient(135deg, #b3e5fc 0%, #e1f5fe 100%);
}

.vehicle-card[data-fuel-type*="Hybrid"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="hybrid"] .vehicle-image::before {
    background-image: url("data:image/svg+xml,%3Csvg fill='%230277bd' viewBox='0 -43.92 122.88 122.88' xmlns='http://www.w3.org/2000/svg'%3E%3Cstyle%3E.st0%7Bfill-rule:evenodd;clip-rule:evenodd%7D%3C/style%3E%3Cpath class='st0' d='M99.42 13.57c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm-20.37-8.57c-.59 1.27-1.06 2.69-1.42 4.23-.82 2.57.39 3.11 3.19 2.06 2.06-1.23 4.12-2.47 6.18-3.7 1.05-.74 1.55-1.47 1.38-2.19-.34-1.42-3.08-2.16-5.33-2.6-2.86-.57-2.66-.69-4-2zm-55.19 14.31c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zm75.56 0c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zM46.14 12.5c2.77-2.97 5.97-4.9 9.67-6.76 8.1-4.08 13.06-3.58 21.66-3.58l-2.89 7.5c-1.21 1.6-2.58 2.73-4.66 2.84H46.14zm-22.28 1.07c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm16.96-3.27c3.52-2.19 7.35-4.15 11.59-5.82 12.91-5.09 22.78-6 36.32-1.9 4.08 1.55 8.16 3.1 12.24 4.06 4.03.96 21.48 1.88 21.91 4.81l-4.31 5.15c1.57 1.36 2.85 3.03 3.32 5.64-.13 1.61-.57 2.96-1.33 4.04-1.29 1.85-5.07 3.76-7.11 2.67-.65-.35-1.02-1.05-1.01-2.24.06-23.9-28.79-21.18-26.62 2.82H35.48C44.8 5.49 5.04 5.4 12.1 28.7 9.62 31.38 3.77 27.34 0 18.75c1.03-1.02 2.16-1.99 3.42-2.89-.06-.05.06.19-.15-.17-.21-.36.51-1.87 1.99-2.74 7.76-4.55 26.47-4.43 35.56-2.65z'/%3E%3C/svg%3E");
    opacity: 0.5;
}

.vehicle-card[data-fuel-type*="Diesel"] .vehicle-image,
.vehicle-card[data-fuel-type*="diesel"] .vehicle-image {
    background: linear-gradient(135deg, #424242 0%, #616161 100%);
}

.vehicle-card[data-fuel-type*="Diesel"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="diesel"] .vehicle-image::before {
    background-image: url("data:image/svg+xml,%3Csvg fill='%23ffffff' viewBox='0 -43.92 122.88 122.88' xmlns='http://www.w3.org/2000/svg'%3E%3Cstyle%3E.st0%7Bfill-rule:evenodd;clip-rule:evenodd%7D%3C/style%3E%3Cpath class='st0' d='M99.42 13.57c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm-20.37-8.57c-.59 1.27-1.06 2.69-1.42 4.23-.82 2.57.39 3.11 3.19 2.06 2.06-1.23 4.12-2.47 6.18-3.7 1.05-.74 1.55-1.47 1.38-2.19-.34-1.42-3.08-2.16-5.33-2.6-2.86-.57-2.66-.69-4-2zm-55.19 14.31c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zm75.56 0c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zM46.14 12.5c2.77-2.97 5.97-4.9 9.67-6.76 8.1-4.08 13.06-3.58 21.66-3.58l-2.89 7.5c-1.21 1.6-2.58 2.73-4.66 2.84H46.14zm-22.28 1.07c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm16.96-3.27c3.52-2.19 7.35-4.15 11.59-5.82 12.91-5.09 22.78-6 36.32-1.9 4.08 1.55 8.16 3.1 12.24 4.06 4.03.96 21.48 1.88 21.91 4.81l-4.31 5.15c1.57 1.36 2.85 3.03 3.32 5.64-.13 1.61-.57 2.96-1.33 4.04-1.29 1.85-5.07 3.76-7.11 2.67-.65-.35-1.02-1.05-1.01-2.24.06-23.9-28.79-21.18-26.62 2.82H35.48C44.8 5.49 5.04 5.4 12.1 28.7 9.62 31.38 3.77 27.34 0 18.75c1.03-1.02 2.16-1.99 3.42-2.89-.06-.05.06.19-.15-.17-.21-.36.51-1.87 1.99-2.74 7.76-4.55 26.47-4.43 35.56-2.65z'/%3E%3C/svg%3E");
    opacity: 0.6;
}

.vehicle-card[data-fuel-type*="Petrol"] .vehicle-image,
.vehicle-card[data-fuel-type*="petrol"] .vehicle-image,
.vehicle-card[data-fuel-type*="Gasoline"] .vehicle-image,
.vehicle-card[data-fuel-type*="gasoline"] .vehicle-image {
    background: linear-gradient(135deg, #ffe0b2 0%, #fff3e0 100%);
}

.vehicle-card[data-fuel-type*="Petrol"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="petrol"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="Gasoline"] .vehicle-image::before,
.vehicle-card[data-fuel-type*="gasoline"] .vehicle-image::before {
    background-image: url("data:image/svg+xml,%3Csvg fill='%23e65100' viewBox='0 -43.92 122.88 122.88' xmlns='http://www.w3.org/2000/svg'%3E%3Cstyle%3E.st0%7Bfill-rule:evenodd;clip-rule:evenodd%7D%3C/style%3E%3Cpath class='st0' d='M99.42 13.57c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm-20.37-8.57c-.59 1.27-1.06 2.69-1.42 4.23-.82 2.57.39 3.11 3.19 2.06 2.06-1.23 4.12-2.47 6.18-3.7 1.05-.74 1.55-1.47 1.38-2.19-.34-1.42-3.08-2.16-5.33-2.6-2.86-.57-2.66-.69-4-2zm-55.19 14.31c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zm75.56 0c2.75 0 4.99 2.23 4.99 4.99 0 2.75-2.23 4.99-4.99 4.99-2.75 0-4.99-2.23-4.99-4.99 0-2.76 2.23-4.99 4.99-4.99zM46.14 12.5c2.77-2.97 5.97-4.9 9.67-6.76 8.1-4.08 13.06-3.58 21.66-3.58l-2.89 7.5c-1.21 1.6-2.58 2.73-4.66 2.84H46.14zm-22.28 1.07c5.93 0 10.73 4.8 10.73 10.73 0 5.93-4.8 10.73-10.73 10.73s-10.73-4.8-10.73-10.73c0-5.93 4.8-10.73 10.73-10.73zm16.96-3.27c3.52-2.19 7.35-4.15 11.59-5.82 12.91-5.09 22.78-6 36.32-1.9 4.08 1.55 8.16 3.1 12.24 4.06 4.03.96 21.48 1.88 21.91 4.81l-4.31 5.15c1.57 1.36 2.85 3.03 3.32 5.64-.13 1.61-.57 2.96-1.33 4.04-1.29 1.85-5.07 3.76-7.11 2.67-.65-.35-1.02-1.05-1.01-2.24.06-23.9-28.79-21.18-26.62 2.82H35.48C44.8 5.49 5.04 5.4 12.1 28.7 9.62 31.38 3.77 27.34 0 18.75c1.03-1.02 2.16-1.99 3.42-2.89-.06-.05.06.19-.15-.17-.21-.36.51-1.87 1.99-2.74 7.76-4.55 26.47-4.43 35.56-2.65z'/%3E%3C/svg%3E");
    opacity: 0.5;
}

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

/* Hide brand/model text when using SVG placeholder */
.vehicle-image:not(:has(img)) {
    color: transparent;
}

.vehicle-info {
    padding: 20px;
}

.vehicle-brand {
    font-size: 12px;
    color: #1A355D;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 8px;
}

.vehicle-name {
    font-size: 18px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 4px;
    line-height: 1.3;
}

.vehicle-variant {
    font-size: 13px;
    color: #6e6e73;
    margin-bottom: 10px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vehicle-meta {
    font-size: 13px;
    color: #86868b;
    margin-bottom: 12px;
}

.vehicle-specs {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.spec-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.spec-value {
    font-size: 14px;
    color: #6e6e73;
}

.view-details {
    color: #1A355D;
    font-size: 14px;
    font-weight: 500;
}

/* FIX #4: Compare Mode Checkbox - Improved Styling */
.compare-checkbox-container {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 10;
}

.compare-checkbox {
    width: 28px;
    height: 28px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    border: 2px solid #fff;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 6px;
    position: relative;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.compare-checkbox:hover {
    background: #fff;
    transform: scale(1.1);
}

.compare-checkbox:checked {
    background: #1A355D;
    border-color: #1A355D;
}

/* Checkmark inside checkbox */
.compare-checkbox:checked::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 18px;
    font-weight: bold;
}

.vehicle-card.selected {
    border: 2px solid #1A355D;
    box-shadow: 0 8px 24px rgba(26, 53, 93, 0.3);
}

.compare-mode-toggle {
    padding: 10px 20px;
    background: #fff;
    border: 1px solid #d2d2d7;
    border-radius: 20px;
    font-size: 14px;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.compare-mode-toggle:hover {
    border-color: #1A355D;
    background: #f5f5f7;
    color: #1A355D;
}

.compare-mode-toggle.active {
    background: #1A355D;
    color: #fff;
    border-color: #1A355D;
}

/* Compare Bar (Fixed at bottom) */
.compare-bar {
    position: fixed;
    bottom: -100px;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 2px solid #1A355D;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.1);
    padding: 20px 40px;
    z-index: 999;
    transition: bottom 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.compare-bar.active {
    bottom: 0;
}

.compare-bar > div {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.compare-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.compare-count {
    font-size: 18px;
    font-weight: 600;
    color: #1d1d1f;
}

.compare-buttons {
    display: flex;
    gap: 12px;
}

.btn-compare {
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    font-family: inherit;
}

.btn-compare-primary {
    background: #1A355D;
    color: #fff;
}

.btn-compare-primary:hover {
    background: #142845;
}

.btn-compare-secondary {
    background: transparent;
    color: #1d1d1f;
    border: 1px solid #d2d2d7;
}

.btn-compare-secondary:hover {
    background: #f5f5f7;
}

/* ===================================
   COMPARE PAGE STYLES
   =================================== */

/* Page Header */
.page-header {
    background: #fff;
    padding: 60px 40px 30px;
    text-align: center;
    border-bottom: 1px solid #d2d2d7;
}

.page-header h1 {
    font-size: 48px;
    font-weight: 700;
    letter-spacing: -1.2px;
    margin-bottom: 16px;
    color: #1d1d1f;
}

.page-header p {
    font-size: 18px;
    color: #6e6e73;
    margin-bottom: 30px;
}

.compare-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: #1A355D;
    color: #fff;
}

.btn-primary:hover {
    background: #142845;
}

.btn-secondary {
    background: #fff;
    color: #1d1d1f;
    border: 1px solid #d2d2d7;
}

.btn-secondary:hover {
    background: #f5f5f7;
}

/* Sticky Vehicle Headers */
.sticky-headers {
    position: sticky;
    top: 73px;
    background: #fff;
    z-index: 900;
    border-bottom: 2px solid #1A355D;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.vehicle-headers-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 40px;
    display: grid;
    grid-template-columns: 180px repeat(4, 1fr);
    gap: 16px;
    align-items: center;
}

.header-spacer {
    /* Empty space for spec labels column */
}

.vehicle-header-compact {
    text-align: center;
}

.vehicle-brand-mini {
    font-size: 11px;
    color: #1A355D;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 4px;
}

.vehicle-name-mini {
    font-size: 15px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 2px;
}

.vehicle-year-mini {
    font-size: 12px;
    color: #6e6e73;
}

/* FIX #6: Remove Button Styling - Clean circular button */
.remove-btn-mini {
    background: #d32f2f;
    color: #fff;
    border: 2px solid #fff;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    margin: 8px auto 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    line-height: 1;
    padding: 0;
}

.remove-btn-mini:hover {
    background: #b71c1c;
    transform: scale(1.1);
}

/* Comparison Section */
.comparison-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 40px 80px;
}

/* Comparison Categories */
.comparison-category {
    background: #fff;
    border-radius: 18px;
    padding: 30px;
    margin-bottom: 20px;
}

.category-title-compare {
    font-size: 21px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f5f5f7;
}

.spec-comparison-row {
    display: grid;
    grid-template-columns: 180px repeat(4, 1fr);
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #f5f5f7;
    align-items: center;
}

.spec-comparison-row:last-child {
    border-bottom: none;
}

.spec-name {
    font-size: 14px;
    color: #6e6e73;
    font-weight: 500;
}

.spec-value-compare {
    font-size: 15px;
    color: #1d1d1f;
    font-weight: 500;
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    transition: all 0.3s;
}

.spec-value-compare.winner {
    background: #E8F5E9;
    color: #2E7D32;
    font-weight: 600;
}

.spec-value-compare.winner::after {
    content: " ⭐";
}

/* Spider Chart Section */
.chart-section {
    background: #fff;
    border-radius: 18px;
    padding: 40px;
    margin: 40px 0;
}

.chart-title {
    font-size: 28px;
    font-weight: 600;
    color: #1d1d1f;
    text-align: center;
    margin-bottom: 40px;
}

.chart-container {
    width: 100%;
    max-width: 900px;
    height: 700px;
    margin: 0 auto;
    position: relative;
}

canvas {
    -moz-osx-font-smoothing: grayscale;
    -webkit-font-smoothing: antialiased;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Legend */
.chart-legend {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.legend-text {
    font-size: 14px;
    color: #1d1d1f;
}

/* Pagination Styles */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.page-number {
    padding: 10px 16px;
    background: #fff;
    border: 1px solid #d2d2d7;
    border-radius: 8px;
    color: #1d1d1f;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
}

.page-number:hover {
    background: #f5f5f7;
    border-color: #1A355D;
}

.page-number.current {
    background: #1A355D;
    color: #fff;
    border-color: #1A355D;
}

.page-number.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ===================================
   RESPONSIVE STYLES
   =================================== */

@media (max-width: 968px) {
    .vehicle-title {
        font-size: 36px;
    }

    .search-hero h1 {
        font-size: 40px;
    }

    .page-header h1 {
        font-size: 36px;
    }

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

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

    .vehicle-headers-grid,
    .spec-comparison-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .spec-name {
        text-align: center;
        font-weight: 600;
        color: #1d1d1f;
        border-bottom: 1px solid #f5f5f7;
        padding-bottom: 8px;
    }

    .sticky-headers {
        top: 61px;
    }

    .chart-container {
        height: 400px;
    }

    .gallery-slide {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .hero-container,
    .filters-section,
    .comparison-section {
        padding-left: 20px;
        padding-right: 20px;
    }

    .search-hero {
        padding: 40px 20px;
    }

    .page-header {
        padding: 40px 20px 20px;
    }

    .vehicle-grid {
        grid-template-columns: 1fr;
        padding-left: 20px;
        padding-right: 20px;
    }

    .action-buttons,
    .compare-actions {
        flex-direction: column;
    }

    .results-info {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }

    .additional-filters {
        justify-content: center;
    }

    .spec-category,
    .comparison-category,
    .chart-section {
        padding: 20px;
    }

    .vehicle-headers-grid {
        padding: 16px 20px;
    }
}

/* ===================================
   FOOTER STYLES
   =================================== */

.drivinstats-footer {
    background: #1d1d1f;
    color: #fff;
    padding: 60px 40px 30px;
    margin-top: 80px;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 60px;
    flex-wrap: wrap;
}

.footer-brand {
    max-width: 400px;
}

.footer-logo {
    display: inline-block;
    margin-bottom: 16px;
}

.footer-logo-img {
    height: 32px;
    width: auto;
    filter: brightness(0) invert(1);
}

.footer-tagline {
    font-size: 14px;
    color: #86868b;
    line-height: 1.6;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 80px;
}

.footer-column h4 {
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

.footer-column ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-column li {
    margin-bottom: 12px;
}

.footer-column a {
    color: #86868b;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: #fff;
}

.footer-bottom {
    max-width: 1400px;
    margin: 40px auto 0;
    padding-top: 30px;
    border-top: 1px solid #424245;
    text-align: center;
}

.footer-bottom p {
    font-size: 13px;
    color: #86868b;
    margin: 0;
}

/* Homepage footer override (simpler version) */
.homepage-footer {
    background: #1d1d1f;
    padding: 40px;
    text-align: center;
}

.footer-content-main {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-tagline-main {
    font-size: 14px;
    color: #86868b;
    margin-bottom: 8px;
}

.footer-text-main {
    font-size: 13px;
    color: #6e6e73;
    margin: 0;
}

@media (max-width: 768px) {
    .drivinstats-footer {
        padding: 40px 20px 20px;
    }
    
    .footer-container {
        flex-direction: column;
        gap: 40px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 30px;
    }
    
    .footer-column h4 {
        margin-bottom: 12px;
    }
}

/* ===================================
   FLOATING COMPARE BAR - GLOBAL
   =================================== */

.floating-compare-bar {
    position: fixed !important;
    bottom: -100px !important;
    left: 0 !important;
    right: 0 !important;
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid #d2d2d7;
    box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.15);
    z-index: 99999 !important;
    transition: bottom 0.3s ease;
    padding: 10px 0;
}

.floating-compare-bar.active {
    bottom: 0 !important;
}

.compare-bar-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.compare-bar-vehicles {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    flex: 1;
}

.compare-vehicle-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #f5f5f7;
    border: 1px solid #d2d2d7;
    border-radius: 16px;
    padding: 5px 8px 5px 12px;
    font-size: 12px;
    color: #1d1d1f;
    max-width: 200px;
}

.compare-vehicle-pill .pill-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.compare-vehicle-pill .pill-remove {
    background: #d2d2d7;
    border: none;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 10px;
    color: #6e6e73;
    transition: all 0.2s;
    flex-shrink: 0;
    line-height: 1;
    padding: 0;
}

.compare-vehicle-pill .pill-remove:hover {
    background: #c62828;
    color: #fff;
}

.compare-bar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.compare-bar-actions .compare-count {
    font-size: 12px;
    color: #6e6e73;
    font-weight: 500;
}

.btn-compare-now {
    padding: 12px 24px;
    background: #0071e3;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.btn-compare-now:hover {
    background: #0077ED;
    transform: translateY(-1px);
}

.btn-clear-compare {
    padding: 12px 20px;
    background: transparent;
    color: #6e6e73;
    border: 1px solid #d2d2d7;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.btn-clear-compare:hover {
    background: #f5f5f7;
    color: #1d1d1f;
    border-color: #1d1d1f;
}

/* Responsive floating bar */
@media (max-width: 768px) {
    .floating-compare-bar {
        padding: 8px 0;
    }
    
    .compare-bar-content {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 0 12px;
        gap: 8px;
    }
    
    .compare-bar-vehicles {
        display: none; /* Hide individual pills on mobile to save space */
    }
    
    .compare-bar-actions {
        width: 100%;
        justify-content: space-between;
    }
    
    .compare-bar-actions .compare-count {
        font-size: 11px;
    }
    
    .btn-compare-now {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .btn-clear-compare {
        padding: 8px 12px;
        font-size: 12px;
    }
}

/* ===================================
   ASTRA THEME FIXES - GLOBAL
   =================================== */

/* Remove light blue/gray background from Astra content areas */
#content.site-content,
.site-content,
.ast-container,
#primary,
#main,
.content-area,
.site-main {
    background: transparent !important;
    background-color: transparent !important;
}

/* Fix for page templates */
body.page #content.site-content,
body.page .ast-container,
body.archive #content.site-content,
body.archive .ast-container {
    background: transparent !important;
    padding: 0 !important;
}

/* Ensure consistent background across all pages */
body {
    background: #f5f5f7 !important;
}

/* Remove any Astra spacing that might cause visual gaps */
.ast-separate-container #primary {
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
}

.ast-separate-container .ast-article-single,
.ast-separate-container .ast-article-post {
    background: transparent !important;
    padding: 0 !important;
}

/* Remove Astra's default entry content styling */
.entry-content {
    background: transparent !important;
}

/* Fix for homepage specifically */
body.home #content.site-content,
body.home .site-content {
    background: transparent !important;
}

/* ===================================
   COMPARE PAGE - VEHICLE CARDS
   =================================== */

.compare-current-vehicles {
    display: grid;
    grid-template-columns: 180px repeat(4, 1fr);
    gap: 0;
    max-width: 1200px;
    margin: 0 auto 0;
    padding: 20px 40px;
    position: sticky;
    top: 70px; /* Account for header height */
    background: #f5f5f7;
    z-index: 100;
    border-bottom: 1px solid #e5e5e7;
}

/* Empty first column to align with table labels */
.compare-current-vehicles::before {
    content: '';
    display: block;
}

.compare-vehicle-card {
    background: #fff;
    border-radius: 12px;
    padding: 12px 8px;
    text-align: center;
    border: 1px solid #e5e5e7;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    margin: 0 8px;
}

.compare-vehicle-card .remove-vehicle {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 18px;
    height: 18px;
    background: #86868b;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    padding: 0;
}

.compare-vehicle-card .remove-vehicle:hover {
    background: #c62828;
}

.compare-vehicle-card .vehicle-brand {
    font-size: 9px;
    font-weight: 600;
    color: #1A355D;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
    margin-top: 2px;
}

.compare-vehicle-card .vehicle-name {
    font-size: 13px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 2px;
    line-height: 1.2;
}

.compare-vehicle-card .vehicle-generation {
    font-size: 11px;
    font-weight: 500;
    color: #6e6e73;
    margin-bottom: 2px;
    line-height: 1.2;
}

.compare-vehicle-card .vehicle-meta {
    font-size: 10px;
    color: #86868b;
}

.compare-add-card {
    background: #fff;
    border: 2px dashed #d2d2d7;
    border-radius: 12px;
    padding: 16px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 8px;
}

.compare-add-card:hover {
    border-color: #1A355D;
    background: #f5f5f7;
}

.compare-add-card .add-icon {
    font-size: 24px;
    color: #1A355D;
    margin-bottom: 4px;
}

.compare-add-card .add-text {
    font-size: 12px;
    font-weight: 500;
    color: #6e6e73;
}

/* Compare page responsive */
@media (max-width: 1024px) {
    .compare-current-vehicles {
        grid-template-columns: 140px repeat(4, 1fr);
        padding: 16px 20px;
    }
}

/* Mobile: Disable sticky and simplify layout */
@media (max-width: 768px) {
    .compare-current-vehicles {
        position: relative;
        top: 0;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 12px;
        border-bottom: none;
    }
    
    .compare-current-vehicles::before {
        display: none;
    }
    
    .compare-vehicle-card {
        margin: 0;
        padding: 10px 6px;
    }
    
    .compare-vehicle-card .remove-vehicle {
        width: 16px;
        height: 16px;
        font-size: 10px;
        top: 4px;
        right: 4px;
    }
    
    .compare-vehicle-card .vehicle-brand {
        font-size: 8px;
        margin-top: 0;
    }
    
    .compare-vehicle-card .vehicle-name {
        font-size: 11px;
    }
    
    .compare-vehicle-card .vehicle-generation {
        font-size: 9px;
    }
    
    .compare-vehicle-card .vehicle-meta {
        font-size: 8px;
    }
    
    .compare-add-card {
        margin: 0;
        padding: 10px 6px;
    }
    
    .compare-add-card .add-icon {
        font-size: 18px;
    }
    
    .compare-add-card .add-text {
        font-size: 10px;
    }
    
    /* Hide floating compare bar on compare page on mobile */
    .page-template-page-compare .compare-bar,
    .page-compare .compare-bar,
    .page-template-page-compare .floating-compare-bar,
    .page-compare .floating-compare-bar {
        display: none !important;
    }
}

/* ===================================
   SEARCHABLE DROPDOWNS
   =================================== */

.dropdown-search-wrapper {
    padding: 8px;
    border-bottom: 1px solid #e5e5e7;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
}

.dropdown-search-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d2d2d7;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s;
}

.dropdown-search-input:focus {
    border-color: #1A355D;
}

.dropdown-search-input::placeholder {
    color: #86868b;
}

.dropdown-item.hidden {
    display: none !important;
}

/* Improve dropdown menu for search */
.dropdown-menu {
    max-height: 350px;
    overflow-y: auto;
}
