/* ═══════════════════════════════════════════
   Tema v2 — Favoritos
   Prefijo: v2f-  · Usa la tarjeta de producto de theme.css
═══════════════════════════════════════════ */

/* Con pocos productos el footer queda abajo de la pantalla */
body.theme-v2.v2f-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.v2f-page .v2-main {
  flex: 1 0 auto;
}

/* ── Cabecera ─────────────────────────────── */

.v2f-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px 20px;
}

.v2f-count {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  opacity: 0.7;
}

.v2f-list {
  margin-top: 28px;
}

/* ── Tarjeta: el corazón queda fuera del enlace ── */

.v2f-card {
  position: relative;
  display: flex;
  flex-direction: column;
  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

.v2f-card.is-removing {
  opacity: 0;
  transform: scale(0.96);
}

/* El botón va debajo del precio y queda alineado en toda la fila */
.v2f-card .v2-card-link {
  flex: 1;
  height: auto;
}

/* ── Agregar al carrito / Elegir opción ──── */

.v2f-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  height: 38px;
  margin-top: 12px;
  padding: 0 10px;
  border: 1px solid #d6d6db;
  border-radius: 999px;
  background: #fff;
  color: var(--v2-ink);
  font-family: var(--v2-font);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    opacity 0.2s ease;
}

.v2f-action svg {
  flex-shrink: 0;
}

.v2f-action-text {
  overflow: hidden;
  text-overflow: ellipsis;
}

.v2f-action:hover:not(:disabled) {
  border-color: var(--v2-ink);
  background: var(--v2-ink);
  color: #fff;
}

.v2f-action:disabled {
  border-color: var(--v2-line);
  background: var(--v2-soft);
  color: var(--v2-muted);
  cursor: default;
}

.v2f-add.is-loading {
  opacity: 0.55;
  cursor: progress;
}

.v2f-add.is-added,
.v2f-add.is-added:disabled {
  border-color: var(--v2-ink);
  background: var(--v2-ink);
  color: #fff;
  opacity: 1;
}

.v2f-remove {
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    opacity 0.2s ease;
}

.v2f-remove:hover {
  border-color: var(--v2-accent);
}

.v2f-remove:disabled {
  opacity: 0.5;
  cursor: default;
}

/* ── Vacío / sin sesión ───────────────────── */

.v2f-empty {
  margin-top: 16px;
  padding: 40px 20px 36px;
  border: 1px solid var(--v2-line);
  border-radius: 20px;
  text-align: center;
}

.v2f-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: var(--v2-soft);
  background: color-mix(in srgb, var(--v2-accent) 14%, #ffffff);
  color: var(--v2-accent);
}

.v2f-empty-icon svg {
  width: 24px;
  height: 24px;
}

.v2f-empty h2 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
}

.v2f-empty p {
  max-width: 340px;
  margin: 0 auto 22px;
  color: var(--v2-muted);
  font-size: 14px;
  line-height: 1.5;
}

/* ── Breakpoints ─────────────────────────── */

@media (min-width: 700px) {
  .v2f-empty {
    padding: 48px 24px 44px;
  }

  .v2f-empty h2 {
    font-size: 20px;
  }
}

@media (min-width: 1024px) {
  .v2f-list {
    margin-top: 36px;
  }

  .v2f-count {
    font-size: 14px;
  }

  .v2f-empty {
    margin-top: 20px;
  }
}
