/*
 * Mobile layout fixes.
 *
 * Loaded from header.php and hcp-header.inc. Kept in its own file so it is not
 * affected by the one-month CSS cache used for the existing stylesheets.
 */

/* Long Dutch/French words in headings (e.g. "gezondheidsbeoefenaar") can be
   wider than the mobile content column; allow them to hyphenate/break. */
@media (max-width: 767.98px) {
  html[lang="nl"] h1,
  html[lang="nl"] h2,
  html[lang="nl"] h3,
  html[lang="fr"] h1,
  html[lang="fr"] h2,
  html[lang="fr"] h3 {
    -webkit-hyphens: auto;
    hyphens: auto;
    overflow-wrap: break-word;
  }

  /* Nested Bootstrap rows inside .signs_inner keep their negative gutters but
     the box they sit in has no matching padding, so they extend past the grid
     cell by 12px each side. */
  .signs_inner .row {
    margin-left: 0;
    margin-right: 0;
  }

  /* The signs boxes are half-width on mobile; long single words such as
     "Gewichtsverlies" must be allowed to break inside them. */
  .signs_inner p {
    overflow-wrap: break-word;
  }

  html[lang="nl"] .signs_inner p,
  html[lang="fr"] .signs_inner p {
    -webkit-hyphens: auto;
    hyphens: auto;
  }
}

/* The homepage hero photo is offset 67px down to sit below the logo bar, so
   the bottom of the image (and its baked-in fade) is clipped at the wrapper
   edge. Fade the last 120px into the #060E11 page background so the hero
   blends smoothly instead of ending on a hard line. Patient homepage only —
   the HCP wrapper uses .sticky-top and has no hero photo. */
@media (max-width: 992px) {
  body.homepage .home_mobile_wrapper:not(.sticky-top) {
    background-image:
      linear-gradient(to bottom, rgba(6, 14, 17, 0) 0%, #060E11 100%),
      url(../img/landing_bg_mobile.jpg);
    background-size: 100% 120px, cover;
    background-position: center bottom, center 67px;
    background-repeat: no-repeat, no-repeat;
  }
}
