/*
 * Muppet Madness Playhouse 1.15.0
 * Mobile article layout: complete image previews, readable titles, no horizontal
 * scrolling. Limited to small screens; desktop and tablet cards are unchanged.
 */
@media (max-width: 620px) {
  /* The previous 320px minimum on BODY could itself create a horizontal
     scrollbar in the Customizer's 320px frame when its vertical bar appeared. */
  body.mm-playhouse {
    min-width: 0 !important;
    max-width: 100%;
  }

  /* Allow every nested grid/flex item to shrink inside the visible viewport. */
  body.mm-playhouse .mm-site-wrap,
  body.mm-playhouse .mm-playhouse-home,
  body.mm-playhouse .mm-play-content,
  body.mm-playhouse .mm-play-section,
  body.mm-playhouse .mm-play-lead-grid,
  body.mm-playhouse .mm-play-story-grid,
  body.mm-playhouse .mm-play-story,
  body.mm-playhouse .mm-play-heading,
  body.mm-playhouse .mm-play-heading > div {
    min-width: 0;
    max-width: 100%;
  }
  body.mm-playhouse .mm-playhouse-home,
  body.mm-playhouse .mm-play-content,
  body.mm-playhouse .mm-play-story-grid {
    width: 100%;
  }
  body.mm-playhouse .mm-play-heading h2,
  body.mm-playhouse .mm-play-story-body strong,
  body.mm-playhouse .mm-play-lead-copy strong {
    overflow-wrap: anywhere;
  }

  /* The old 40%-wide/tall thumbnail crops the source image. On phones,
     stack the artwork above the copy and show the entire original image. */
  body.mm-playhouse .mm-play-story-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 13px;
  }
  body.mm-playhouse .mm-play-story {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 0;
    overflow: hidden;
  }
  body.mm-playhouse .mm-play-story-thumb {
    display: block;
    flex: 0 0 auto;
    width: 100%;
    height: auto;
    min-height: 0;
    aspect-ratio: auto;
    overflow: hidden;
  }
  body.mm-playhouse .mm-play-story-thumb img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: none;
    aspect-ratio: auto;
    object-fit: contain;
    object-position: center;
  }
  /* Keep the no-image placeholder attractively proportioned too. */
  body.mm-playhouse .mm-play-story-thumb:has(.mm-play-image-placeholder) {
    aspect-ratio: 16 / 9;
  }
  body.mm-playhouse .mm-play-story-body {
    min-width: 0;
    padding: 14px 16px 17px;
  }
  body.mm-playhouse .mm-play-story-body strong,
  body.mm-playhouse .mm-play-deep-grid .mm-play-story-body strong {
    font-size: 16px;
    line-height: 1.4;
    margin: 7px 0 11px;
  }
  body.mm-playhouse .mm-play-meta {
    font-size: 9px;
    line-height: 1.5;
  }
  body.mm-playhouse .mm-play-read {
    font-size: 11px;
  }

  /* Lead story: its fixed 215px image slot was clipping wide feature art. */
  body.mm-playhouse .mm-play-lead-story {
    min-width: 0;
    width: 100%;
  }
  body.mm-playhouse .mm-play-lead-image {
    height: auto;
    min-height: 0;
    aspect-ratio: auto;
    overflow: hidden;
  }
  body.mm-playhouse .mm-play-lead-image > img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: none;
    object-fit: contain;
    object-position: center;
  }

  /* Single-article related stories used the same narrow/cropped strip layout. */
  body.mm-playhouse.single-post .mm-playhouse-related-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  body.mm-playhouse.single-post .mm-playhouse-related-card,
  body.mm-playhouse.single-post .mm-playhouse-related-card:last-child:nth-child(odd) {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    min-height: 0;
  }
  body.mm-playhouse.single-post .mm-playhouse-related-thumb,
  body.mm-playhouse.single-post .mm-playhouse-related-card:last-child:nth-child(odd) .mm-playhouse-related-thumb {
    width: 100%;
    height: auto;
    aspect-ratio: auto;
  }
  body.mm-playhouse.single-post .mm-playhouse-related-thumb img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: contain;
  }
  body.mm-playhouse.single-post .mm-playhouse-related-copy {
    padding: 14px 15px;
  }
  body.mm-playhouse.single-post .mm-playhouse-related-copy strong {
    font-size: 15px;
    line-height: 1.4;
  }
}
