/* Mobile portfolio text and still-image containment. Desktop art direction is local. */
@media (max-width: 760px) {
  body[data-cup-case-heading] {
    --cup-mobile-copy: 18px;
    --cup-mobile-heading: clamp(30px, 7.7vw, 36px);
  }

  /* Grid items must be allowed to shrink below a photo's intrinsic pixel width. */
  body[data-cup-case-heading] :is(
    .case-description, .lv-panel, .cup-spread, .ysl-pair,
    .art-section-heading, .cgi-caption, .film-stills-grid
  ) > *,
  body[data-cup-case-heading] :is(
    .estate-copy, .dior-copy, .assistant-editorial-copy, .slim-film-copy
  ) {
    min-width: 0;
  }

  body[data-cup-case-heading] img[data-cup-photo-reveal],
  body[data-cup-case-heading] :is(.cup-spread button, .cup-legacy-zoom) {
    min-width: 0;
    max-inline-size: 100%;
  }

  body[data-cup-case-heading] :is(
    .case-description, .case-passage, .estate-copy, .dior-copy,
    .light-note, .slim-chapter, .assistant-editorial-copy,
    .owala-original-copy, .slim-film-copy, .art-section-heading,
    .concept-exhibition figcaption, .film-stills
  ) p:not([class*="kicker"]):not([class*="credit"]):not([class*="source"]):not(blockquote p),
  body[data-cup-case-heading] :is(
    .concept-heading-note, .slim-campaign-intro,
    .art-intro-copy, .site-case-summary, .premiere-copy .lead,
    .chapter-header .lead, .chapter-header > p
  ) {
    font-size: var(--cup-mobile-copy);
    line-height: 1.5;
    overflow-wrap: anywhere;
  }

  body[data-cup-case-heading] :is(
    .case-description, .case-passage, .estate-copy, .dior-copy,
    .light-note, .slim-chapter, .assistant-editorial-copy,
    .owala-original-copy, .slim-film-copy, .art-section-heading,
    .cgi-caption, .film-stills
  ) h2 {
    font-size: var(--cup-mobile-heading);
    line-height: 1.12;
    overflow-wrap: anywhere;
  }

  /* Credits remain a compact vertical list without changing their typeface. */
  body[data-cup-case-heading] main .project-credits,
  body[data-cup-case-heading] main .case-description-copy .project-credits,
  body[data-cup-case-heading] footer .credits {
    display: block;
    min-width: 0;
    max-width: 100%;
    column-count: auto;
    list-style: none;
    font-size: 14px;
    line-height: 1.7;
    overflow-wrap: anywhere;
  }

  body[data-cup-case-heading] main .project-credits { padding-inline: 0; }

  body[data-cup-case-heading] .project-credits > :is(li, span) {
    display: block;
    margin: 0;
    font-size: inherit;
    line-height: inherit;
  }

  body[data-cup-case-heading] main :is(
    .lv-panel, .lv-motion, .ysl-figure, .dior-panel, .estate-media,
    .light-figure, .cup-spread, .art-work, .study, .cgi-detail, .film-stills
  ) figcaption {
    min-width: 0;
    font-size: 14px;
    line-height: 1.5;
    overflow-wrap: anywhere;
  }

  /* A long caption and its text action may use separate lines on narrow screens. */
  body[data-cup-case-heading] :is(.estate-media, .lv-motion) figcaption,
  body[data-cup-case-heading] :is(.showcase-toolbar, .showcase-foot) {
    flex-wrap: wrap;
    min-width: 0;
  }

  /* Beauty's mobile column switch formerly stopped at 680px, leaving six
     small images across a 681–760px screen. Extend that existing composition. */
  body[data-cup-case-heading] .beauty-book .collection {
    grid-template-columns: minmax(0, 1fr);
    row-gap: clamp(30px, 8vw, 50px);
  }
  body[data-cup-case-heading] .beauty-book .collection > * { grid-column: 1; }
  body[data-cup-case-heading] .beauty-book .opening { display: block; }
  body[data-cup-case-heading] .beauty-book .opening .heading {
    max-width: 100%;
    padding: 0 0 21px;
  }
  body[data-cup-case-heading] .beauty-book :is(.pair-right, .pair-outer, .pair-left, .pair-inset) {
    margin-top: 0;
  }
  body[data-cup-case-heading] .beauty-book :is(.pair-right, .pair-outer) {
    width: 92%;
    justify-self: end;
  }
  body[data-cup-case-heading] .beauty-book :is(.pair-left, .pair-inset) { width: 96%; }
  body[data-cup-case-heading] .beauty-book .centered {
    width: 94%;
    justify-self: center;
  }
  body[data-cup-case-heading] .beauty-book .frames > * { min-width: 0; }
}
