.auth-page {
    min-height: 100vh;
    background:
        radial-gradient(ellipse at 15% 20%, rgba(255, 220, 238, .86), transparent 42%),
        radial-gradient(ellipse at 85% 15%, rgba(215, 211, 255, .9), transparent 40%),
        linear-gradient(145deg, #fffaf7 0%, #f5f1ff 52%, #fff5fb 100%);
}

.auth-page .container {
    width: 100%;
    max-width: none;
    min-height: 100vh;
    margin: 0;
    padding: 22px 16px;
    display: grid;
    place-items: center;
}

.auth-page .topbar,
.auth-page .footer {
    display: none !important;
}

.auth-shell {
    position: relative;
    isolation: isolate;
    width: min(100%, 620px);
    margin: auto;
    padding: clamp(12px, 3vw, 28px);
}

.auth-login-shell {
    min-height: min(820px, calc(100vh - 44px));
    display: grid;
    place-items: center;
}

.auth-register-shell {
    width: min(100%, 620px);
}

.auth-content {
    position: relative;
    z-index: 2;
    width: 100%;
}

.auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 0 auto 20px;
    color: #38304f;
    text-decoration: none;
}

.auth-logo {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border: 1px solid rgba(255, 255, 255, .8);
    border-radius: 22px;
    background: linear-gradient(145deg, #ffffffd9, #f1eaffc9);
    box-shadow: 0 15px 35px rgba(104, 77, 150, .17);
    transform: perspective(300px) rotateY(-8deg) rotateX(5deg);
}

.auth-logo svg {
    width: 48px;
    height: 48px;
}

.auth-brand-name {
    font-size: clamp(21px, 5vw, 31px);
    font-weight: 800;
    letter-spacing: -.045em;
    text-shadow: 0 2px 0 #fff, 0 9px 22px rgba(92, 70, 133, .2);
}

.auth-card {
    position: relative;
    padding: clamp(22px, 5vw, 36px);
    border: 1px solid rgba(255, 255, 255, .88);
    border-radius: 28px;
    background: rgba(255, 255, 255, .82);
    box-shadow:
        0 22px 70px rgba(85, 68, 127, .15),
        inset 0 1px 0 rgba(255, 255, 255, .9);
    backdrop-filter: blur(12px);
}

.auth-card h1 {
    margin: 0;
    color: #302744;
    font-size: clamp(24px, 5vw, 32px);
    line-height: 1.15;
    text-align: center;
}

.auth-subtitle {
    margin: 9px 0 24px;
    color: #766d86;
    text-align: center;
}

.auth-form {
    display: grid;
    gap: 15px;
}

.auth-field {
    display: grid;
    gap: 7px;
    color: #4b415e;
    font-size: 14px;
    font-weight: 650;
}

.auth-field small {
    color: #8c829a;
    font-size: 12px;
    font-weight: 500;
}

.auth-field input,
.auth-field select {
    width: 100%;
    min-height: 48px;
    padding: 11px 14px;
    border: 1px solid #e3ddec;
    border-radius: 14px;
    outline: none;
    color: #302744;
    background: #fff;
    font: inherit;
    font-weight: 450;
    transition: border-color .18s ease, box-shadow .18s ease;
}

.auth-field input:focus,
.auth-field select:focus {
    border-color: #9276d9;
    box-shadow: 0 0 0 4px rgba(146, 118, 217, .14);
}

.auth-location {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 14px;
    border: 1px solid #eee8f4;
    border-radius: 18px;
}

.auth-location legend {
    padding: 0 6px;
    color: #4b415e;
    font-size: 14px;
    font-weight: 700;
}

.auth-button,
.auth-secondary-button {
    display: flex;
    width: 100%;
    min-height: 50px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 15px;
    color: #fff;
    background: linear-gradient(110deg, #7359c7, #a35fba 55%, #d47eaa);
    box-shadow: 0 10px 22px rgba(125, 83, 173, .22);
    font: inherit;
    font-weight: 750;
    text-decoration: none;
    cursor: pointer;
    transition: transform .18s ease, filter .18s ease;
}

.auth-button:hover,
.auth-secondary-button:hover {
    filter: brightness(1.04);
    transform: translateY(-1px);
}

.auth-button:disabled {
    opacity: .55;
    cursor: not-allowed;
    transform: none;
}

.auth-secondary-button {
    margin-top: 12px;
    border: 1px solid #dcd1ec;
    color: #654a9a;
    background: #fff;
    box-shadow: none;
}

.auth-consent {
    display: grid;
    grid-template-columns: 22px 1fr;
    gap: 10px;
    align-items: start;
    color: #6f667c;
    font-size: 13px;
    line-height: 1.55;
}

.auth-consent input {
    width: 19px;
    height: 19px;
    margin: 2px 0 0;
    accent-color: #805fc2;
}

.auth-page a:not(.auth-brand):not(.auth-secondary-button) {
    color: #714ab0;
    font-weight: 700;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.auth-switch {
    margin: 18px 0 0;
    color: #766d86;
    text-align: center;
}

.auth-legal {
    margin: 20px 0 0;
    color: #887f94;
    font-size: 12px;
    line-height: 1.6;
    text-align: center;
}

.auth-warning {
    padding: 12px 14px;
    border-radius: 12px;
    color: #813f44;
    background: #fff0f0;
    font-size: 13px;
}

.auth-orbit,
.auth-glow {
    position: absolute;
    z-index: -1;
    pointer-events: none;
}

.auth-orbit-one {
    top: 10%;
    left: -7%;
    width: 130px;
    height: 130px;
    border: 1px solid rgba(165, 130, 204, .35);
    border-radius: 50%;
    box-shadow: 0 0 0 16px rgba(255, 255, 255, .15);
    animation: auth-float 9s ease-in-out infinite;
}

.auth-orbit-two {
    right: -3%;
    bottom: 12%;
    width: 82px;
    height: 82px;
    border: 1px solid rgba(220, 153, 197, .45);
    border-radius: 50%;
    animation: auth-float 11s ease-in-out infinite reverse;
}

.auth-glow {
    top: 18%;
    right: 4%;
    width: 170px;
    height: 170px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 228, 187, .48), transparent 70%);
    filter: blur(4px);
    animation: auth-breathe 7s ease-in-out infinite;
}

@keyframes auth-float {
    0%, 100% { transform: translate3d(0, 0, 0) rotateX(0deg); }
    50% { transform: translate3d(0, -12px, 0) rotateX(8deg); }
}

@keyframes auth-breathe {
    0%, 100% { opacity: .55; transform: scale(.94); }
    50% { opacity: .95; transform: scale(1.06); }
}

@media (max-width: 520px) {
    .auth-page .container {
        padding: 10px;
        align-items: start;
    }

    .auth-register-shell {
        padding: 4px;
    }

    .auth-login-shell {
        min-height: calc(100vh - 20px);
        padding: 4px;
    }

    .auth-card {
        padding: 21px 17px;
        border-radius: 23px;
    }

    .auth-brand {
        margin-bottom: 14px;
    }

    .auth-logo {
        width: 54px;
        height: 54px;
        border-radius: 18px;
    }

    .auth-logo svg {
        width: 42px;
        height: 42px;
    }

    .auth-form {
        gap: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-orbit,
    .auth-glow {
        animation: none !important;
    }

    .auth-button,
    .auth-secondary-button,
    .auth-field input,
    .auth-field select {
        transition: none;
    }
}



.auth-page [hidden] {
    display: none !important;
}