/* Secret rewards: hidden buttons, and rarities that flash in two colors. */
.lsx-secret-spot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: currentColor;
  opacity: 0.1;
  transition: opacity 0.3s, color 0.3s, transform 0.3s;
  cursor: pointer;
  z-index: 50;
}

.lsx-secret-spot:hover,
.lsx-secret-spot:focus-visible {
  opacity: 1;
  transform: scale(1.25);
}

.lsx-secret-spot.is-found {
  opacity: 0.4;
}

/* Where each one hides. */
.lsx-secret-spot--news_secret { margin-top: 2rem; }
.lsx-secret-spot--news_secret:hover { color: #e11d48; transform: rotate(-20deg) scale(1.2); }
.lsx-secret-spot--ghost_signal { position: fixed; left: 0.75rem; bottom: 0.75rem; color: #22d3ee; }
.lsx-secret-spot--lost_comet { position: fixed; right: 1rem; top: 6.5rem; color: #f97316; }
.lsx-secret-spot--keymaster { position: fixed; right: 0.75rem; bottom: 0.75rem; color: #fbbf24; }

.lsx-secret-status {
  position: fixed;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  z-index: 60;
  max-width: calc(100% - 2rem);
}

.lsx-secret-status--news_secret {
  position: static;
  transform: none;
  margin-top: 1rem;
}

@keyframes lsx-flash {
  0%, 49% { color: var(--flash-a); text-shadow: 0 0 12px var(--flash-a); }
  50%, 100% { color: var(--flash-b); text-shadow: 0 0 12px var(--flash-a), 0 0 2px var(--flash-a); }
}

/* Each secret flashes between its own two colors (matched by rarity name). */
.rarity-code_red { --flash-a: #e11d48; --flash-b: #ffffff; }
.rarity-singularity { --flash-a: #ffffff; --flash-b: #7c3aed; }
.rarity-ghost_signal { --flash-a: #22d3ee; --flash-b: #ffffff; }
.rarity-lost_comet { --flash-a: #f97316; --flash-b: #fbbf24; }
.rarity-keymaster { --flash-a: #fbbf24; --flash-b: #7c3aed; }
.rarity-cheat_code { --flash-a: #22c55e; --flash-b: #0b1026; }
.rarity-codebreaker { --flash-a: #22c55e; --flash-b: #22d3ee; }

.lsx-flash,
.lsx-flash i,
.lsx-flash .lsx-cutscene__reveal-name,
.lsx-reward-flash,
.lsx-reward-flash i,
:is(.rarity-singularity, .rarity-ghost_signal, .rarity-lost_comet, .rarity-keymaster, .rarity-cheat_code, .rarity-codebreaker) :is(i, strong),
.lsx-reward-name i,
.lsx-reward-name strong {
  animation: lsx-flash 0.8s steps(1, end) infinite;
  /* Matched-by-name rules above set the colors; inline styles win. */
  color: var(--flash-a, #e11d48) !important;
}

@media (prefers-reduced-motion: reduce) {
  .lsx-flash,
  .lsx-flash i,
  .lsx-reward-flash,
  .lsx-reward-flash i,
  .lsx-reward-name i,
  .lsx-reward-name strong {
    animation-duration: 2.4s;
  }
}
