@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600;700&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
    --auth-bg: #0d151d;
    --auth-ink: #eaf0f4;
    --auth-muted: rgba(234, 240, 244, .74);
    --auth-surface: rgba(255, 255, 255, .97);
    --auth-border: rgba(255, 255, 255, .14);
    --auth-accent: #0f766e;
    --auth-accent-2: #134e4a;
    --auth-shadow: 0 24px 60px rgba(0, 0, 0, .26);
}

html, body {
    min-height: 100%;
    font-family: 'IBM Plex Sans', sans-serif;
}

body {
    min-height: 100vh;
    margin: 0;
    background:
        radial-gradient(circle at top left, rgba(15, 118, 110, .28), transparent 32%),
        radial-gradient(circle at bottom right, rgba(19, 78, 74, .18), transparent 28%),
        linear-gradient(135deg, #101922 0%, #13212c 42%, #0d151d 100%);
    color: var(--auth-ink);
}

.auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(300px, 1.05fr) minmax(360px, .95fr);
}

.auth-rail {
    padding: clamp(1.5rem, 4vw, 4rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.25rem;
    position: relative;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, 0)),
        linear-gradient(180deg, rgba(15, 118, 110, .16), rgba(15, 118, 110, 0));
    border-right: 1px solid rgba(255, 255, 255, .09);
}

.auth-rail::before {
    content: '';
    position: absolute;
    inset: 1.2rem;
    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 1rem;
    pointer-events: none;
}

.auth-rail-band {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .75rem;
    max-width: 42rem;
}

.auth-band-card {
    padding: .9rem;
    border-radius: .8rem;
    border: 1px solid rgba(255, 255, 255, .09);
    background: rgba(255, 255, 255, .06);
}

.auth-band-card i {
    color: #93d6cf;
    margin-bottom: .5rem;
    font-size: 1.05rem;
}

.auth-band-card strong {
    display: block;
    margin-bottom: .2rem;
}

.auth-band-card span {
    color: var(--auth-muted);
    font-size: .82rem;
}

.auth-rail h1 {
    font-size: clamp(2rem, 3vw, 3.4rem);
    line-height: 1.02;
    margin: 0;
    max-width: 12ch;
}

.auth-copy {
    max-width: 36rem;
    color: var(--auth-muted);
    font-size: 1.02rem;
}

.auth-brand {
    align-items: center;
    gap: .85rem;
}

.brand-eyebrow {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: .72rem;
    color: rgba(234, 240, 244, .72);
}

.brand-title {
    font-size: 1.05rem;
    font-weight: 700;
}

.brand-mark {
    width: 2.7rem;
    height: 2.7rem;
    display: grid;
    place-items: center;
    border-radius: .65rem;
    background: linear-gradient(135deg, var(--auth-accent), #166d7c);
    color: #fff;
    font-weight: 700;
    box-shadow: 0 18px 26px rgba(0, 0, 0, .24);
}

.auth-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .9rem;
    max-width: 36rem;
}

.auth-metrics div {
    padding: .95rem;
    border-radius: .75rem;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .08);
}

.auth-metrics strong {
    display: block;
    font-size: 1.2rem;
    margin-bottom: .2rem;
}

.auth-metrics span,
.auth-chips span,
.auth-stage small {
    color: var(--auth-muted);
    font-size: .82rem;
}

.auth-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    max-width: 40rem;
}

.auth-chips span {
    color: rgba(234, 240, 244, .9);
    border: 1px solid rgba(255, 255, 255, .11);
    background: rgba(255, 255, 255, .05);
    border-radius: 999px;
    padding: .35rem .65rem;
}

.auth-stage {
    display: grid;
    place-items: center;
    padding: 1.2rem;
}

.auth-stage .auth-panel {
    width: min(100%, 470px);
    border: 1px solid rgba(15, 118, 110, .18);
    border-radius: 1rem;
    background: var(--auth-surface);
    color: #15212b;
    padding: clamp(1.4rem, 3vw, 2.2rem);
    box-shadow: var(--auth-shadow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(14px);
}

.auth-stage .auth-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(15, 118, 110, .06), rgba(15, 118, 110, 0) 38%);
    pointer-events: none;
}

.auth-panel h1 {
    font-size: 1.55rem;
    margin-bottom: .35rem;
    letter-spacing: -.02em;
}

.auth-panel-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.auth-panel-copy {
    color: #607381;
    margin-bottom: 1rem;
}

.auth-panel-grid {
    display: grid;
    gap: .9rem;
}

.auth-panel-grid.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.auth-panel-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.auth-micro-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .75rem;
    margin-top: 1rem;
}

.auth-micro-card {
    padding: .85rem .9rem;
    border-radius: .65rem;
    background: #f7fafb;
    border: 1px solid #dde6eb;
}

.auth-micro-card span {
    display: block;
    color: #637685;
    font-size: .8rem;
}

.auth-micro-card strong {
    display: block;
    margin-top: .15rem;
    font-size: .96rem;
}

.auth-panel .input-group,
.auth-panel .form-control,
.auth-panel .form-select {
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}

.auth-panel .form-label {
    font-size: .9rem;
    color: #4b5d6a;
}

.auth-panel .form-control,
.auth-panel .form-select {
    border-radius: .75rem;
    min-height: 2.95rem;
    border-color: #ccd7df;
}

.auth-panel .form-control-solid,
.auth-panel .form-select.form-control-solid {
    background: #f8fbfc;
}

.auth-panel .form-control:focus,
.auth-panel .form-select:focus,
.auth-panel .input-group:focus-within .form-control {
    border-color: rgba(15, 118, 110, .4);
    box-shadow: 0 0 0 .18rem rgba(15, 118, 110, .12);
}

.auth-panel .form-check {
    display: flex;
    align-items: center;
    gap: .5rem;
}

.auth-panel .form-check-input {
    margin-top: 0;
}

.auth-panel .btn-primary {
    min-height: 3rem;
    border-radius: .75rem;
    background: linear-gradient(135deg, var(--auth-accent), var(--auth-accent-2));
    border: 0;
    box-shadow: 0 16px 30px rgba(15, 118, 110, .22);
    transition: transform .16s ease, box-shadow .16s ease, filter .16s ease;
}

.auth-panel .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 20px 38px rgba(15, 118, 110, .26);
    filter: brightness(1.04);
}

.auth-panel .badge {
    border-radius: 999px;
    padding: .4rem .6rem;
    font-weight: 600;
}

.auth-panel .auth-link-row a {
    padding: .25rem 0;
    font-weight: 500;
}

.auth-panel a {
    color: #0f766e;
    text-decoration: none;
}

.auth-panel a:hover {
    text-decoration: underline;
}

.auth-link-row {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem 1rem;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.auth-separator {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin: 1rem 0;
    color: #768995;
    font-size: .82rem;
}

.auth-separator::before,
.auth-separator::after {
    content: '';
    height: 1px;
    flex: 1;
    background: #dde6eb;
}

.auth-history-list,
.auth-steps {
    display: grid;
    gap: .7rem;
}

.auth-history-item,
.auth-step-item {
    display: flex;
    gap: .75rem;
    align-items: flex-start;
    padding: .8rem .85rem;
    border: 1px solid #dde6eb;
    border-radius: .7rem;
    background: linear-gradient(180deg, #fbfdfe, #f6fafb);
}

.auth-history-item i,
.auth-step-item i {
    width: 1.9rem;
    height: 1.9rem;
    display: grid;
    place-items: center;
    border-radius: .5rem;
    background: rgba(15, 118, 110, .08);
    color: var(--auth-accent);
    flex: 0 0 auto;
}

.auth-stage .auth-panel .form-control:focus,
.auth-stage .auth-panel .form-select:focus {
    border-color: rgba(15, 118, 110, .42);
    box-shadow: 0 0 0 .18rem rgba(15, 118, 110, .12);
}

.auth-history-item strong,
.auth-step-item strong {
    display: block;
    margin-bottom: .15rem;
}

.auth-history-item span,
.auth-step-item span {
    color: #607381;
    font-size: .82rem;
}

@media (max-width: 991.98px) {
    .auth-shell {
        grid-template-columns: 1fr;
    }

    .auth-rail {
        border-right: 0;
        border-bottom: 1px solid rgba(255, 255, 255, .09);
    }

    .auth-rail h1 {
        max-width: 100%;
    }
}

@media (max-width: 767.98px) {
    .auth-rail-band,
    .auth-micro-grid,
    .auth-panel-grid.two,
    .auth-panel-grid.three {
        grid-template-columns: 1fr;
    }

    .auth-panel-head {
        flex-direction: column;
    }
}
