/* Home with reduced motion. Owner ruling of 2026-11-02 (docs/rulings/2026-11-02_ruling-reduced-motion-home.txt).
   Every rule sits inside (prefers-reduced-motion: reduce), so a visitor without the preference gets nothing from this
   file, and a visitor who chooses the cinematic (motion-choice.js, ?motion=full) has these queries switched off. The
   approved opening is held still at its first frame; the film's lines stand as plain text on graphite after it. */
@media (prefers-reduced-motion: reduce) {
  html[data-cinematic="static"] .page-home .cinematic { height: auto !important; }
  html[data-cinematic="static"] .page-home .cinematic__pin {
    position: relative; height: auto; overflow: clip; padding-top: 100vh; padding-top: 100svh;
  }
  html[data-cinematic="static"] .page-home .cinematic__frame {
    position: absolute; top: 0; height: 100vh !important; height: 100svh !important;
  }
  html[data-cinematic="static"] .page-home .arrival-copy { top: 28.5vh; }

  html[data-cinematic="static"] .film {
    display: block !important; position: relative; inset: auto; overflow: visible; height: auto;
    padding: var(--space-6) var(--gutter); background: var(--graphite); color: var(--ivory);
  }
  html[data-cinematic="static"] .film-ruler,
  html[data-cinematic="static"] .film__veil,
  html[data-cinematic="static"] .film__pool,
  html[data-cinematic="static"] .film__swell,
  html[data-cinematic="static"] .film__bridge { display: none !important; }

  html[data-cinematic="static"] .film__beat,
  html[data-cinematic="static"] .film__moment,
  html[data-cinematic="static"] .film__slot,
  html[data-cinematic="static"] .film__frame,
  html[data-cinematic="static"] .film__moment .wrap,
  html[data-cinematic="static"] .film .recog,
  html[data-cinematic="static"] .film .recog__frame {
    position: static; inset: auto; height: auto; min-height: 0; width: auto; max-width: none;
    margin: 0; padding: 0; transform: none; opacity: 1; text-align: left; background: none; border: 0;
  }
  html[data-cinematic="static"] .film__moment { margin-top: var(--space-5); padding-top: var(--space-5); border-top: 1px solid var(--ivory-16); }
  html[data-cinematic="static"] .film__beat--tagline { margin-top: var(--space-5); padding-top: var(--space-5); border-top: 1px solid var(--ivory-16); }
  html[data-cinematic="static"] .film__welcome,
  html[data-cinematic="static"] .film__headline,
  html[data-cinematic="static"] .film__support,
  html[data-cinematic="static"] .film__moment--three p,
  html[data-cinematic="static"] .film__tagline {
    position: static; inset: auto; opacity: 1; transform: none; animation: none; color: var(--ivory); text-shadow: none;
  }
  html[data-cinematic="static"] .film__support { color: var(--ivory-72); }
  html[data-cinematic="static"] .film .recog__statement { font-size: var(--film-size); line-height: 1; }
  html[data-cinematic="static"] .film .recog__role { margin-top: calc(var(--film-size) * 0.34); color: var(--ivory-72); font-size: calc(var(--film-size) * 0.44); }

  /* the one control: a hairline gold frame on graphite, the display face in ivory, at least 48 px tall */
  .motion-choice {
    position: absolute; z-index: 7; left: 58%; top: calc(28.5vh + 7vh + 5.5rem);
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 48px; margin: 0; padding: 0.625rem 1.375rem;
    border: 1px solid var(--gold); border-radius: 0; background: rgb(37 37 38 / 0.66); cursor: pointer;
    color: var(--ivory); font-family: var(--font-display); font-style: italic; font-weight: 400;
    font-size: 1.1875rem; line-height: 1.2; letter-spacing: 0.01em; white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
  }
  .motion-choice:hover { background: rgb(37 37 38 / 0.84); }
  .motion-choice:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
}

@media (prefers-reduced-motion: reduce) and (min-width: 960px) {
  html[data-cinematic="static"] .film {
    display: grid !important; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); column-gap: var(--space-6);
    padding-inline: max(var(--gutter), calc((100vw - var(--wrap-max)) / 2));
    --film-size: clamp(2.5rem, 3.4vw, 4rem);
  }
  html[data-cinematic="static"] .film__welcome { font-size: clamp(3rem, 4.6vw, 5.5rem); }
  html[data-cinematic="static"] .film__beat--welcome { grid-column: 1; grid-row: 1 / span 4; }
  html[data-cinematic="static"] .film__moment,
  html[data-cinematic="static"] .film__beat--tagline { grid-column: 2; }
  html[data-cinematic="static"] .film__moment--one { margin-top: 0; padding-top: 0; border-top: 0; }
}

/* a phone on its side narrower than the one-line control (it stands at 58%): two lines, inside the window */
@media (prefers-reduced-motion: reduce) and (max-width: 799px) and (orientation: landscape) {
  .motion-choice { max-width: calc(42vw - 1rem); padding-inline: 1rem; white-space: normal; text-wrap: balance; }
}

/* the approved tablet opening, at its first frame, held still */
@media (prefers-reduced-motion: reduce) and (min-width: 720px) and (orientation: portrait) {
  html[data-device-tier="tablet"][data-cinematic="static"] .page-home .cinematic__frame {
    --tab-picture: max(100vw, 177.7778vh);
    --tab-room: calc((var(--tab-picture) - 100vw) / 2);
    --tab-open: max(0px, calc(var(--tab-room) - var(--tab-picture) * 0.125));
    left: calc(50% - var(--tab-picture) / 2) !important;
    width: var(--tab-picture) !important;
    translate: var(--tab-open) 0;
  }
  html[data-device-tier="tablet"][data-cinematic="static"] .film-id {
    position: absolute;
    top: calc(11.5vh - var(--film-id-size) * 1.05 - clamp(0.9rem, 1.3vw, 1.4rem) - 1.8rem);
    right: calc(58vw - min(100vw - var(--gutter), 0.42 * max(100vw, 177.7778vh)) - var(--film-id-size) * 0.14);
    width: max-content;
    margin-top: 0;
  }
  html[data-device-tier="tablet"] .motion-choice {
    left: auto; right: var(--gutter); top: auto; bottom: calc(100% - 100svh + 2rem);
  }
}

/* the approved phone opening, at its first frame, held still */
@media (prefers-reduced-motion: reduce) and (max-width: 719px) and (orientation: portrait) {
  html[data-cinematic="static"] .page-home .cinematic__frame {
    --film-picture: max(100vw, 177.7778vh);
    --film-room: calc((var(--film-picture) - 100vw) / 2);
    --film-open: min(calc(var(--film-picture) * 0.26), var(--film-room));
    --film-head: clamp(0px, calc(var(--nav-h) + 3rem - 11vh), var(--nav-h));
    left: calc(50% - var(--film-picture) / 2) !important;
    width: var(--film-picture) !important;
    translate: var(--film-open) var(--film-head);
  }
  html[data-cinematic="static"] .film-id {
    margin-top: calc(var(--nav-h) + 0.25rem - 28.5vh);
  }
  html[data-cinematic="static"] .film-id__line { margin-top: 0.35rem; }
  html[data-cinematic="static"] .film-id::before { inset: -4.5rem -30vw -3.8rem -60vw; }
  .motion-choice {
    left: 50%; top: auto; bottom: calc(100% - 100svh + 0.875rem); translate: -50% 0; max-width: calc(100vw - 2 * var(--gutter));
  }
}

/* a shorter phone: the keys sit lower in the window, so the control stands to their right, on two lines */
@media (prefers-reduced-motion: reduce) and (max-width: 719px) and (orientation: portrait) and (max-height: 719px) {
  .motion-choice {
    left: auto; right: var(--gutter); translate: none; max-width: 10.5em; padding-inline: 1rem; white-space: normal; text-wrap: balance;
  }
}
@media (prefers-reduced-motion: reduce) and (max-width: 359px) and (orientation: portrait) and (max-height: 719px) {
  .motion-choice { font-size: 1.0625rem; }
}
