/* LDP Group, mobile layout (17.09.2026)
   Site-wide overrides for phones and small tablets, loaded after the inline theme CSS on every
   WordPress-level page (next to mobile-nav.css). Equal specificity wins by order; !important only
   where the theme sets it too. Sections: homepage hero, why invest, offerings, partnering, journey,
   tables and graphics on guides/decision pages and /services/, popups, footer.
   Design language stays the theme's: Montserrat, gobold headings, accent #1586b6, CTA #3ba5e6,
   dividers #e5eef2, 12 to 20px radii, soft shadows. */

/* ---------- helpers ---------- */
.ldp-mb-only { display: none; }
@media (max-width: 991px) {
  .ldp-mb-only { display: block; }
  .ldp-desk-only { display: none !important; }
}

@media (max-width: 991px) {

  /* ---------- homepage hero, tablets and phones ----------
     The two floating cards sit side by side under the property card; the blurred glass
     image behind the card is decoration that reads as a smear below 992px. */
  .bnr-right-outer .flt-left,
  .bnr-right-outer .flt-right {
    display: block;
    position: static;
    order: 1;
    flex: 1 1 calc(50% - 6px);
    width: calc(50% - 6px);
    margin: 22px 0 0;
  }
  .bnr-right-outer { display: flex; flex-direction: row; flex-wrap: wrap; gap: 12px; }
  .bnr-right-outer > * { order: 0; }
  .bnr-right-outer .bnr-img,
  .bnr-right-outer .bnr-txt-content { flex: 0 0 100%; width: 100%; }
  .bnr-right-outer .bnr-gls-wrap { display: none; }
  .flt-left-shape, .flt-right-shape, .bnr-dot { display: none !important; }
  .flt-left-box, .flt-right-box {
    transform: none !important;
    height: 100%;
    padding: 16px 14px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(13, 20, 24, .06);
  }
  .flt-left-icon-wrap { width: 40px; height: 40px; margin-bottom: 12px; }
  .flt-left-icon-subtitle { font-size: 13px; }
  .flt-left-icon-desc { font-size: 11.5px; line-height: 1.35; }

  /* ---------- why invest ----------
     Both items read left to right: icon left, text left aligned. */
  .why-choose-left,
  .why-choose-right {
    text-align: left;
    align-items: flex-start;
  }
  .why-choose-left .wc-icon,
  .why-choose-right .wc-icon {
    order: 0;
    margin: 0 14px 0 0;
    width: 56px;
    height: 56px;
  }
  .why-choose-left .wc-left-content,
  .why-choose-right .wc-left-content { flex: 1 1 auto; }
  .wc-subtitle { font-size: 16px; }
  .why-choose-mid { margin-bottom: 20px; }

  /* ---------- offerings ----------
     No 3D scene on phones (three.js stays desktop only). The poster stays as the visual,
     the seven services become tappable buttons that open the same popups. */
  .city_box .mob-ind,
  .city_box .mob_hints { display: none !important; }
  .ofr-img { margin-bottom: 0; }
  .ldp-ofr-chips {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 18px auto 0;
    max-width: 520px;
    padding: 0;
    list-style: none;
  }
  .ldp-ofr-chips li { margin: 0; padding: 0; }
  .ldp-ofr-chips button {
    width: 100%;
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 14px;
    border: 1px solid #e5eef2;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 6px 20px rgba(13, 20, 24, .05);
    font-family: var(--font-Montserrat), sans-serif;
    font-size: 13.5px;
    font-weight: 700;
    line-height: 1.25;
    color: #0d1418;
    text-align: left;
    -webkit-appearance: none;
    appearance: none;
  }
  .ldp-ofr-chips button::after {
    content: "";
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #1586b6 url(/wp-content/themes/ldp-group/images/plus.svg) center / 10px no-repeat;
  }
  .ldp-ofr-chips button:active { border-color: #3ba5e6; }
  .ldp-ofr-chips li:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .ldp-ofr-hint {
    text-align: center;
    font-size: 12px;
    color: var(--color-gary, #787878);
    margin: 14px 0 0;
  }
  .ofr-sec .sdle-demo { margin-top: 24px; }

  /* ---------- what you gain ----------
     The "Book a meeting" link no longer sits on top of card 05. */
  .partning-clck-part .sdle-demo {
    position: static;
    margin: 28px auto 0;
    width: 100%;
    max-width: none;
  }
  .partning-sec { padding-bottom: 50px !important; }
  .partning-clck-item { padding: 6px 0; }
  .partning-clck-box2 ul[data-toggle_list] { margin-bottom: 0; }
  .partning-clck-box2 ul[data-toggle_list].active { margin-bottom: 4px; }
  [data-toggle_link] { padding-right: 34px; cursor: pointer; }

  /* ---------- your journey ----------
     The map is revealed by GSAP; on phones the rotated map is 530px tall and the section
     needs breathing room above and below. */
  .jurny-sec .sec-head { margin-bottom: 24px; }

  /* ---------- popups (offerings + why invest modals) ---------- */
  .popup_box_container { padding: 26px 20px; }
  .popup_box_inner { font-size: 14.5px; }
  .popup_box_inner h3 { font-size: 18px; margin-bottom: 12px; }
  .close_popup { right: -10px; top: -10px; }
}

/* ---------- homepage hero, phones ----------
   Below 768px the theme swaps to its mobile stats block (.for-mb) under the property card.
   Order on a phone: headline, CTA, property card, floating cards, three stats in one row,
   trust widget. The CTA sits above the fold instead of 2.5 screens down. */
@media (max-width: 767px) {
  .banner-section { padding-top: 32px; }
  .bnr-text-part h1 { margin-bottom: 18px; }
  .signup-btn--hero-mb {
    display: block;
    width: 100%;
    max-width: 420px;
    margin: 0 auto 28px;
    font-size: 17px;
    padding: 15px 24px;
    text-align: center;
    border-radius: 14px;
  }
  .bnr-right-outer { margin-top: 0; padding: 10px; width: 100%; max-width: 420px; }
  .bnr-right-outer .bnr-txt-content { margin-top: -12px; }
  .bnr-right-outer .bnr-txt-content::before { display: none; }
  .bnr-right-outer .cnt-secUp.for-mb { order: 2; flex: 0 0 100%; width: 100%; margin-top: 12px; }
  .cnt-secUp.for-mb .cnt-row { --bs-gutter-x: 8px; --bs-gutter-y: 8px; margin: 0 -4px; }
  .cnt-secUp.for-mb .cnt-row > .col-md-4 { flex: 0 0 33.3333%; width: 33.3333%; padding: 0 4px; display: flex; }
  .cnt-secUp.for-mb .cnt-row > div:first-child { border-right: 0; }
  .cnt-secUp.for-mb .cnt-box { padding: 12px 6px 10px; justify-content: flex-end; min-height: 104px; }
  .cnt-secUp.for-mb .cnt-row .cnt-number.h2-title { font-size: 17px; letter-spacing: 0; white-space: nowrap; padding: 4px 8px; }
  .cnt-secUp.for-mb .cnt-row .cnt-head { font-size: 10.5px; line-height: 1.2; min-height: 0; margin-top: 4px; letter-spacing: 0; }
  .cnt-secUp.for-mb .ldp-avatars img { width: 26px; height: 26px; }
  .cnt-secUp.for-mb .ldp-avatars { margin-bottom: 4px; }
  /* the top button replaces this one on phones; the trust widget stays */
  .cnt-secUp.for-mb .ldp-cta-row .signup-btn--hero { display: none; }
  .cnt-secUp.for-mb .ldp-cta-row { display: flex; justify-content: center; max-width: none; margin: 6px auto 0; }
  .cnt-secUp.for-mb .ldp-cta-row .trustmarkt-widget { transform-origin: center top; margin: 8px auto -22px; }
}
@media (min-width: 768px) {
  .signup-btn--hero-mb { display: none !important; }
}

/* ---------- tables and graphics ----------
   Guides and decision pages (.ldp-dp-wrap), the service pages (#ldp-ed .twrap, .panel-bd) and
   the legacy articles: wide tables scroll sideways instead of squeezing into 30px columns,
   charts keep a readable minimum width. :has() is progressive, older browsers fall back to
   today's behaviour. */
@media (max-width: 767px) {
  .ldp-dp-wrap,
  #ldp-ed .twrap,
  #ldp-ed .panel-bd,
  #ldp-ed .flow-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    /* scrolling shadows: a soft edge appears on the side that still has content */
    background:
      linear-gradient(90deg, #fff 40%, rgba(255,255,255,0)) left / 36px 100% no-repeat local,
      linear-gradient(270deg, #fff 40%, rgba(255,255,255,0)) right / 36px 100% no-repeat local,
      linear-gradient(90deg, rgba(13,20,24,.10), rgba(13,20,24,0)) left / 14px 100% no-repeat scroll,
      linear-gradient(270deg, rgba(13,20,24,.10), rgba(13,20,24,0)) right / 14px 100% no-repeat scroll;
  }
  .ldp-dp-wrap { margin-left: -4px; margin-right: -4px; padding: 0 4px 6px; }
  .ldp-dp-table:has(th:nth-child(4)),
  .ldp-dp-table:has(td:nth-child(4)) { min-width: 620px; }
  .ldp-dp-table:has(th:nth-child(6)),
  .ldp-dp-table:has(td:nth-child(6)) { min-width: 760px; }
  .ldp-dp-table th, .ldp-dp-table td { padding: .55em .6em; font-size: 14px; }
  .ldp-dp-table caption { position: sticky; left: 0; max-width: calc(100vw - 48px); font-size: 12.5px; text-align: left; padding-top: 8px; }
  #ldp-ed .twrap table:has(th:nth-child(3)) { min-width: 560px; }
  #ldp-ed .twrap table:has(th:nth-child(5)) { min-width: 680px; }
  #ldp-ed .ldp-chart { min-width: 620px; display: block; }
  #ldp-ed .panel-bd > svg[viewBox][style*="max-width"] { min-width: 400px; display: block; }
}
