/* JoTrip DMC V0.11 - mobile QA fixes.
   This file is intentionally small and loaded after the locked V3/V11 CSS. */

@media(max-width:820px){
  /* Keep the approved homepage story on mobile too. The old responsive layer
     replaced the sea-view room with an unrelated beach fallback, which made
     mobile feel like a different site. */
  .hero{background:#1b3029!important;}
  .hero picture{display:block!important;position:absolute!important;inset:0!important;}
  .hero picture img{width:100%!important;height:100%!important;object-fit:cover!important;object-position:52% 54%!important;}

  /* The first experience card must never inherit a narrow text track from
     older desktop/card-grid layers. The screenshot bug rendered the copy
     one word per line down the left edge of the image. */
  .experiences .exp-card:first-child{display:block!important;position:relative!important;width:100%!important;max-width:100%!important;}
  .experiences .exp-card:first-child .exp-card-content{
    position:absolute!important;
    z-index:3!important;
    top:auto!important;
    left:18px!important;
    right:18px!important;
    bottom:18px!important;
    width:auto!important;
    max-width:calc(100% - 36px)!important;
    min-width:0!important;
    display:block!important;
    padding:0!important;
    writing-mode:horizontal-tb!important;
  }
  .experiences .exp-card:first-child .exp-card-content h3,
  .experiences .exp-card:first-child .exp-card-content p{
    display:block!important;
    width:auto!important;
    max-width:30rem!important;
    white-space:normal!important;
    word-break:normal!important;
    overflow-wrap:break-word!important;
    writing-mode:horizontal-tb!important;
  }
  .experiences .exp-card:first-child .exp-card-content h3{margin:0 0 7px!important;line-height:1!important;}
  .experiences .exp-card:first-child .exp-card-content p{margin:0!important;line-height:1.45!important;}

  /* Long VI/EN copy should wrap normally everywhere, never create a
     single-word vertical column in image cards. */
  .exp-card-content,.luxury-copy,.story-copy,.note-article{min-width:0;}
  .exp-card-content p,.luxury-copy p,.story-copy p,.note-article p{overflow-wrap:break-word;word-break:normal;}

  body[data-page="about"] .about-origin-prose p+p{margin-top:14px;}
}
