/* Reason: login composes the existing Radius tokens in a single compact panel without loading dashboard/vendor layout owners. */
* { box-sizing: border-box; }
body.rm-login-page { margin: 0; min-width: 0; min-height: 100vh; color: var(--ops-text); background: var(--ops-bg); font: 400 14px/1.6 var(--ui-font); }
.rm-login-page button, .rm-login-page input, .rm-login-page select { font: inherit; }
.rm-login-tools { display: flex; justify-content: flex-end; padding: 24px 32px 0; }
.rm-login-icon-button { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 44px; width: 44px; height: 44px; padding: 10px; color: var(--ops-muted); background: var(--ops-surface); border: 1px solid var(--ops-line); border-radius: var(--ui-control-radius); cursor: pointer; }
.rm-login-icon-button svg { width: 20px; height: 20px; }
.rm-login-icon-button:hover { color: var(--ops-brand-dark); background: var(--ops-surface-soft); }
.rm-login-main { display: grid; place-items: center; min-height: calc(100vh - 68px); min-height: calc(100dvh - 68px); padding: 24px 24px 68px; }
.rm-login-panel { width: min(100%, 480px); min-width: 0; overflow: hidden; border: 1px solid var(--ops-line); border-radius: 12px; background: var(--ops-surface); box-shadow: var(--ops-shadow); }
.rm-login-brand { display: flex; justify-content: center; align-items: center; min-height: 104px; padding: 16px; background: var(--refresh-sidebar); }
.rm-login-brand img { display: block; width: 144px; height: 72px; object-fit: contain; }
.rm-login-body { padding: 32px; }
.rm-login-body h1 { margin: 0 0 24px; color: var(--ops-text-strong); font-size: 24px; line-height: 1.4; font-weight: 700; }
.auth-login-form { display: grid; gap: 20px; margin: 0; }
.rm-login-field { display: grid; gap: 8px; min-width: 0; }
.rm-login-field label { font-weight: 500; }
.rm-login-field input, .rm-login-language select { min-width: 0; width: 100%; min-height: var(--ui-control-height); border: 1px solid var(--ops-line); border-radius: var(--ui-control-radius); color: var(--ops-text); background: var(--ops-surface); padding: 9px 12px; }
.rm-login-field input { direction: ltr; text-align: start; }
.rm-login-page :is(input,select,button,a):focus-visible { outline: 2px solid var(--ui-primary); outline-offset: 3px; }
.rm-login-field input:focus { border-color: var(--ui-primary); box-shadow: 0 0 0 3px var(--ui-focus); outline: none; }
.rm-login-password { position: relative; min-width: 0; }
.rm-login-password input { padding-left: 52px; }
.rm-login-password .rm-login-icon-button { position: absolute; left: 1px; top: 1px; height: 42px; border: 0; background: transparent; }
.rm-login-options { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.rm-login-remember { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; }
.rm-login-remember input { width: 18px; height: 18px; margin: 0; accent-color: var(--ui-primary); }
.rm-login-language select { width: 112px; padding-inline: 10px; cursor: pointer; }
.rm-login-submit { display: flex; align-items: center; justify-content: center; min-height: var(--ui-control-height); padding: 10px 16px; border: 1px solid var(--ui-primary); border-radius: var(--ui-control-radius); color: var(--ui-on-primary); background: var(--ui-primary); font-weight: 500 !important; cursor: pointer; }
.rm-login-submit:hover { background: var(--ui-primary-hover); border-color: var(--ui-primary-hover); }
.rm-login-footer { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--ops-line); text-align: center; }
.rm-login-footer a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: var(--ui-control-radius); color: var(--ops-brand-dark); text-decoration: none; font-weight: 500; }
.rm-login-footer a:hover { color: var(--ops-brand-strong); text-decoration: underline; }
/* Reason: show server feedback only when present, while preserving live announcements and native form validation. */
.rm-login-error { margin: 0; padding: 12px; border: 1px solid var(--ops-red); border-radius: var(--ui-control-radius); color: var(--ops-red); background: var(--ops-red-soft); overflow-wrap: anywhere; }
.rm-login-error[hidden], .rm-login-error.is-empty, .rm-login-eye-slash, .rm-login-sun { display: none; }
[data-login-password][aria-pressed="true"] .rm-login-eye-slash { display: block; }
html[data-ui-color-mode="dark"] .rm-login-sun { display: block; }
html[data-ui-color-mode="dark"] .rm-login-moon { display: none; }
.rm-login-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
/* Reason: retain the same form hierarchy on phones and allow normal vertical scrolling with browser zoom or a short keyboard viewport. */
@media (max-width: 575.98px) {
 .rm-login-tools { padding: 16px 16px 0; }
 .rm-login-main { min-height: calc(100vh - 60px); min-height: calc(100dvh - 60px); padding: 20px 16px 40px; }
 .rm-login-body { padding: 24px; }
 .rm-login-field input, .rm-login-language select { font-size: 16px; }
}
@media (max-height: 700px) { .rm-login-main { align-items: start; padding-bottom: 24px; } }
