/**
 * Listado Core de favoritos (VO/VN y gama): mismos estilos en ambos modos.
 * Depende de vehicle-grid-list.css (preloader, cards, swiper).
 */

/* Contenedor: favoritos y favoritos-gama */
.contenedor-mx-core-favorites-grid.mx-grid-favoritos,
.contenedor-mx-core-favorites-grid.mx-grid-favoritos-gama {
  width: 100%;
  max-width: 100%;
  position: relative;
}

.contenedor-mx-core-favorites-grid .mx-core-vf-initial-preloader {
  display: block;
}

.contenedor-mx-core-favorites-grid .mx-core-vf-delete-all-wrap,
.contenedor-mx-core-favorites-grid .boton--borrar-favoritos--container {
  display: flex;
  justify-content: center;
  width: 100%;
  text-align: center;
}

/* Botón eliminar todos: paridad con customtheme-child (VO/VN y gama) */
.contenedor-mx-core-favorites-grid.mx-grid-favoritos .boton--borrar-favoritos,
.contenedor-mx-core-favorites-grid.mx-grid-favoritos-gama .boton--borrar-favoritos,
.contenedor-mx-grid.mx-grid-favoritos-gama .boton--borrar-favoritos--container .boton--borrar-favoritos {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 50px;
  width: 100%;
  text-decoration: none;
}

.contenedor-mx-core-favorites-grid.mx-grid-favoritos .boton--borrar-favoritos .boton-ficha---txt,
.contenedor-mx-core-favorites-grid.mx-grid-favoritos-gama .boton--borrar-favoritos .boton-ficha---txt,
.contenedor-mx-grid.mx-grid-favoritos-gama .boton--borrar-favoritos .boton-ficha---txt {
  display: inline-block;
  background-color: var(--verde-300, #6b8e23);
  color: var(--verde-100, #fff);
  padding: 15px 50px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.contenedor-mx-core-favorites-grid.mx-grid-favoritos .boton--borrar-favoritos:hover .boton-ficha---txt,
.contenedor-mx-core-favorites-grid.mx-grid-favoritos-gama .boton--borrar-favoritos:hover .boton-ficha---txt,
.contenedor-mx-grid.mx-grid-favoritos-gama .boton--borrar-favoritos:hover .boton-ficha---txt {
  opacity: 0.9;
}

.contenedor-mx-core-favorites-grid.mx-preloader-blur .mx-core-vg-body,
.contenedor-mx-core-favorites-grid .mx-core-vg-body.mx-preloader-blur {
  filter: blur(6px);
  pointer-events: none;
  transition: filter 0.3s;
}

.contenedor-mx-core-favorites-grid .mx-custom-grid-item.mx-core-vg-body {
  display: block;
  width: 100%;
  position: relative;
  flex-wrap: nowrap;
}

.contenedor-mx-core-favorites-grid .mx-custom-preloader {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  width: 100%;
  z-index: 9;
}

/* Grid de items (responsive inline en #id); anular anchos legacy vc_col */
.contenedor-mx-core-favorites-grid .mx-core-vg-items {
  align-items: stretch;
  width: 100%;
  max-width: 100%;
}

.contenedor-mx-core-favorites-grid .mx-core-vg-items > .mx-grid-item,
.contenedor-mx-core-favorites-grid .mx-core-vg-items > .vc_grid-item,
.contenedor-mx-core-favorites-grid .mx-core-vg-items > .vc_grid-item.vc_col-sm-3,
.contenedor-mx-core-favorites-grid .mx-core-vg-items > .vc_grid-item.vc_col-sm-4 {
  display: flex;
  float: none !important;
  width: 100% !important;
  max-width: 100%;
  height: 100%;
  min-width: 0;
}

.contenedor-mx-core-favorites-grid .mx-core-vg-items > .mx-grid-item > .vc_grid-item-mini,
.contenedor-mx-core-favorites-grid .mx-core-vg-items > .vc_grid-item > .vc_grid-item-mini {
  display: flex;
  flex-direction: column;
  max-width: 100%;
  width: 100%;
}

@media only screen and (max-width: 768px) {
  .contenedor-mx-core-favorites-grid .mx-core-vg-items > .vc_grid-item > .vc_grid-item-mini {
    width: 100%;
    max-width: 345px;
    margin-left: auto;
    margin-right: auto;
  }
}

.contenedor-mx-core-favorites-grid .mx-core-vg-items .vc_gitem-zone.vc_gitem-zone-c,
.contenedor-mx-core-favorites-grid .mx-core-vg-items .vc_gitem-zone.vc_gitem-zone-c > .vc_gitem-zone-mini {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
}

.contenedor-mx-core-favorites-grid .mx-core-vg-items .vc_gitem-zone.vc_gitem-zone-c > .vc_gitem-zone-mini {
  justify-content: space-between;
}

/* Cards: reglas equivalentes a .mx-custom-grid-item .vc_grid-item (grid vehículos) */
.contenedor-mx-core-favorites-grid .mx-custom-grid-item .vc_grid-item {
  display: flex;
  justify-content: center;
}

.contenedor-mx-core-favorites-grid .mx-custom-grid-item .vc_grid-item > .vc_grid-item-mini .vc_gitem-zone.vc_gitem-zone-c {
  display: flex;
  height: 100%;
}

.contenedor-mx-core-favorites-grid .mx-custom-grid-item .vc_grid-item > .vc_grid-item-mini:hover img.item-lista--img-veh.item-lista--img-veh--hover {
  opacity: 1;
}

.contenedor-mx-core-favorites-grid .mx-custom-grid-item img.item-lista--img-veh,
.contenedor-mx-core-favorites-grid .mx-custom-grid-item img.item-lista--img-veh.item-lista--img-veh--hover {
  left: 15px;
  top: 0;
  width: calc(100% - 30px);
  max-width: calc(100% - 30px);
}

.contenedor-mx-core-favorites-grid .mx-custom-grid-item .vc_grid-item.vendido > .vc_grid-item-mini,
.contenedor-mx-core-favorites-grid .mx-custom-grid-item .vc_grid-item.reservado > .vc_grid-item-mini {
  position: relative;
  overflow: hidden;
}

/* Slider */
.contenedor-mx-core-favorites-grid .mx-core-vg-swiper,
.contenedor-mx-core-favorites-grid .mx-core-vg-swiper .swiper-wrapper {
  width: 100%;
  max-width: 100%;
}

.contenedor-mx-core-favorites-grid .mx-core-vg-slider-mode .mx-core-vg-items {
  display: flex !important;
}

/* Grids legacy en la misma página (paridad visual con Core) */
.contenedor-mx-grid.mx-grid-favoritos .mx-custom-grid-item,
.contenedor-mx-grid.mx-grid-favoritos-gama .mx-custom-grid-item {
  width: 100%;
}
