/* Module 03 — Homepage hero only. Scoped to .mh-* classes.
   Tokens copied verbatim from the Module 02 locked Design System (Concept C).
   Does not modify component-library.css or any shared/global rule. */

/* Required for the "Get a Quote" anchor -> #quote-form to scroll smoothly.
   Necessarily document-level (anchor scrolling isn't scopable to one section),
   but purely behavioural — no visual/style change to any other element. */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

.mh-hero {
  --mh-ink: #101418;
  --mh-paper: #FFFFFF;
  --mh-mist: #F1F3F4;
  --mh-line: #E2E5E7;
  --mh-signal: #E4572E;
  --mh-signal-dark: #C43F1C;
  --mh-steel: #3A4048;
  --mh-slate: #53595E;
  --mh-fog: #8A9096;
  --mh-shadow-sm: 0 1px 2px rgba(16,20,24,.06);
  --mh-shadow-md: 0 4px 12px rgba(16,20,24,.10);

  background: var(--mh-paper);
  padding: 32px 20px 40px;
}

/* ---- photo variant: background image + dark overlay, per-page ---- */
/* background-image itself is set inline per page (data-driven, not hardcoded here);
   this modifier only supplies the readability treatment: overlay + light text. */
.mh-hero--photo {
  background-size: cover;
  background-position: center;
  position: relative;
}
.mh-hero--photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(16,20,24,.88), rgba(16,20,24,.68) 70%);
  pointer-events: none;
}
.mh-hero--photo .mh-hero__inner { position: relative; z-index: 1; }
.mh-hero--photo .mh-hero__eyebrow { color: #FF8B65; }
.mh-hero--photo .mh-hero__title { color: #FFFFFF; }
.mh-hero--photo .mh-hero__lede { color: rgba(255,255,255,.88); }
.mh-hero--photo .mh-btn--outline { border-color: #FFFFFF; color: #FFFFFF; }
.mh-hero--photo .mh-btn--outline:hover { background: #FFFFFF; color: var(--mh-ink); }
.mh-hero--photo .mh-chip {
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.3);
  color: #FFFFFF;
}
/* the form card stays a solid opaque surface regardless — always readable on any photo */

.mh-hero__inner {
  max-width: 1180px; /* matches the site's standard .bc-container width (--bc-container-w), so hero content lines up with every other section on every page */
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* ---- content column ---- */
.mh-hero__content {
  display: flex;
  flex-direction: column;
}

.mh-hero__eyebrow {
  display: block;
  font-family: 'IBM Plex Mono', 'Inter', monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--mh-signal);
  margin-bottom: 10px;
}

.mh-hero__title {
  font-family: 'Oswald', 'Arial Narrow', sans-serif;
  font-weight: 600;
  font-size: clamp(1.8rem, 1.55rem + 1.3vw, 2.6rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--mh-ink);
  margin: 0 0 14px;
  text-wrap: balance;
}

.mh-hero__lede {
  font-family: 'Inter', 'Segoe UI', sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--mh-slate);
  margin: 0 0 20px;
  max-width: 46ch;
}

.mh-hero__cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.mh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 4px;
  font-family: 'Inter', 'Segoe UI', sans-serif;
  font-weight: 700;
  font-size: .95rem;
  text-transform: uppercase;
  letter-spacing: .02em;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 150ms ease-out, color 150ms ease-out, border-color 150ms ease-out;
}
.mh-btn:focus-visible {
  outline: 2px solid var(--mh-signal-dark);
  outline-offset: 2px;
}

.mh-btn--primary {
  background: var(--mh-signal);
  color: #fff;
}
.mh-btn--primary:hover { background: var(--mh-signal-dark); }

.mh-btn--outline {
  background: transparent;
  border-color: var(--mh-ink);
  color: var(--mh-ink);
}
.mh-btn--outline:hover { background: var(--mh-ink); color: #fff; }

.mh-chip-row {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.mh-chip {
  font-family: 'Inter', sans-serif;
  font-size: .8125rem;
  font-weight: 600;
  color: var(--mh-ink);
  background: var(--mh-mist);
  border: 1px solid var(--mh-line);
  border-radius: 4px;
  padding: 6px 12px;
  white-space: nowrap;
}

/* ---- form column ---- */
/* scroll-margin-top clears the EXISTING site-header, which is position:sticky
   (component-library.css, out of this module's scope) and wraps to a taller
   multi-line nav on narrow viewports — without this, a scroll-to-#quote-form
   lands with the first form fields hidden underneath the pinned header. */
.mh-hero__form-col { scroll-margin-top: 260px; }

@media (min-width: 480px) {
  .mh-hero__form-col { scroll-margin-top: 120px; }
}
@media (min-width: 768px) {
  .mh-hero__form-col { scroll-margin-top: 16px; } /* form is already above the fold here */
}

.mh-form-card {
  background: var(--mh-paper);
  border: 1px solid var(--mh-line);
  border-radius: 6px;
  box-shadow: var(--mh-shadow-sm);
  padding: 24px;
}

.mh-form-card__title {
  font-family: 'Oswald', sans-serif;
  font-weight: 600;
  font-size: 1.2rem;
  text-transform: uppercase;
  color: var(--mh-ink);
  margin: 0 0 6px;
}

.mh-form-card__sub {
  font-family: 'Inter', sans-serif;
  font-size: .875rem;
  color: var(--mh-slate);
  margin: 0 0 18px;
}

.mh-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}
.mh-field label {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: .875rem;
  color: var(--mh-ink);
}
.mh-field input,
.mh-field textarea {
  font-family: 'Inter', sans-serif;
  font-size: .95rem;
  color: var(--mh-ink);
  background: var(--mh-paper);
  border: 1px solid var(--mh-line);
  border-radius: 4px;
  padding: 12px 14px;
  min-height: 48px;
}
.mh-field textarea { min-height: 84px; resize: vertical; }
.mh-field input:focus-visible,
.mh-field textarea:focus-visible {
  outline: 2px solid var(--mh-signal-dark);
  outline-offset: 1px;
  border-color: var(--mh-signal-dark);
}

.mh-form-card__submit { width: 100%; margin-top: 4px; }

.mh-form-card__note {
  margin: 14px 0 0;
  font-family: 'Inter', sans-serif;
  font-size: .75rem;
  color: var(--mh-fog);
  line-height: 1.4;
}

/* ---- tablet / desktop (form above the fold, scroll button hidden) ---- */
@media (min-width: 768px) {
  .mh-hero { padding: 48px 32px 56px; }
  .mh-hero__inner {
    flex-direction: row;
    align-items: flex-start;
    gap: 40px;
  }
  .mh-hero__content { flex: 1 1 52%; padding-top: 6px; }
  .mh-hero__form-col { flex: 1 1 44%; max-width: 440px; }
  .mh-cta-scroll { display: none; } /* form is already visible — no scroll target needed */
}

@media (min-width: 1024px) {
  .mh-hero { padding: 56px 48px 64px; }
  .mh-hero__inner { gap: 56px; }
}

@media (prefers-reduced-motion: reduce) {
  .mh-btn { transition: none; }
}
