/* Phone lens-change panel ("Get your lenses faster, thinner and cheaper"): the lens-swap video fills the panel and sits above the
   still images (the React phone page's .m-lenschange video rule). The panel keeps its own size, radius and blue from the theme.
   The video is transparent until its first frame is drawn, so the stills show until then without any script. */
[role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] > video[data-lens-video] {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Centering. In the 1024x576 video (and in the still, which is its first frame) the glasses and the sliding lenses sit right of
   the middle: over the whole loop they span x 247 to 977, so their centre is at 612, 100 px (9.77%) right of the panel centre.
   Everything in the panel moves left by that amount, so the glasses and lenses are centred side to side and the still lines up
   with the video. 1 cqw is 1% of the panel width (the panel is the query container), so the shift scales with the panel.
   Vertically the glasses at rest are already within 2% of the centre, so that is left alone. The video's own blue (185, 197, 208)
   is 2 levels darker than the panel's, so a shadow of that colour fills the strip the shift uncovers on the right, without a seam.
   Browsers without container units skip these rules and show the video where it was. */
[role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] {
  container-type: inline-size;
}
[role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] > img,
[role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] > video[data-lens-video] {
  transform: translateX(-9.77cqw);
}
[role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] > video[data-lens-video] {
  box-shadow: 10cqw 0 0 0 rgb(185, 197, 208);
}

/* Reduced motion: keep the still (the video is also removed from the page by a small inline script in the markup). */
@media (prefers-reduced-motion: reduce) {
  [role="img"][aria-label="Prescription glasses with the lenses sliding out of the frame"] > video[data-lens-video] {
    display: none;
  }
}
