/* ═══════════════════════════════════════════════
   Hero Module — Integrity Home Exteriors
   Mobile-first responsive, CSS variable-driven
   ═══════════════════════════════════════════════ */

.ihe-hero {
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
  background-size: cover;
  background-position: var(--bg-pos-mobile, center center);
  background-repeat: no-repeat;
  background-attachment: scroll;
  height: var(--hero-h-mobile, 50vh);
  min-height: 280px;
}

@supports (height: 1dvh) {
  .ihe-hero {
    height: calc(var(--hero-h-mobile, 50) * 1dvh);
  }
}

.ihe-hero__overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: #000000;
  z-index: 1;
  pointer-events: none;
}

.ihe-hero__inner {
  position: relative;
  z-index: 2;
  width: 90%;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 80px 0 28px 0;
}

.ihe-hero__headline {
  margin: 0 0 12px 0;
  padding: 0;
  font-family: 'Montserrat', 'Gotham', sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  text-shadow: -6px -6px 15px rgba(255, 255, 255, 0.15);
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
  font-size: clamp(24px, calc(var(--headline-size, 65px) * 0.5), var(--headline-size, 65px));
  line-height: clamp(22px, calc(var(--headline-lh, 55px) * 0.55), var(--headline-lh, 55px));
  max-width: 100%;
}

.ihe-hero__accent {
  font-style: normal;
}

.ihe-hero__description {
  font-family: 'Montserrat', 'Gotham', sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  opacity: 0.85;
  max-width: 100%;
  margin-bottom: 20px;
}

.ihe-hero__description p { margin: 0; }

.ihe-hero__buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-wrap: wrap;
  width: 100%;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.ihe-hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 14px 28px;
  font-family: 'Montserrat', 'Gotham', sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  text-decoration: none;
  border-radius: 0;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.4s ease, border-color 0.4s ease;
}

.ihe-hero__btn span {
  position: relative;
  z-index: 2;
}

.ihe-hero__btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.8s cubic-bezier(0.23, 1, 0.32, 1),
              height 0.8s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 1;
  pointer-events: none;
}

.ihe-hero__btn:hover::after {
  width: 500px;
  height: 500px;
}

/* Primary: gold fill → black wipe, gold text */
.ihe-hero__btn--primary {
  background-color: #EAAA00;
  color: #333132;
  border: 2px solid #EAAA00;
}
.ihe-hero__btn--primary span { color: #333132; }
.ihe-hero__btn--primary::after { background: #333132; }
.ihe-hero__btn--primary:hover { color: #EAAA00; border-color: #333132; }
.ihe-hero__btn--primary:hover span { color: #EAAA00; }

/* Secondary: transparent outline → gold wipe, dark text */
.ihe-hero__btn--secondary {
  background-color: transparent;
  color: #FFFFFF;
  border: 2px solid #FFFFFF;
}
.ihe-hero__btn--secondary span { color: #FFFFFF; }
.ihe-hero__btn--secondary::after { background: #EAAA00; }
.ihe-hero__btn--secondary:hover { color: #333132; border-color: #EAAA00; }
.ihe-hero__btn--secondary:hover span { color: #333132; }


/* ── Tablet (768px+) ── */

@media only screen and (min-width: 768px) {
  .ihe-hero {
    background-position: var(--bg-pos, center center);
    height: var(--hero-h, 50vh);
    min-height: 420px;
  }

  @supports (height: 1dvh) {
    .ihe-hero {
      height: calc(var(--hero-h, 50) * 1dvh);
    }
  }

  .ihe-hero__inner {
    width: 85%;
    padding: 180px 0 40px 0;
  }

  .ihe-hero__headline {
    font-size: calc(var(--headline-size, 65px) * 0.72);
    line-height: calc(var(--headline-lh, 55px) * 0.75);
  }

  .ihe-hero__buttons {
    flex-direction: row;
    width: auto;
  }

  .ihe-hero__btn {
    width: auto;
    padding: 14px 36px;
    font-size: 13px;
  }
}


/* ── Desktop (1024px+) ── */

@media only screen and (min-width: 1024px) {
  .ihe-hero {
    background-attachment: fixed;
  }

  .ihe-hero__inner {
    padding: 220px 0 40px 0;
  }

  .ihe-hero__headline {
    font-size: calc(var(--headline-size, 65px) * 0.85);
    line-height: calc(var(--headline-lh, 55px) * 0.88);
  }
}


/* ── Large Desktop (1440px+) ── */

@media only screen and (min-width: 1440px) {
  .ihe-hero__headline {
    font-size: var(--headline-size, 65px);
    line-height: var(--headline-lh, 55px);
  }
}