/* Shared win FX (see static/js/pv-fx.js). */

.pv-fx-layer {
  position: fixed;
  inset: 0;
  z-index: 120;
  pointer-events: none;
  overflow: hidden;
}

.pv-fx-coin {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, #fff6c8 0 26%, #f5c518 48%, #c98906 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.7) inset,
    0 3px 8px rgba(180, 110, 0, 0.45);
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
  will-change: left, top, transform, opacity;
}

.pv-fx-coin::after {
  content: "$";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #8a5a00;
  font-size: 11px;
  font-weight: 800;
  line-height: 22px;
  text-align: center;
}

.pv-fx-confetti {
  position: fixed;
  inset: 0;
  z-index: 79;
  pointer-events: none;
}

.pv-fx-toast {
  position: fixed;
  left: 50%;
  top: 18%;
  z-index: 90;
  transform: translate(-50%, 0);
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, #eab308 55%, var(--border, #d6d3e8));
  background: color-mix(in srgb, #fffbeb 86%, var(--surface-strong, #fff));
  color: var(--text, #1e1b4b);
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  box-shadow: 0 10px 28px rgba(58, 30, 118, 0.18);
  animation: pv-fx-toast-in 0.38s ease;
  pointer-events: none;
  white-space: nowrap;
}

.pv-fx-toast.is-out {
  animation: pv-fx-toast-out 0.4s ease forwards;
}

.pv-daily-tile.pv-fx-tile-pop {
  animation: pv-fx-tile-pop 0.55s ease;
}

@keyframes pv-fx-toast-in {
  from {
    opacity: 0;
    transform: translate(-50%, 12px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

@keyframes pv-fx-toast-out {
  to {
    opacity: 0;
    transform: translate(-50%, -10px) scale(0.96);
  }
}

@keyframes pv-fx-tile-pop {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.16);
  }
  100% {
    transform: scale(1);
  }
}

.site-shell--native-app .pv-fx-toast {
  top: calc(14% + env(safe-area-inset-top, 0px));
  font-size: 0.88rem;
  padding: 0.62rem 1rem;
}

@media (max-width: 640px) {
  .pv-fx-toast {
    white-space: normal;
    text-align: center;
    max-width: calc(100vw - 2rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .pv-fx-coin,
  .pv-fx-confetti,
  .pv-fx-toast,
  .pv-daily-tile.pv-fx-tile-pop {
    animation: none;
    transition: none;
  }
}
