/* ==========================================================================
   STONEGRAPH — the motion runs on every device
   --------------------------------------------------------------------------
   WHY THIS FILE EXISTS

   `prefers-reduced-motion: reduce` is meant to be a considered accessibility
   choice. On Android it is not one. Battery Saver sets it, and Battery Saver
   comes on by itself at twenty per cent — so a visitor whose phone is simply
   low on charge was being handed a different, worse website: the plates on the
   homepage stopped drifting, every reveal lost its rise, the network snapped
   into place instead of assembling, and the studio page opened as a still.

   The decision here is the studio's, and it is deliberate: this site presents
   the same work to everybody, and a phone at nineteen per cent is not a
   different visitor. Every animation runs on every device, all the time.

   WHAT THAT COSTS, STATED PLAINLY

   A reader who has genuinely set Reduce Motion — on iOS, where the setting is
   an explicit accessibility choice rather than a power state — will now get
   the full motion too. Nothing on this site is large-amplitude or
   vestibular-triggering: the travel is sixteen pixels of rise, a 1.06 scale
   settle, a fourteen-pixel parallax and a hairline drawing itself. It is at
   the gentle end of what the preference exists to catch. That is the trade
   being made, and it is being made knowingly rather than by omission.

   HOW IT WORKS, AND WHY IT CHANGED

   This file used to load last and re-declare, inside the same media query,
   everything the earlier sheets switched off there. That is a losing
   arrangement and it lost: a restoration has to name every property the
   suppressions touch, so anything it missed — or anything added to a
   suppression block afterwards — came back as a second, quieter version of
   the site for anyone whose phone had reached twenty per cent. It is how the
   reveal timings ended up slower on a low battery than on a full one: the
   values here were copied before a later speed pass shortened them, and
   nobody had a reason to look.

   Nothing is restored now, because nothing is taken away. Every
   `prefers-reduced-motion: reduce` block on the site — twenty-two of them,
   across five stylesheets — carries a second, contradictory clause:

       @media (prefers-reduced-motion: reduce)
          and (prefers-reduced-motion: no-preference)

   The feature has exactly those two values and a browser reports one of them,
   so the condition cannot be true and the block never applies. Each one stays
   where it is, fully readable, with its own reasoning intact.

   The consequence worth stating plainly: there is no longer any code path,
   in any stylesheet, that produces a different site under Battery Saver.
   Not a shorter transition, not a missing drift, not a still hero. The same
   page, at nineteen per cent and at a hundred.

   TO RESTORE THE BROWSER DEFAULT
   Delete the `and (prefers-reduced-motion: no-preference)` clause from every
   block that carries the marker comment, and set window.STONEGRAPH_MOTION to
   "auto" in the page head. Both halves are needed: the stylesheets and the
   four scripts read the policy independently.

   WHAT REMAINS BELOW
   Only the rules outside the query — the guards that keep a content
   photograph from being scaled or parallaxed inside its mount. Those are not
   part of the motion policy and apply to everybody. The block that follows is
   switched off with the rest and is kept for the same reason they are.
   ========================================================================== */

@media (prefers-reduced-motion: reduce) and (prefers-reduced-motion: no-preference) { /* OFF by the motion policy — see motion-always.css */

  /* ---- smooth scrolling ---- */
  html { scroll-behavior: smooth; }

  /* ---- the reveals: the rise comes back ----
     site.css forces `transform: none !important` on all three of these and
     swaps the transition for opacity alone. Re-declared here with the values
     from components.css, at the same weight. */
  html.js-reveal .reveal {
    transform: translateY(30px) !important;
    /* Timings match the speed pass in components.css exactly. They have to be
       restated rather than inherited: this file re-declares the whole rule
       inside the reduced-motion query at !important, so anything it leaves out
       falls back to the pre-speed-pass value and the page runs slower on a
       phone that is merely low on charge. */
    transition: opacity .42s var(--ease), transform .42s var(--ease) !important;
    transition-delay: calc(var(--rd, 0s) * 0.35) !important;
  }
  html.js-reveal .reveal.is-in { opacity: 1 !important; transform: none !important; }

  html.js-reveal .reveal-line {
    transform: scaleX(0) !important;
    transform-origin: left;
    opacity: 1;
    transition: transform .55s var(--ease) !important;
    transition-delay: calc(var(--rd, 0s) * 0.35) !important;
  }
  html.js-reveal .reveal-line.is-in { transform: scaleX(1) !important; opacity: 1; }

  html.js-reveal .rise-mask > span {
    transform: translateY(135%) !important;
    opacity: 1;
    transition: transform .5s var(--ease) !important;
    transition-delay: calc(var(--rd, 0s) * 0.35) !important;
  }
  html.js-reveal .rise-mask.is-in > span { transform: none !important; opacity: 1; }

  /* Photographs settle rather than appear. */
  html.js-reveal .reveal .plate img {
    transform: scale(1.12) !important;
    opacity: 0 !important;
    transition: transform .9s var(--ease), opacity .7s var(--ease) !important;
    transition-delay: calc(var(--rd, 0s) * 0.35) !important;
  }
  html.js-reveal .reveal.is-in .plate img { transform: none !important; opacity: 1 !important; }

  /* ---- the constellation ----
     The plates drift. This is the one the brief names: on a laptop the
     photographs are alive, and on a phone they were pinned still. */
  .cn__drift {
    animation-name: cn-float !important;
    animation-timing-function: ease-in-out !important;
    animation-iteration-count: infinite !important;
    animation-direction: alternate !important;
  }
  .cn::before { transition: inset 1.1s cubic-bezier(.16,1,.3,1), border-radius 1.1s cubic-bezier(.16,1,.3,1); }
  .cn--closed { --cn-inset: 44px; --cn-round: 20px; }
  .cn__hub-t { transition: fill .35s ease; }

  /* ---- the motion layer ---- */
  .motion-on .m-shot img,
  .motion-on .m-shot video {
    transform: translate3d(0, var(--mp, 0px), 0) scale(var(--ms, 1)) !important;
  }
  .motion-on .m-shot--settling img,
  .motion-on .m-shot--settling video {
    transition: transform 1.5s var(--ease, cubic-bezier(.16,1,.3,1)) !important;
  }
  .motion-on .btn { transform: translate3d(var(--mx, 0px), var(--my, 0px), 0) !important; }
  .pt-veil { display: block; }
  .motion-on .band--dark > .m-glow { display: block; }

  /* ---- the studio page ---- */
  .stu-card.is-in { animation: stu-card-in 1s var(--ease, cubic-bezier(.16,1,.3,1)) both !important; }
  .stu-track::before { transform: scaleY(0) !important; opacity: 1 !important; transition: transform 1.6s cubic-bezier(.22,.61,.36,1) .2s !important; }
  .stu-track.is-in::before { transform: scaleY(1) !important; }
  .stu-area .stu-area__mark::before { transform: scale(0) !important; opacity: 1 !important; transition: transform .7s var(--ease, cubic-bezier(.16,1,.3,1)) var(--rd, 0s) !important; }
  .stu-area.is-in .stu-area__mark::before { transform: scale(1) !important; }
  .stu-hero--open .stu-pill { animation: stu-pill-in 1s var(--ease, cubic-bezier(.16,1,.3,1)) both .1s !important; }
  .stu-hero--open .stu-hero__tick { animation: stu-tick 1.1s cubic-bezier(.16,1,.3,1) both 1.05s !important; }
  .stu-pill__dot::before { animation: stu-ping 2.4s cubic-bezier(0,0,.2,1) infinite !important; }
  .stu-globe__ring { animation: stu-spin 34s linear infinite !important; }

  /* ---- the hero, the art layer, the spine ---- */
  .is-entering .hero__inner { opacity: 0; transform: translateY(18px); }
  .is-entered .enter { transition-duration: inherit; }
}

/* A content photograph is evidence, not a background texture. Scaling or
   parallax-translating it inside an overflow-clipped mount is a crop, even
   when the final resting value is 1. The section may still reveal; the image
   itself always remains mathematically inside its frame. */
.motion-on .m-shot img,
.motion-on .m-shot video,
.motion-on .m-shot--settling img,
.motion-on .m-shot--settling video {
  transform: none !important;
  will-change: auto !important;
}

.motion-on .m-shot--settling img,
.motion-on .m-shot--settling video { transition: none !important; }
