/* =========================================================
   Prime Land — responsive pass
   Breakpoints: 1200 / 1024 (tablet) / 900 / 767 (mobile) / 560 / 420
   Loaded last so it wins over the module stylesheets.
   ========================================================= */

/* ---------- global overflow guards ---------- */
html,body{max-width:100%;overflow-x:hidden}
*,*::before,*::after{box-sizing:border-box}
img,svg,video,iframe{max-width:100%}
img{height:auto}
.e-con,.e-con-inner,.elementor-widget,.elementor-widget-container{min-width:0}
.elementor-section,.e-con{max-width:100%}

/* grids must never force their tracks wider than the viewport */
.pl-g2,.pl-g3,.pl-g4,.pl-g5,.pl-row2,.pl-fgrid,.pl-shead,.pl-faqsplit,.pl-cta,.pl-fcard{max-width:100%}
.pl-g2 > *,.pl-g3 > *,.pl-g4 > *,.pl-g5 > *,.pl-row2 > *,
.pl-fgrid > *,.pl-faqsplit > *,.pl-cta > *,.pl-fcard > *{min-width:0}

/* long unbroken strings (emails, refs) shouldn't push layout */
p,li,span,h1,h2,h3,h4,.elementor-heading-title,
.elementor-icon-list-text,.elementor-icon-box-description{overflow-wrap:break-word}

/* ---------- desktop-down: 1200 ---------- */
@media (max-width:1200px){
  .pl-g5{grid-template-columns:repeat(3,minmax(0,1fr)) !important}
  .plh-slot{height:auto;min-height:300px}
}

/* ---------- tablet: 1024 ---------- */
@media (max-width:1024px){
  /* section rhythm tightens */
  .e-con.e-parent > .e-con-inner{padding-left:20px;padding-right:20px}

  /* grids */
  .pl-g5,.pl-g4{grid-template-columns:repeat(2,minmax(0,1fr)) !important}
  .pl-g3{grid-template-columns:repeat(2,minmax(0,1fr)) !important}
  .pl-g2,.pl-row2{grid-template-columns:1fr !important}
  .pl-fcard{grid-template-columns:1fr !important}

  /* section header: heading over link */
  .pl-shead{flex-direction:column;align-items:flex-start;gap:14px}
  .pl-shead > *{width:100% !important}
  .pl-slink .elementor-widget-container{text-align:left}

  /* FAQ: stack, and no reserved gutter for the rail */
  .pl-faqsplit{grid-template-columns:1fr !important;gap:30px !important;padding-right:0}

  /* CTA strips stack with left-aligned buttons */
  .pl-cta{grid-template-columns:1fr !important;text-align:left}
  .pl-cta .elementor-widget-button{width:auto}

  /* property cards */
  .card-deck{grid-template-columns:repeat(2,minmax(0,1fr)) !important}

  /* hero */
  .plh-el{padding-top:40px !important;padding-bottom:44px !important}
  .plh-h1 .elementor-heading-title{font-size:38px !important;line-height:1.1 !important}
  .plh-subw .elementor-widget-container{font-size:15px;max-width:100%}
  .plh-slot{min-height:270px}
  .plh-spin,.plh-spinw{display:none !important}

  /* hero search: two fields per row, button full width */
  .plh-search{flex-wrap:wrap;padding:8px}
  .plh-sf{flex:1 1 calc(50% - 4px) !important;border-right:0 !important;padding:8px 14px}
  .plh-btn{flex:1 1 100%;margin:8px 0 0}

  /* hero stats: two up */
  .plh-el .pl-g4{grid-template-columns:repeat(2,minmax(0,1fr)) !important;gap:20px !important}

  /* Houzez advanced search */
  .pl-hzsearch .form-group,
  .pl-hzsearch .col-md-3,
  .pl-hzsearch .col-md-4,
  .pl-hzsearch .col-lg-3{width:50% !important;flex:0 0 50% !important;max-width:50% !important}

  /* marquee */
  .pl-mqi{font-size:32px}
  .pl-mqtrack{gap:36px}
}

/* ---------- small tablet / large phone: 900 ---------- */
@media (max-width:900px){
  .pl-band{padding-top:52px !important;padding-bottom:56px !important}
  .pl-band::before,.pl-band::after{width:360px;height:360px}
  .pl-vmbox .elementor-icon-box-title{font-size:19px !important}
  .pl-ftcta{flex-direction:column;align-items:flex-start;gap:20px}
}

/* ---------- mobile: 767 ---------- */
@media (max-width:767px){
  /* one column everywhere */
  .pl-g2,.pl-g3,.pl-g4,.pl-g5,.pl-row2,.card-deck{grid-template-columns:1fr !important}
  .pl-g5,.pl-g4,.pl-g3{gap:16px !important}

  /* section padding */
  .e-con.e-parent > .e-con-inner{padding-left:16px;padding-right:16px}
  .e-con.e-parent{padding-top:clamp(34px,7vw,48px) !important;padding-bottom:clamp(6px,2vw,14px) !important}

  /* typography scale */
  .pl-head .elementor-heading-title{font-size:23px !important;line-height:1.22 !important}
  .pl-eyebrow .elementor-heading-title{font-size:11px !important;letter-spacing:.18em !important}
  .pl-ibox .elementor-icon-box-title{font-size:16px !important}
  .pl-ibox .elementor-icon-box-description{font-size:13px !important}
  .pl-vmbox .elementor-icon-box-title{font-size:18px !important}
  .pl-fthead .elementor-heading-title{font-size:21px !important}

  /* hero */
  .plh-el{padding-top:30px !important;padding-bottom:34px !important}
  .plh-h1 .elementor-heading-title{font-size:27px !important;line-height:1.16 !important;margin-top:12px}
  .plh-subw .elementor-widget-container{font-size:14.5px;margin-top:12px}
  .plh-pillw .elementor-heading-title{font-size:10px !important;padding:8px 14px;letter-spacing:.14em !important}
  .plh-slot{min-height:0}
  .plh-slot > .e-con{position:relative;display:none}
  .plh-slot > .e-con.on{display:block}

  /* hero search: one field per row */
  .plh-sf{flex:1 1 100% !important;padding:9px 14px}
  .plh-nav{margin:4px 0 14px}
  .plh-tabs{gap:6px}
  .plh-tab{font-size:11.5px;padding:8px 14px}

  /* hero stats: 2x2, smaller */
  .plh-el .pl-g4{grid-template-columns:repeat(2,minmax(0,1fr)) !important;gap:18px !important}
  .pl-stats-dark .elementor-counter-number-wrapper{font-size:26px !important}
  .pl-stats-dark .elementor-counter-title{font-size:11px !important}
  .pl-stats .elementor-counter-number-wrapper{font-size:30px !important}

  /* CTA strips */
  .pl-cta{padding:26px 20px !important}
  .pl-cta .elementor-widget-button,
  .pl-cta .elementor-button{width:100%}
  .pl-cta > .e-con:last-child{flex-direction:column !important;align-items:stretch !important}

  /* cards and tiles */
  .pl-tile img{height:180px}
  .pl-ibox{padding:24px 20px !important}
  .pl-num .elementor-heading-title{font-size:24px !important;top:14px;right:16px}

  /* Houzez search + cards */
  .pl-hzsearch{padding:20px 16px 22px !important}
  .pl-hzsearch .form-group,
  .pl-hzsearch .col-md-3,
  .pl-hzsearch .col-md-4,
  .pl-hzsearch .col-lg-3{width:100% !important;flex:0 0 100% !important;max-width:100% !important}
  .pl-hzsearch .btn-primary,
  .pl-hzsearch button[type=submit]{width:100%}

  /* marquee */
  .pl-mqi{font-size:24px}
  .pl-mqtrack{gap:26px}
  .pl-mqs{font-size:20px}

  /* maps */
  .elementor-widget-google_maps iframe{height:280px !important}

  /* forms: comfortable tap targets */
  .pl-form .elementor-field,
  .elementor-field-group .elementor-field,
  .form-control{min-height:46px}
  .pl-form .elementor-button,
  .elementor-field-type-submit .elementor-button{width:100%;min-height:48px}

  /* keep content clear of the fixed bottom rail */
  body{padding-bottom:62px}
  .pl-footer{padding-bottom:34px !important}
}

/* ---------- small phone: 560 ---------- */
@media (max-width:560px){
  .plh-h1 .elementor-heading-title{font-size:24px !important}
  .pl-head .elementor-heading-title{font-size:21px !important}
  .plh-el .pl-g4{grid-template-columns:1fr !important;gap:14px !important}
  .pl-tile img{height:164px}
  .pl-ftcta{padding-bottom:28px !important;margin-bottom:28px !important}
  .pl-fbottom{flex-direction:column;align-items:flex-start;gap:6px}
}

/* ---------- very small: 420 ---------- */
@media (max-width:420px){
  .plh-h1 .elementor-heading-title{font-size:22px !important}
  .plh-tabs{width:100%}
  .plh-tab{flex:1 1 calc(50% - 3px);text-align:center}
  .pl-ibox{padding:22px 16px !important}
}

/* ---------- landscape phones: keep the hero usable ---------- */
@media (max-height:520px) and (orientation:landscape){
  .plh-el{padding-top:24px !important;padding-bottom:26px !important}
  .plh-h1 .elementor-heading-title{font-size:22px !important}
  .plh-el .pl-g4{display:none !important}
}

/* ---------- tablet/mobile: hide the desktop hover rail labels ---------- */
@media (hover:none){
  .pl-fi:hover{width:auto;transform:none}
  .pl-fi:hover span{max-width:0;opacity:0;margin-left:0}
}
