/* ===== SOLUCIÓN DEFINITIVA PARA FILTRO FIJO Y PEGADO ===== */

/* Page Header ajustado */
.page-header {
    background: #f8f9fa;
    padding: 20px 0 0px; /* SIN padding inferior */
    margin-top: 80px;
    border-bottom: none;
    position: relative;
    z-index: 100;
}

.page-header .container-full {
    max-width: 100%;
    padding: 0 20px;
    margin: 0 auto;
}

/* ===== CATEGORIES CONTAINER - STICKY EN LUGAR DE FIXED ===== */
.categories-container-full {
    display: grid !important;
    grid-template-columns: repeat(6, 1fr) !important;
    gap: 0 !important;
    margin: 0 !important;
    padding: 10px 0 !important;
    background: var(--primary-white) !important;
    
    /* STICKY - FUNCIONA MEJOR QUE FIXED */
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 80px !important;
    z-index: 998 !important;
    
    /* Ancho completo */
    width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    
    /* Bordes y sombra */
    border-top: 1px solid #e5e7eb !important;
    border-bottom: 2px solid #e5e7eb !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1) !important;
}

/* Cada botón de categoría */
.category-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 6px 4px !important;
    background: var(--primary-white) !important;
    border-right: 1px solid #e5e7eb !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    text-align: center !important;
    position: relative !important;
    height: auto !important;
    min-height: 50px !important;
}

.category-item:last-child {
    border-right: none !important;
}

/* Estados hover y active */
.category-item:hover {
    background: #f8f9fa !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 2px 8px rgba(61, 95, 172, 0.1) !important;
}

.category-item.active {
    background: var(--primary-white) !important;
    color: var(--primary-black) !important;
    border: 2px solid var(--primary-blue) !important;
    box-shadow: 0 0 0 1px var(--primary-blue) !important;
}

/* Imagen/icono */
.category-image {
    width: 28px !important;
    height: 22px !important;
    margin-bottom: 4px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.category-photo {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    transition: transform 0.3s ease !important;
}

.category-item:hover .category-photo {
    transform: scale(1.1) !important;
}

.category-item.active .category-photo {
    transform: scale(1.05) !important;
}

/* Información de texto */
.category-info {
    display: flex !important;
    flex-direction: column !important;
    gap: 1px !important;
}

.category-name {
    font-size: 0.7rem !important;
    font-weight: 600 !important;
    color: var(--primary-black) !important;
    line-height: 1.1 !important;
    margin: 0 !important;
}

.category-item.active .category-name {
    font-weight: 700 !important;
}

.category-count {
    font-size: 0.6rem !important;
    color: var(--secondary-gray) !important;
    line-height: 1 !important;
    margin: 0 !important;
}

.category-item.active .category-count {
    color: var(--primary-blue) !important;
    font-weight: 600 !important;
}

/* ===== CONTENIDO PEGADO A CATEGORÍAS ===== */
.content-section-full {
    padding: 0 !important;
    background: var(--primary-white) !important;
    margin-top: 0 !important;
}

.content-layout-full {
    display: grid !important;
    grid-template-columns: 280px 1fr !important;
    max-width: 100% !important;
    margin: 0 !important;
    gap: 0 !important;
}

.sidebar-filters-full {
    background: #f8f9fa !important;
    border-right: 1px solid #e5e7eb !important;
    padding: 20px !important;
    overflow-y: auto !important;
    height: calc(100vh - 160px) !important;
    position: sticky !important;
    top: 150px !important;
}

.main-content-full {
    padding: 0px 20px 20px 20px !important;
    background: var(--primary-white) !important;
    overflow: visible !important;
}

/* ===== AJUSTES PARA RESULTS HEADER ===== */
.results-header {
    margin-top: 10px !important;
    margin-bottom: 15px !important;
    padding-bottom: 15px !important;
    border-bottom: 1px solid #e5e7eb !important;
}

/* ===== NUEVO DISEÑO DE VEHICLES GRID - ESTILO COMPACTO ===== */
.vehicles-grid-clean {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 1px !important; /* GAP MÍNIMO PARA CREAR SEPARACIÓN VISUAL */
    margin-bottom: 30px !important;
    padding: 0 !important;
    background: #e5e7eb !important; /* FONDO GRIS PARA SIMULAR BORDES */
    border: 1px solid #e5e7eb !important;
}

/* ===== VEHICLE CARD - DISEÑO  ===== */
.vehicle-card {
    background: var(--primary-white) !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
    position: relative !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 380px !important;
}

.vehicle-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12) !important;
    transform: translateY(-4px) !important;
    border-color: var(--primary-blue) !important;
}

/* ===== ELIMINAR BADGES AMARILLOS ===== */
.vehicle-status,
.vehicle-featured {
    display: none !important;
}

/* ===== IMAGEN DEL VEHÍCULO ===== */
.vehicle-image {
    position: relative !important;
    height: 180px !important;
    overflow: hidden !important;
    background: #f8f9fa !important;
    flex-shrink: 0 !important;
}

.vehicle-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    transition: transform 0.3s ease !important;
}

.vehicle-card:hover .vehicle-image img {
    transform: scale(1.08) !important;
}

/* ===== CONTENIDO DEL VEHÍCULO ===== */
.vehicle-content {
    padding: 16px !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
}

/* ===== TÍTULO Y SUBTÍTULO ===== */
.vehicle-title {
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    color: var(--primary-black) !important;
    margin: 0 !important;
    line-height: 1.3 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
}

.vehicle-subtitle {
    font-size: 0.85rem !important;
    color: #6b7280 !important;
    margin: 0 !important;
    font-weight: 500 !important;
}

/* ===== ESPECIFICACIONES CON ICONOS ===== */
.vehicle-specs {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
}

.vehicle-spec {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 0.8rem !important;
    color: #4b5563 !important;
}

.vehicle-spec-icon {
    width: 16px !important;
    height: 16px !important;
    flex-shrink: 0 !important;
    opacity: 0.7 !important;
}

.vehicle-spec-value {
    font-weight: 600 !important;
    color: var(--primary-black) !important;
    font-size: 0.8rem !important;
}

/* ===== FOOTER CON UBICACIÓN ===== */
.vehicle-footer {
    padding: 12px 16px !important;
    background: #f8f9fa !important;
    border-top: 1px solid #e5e7eb !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.vehicle-location {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    font-size: 0.8rem !important;
    color: #6b7280 !important;
}

.location-icon {
    width: 14px !important;
    height: 14px !important;
    opacity: 0.7 !important;
}

/* ===== ACCIONES (CONSULTAR + PRECIO) ===== */
/* ===== BOTÓN CONSULTAR - IDÉNTICO AL DE DETALLE ===== */
.vehicle-actions {
    padding: 15px 18px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    border-top: 1px solid #e5e7eb !important;
    background: white !important;
}

.btn-consult {
    background: white !important;
    color: #1a202c !important;
    border: 2px solid #e2e8f0 !important;
    padding: 8px 20px !important;
    font-size: 0.8rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    border-radius: 4px !important;
    width: auto !important;
    min-width: 180px !important;
    text-align: center !important;
}

.btn-consult:hover {
    color: var(--primary-blue) !important;
    border-color: var(--primary-blue) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 2px 8px rgba(61, 95, 172, 0.15) !important;
}

.vehicle-price {
    display: none !important;
}

/* ===== CÓDIGO DEL VEHÍCULO ===== */
.vehicle-code {
    padding: 8px 16px !important;
    text-align: center !important;
    font-size: 0.75rem !important;
    color: #9ca3af !important;
    background: #fafafa !important;
    border-top: 1px solid #e5e7eb !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .vehicle-card {
        min-height: 350px !important;
    }
    
    .vehicle-image {
        height: 150px !important;
    }
    
    .vehicle-title {
        font-size: 0.95rem !important;
    }
}

@media (max-width: 480px) {
    .vehicle-specs {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}
/* ===== FILTROS COLAPSABLES - MÁS COMPACTOS ===== */
.filter-group {
    margin-bottom: 12px; /* REDUCIDO de 15px */
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #ffffff;
    overflow: hidden;
    transition: all 0.3s ease;
}

.filter-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.9rem; /* REDUCIDO de 0.95rem */
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    padding: 10px 14px; /* REDUCIDO de 12px 16px */
    cursor: pointer;
    background: #ffffff;
    border: none;
    width: 100%;
    text-align: left;
    transition: all 0.3s ease;
    user-select: none;
    min-height: 40px; /* AÑADIDO: altura máxima controlada */
}

.filter-title:hover {
    background: #f8f9fa;
}

/* OCULTAR SOLO LOS ICONOS DENTRO DEL SPAN (emoticones) */
.filter-title span i {
    display: none !important;
}

/* FLECHA DE COLAPSO - MÁS PEQUEÑA */
.collapse-icon {
    font-size: 0.85rem !important; /* REDUCIDO de 0.9rem */
    color: #3D5FAC !important;
    transition: transform 0.3s ease !important;
    transform: rotate(0deg) !important;
    display: inline-block !important;
    margin-left: auto !important;
}

/* CONTENIDO COLAPSADO POR DEFECTO */
.filter-content {
    max-height: 0 !important;
    overflow: hidden !important;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    background: #ffffff;
}

/* ESTADO EXPANDIDO */
.filter-group.expanded .filter-content {
    max-height: 500px !important;
    overflow: visible !important;
}

.filter-group.expanded .collapse-icon {
    transform: rotate(180deg) !important;
}

.filter-group.expanded .filter-title {
    background: #f8f9fa;
    border-bottom: 1px solid #e5e7eb;
}

/* ===== CONTENIDO DE FILTROS ===== */
.filter-options {
    padding: 15px 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 8px 0;
    transition: all 0.3s ease;
    position: relative;
}

.filter-checkbox:hover {
    background: rgba(61, 95, 172, 0.05);
    border-radius: 4px;
    padding-left: 6px;
    margin-left: -6px;
}

.filter-checkbox input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #d1d5db;
    border-radius: 4px;
    margin-right: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    position: relative;
    background: #ffffff;
}

.filter-checkbox input[type="checkbox"]:checked {
    background-color: #3D5FAC;
    border-color: #3D5FAC;
}

.filter-checkbox input[type="checkbox"]:checked::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.option-text {
    font-size: 0.9rem;
    color: #1a1a1a;
    flex: 1;
}

/* ===== BÚSQUEDA - SIEMPRE FONDO BLANCO ===== */
.filter-search {
    margin-bottom: 20px; /* REDUCIDO de 25px */
    padding: 0;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #ffffff !important; /* SIEMPRE BLANCO */
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    padding: 0 14px; /* REDUCIDO de 16px */
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    min-height: 48px; /* ALTURA CONTROLADA */
}

.search-input-wrapper:hover {
    border-color: #d1d5db;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
    background: #ffffff !important; /* MANTENER BLANCO */
}

.search-input-wrapper:focus-within {
    border-color: #3D5FAC !important;
    box-shadow: 
        0 0 0 3px rgba(61, 95, 172, 0.15),
        0 4px 12px rgba(61, 95, 172, 0.2);
    background: #ffffff !important; /* MANTENER BLANCO, NO GRIS */
}

.search-icon {
    color: #3D5FAC !important;
    font-size: 1rem; /* REDUCIDO de 1.1rem */
    margin-right: 10px; /* REDUCIDO de 12px */
    transition: all 0.3s ease;
    opacity: 0.7;
}

.search-input-wrapper:focus-within .search-icon {
    opacity: 1;
    transform: scale(1.1);
}

.filter-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px 0; /* REDUCIDO de 14px */
    font-size: 0.9rem; /* REDUCIDO de 0.95rem */
    background: transparent;
    color: #1a1a1a !important;
    font-weight: 500;
}

.filter-search-input::placeholder {
    color: #9ca3af !important;
    font-weight: 400;
}

.clear-icon {
    color: #9ca3af;
    font-size: 0.95rem; /* REDUCIDO de 1rem */
    cursor: pointer;
    padding: 5px; /* REDUCIDO de 6px */
    border-radius: 50%;
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
}

.clear-icon.show {
    opacity: 1 !important;
    visibility: visible !important;
    transform: scale(1) !important;
}

.clear-icon:hover {
    background: #fee2e2;
    color: #ef4444;
}

/* ELIMINAR ESTADOS DE COLOR DE FONDO */
.search-input-wrapper.has-text {
    border-color: #3D5FAC;
    box-shadow: 0 0 0 2px rgba(61, 95, 172, 0.1);
    background: #ffffff !important; /* MANTENER BLANCO */
}

/* ELIMINAR ESTOS ESTADOS SI EXISTEN */
.search-input-wrapper.searching,
.search-input-wrapper.has-results,
.search-input-wrapper.no-results {
    background: #ffffff !important; /* SIEMPRE BLANCO */
    border-color: #3D5FAC;
}

/* ===== FILTROS DE RANGO - DISEÑO COMPACTO Y CENTRADO ===== */
.range-filter {
    padding: 18px 15px;
    background: #ffffff;
}

.range-inputs {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
}

.range-input {
    flex: 1;
    padding: 10px 8px;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-size: 0.85rem;
    background: #f9fafb;
    transition: all 0.3s ease;
    color: #1a1a1a;
    font-weight: 500;
    text-align: center;
    width: 100%;
    max-width: 110px;
}

.range-input:focus {
    outline: none;
    border-color: #3D5FAC;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(61, 95, 172, 0.1);
}

.range-input::placeholder {
    color: #9ca3af;
    opacity: 0.8;
    font-weight: 400;
    font-size: 0.8rem;
}

.range-separator {
    color: #6b7280;
    font-weight: 700;
    font-size: 1.1rem;
    flex-shrink: 0;
    margin: 0 4px;
}

/* ===== SLIDER CON INDICADOR DE VALOR ===== */
.range-slider {
    margin: 20px 0 12px 0;
    position: relative;
    padding-top: 35px;
}

/* Tooltip con el valor actual */
.range-slider::before {
    content: attr(data-value);
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    background: #3D5FAC;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(61, 95, 172, 0.3);
}

.range-slider:hover::before,
.range-slider.active::before {
    opacity: 1;
}

.slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e5e7eb;
    outline: none;
    transition: all 0.3s ease;
    position: relative;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #3D5FAC;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(61, 95, 172, 0.4);
    border: 3px solid #ffffff;
}

.slider::-webkit-slider-thumb:hover {
    background: #2a4490;
    transform: scale(1.2);
    box-shadow: 0 4px 10px rgba(61, 95, 172, 0.6);
}

.slider::-webkit-slider-thumb:active {
    transform: scale(1.3);
    box-shadow: 0 0 0 8px rgba(61, 95, 172, 0.2);
}

.slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #3D5FAC;
    cursor: pointer;
    border: 3px solid #ffffff;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(61, 95, 172, 0.4);
}

.slider::-moz-range-thumb:hover {
    background: #2a4490;
    transform: scale(1.2);
    box-shadow: 0 4px 10px rgba(61, 95, 172, 0.6);
}

.slider::-moz-range-thumb:active {
    transform: scale(1.3);
    box-shadow: 0 0 0 8px rgba(61, 95, 172, 0.2);
}

.slider::-moz-range-track {
    background: #e5e7eb;
    border-radius: 3px;
    height: 6px;
}

/* ===== LABELS DEL RANGO ===== */
.range-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    padding: 0 2px;
}

.range-label-min,
.range-label-max {
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 600;
    background: #f9fafb;
    padding: 3px 8px;
    border-radius: 4px;
    border: 1px solid #e5e7eb;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .range-filter {
        padding: 15px 12px;
    }
    
    .range-input {
        padding: 9px 6px;
        font-size: 0.8rem;
        max-width: 100px;
    }
    
    .range-separator {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .range-filter {
        padding: 14px 10px;
    }
    
    .range-input {
        padding: 8px 5px;
        font-size: 0.75rem;
        max-width: 90px;
    }
    
    .range-inputs {
        gap: 6px;
    }
    
    .range-separator {
        font-size: 0.9rem;
        margin: 0 2px;
    }
    
    .slider {
        height: 5px;
    }
    
    .slider::-webkit-slider-thumb {
        width: 18px;
        height: 18px;
    }
    
    .slider::-moz-range-thumb {
        width: 18px;
        height: 18px;
    }
}

/* Results Header */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e5e7eb;
}

.results-tabs {
    display: flex;
    gap: 2px;
}

.tab-btn {
    padding: 10px 16px;
    background: #f8f9fa;
    border: none;
    border-radius: 6px 6px 0 0;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    color: var(--secondary-gray);
}

.tab-btn.active {
    background: var(--primary-white);
    color: var(--primary-black);
    border-bottom: 2px solid var(--primary-blue);
}

.tab-btn:hover:not(.active) {
    background: #e5e7eb;
}

/* Sort Dropdown */
.sort-dropdown {
    position: relative;
}

.sort-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--primary-white);
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    color: var(--primary-black);
}

.sort-btn:hover {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 2px rgba(61, 95, 172, 0.1);
}

.sort-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--primary-white);
    border: 1px solid #d1d5db;
    border-radius: 6px;
    box-shadow: var(--shadow-medium);
    z-index: 100;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition-fast);
}

.sort-dropdown:hover .sort-menu,
.sort-dropdown.open .sort-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sort-option {
    display: block;
    width: 100%;
    padding: 10px 16px;
    background: none;
    border: none;
    text-align: left;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    color: var(--primary-black);
}

.sort-option:hover {
    background: #f8f9fa;
}

.sort-option.active {
    background: var(--primary-blue);
    color: var(--primary-white);
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--secondary-gray);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #f8f9fa;
    border-top: 3px solid var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Load More Button */
.load-more-container {
    text-align: center;
    padding: 20px 0;
}

.load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--primary-white);
    border: 1px solid var(--primary-blue);
    border-radius: 6px;
    color: var(--primary-blue);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-fast);
}

.load-more-btn:hover {
    background: var(--primary-blue);
    color: var(--primary-white);
}

.load-more-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===== ARREGLO PARA IMÁGENES FALTANTES ===== */
.vehicle-spec-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    font-size: 14px;
    text-align: center;
}

.icon-calendar::before {
    content: "📅";
}

.icon-road::before {
    content: "🛣️";
}

.icon-gear::before {
    content: "⚙️";
}

.icon-power::before {
    content: "🔋";
}

/* Estados de carga y error */
.empty-state, .error-state, .connection-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    color: #666;
    grid-column: 1 / -1;
}

.empty-icon, .error-icon {
    font-size: 48px;
    margin-bottom: 20px;
    color: #ccc;
}

.btn-retry {
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 20px;
    transition: background 0.3s ease;
    font-weight: 600;
}

.btn-retry:hover {
    background: var(--secondary-dark-blue);
    transform: translateY(-2px);
}

.btn-retry.secondary {
    background: #6c757d;
    margin-left: 10px;
}

.btn-retry.secondary:hover {
    background: #495057;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1200px) {
    .categories-container-full {
        grid-template-columns: repeat(6, 1fr);
    }
    
    .category-item {
        min-height: 75px;
        padding: 12px 6px;
    }
    
    .category-image {
        width: 30px;
        height: 24px;
    }
    
    .category-name {
        font-size: 0.75rem;
    }
    
    .category-count {
        font-size: 0.65rem;
    }
    
    .content-layout-full {
        grid-template-columns: 260px 1fr;
    }
    
    .sidebar-filters-full {
        padding: 15px;
    }
    
    .vehicles-grid,
    .vehicles-grid-clean {
        grid-template-columns: repeat(3, 1fr) !important;
    }
    
    .brands-track {
        gap: 35px;
    }
    
    .brand-logo {
        height: 45px;
        max-width: 110px;
        margin: 8px;
    }
}

@media (max-width: 992px) {
    .brands {
        padding: 50px 0;
    }
    
    .brands-track {
        gap: 30px;
    }
    
    .brand-logo {
        height: 42px;
        max-width: 100px;
        margin: 6px;
    }
    
    .brand-logo[alt="Randon"] {
        height: 38px;
        max-width: 90px;
    }
}

@media (max-width: 768px) {
    .categories-container-full {
        grid-template-columns: repeat(3, 1fr);
        margin-left: 0;
        width: 100%;
    }
    
    .category-item {
        min-height: 70px;
        padding: 10px 4px;
    }
    
    .category-image {
        width: 28px;
        height: 22px;
    }
    
    .category-name {
        font-size: 0.7rem;
    }
    
    .category-count {
        font-size: 0.6rem;
    }
    
    .content-layout-full {
        grid-template-columns: 1fr;
    }
    
    .sidebar-filters-full {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        max-width: 320px;
        height: 100vh;
        z-index: 1001;
        transition: left 0.3s ease;
        border-right: none;
        box-shadow: 2px 0 15px rgba(0, 0, 0, 0.3);
        overflow-y: auto;
    }

    .sidebar-filters-full.active {
        left: 0;
    }

    .main-content-full {
        padding: 15px;
        width: 100%;
    }

    .vehicles-grid,
    .vehicles-grid-clean {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 1px !important;
    }
    
    .vehicle-card {
        min-height: 320px !important;
    }

    .vehicle-image {
        height: 160px !important;
    }

    .vehicle-content {
        padding: 12px !important;
    }

    .vehicle-title {
        font-size: 0.95rem !important;
        line-height: 1.3 !important;
        margin-bottom: 8px !important;
    }

    .vehicle-subtitle {
        font-size: 0.8rem !important;
        margin-bottom: 10px !important;
    }

    .vehicle-specs {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
        margin-bottom: 10px !important;
    }

    .vehicle-spec {
        font-size: 0.75rem !important;
        padding: 6px !important;
    }

    .vehicle-spec-value {
        font-size: 0.75rem !important;
    }

    .vehicle-spec-icon {
        width: 14px !important;
        height: 14px !important;
    }

    .vehicle-location {
        font-size: 0.75rem !important;
    }

    .vehicle-price {
        font-size: 1rem !important;
        font-weight: 700 !important;
    }

    .btn-consult {
        font-size: 0.85rem !important;
        padding: 10px 16px !important;
    }
    
    .search-input-wrapper {
        padding: 0 15px;
        border-radius: 14px;
    }
    
    .filter-search-input {
        padding: 14px 0;
        font-size: 0.9rem;
    }
    
    .search-icon {
        font-size: 1rem;
        margin-right: 10px;
    }
    
    .range-input {
        padding: 8px 10px;
        font-size: 0.85rem;
    }
    
    .slider::-webkit-slider-thumb {
        width: 18px;
        height: 18px;
    }
    
    .slider::-moz-range-thumb {
        width: 18px;
        height: 18px;
    }
    
    .brands {
        padding: 40px 0;
    }
    
    .brands-track {
        gap: 25px;
        justify-content: center;
    }
    
    .brand-logo {
        height: 38px;
        max-width: 90px;
        min-width: 60px;
        margin: 5px;
    }
    
    .brand-logo[alt="Randon"] {
        height: 35px;
        max-width: 80px;
    }
    
    .brand-logo[alt="Mercedes-Benz"],
    .brand-logo[alt="Volkswagen"] {
        max-width: 85px;
    }
}

@media (max-width: 480px) {
    .categories-container-full {
        grid-template-columns: repeat(2, 1fr);
    }

    .category-item {
        min-height: 65px;
        padding: 8px 3px;
    }

    .category-image {
        width: 25px;
        height: 20px;
    }

    .category-name {
        font-size: 0.65rem;
    }

    .category-count {
        font-size: 0.55rem;
    }

    .sidebar-filters-full {
        width: 90%;
        max-width: 300px;
    }

    .main-content-full {
        padding: 10px;
    }

    .vehicles-grid,
    .vehicles-grid-clean {
        grid-template-columns: 1fr !important;
        gap: 1px !important;
    }

    .vehicle-card {
        min-height: 380px !important;
    }

    .vehicle-image {
        height: 180px !important;
    }

    .vehicle-content {
        padding: 14px !important;
    }

    .vehicle-title {
        font-size: 1rem !important;
        line-height: 1.3 !important;
        margin-bottom: 10px !important;
    }

    .vehicle-subtitle {
        font-size: 0.85rem !important;
        margin-bottom: 12px !important;
    }

    .vehicle-specs {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px !important;
        margin-bottom: 12px !important;
    }

    .vehicle-spec {
        font-size: 0.75rem !important;
        padding: 6px !important;
    }

    .vehicle-spec-value {
        font-size: 0.8rem !important;
    }

    .vehicle-spec-icon {
        width: 16px !important;
        height: 16px !important;
    }

    .vehicle-location {
        font-size: 0.8rem !important;
    }

    .vehicle-price {
        font-size: 1.1rem !important;
        font-weight: 700 !important;
    }

    .btn-consult {
        font-size: 0.9rem !important;
        padding: 12px 20px !important;
    }
    
    .search-input-wrapper {
        padding: 0 12px;
        border-radius: 12px;
    }
    
    .filter-search-input {
        padding: 12px 0;
        font-size: 0.85rem;
    }
    
    .brands {
        padding: 30px 0;
        margin: 20px 0 0 0;
    }
    
    .brands-track {
        gap: 20px;
        justify-content: center;
        max-width: 100%;
    }
    
    .brand-logo {
        height: 35px;
        max-width: 80px;
        min-width: 50px;
        margin: 4px;
    }
    
    .brand-logo[alt="Randon"] {
        height: 32px;
        max-width: 70px;
    }
}

/* ===== FOCUS PARA ACCESIBILIDAD ===== */
.category-item:focus,
.vehicle-card:focus,
.filter-title:focus,
.sort-btn:focus,
.tab-btn:focus {
    outline: 2px solid var(--primary-blue);
    outline-offset: 2px;
}

/* ===== TRANSICIONES SUAVES ===== */
.category-item,
.vehicle-card,
.filter-group {
    will-change: transform, box-shadow;
}

/* ===== EFECTOS DE CARGA ===== */
.category-item {
    opacity: 0;
    animation: fadeInUp 0.4s ease forwards;
}

.category-item:nth-child(1) { animation-delay: 0.1s; }
.category-item:nth-child(2) { animation-delay: 0.15s; }
.category-item:nth-child(3) { animation-delay: 0.2s; }
.category-item:nth-child(4) { animation-delay: 0.25s; }
.category-item:nth-child(5) { animation-delay: 0.3s; }
.category-item:nth-child(6) { animation-delay: 0.35s; }

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

/* ===== EFECTOS DE ANIMACIÓN PARA CARDS ===== */
.vehicle-card {
    opacity: 0;
    animation: fadeInScale 0.5s ease forwards;
}

.vehicle-card:nth-child(1) { animation-delay: 0.05s; }
.vehicle-card:nth-child(2) { animation-delay: 0.1s; }
.vehicle-card:nth-child(3) { animation-delay: 0.15s; }
.vehicle-card:nth-child(4) { animation-delay: 0.2s; }
.vehicle-card:nth-child(5) { animation-delay: 0.25s; }
.vehicle-card:nth-child(6) { animation-delay: 0.3s; }
.vehicle-card:nth-child(7) { animation-delay: 0.35s; }
.vehicle-card:nth-child(8) { animation-delay: 0.4s; }

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

.filter-search {
    opacity: 0;
    animation: fadeInDown 0.6s ease forwards;
}

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

/* ===== OVERLAY PARA SIDEBAR MÓVIL ===== */
.filter-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.filter-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ===== MOBILE FILTER TOGGLE BUTTON ===== */
.mobile-filter-toggle {
    display: none;
    background: var(--primary-blue);
    color: var(--primary-white);
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 15px;
    align-items: center;
    gap: 8px;
    transition: var(--transition-fast);
}

.mobile-filter-toggle:hover {
    background: var(--secondary-dark-blue);
}

.mobile-filter-toggle i {
    font-size: 1rem;
}

@media (max-width: 768px) {
    .mobile-filter-toggle {
        display: flex;
    }
}

/* ===== ESTILOS PARA NO RESULTS ===== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: var(--secondary-gray);
    grid-column: 1 / -1;
}

.no-results h3 {
    font-size: 1.5rem;
    color: var(--primary-black);
    margin-bottom: 10px;
}

.no-results p {
    font-size: 1rem;
    line-height: 1.6;
}

/* ===== MEJORAS ADICIONALES PARA HOVER ===== */
.vehicle-card:hover .vehicle-title {
    color: var(--primary-blue) !important;
}

.vehicle-card:hover .vehicle-spec i {
    color: var(--secondary-dark-blue) !important;
}

/* ===== ESTILOS PARA BREADCRUMB ===== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    font-size: 0.9rem;
    color: var(--secondary-gray);
}

.breadcrumb a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: var(--transition-fast);
}

.breadcrumb a:hover {
    color: var(--secondary-dark-blue);
    text-decoration: underline;
}

.separator {
    color: var(--secondary-gray);
    font-weight: 300;
}

.current {
    color: var(--primary-black);
    font-weight: 600;
}

/* ===== PRINT STYLES ===== */
@media print {
    .sidebar-filters-full,
    .mobile-filter-toggle,
    .filter-overlay,
    .categories-container-full,
    .results-header {
        display: none !important;
    }
    
    .content-layout-full {
        grid-template-columns: 1fr !important;
    }
    
    .vehicles-grid,
    .vehicles-grid-clean {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        background: transparent !important;
        border: none !important;
    }
    
    .vehicle-card {
        border: 1px solid #000 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        break-inside: avoid !important;
    }
    
    .vehicle-card:hover {
        transform: none !important;
        box-shadow: none !important;
    }
}

/* ===== HIGH CONTRAST MODE ===== */
@media (prefers-contrast: high) {
    .vehicle-card {
        border: 2px solid #000 !important;
    }
    
    .vehicle-card:hover {
        border: 3px solid #000 !important;
        box-shadow: 0 0 0 2px #000 !important;
    }
    
    .category-item {
        border: 2px solid #000 !important;
    }
    
    .category-item.active {
        background: #000 !important;
        color: #fff !important;
    }
    
    .filter-group {
        border: 2px solid #000 !important;
    }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
    .vehicle-card,
    .category-item,
    .filter-group,
    .search-input-wrapper,
    .brand-logo {
        animation: none !important;
        transition: none !important;
    }
    
    .vehicle-card:hover {
        transform: none !important;
    }
    
    .category-item:hover {
        transform: none !important;
    }
    
    .collapse-icon {
        transition: none !important;
    }
}

/* ===== CUSTOM SCROLLBAR PARA SIDEBAR ===== */
.sidebar-filters-full::-webkit-scrollbar {
    width: 6px;
}

.sidebar-filters-full::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.sidebar-filters-full::-webkit-scrollbar-thumb {
    background: var(--primary-blue);
    border-radius: 3px;
}

.sidebar-filters-full::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-dark-blue);
}

/* ===== ESTILOS FINALES Y CORRECCIONES ===== */
.vehicles-grid,
.vehicles-grid-clean {
    contain: layout style;
    isolation: isolate;
}

.vehicle-card,
.category-item {
    transform: translateZ(0);
    backface-visibility: hidden;
    perspective: 1000px;
}

/* ===== FALLBACK PARA NAVEGADORES SIN CSS GRID ===== */
@supports not (display: grid) {
    .vehicles-grid,
    .vehicles-grid-clean {
        display: flex;
        flex-wrap: wrap;
        gap: 1px;
    }
    
    .vehicle-card {
        flex: 0 0 calc(25% - 1px);
        max-width: calc(25% - 1px);
    }
    
    @media (max-width: 1200px) {
        .vehicle-card {
            flex: 0 0 calc(33.333% - 1px);
            max-width: calc(33.333% - 1px);
        }
    }
    
    @media (max-width: 768px) {
        .vehicle-card {
            flex: 0 0 calc(50% - 1px);
            max-width: calc(50% - 1px);
        }
    }
    
    @media (max-width: 480px) {
        .vehicle-card {
            flex: 0 0 100%;
            max-width: 100%;
        }
    }
}

/* ===== ESTADOS ADICIONALES DE BÚSQUEDA ===== */
.search-input-wrapper.searching {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-color: #fbbf24;
}

.search-input-wrapper.has-results {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    border-color: #10b981;
}

.search-input-wrapper.no-results {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    border-color: #ef4444;
}

/* ===== MODO OSCURO (OPCIONAL) ===== */
@media (prefers-color-scheme: dark) {
    .search-input-wrapper {
        background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
        border-color: #374151;
    }
    
    .filter-search-input {
        color: #f9fafb;
    }
    
    .filter-search-input::placeholder {
        color: #9ca3af;
    }
    
    .search-icon {
        color: #60a5fa;
    }
}

/* ===== ACCESIBILIDAD ADICIONAL ===== */
.search-input-wrapper:focus-within {
    outline: 2px solid transparent;
    outline-offset: 2px;
}

.filter-search-input:focus {
    outline: none;
}

/* ===== ANIMACIÓN DE ENTRADA DE MARCAS ===== */
.brands.animate-in .brand-logo {
    animation: fadeInBrand 0.6s ease forwards;
    opacity: 0;
}

@keyframes fadeInBrand {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.8);
    }
    to {
        opacity: 0.7;
        transform: translateY(0) scale(1);
    }
}

.brands.animate-in .brand-logo:nth-child(1) { animation-delay: 0.1s; }
.brands.animate-in .brand-logo:nth-child(2) { animation-delay: 0.2s; }
.brands.animate-in .brand-logo:nth-child(3) { animation-delay: 0.3s; }
.brands.animate-in .brand-logo:nth-child(4) { animation-delay: 0.4s; }
.brands.animate-in .brand-logo:nth-child(5) { animation-delay: 0.5s; }
.brands.animate-in .brand-logo:nth-child(6) { animation-delay: 0.6s; }
.brands.animate-in .brand-logo:nth-child(7) { animation-delay: 0.7s; }
.brands.animate-in .brand-logo:nth-child(8) { animation-delay: 0.8s; }

.brand-logo:hover {
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.1),
        0 0 20px rgba(61, 95, 172, 0.1);
    border-radius: 8px;
}

.brand-logo:focus {
    outline: 3px solid #3D5FAC;
    outline-offset: 3px;
    opacity: 1;
    filter: grayscale(0%) brightness(1);
}

/* ===== VARIANTES ESPECÍFICAS POR PÁGINA ===== */
.page-inicio .brands {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.page-unidades .brands {
    background: #ffffff;
    border-top: 2px solid #3D5FAC;
}

.page-empresa .brands {
    background: #f8f9fa;
}

.page-contacto .brands {
    background: #ffffff;
    margin-top: 60px;
}

.page-detalle .brands {
    background: #f8f9fa;
    margin-top: 40px;
}

/* ===== CARDS DE VEHÍCULOS - DISEÑO LIMPIO CON ROBOTO ===== */

/* Fuente Roboto */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');

/* ===== OPTIMIZACIÓN DE ESPACIOS EN VEHICLE CARDS - VERSIÓN 2.0 ===== */
/* Cambios aplicados:
   1. Card mantiene altura original MÁS ALTA (500px)
   2. Imagen AGRANDADA significativamente (350px - era 200px)
   3. Título y tipo compactados
   4. TODO el espacio ganado va a la imagen
*/

/* ===== VEHICLE CARD - ESTRUCTURA PRINCIPAL (MÁS ALTA) ===== */
.vehicle-card {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08) !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 550px !important; /* ✅ ALTURA MAYOR: 500px (antes 400px) */
    max-height: 500px !important;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
}

.vehicle-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15) !important;
    border-color: #3D5FAC !important;
}

/* ===== IMAGEN DEL VEHÍCULO - MUCHO MÁS GRANDE ===== */
.vehicle-image {
    position: relative !important;
    height: 290px !important; /* ✅ MUCHO MÁS GRANDE: 350px (antes 200px = +75%!) */
    overflow: hidden !important;
    background: #f8f9fa !important;
    flex-shrink: 0 !important;
}

.vehicle-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    transition: transform 0.4s ease !important;
}

.vehicle-card:hover .vehicle-image img {
    transform: scale(1.08) !important;
}

/* ===== CONTENIDO PRINCIPAL - SÚPER COMPACTO ===== */
.vehicle-content-box {
    padding: 10px 14px 6px 14px !important; /* ✅ MUY REDUCIDO */
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 3px !important; /* ✅ GAP MÍNIMO */
    background: #ffffff !important;
    overflow: hidden !important;
}

/* ===== TÍTULO - COMPACTO ===== */
.vehicle-title-new {
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.9rem !important; /* ✅ Más pequeño */
    font-weight: 700 !important;
    color: #1a1a1a !important;
    margin: 0 !important;
    line-height: 1.15 !important; /* ✅ Muy compacto */
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
}

/* ===== TIPO DE VEHÍCULO - MUY COMPACTO ===== */
.vehicle-type-new {
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.75rem !important; /* ✅ Muy pequeño */
    font-weight: 500 !important;
    color: #6b7280 !important;
    margin: 0 0 4px 0 !important; /* ✅ Margen mínimo */
    line-height: 1.1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ===== GRID DE ESPECIFICACIONES - COMPACTO ===== */
.specs-grid-new {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 5px 8px !important; /* ✅ Gaps mínimos */
    padding: 6px 0 !important; /* ✅ Padding mínimo */
    border-top: 1px solid #e5e7eb !important;
    /* border-bottom eliminado */
    margin-top: auto !important;
}

/* ===== CADA ESPECIFICACIÓN ===== */
.spec-item-new {
    display: flex !important;
    flex-direction: column !important;
    gap: 1px !important; /* ✅ Gap mínimo */
}

.spec-label-new {
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.65rem !important; /* ✅ Muy pequeño */
    font-weight: 400 !important;
    color: #9ca3af !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    line-height: 1.1 !important;
}

.spec-value-new {
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.85rem !important; /* ✅ Compacto pero legible */
    font-weight: 600 !important;
    color: #1a1a1a !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ===== FOOTER - COMPACTO ===== */
.vehicle-footer-new {
    padding: 10px 14px !important; /* ✅ Padding reducido */
    background: #f9fafb !important;
    border-top: 1px solid #e5e7eb !important;
    margin-top: auto !important;
    flex-shrink: 0 !important;
}

/* Footer CON PRECIO: Layout horizontal */
.vehicle-footer-new.with-price {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
}

/* Footer SIN PRECIO: Layout centrado */
.vehicle-footer-new.no-price {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* ===== PRECIO ===== */
.vehicle-price-display {
    font-family: 'Roboto', sans-serif !important;
    font-size: 1.05rem !important; /* ✅ Ligeramente más pequeño */
    font-weight: 700 !important;
    color: #1a1a1a !important;
    letter-spacing: 0.5px !important;
}

/* ===== BOTÓN VER DETALLE (cuando hay precio) ===== */
.btn-view-detail {
    background: white !important;
    color: #1a202c !important;
    border: 2px solid #e2e8f0 !important;
    padding: 7px 14px !important; /* ✅ Más compacto */
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.75rem !important; /* ✅ Más pequeño */
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 0.8px !important;
    border-radius: 4px !important;
    white-space: nowrap !important;
}

.btn-view-detail:hover {
    color: #3D5FAC !important;
    border-color: #3D5FAC !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(61, 95, 172, 0.15) !important;
}

/* ===== BOTÓN VER DETALLE FULL WIDTH (cuando NO hay precio) ===== */
.btn-view-detail-full {
    background: white !important;
    color: #1a202c !important;
    border: 2px solid #e2e8f0 !important;
    padding: 7px 14px !important; /* Igualado al botón con precio */
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.75rem !important; /* Igualado al botón con precio */
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 0.8px !important; /* Igualado al botón con precio */
    border-radius: 4px !important;
    white-space: nowrap !important;
}

.btn-view-detail-full:hover {
    color: #3D5FAC !important;
    border-color: #3D5FAC !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(61, 95, 172, 0.2) !important;
}

/* ===== RESPONSIVE - AJUSTES PARA DIFERENTES DISPOSITIVOS ===== */
@media (max-width: 1400px) {
    .vehicle-card {
        min-height: 480px !important;
        max-height: 480px !important;
    }
    
    .vehicle-image {
        height: 330px !important;
    }
}

@media (max-width: 1200px) {
    .vehicle-card {
        min-height: 460px !important;
        max-height: 460px !important;
    }
    
    .vehicle-image {
        height: 310px !important;
    }
}

@media (max-width: 992px) {
    .vehicle-card {
        min-height: 440px !important;
        max-height: 440px !important;
    }
    
    .vehicle-image {
        height: 290px !important;
    }
    
    .vehicle-title-new {
        font-size: 0.85rem !important;
    }
    
    .vehicle-type-new {
        font-size: 0.72rem !important;
    }
}

@media (max-width: 768px) {
    .vehicle-card {
        min-height: 420px !important;
        max-height: 420px !important;
    }
    
    .vehicle-image {
        height: 270px !important;
    }
    
    .vehicle-title-new {
        font-size: 0.8rem !important;
    }
    
    .vehicle-type-new {
        font-size: 0.7rem !important;
    }
    
    .spec-value-new {
        font-size: 0.8rem !important;
    }
    
    .vehicle-content-box {
        padding: 8px 12px 5px 12px !important;
    }
}

@media (max-width: 576px) {
    .vehicle-card {
        min-height: 400px !important;
        max-height: 400px !important;
    }
    
    .vehicle-image {
        height: 250px !important;
    }
    
    .specs-grid-new {
        grid-template-columns: 1fr !important;
        gap: 4px !important;
    }
    
    .vehicle-footer-new.with-price {
        flex-direction: column !important;
        gap: 6px !important;
    }
    
    .btn-view-detail {
        width: 100% !important;
        text-align: center !important;
    }
}

/* ===== ANIMACIÓN DE ENTRADA ===== */
.vehicle-card.fade-in {
    animation: cardFadeIn 0.5s ease forwards;
    opacity: 0;
}

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

/* ===== SUMMARY DE CAMBIOS V2.0 ===== */
/*
✅ Card: 400px → 500px (altura AUMENTADA +25%)
✅ Imagen: 200px → 350px (+150px, +75% MÁS GRANDE!)
✅ Título: 1.1rem → 0.9rem (compactado)
✅ Tipo: 0.9rem → 0.75rem (muy compacto)
✅ Padding: 20px → 10px-14px (mínimo)
✅ Gaps: Todos reducidos al mínimo
✅ Specs: Super compactas
✅ Footer: Compacto
✅ Espacios blancos: Eliminados
✅ TODO el espacio ganado → IMAGEN

Resultado:
- Card MÁS ALTA (500px vs 400px)
- Imagen MUCHO MÁS GRANDE (+75%)
- Textos ultra compactos pero legibles
- Máximo impacto visual
*/


/* ===== ESTADOS DE LOADING ===== */
.loading-state, 
.empty-state, 
.error-state {
    grid-column: 1 / -1;
    padding: 60px 20px;
    text-align: center;
    font-family: 'Roboto', sans-serif;
}

.loading-state h3,
.empty-state h3,
.error-state h3 {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3D5FAC;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== FOOTER - LAYOUT CONDICIONAL ===== */
.vehicle-footer-new {
    padding: 16px 20px !important;
    background: #f9fafb !important;
    border-top: 1px solid #e5e7eb !important;
    margin-top: auto !important;
}

/* Footer CON PRECIO: Layout horizontal */
.vehicle-footer-new.with-price {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
}

/* Footer SIN PRECIO: Layout centrado */
.vehicle-footer-new.no-price {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* ===== PRECIO CON SIGNO $ ===== */
.vehicle-price-display {
    font-family: 'Roboto', sans-serif !important;
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    letter-spacing: 0.5px !important;
}

/* ===== BOTÓN VER DETALLE (cuando hay precio) ===== */
.btn-view-detail {
    background: white !important;
    color: #1a202c !important;
    border: 2px solid #e2e8f0 !important;
    padding: 10px 20px !important;
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    border-radius: 4px !important;
    white-space: nowrap !important;
}

.btn-view-detail:hover {
    color: #3D5FAC !important;
    border-color: #3D5FAC !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(61, 95, 172, 0.15) !important;
}

/* ===== BOTÓN VER DETALLE FULL WIDTH (cuando NO hay precio) ===== */
.btn-view-detail-full {
    background: white !important;
    color: #1a202c !important;
    border: 2px solid #e2e8f0 !important;
    padding: 10px 20px !important;
    font-family: 'Roboto', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    border-radius: 4px !important;
    white-space: nowrap !important;
}

.btn-view-detail-full:hover {
    color: #3D5FAC !important;
    border-color: #3D5FAC !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(61, 95, 172, 0.2) !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 576px) {
    .vehicle-footer-new.with-price {
        flex-direction: column !important;
        gap: 10px !important;
    }
    
    .btn-view-detail {
        width: 100% !important;
        text-align: center !important;
    }
    
    .vehicle-price-display {
        font-size: 1.1rem !important;
    }
}
/* ===== OVERRIDE: Eliminar recuadro azul del botón Randon ===== */
.nav-button .btn-special:hover {
    border-color: transparent !important;
}

/* ===== FIX RESPONSIVE MOBILE - CARDS DE VEHÍCULOS ===== */

/* MOBILE: 768px y menos */
@media (max-width: 768px) {
    /* Card ajustada para móvil */
    .vehicle-card {
        min-height: 480px !important;
        max-height: 480px !important;
    }
    
    /* Imagen más grande en móvil */
    .vehicle-image {
        height: 200px !important;
    }
    
    /* Contenido con más espacio */
    .vehicle-content-box {
        padding: 12px 14px !important;
        gap: 6px !important;
    }
    
    /* Título más pequeño pero legible */
    .vehicle-title-new {
        font-size: 0.9rem !important;
        line-height: 1.3 !important;
        -webkit-line-clamp: 2 !important;
        margin-bottom: 4px !important;
    }
    
    /* Tipo de vehículo compacto */
    .vehicle-type-new {
        font-size: 0.75rem !important;
        margin-bottom: 8px !important;
    }
    
    /* ===== GRID DE ESPECIFICACIONES: 2 COLUMNAS EN MÓVIL ===== */
    .specs-grid-new {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important; /* ✅ 2 columnas siempre */
        gap: 8px 10px !important; /* ✅ Más espacio entre items */
        padding: 10px 0 !important;
    }
    
    /* Cada especificación más compacta */
    .spec-item-new {
        display: flex !important;
        flex-direction: column !important;
        gap: 2px !important;
        min-width: 0 !important; /* ✅ Permite que el texto se ajuste */
    }
    
    /* Label más pequeño */
    .spec-label-new {
        font-size: 0.65rem !important;
        line-height: 1.2 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    /* Valor ajustado para que no se corte */
    .spec-value-new {
        font-size: 0.85rem !important;
        font-weight: 600 !important;
        line-height: 1.2 !important;
        white-space: normal !important; /* ✅ Permite múltiples líneas si es necesario */
        overflow: visible !important; /* ✅ No corta el texto */
        text-overflow: clip !important;
        word-break: break-word !important; /* ✅ Rompe palabras largas */
    }
    
    /* Footer ajustado */
    .vehicle-footer-new {
        padding: 12px 14px !important;
    }
    
    /* Precio más pequeño en móvil */
    .vehicle-price-display {
        font-size: 1.1rem !important;
    }
    
    /* Botón ajustado */
    .btn-view-detail {
        padding: 8px 16px !important;
        font-size: 0.75rem !important;
    }
    
    .btn-view-detail-full {
        padding: 10px 24px !important;
        font-size: 0.8rem !important;
        min-width: 140px !important;
    }
}

/* MOBILE PEQUEÑO: 576px y menos */
@media (max-width: 576px) {
    /* Card más compacta */
    .vehicle-card {
        min-height: 460px !important;
        max-height: 460px !important;
    }
    
    /* Imagen proporcional */
    .vehicle-image {
        height: 180px !important;
    }
    
    /* Contenido más compacto */
    .vehicle-content-box {
        padding: 10px 12px !important;
        gap: 5px !important;
    }
    
    /* Título más pequeño */
    .vehicle-title-new {
        font-size: 0.85rem !important;
        line-height: 1.25 !important;
    }
    
    /* Tipo más pequeño */
    .vehicle-type-new {
        font-size: 0.7rem !important;
        margin-bottom: 6px !important;
    }
    
    /* ===== GRID: MANTENER 2 COLUMNAS ===== */
    .specs-grid-new {
        grid-template-columns: 1fr 1fr !important; /* ✅ Siempre 2 columnas */
        gap: 6px 8px !important;
        padding: 8px 0 !important;
    }
    
    /* Specs más compactas */
    .spec-label-new {
        font-size: 0.6rem !important;
    }
    
    .spec-value-new {
        font-size: 0.8rem !important;
    }
    
    /* Footer con layout vertical en móvil pequeño */
    .vehicle-footer-new.with-price {
        flex-direction: column !important;
        gap: 8px !important;
        padding: 10px 12px !important;
    }
    
    .btn-view-detail {
        width: 100% !important;
        padding: 10px 20px !important;
        font-size: 0.8rem !important;
    }
    
    .vehicle-price-display {
        font-size: 1rem !important;
    }
}

/* MOBILE EXTRA PEQUEÑO: 480px y menos */
@media (max-width: 480px) {
    .vehicle-card {
        min-height: 440px !important;
        max-height: 440px !important;
    }
    
    .vehicle-image {
        height: 170px !important;
    }
    
    .vehicle-content-box {
        padding: 8px 10px !important;
    }
    
    .vehicle-title-new {
        font-size: 0.8rem !important;
    }
    
    .vehicle-type-new {
        font-size: 0.68rem !important;
    }
    
    /* ===== MANTENER 2 COLUMNAS INCLUSO EN PANTALLAS MUY PEQUEÑAS ===== */
    .specs-grid-new {
        grid-template-columns: 1fr 1fr !important;
        gap: 5px 6px !important;
    }
    
    .spec-label-new {
        font-size: 0.58rem !important;
    }
    
    .spec-value-new {
        font-size: 0.75rem !important;
    }
}

/* ===== FIX PARA TEXTOS LARGOS ===== */
.spec-value-new {
    /* Asegurar que números largos se vean completos */
    hyphens: auto !important;
    -webkit-hyphens: auto !important;
    overflow-wrap: break-word !important;
}

/* ===== FIX PARA GRID RESPONSIVE ===== */
.vehicles-grid-clean {
    /* En móvil: 1 columna para dar más espacio */
    @media (max-width: 768px) {
        grid-template-columns: 1fr !important;
    }

    /* En tablet pequeño: 2 columnas */
    @media (min-width: 769px) and (max-width: 992px) {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ===================================================================
   RESPONSIVE PARA PANTALLAS GRANDES (MONITORES ANCHOS)
   ================================================================= */

/* Para pantallas de 1400px a 1599px (laptops grandes) */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
        padding: 0 30px;
    }

    /* Hero Section */
    .units-hero h1 {
        font-size: 3.8rem;
    }

    /* Filters Section */
    .filters-container {
        max-width: 1320px;
        padding: 30px;
    }

    .filter-group select,
    .filter-group input {
        padding: 14px 18px;
        font-size: 1.05rem;
    }

    .btn-filter {
        padding: 14px 35px;
        font-size: 1.05rem;
    }

    /* Vehicles Grid */
    .vehicles-grid-clean {
        grid-template-columns: repeat(3, 1fr);
        gap: 35px;
        max-width: 1320px;
    }

    .vehicle-card-clean {
        padding: 25px;
    }

    .vehicle-title {
        font-size: 1.5rem;
    }

    .vehicle-details p {
        font-size: 1.05rem;
    }

    .btn-ver-detalle {
        padding: 14px 28px;
        font-size: 1.05rem;
    }
}

/* Para pantallas de 1600px a 1919px (monitores Full HD) */
@media (min-width: 1600px) {
    .container {
        max-width: 1500px;
        padding: 0 40px;
    }

    /* Hero Section */
    .units-hero {
        height: 450px;
    }

    .units-hero h1 {
        font-size: 4.2rem;
    }

    /* Filters Section */
    .filters-section {
        padding: 50px 0;
    }

    .filters-container {
        max-width: 1500px;
        padding: 40px;
        gap: 30px;
    }

    .filter-group label {
        font-size: 1.05rem;
    }

    .filter-group select,
    .filter-group input {
        padding: 16px 20px;
        font-size: 1.1rem;
    }

    .btn-filter,
    .btn-clear {
        padding: 16px 40px;
        font-size: 1.1rem;
    }

    /* Vehicles Grid */
    .vehicles-section {
        padding: 60px 0;
    }

    .section-header h2 {
        font-size: 2.8rem;
    }

    .vehicles-grid-clean {
        grid-template-columns: repeat(3, 1fr);
        gap: 40px;
        max-width: 1500px;
    }

    .vehicle-card-clean {
        padding: 30px;
    }

    .vehicle-image-wrapper {
        height: 280px;
    }

    .vehicle-title {
        font-size: 1.6rem;
        margin-bottom: 1rem;
    }

    .vehicle-subtitle {
        font-size: 1.15rem;
    }

    .vehicle-details {
        gap: 18px;
        margin: 1.5rem 0;
    }

    .vehicle-details p {
        font-size: 1.1rem;
        padding: 14px 0;
    }

    .btn-ver-detalle {
        padding: 16px 32px;
        font-size: 1.1rem;
    }

    /* Pagination */
    .pagination-btn {
        padding: 12px 20px;
        font-size: 1.05rem;
    }
}

/* Para pantallas de 1920px en adelante (monitores 2K y superiores) */
@media (min-width: 1920px) {
    .container {
        max-width: 1720px;
        padding: 0 50px;
    }

    /* Hero Section */
    .units-hero {
        height: 500px;
    }

    .units-hero h1 {
        font-size: 5rem;
    }

    /* Filters Section */
    .filters-section {
        padding: 60px 0;
    }

    .filters-container {
        max-width: 1720px;
        padding: 50px;
        gap: 40px;
    }

    .filter-group label {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }

    .filter-group select,
    .filter-group input {
        padding: 18px 22px;
        font-size: 1.15rem;
        border-width: 2px;
    }

    .btn-filter,
    .btn-clear {
        padding: 18px 45px;
        font-size: 1.2rem;
    }

    /* Vehicles Grid */
    .vehicles-section {
        padding: 80px 0;
    }

    .section-header h2 {
        font-size: 3.5rem;
        margin-bottom: 3rem;
    }

    .results-count {
        font-size: 1.2rem;
    }

    .vehicles-grid-clean {
        grid-template-columns: repeat(4, 1fr);
        gap: 45px;
        max-width: 1720px;
    }

    .vehicle-card-clean {
        padding: 35px;
        border-width: 2px;
    }

    .vehicle-image-wrapper {
        height: 300px;
        margin-bottom: 1.8rem;
    }

    .vehicle-title {
        font-size: 1.8rem;
        margin-bottom: 1.2rem;
    }

    .vehicle-subtitle {
        font-size: 1.25rem;
        margin-bottom: 1.5rem;
    }

    .vehicle-details {
        gap: 20px;
        margin: 2rem 0;
    }

    .vehicle-details p {
        font-size: 1.15rem;
        padding: 16px 0;
    }

    .vehicle-details i {
        font-size: 1.3rem;
    }

    .btn-ver-detalle {
        padding: 18px 36px;
        font-size: 1.15rem;
    }

    /* Pagination */
    .pagination {
        margin-top: 4rem;
    }

    .pagination-btn {
        padding: 14px 24px;
        font-size: 1.1rem;
    }

    .page-number {
        min-width: 50px;
        height: 50px;
        font-size: 1.1rem;
    }
}

/* Para pantallas ultra anchas 2560px+ (4K y superiores) */
@media (min-width: 2560px) {
    .container {
        max-width: 2200px;
        padding: 0 80px;
    }

    /* Hero Section */
    .units-hero {
        height: 600px;
    }

    .units-hero h1 {
        font-size: 6rem;
    }

    /* Filters */
    .filters-container {
        max-width: 2200px;
        padding: 60px;
    }

    .filter-group select,
    .filter-group input {
        padding: 22px 26px;
        font-size: 1.3rem;
    }

    /* Vehicles Grid */
    .vehicles-grid-clean {
        grid-template-columns: repeat(4, 1fr);
        gap: 60px;
        max-width: 2200px;
    }

    .vehicle-card-clean {
        padding: 45px;
    }

    .vehicle-image-wrapper {
        height: 350px;
    }

    .vehicle-title {
        font-size: 2.2rem;
    }

    .btn-ver-detalle {
        padding: 20px 40px;
        font-size: 1.3rem;
    }
}