/* Atlas secondary-page hero system */
.atlas-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background-color: #1f1b17 !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  color: #fff !important;
  min-height: 340px;
  padding: 70px 0 62px !important;
  display: flex;
  align-items: center;
  border: 0 !important;
}

.atlas-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(16, 14, 12, .52);
}

.atlas-hero::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(1180px, calc(100% - 48px));
  height: 1px;
  transform: translateX(-50%);
  background: rgba(255,255,255,.28);
  z-index: 1;
}

.atlas-hero-market { background-image: url('../img/heroes/hero-market.webp') !important; }
.atlas-hero-invest { background-image: url('../img/heroes/hero-invest.webp') !important; }
.atlas-hero-tools { background-image: url('../img/heroes/hero-tools.webp') !important; }
.atlas-hero-neighborhoods { background-image: url('../img/heroes/hero-neighborhoods.webp') !important; }
.atlas-hero-editorial { background-image: url('../img/heroes/hero-editorial.webp') !important; }
.atlas-hero-property { background-image: url('../img/heroes/hero-property.webp') !important; }

.atlas-hero > .container,
.atlas-hero > .container > div,
.atlas-hero .authority-hero-inner,
.atlas-hero .guide-archive-hero__container,
.atlas-hero .quartier-archive-hero__container,
.atlas-hero .article-archive-hero__container,
.atlas-hero .agence-archive-hero__container,
.atlas-hero .mi-listings-hero-inner,
.atlas-hero .mi-form-page-hero__inner {
  position: relative;
  z-index: 2;
}

.atlas-hero > .container,
.atlas-hero .authority-hero-inner,
.atlas-hero .guide-archive-hero__container,
.atlas-hero .quartier-archive-hero__container,
.atlas-hero .article-archive-hero__container,
.atlas-hero .agence-archive-hero__container,
.atlas-hero .mi-form-page-hero__inner {
  width: min(980px, calc(100% - 40px));
  margin-inline: auto;
  text-align: center;
}

.atlas-hero .mi-listings-hero-inner {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

.atlas-hero h1,
.atlas-hero .guide-archive-hero__title,
.atlas-hero .quartier-archive-hero__title,
.atlas-hero .article-archive-hero__title,
.atlas-hero .agence-archive-hero__title,
.atlas-hero .mi-listings-hero h1,
.atlas-hero .faq-premium-hero__title,
.atlas-hero .quartiers-hero__title {
  color: #fff !important;
  max-width: 900px;
  margin: 8px auto 16px !important;
  font-size: clamp(2.15rem, 4.5vw, 4.2rem) !important;
  line-height: 1.02 !important;
  letter-spacing: -.035em !important;
  text-wrap: balance;
  text-shadow: 0 2px 18px rgba(0,0,0,.15);
}

.atlas-hero p,
.atlas-hero .hero-text,
.atlas-hero .authority-lead,
.atlas-hero .guide-archive-hero__text,
.atlas-hero .quartier-archive-hero__text,
.atlas-hero .article-archive-hero__text,
.atlas-hero .agence-archive-hero__text,
.atlas-hero .mi-listings-hero p,
.atlas-hero .faq-premium-hero__text,
.atlas-hero .quartiers-hero__text {
  color: rgba(255,255,255,.90) !important;
  max-width: 790px;
  margin-left: auto !important;
  margin-right: auto !important;
  font-size: 1.02rem !important;
  line-height: 1.72 !important;
}

.atlas-hero .hero-kicker,
.atlas-hero .section-kicker,
.atlas-hero .guide-archive-hero__kicker,
.atlas-hero .quartier-archive-hero__kicker,
.atlas-hero .article-archive-hero__kicker,
.atlas-hero .agence-archive-hero__kicker,
.atlas-hero .mi-section-kicker,
.atlas-hero .faq-premium-hero__kicker,
.atlas-hero .quartiers-hero__kicker {
  display: inline-block;
  color: rgba(255,255,255,.82) !important;
  font-size: .72rem !important;
  font-weight: 700 !important;
  letter-spacing: .16em !important;
  text-transform: uppercase;
  margin: 0 auto 8px !important;
}

.atlas-hero .authority-actions,
.atlas-hero .hero-actions,
.atlas-hero .guide-archive-hero__cta,
.atlas-hero .quartier-archive-hero__cta,
.atlas-hero .article-archive-hero__cta,
.atlas-hero .agence-archive-hero__cta,
.atlas-hero .faq-premium-hero__cta,
.atlas-hero .quartiers-hero__cta {
  justify-content: center !important;
  align-items: center;
  gap: 12px;
  margin-top: 24px !important;
}

.atlas-hero .btn,
.atlas-hero .button,
.atlas-hero a.btn,
.atlas-hero .guide-archive-hero__cta a,
.atlas-hero .quartier-archive-hero__cta a,
.atlas-hero .article-archive-hero__cta a,
.atlas-hero .agence-archive-hero__cta a,
.atlas-hero .mi-listings-hero-links a {
  border-radius: 999px !important;
}

.atlas-hero .btn-primary,
.atlas-hero .btn-gold,
.atlas-hero a.btn-primary {
  background: #fff !important;
  border-color: #fff !important;
  color: #191612 !important;
  box-shadow: none !important;
}

.atlas-hero .btn-secondary-dark,
.atlas-hero .btn-secondary,
.atlas-hero a.btn-secondary-dark {
  background: rgba(255,255,255,.08) !important;
  border: 1px solid rgba(255,255,255,.45) !important;
  color: #fff !important;
}

/* Avoid old blue blocks and side layouts inside the listings hero */
.atlas-hero.mi-listings-hero .mi-listings-hero-inner {
  align-items: center;
}
.atlas-hero.mi-listings-hero .mi-listings-hero-copy {
  max-width: 820px;
}
.atlas-hero.mi-listings-hero .mi-listings-hero-links {
  min-width: 200px;
}
.atlas-hero.mi-listings-hero .mi-listings-hero-links a {
  color: #fff !important;
  border-color: rgba(255,255,255,.28) !important;
}

/* Compact mobile hero: no clipped titles, no oversized mastheads */
@media (max-width: 768px) {
  .atlas-hero {
    min-height: 245px;
    padding: 42px 0 38px !important;
    background-position: center !important;
  }

  .atlas-hero::before { background: rgba(16, 14, 12, .58); }

  .atlas-hero > .container,
  .atlas-hero .authority-hero-inner,
  .atlas-hero .guide-archive-hero__container,
  .atlas-hero .quartier-archive-hero__container,
  .atlas-hero .article-archive-hero__container,
  .atlas-hero .agence-archive-hero__container,
  .atlas-hero .mi-listings-hero-inner,
  .atlas-hero .mi-form-page-hero__inner {
    width: calc(100% - 30px) !important;
  }

  .atlas-hero h1,
  .atlas-hero .guide-archive-hero__title,
  .atlas-hero .quartier-archive-hero__title,
  .atlas-hero .article-archive-hero__title,
  .atlas-hero .agence-archive-hero__title,
  .atlas-hero .mi-listings-hero h1,
  .atlas-hero .faq-premium-hero__title,
  .atlas-hero .quartiers-hero__title {
    font-size: clamp(1.85rem, 9vw, 2.75rem) !important;
    line-height: 1.04 !important;
    margin-bottom: 12px !important;
    overflow-wrap: anywhere;
  }

  .atlas-hero p,
  .atlas-hero .hero-text,
  .atlas-hero .authority-lead,
  .atlas-hero .guide-archive-hero__text,
  .atlas-hero .quartier-archive-hero__text,
  .atlas-hero .article-archive-hero__text,
  .atlas-hero .agence-archive-hero__text,
  .atlas-hero .mi-listings-hero p,
  .atlas-hero .faq-premium-hero__text,
  .atlas-hero .quartiers-hero__text {
    font-size: .94rem !important;
    line-height: 1.58 !important;
    max-width: 38rem;
  }

  .atlas-hero .authority-actions,
  .atlas-hero .hero-actions,
  .atlas-hero .guide-archive-hero__cta,
  .atlas-hero .quartier-archive-hero__cta,
  .atlas-hero .article-archive-hero__cta,
  .atlas-hero .agence-archive-hero__cta {
    flex-direction: column;
    align-items: stretch !important;
    width: min(100%, 360px);
    margin-left: auto !important;
    margin-right: auto !important;
  }

  .atlas-hero .authority-actions .btn,
  .atlas-hero .hero-actions .btn,
  .atlas-hero .guide-archive-hero__cta a,
  .atlas-hero .quartier-archive-hero__cta a,
  .atlas-hero .article-archive-hero__cta a,
  .atlas-hero .agence-archive-hero__cta a {
    width: 100%;
    justify-content: center;
  }

  .atlas-hero.mi-listings-hero .mi-listings-hero-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 18px;
  }

  .atlas-hero.mi-listings-hero .mi-listings-hero-links {
    display: none !important;
  }
}
