/* Visible before the first interaction: stable outer boxes, raised edges. */
:is(.cm-responsive-site.cm-responsive-site, [data-cm-feedback-root][data-cm-feedback-root])
  :is(
    button,
    [role="button"],
    input[type="button"],
    input[type="submit"],
    input[type="reset"],
    summary,
    nav a[href],
    a.luna-button,
    a.game-navigation-control,
    a.play-mode-banner,
    a.pass-launch,
    a.luna-cabinet__action,
    a.game-announcement__cta,
    a[class*="button"],
    a[class*="btn"],
    a[data-cm-feedback="card"]
  ):not(
    :where(
      [data-square],
      [data-cell],
      [role="switch"],
      [role="checkbox"],
      [role="radio"],
      [role="option"],
      [data-cm-feedback="off"],
      [data-cm-feedback="off"] *,
      .crystal-board *,
      .crystal-grid *,
      .logical-board *,
      .knight-board *,
      .parkour-board *,
      .minefield-board *,
      .squadron-board *,
      cg-board *,
      .rated-board *,
      .battle-board *,
      .battle-rated-board *,
      .mafia-arena-board *,
      .puzzle-board *,
      .history-board *,
      .tournament-replay-board *,
      .chessboard *,
      .match-board *,
      .kp-board *,
      .sq-board *,
      .lg-board *,
      .lf-field *,
      .lf-pulse
    )
  ) {
  box-shadow:
    inset 0 1px 0 #ffffff38,
    inset 0 -2px 0 #0005,
    0 3px 0 #02070b99,
    0 6px 12px #0003;
}
/* Text links retain their readable inline shape and receive the same press response. */
:where(.cm-responsive-site, [data-cm-feedback-root]) a[href] {
  text-underline-offset: 0.2em;
}
/* Stable hit targets: only artwork/content moves, never the clickable outer box. */
.cm-feedback {
  --cm-press-ease: cubic-bezier(0.18, 0.85, 0.3, 1.25);
  transition:
    filter 160ms ease,
    box-shadow 180ms ease,
    outline-color 180ms ease;
  -webkit-tap-highlight-color: transparent;
}
.cm-feedback
  > :where(
    span,
    .play-banner-copy,
    .luna-game-artwork,
    .pass-launch__copy,
    .pass-launch__puls,
    .orbit-art,
    .item-art,
    svg
  ) {
  transition:
    translate 180ms var(--cm-press-ease),
    scale 180ms var(--cm-press-ease);
}
.cm-feedback.cm-feedback[data-cm-pressed] {
  filter: brightness(0.91) saturate(1.06);
  box-shadow:
    inset 0 3px 8px #0008,
    inset 0 1px 0 #ffffff14,
    0 1px 0 #02070b66;
}
.cm-feedback[data-cm-pressed]
  > :where(
    span,
    .play-banner-copy,
    .luna-game-artwork,
    .pass-launch__copy,
    .pass-launch__puls,
    .orbit-art,
    .item-art,
    svg
  ) {
  translate: 0 2px;
  scale: 0.975;
  transition-duration: 65ms;
}
.cm-feedback-card[data-cm-pressed]
  > :where(.play-banner-copy, .luna-game-artwork, .pass-launch__copy, .pass-launch__puls) {
  scale: 0.988;
}
@media (hover: hover) and (pointer: fine) {
  .cm-feedback:hover:not(:disabled, [aria-disabled="true"], [data-disabled]):not(
      [data-cm-pressed]
    ) {
    filter: brightness(1.07) saturate(1.04);
  }
  .cm-feedback-card:hover:not(
      :focus-visible,
      [data-cm-pressed],
      :disabled,
      [aria-disabled="true"],
      [data-disabled]
    ) {
    outline: 1px solid #f1d39673;
    outline-offset: 2px;
  }
}
/* System motion preference applies equally to the site, PWA and Pass iframe. */
@media (prefers-reduced-motion: reduce) {
  .cm-feedback,
  .cm-feedback
    > :where(
      span,
      .play-banner-copy,
      .luna-game-artwork,
      .pass-launch__copy,
      .pass-launch__puls,
      .orbit-art,
      .item-art,
      svg
    ) {
    transition: none !important;
  }
  .cm-feedback[data-cm-pressed]
    > :where(
      span,
      .play-banner-copy,
      .luna-game-artwork,
      .pass-launch__copy,
      .pass-launch__puls,
      .orbit-art,
      .item-art,
      svg
    ) {
    translate: none;
    scale: none;
  }
}

:where(.cm-responsive-site, [data-cm-feedback-root])
  :is(
    button,
    a[href],
    [role="button"],
    summary,
    input[type="submit"],
    input[type="button"],
    input[type="reset"]
  ):focus-visible {
  outline: 2px solid #f1d396;
  outline-offset: 3px;
}

:where(.cm-responsive-site, [data-cm-feedback-root]) nav a[href] {
  border-radius: 10px;
  background-color: #ffffff05;
}
