/* Interactive auth aside — cursor-reactive constellation, spotlight, parallax.
   Presentation only; behaviour lives in
   js/custom/authentication/interactive-aside.js. Governed by
   .mdd/docs/00-design-system.md. */

.auth-aside {
    position: relative;
    overflow: hidden;
    /* Colour of the particle field / links, as an "r, g, b" triplet read by JS. */
    --auth-fx-rgb: 255, 255, 255;
}

/* Canvas sits above the brand background image but below the content. */
.auth-aside__canvas {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Soft glow that eases toward the cursor. Positioned by CSS vars from JS. */
.auth-aside__spotlight {
    position: absolute;
    z-index: 0;
    left: 0;
    top: 0;
    width: 46vmax;
    height: 46vmax;
    pointer-events: none;
    border-radius: 50%;
    opacity: 0;
    transform: translate3d(
        calc(var(--spot-x, 50%) - 50%),
        calc(var(--spot-y, 50%) - 50%),
        0
    );
    background: radial-gradient(
        circle at center,
        rgba(var(--auth-fx-rgb), 0.22),
        rgba(var(--auth-fx-rgb), 0) 62%
    );
    mix-blend-mode: soft-light;
    transition: opacity 0.5s ease;
    will-change: transform;
}

.auth-aside--active .auth-aside__spotlight {
    opacity: 1;
}

/* Keep the logo / image and text above the effect layers. */
.auth-aside__content {
    position: relative;
    z-index: 1;
}

.auth-aside__parallax {
    transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
    .auth-aside__spotlight {
        display: none;
    }

    .auth-aside__parallax {
        transition: none;
        transform: none !important;
    }
}
