/* ============================================================================
   LEGO — mobile-scroll-reel CSS (companion candidate)
   Scoped beneath [data-lego="pinned-horizontal-reel"].lego-msr-active — the JS
   adds the class only while the companion's media gate is active, so the
   certified vertical stack remains the no-JS / reduced / short-landscape
   presentation. One project composition reads at a time; the next card peeks
   at the right edge so the horizontal behavior is discoverable.
   ============================================================================ */

@media (max-width: 991px) and (min-height: 480px) {
  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="track"] {
    flex-flow: row nowrap;
    justify-content: flex-start;
    align-items: stretch;
    column-gap: 16vw;
    row-gap: 0;
    height: 100vh;
    height: 100svh;
    margin-top: 0;
    margin-bottom: 0;
    /* Clear the existing two-row phone chrome; no navigation redesign. */
    padding-top: 8rem;
    padding-bottom: 4rem;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="project"] {
    flex: 0 0 auto;
    width: min(84vw, 30rem);
    height: 100%;
    margin-left: 0;
    padding: 0 1.25rem;
    overflow: hidden;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="project"]:first-child {
    margin-left: 8vw;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="project"]:last-child {
    margin-right: 8vw;
    padding-right: 1.25rem;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="title"] {
    font-size: clamp(2rem, 8vw, 3rem);
    line-height: 1.05;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="desc"] {
    font-size: 1rem;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="media"] {
    aspect-ratio: auto;
    flex: 1 1 auto;
    min-height: 3rem;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="media"] img {
    aspect-ratio: auto;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="progress"] {
    display: block;
    bottom: max(1.25rem, env(safe-area-inset-bottom));
    padding-left: 8vw;
    padding-right: 8vw;
  }

  [data-lego="pinned-horizontal-reel"].lego-msr-active [data-lego-phr="progress-inner"] {
    grid-column: auto;
    row-gap: 0.6rem;
  }
}
