/* ==========================================================================
   feed.css — the feed layer, and the detail layer over it
   --------------------------------------------------------------------------
   app.css is the product's component set, ported from the companion. This
   sheet is the concept's, and it is the only file in the prototype carrying a
   rule that is not in the design file.

   TWO RULES RUN THROUGH ALL OF IT.

   The picture is the product. A control may take light away from the trailer
   only for as long as it is being looked at, so the controls are the
   product's own `.disc` on a soft ground, and the scrims are the brand's own
   background colour at low alpha. Never black: black on this artwork reads
   as a hole punched in it.

   Nothing is in a container that does not need one. The themes, the genre
   and the rating are a meta line — the same dot-separated line the hero and
   the detail page use — not a row of filled pills; and the synopsis is the
   same `.readmore` the detail page has, not a link.

   GEOMETRY. The layer is left/top/width/height rather than inset:0, because
   those four are what the morph animates and `inset` is not four properties.
   Everything inside is a percentage of the layer, which is what lets the
   whole feed be laid out correctly while the box is still 144px wide and
   growing.
   ========================================================================== */

.feed {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--frame-width);
  height: var(--frame-height);
  z-index: 50;
  overflow: hidden;
  background: #000;
  contain: paint;
}

/* ---- WHAT STACKS OVER WHAT --------------------------------------------
   The home screen is never torn down, so its chrome is still in the
   document under every layer and the numbers have to be right or it shows
   through. The tab bar is z-index 30 in the component set and the feed was
   20, which is exactly what happened: a BritBox tab bar sitting across the
   bottom of a full-screen trailer.

       home screen        1 .. 30   (its own stack, app.css)
       the feed           50
       the detail page    54
       the status bar     58        the HANDSET's, not a screen's
       the home indicator 60        likewise

   The last two are the device rather than the product, so they stay on top
   of everything — and because they do, no layer renders its own. */
.statusbar { z-index: 58; }
.home-indicator { z-index: 60; }

/* THE MORPH. While the box is travelling, every overlay is off and only the
   slide being opened exists — eight slides laying themselves out on each
   frame of a 460ms animation is the difference between 60fps and not. The
   chrome comes up AFTER the box lands, as a fade. */
.feed.is-morphing .feed__top,
.feed.is-morphing .slide__actions,
.feed.is-morphing .slide__info,
.feed.is-morphing .slide__mark,
.feed.is-morphing .slide__scrim { opacity: 0; }

.feed:not(.is-live) .slide:not(.is-at) { display: none; }

.feed.is-live .feed__top,
.feed.is-live .slide__scrim {
  opacity: 1;
  transition: opacity var(--dur-base) var(--ease-standard) .04s;
}

.feed.is-live .slide__info { transform: none; }

/* ---- the vertical stack -------------------------------------------------
   Moved by PERCENTAGE, not by scroll offset. A pixel scroller cannot survive
   its own container going from 216 tall to 844 in the middle of a morph; a
   percentage simply means the same thing at both sizes. --dy is the finger,
   in phone pixels, while a drag is live. */
.feed__rail {
  position: absolute;
  inset: 0;
  transform: translate3d(0, calc(var(--at, 0) * -100% + var(--dy, 0) * 1px), 0);
  will-change: transform;
  touch-action: none;       /* the gestures are ours; see feed.js          */
}

.slide {
  position: absolute;
  left: 0;
  top: calc(var(--n, 0) * 100%);
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.slide__media { position: absolute; inset: 0; background: #000; }
.slide__still { position: absolute; inset: 0; }

/* `--pos` is set on the element only where the source is RAW LANDSCAPE
   footage cropped live (The Hardacres). The other seven clips were rendered
   at their title's own focus and are already cropped, so they fall back to
   the centre — cropping them a second time would shift a window that is
   already the right one. See ui.js pos(). */
.slide__vid {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--pos, 50% 50%);
  opacity: 0;
  transition: opacity var(--dur-media) var(--ease-standard);
}

/* The clip is only revealed once a frame exists behind it. `play` fires when
   playback is REQUESTED, not when there is a picture, and fading the still at
   that moment leaves a black hole in the frame. */
.slide.is-rolling .slide__vid { opacity: 1; }

/* OPENING A CARD GOES STRAIGHT INTO THE VIDEO. feed.js starts the clip before
   the morph is even set up — the card has been playing that exact file, so it
   is cached — and the fade is switched off for the whole of the travel, so
   the picture is the moving one from the first frame of the expansion rather
   than a still that dissolves into it a moment after landing. The still is
   still there underneath, and shows only if the clip has not managed a frame
   in the 460ms the box takes to grow. */
.feed.is-morphing .slide__vid,
.feed.is-morphing .slide__still { transition: none; }

.slide__scrim {
  position: absolute;
  left: 0; right: 0;
  opacity: 0;
  pointer-events: none;
}

.slide__scrim--top {
  top: 0;
  height: 190px;
  background: linear-gradient(to bottom,
              rgba(0, 24, 43, 0.70) 0%,
              rgba(0, 24, 43, 0.34) 46%,
              rgba(0, 24, 43, 0) 100%);
}

.slide__scrim--bottom {
  bottom: 0;
  height: 62%;
  background: linear-gradient(to top,
              rgba(0, 24, 43, 0.94) 0%,
              rgba(0, 24, 43, 0.78) 22%,
              rgba(0, 24, 43, 0.36) 58%,
              rgba(0, 24, 43, 0) 100%);
}

/* ---- the paused mark ----------------------------------------------------
   IT STAYS ON THE SCREEN FOR AS LONG AS PLAYBACK IS STOPPED. The first build
   flashed a glyph for half a second and took it away, which leaves a paused
   trailer looking like a still photograph with no way back — the one state in
   a player that has to be unambiguous. Playing, there is nothing at all over
   the middle of the picture. */
.slide__mark {
  position: absolute;
  left: 50%;
  top: 44%;
  z-index: 3;
  width: 64px;
  height: 64px;
  margin: -32px 0 0 -32px;
  /* NO CONTAINER. The disc this used to sit in was a second object in the
     middle of the frame, which is the one place this feed may not put one.
     What is left is the glyph: white at 0.82 so it reads as an overlay
     rather than as an element, with a soft shadow doing the work the disc
     was doing — keeping it legible over a bright shot — and round joins on
     the triangle so its corners match the radius everything else here uses. */
  /* THE DOUBLED PLAY BUTTON, AND WHY IT WAS DOUBLED.
     The glyph was white at 0.82 with `drop-shadow(0 2px 14px …)` on it. A
     drop-shadow is painted BEHIND the shape, so through a shape that is only
     82% opaque you can see it — and an offset shadow seen through its own
     glyph is a second, darker triangle sitting 2px below the first. It read
     as two play buttons because, in every way that matters, it was.

     Solid white now, with the softness coming from the element's own opacity
     and the shadow carrying no offset at all: a halo cannot be mistaken for
     a copy. */
  color: #fff;
  opacity: 0;
  transform: scale(0.88);
  pointer-events: none;
  filter: drop-shadow(0 0 16px rgba(0, 0, 0, 0.5));
  transition: opacity var(--dur-fast) var(--ease-standard),
              transform var(--dur-base) var(--ease-rise);
}

.slide__mark svg { width: 100%; height: 100%; }

/* AND IT IS NOT SHOWN UNTIL IT IS ASKED FOR. `is-at:not(.is-playing)` was
   true of every trailer that had not started YET as well as every trailer
   that had been stopped — so opening a card put a play mark over a video
   that was already on its way, for as long as the first frame took to
   decode. The two states look identical in CSS and are opposites to a
   reader. `is-held` is set by the tap that pauses and by nothing else; see
   feed.js toggle(). */
.feed.is-live .slide.is-at.is-held:not(.is-playing) .slide__mark {
  opacity: 0.86;
  transform: none;
}

/* ==========================================================================
   THE METADATA BLOCK
   Bottom left, close to the foot of the screen, clear of the control column.
   Logo, then themes and genre and rating, then a partial synopsis, then the
   bar. Nothing else.
   ========================================================================== */

.slide__info {
  position: absolute;
  z-index: 4;
  left: var(--frame-gutter);
  /* THE CONTROL COLUMN LIVES IN THIS GUTTER, and it is wider than it was.
     At 72 the share button sat level with the synopsis and a finger's width
     from it; the two blocks read as one crowded corner rather than as two
     things with different jobs. */
  right: 92px;
  /* AND THE WHOLE BLOCK IS FURTHER OFF THE FOOT OF THE SCREEN. At 26 the
     progress bar was a few pixels from the home indicator, which is the
     system's own furniture and not something a product may crowd. */
  bottom: 48px;
  opacity: 0;
  transform: translateY(8px);
}

/* THE BOX HAS TO BE THE SHAPE OF THE PROBLEM, which is eight lockups of
   seven different proportions.
   -----------------------------------------------------------------------
   `background-size: contain` fits artwork to whichever side runs out first.
   In a WIDE, SHORT box every wide lockup is width-capped and every square
   one is height-capped — so Blue Lights (4.5:1) drew 262 across and Death
   in Paradise (1.3:1, a stacked badge) drew 76, at the same 58 tall. Equal
   cap height, and one of them four times the mass of the other. That is
   what "blue lights feels big, the rest feel very small" was.

   232 x 77 is the product's own detail lockup box and it is nearly square
   enough to catch both: the wide ones run out of WIDTH at 232 and the
   stacked ones run out of HEIGHT at 77, and they land between 100 and 232
   across instead of between 76 and 300. Nobody is capped twice, and the
   artwork is still never distorted — contain does not stretch. */
.slide__logo {
  display: block;
  width: 232px;
  max-width: 100%;
  height: 77px;
  margin-bottom: var(--space-s);
  background-position: left bottom;
  background-size: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.55));
}

/* THE FALLBACK THE BRIEF ASKS FOR, built as a real branch rather than as a
   promise: a title whose lockup is missing or unusable gets a typeset
   headline with the weight on the frame a wordmark would have had. Karen
   Pirie is the live case — see ASSETS.md. */
.slide__wordmark {
  margin: 0 0 var(--space-s);
  font-size: 30px;
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* The product's own meta line, over video. Same component, same dots, same
   sizes; the only addition is a shadow, because a dot-separated line of 12px
   text on moving picture needs one. */
/* LEFT, like everything else in the block. The component centres itself —
   correctly, because the hero and the detail page centre their lockups and
   this line sits under them there. In the feed the lockup is left and the
   synopsis is left, so a centred line between the two was the one thing on
   the block that did not line up with anything. */
.slide__meta {
  justify-content: flex-start;
  gap: 6px;
  margin-bottom: var(--space-s);
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.55);
}

/* ONE LINE, ALWAYS. The container is `flex-wrap: nowrap`, which stops the
   ITEMS wrapping onto a second row — and does nothing about the text inside
   them. Flex items are `flex-shrink: 1` by default, so on the longest line
   in the set they were squeezed narrower than their own text and each one
   broke internally: "Warm & / Sweeping · Period / Drama · TV- / 14", four
   lines pretending to be one.

   A rating split across two lines is not a rating. The items refuse to
   shrink and refuse to break, which is right for a dot-separated line of
   three short labels: it is either on one line or it is wrong. The widths
   below are what keep it on one — see data.js. */
.slide__meta > span { flex: none; white-space: nowrap; }

.slide__meta .meta__dot { background: rgba(255, 255, 255, 0.55); }

/* ---- the partial synopsis over video ------------------------------------
   The SAME `.readmore` the detail page uses — two lines, then a MORE chip on
   the end of the second. The only thing overridden is the fade, which on the
   detail page is the page's own background and over a trailer has to be the
   scrim instead. */
/* LIGHTER THAN THE LINE ABOVE IT. The synopsis was at 0.88 and the themes
   at 0.86, which is the hierarchy upside down: the longest, least urgent
   text on the frame was also the brightest, and it flattened the block into
   one grey mass. The lockup leads, the themes and the rating answer, and the
   synopsis is there for whoever wants it. */
/* AND IT HAS TO BE SET ON THE PARAGRAPH, not on the block. The component
   paints its own text — `.readmore p { color: var(--color-on-surface) }`, a
   0,1,1 selector — so `.slide .readmore` at 0,2,0 was setting a colour on a
   box whose only child overrode it. The rule was there for two rounds and
   never once reached the screen. */
.slide .readmore p {
  color: rgba(255, 255, 255, 0.68);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.55);
}

/* ---- THE SHADOW UNDER THE MORE CHIP, AND WHY IT WAS THERE ---------------
   The component ends its clamped paragraph with a 132 x 19 gradient plate
   behind the chip, so the last line dissolves instead of being sliced by
   it. On the detail page that plate is `--color-background` over a page
   that IS `--color-background`, so it cannot be seen. Over a trailer there
   is nothing for it to match: whatever colour it is given, it is a painted
   rectangle sitting under the chip on moving picture, and it reads as a
   drop shadow somebody forgot to remove.

   So nothing is painted. The paragraph is MASKED instead — two mask
   layers, one per line at the component's own 21px — and the second fades
   its right-hand end out before the chip reaches it. Same job, no plate: a
   mask takes light away from the TEXT rather than adding a shape to the
   frame.

   The mask is lifted when the synopsis opens, because the paragraph is
   then four lines tall and two 21px layers would cut the rest of it off. */
.slide .readmore__fade { display: none; }

.slide .readmore p {
  -webkit-mask-image: linear-gradient(#000, #000),
                      linear-gradient(to right, #000 55%, rgba(0, 0, 0, 0) 85%);
  mask-image: linear-gradient(#000, #000),
              linear-gradient(to right, #000 55%, rgba(0, 0, 0, 0) 85%);
  -webkit-mask-size: 100% 21px, 100% 21px;
  mask-size: 100% 21px, 100% 21px;
  -webkit-mask-position: 0 0, 0 21px;
  mask-position: 0 0, 0 21px;
  -webkit-mask-repeat: no-repeat, no-repeat;
  mask-repeat: no-repeat, no-repeat;
}

.slide .readmore.is-open p {
  -webkit-mask-image: none;
  mask-image: none;
}

/* ---- OPENING IT IS A MOVEMENT, AND IT TRAVELS THE REAL DISTANCE --------
   The product's component swaps `-webkit-line-clamp: 2` for `unset`, which
   is not an animatable property: the paragraph simply becomes four lines
   tall in one frame and everything above it jumps. That is right on the
   detail page, where the block is in flow near the top of a scroller and
   the jump is downward into empty space. It is wrong over video, where the
   block is anchored to the BOTTOM and a sudden four lines shoves the lockup
   up the screen.

   So over video the clamp is a max-height instead — two lines at the
   component's own 14px/1.5, which is 42 — and it travels.

   THE OPEN HEIGHT IS NOT WRITTEN HERE ANY MORE. It was 240px, a guess, and
   the synopses are 105 to 126. Animating to a number nearly twice the real
   one wrecks both directions: opening, the box reaches the content's own
   height 42% of the way through its stated range, which on a front-loaded
   ease is about 30ms, so it snaps; closing, the first 58% of the travel
   happens above the content, cannot be seen, and then it drops. js/app.js
   measures the element and sets the number; this rule is where the SHUT
   height lives, which is what closing hands the property back to.

   `--ease-standard` and not `--ease-rise`, which is what the token file
   says for the synopsis in the first place: ease-rise is for a thing
   arriving from nowhere, and this is a block of text changing size. At the
   real distance 0.28s is still a glance. */
.slide .readmore p {
  display: block;
  -webkit-line-clamp: unset;
  max-height: 42px;
  overflow: hidden;
  transition: max-height var(--dur-base) var(--ease-standard);
}

/* AND THE CHIP STAYS WHERE IT IS, instead of teleporting. The component
   makes it `position: static` when open, so it leaves the end of the second
   line and reappears as a block under the paragraph in one frame — a second
   abruptness, on the one element the reader is looking at when they press.

   Pinned to the bottom right of a box that is growing, it travels with the
   box; the paragraph carries the room for it as padding, so it never sits
   on the text and `scrollHeight` counts it. */
.slide .readmore.is-open p { padding-bottom: 26px; }

.slide .readmore.is-open .readmore__more {
  position: absolute;
  right: 0;
  bottom: 0;
  display: inline-block;
  margin-top: 0;
}

/* AND THE SCRIM GROWS WITH IT. Four lines of synopsis reach further up the
   frame than two, into picture the gradient was not covering — so the
   gradient comes up to meet them, on the same curve and over the same time,
   and the text stays legible over whatever happens to be in the shot. */
/* The scrim grows with the text, so it moves on the text's curve. Two
   easings on two things travelling together is what makes a single
   movement look like two. */
.slide__scrim--bottom {
  transition: height var(--dur-base) var(--ease-standard),
              opacity var(--dur-base) var(--ease-standard) .04s;
}

.slide.is-open-desc .slide__scrim--bottom { height: 82%; }

/* ==========================================================================
   THE PROGRESS BAR
   --------------------------------------------------------------------------
   INSIDE the metadata block — same left edge, same width — and minimal.

   It was a full-bleed bar welded to the bottom of the screen, and that is
   wrong on a handset twice over: at the very last row of pixels the 44px
   corner radius eats it, and lifted clear of the radius it sits in the strip
   the home indicator owns, leaving an odd gap between the two. Aligned to
   the block it describes, it is part of the content rather than a piece of
   chrome arguing with the system's own.
   ========================================================================== */

.slide__bar {
  position: relative;
  display: block;
  width: 100%;
  height: 22px;                /* the HIT area. The drawn bar is the 2px
                                  line inside it — a 2px target is not a
                                  control, it is a dare. */
  margin-top: var(--space-s);
  touch-action: none;
}

.slide__bar::before,
.slide__bar-fill {
  content: '';
  position: absolute;
  left: 0;
  bottom: 8px;
  height: 2px;
  border-radius: var(--radius-full);
  transition: height var(--dur-fast) var(--ease-rise),
              bottom var(--dur-fast) var(--ease-rise);
}

.slide__bar::before { right: 0; background: rgba(255, 255, 255, 0.28); }
.slide__bar-fill { width: var(--pct, 0%); background: var(--accent-progress); }

/* THE KNOB IS ALWAYS THERE. It was revealed only while the bar was being
   dragged, which is the wrong way round: a reader who cannot see a handle
   has no reason to believe the line is anything but a readout, so the one
   state that needs it is the state before they have touched it. It sits on
   the line at rest, small, and grows when it is being used.

   AND IT IS CENTRED ON THE LINE BY A TRANSFORM, NOT BY ARITHMETIC.
   -----------------------------------------------------------------------
   It used to be `bottom` plus a negative `margin-bottom`, and that pair has
   to be re-derived every time the knob changes size — which it does, from 8
   to 16, every time a finger lands. Both derivations were wrong: measured
   against the drawn line, whose centre is 9px off the bar's floor in BOTH
   states, the knob's centre sat at 10 at rest and 11 while dragging. One
   pixel high, then two, on the one element whose whole job is to say
   exactly where you are.

   `bottom: 9px` puts the knob's lower edge on the line's centre and
   `translateY(50%)` drops it back by half of itself, so its middle lands
   there whatever size it happens to be. `translateX(-50%)` does the same
   job horizontally against `--pct`, which is what the old `margin-left`
   was for. Growing the knob is now one property, and it cannot drift. */
.slide__bar-knob {
  position: absolute;
  left: var(--pct, 0%);
  bottom: 9px;                 /* the drawn line's centre, in both states:
                                  2px line at bottom 8, 4px line at bottom 7 */
  width: 8px;
  height: 8px;
  margin: 0;
  transform: translate(-50%, 50%);
  border-radius: 50%;
  background: var(--accent-progress);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
  transition: width var(--dur-fast) var(--ease-rise),
              height var(--dur-fast) var(--ease-rise);
  pointer-events: none;
}

/* WHERE YOU ARE, while you are choosing it. "A bit before the middle" is
   not a position, and a 2px line cannot say one. It is only up during a
   drag, because the rest of the time the answer is "playing".
   -----------------------------------------------------------------------
   TWO READOUTS, UNDER THE LINE, ONE AT EACH END.

   It was one plate reading `0:09 / 0:12`, ABOVE the bar. Two things wrong
   with that. Above the bar is over the synopsis, so touching the line put a
   box across the sentence the reader was in the middle of — and the thing
   you are dragging is at the bottom of the block, so its readout wants to
   be the last thing down, not something that appears in the middle of it.
   And `0:09 / 0:12` is two different facts in one line: where you are, and
   how long it runs. Where you are belongs at the left-hand end, because
   that is where the fill starts; how long it runs belongs at the right,
   because that is where it ends — so the two numbers label the two ends of
   the thing they are about.

   NO PLATE BEHIND THEM. A filled box on moving picture is the artefact that
   had to come out from under the MORE chip; a text-shadow and the scrim
   that is already there do the same job without drawing a rectangle.

   They hang 8px BELOW the bar's own box, into the 48px of clearance the
   metadata block keeps off the foot of the screen — so they cost no layout
   and nothing moves when a finger lands. */
.slide__bar-at,
.slide__bar-of {
  position: absolute;
  top: 15px;
  font-size: var(--type-body-xs-size);
  font-weight: var(--type-weight-semi-bold);
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
  opacity: 0;
  transform: translateY(-3px);
  pointer-events: none;
  transition: opacity var(--dur-fast) var(--ease-standard),
              transform var(--dur-fast) var(--ease-rise);
}

.slide__bar-at { left: 0; }
.slide__bar-of { right: 0; }

.slide.is-seeking .slide__bar-at,
.slide.is-seeking .slide__bar-of { opacity: 1; transform: none; }

/* A BIGGER ROW TO GRAB. The drawn line stays 2px; what grew is the band
   around it, because the thing a finger has to find is the target and not
   the graphic. */
.slide.is-seeking .slide__bar::before,
.slide.is-seeking .slide__bar-fill { height: 4px; bottom: 7px; }
/* Size only. The transform keeps it centred.

   12, not 16. A handle has to grow enough to say "you have hold of this"
   and no more — at 16 on a 2px line it stopped being a position on a bar
   and became a disc sitting on top of one, which is the wrong thing to be
   looking at while you are choosing a frame. The thing a finger has to find
   is the 22px row, and that has not changed. */
.slide.is-seeking .slide__bar-knob { width: 12px; height: 12px; }

/* ==========================================================================
   THE CONTROLS
   The product's own `.disc`, with the ground it needs over moving picture.
   ========================================================================== */

.feed .disc {
  background: rgba(0, 24, 43, 0.46);
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.22);
  transition: background .12s var(--ease-standard),
              transform .12s var(--ease-rise);
}

/* Pressed goes LIGHTER. On a dark trailer a control that darkens on press
   has disappeared rather than responded. */
.feed .disc.is-press {
  background: rgba(255, 255, 255, 0.24);
  transform: scale(0.92);
}

/* ONE SIZE FOR EVERY CONTROL ON THE FRAME. There was a larger Play at the
   top of the column, and a column of three where one is bigger than the
   other two reads as a hierarchy that is not there — all three act on this
   trailer and none of them outranks another. 44 is the iOS touch floor,
   which the component set's own 32 is under. */
.feed .disc { width: 44px; height: 44px; }

.feed__top {
  position: absolute;
  z-index: 6;
  top: calc(var(--statusbar-height) + 8px);
  left: var(--frame-gutter);
  right: var(--frame-gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  opacity: 0;
}

/* The control column, INSIDE the slide. It was feed chrome, standing still
   while the trailer it acts on slid away underneath it — three buttons
   hovering over a programme that had already gone. It belongs to the
   picture: same stacking context, same fade, and the next trailer brings its
   own. Bottom-aligned with the metadata block beside it. */
.slide__actions {
  position: absolute;
  z-index: 6;
  right: var(--frame-gutter);
  bottom: 48px;                /* the metadata block's own baseline       */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-l);
  opacity: 0;
}

/* ---- THE OVERLAY LEAVES WITH THE PICTURE -------------------------------
   --fade is set per slide by feed.js from how far that slide is from the
   middle of the screen, so the trailer being left behind takes its own
   metadata and its own controls with it while the next one brings its own
   up into place. At rest the centre slide is 1 and the rest are 0, so this
   costs nothing until a finger is moving. */
.feed.is-live .slide__info,
.feed.is-live .slide__actions { opacity: var(--fade, 0); }

/* The one line of feedback the feed gives for something it cannot do — a
   player it does not have, a share sheet it does not have. */
.feed__say {
  position: absolute;
  left: 50%;
  bottom: 150px;
  z-index: 8;
  max-width: 300px;
  padding: 8px var(--space-l);
  border-radius: var(--radius-full);
  background: rgba(0, 24, 43, 0.74);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: var(--type-body-s-size);
  text-align: center;
  opacity: 0;
  transform: translate(-50%, 6px);
  pointer-events: none;
  transition: opacity var(--dur-fast) var(--ease-standard),
              transform var(--dur-fast) var(--ease-rise);
}
.feed__say.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ==========================================================================
   THE DETAIL LAYER
   The product's title page, pushed in from the right. Everything inside it is
   app.css; this block is only the layer it sits in.
   ========================================================================== */

.detail {
  position: absolute;
  left: 0; top: 0;
  width: var(--frame-width);
  height: var(--frame-height);
  z-index: 54;
  overflow: hidden;
  background: var(--color-background);
  box-shadow: -8px 0 28px rgba(0, 0, 0, 0.5);
  will-change: transform;
}

/* ---- THE PAGE IS FROZEN, AND THAT IS THE HONEST STATE FOR IT ----------
   Nothing below the fold on this page is real. The episode list is this
   prototype's own invention (ASSETS.md says which parts), Trailers & Extras
   holds the one clip the reader has just come out of, and More Like This is
   nine poster cards borrowed from two rails on the home screen. A reviewer
   who scrolls into that is being shown made-up depth and invited to judge
   it, and a reviewer who taps a tab gets a panel that is no better.

   So the page does not scroll and nothing in it can be pressed. The nav row
   is OUTSIDE the scroller in the markup, which is what leaves Back — the
   one thing this page genuinely does — working.

   It is a freeze, not a hide. Everything is still drawn, still legible and
   still read by a screen reader; see detail.js for the `tabindex="-1"` pass
   that takes the frozen content out of the TAB order without taking it out
   of the accessibility tree. `inert` would have done both at once, and the
   second half of that is not wanted: the text is worth reading, it is just
   not worth exploring. */
.detail .scroll {
  overflow: hidden;
  touch-action: none;
}

.detail .scroll * { pointer-events: none; }

/* While the feed is behind the detail page it is DIMMED, not hidden: a layer
   you can still see is a layer you can still get back to. */
.feed.is-behind::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 10;
  background: rgba(0, 10, 20, 0.5);
  pointer-events: none;
}

/* The detail page carries its own typeset fallback, for the same title and
   the same reason the feed does. */
.hero__wordmark {
  margin: 0;
  font-size: 30px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
  color: var(--color-on-surface);
}

/* ==========================================================================
   LESS MOVEMENT
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .feed__rail { transition: none; }
  .slide__mark { transition: none; }
}
