/* ==========================================================================
   v8.10.0 — Secciones de anuncios, favoritos e insignias.
   Solo capa de presentación: respeta colores y tipografía actuales del tema.
   ========================================================================== */

.mv-section-archive { padding-block: clamp(18px, 3vw, 34px); }
.mv-section-archive-head {
  display: flex; flex-wrap: wrap; gap: 14px;
  align-items: flex-end; justify-content: space-between;
  margin-bottom: 14px;
}
.mv-section-archive-title {
  display: flex; align-items: center; gap: 10px;
  margin: 0; line-height: 1.15;
  font-size: clamp(1.35rem, 1rem + 1.4vw, 2rem);
}
.mv-section-count { margin: 0 0 12px; font-size: .9rem; }

/* Pestañas de secciones (scroll táctil en móvil, sin overflow de página) */
.mv-section-tabs {
  display: flex; gap: 8px; flex-wrap: wrap;
  max-width: 100%;
}
.mv-section-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 13px; border-radius: 999px;
  border: 1px solid hsl(140 15% 88%);
  background: #fff; color: hsl(150 30% 14%);
  font-size: .78rem; font-weight: 700; text-decoration: none;
  white-space: nowrap;
}
.mv-section-tab.is-active,
.mv-section-tab:hover { background: hsl(145 63% 32%); border-color: hsl(145 63% 32%); color: #fff; }

/* Rejilla unificada de tarjetas */
.mv-listings-grid {
  display: grid; gap: clamp(12px, 1.4vw, 20px);
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
}
@media (max-width: 1279px) { .mv-listings-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px)  { .mv-listings-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px)  { .mv-listings-grid { grid-template-columns: 1fr; } }

.mv-listings-grid > * { min-width: 0; }
.mv-listings-grid .mv-card { display: flex; flex-direction: column; height: 100%; }
.mv-listings-grid .mv-card-body { display: flex; flex-direction: column; gap: 6px; flex: 1 1 auto; }
.mv-listings-grid .mv-card-title { overflow-wrap: anywhere; }

/* Insignias reales (solo se imprimen si el dato existe) */
.mv-card-flags { position: absolute; inset: 8px 8px auto auto; display: flex; flex-direction: column; gap: 5px; align-items: flex-end; pointer-events: none; }
.mv-flag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 999px;
  font-size: .66rem; font-weight: 800; letter-spacing: .02em;
  background: rgba(255,255,255,.94); color: hsl(150 30% 14%);
  box-shadow: 0 1px 4px rgba(0,0,0,.12);
}
.mv-flag-verified    { background: hsl(145 63% 32%); color: #fff; }
.mv-flag-recommended { background: hsl(38 92% 50%); color: hsl(30 60% 12%); }

/* Botón de favoritos */
.mv-fav-btn {
  position: absolute; left: 8px; top: 8px; z-index: 3;
  width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid hsl(140 15% 88%); border-radius: 999px;
  background: rgba(255,255,255,.95); color: hsl(350 70% 45%);
  font-size: 1rem; line-height: 1; cursor: pointer; text-decoration: none;
  transition: transform .15s ease, background .15s ease;
}
.mv-fav-btn:hover { transform: scale(1.07); }
.mv-fav-btn.is-active { background: hsl(350 75% 96%); border-color: hsl(350 60% 70%); }
.mv-fav-btn[disabled] { opacity: .6; cursor: progress; }

.mv-card { position: relative; }

/* Paginación */
.mv-section-pagination { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 22px; }
.mv-section-pagination a,
.mv-section-pagination span {
  min-width: 40px; min-height: 40px; padding: 0 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid hsl(140 15% 88%); border-radius: 10px;
  background: #fff; color: hsl(150 30% 14%); text-decoration: none; font-weight: 700; font-size: .85rem;
}
.mv-section-pagination .current { background: hsl(145 63% 32%); border-color: hsl(145 63% 32%); color: #fff; }

/* Bloques de portada */
.mv-home-section-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.mv-home-section-actions .mv-btn { min-height: 44px; }
.mv-home-strip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; padding-bottom: 6px; }
.mv-home-strip > * { flex: 0 0 min(84%, 320px); scroll-snap-align: start; }
@media (min-width: 901px) { .mv-home-strip { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); overflow: visible; } .mv-home-strip > * { flex: initial; } }

/* Anti-overflow global de las secciones nuevas */
.mv-section-archive, .mv-section-archive * { max-width: 100%; }
.mv-section-archive img { height: auto; }
