/* Three rainbow backgrounds shared by the stage and design previews. */
.rainbow-scene {
  overflow: hidden;
  isolation: isolate;
  --spectrum: #d984a9, #d69c7c, #e1cb82, #8cbd8a, #78bdbd, #7c98cc, #a188c0, #d984a9;
}

.rainbow-scene::before, .rainbow-scene::after, .rainbow-field {
  position: absolute;
  inset: 0;
}

.rainbow-scene::before, .rainbow-scene::after { content: ""; }
.rainbow-field { z-index: 1; pointer-events: none; }
.rainbow-field i { display: block; position: absolute; }

/* 08 糖波泡泡 */
.rainbow-scene[data-rainbow-theme="bubbles"] { background: radial-gradient(ellipse at 42% 39%, #beaeca, #9bacbf 65%, #839dad); }
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i {
  left: var(--x); top: var(--y); width: var(--size); aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 29%, #ebdced9f, #baaac22a 38%, transparent 66%), conic-gradient(from 34deg, var(--spectrum));
  box-shadow: inset 0 0 15px 6px #dccbe073, inset -8px -8px 16px #6b628750, 4px 8px 20px #5446672a;
  opacity: .7;
  animation: bubble-float var(--time) var(--offset) ease-in-out infinite alternate;
}
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i:nth-child(1) { --x: -12%; --y: 7%; --size: 49%; --time: 5s; --offset: -2s; }
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i:nth-child(2) { --x: 67%; --y: -10%; --size: 43%; --time: 6.1s; --offset: -1s; }
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i:nth-child(3) { --x: 68%; --y: 53%; --size: 47%; --time: 7.3s; --offset: -3s; }
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i:nth-child(4) { --x: 11%; --y: 63%; --size: 23%; --time: 6s; --offset: -4s; }
.rainbow-scene[data-rainbow-theme="bubbles"] .rainbow-field i:nth-child(5) { --x: 43%; --y: -3%; --size: 18%; --time: 5.9s; --offset: 0s; }
@keyframes bubble-float {
  from { transform: translate3d(-5%, 17%, 0) rotate(-12deg); }
  to { transform: translate3d(13%, -18%, 0) rotate(19deg); }
}
