/* PLAT 2 - calm open/close for every <details> (flag PR_PLAT_DETAILS). CSS only: no script, nothing is removed from the HTML, so crawlers
   still read every answer. Only where the browser can animate to `height: auto` (interpolate-size) AND exposes the content slot
   (::details-content); other browsers keep today's instant open/close. Reduced motion: no transition at all.
   The slot is the whole body of the disclosure, so the summary never moves and the text below shifts by the answer's own height,
   the same total shift as the instant open (only spread over 220 ms), so the reader's place is kept. */
@supports (interpolate-size: allow-keywords) and selector(::details-content) {
  @media (prefers-reduced-motion: no-preference) {
    :root { interpolate-size: allow-keywords; }
    body.v2 details::details-content {
      block-size: 0; opacity: 0; overflow: clip;
      transition: block-size 220ms var(--v2-ease, ease), opacity 160ms ease, content-visibility 220ms allow-discrete;
    }
    body.v2 details[open]::details-content { block-size: auto; opacity: 1; }
    @starting-style { body.v2 details[open]::details-content { block-size: 0; opacity: 0; } }
  }
}
