/**
 * Widget Cards — VIP Travel
 *
 * Tarjetas con foto a sangre completa de fondo, degradado de legibilidad y el
 * contenido anclado abajo: badge, título, descripción, meta y botón.
 *
 * El contenido se ancla al fondo (justify-content: flex-end) para que los pies
 * de todas las tarjetas queden alineados aunque los textos midan distinto.
 */

/* =============================================================================
 * GRILLA
 * ============================================================================= */
.vt-cards {
  display: grid;
  grid-template-columns: repeat(var(--vt-cards-cols, 3), minmax(0, 1fr));
  gap: var(--vt-cards-gap, 24px);
}

/* =============================================================================
 * TARJETA
 * ============================================================================= */
.vt-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 440px;
  border-radius: var(--vt-card-radius, 24px);
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 4px 24px rgba(26, 26, 26, .12);
  transition: transform .35s ease, box-shadow .35s ease;
}

.vt-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 48px rgba(26, 26, 26, .24);
}

/* --- Foto de fondo --- */
.vt-card__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--vt-gray-light, #b6b6b4);
}

.vt-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform .6s ease;
}

.vt-card:hover .vt-card__media img { transform: scale(1.06); }

/* --- Degradado de legibilidad (configurable desde Elementor) --- */
.vt-card__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

/* --- Badge superior --- */
.vt-card__badge {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  color: var(--vt-accent, #5694a9);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 100px;
  line-height: 1;
}

.vt-card__badge-icon {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
}

.vt-card__badge-icon svg {
  width: 1em;
  height: 1em;
  fill: currentColor;
}

/* --- Contenido --- */
.vt-card__content {
  position: relative;
  z-index: 2;
  padding: 28px;
  color: #fff;
}

.vt-card__title {
  font-family: var(--vt-font-display, 'Playfair Display', Georgia, serif);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.25;
  color: #fff;
  margin: 0 0 8px;
}

.vt-card__desc {
  font-size: .9rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, .82);
  margin: 0 0 20px;
}

/* --- Pie: meta + botón --- */
.vt-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.vt-card__meta { line-height: 1.35; }

.vt-card__meta-label {
  display: block;
  font-size: .72rem;
  color: rgba(255, 255, 255, .7);
}

.vt-card__meta-value {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
}

.vt-card__meta-suffix {
  font-size: .72rem;
  color: rgba(255, 255, 255, .7);
  margin-left: 4px;
}

.vt-card__btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  background: var(--vt-accent, #5694a9);
  color: #fff;
  font-size: .82rem;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 8px;
  border: 0;
  transition: background .25s ease, transform .25s ease;
}

.vt-card:hover .vt-card__btn { background: var(--vt-accent-dark, #427a8d); }
a.vt-card__btn:hover { color: #fff; transform: translateY(-1px); }

/* --- Tarjeta completa clickeable --- */
.vt-card__link {
  position: absolute;
  inset: 0;
  z-index: 4;
  /* Enlace invisible que cubre toda la tarjeta. */
}

/* Con la tarjeta clickeable el botón es decorativo: no intercepta el click. */
.vt-card--linked .vt-card__btn { pointer-events: none; }

.vt-card__link:focus-visible {
  outline: 3px solid var(--vt-accent, #5694a9);
  outline-offset: -3px;
}

/* =============================================================================
 * RESPONSIVE
 * -----------------------------------------------------------------------------
 * El número de columnas NO se define aquí: lo controla Elementor con su control
 * responsive (escritorio / tablet / móvil), que genera sus propias media queries.
 * ============================================================================= */
@media (max-width: 767px) {
  .vt-card__content { padding: 22px; }
  .vt-card__title { font-size: 1.2rem; }
}

/* Sin animaciones si el usuario las desactivó en su sistema. */
@media (prefers-reduced-motion: reduce) {
  .vt-card,
  .vt-card__media img,
  .vt-card__btn {
    transition: none;
  }
  .vt-card:hover { transform: none; }
  .vt-card:hover .vt-card__media img { transform: none; }
}
