/* Motion only: no delayed actions, no numeric counters, no animated backgrounds.
 * Closures remain immediate, preserving focus restoration and existing callbacks.
 * Animate persistent view roots, never regenerated financial rows/cards. */
:root { --motion-ease: cubic-bezier(.2,.65,.3,1); }
@keyframes section-arrival {
  from { opacity: .5; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes detail-arrival {
  from { opacity: .6; transform: translateY(-3px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes dialog-arrival {
  from { opacity: .5; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes veil-arrival { from { opacity: .6; } to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  .page.on { animation: section-arrival 180ms var(--motion-ease); }
  .fb-drawer.open, .mob-cell.open .mob-detail { animation: detail-arrival 150ms var(--motion-ease); }
  .mov.open { animation: veil-arrival 130ms ease-out; }
  .mov.open > .mod, dialog[open] { animation: dialog-arrival 160ms var(--motion-ease); }
  .ni, .tab, .mpill, .mov-seg-btn {
    transition: background-color 140ms ease, color 140ms ease, box-shadow 140ms ease;
  }
  .btn-primary, .btn-pdf, .add-btn, .btn-sec, .bg2, .bp, .bd, .fb-filter-btn {
    transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease, transform 120ms ease;
  }
  .fi input, .fi select, .fi textarea, .pres-input {
    transition: border-color 140ms ease, box-shadow 140ms ease;
  }
  .fi input:focus, .fi select:focus, .fi textarea:focus { box-shadow: 0 0 0 3px #265bc112; }
  #toast.toast { transition: opacity 160ms ease, transform 160ms var(--motion-ease), visibility 160ms; }
}
@media (hover:hover) and (pointer:fine) and (prefers-reduced-motion:no-preference) {
  .btn-primary:not(:disabled):hover, .btn-pdf:not(:disabled):hover, .add-btn:not(:disabled):hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px #204f9e2c;
  }
  .btn-primary:not(:disabled):active, .btn-pdf:not(:disabled):active, .add-btn:not(:disabled):active { transform: translateY(1px); }
}
@media (prefers-reduced-motion:reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  button:active { transform: none; }
}
