/*
 * Homepage hero (first section). The top navigation is shared via /site-header.css.
 * Desktop values are in the 1920px design-sheet coordinate space (the sheet is zoomed
 * to the viewport), so the composition keeps the reference proportions at every
 * desktop width. Mobile (≤760px) uses a separate fluid layout.
 */

/* ---------- Shared hero tokens ---------- */
.home-hero,
.home-hero-mobile {
  --hh-navy: #051739;
  --hh-navy-2: #0a2253;
  --hh-red: #e30a13;
  --hh-red-dark: #b3040a;
  --hh-gold: #ffc21a;
  font-family: "Montserrat", "Inter", Arial, sans-serif;
  color: #fff;
}
.home-hero *,
.home-hero-mobile * { box-sizing: border-box; }

.home-hero-badge {
  display: inline-flex;
  align-items: center;
  margin: 0;
  border: 2px solid rgba(255, 255, 255, .92);
  border-radius: 999px;
  background: rgba(4, 16, 42, .62);
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(0, 8, 30, .28);
}
.home-hero-stars {
  color: var(--hh-gold);
  letter-spacing: .02em;
  text-shadow: 0 0 1px #3a2400, 0 1px 0 #6b4700;
}
.home-hero-title {
  margin: 0;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1;
  letter-spacing: -.012em;
  text-shadow: 0 3px 14px rgba(0, 8, 30, .45);
}
.home-hero-title-line { display: block; }
.home-hero-title .heading-accent { color: #f0161d; }
.home-hero-lead {
  margin: 0;
  font-weight: 700;
  line-height: 1.12;
  text-shadow: 0 2px 10px rgba(0, 8, 30, .45);
}
.home-hero-lead > span { display: block; }
.home-hero-copy {
  margin: 0;
  font-weight: 500;
  color: #f2f5fc;
  text-shadow: 0 1px 8px rgba(0, 8, 30, .5);
}
.home-hero-actions { display: flex; flex-wrap: wrap; }
.home-hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 3px solid #fff;
  border-radius: 999px;
  color: #fff;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(0, 8, 30, .32);
  transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease, filter .2s ease;
}
.home-hero-btn--primary { background: linear-gradient(180deg, #f2171e 0%, #c9050c 100%); }
.home-hero-btn--secondary { background: var(--hh-navy); }
.home-hero-btn:hover { transform: translateY(-2px); filter: brightness(1.08); box-shadow: 0 12px 26px rgba(0, 8, 30, .4); }
.home-hero-btn--secondary:hover { background: var(--hh-navy-2); }
.home-hero-btn-icon { flex: none; transition: transform .2s ease; }
.home-hero-btn:hover .home-hero-btn-icon { transform: translateX(3px); }

.home-hero-services { display: grid; grid-template-columns: 1fr 1fr; }
.home-hero-card {
  position: relative;
  display: block;
  overflow: hidden;
  border: 3px solid #fff;
  color: #fff;
  text-decoration: none;
  background: var(--hh-navy);
  box-shadow: 0 10px 24px rgba(0, 8, 30, .35);
  transition: transform .25s ease, box-shadow .25s ease;
}
.home-hero-card > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.home-hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 23, 57, 0) 20%, rgba(5, 23, 57, .55) 62%, rgba(5, 23, 57, .9) 100%);
}
.home-hero-card-label {
  position: absolute;
  z-index: 1;
  display: flex;
  align-items: center;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .55);
  white-space: nowrap;
}
.home-hero-card-icon { flex: none; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .5)); }
.home-hero-card-icon--heat { color: #f2171e; }
.home-hero-card-icon--cool { color: #fff; }
.home-hero-card:hover { transform: translateY(-3px); box-shadow: 0 16px 30px rgba(0, 8, 30, .45); }
.home-hero-card:hover > img { transform: scale(1.06); }

.home-hero a:focus-visible,
.home-hero-mobile a:focus-visible {
  outline: 3px solid #ffd84d;
  outline-offset: 4px;
}

/* ---------- Desktop hero (sheet coordinates) ---------- */
.home-hero {
  position: absolute;
  inset: 0;
  overflow: hidden;
  isolation: isolate;
  background: var(--hh-navy);
}
.home-hero-backdrop {
  position: absolute;
  inset: 0;
  z-index: -3;
  background: url("/assets/home-hero-technician-blur.webp") 70% 30% / cover no-repeat;
  opacity: .9;
}
.home-hero-photo {
  position: absolute;
  z-index: -2;
  right: -28px;
  top: 194px;
  width: auto;
  height: 870px;
  max-width: none;
  -webkit-mask-image:
    linear-gradient(90deg, transparent 0%, #000 22%),
    linear-gradient(180deg, transparent 0%, #000 7%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(90deg, transparent 0%, #000 22%),
    linear-gradient(180deg, transparent 0%, #000 7%);
  mask-composite: intersect;
}
.home-hero-shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(90deg,
      rgba(5, 23, 57, .98) 0%,
      rgba(5, 23, 57, .95) 30%,
      rgba(5, 23, 57, .8) 44%,
      rgba(5, 23, 57, .42) 54%,
      rgba(5, 23, 57, .1) 62%,
      rgba(5, 23, 57, 0) 70%),
    linear-gradient(0deg, rgba(5, 23, 57, .55) 0%, rgba(5, 23, 57, 0) 16%);
}
.home-hero-content {
  position: absolute;
  left: 79px;
  top: 214px;
  width: 1080px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.home-hero .home-hero-badge { height: 61px; padding: 0 24px 0 20px; gap: 12px; font-size: 22px; font-weight: 800; letter-spacing: -.012em; border-width: 2.5px; }
.home-hero .home-hero-stars { font-size: 35px; letter-spacing: 0; }
.home-hero .home-hero-title { margin-top: 10px; margin-left: 5px; font-size: 78px; font-weight: 800; line-height: .95; letter-spacing: -.004em; white-space: nowrap; }
.home-hero .home-hero-title-line + .home-hero-title-line { margin-top: 0; letter-spacing: -.036em; }
.home-hero .home-hero-lead { margin-top: 16px; margin-left: 5px; font-size: 37px; font-weight: 800; line-height: 1.05; letter-spacing: -.006em; }
.home-hero .home-hero-copy { margin-top: 14px; margin-left: 5px; width: 815px; font-size: 21.5px; line-height: 1.32; }
.home-hero .home-hero-actions { margin-top: 22px; gap: 24px; flex-wrap: nowrap; }
.home-hero .home-hero-btn { height: 70px; width: 427px; padding: 0 30px; gap: 22px; font-size: 27px; font-weight: 800; border-width: 3px; }
.home-hero .home-hero-btn--secondary { width: 324px; padding: 0 30px; }
.home-hero .home-hero-btn-icon { width: 22px; height: 22px; }
.home-hero .home-hero-services { margin-top: 20px; gap: 24px; width: 942px; }
.home-hero .home-hero-card { height: 147px; border-radius: 20px; }
.home-hero .home-hero-card::after { background: linear-gradient(180deg, rgba(5, 23, 57, 0) 12%, rgba(5, 23, 57, .5) 52%, rgba(5, 23, 57, .92) 100%); }
.home-hero .home-hero-card-label { left: 27px; bottom: 17px; gap: 16px; font-size: 28px; letter-spacing: -.012em; }
.home-hero .home-hero-card-icon { width: 54px; height: 54px; }

/* Entrance: gentle fade/rise of the copy and a soft settle of the photo. */
@keyframes home-hero-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes home-hero-settle { from { opacity: 0; transform: scale(1.04); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: no-preference) {
  .home-hero-photo,
  .home-hero-mobile-media > img { animation: home-hero-settle .9s ease-out both; transform-origin: 60% 30%; }
  :is(.home-hero-content, .home-hero-mobile-body) > * { animation: home-hero-rise .6s ease-out both; }
  :is(.home-hero-content, .home-hero-mobile-body) > :nth-child(2) { animation-delay: .06s; }
  :is(.home-hero-content, .home-hero-mobile-body) > :nth-child(3) { animation-delay: .12s; }
  :is(.home-hero-content, .home-hero-mobile-body) > :nth-child(4) { animation-delay: .18s; }
  :is(.home-hero-content, .home-hero-mobile-body) > :nth-child(5) { animation-delay: .24s; }
  :is(.home-hero-content, .home-hero-mobile-body) > :nth-child(6) { animation-delay: .3s; }
}
@media (prefers-reduced-motion: reduce) {
  .home-hero-btn, .home-hero-card, .home-hero-card > img, .home-hero-btn-icon { transition: none; }
  .home-hero-btn:hover, .home-hero-card:hover, .home-hero-card:hover > img { transform: none; }
}

/* Narrow desktop/tablet: the sheet scales down, so enlarge the copy for legibility. */
@media (min-width: 761px) and (max-width: 1100px) {
  .home-hero .home-hero-content { width: 1140px; }
  .home-hero .home-hero-badge { font-size: 25px; height: 62px; }
  .home-hero .home-hero-title { font-size: 80px; }
  .home-hero .home-hero-lead { font-size: 40px; }
  .home-hero .home-hero-copy { width: 980px; font-size: 26px; line-height: 1.36; }
  .home-hero .home-hero-actions { margin-top: 26px; }
  .home-hero .home-hero-btn { font-size: 30px; height: 74px; width: auto; padding: 0 40px; }
  .home-hero .home-hero-btn--secondary { width: auto; padding: 0 44px; }
  .home-hero .home-hero-services { margin-top: 22px; width: 1000px; }
  .home-hero .home-hero-card { height: 132px; }
  .home-hero .home-hero-card-label { font-size: 34px; }
  .home-hero-shade {
    background:
      linear-gradient(90deg, rgba(5, 23, 57, .98) 0%, rgba(5, 23, 57, .94) 40%, rgba(5, 23, 57, .7) 56%, rgba(5, 23, 57, .15) 70%, rgba(5, 23, 57, 0) 78%),
      linear-gradient(0deg, rgba(5, 23, 57, .55) 0%, rgba(5, 23, 57, 0) 16%);
  }
}

/* ---------- Homepage navigation (desktop) ---------- */
/* The hero now supplies its own lighting: drop the dark band that sat behind the header. */
.design-sheet[data-design-page="675:5"] [data-node-id="675:54"] { display: none; }

/* Wordmark, menu, separators and action pills now live in the shared /site-header.css. */

/* ---------- Mobile hero (≤760px) ---------- */
.home-hero-mobile { display: none; }
@media (max-width: 760px) {
  .home-hero-mobile {
    display: block;
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background:
      radial-gradient(ellipse 120% 60% at 80% 0%, #10306a 0%, rgba(16, 48, 106, 0) 70%),
      var(--hh-navy);
    padding-bottom: 30px;
  }
  .home-hero-mobile-media {
    position: relative;
    z-index: -1;
    height: clamp(300px, 92vw, 520px);
    overflow: hidden;
  }
  .home-hero-mobile-media > img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 62% 0%;
  }
  .home-hero-mobile-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
      linear-gradient(180deg, rgba(5, 23, 57, 0) 38%, rgba(5, 23, 57, .7) 72%, var(--hh-navy) 100%),
      linear-gradient(90deg, rgba(5, 23, 57, .55) 0%, rgba(5, 23, 57, 0) 45%);
  }
  .home-hero-mobile-body {
    margin-top: clamp(-120px, -24vw, -80px);
    padding: 0 clamp(18px, 5vw, 32px);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }
  .home-hero-mobile .home-hero-badge {
    max-width: 100%;
    gap: 8px;
    padding: 8px 14px 8px 11px;
    font-size: clamp(11.5px, 3.2vw, 14px);
    white-space: normal;
    line-height: 1.2;
  }
  .home-hero-mobile .home-hero-stars { font-size: clamp(14px, 4vw, 18px); white-space: nowrap; }
  .home-hero-mobile .home-hero-title {
    margin-top: 16px;
    font-size: clamp(29px, 8.4vw, 52px);
    line-height: 1.04;
  }
  .home-hero-mobile .home-hero-lead {
    margin-top: 14px;
    font-size: clamp(18px, 5vw, 26px);
    line-height: 1.2;
  }
  .home-hero-mobile .home-hero-lead > span { display: inline; }
  .home-hero-mobile .home-hero-copy {
    margin-top: 14px;
    font-size: clamp(15px, 4vw, 17px);
    line-height: 1.6;
  }
  .home-hero-mobile .home-hero-actions {
    margin-top: 22px;
    gap: 12px;
    width: 100%;
  }
  .home-hero-mobile .home-hero-btn {
    flex: 1 1 210px;
    min-height: 54px;
    padding: 0 20px;
    gap: 12px;
    font-size: clamp(16px, 4.4vw, 18px);
    border-width: 2.5px;
  }
  .home-hero-mobile .home-hero-btn-icon { width: 15px; height: 15px; }
  .home-hero-mobile .home-hero-services {
    margin-top: 18px;
    gap: 12px;
    width: 100%;
  }
  .home-hero-mobile .home-hero-card { height: clamp(96px, 28vw, 150px); border-radius: 16px; border-width: 2.5px; }
  .home-hero-mobile .home-hero-card-label {
    left: 12px;
    right: 10px;
    bottom: 12px;
    gap: 8px;
    font-size: clamp(14px, 3.9vw, 20px);
    white-space: normal;
    line-height: 1.1;
  }
  .home-hero-mobile .home-hero-card-icon { width: clamp(22px, 6vw, 30px); height: clamp(22px, 6vw, 30px); }
}
@media (max-width: 360px) {
  .home-hero-mobile .home-hero-services { grid-template-columns: 1fr 1fr; gap: 10px; }
  .home-hero-mobile .home-hero-card-label { font-size: 13px; }
}

/* Homepage mobile header: navy phone pill with white outline, matching the desktop pills. */
@media (max-width: 760px) {
  body:has(.home-hero-mobile) .mobile-navigation .mobile-call {
    background: #051739;
    color: #fff;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0, 10, 35, .3);
  }
  body:has(.home-hero-mobile) .mobile-navigation .mobile-call img { filter: brightness(0) invert(1); }
  body:has(.home-hero-mobile) .mobile-navigation .mobile-schedule {
    background: linear-gradient(180deg, #f2171e 0%, #c9050c 100%);
  }
}
