/* =====================================================================
   RESPONSIVE — DÓNDE ESTAMOS (.locations-body, prefijo locations-/loc-)
   ---------------------------------------------------------------------
   Scope: .rsp (solo páginas adaptadas).
   Móvil:  < 768px · Tablet: 768px – 1199.98px · Desktop (≥1200px) intacto.
   Esta página ya está maquetada en flujo (no usa el lienzo 1440px):
   aquí se afinan tipografía fluida, el pill de controles (tabs +
   búsqueda) que pasa a columna en móvil, el dropdown de estados a
   ancho completo, la lista a 1 columna y áreas táctiles ≥44px.
   Sin animaciones por IntersectionObserver en esta vista (las
   transiciones hover/dropdown quedan intactas).
   ===================================================================== */

/* ────────────────────────────────────────────────────────────────────
   COMÚN (móvil + tablet)
   ──────────────────────────────────────────────────────────────────── */
@media (max-width: 1199.98px) {

  /* ═══ SECCIÓN: HERO ═══ */
  .rsp .locations-hero {
    min-height: 0; /* el alto lo define el contenido + padding */
  }

  /* ═══ SECCIÓN: CONTROLES (tabs + búsqueda) ═══ */
  /* Pill de tabs a ancho de flujo (sin inline-flex) y radio suavizado */
  .rsp .locations-tabs {
    display: flex;
    border-radius: 20px;
  }

  /* Tabs con área táctil ≥44px */
  .rsp .locations-tab {
    min-height: 44px;
  }

  .rsp .locations-search input {
    min-height: 60px;
    font-size: 16px; /* evita el zoom automático de iOS al enfocar */
  }

  /* Botón limpiar búsqueda: zona táctil ampliada */
  .rsp .locations-search-clear {
    width: 34px;
    height: 34px;
    right: 8px;
  }

  /* ═══ SECCIÓN: FILTRO POR ESTADO ═══ */
  .rsp .locations-state-trigger {
    min-height: 48px;
  }

  .rsp .locations-state-option {
    min-height: 44px;
    box-sizing: border-box;
  }

  /* ═══ SECCIÓN: LISTA DE UBICACIONES ═══ */
  /* Flecha "ver en mapa" con área táctil ≥44px (es enlace en
     parquímetros) sin ensanchar la tarjeta */
  .rsp .loc-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: -9px -14px -9px -8px;
  }

  /* ═══ SECCIÓN: CTA FINAL ═══ */
  /* Badges de tiendas: altura táctil cómoda */
  .rsp .locations-cta-btns a {
    display: inline-flex;
  }

  .rsp .locations-cta-btns img {
    height: 48px;
  }
}

/* ────────────────────────────────────────────────────────────────────
   MÓVIL (< 768px)
   ──────────────────────────────────────────────────────────────────── */
@media (max-width: 767.98px) {

  /* ═══ HERO ═══ */
  .rsp .locations-hero {
    padding: 126px 24px 56px;
  }

  .rsp .locations-hero-subtitle {
    font-size: clamp(17px, 4.6vw, 22px);
  }

  .rsp .locations-hero-title {
    font-size: clamp(40px, 11.5vw, 56px);
  }

  .rsp .locations-hero-desc {
    font-size: clamp(16px, 4.4vw, 18px);
    margin-bottom: 26px;
  }

  /* Píldora de métricas: ocupa el ancho, 3 stats repartidas */
  .rsp .locations-stats {
    display: flex;
    width: 100%;
    max-width: 420px;
    justify-content: space-between;
    gap: 6px;
    padding: 16px 10px;
    box-sizing: border-box;
  }

  .rsp .locations-stat {
    flex: 1 1 0;
    padding: 0 6px;
  }

  .rsp .locations-stat-num {
    font-size: clamp(26px, 7.5vw, 34px);
  }

  .rsp .locations-stat-label {
    font-size: 11px;
    letter-spacing: 0.08em;
  }

  /* ═══ CONTROLES: pill en columna (tabs arriba, búsqueda abajo) ═══ */
  .rsp .locations-controls {
    padding: 32px 16px 8px;
  }

  .rsp .locations-controls-inner {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 12px;
    border-radius: 30px;
  }

  /* Tabs apiladas: "Estacionamientos + contador" no cabe en dos
     columnas por debajo de ~420px sin desbordar el pill */
  .rsp .locations-tabs {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
    box-sizing: border-box;
  }

  .rsp .locations-tab {
    width: 100%;
    justify-content: flex-start;
    gap: 10px;
    padding: 11px 16px;
    font-size: 16px;
    box-sizing: border-box;
  }

  /* Contador alineado a la derecha del tab */
  .rsp .locations-tab-count {
    margin-left: auto;
    min-width: 28px;
    padding: 4px 9px;
    font-size: 13px;
  }

  .rsp .locations-search {
    min-width: 0;
    max-width: none;
    width: 100%;
    padding-top: 20px;
  }

  /* ═══ FILTRO POR ESTADO: ancho completo ═══ */
  .rsp .locations-states {
    padding: 0 16px 12px;
  }

  .rsp .locations-state-dropdown {
    width: 100%;
    max-width: 460px;
  }

  .rsp .locations-state-trigger {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    gap: 10px;
    padding: 12px 14px 12px 18px;
  }

  .rsp .locations-state-pill-value {
    font-size: 16px;
  }

  .rsp .locations-state-menu {
    width: 100%;
    min-width: 0;
    max-height: 320px;
    box-sizing: border-box;
  }

  /* ═══ LISTA: una columna ═══ */
  .rsp .locations-list-wrap {
    padding: 22px 16px 72px;
  }

  .rsp .locations-list.is-active {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .rsp .loc-card {
    gap: 14px;
    padding: 16px 16px;
    border-radius: 16px;
  }

  .rsp .loc-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
  }

  /* Nombres largos legibles: se permite salto de línea */
  .rsp .loc-name {
    font-size: 17px;
    white-space: normal;
    overflow: visible;
  }

  .rsp .loc-meta {
    font-size: 14px;
  }

  .rsp .locations-empty {
    padding: 48px 20px;
  }

  /* ═══ CTA FINAL ═══ */
  .rsp .locations-cta-wrap {
    padding: 0 16px 72px;
  }

  .rsp .locations-cta {
    padding: 40px 22px;
    border-radius: 26px;
  }

  .rsp .locations-cta-title {
    font-size: clamp(24px, 7vw, 30px);
  }

  .rsp .locations-cta-desc {
    font-size: 16px;
  }
}

/* ────────────────────────────────────────────────────────────────────
   TABLET (768px – 1199.98px)
   ──────────────────────────────────────────────────────────────────── */
@media (min-width: 768px) and (max-width: 1199.98px) {

  /* ═══ HERO ═══ */
  .rsp .locations-hero {
    padding: 160px 48px 72px;
  }

  .rsp .locations-hero-subtitle {
    font-size: clamp(20px, 2.8vw, 24px);
  }

  .rsp .locations-hero-title {
    font-size: clamp(52px, 7vw, 64px);
  }

  .rsp .locations-hero-desc {
    font-size: clamp(17px, 2.4vw, 19px);
  }

  /* ═══ CONTROLES: en fila, con wrap si la búsqueda no cabe ═══ */
  .rsp .locations-controls {
    padding: 40px 48px 8px;
  }

  .rsp .locations-controls-inner {
    max-width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    border-radius: 34px;
  }

  .rsp .locations-search {
    flex: 1 1 260px;
    min-width: 240px;
  }

  /* ═══ FILTRO POR ESTADO ═══ */
  .rsp .locations-states {
    padding: 0 48px 12px;
  }

  /* ═══ LISTA: dos columnas (como desktop, con aire lateral) ═══ */
  .rsp .locations-list-wrap {
    padding: 26px 48px 80px;
  }

  .rsp .loc-card {
    padding: 20px 22px;
  }

  .rsp .loc-name {
    font-size: 18px;
  }

  /* ═══ CTA FINAL ═══ */
  .rsp .locations-cta-wrap {
    padding: 0 48px 80px;
  }

  .rsp .locations-cta {
    padding: 48px 40px;
  }

  .rsp .locations-cta-title {
    font-size: clamp(28px, 3.6vw, 32px);
  }
}
