html {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

@supports (overflow: clip) {
  html,
  body { overflow-x: clip; }
}

img,
svg,
video {
  max-width: 100%;
  height: auto;
}

.hero-grid > *,
.featured-head > *,
.property-detail-grid > *,
.contact-box > *,
.testimonial-layout > * {
  min-width: 0;
}

@media (max-width: 1050px) {
  input:not([type="checkbox"]):not([type="radio"]),
  textarea,
  select { font-size: 16px !important; }

  .header {
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }

  .mobile-menu {
    min-height: 100vh;
    min-height: 100dvh;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-top: max(32px, env(safe-area-inset-top));
    padding-right: max(32px, env(safe-area-inset-right));
    padding-bottom: max(32px, env(safe-area-inset-bottom));
    padding-left: max(32px, env(safe-area-inset-left));
  }
}

@media (max-width: 1050px) and (max-height: 500px) {
  .mobile-menu-contact {
    position: static;
    margin-top: 28px;
  }
  .mobile-nav { margin-top: 30px; }
  .mobile-nav a { font-size: clamp(28px, 9vh, 42px); }
}

@media (max-width: 700px) {
  .menu-button,
  .testimonial-arrow,
  .filter-reset,
  .btn,
  .faq-question {
    min-width: 44px;
    min-height: 44px;
  }

  .hero-title,
  .property-page-title,
  .section-title,
  .testimonial blockquote {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .modal {
    min-height: 100vh;
    min-height: 100dvh;
    padding-top: max(18px, env(safe-area-inset-top));
    padding-right: max(18px, env(safe-area-inset-right));
    padding-bottom: max(18px, env(safe-area-inset-bottom));
    padding-left: max(18px, env(safe-area-inset-left));
  }

  .property-gallery img,
  .property-image img,
  .about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

@media (max-width: 480px) {
  .filters { grid-template-columns: 1fr; }
  .property-page-meta { grid-template-columns: 1fr; }
  .feature-list { grid-template-columns: 1fr; }
  .mobile-menu {
    padding-left: max(22px, env(safe-area-inset-left));
    padding-right: max(22px, env(safe-area-inset-right));
  }
  .mobile-menu a { font-size: clamp(32px, 11vw, 46px); }
}

@media (hover: none) {
  .property-card:hover img,
  .btn:hover {
    transform: none;
  }
}

/* Mobile composition: editorial labels stay left, key messages stay centered. */
@media (max-width: 700px) {
  .hero-heading {
    margin-left: 0;
  }

  .hero-copy {
    justify-self: center;
    align-self: center;
    transform: none;
  }

  .hero-copy > p {
    margin-right: auto;
    margin-left: auto;
  }

  .hero-title,
  .hero-copy,
  .featured-head .section-title,
  .featured-head .section-intro,
  .process .section-title,
  .location-title,
  .about .section-title,
  #faq .section-title,
  .contact-title {
    text-align: center;
  }

  .hero-cta-row {
    justify-content: center;
  }

  .featured-head .section-intro {
    margin-right: auto;
    margin-left: auto;
  }

  .location-title em,
  .contact-title em {
    margin-right: auto;
    margin-left: auto;
  }

  .testimonial-copy {
    text-align: center;
  }

  .testimonial-media {
    margin-right: auto;
    margin-left: auto;
  }

  .testimonial-author {
    justify-content: center;
  }

  .about-copy {
    text-align: center;
  }

  .about-copy p {
    margin-right: auto;
    margin-left: auto;
  }

  .about-tags {
    justify-content: center;
  }

  .contact-section .lead-form .btn {
    width: 100%;
    margin: 14px auto 0;
  }
}
