/* Shared sign-in styles (FR-002, SC-002): one stylesheet for the sign-in card, the MSAL redirect legs,
   and the signed-in user menu — linked by every consuming application as
   _content/ReportFYI.AuthBridge.Components/signin.css AFTER its brand tokens, which define the
   custom properties used here. Selectors are part of the E2E contract (.rv-login__submit,
   data-testid hooks) — do not rename. */

/* ── Sign-in page — the boot-splash card language over the shared tokens. ───────────────── */
.rv-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: var(--bg-light);
}

.rv-login__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    width: 100%;
    max-width: 380px;
    padding: 40px 44px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}

.rv-login__logo { height: 40px; width: auto; margin-bottom: 6px; }

.rv-login__title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 10px;
}

.rv-login__form { display: flex; flex-direction: column; width: 100%; gap: 6px; }

.rv-login__label {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-2);
    margin-top: 8px;
}

.rv-login__error {
    font-size: 13px;
    color: var(--error);
    margin-top: 8px;
}

.rv-login__form .rv-login__submit { margin-top: 16px; width: 100%; }

/* The Microsoft door (rendered only when Entra is provisioned) + the MSAL redirect legs. */
.rv-login__divider {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-top: 14px;
    font-size: 12px;
    color: var(--text-2);
}

.rv-login__divider::before,
.rv-login__divider::after {
    content: "";
    flex: 1;
    border-top: 1px solid var(--border);
}

.rv-login__card [data-testid="login-microsoft"] { width: 100%; margin-top: 12px; }

.rv-login__card .rv-login__microsoft { width: 100%; }

.rv-login__status {
    font-size: 13.5px;
    color: var(--text-2);
    margin-top: 6px;
}

/* ── Signed-in user menu (FR-008) — the avatar circle is the trigger (a real <button>). ──── */
.rv-user { position: relative; }

.rv-avatar {
    width: 40px; height: 40px;
    border: 0; padding: 0;
    border-radius: var(--r-full);
    background: var(--primary);
    color: var(--inverse);
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 16px;
    cursor: pointer;
}
.rv-avatar:hover { background: var(--primary-hover); }

.rv-user__menu {
    position: absolute;
    top: 48px; right: 0;
    z-index: 1100;
    min-width: 220px;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-md);
    padding: 6px;
    display: flex; flex-direction: column; gap: 2px;
}
.rv-user__email {
    padding: 8px 10px;
    font-size: 12.5px; color: var(--text-2);
    border-bottom: 1px solid var(--border-light);
    word-break: break-all;
}
.rv-user__signout {
    border: none; background: transparent;
    text-align: left;
    padding: 8px 10px;
    font-size: 13px; font-weight: 600; color: var(--text);
    border-radius: var(--r-sm);
    cursor: pointer;
}
.rv-user__signout:hover { background: rgba(var(--primary-rgb), .12); color: var(--primary-dark); }
