/* =========================================================================
   Auth shell — shared layout for every unauthenticated page (login, reset,
   verify, confirm). Institutional-warm: a living brand panel on the left, a
   calm, generous form card on the right. Theme-aware via Bootstrap --bs-*
   tokens so light/dark follow the app switch with no per-page overrides.
   ========================================================================= */

.auth-shell {
    min-height: 100vh;
    min-height: 100dvh;
}

/* ---- Left brand panel: the one deliberate hero surface -------------------- */
.auth-brand {
    position: relative;
    overflow: hidden;
    color: #fff;
    background:
        radial-gradient(1200px 600px at 15% 10%, rgba(255, 255, 255, .08), transparent 60%),
        linear-gradient(160deg, var(--brand-800) 0%, var(--brand-600) 100%);
}

/* Three.js canvas lives behind the brand copy. */
.auth-brand__canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    display: block;
    /* Fades the living network toward the edges so text never fights it. */
    -webkit-mask-image: radial-gradient(120% 120% at 50% 40%, #000 55%, transparent 100%);
            mask-image: radial-gradient(120% 120% at 50% 40%, #000 55%, transparent 100%);
}

.auth-brand__inner {
    position: relative;
    z-index: 1;
    max-width: 460px;
}

.auth-brand__badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .4rem .85rem;
    border-radius: 999px;
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .92);
    background: rgba(255, 255, 255, .10);
    border: 1px solid rgba(255, 255, 255, .18);
    backdrop-filter: blur(6px);
}

.auth-brand h1 {
    color: #fff;
    letter-spacing: .01em;
    line-height: 1.15;
}

.auth-brand__tagline {
    color: rgba(255, 255, 255, .74);
}

/* Small trust points at the foot of the brand panel — human, reassuring. */
.auth-brand__points {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: .65rem;
}
.auth-brand__points li {
    display: flex;
    align-items: center;
    gap: .6rem;
    color: rgba(255, 255, 255, .82);
    font-size: .95rem;
}
.auth-brand__points i {
    color: #fff;
    opacity: .9;
}

/* ---- Right form column ---------------------------------------------------- */
.auth-form-col {
    flex: 1;
    min-width: 0;
    background: var(--bs-body-bg);
}

.auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--bs-body-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: var(--ds-radius-lg);
    box-shadow: var(--ds-shadow-lg);
}

.auth-card__eyebrow {
    color: var(--bs-secondary-color);
    font-weight: 600;
}
.auth-card__title {
    color: var(--bs-heading-color, var(--bs-body-color));
    font-weight: 700;
}
.auth-card__lead {
    color: var(--bs-secondary-color);
}

.auth-card .form-label {
    font-weight: 600;
    color: var(--bs-body-color);
    margin-bottom: .35rem;
}
.auth-card .form-control {
    height: 46px;
}

/* Password field with a reveal toggle. */
.auth-pass {
    position: relative;
}
.auth-pass .form-control {
    padding-right: 3rem;
}
.auth-pass__toggle {
    position: absolute;
    top: 0;
    right: 0;
    height: 46px;
    width: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: transparent;
    color: var(--bs-secondary-color);
    cursor: pointer;
}
.auth-pass__toggle:hover {
    color: var(--bs-primary);
}

/* Submit button gets a subtle lift so the primary action reads first. */
.auth-card .btn-primary {
    height: 48px;
    font-weight: 600;
    box-shadow: 0 8px 20px -8px rgba(var(--bs-primary-rgb), .55);
}

.auth-alert-note {
    font-size: .9rem;
    color: var(--bs-secondary-color);
}

.auth-foot-link {
    color: var(--bs-primary);
    font-weight: 600;
    text-decoration: none;
}
.auth-foot-link:hover {
    text-decoration: underline;
}

/* Staggered entrance — one orchestrated load, not scattered fidgets. */
@media (prefers-reduced-motion: no-preference) {
    .auth-card,
    .auth-brand__inner > * {
        animation: authRise .6s cubic-bezier(.2, .7, .2, 1) both;
    }
    .auth-brand__inner > *:nth-child(1) { animation-delay: .05s; }
    .auth-brand__inner > *:nth-child(2) { animation-delay: .12s; }
    .auth-brand__inner > *:nth-child(3) { animation-delay: .19s; }
    .auth-brand__inner > *:nth-child(4) { animation-delay: .26s; }
    .auth-brand__inner > *:nth-child(5) { animation-delay: .33s; }
    .auth-card { animation-delay: .10s; }
}
@keyframes authRise {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 991.98px) {
    .auth-card {
        max-width: 480px;
        box-shadow: none;
        border: none;
        background: transparent;
    }
}
