/**
 * home.css - Secciones del home después del hero (index.php).
 * Por ahora: la vidriera de propiedades con "Cargar más".
 */

/* --------------------------------------------------------------
 # Vidriera de propiedades
--------------------------------------------------------------- */
/* Fondo en el azul del logo, con textos en blanco y acentos en amarillo:
   las cards blancas se despegan y la marca se siente fuerte.
   Con el id a propósito: custom.css vuelve transparentes todas las secciones
   (".section:not(...):not(...)") para que se vea el patrón del sitio. */
#featured-properties.hp-props {
  --hp-ink: var(--hero-ink, #0d1017);
  --hp-navy: #364057;
  --hp-text: #ffffff;
  --hp-soft: rgba(255, 255, 255, 0.7);
  --hp-yellow: var(--hero-yellow, #FFDE59);

  padding: 96px 0 104px;
  background-color: var(--hp-navy);
  /* Un brillo amarillo apenas perceptible arriba a la derecha y el azul que
     se oscurece hacia abajo: da profundidad sin dejar de ser el color plano */
  background-image:
    radial-gradient(60% 50% at 90% 0%, rgba(255, 222, 89, 0.08) 0%, transparent 70%),
    linear-gradient(180deg, #364057 0%, #2c3548 100%);
  color: var(--hp-text);
}

.hp-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 44px;
}

.hp-eyebrow {
  margin: 0 0 12px;
  font-family: var(--nav-font);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--hp-yellow);
}

.hp-eyebrow::before {
  content: "";
  display: inline-block;
  width: 28px;
  height: 3px;
  margin: 0 12px 3px 0;
  border-radius: 2px;
  background: var(--hero-yellow, #FFDE59);
  vertical-align: middle;
}

.hp-head h2 {
  margin: 0;
  font-family: var(--heading-font);
  font-size: clamp(30px, 3.4vw, 46px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--hp-text);
}

/* "22 propiedades disponibles / Buscar con filtros" a la derecha del título */
.hp-head-link {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
  font-size: 15px;
  color: var(--hp-soft);
  text-align: right;
}

.hp-head-link strong {
  font-family: var(--nav-font);
  font-weight: 700;
  color: var(--hp-yellow);
}

.hp-head-cta {
  font-family: var(--nav-font);
  font-weight: 600;
  color: var(--hp-text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}

.hp-head-link i {
  display: inline-block;
  transition: transform 0.25s;
}

.hp-head-link:hover {
  color: var(--hp-soft);
}

.hp-head-link:hover .hp-head-cta {
  color: var(--hp-yellow);
}

.hp-head-link:hover i {
  transform: translateX(4px);
}

/* --------------------------------------------------------------
 # Cargar más
--------------------------------------------------------------- */
.hp-more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin-top: 56px;
}

.hp-more-count {
  margin: 0;
  font-size: 15px;
  color: var(--hp-soft);
}

.hp-more-count strong {
  font-family: var(--nav-font);
  color: var(--hp-text);
}

/* Barra de progreso: muestra cuánto falta ver */
.hp-more-bar {
  width: 220px;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.16);
  overflow: hidden;
}

.hp-more-bar span {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: var(--hp-yellow);
  transition: width 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* El botón protagonista: amarillo sobre el azul, imposible de no ver */
.hp-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  padding: 18px 38px;
  border: 0;
  border-radius: 999px;
  background: var(--hp-yellow);
  color: var(--hp-ink);
  font-family: var(--nav-font);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  transition: transform 0.3s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.3s, background-color 0.3s;
}

.hp-more-btn i {
  transition: transform 0.3s;
}

.hp-more-btn:hover {
  transform: translateY(-2px);
  background: #ffe57a;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.32);
}

.hp-more-btn:hover i {
  transform: translateY(3px);
}

.hp-more-btn:focus-visible {
  outline: 3px solid #ffffff;
  outline-offset: 3px;
}

.hp-more-btn.is-loading {
  cursor: progress;
  opacity: 0.85;
}

.hp-more-btn.is-loading i {
  animation: hp-bounce 0.8s ease-in-out infinite;
}

@keyframes hp-bounce {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(4px); }
}

.hp-more-link {
  font-family: var(--nav-font);
  font-size: 15px;
  font-weight: 600;
  color: var(--hp-text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}

.hp-more-link:hover {
  color: var(--hp-yellow);
}

/* Sobre el azul, las cards necesitan una sombra más marcada para flotar */
.hp-props .pcard {
  border-color: transparent;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
}

.hp-props .pcard:hover {
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.32);
}

.hp-empty {
  padding: 48px 24px;
  border: 1px dashed rgba(255, 255, 255, 0.3);
  border-radius: 20px;
  text-align: center;
  color: var(--hp-soft);
}

.hp-empty p {
  margin: 0;
}

/* --------------------------------------------------------------
 # Responsive
--------------------------------------------------------------- */
@media (max-width: 767px) {
  #featured-properties.hp-props {
    padding: 64px 0 72px;
  }

  .hp-head {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 30px;
  }

  .hp-head-link {
    align-items: flex-start;
    text-align: left;
  }

  .hp-more {
    margin-top: 40px;
  }

  .hp-more-btn {
    width: 100%;
    justify-content: center;
  }
}
