/* Standalone stylesheet for the shared login page. It deliberately pulls in none of the theme
   bundles: the page serves every tenant and has no tenant switch, so it owes nothing to the
   LeptonXLite account layout and is cheaper to keep coherent on its own. */

:root {
    --auth-bg: #08080a;
    --auth-surface: rgba(255, 255, 255, 0.045);
    --auth-border: rgba(212, 175, 55, 0.22);
    --auth-text: #f4f4f6;
    --auth-muted: #9b9ba4;
    --auth-gold: #d4af37;
    --auth-gold-soft: #f0d98a;
    --auth-danger: #ff7a7a;
    --auth-danger-bg: rgba(255, 92, 92, 0.12);
    --auth-info-bg: rgba(212, 175, 55, 0.12);
    --auth-radius: 16px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    min-height: 100%;
}

body {
    background: var(--auth-bg);
    color: var(--auth-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Kufi Arabic", "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Two soft gold pools behind the card, so the transparent gold logo has something to sit on
   without turning the page into a gradient. */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background:
        radial-gradient(60rem 40rem at 50% -10%, rgba(212, 175, 55, 0.13), transparent 70%),
        radial-gradient(40rem 30rem at 85% 110%, rgba(212, 175, 55, 0.07), transparent 70%);
    pointer-events: none;
}

.auth {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 32px 16px;
    gap: 20px;
}

.auth__card {
    width: 100%;
    max-width: 420px;
    padding: 36px 32px 32px;
    background: var(--auth-surface);
    border: 1px solid var(--auth-border);
    border-radius: var(--auth-radius);
    backdrop-filter: blur(14px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.auth__logo {
    display: block;
    width: 108px;
    height: auto;
    margin: 0 auto 20px;
}

.auth__title {
    margin: 0 0 6px;
    font-size: 22px;
    font-weight: 600;
    text-align: center;
    letter-spacing: -0.01em;
}

.auth__subtitle {
    margin: 0 0 24px;
    font-size: 14px;
    color: var(--auth-muted);
    text-align: center;
}

.auth__alert {
    margin-bottom: 18px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 14px;
}

.auth__alert--danger {
    background: var(--auth-danger-bg);
    border: 1px solid rgba(255, 92, 92, 0.3);
    color: var(--auth-danger);
}

.auth__alert--info {
    background: var(--auth-info-bg);
    border: 1px solid var(--auth-border);
    color: var(--auth-gold-soft);
}

/* asp-validation-summary always renders the wrapper; only give it alert styling once it has
   something in it, otherwise an empty coloured bar sits above the form. */
.auth__validation:empty,
.auth__validation.validation-summary-valid {
    display: none;
}

.auth__validation ul {
    margin: 0;
    padding-inline-start: 18px;
}

.auth__field {
    margin-bottom: 16px;
}

.auth__field label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--auth-muted);
}

.auth__field input {
    width: 100%;
    padding: 11px 13px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--auth-text);
    font: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth__field input:focus {
    outline: none;
    border-color: var(--auth-gold);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.16);
}

.auth__field input::placeholder { color: #6a6a73; }

.auth__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 4px 0 22px;
    font-size: 13px;
}

.auth__remember {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--auth-muted);
    cursor: pointer;
}

.auth__remember input { accent-color: var(--auth-gold); }

.auth__link {
    color: var(--auth-gold-soft);
    text-decoration: none;
}

.auth__link:hover { text-decoration: underline; }

.auth__submit {
    width: 100%;
    padding: 12px 16px;
    background: linear-gradient(135deg, #b8860b, var(--auth-gold) 45%, var(--auth-gold-soft));
    border: none;
    border-radius: 10px;
    color: #1a1405;
    font: inherit;
    font-weight: 650;
    cursor: pointer;
    transition: filter 0.15s ease, transform 0.05s ease;
}

.auth__submit:hover { filter: brightness(1.07); }
.auth__submit:active { transform: translateY(1px); }
.auth__submit:focus-visible { outline: 2px solid var(--auth-gold-soft); outline-offset: 3px; }

/* Only rendered when one identifier proved valid in several tenants at once. */
.auth__choice {
    margin-bottom: 20px;
    padding: 14px;
    border: 1px solid var(--auth-border);
    border-radius: 12px;
    background: rgba(212, 175, 55, 0.05);
}

.auth__choice-hint {
    margin: 0 0 10px;
    font-size: 13px;
    color: var(--auth-gold-soft);
}

.auth__choice-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 6px;
    border-radius: 8px;
    cursor: pointer;
}

.auth__choice-item:hover { background: rgba(255, 255, 255, 0.04); }
.auth__choice-item input { accent-color: var(--auth-gold); }

.auth__divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 24px 0 16px;
    font-size: 12px;
    color: var(--auth-muted);
}

.auth__divider::before,
.auth__divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.auth__providers {
    display: grid;
    gap: 8px;
}

.auth__provider {
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    color: var(--auth-text);
    font: inherit;
    cursor: pointer;
}

.auth__provider:hover { background: rgba(255, 255, 255, 0.09); }

.auth__footer {
    margin: 0;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #55555e;
}

@media (max-width: 420px) {
    .auth__card { padding: 28px 20px 24px; }
    .auth__logo { width: 92px; }
}

@media (prefers-reduced-motion: reduce) {
    .auth__submit,
    .auth__field input { transition: none; }
}
