/* Responsive guardrails for the Elementor and custom HTML sections used by Iwan. */
html,
body {
  max-width: 100%;
  overflow-x: clip;
}

.elementor,
.elementor .e-con,
.elementor .e-con-inner,
.elementor-widget,
.elementor-widget-container,
.elementor-widget-html,
.elementor-widget-shortcode {
  min-width: 0;
  max-width: 100%;
}

.elementor img,
.elementor video,
.elementor iframe {
  max-width: 100%;
}

.iwan-lead-section,
.iwan-lead-section * {
  box-sizing: border-box;
}

.iwan-lead-company-fields[hidden] {
  display: none !important;
}

.iwan-lead-cta-wrap {
  margin: 24px 0 0;
  text-align: center;
}

.iwan-lead-cta {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 10px 26px;
  border: 1px solid #b4973a;
  border-radius: 10px;
  background: #a88a2d;
  color: #fff !important;
  font: inherit;
  font-weight: 700;
  text-decoration: none !important;
  transition: background-color .2s ease, transform .2s ease;
}

.iwan-lead-cta:hover,
.iwan-lead-cta:focus-visible {
  background: #8e7424;
  color: #fff !important;
  transform: translateY(-1px);
}

@media (max-width: 767px) {
  .iwan-about-premium,
  .owner-section-home,
  .custom-housing-section,
  .brands-clean {
    padding: 48px 16px !important;
  }

  .elementor .e-con,
  .elementor .e-con-inner {
    --width: 100%;
    min-width: 0;
  }

  .iwan-lead-section {
    width: 100%;
    padding: 48px 16px;
  }

  .iwan-lead-section--investors,
  .iwan-lead-section--companies {
    padding-block: 40px;
  }

  .iwan-lead-wrap {
    width: 100%;
    min-width: 0;
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
  }

  .iwan-lead-card {
    min-width: 0;
    padding: 20px;
  }

  .iwan-lead-grid,
  .iwan-lead-company-fields .iwan-lead-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 767px) {
  /* Give the homepage's narrow Elementor wrappers the full mobile column. */
  .elementor-10 .elementor-element-3a3d7ec,
  .elementor-10 .elementor-element-6678766 {
    padding-inline: 12px !important;
  }

  .elementor-10 .elementor-element-aeeb7a4,
  .elementor-10 .elementor-element-f578efe {
    width: 100% !important;
    max-width: 100% !important;
  }

  .iwan-about-premium .iwan-container {
    width: 100% !important;
  }

  html[lang^="en"] .iwan-about-premium .iwan-layout {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  html[lang^="en"] .iwan-about-premium .iwan-layout > * {
    width: 100%;
    min-width: 0;
  }

  /* Keep the About page's content cards comfortably wide on small screens. */
  .iwan-journey-section,
  .stats-only-section,
  .mission-values-section,
  .why-iwan-section {
    padding-inline: 16px !important;
  }

  .iwan-journey-section .iwan-container {
    width: 100% !important;
  }

  .elementor-584 > .e-con {
    padding-inline: 12px !important;
  }

  /* The contact page had nested side padding that left a very narrow form. */
  .contact-us-page {
    padding: 16px 12px !important;
  }

  .contact-container {
    width: 100% !important;
  }

  .elementor-598 .elementor-element-9c15894,
  .elementor-598 .elementor-element-7118c30 {
    padding-inline: 0 !important;
  }

  .contact-form {
    padding: 24px 18px !important;
  }

  .contact-form .wpforms-container,
  .contact-form .wpforms-form {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Lift the off-canvas menu above the fixed header and floating widgets. */
  body:has(.elementskit-menu-container.active) .custom-main-header {
    z-index: 1000000 !important;
  }

  body:has(.elementskit-menu-container.active) .elementskit-menu-container.active {
    z-index: 1000001 !important;
  }
}

/* Homepage: one spacing layer per section, including after a site migration. */
@media (max-width: 767px) {
  .elementor-10 > .e-con {
    padding: 0 !important;
    margin-block: 0 !important;
    min-height: 0 !important;
    --gap: 0px;
    --row-gap: 0px;
  }

  .elementor-10 > .e-con > .e-con-inner,
  .elementor-10 > .e-con > .e-con,
  .elementor-10 > .e-con > .e-con-inner > .e-con {
    padding: 0 !important;
    margin-block: 0 !important;
    min-height: 0 !important;
    width: 100% !important;
    --gap: 0px;
    --row-gap: 0px;
  }

  .elementor-10 .iwan-about-premium,
  .elementor-10 .hotel-services-arabic,
  .elementor-10 .owner-section-home,
  .elementor-10 .custom-housing-section,
  .elementor-10 .brands-clean {
    padding: 36px 16px !important;
    margin-block: 0 !important;
  }

  .elementor-10 .iwan-about-premium .iwan-layout,
  html[lang^="en"] .elementor-10 .iwan-about-premium .iwan-layout {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .elementor-10 .brands-clean__head,
  .elementor-10 .owner-section-home__head,
  .elementor-10 .section-head {
    margin-bottom: 24px !important;
  }

  .elementor-10 .iwan-lead-section--start {
    padding: 36px 16px !important;
  }
}
