/* A lesson's Watch blocks: the poster of a video that may play whole, with its line on why it fits, and the player
   (tools/courses/render/tools.py poster and video_why, site/tools/clip.js), 2026-11-19. A poster is a frame at the
   video's 16:9 ratio in the page's own colours: no picture from YouTube, nothing loaded before a press of Play. The page
   links this sheet after site.css on a page that holds a Watch block (render/page.py shell). Sizes keep the School's
   reading floor: body words 18 px, every other word 15 px, keys 44 px and up. */

.video-poster { min-width: 0; margin: 16px 0 8px; }
.video-screen { box-sizing: border-box; display: flex; align-items: center; justify-content: center; width: 100%;
  aspect-ratio: 16 / 9; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
.video-screen .video-play { gap: 10px; min-width: 132px; min-height: 52px; padding: 0 26px 0 22px; border: 0;
  background: var(--ink); color: var(--bg); font: 600 18px/1 var(--ui); }
.video-screen .video-play::before { content: ""; width: 0; height: 0; border-style: solid; border-width: 8px 0 8px 13px;
  border-color: transparent transparent transparent currentColor; }
.video-screen .video-play:hover { box-shadow: 0 0 0 3px var(--accent); }
.video-screen .video-play:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.video-poster figcaption { margin-top: 12px; }
.lesson-page .video-poster .video-head { margin: 0; font: 15px/1.5 var(--ui); color: var(--dim); }
.video-poster .video-title { display: block; margin-bottom: 2px; font: 600 18px/1.4 var(--display); color: var(--ink); }
.video-poster .video-channel + .video-length::before { content: "· "; content: "· " / ""; }
.video-poster .video-head a { display: inline-flex; align-items: center; min-height: 44px; margin-left: 6px; }
.video-poster.clip-playing { box-shadow: none; padding-left: 0; }
.lesson-page .video .video-why { margin: 6px 0 0; font: 18px/1.6 var(--ui); color: var(--ink); }
/* The notice's sentence, then its three links on a row of their own, each 44 px tall, wrapping where the column ends. */
.lesson-page .video .clip-privacy { display: flex; flex-wrap: wrap; align-items: center; column-gap: 16px; font-size: 15px; }
.lesson-page .video .clip-privacy a { display: inline-flex; align-items: center; min-height: 44px; margin: 0; }

/* While the player is open, it stands under the poster's words and the frame steps aside. */
.video.video-open .video-screen { display: none; }

/* The Watch block's grids (site/scss/_tools.scss) place a video's clips side by side. A poster's video has no clip, so it
   stays one column, its player in the reading column at every width. */
@media (min-width: 600px) and (max-width: 1039px) {
  .tool[data-tool="clip"] .video > .video-poster { grid-column: 1 / -1; }
  .tool[data-tool="clip"] .video:not(:has(> .clip)) { display: block; }
}
@media (min-width: 1440px) {
  .pg-lesson .video:not(:has(> .clip)):has(> .clip-stage) { display: block; width: auto; }
}
@media (prefers-reduced-motion: no-preference) {
  .video-screen .video-play { transition: box-shadow .15s ease; }
}
@media (forced-colors: active) {
  .video-screen .video-play { border: 2px solid ButtonText; }
}
@media print {
  .video-screen { display: none; }
}
