/* Laundry Monsters films: the shared gallery frame and story description. */
body[data-lm-floating-watch] .lm-film-dialog {
  position: fixed; inset: 0; z-index: 10000; box-sizing: border-box;
  width: 100%; max-width: none; height: 100%; height: 100dvh; max-height: none;
  margin: 0; padding: 28px 24px; border: 0; background: transparent;
  overflow: auto; overscroll-behavior: contain; color: #999; outline: 0;
}
body[data-lm-floating-watch] .lm-film-dialog[open] { display: flex; }
body[data-lm-floating-watch] .lm-film-dialog::backdrop { background: #000; }
body[data-lm-floating-watch] .lm-watch-backdrop {
  position: fixed; inset: 0; z-index: -1; display: block;
  background-color: #000;
  background-image: linear-gradient(rgba(0,0,0,.72), rgba(0,0,0,.72)), var(--lm-watch-background);
  background-position: center top; background-size: cover; background-repeat: no-repeat;
  outline: 0; border: 0; box-shadow: none; -webkit-tap-highlight-color: transparent;
}
body[data-lm-floating-watch] .lm-watch {
  position: relative; flex: none; box-sizing: border-box;
  width: min(100%, 1280px, max(680px, calc(177.7778dvh - 480px)));
  max-width: 100%; margin: auto; padding: 26px; background: #000;
}
body[data-lm-floating-watch] .lm-film-description {
  min-height: 0; padding: 22px 4px 0;
  color: #999; font: 16px/1.6 Arial, Helvetica, sans-serif;
}
body[data-lm-floating-watch] .lm-film-description h1 {
  max-width: none; margin: 0 0 12px;
  color: #aaa; font: 400 21px/1.3 Arial, Helvetica, sans-serif;
}
body[data-lm-floating-watch] .lm-film-description p { max-width: 100ch; }
body[data-lm-floating-watch] .lm-film-description a { color: #999; }
body[data-lm-floating-watch] .lm-film-description a:hover { color: #e8e8e8; }
body[data-lm-floating-watch] .lm-watch-keyboard-close {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap;
}
body[data-lm-floating-watch] .lm-watch-keyboard-close:focus {
  clip: auto; clip-path: none; width: auto; height: auto; top: 4px; right: 4px;
  z-index: 2; margin: 0; padding: 8px 12px; background: #000; color: #eee;
  border: 1px solid #aaa; outline: 2px solid #eee; font: 16px/1.3 Arial,sans-serif;
}
@media (max-width: 800px) {
  body[data-lm-floating-watch] .lm-film-dialog { padding: 20px 8px; }
  body[data-lm-floating-watch] .lm-watch { width: 100%; padding: 12px; }
  body[data-lm-floating-watch] .lm-film-description { min-height: 0; padding: 18px 4px 4px; font-size: 16px; }
  body[data-lm-floating-watch] .lm-film-description h1 { font-size: 19px; }
}

body[data-lm-floating-watch] .lm-film-description .lm-film-links { margin-top: 20px; font-size: 14px; }
/* The solid return arrow matches the existing character-page navigation. */
body[data-lm-floating-watch] .lm-film-description .lm-film-back {
  display: inline-flex; align-items: center; gap: .65em;
  font: bold 14.95px/1.4 Arial, sans-serif; letter-spacing: .035em;
  text-transform: uppercase; text-decoration: none;
}
body[data-lm-floating-watch] .lm-film-back::before {
  content: ""; flex: 0 0 auto; width: 0; height: 0;
  border-style: solid; border-width: .45em .65em .45em 0;
  border-color: transparent currentColor transparent transparent;
  pointer-events: none;
}

/* Single-film close-control trial: outside the frame, at the screen's top right. */
body[data-lm-floating-watch] .lm-film-dialog[data-lm-close-pilot] { padding-top: 48px; }
body[data-lm-floating-watch] .lm-watch-close {
  position: fixed; top: env(safe-area-inset-top, 0px); right: env(safe-area-inset-right, 0px);
  z-index: 3; display: block; box-sizing: border-box; width: 44px; height: 44px;
  margin: 0; padding: 0; border: 0; background: transparent; color: #999;
  text-decoration: none; box-shadow: none; outline: none;
  -webkit-tap-highlight-color: transparent;
}
body[data-lm-floating-watch] .lm-watch-close::before,
body[data-lm-floating-watch] .lm-watch-close::after {
  content: ""; position: absolute; top: 50%; left: 50%; width: 20px; height: 1px;
  background: currentColor; transform: translate(-50%, -50%) rotate(45deg);
  pointer-events: none;
}
body[data-lm-floating-watch] .lm-watch-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}
body[data-lm-floating-watch] .lm-watch-close:hover { color: #fff; }
body[data-lm-floating-watch] .lm-watch-close:focus-visible {
  color: #fff; outline: 1px solid #999; outline-offset: -6px;
}
