/* Ambient light and fine contours for the GGV login entrance. */
html:has(.auth-login),
.auth-login {
    background: #092b23;
}

.login-backdrop {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 4% 0%, #285643 0, transparent 52%),
        radial-gradient(ellipse at 100% 100%, #254c39 0, transparent 50%),
        #092b23;
}

.login-aurora {
    position: absolute;
    width: 90vmax;
    height: 90vmax;
    border-radius: 50%;
    animation: login-light-drift 28s ease-in-out infinite alternate;
}

.login-aurora-green {
    top: -50vmax;
    left: -30vmax;
    background: radial-gradient(circle, #4caa786b 0, #3a916130 32%, transparent 66%);
}

.login-aurora-gold {
    right: -42vmax;
    bottom: -56vmax;
    background: radial-gradient(circle, #c8ae6261 0, #a2915424 34%, transparent 65%);
    animation-duration: 34s;
    animation-delay: -17s;
    animation-direction: alternate-reverse;
}

.login-contours {
    position: absolute;
    inset: -12%;
    width: 124%;
    height: 124%;
    opacity: .65;
}

.login-contour-flow {
    transform-origin: center;
    animation: login-contour-drift 32s ease-in-out infinite alternate;
}

.auth-login .auth-container {
    border-color: #ffffff26;
    box-shadow: 0 30px 90px #001c2445, 0 1px 0 #ffffff1a;
}

.auth-login .auth-story {
    isolation: isolate;
    background: linear-gradient(145deg, #103f2d, #15543c 70%, #1a6247);
}

.auth-login .auth-story > * {
    position: relative;
    z-index: 1;
}

.auth-login .auth-story::before {
    content: '';
    position: absolute;
    inset: -35%;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 80% 20%, #bfa36424, transparent 45%),
        radial-gradient(ellipse at 15% 80%, #47b48130, transparent 50%);
    animation: login-panel-light 24s ease-in-out infinite alternate;
}

.auth-login .auth-story::after {
    width: 460px;
    height: 460px;
    right: -310px;
    bottom: -170px;
    z-index: -1;
    border-color: #c7b57426;
    box-shadow: 0 0 0 36px #ffffff03, 0 0 0 72px #ffffff03, 0 0 0 108px #ffffff03;
    animation: login-panel-contour 30s ease-in-out infinite alternate;
}

.auth-login .auth-footer {
    color: #c3d5ca;
}

/* Save resources while the tab is hidden. */
.auth-login[data-motion-hidden="true"] .login-aurora,
.auth-login[data-motion-hidden="true"] .login-contour-flow,
.auth-login[data-motion-hidden="true"] .auth-story::before,
.auth-login[data-motion-hidden="true"] .auth-story::after {
    animation-play-state: paused;
}

@keyframes login-light-drift {
    from { transform: translate3d(-3%, -2%, 0) scale(1); }
    to { transform: translate3d(12%, 9%, 0) scale(1.08); }
}

@keyframes login-contour-drift {
    from { transform: translate3d(-2%, 1%, 0) rotate(-5deg); }
    to { transform: translate3d(3%, -3%, 0) rotate(5deg); }
}

@keyframes login-panel-light {
    from { transform: translate3d(-5%, 0, 0); }
    to { transform: translate3d(9%, 6%, 0); }
}

@keyframes login-panel-contour {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to { transform: translate3d(-28px, -22px, 0) scale(1.1); }
}

@media (max-width: 760px) {
    .login-aurora { width: 110vmax; height: 110vmax; }
    .login-aurora-gold { display: none; }
    .login-contours { opacity: .4; }
    .auth-login .auth-story::after { width: 260px; height: 260px; right: -130px; }
}

@media (prefers-reduced-motion: reduce) {
    .auth-login .login-aurora,
    .auth-login .login-contour-flow,
    .auth-login .auth-story::before,
    .auth-login .auth-story::after { animation: none !important; }
}
