/* FINAL LAYOUT FIX
   1. Quote popup always clears the sticky header
   2. Contact page columns cannot spill into the footer
   3. Long contact/address text wraps instead of being clipped
*/

/* ---------- QUOTE MODAL / POPUP ---------- */
.modal{
  z-index:2500!important;
  padding:125px 18px 30px!important;
  overflow-y:auto!important;
}
.modal-dialog{
  margin:0 auto 30px!important;
  min-height:0!important;
  width:min(100%,560px)!important;
}
.modal-dialog-centered{
  display:block!important;
  min-height:0!important;
}
.modal-content{
  max-height:none!important;
  overflow:visible!important;
}
.modal-header{
  position:relative!important;
  top:auto!important;
  background:#fff!important;
  z-index:2;
}
.modal-body{
  overflow:visible!important;
}
body.modal-open,
body:has(.modal.show){
  overflow:hidden;
}

/* ---------- CONTACT PAGE ---------- */
body.page-contact .section{
  position:relative;
  z-index:1;
  overflow:visible!important;
  padding-bottom:85px!important;
}
body.page-contact .section > .container{
  position:relative;
  overflow:visible!important;
}
body.page-contact .section > .container > .row{
  display:flex!important;
  flex-wrap:wrap!important;
  align-items:flex-start!important;
  height:auto!important;
  min-height:0!important;
}
body.page-contact .section > .container > .row > [class*="col-"]{
  position:relative!important;
  height:auto!important;
  min-height:0!important;
  align-self:flex-start!important;
}
body.page-contact .contact-card,
body.page-contact .contact-form{
  position:relative!important;
  top:auto!important;
  bottom:auto!important;
  left:auto!important;
  right:auto!important;
  transform:none!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  overflow:visible!important;
  margin:0!important;
}
body.page-contact .contact-card{
  margin-top:24px!important;
}
body.page-contact .contact-card p,
body.page-contact .contact-card a,
body.page-contact .col-lg-5 p{
  white-space:normal!important;
  overflow-wrap:anywhere!important;
  word-break:normal!important;
}
body.page-contact .contact-form textarea{
  min-height:150px;
}
body.page-contact .site-footer,
body.page-contact .cta-band{
  position:relative!important;
  clear:both!important;
  z-index:2;
  margin-top:0!important;
}

/* ---------- MOBILE ---------- */
@media(max-width:991.98px){
  .modal{
    padding-top:125px!important;
  }
  body.page-contact .section{
    padding-bottom:65px!important;
  }
  body.page-contact .contact-form{
    margin-top:30px!important;
  }
}
@media(max-width:575.98px){
  .modal{
    padding:112px 10px 20px!important;
  }
  .modal-dialog{
    width:100%!important;
  }
  .modal-body,
  .modal-header,
  .modal-footer{
    padding-left:16px!important;
    padding-right:16px!important;
  }
  body.page-contact .section{
    padding-bottom:55px!important;
  }
}
