/* REALPRO V62 — Contact hero top-spacing correction
   Keeps the eyebrow in the normal hero flow and separates it cleanly from the header logo. */

html body.rp-page-contact main#main > section.rp-contact-hero[data-rp-surface="dark"]{
  /* Keep lower space compact while giving the composition a slightly lower optical position. */
  padding-top:clamp(14px,2vh,24px) !important;
  padding-bottom:clamp(7px,1.05vh,12px) !important;
}

html body.rp-page-contact .rp-contact-hero__content{
  /* Small optical drop: enough separation from the header without sacrificing first-viewport fit. */
  transform:translateY(clamp(8px,1.05vh,12px)) !important;
}

/* Critical fix: the eyebrow must remain in normal document flow directly above the title. */
html body.rp-page-contact .rp-contact-hero__content > .rp-contact-eyebrow{
  position:static !important;
  inset:auto !important;
  top:auto !important;
  right:auto !important;
  bottom:auto !important;
  left:auto !important;
  float:none !important;
  clear:both !important;
  order:0 !important;
  align-self:flex-start !important;
  display:block !important;
  width:auto !important;
  max-width:100% !important;
  height:auto !important;
  min-height:0 !important;
  margin:0 0 clamp(7px,.85vh,9px) !important;
  padding:0 !important;
  transform:none !important;
  translate:none !important;
  z-index:auto !important;
}

html body.rp-page-contact .rp-contact-hero__content > h1#rp-contact-title{
  order:1 !important;
}
html body.rp-page-contact .rp-contact-hero__content > p:not(.eyebrow){
  order:2 !important;
}
html body.rp-page-contact .rp-contact-hero__content > .rp-contact-hero__details{
  order:3 !important;
}

/* Reduced-height desktops: preserve visibility before adding vertical displacement. */
@media (min-width:768px) and (max-height:820px){
  html body.rp-page-contact main#main > section.rp-contact-hero[data-rp-surface="dark"]{
    padding-top:10px !important;
    padding-bottom:7px !important;
  }
  html body.rp-page-contact .rp-contact-hero__content{
    transform:translateY(5px) !important;
  }
  html body.rp-page-contact .rp-contact-hero__content > .rp-contact-eyebrow{
    margin-bottom:6px !important;
  }
}

@media (min-width:768px) and (max-height:680px){
  html body.rp-page-contact main#main > section.rp-contact-hero[data-rp-surface="dark"]{
    padding-top:6px !important;
    padding-bottom:5px !important;
  }
  html body.rp-page-contact .rp-contact-hero__content{
    transform:translateY(2px) !important;
  }
  html body.rp-page-contact .rp-contact-hero__content > .rp-contact-eyebrow{
    margin-bottom:4px !important;
  }
}

/* Mobile: maintain a visible safe gap below the header while protecting the bottom contact row. */
@media (max-width:767px){
  html body.rp-page-contact main#main > section.rp-contact-hero[data-rp-surface="dark"]{
    padding-top:10px !important;
    padding-bottom:8px !important;
  }
  html body.rp-page-contact .rp-contact-hero__content{
    transform:translateY(4px) !important;
  }
  html body.rp-page-contact .rp-contact-hero__content > .rp-contact-eyebrow{
    margin-bottom:5px !important;
  }
}

@media (max-width:767px) and (max-height:640px){
  html body.rp-page-contact .rp-contact-hero__content{
    transform:translateY(1px) !important;
  }
  html body.rp-page-contact .rp-contact-hero__content > .rp-contact-eyebrow{
    margin-bottom:3px !important;
  }
}
