/* Sign-in, access-denied and sign-out pages. A single card on the grid background. */

.auth {
    display: grid;
    place-items: center;
    min-height: 100dvh;
    padding: max(var(--s-4), env(safe-area-inset-top, 0px)) max(var(--s-4), env(safe-area-inset-right, 0px)) max(var(--s-4), env(safe-area-inset-bottom, 0px)) max(var(--s-4), env(safe-area-inset-left, 0px));
    background-color: var(--ink-0);
}

.auth__card {
    display: grid;
    gap: var(--s-4);
    width: 100%;
    max-width: 25rem;
    padding: var(--s-6) var(--s-5);
    background-color: var(--ink-1);
    border: 1px solid var(--rule);
    border-radius: var(--r-2);
}

.auth__brand {
    position: relative;
    display: grid;
    justify-items: center;
    gap: var(--s-3);
    text-align: center;
}

.auth__glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12rem;
    height: 12rem;
    margin: -6rem 0 0 -6rem;
    border-radius: 50%;
    background: radial-gradient(closest-side, var(--g-all), transparent);
    opacity: .18;
    pointer-events: none;
}

[data-theme="light"] .auth__glow {
    opacity: .1;
}

.auth__logo {
    position: relative;
    display: block;
    width: 10rem;
    height: 10rem;
}

.auth__wordmark {
    position: relative;
    font: 700 var(--t-lg) / 1 var(--font-display);
    letter-spacing: .04em;
    color: var(--paper-hi);
}

.auth__title {
    text-align: center;
}

/* FocusOnNavigate moves focus to the heading on load; a heading is not a control, so no ring. */
.auth__title:focus {
    outline: none;
}

.auth__tag,
.auth__text,
.auth__note {
    color: var(--paper-lo);
}

.auth__tag,
.auth__text {
    text-align: center;
}

.auth__text {
    text-align: left;
}

.auth__area,
.auth__form,
.auth__field {
    display: grid;
    gap: var(--s-4);
}

.auth__area {
    margin-top: var(--s-2);
}

.auth__field {
    gap: var(--s-1);
}

.auth__label {
    font: 500 var(--t-md) / var(--lh-md) var(--font-ui);
    color: var(--paper-hi);
}

/* 16 px text keeps iOS from zooming the page on focus; the field and buttons meet the touch size. */
.auth .input {
    min-height: var(--tap);
    font-size: 1rem;
}

.auth .btn {
    min-height: var(--tap);
}

.auth .btn {
    width: 100%;
}

.auth__google {
    gap: var(--s-3);
}

.auth__g {
    width: var(--s-4);
    height: var(--s-4);
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.5;
}

.auth__or {
    display: flex;
    align-items: center;
    gap: var(--s-3);
    font: 400 var(--t-xs) / var(--lh-xs) var(--font-mono);
    letter-spacing: .1em;
    color: var(--paper-lo);
}

.auth__or::before,
.auth__or::after {
    content: "";
    flex: 1;
    height: 1px;
    background-color: var(--rule);
}

.auth__note {
    font: 400 var(--t-sm) / var(--lh-sm) var(--font-ui);
}

.auth__msg {
    font: 400 var(--t-sm) / var(--lh-sm) var(--font-ui);
}

.auth__msg--fault {
    color: var(--fault);
}

.auth__msg--caution {
    color: var(--caution);
}
