/* Real footage shares the same lightweight poster until playback succeeds. */
[data-film] { position: relative; }
[data-film-video] { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; pointer-events: none; transition: opacity 250ms ease; }
[data-film-video].is-film-playing { opacity: 1; }
.film-toggle { position: absolute; z-index: 3; right: 16px; bottom: 16px; display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 106px; padding: 10px 15px; border: 1px solid rgba(255,255,255,.65); background: rgba(var(--shadow-rgb),.88); color: #fff; font-family: var(--sans); font-size: 13px; line-height: 1.6; letter-spacing: .04em; cursor: pointer; pointer-events: auto; }
.film-toggle[hidden] { display: none; }
.film-toggle:disabled { pointer-events: none; }
.film-toggle:hover { background: var(--deep); }
.film-toggle:focus-visible { outline: 3px solid var(--deep); outline-offset: 4px; box-shadow: 0 0 0 4px #fff; }
.is-immersive .stage-image[data-film].is-active,
.is-compact-stage .stage-image[data-film].is-active { pointer-events: auto; }
.stage-image[data-film] > img { aspect-ratio: 16/9; }
.is-immersive .stage-image[data-film] > img,
.is-compact-stage .stage-image[data-film] > img { object-fit: contain; object-position: center; }
.is-immersive .stage-image[data-stage-image="0"] > img,
.is-immersive .stage-image[data-stage-image="0"] > video,
.is-compact-stage .stage-image[data-stage-image="0"] > img,
.is-compact-stage .stage-image[data-stage-image="0"] > video { object-fit: cover; object-position: center; }
.stage-image .film-toggle { top: 18px; bottom: auto; right: 18px; min-height: 48px; }
.ritual-film { width: min(100%,1080px); margin: 55px auto 0; }
.film-frame { width: 100%; aspect-ratio: 16/9; overflow: hidden; background: var(--paper); }
.film-frame > img { display: block; width: 100%; height: 100%; object-fit: contain; }
.ritual-film > figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; padding-top: 14px; font-size: 14px; line-height: 1.8; color: var(--index); }
/* Preserve the room photographs' architecture and their original proportions. */
.atelier-home .space-slide > img { aspect-ratio: auto; height: auto; }
.space-film { width: min(1600px,calc(100% - var(--gutter) * 2)); margin: 0 auto 42px; }
.space-film .film-frame { aspect-ratio: 16/9; }
.space-film > figcaption { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; margin-top: 15px; color: var(--index); font-size: 14px; line-height: 1.8; }
.inner-page .space-film { width: 100%; margin-top: 40px; }
@media (max-width:600px) {
  .film-toggle { right: 8px; bottom: 8px; padding: 8px 12px; min-width: 100px; }
  .ritual-film { margin-top: 32px; }
  .ritual-film > figcaption { font-size: 13px; }
  .stage-image .film-toggle { top: 12px; right: 12px; bottom: auto; }
  .atelier-home .space-film { width: 100%; margin-bottom: 30px; }
  .atelier-home .space-film > figcaption { padding: 0 var(--gutter); }
}
@media (prefers-reduced-motion:reduce) { [data-film-video] { transition: none; } }
@media print { [data-film-video], .film-toggle { display: none !important; } }

/* The new portrait footage has separate desktop and mobile edits. */
.film-poster { display: block; width: 100%; height: 100%; }
.film-poster > img { display: block; width: 100%; height: 100%; object-fit: contain; }
.stage-image > .film-poster { aspect-ratio: 16/9; }
.is-immersive .stage-image > .film-poster,
.is-compact-stage .stage-image > .film-poster { aspect-ratio: auto; }
.is-immersive .stage-image[data-stage-image="0"] .film-poster > img,
.is-compact-stage .stage-image[data-stage-image="0"] .film-poster > img { object-fit: cover; }
.is-compact-stage[data-current-scene="3"] .stage-images { aspect-ratio: 16/9; }
.keepsake-film { align-self: center; }
.is-linear-stage .stage-intro > .stage-image > .film-poster { aspect-ratio: auto; }
.is-linear-stage .stage-intro .film-poster > img,
.is-linear-stage .stage-intro [data-film-video] { object-fit: cover; }
@media (max-width:600px) {
  .is-compact-stage.is-in-chapters .stage-images { aspect-ratio: 4/5; max-height: 620px; }
  .film-frame:has([data-src-mobile]) { aspect-ratio: 9/16; }
  .space-film .film-frame:has([data-src-mobile]) { aspect-ratio: 9/16; }
  .stage-image > .film-poster { aspect-ratio: 9/16; }
  .is-compact-stage .stage-image > .film-poster { aspect-ratio: auto; }
}
