/* Shared interaction for result / performance cards ----------------------
   Every talent page uses the same interaction: the supporting event/region
   label turns brand blue when its result card is hovered or keyboard-focused.
   This component is loaded after each page stylesheet so the behaviour stays
   consistent even when individual profile layouts differ. */

a.performance-link:is(:hover, :focus-visible) small,
a.performance:is(:hover, :focus-visible) small,
a.milestone:is(:hover, :focus-visible) small,
.performance-stat:hover > small,
.performance-stat:focus-within > small {
  color: var(--blue, #315cff);
}

/* Tawk's third result contains two source links inside the supporting label. */
.performance-stat:is(:hover, :focus-within) .perf-inline-link {
  color: var(--blue, #315cff);
}

/* Trackmania compact EWC cards. */
a.ewc-main:is(:hover, :focus-visible) .ewc-result {
  color: var(--blue, #315cff);
}

/* Kaadxzu's EWC ledger uses .ewc-result for the full card. */
a.ewc-result:is(:hover, :focus-visible) > span:last-child {
  color: var(--blue, #315cff);
}

:where(
  .performance-stat small,
  .performance small,
  .milestone small,
  .ewc-main .ewc-result,
  a.ewc-result > span:last-child,
  .perf-inline-link
) {
  transition: color 160ms ease;
}

@media (prefers-reduced-motion: reduce) {
  :where(
    .performance-stat small,
    .performance small,
    .milestone small,
    .ewc-main .ewc-result,
    a.ewc-result > span:last-child,
    .perf-inline-link
  ) {
    transition: none;
  }
}
