.hero {
  background-image: var(--bg-desktop) !important;
  position: relative;
  width: 100vw !important;
  left: 50% !important;
  right: 50% !important;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
  min-height: 750px;
  display: flex;
  align-items: center;
  background-size: cover !important;
  background-repeat: no-repeat !important;
  overflow: hidden;
}
/* Hero Logo */
.hero .hero-logo {
  margin-bottom: 1.5em;
}
.hero .hero-logo img {
  display: block;
  max-width: 500px;
  height: auto;
}

/* Hero Buttons */
.hero .hero-button-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1em;
  margin-top: 1.75em;
}
.hero-body-text, p{
  font-size: 1.25rem;
  margin: 1.25rem 0 0; !important;
}

.hero-gradient-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: var(--overlay-desktop);
}

.hero-inner-container {
  max-width: 1290px;
  width: 100%;
  padding: 3em 1.5em calc(80px + 2em); /* bottom clears the 80px wave */
  margin: 0 auto;
  position: relative;
  z-index: 2;
}
/* Content position (box placement) */
.hero .hero-text-content--right { margin-left: auto; }

/* Text alignment (copy inside the box) */
.hero .hero-text-content--align-center { text-align: center; }
.hero .hero-text-content--align-right  { text-align: right; }

.hero .hero-text-content--align-center .hero-logo img { margin-left: auto; margin-right: auto; }
.hero .hero-text-content--align-right  .hero-logo img { margin-left: auto; }

.hero .hero-text-content--align-center .hero-title-divider { margin: .5em auto 0; }
.hero .hero-text-content--align-right  .hero-title-divider { margin: .5em 0 0 auto; }

.hero .hero-text-content--align-center .hero-button-group { justify-content: center; }
.hero .hero-text-content--align-right  .hero-button-group { justify-content: flex-end; }
.hero .hero-title-divider {
  width: 75%;
  height: 2px;
  background-color: #A7AD37 !important;
  margin: 0.5em 0 0 0;
}
.hero .hero-main-title {
  display: inline-block;
  width: auto !important;
  max-width: 100% !important;
}
.hero .hero-main-title h1,
.hero .hero-main-title h2 {
  display: inline !important;
  width: auto !important;
  max-width: 100% !important;
}
.hero-bottom-separator {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  line-height: 0;
  z-index: 3;
}
.hero-bottom-separator svg {
  position: relative;
  display: block;
  width: calc(100% + 1.3px);
  height: 80px;
}
.hero-bottom-separator svg path { fill: var(--divider-fill, #FFFFFF); }

.hero .hero-inner-container .hero-text-content {
  width: var(--desktop-width, 45%) !important;
  max-width: var(--desktop-width, 45%) !important;
}

@media screen and (max-width: 1026px) {
.hero {
    width: 100vw !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    margin: 0 !important;
    background-clip: initial !important;
    padding: 2em 0!important;
    min-height: 400px;
}
  .hero .hero-inner-container {padding: 0 1.5rem calc(40px + 1rem) 1.5rem;}
  .hero .hero-logo img {
    max-width: 300px;
  }
 .hero .hero-button-group {
    margin-top: 1.5em;
  }
 .hero .hero-inner-container .hero-text-content {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    display: block !important;
  }
  .hero-gradient-overlay {
    background: var(--overlay-mobile);
  }
.hero .hero-bottom-separator svg {
    height: 40px !important; /* Forces the wave to be shallower */
    transform: scaleY(0.7) !important; /* Flattens the curves */
    transform-origin: bottom !important;
  }
 .hero .hero-title-divider {
    width: 100%;
  }
  .hero-body-text p{
    padding-top:0; 
    font-size: 1.125rem!important;
    line-height: 1.375;
  }
}
@media (max-width: 767px) {
  .hero { background-image: var(--bg-mobile) !important; }

  .hero .hero-button-group {
    display: grid;
    grid-template-columns: max-content;
    justify-content: start;
  }
  .hero .hero-button-group .tutera-btn {
    width: 100%;
  }
}

/* ============================================================
   FORM MODAL
   Hidden but LAID OUT at load (visibility/opacity, never
   display:none) so the HubSpot form iframe can measure itself.
   Same layout as the Community - Home Hero modal.
   ============================================================ */
.hero-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 1.5rem;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, visibility .2s ease;
}
.hero-modal.is-open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}
.hero-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .6);
}
.hero-modal__box {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: 1240px;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  padding: 3.5rem 3rem 3rem;
}
.hero-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  border-radius: 50%;
  background: #003C4D;
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}
body.hero-modal-open { overflow: hidden; }

/* ---------- Modal: two-column layout ---------- */
.hero-modal__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 3.5rem;
  align-items: start;
}
.hero-modal__form {
  min-width: 0;
  /* min-height: 480px;  uncomment if a step form renders short */
}

.hero-modal__aside { text-align: left; }
.hero-modal__logo {
  display: block;
  width: 100% !important;
  max-width: 320px !important;
  height: auto;
  margin-bottom: 2rem;
}
.hero-modal__aside p {
  margin: 0 0 1.75rem;
  font-size: 1.125rem;
  line-height: 1.6;
  color: #555;
}
.hero-modal__aside a { color: inherit; text-decoration: underline; }

/* Phone line: hidden on desktop, shown when stacked */
.hero-modal__phone { display: none; }

/* ---------- Modal: level-of-care badges
   Same look as the Community Search Advanced cards ---------- */
.hero-modal__loc {
  display: flex;
  flex-wrap: wrap;
  row-gap: .5rem;
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
}
.hero-modal__loc-item {
  --badge: #003C4D;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 999px;
  background: var(--badge);
  color: #fff;
  font-size: 14px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: .02em;
  position: relative;
}
.hero-modal__loc-item + .hero-modal__loc-item { margin-left: -14px; }

.hero-modal__loc-item--il  { --badge: #003C4D; }
.hero-modal__loc-item--al  { --badge: #bf7041; }
.hero-modal__loc-item--ltc { --badge: #A7AD37; }
.hero-modal__loc-item--rc  { --badge: #76AE99; }
.hero-modal__loc-item--mc  { --badge: #006D70; }
.hero-modal__loc-item--stc { --badge: #757A4D; }
.hero-modal__loc-item--sc  { --badge: #5299B2; }

.hero-modal__sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Tablet + mobile: stack, trim left column to logo / badges / phone */
@media (max-width: 1026px) {
  .hero-modal__grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .hero-modal__aside {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .hero-modal__logo { max-width: 240px !important; margin-bottom: 1rem; }
  .hero-modal__loc { justify-content: center; margin-bottom: 1rem; }
  .hero-modal__loc-item { width: 44px; height: 44px; font-size: 13px; }
  .hero-modal__copy { display: none; }
  .hero-modal__phone {
    display: block;
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
  }
  .hero-modal__phone a { color: #003C4D; text-decoration: none; }
}
@media (max-width: 767px) {
  .hero-modal__box { padding: 2.75rem 1.25rem 1.5rem; }
}

.hero .hero-button-group .hero-btn-icon {
  display: inline-flex;
  margin-left: .6em;
}
.hero .hero-button-group .hero-btn-icon svg {
  width: .9em;
  height: .9em;
  fill: currentColor;
}

/* ============================================================
   HUBSPOT FORM CSS (modal only)
   Same rules as Community - Home Hero, scoped to .hero-modal so
   they don't touch other forms on the page.
   ============================================================ */

/* Radios as buttons */
.hero-modal .hsfc-FieldLabel:has(.hsfc-RadioInput) .hsfc-RadioInput {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-RadioInput) {
  display: flex;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
  min-height: 50px;
  padding: 10px 20px;
  margin: 0;
  cursor: pointer;
  background-color: #757A4D;
  transition: all 0.2s ease;
  user-select: none;
  color: white !important;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-RadioInput):hover {
  background-color: #003C4D;
  color: white;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-RadioInput:checked) {
  background-color: #003C4D;
  color: white;
}

.hero-modal .hsfc-CheckboxField { line-height: 20px !important; }

/* Checkboxes as buttons, except the two consent fields */
.hero-modal .hsfc-FieldLabel:has(.hsfc-CheckboxInput):not(:has(input[name="0-1/marketing_consent"])):not(:has(input[name="0-1/inquiry_consent"])) .hsfc-CheckboxInput {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-CheckboxInput):not(:has(input[name="0-1/marketing_consent"])):not(:has(input[name="0-1/inquiry_consent"])) {
  display: flex;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
  min-height: 50px;
  padding: 10px 20px;
  margin: 0;
  cursor: pointer;
  background-color: #757A4D;
  transition: all 0.2s ease;
  user-select: none;
  color: white !important;
  border-radius: 4px;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-CheckboxInput):not(:has(input[name="0-1/marketing_consent"])):not(:has(input[name="0-1/inquiry_consent"])):hover {
  background-color: #003C4D;
}
.hero-modal .hsfc-FieldLabel:has(.hsfc-CheckboxInput:checked):not(:has(input[name="0-1/marketing_consent"])):not(:has(input[name="0-1/inquiry_consent"])) {
  background-color: #003C4D;
  color: white;
}

/* Consent fields: regular checkbox + text side by side */
.hero-modal .hsfc-FieldLabel:has(input[name="0-1/marketing_consent"]),
.hero-modal .hsfc-FieldLabel:has(input[name="0-1/inquiry_consent"]) {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: flex-start !important;
  background: transparent !important;
  border: none !important;
  padding: 5px 0 !important;
  margin: 0 !important;
  width: 100% !important;
  cursor: pointer;
  gap: 0 !important;
}
.hero-modal .hsfc-FieldLabel:has(input[name*="consent"]) .hsfc-CheckboxInput {
  position: relative !important;
  display: inline-block !important;
  opacity: 1 !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  margin-right: 12px !important;
  margin-top: 2px !important;
  flex-shrink: 0 !important;
  pointer-events: auto !important;
}
.hero-modal .hsfc-FieldLabel:has(input[name*="consent"]) svg,
.hero-modal .hsfc-FieldLabel:has(input[name*="consent"]) .hsfc-CheckboxInput::after {
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  width: 12px !important;
  height: 12px !important;
  margin: 0 !important;
  display: block !important;
}
.hero-modal .hsfc-FieldLabel:has(input[name*="consent"]) span {
  display: inline-block !important;
  color: #333 !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  padding: 0 !important;
  margin: 0 !important;
  pointer-events: auto !important;
}

.hero-modal .hsfc-TextInput { height: 42px !important; font-size: 16px !important; }
.hero-modal .hsfc-Button { font-size: 20px !important; }