/* --- Image Fallback (when image.file is null, show image.prompt) --- */
.fe-image-fallback {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px 18px;
  min-height: 180px;
  background: linear-gradient(135deg, rgba(255, 220, 180, 0.45), rgba(236, 220, 185, 0.65));
  border: 2px dashed rgba(255, 138, 76, 0.4);
  border-radius: var(--radius-card);
  box-shadow: inset 0 2px 6px rgba(58, 42, 26, 0.06);
  text-align: center;
}
.fe-image-fallback__icon {
  font-size: 36px;
  opacity: 0.7;
}
.fe-image-fallback__label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--fg-soft);
  background: rgba(255, 255, 255, 0.55);
  padding: 3px 10px;
  border-radius: 20px;
}
.fe-image-fallback__prompt {
  font-size: 14px;
  line-height: 1.5;
  color: var(--fg);
  font-style: italic;
  max-width: 92%;
}

.confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

.confetti-particle {
  position: absolute;
  top: -20px;
  width: 8px;
  height: 12px;
  border-radius: 2px;
  opacity: 0.9;
  animation-name: confetti-fall;
  animation-timing-function: cubic-bezier(0.25, 0.6, 0.4, 1);
  animation-fill-mode: forwards;
}

@keyframes confetti-fall {
  0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(105vh) rotate(var(--rotate-end)); opacity: 0.8; }
}

@media (prefers-reduced-motion: reduce) {
  .confetti-container { display: none; }
  .exam-marker__avatar { animation: none; }
  .exam-hero__bar span,
  .exam-runner__progress span,
  .exam-stage,
  .home-exam-honor { transition: none; }
}
