/* 4 Princes — press feedback (4p-press-feedback-v1); behaviour in 4p-press.js.
   Pressed: 96 % and a little darker, 80 ms in; released: springs back in 120 ms. `scale` and `filter` never move the layout
   and add to an element's own transform, so selected looks (chips, tabs, sound level) keep theirs underneath.
   Phones: no grey tap highlight, no double-tap delay on anything tappable. Game boards are never given these classes. */
html { -webkit-tap-highlight-color: transparent; }
button, a[href], [role="button"], [role="tab"], [role="menuitem"], [role="option"], input[type="submit"], input[type="button"], summary, label, [data-press] {
  touch-action: manipulation;
}
.fp-press {
  scale: 0.96;
  filter: brightness(0.86) saturate(1.08);
  transition: scale 80ms ease-out, filter 80ms ease-out !important;
}
.fp-rel {
  transition: scale 120ms cubic-bezier(0.34, 1.56, 0.64, 1), filter 120ms ease-out !important;
}

/* one send per tap: the button keeps its size, its label gives way to a small spinner in its own text colour */
.fp-busy { cursor: progress; pointer-events: none; }
.fp-busy-rel { position: relative; }
button.fp-busy, a.fp-busy { color: transparent !important; }
button.fp-busy > *, a.fp-busy > * { visibility: hidden; }
button.fp-busy::after, a.fp-busy::after {
  content: ''; position: absolute; left: 50%; top: 50%; width: 1em; height: 1em; margin: -0.5em 0 0 -0.5em; box-sizing: border-box;
  border: 2px solid var(--fp-busy-c, currentColor); border-right-color: transparent; border-radius: 50%;
  animation: fp-spin 0.7s linear infinite; visibility: visible;
}
@keyframes fp-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .fp-press { scale: none; }
  .fp-rel { scale: none; }
  button.fp-busy::after, a.fp-busy::after { content: '…'; border: 0; width: auto; height: auto; margin: 0; transform: translate(-50%, -50%);
    color: var(--fp-busy-c, inherit); font-weight: 700; line-height: 1; animation: none; }
}
