/* The film player: a 16:9 paper stage with a fender-yellow play button. Used on / and on /film/. */
.film { position: relative; }
.film-stage {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden;
  border-radius: clamp(10px, 1.6vw, 20px);
  background: #f4ecd8;
  box-shadow: 0 0 0 clamp(5px, .7vw, 9px) #fdfbf3, 0 30px 60px -20px rgba(0, 16, 22, .7), 0 10px 20px -10px rgba(0, 16, 22, .5);
}
.film-canvas, .film-poster { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.film-canvas { cursor: pointer; }
.film-poster { object-fit: cover; }
.film[data-state="playing"] .film-poster, .film[data-state="paused"] .film-poster, .film[data-state="ended"] .film-poster { display: none; }

.film-play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: grid; justify-items: center; gap: 4px;
  font: 700 clamp(1rem, 2.2vw, 1.375rem)/1.1 var(--display, sans-serif); color: var(--ink, #0a3341);
  background: none; border: 0; padding: 0; cursor: pointer;
}
.film-play-icon {
  width: clamp(64px, 11vw, 116px); height: clamp(64px, 11vw, 116px); border-radius: 50%;
  background: var(--fender, #f0b429); border: 3px solid var(--fender-line, #8b6115);
  box-shadow: 0 0 0 clamp(4px, .6vw, 7px) #fdfbf3, 0 14px 28px -8px rgba(0, 20, 26, .55);
  display: grid; place-items: center; margin-bottom: 10px;
  transition: transform .2s ease;
}
.film-play-icon::before {
  content: ""; margin-left: 12%;
  border-left: clamp(20px, 3.4vw, 36px) solid var(--ink, #0a3341);
  border-top: clamp(13px, 2.2vw, 23px) solid transparent; border-bottom: clamp(13px, 2.2vw, 23px) solid transparent;
}
.film-play:hover .film-play-icon { transform: scale(1.06) rotate(-4deg); }
.film-play-label, .film-play-meta {
  background: #fdfbf3; padding: 6px 12px; border-radius: 4px; box-shadow: 0 6px 14px -8px rgba(0, 20, 26, .6);
}
.film-play-label { transform: rotate(-2deg); }
.film-play-meta { font: 600 clamp(.75rem, 1.4vw, .875rem)/1.2 var(--text, sans-serif); transform: rotate(1.5deg); color: #3b5a63; }
.film[data-state="playing"] .film-play, .film[data-state="ended"] .film-play { display: none; }
.film-end[hidden], .film-tools [hidden] { display: none; }
.film[data-state="loading"] .film-play-icon { animation: film-bob 1s ease-in-out infinite; }
.film[data-state="loading"] .film-play-icon::before { opacity: .35; }
@keyframes film-bob { 50% { transform: translateY(-6px) rotate(-6deg); } }
@media (prefers-reduced-motion: reduce) { .film[data-state="loading"] .film-play-icon { animation: none; } }

.film-status {
  position: absolute; left: 50%; bottom: 10%; transform: translateX(-50%); margin: 0;
  font: 600 .9375rem/1.3 var(--text, sans-serif); color: var(--ink, #0a3341); background: #fdfbf3;
  padding: 6px 12px; border-radius: 4px; white-space: nowrap;
}
.film-status:empty { display: none; }

.film-tools { position: absolute; right: 10px; top: 10px; display: flex; gap: 8px; opacity: 0; transition: opacity .2s; }
.film-stage:hover .film-tools, .film-tools:focus-within, .film[data-state="paused"] .film-tools, .film[data-state="ended"] .film-tools { opacity: 1; }
.film-tools button {
  font: 700 .8125rem/1 var(--text, sans-serif); color: var(--ink, #0a3341); background: rgba(253, 251, 243, .92);
  border: 0; border-radius: 6px; padding: 8px 10px; cursor: pointer;
}
.film-tools button[aria-pressed="true"] { background: var(--fender, #f0b429); }
.film-caption {
  position: absolute; left: 50%; bottom: 4%; transform: translateX(-50%); width: min(86%, 900px); margin: 0;
  text-align: center; font: 600 clamp(.8125rem, 1.8vw, 1.25rem)/1.35 var(--text, sans-serif); color: #fdfbf3;
  text-shadow: 0 1px 2px #000, 0 0 8px rgba(0, 0, 0, .6); pointer-events: none;
}
.film-caption:empty { display: none; }

.film-end {
  margin-top: clamp(22px, 3vw, 34px); display: grid; gap: 6px 32px; align-items: center;
  padding: 22px clamp(18px, 3vw, 32px); border-radius: 14px; background: var(--harbour, #0e3d4b);
  box-shadow: inset 0 0 0 2px rgba(180, 206, 210, .18);
}
@media (min-width: 860px) { .film-end { grid-template-columns: 1fr auto; } }
.film-end h3 { font-size: 1.375rem; }
.film-end p { color: var(--mist, #b4ced2); margin-top: 4px; }
.film-replay {
  font: 600 1rem var(--text, sans-serif); color: var(--hull, #fbfaf2); background: none; cursor: pointer;
  border: 2px solid rgba(180, 206, 210, .5); border-radius: 999px; padding: 10px 20px; justify-self: start;
}
.film-replay:hover { border-color: var(--hull, #fbfaf2); }

.film-stage:fullscreen { aspect-ratio: auto; width: 100vw; height: 100vh; border-radius: 0; box-shadow: none; background: #0a2f3a; }
.film-stage:fullscreen .film-canvas { width: min(100vw, 177.78vh); height: min(56.25vw, 100vh); inset: 0; margin: auto; }
.film-store { display: inline-block; margin-top: 16px; line-height: 0; border-radius: 9px; }
.film-store img { display: block; width: auto; height: 54px; }
.film-store:hover img { filter: brightness(1.15); }
.film-links { margin: 12px 4px 0; text-align: right; font: 600 .9375rem/1.4 var(--text, sans-serif); }
.film-links a { color: var(--mist, #b4ced2); text-decoration: none; }
.film-links a:hover { color: var(--hull, #fbfaf2); text-decoration: underline; }
