/* Crowndoku result art is decoded first, then revealed as one complete image.
   The glow launches behind the frame; no partial image is ever exposed. */
.crowndoku-victory .crowndoku-result-illustration {
  position: relative;
  isolation: isolate;
  overflow: visible;
  background: transparent;
  box-shadow: none;
}

.crowndoku-victory .crowndoku-result-illustration::before {
  content: '';
  position: absolute;
  z-index: 0;
  inset: -2rem;
  pointer-events: none;
  opacity: 0;
  border-radius: 50%;
  background:
    repeating-conic-gradient(
      from -8deg,
      rgba(255, 244, 184, 0) 0deg 7deg,
      rgba(255, 230, 112, 0.9) 8deg 9.1deg,
      rgba(255, 188, 81, 0.24) 10deg 12deg,
      rgba(255, 244, 184, 0) 13deg 22deg
    ),
    radial-gradient(circle, rgba(255, 255, 238, 0.94) 0 5%, rgba(255, 218, 91, 0.54) 20%, rgba(240, 151, 255, 0.18) 43%, transparent 70%);
  filter: blur(0.35px);
  transform: scale(0.57) rotate(-8deg);
  animation: ctg-victory-art-rays 0.72s cubic-bezier(.16, .84, .24, 1) 0.03s both;
}

.crowndoku-victory .crowndoku-result-illustration img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  opacity: 0;
  transform: translateZ(0) scale(0.982);
  backface-visibility: hidden;
  will-change: opacity, transform;
}

.crowndoku-victory .crowndoku-result-illustration img.ctg-victory-image-ready {
  animation: ctg-victory-art-arrive 0.22s cubic-bezier(.16, .82, .27, 1) both;
}

@keyframes ctg-victory-art-arrive {
  0% { opacity: 0; transform: translateZ(0) scale(0.982); }
  62% { opacity: 1; transform: translateZ(0) scale(1.012); }
  100% { opacity: 1; transform: translateZ(0) scale(1); }
}

@keyframes ctg-victory-art-rays {
  0% { opacity: 0; transform: scale(0.57) rotate(-8deg); }
  34% { opacity: 0.9; }
  100% { opacity: 0.34; transform: scale(1.12) rotate(12deg); }
}

@media (prefers-reduced-motion: reduce) {
  .crowndoku-victory .crowndoku-result-illustration::before,
  .crowndoku-victory .crowndoku-result-illustration img.ctg-victory-image-ready {
    animation: none;
  }
  .crowndoku-victory .crowndoku-result-illustration::before { opacity: 0.22; transform: scale(1); }
  .crowndoku-victory .crowndoku-result-illustration img { opacity: 1; transform: none; }
}
