/* Stamp: 20261002b — plate radius clips canvas + fallback with the card frame */
/**
 * Homepage illustration canvases — vaporwave Three.js inside existing card media.
 * Pair with scene-vaporwave.js. Stills stay in .scene-fallback for reduced-motion
 * and no-WebGL. Layout aspect ratios stay on .why-card-media / .tutorial-card-media.
 */

.why-card-media.scene-canvas,
.tutorial-card-media.scene-canvas {
  background: transparent;
  border-radius: var(--plate-radius, 6px);
}

.scene-canvas > .scene-fallback {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  border-radius: inherit;
}

.scene-canvas > .scene-fallback img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: inherit;
}

.scene-canvas > canvas.scene-webgl {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  pointer-events: none;
}

/* Opaque theme clear covers the still once a frame has been drawn. */
.scene-canvas--live > .scene-fallback {
  visibility: hidden;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .scene-canvas > canvas.scene-webgl {
    display: none !important;
  }
  .scene-canvas--live > .scene-fallback {
    visibility: visible;
  }
}

/* Pause toggle: same as reduced motion — stills, no live canvas */
html.motion-paused .scene-canvas > canvas.scene-webgl,
html.motion-paused .scene-canvas > canvas {
  display: none !important;
}
html.motion-paused .scene-canvas--live > .scene-fallback {
  visibility: visible;
}
