/* Login banner motion. Every rule is scoped to .login-page .lpm so this
   file cannot restyle the form, shared layout, or animations elsewhere.
   Motion uses transform and opacity only, inside a clipped layer. */

.login-page .lpm {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
    contain: paint;
    user-select: none;
    animation: lpm-fade 1.15s ease both;
}

.login-page .lpm-grid {
    --lpm-grid: 56px;
    position: absolute;
    inset: -40%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
    background-size: var(--lpm-grid) var(--lpm-grid);
    -webkit-mask-image: radial-gradient(circle at 28% 42%, #000 0%, transparent 68%);
    mask-image: radial-gradient(circle at 28% 42%, #000 0%, transparent 68%);
    animation: lpm-grid 36s linear infinite;
}

.login-page .lpm-orb {
    position: absolute;
    border-radius: 50%;
}

.login-page .lpm-orb--a {
    width: min(54%, 300px);
    aspect-ratio: 1;
    top: -22%;
    right: -12%;
    background: radial-gradient(circle, rgba(205, 205, 252, 0.38) 0%, rgba(92, 92, 255, 0.1) 48%, transparent 72%);
    animation: lpm-drift-a 20s ease-in-out infinite alternate;
}

.login-page .lpm-orb--b {
    width: min(48%, 250px);
    aspect-ratio: 1;
    left: -20%;
    bottom: -24%;
    background: radial-gradient(circle, rgba(63, 63, 196, 0.42) 0%, rgba(15, 15, 46, 0) 70%);
    animation: lpm-drift-b 26s ease-in-out infinite alternate;
}

.login-page .lpm-seal {
    position: absolute;
    width: min(72%, 340px);
    height: auto;
    right: -16%;
    bottom: -20%;
    overflow: visible;
}

.login-page .lpm-seal-spin {
    transform-box: fill-box;
    transform-origin: center;
    animation: lpm-spin 64s linear infinite;
}

.login-page .lpm-seal-ring {
    fill: none;
    stroke: rgba(205, 205, 252, 0.28);
    stroke-width: 1;
}

.login-page .lpm-seal-ring--inner {
    stroke: rgba(255, 255, 255, 0.2);
}

.login-page .lpm-seal-dashed {
    fill: none;
    stroke: rgba(255, 255, 255, 0.38);
    stroke-width: 1;
    stroke-dasharray: 2 9;
}

.login-page .lpm-seal-core {
    fill: rgba(205, 205, 252, 0.55);
    stroke: none;
}

.login-page .lpm-sheen {
    position: absolute;
    top: -20%;
    left: 0;
    width: 38%;
    height: 140%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.14), transparent);
    transform: translate3d(-180%, 0, 0) rotate(16deg);
    animation: lpm-sheen 12s ease-in-out infinite;
}

.login-page .lpm.is-paused,
.login-page .lpm.is-paused * {
    animation-play-state: paused;
}

.login-page .lpm.is-static,
.login-page .lpm.is-static * {
    animation: none;
}

@keyframes lpm-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes lpm-grid {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(calc(var(--lpm-grid) * -1), calc(var(--lpm-grid) * -1), 0); }
}

@keyframes lpm-drift-a {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to { transform: translate3d(-7%, 9%, 0) scale(1.06); }
}

@keyframes lpm-drift-b {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to { transform: translate3d(8%, -8%, 0) scale(1.05); }
}

@keyframes lpm-spin {
    to { transform: rotate(360deg); }
}

@keyframes lpm-sheen {
    0%, 58% {
        transform: translate3d(-180%, 0, 0) rotate(16deg);
        opacity: 0;
    }
    70% { opacity: 1; }
    86%, 100% {
        transform: translate3d(420%, 0, 0) rotate(16deg);
        opacity: 0;
    }
}

@media (max-width: 899px) {
    .login-page .lpm-seal {
        width: min(46vw, 190px);
        right: -14%;
        bottom: auto;
        top: 50%;
        transform: translateY(-50%);
    }

    .login-page .lpm-orb--a {
        width: min(42%, 160px);
        top: -40%;
    }

    .login-page .lpm-orb--b {
        width: min(36%, 140px);
        bottom: -46%;
    }

    .login-page .lpm-grid {
        --lpm-grid: 40px;
    }
}

@media (max-width: 899px) and (min-width: 700px) and (orientation: landscape) {
    .login-page .lpm-seal {
        width: min(78%, 240px);
        top: auto;
        right: -18%;
        bottom: -24%;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .login-page .lpm,
    .login-page .lpm * {
        animation: none;
    }
}
