/*
 * motion.css — web port of Motion.swift tokens + PressableStyle.
 * A crisp, fast dashboard: everything < 300ms (except the ring), ease-out,
 * transform/opacity only, reduced-motion aware. Press feedback = scale 0.97 +
 * opacity 0.92 (PressableStyle), eased over 160ms (Motion.press).
 */

:root {
  --motion-press: 160ms;    /* Motion.press   — button press */
  --motion-enter: 280ms;    /* Motion.enter   — content appearing */
  --motion-content: 400ms;  /* Motion.content — state morph */
  --motion-ring: 500ms;     /* Motion.ring    — donut fill on load */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Rest state — eased return after release, transform/opacity only. */
button,
.seg,
.chip,
.seg-sm,
.vas-cell,
.survey-row,
.bm-chip {
  transition: transform var(--motion-press) var(--ease-out),
              opacity var(--motion-press) var(--ease-out);
  will-change: transform;
}

/* Pressed state — scale-down + dim, the tactile "tap registered" confirmation. */
button:active,
.seg:active,
.chip:active,
.seg-sm:active,
.vas-cell:active,
.survey-row:active,
.bm-chip:active {
  transform: scale(0.97);
  opacity: 0.92;
}

/* Reduced motion: keep the opacity dim, drop the scale + transitions. */
@media (prefers-reduced-motion: reduce) {
  button,
  .seg,
  .chip,
  .seg-sm,
  .vas-cell,
  .survey-row,
  .bm-chip {
    transition: none;
  }
  button:active,
  .seg:active,
  .chip:active,
  .seg-sm:active,
  .vas-cell:active,
  .survey-row:active,
  .bm-chip:active {
    transform: none;
    opacity: 0.92;
  }
}
