@font-face {
    font-family: 'Poppins';
    src: url('../fonts/poppins/Poppins-Regular.woff') format('woff');
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/poppins/Poppins-Bold.woff') format('woff');
    font-weight: 700;
    font-display: swap;
}

:root {
    color-scheme: light;
    --nr-blue: #244f8c;
    --nr-navy: #173b6b;
    --nr-red: #cb2804;
    --text: #192e4a;
    --muted: #627188;
    --border: #d8e0ea;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
    margin: 0;
    min-height: 100vh;
    min-height: 100svh;
    background: #f3f5f8;
    color: var(--text);
    font-family: 'Poppins', 'Segoe UI', sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
a { color: var(--nr-blue); }
button { cursor: pointer; }
svg { display: block; flex-shrink: 0; }

:focus-visible {
    outline: 3px solid #8bafe3;
    outline-offset: 4px;
}

.login-page {
    width: min(1120px, calc(100% - 80px));
    min-height: 100vh;
    min-height: 100svh;
    margin: 0 auto;
    padding: clamp(24px, 5vh, 56px) 0 24px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.login-card {
    display: grid;
    grid-template-columns: 0.94fr 1.06fr;
    min-height: 540px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #e2e7ee;
    border-radius: 24px;
    box-shadow: 0 20px 60px -28px #173b6b35;
}

.brand-panel {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    overflow: hidden;
    padding: 40px 46px 28px;
    color: #fff;
    background: var(--nr-navy);
}

.brand-panel::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: '';
    background: radial-gradient(ellipse at 100% 100%, #3067a7 0, transparent 70%);
}

.eyebrow {
    margin: 0;
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.brand-panel .eyebrow { color: #c8d9f0; }
.brand-accent { width: 36px; height: 4px; margin: 20px 0 14px; background: #f26a48; border-radius: 2px; }

.brand-logo-surface {
    position: relative;
    width: 100%;
    margin: 16px 0;
    padding: 16px 20px;
    background: #fff;
    border-radius: 16px;
}

.brand-panel-logo {
    display: block;
    width: 100%;
    height: auto;
}

.brand-art {
    position: absolute;
    z-index: -1;
    width: 350px;
    height: 350px;
    right: -81px;
    bottom: -64px;
    color: #a9c9ef;
    opacity: 0.23;
}

.brand-footer {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: auto;
    padding-top: 40px;
    color: #d0dff1;
    font-size: 11px;
    line-height: 1.7;
}

.brand-footer svg { color: #adc9ed; }
.brand-footer strong { display: block; color: #fff; font-size: 12px; font-weight: 400; }

.form-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 32px 64px;
}

.form-panel .eyebrow { color: var(--nr-blue); letter-spacing: 1.7px; }
.login-title { margin: 10px 0 10px; font-size: 29px; line-height: 1.35; letter-spacing: -0.8px; }
.login-description { margin: 0 0 31px; color: var(--muted); font-size: 12px; line-height: 1.8; }
.form-field { margin-bottom: 22px; }
.field-label { display: block; margin-bottom: 9px; font-size: 12px; font-weight: 700; }
.input-wrap { position: relative; }

.field-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    color: #7a8aa1;
    transform: translateY(-50%);
    pointer-events: none;
}

.form-input {
    display: block;
    width: 100%;
    height: 52px;
    padding: 0 16px 0 46px;
    color: var(--text);
    background: #fcfdff;
    border: 1px solid var(--border);
    border-radius: 9px;
    font-size: 13px;
    transition: border-color 150ms, box-shadow 150ms;
}

.form-input::placeholder { color: #7c899b; opacity: 1; }
.password-input { padding-right: 53px; }
.form-input:hover { border-color: #a9bbd1; }
.form-input:focus { outline: none; border-color: var(--nr-blue); box-shadow: 0 0 0 3px #244f8c15; background: #fff; }
.form-input[aria-invalid='true'] { border-color: #bd302c; }
.field-error { display: block; margin: 8px 0 0; color: #b42d27; font-size: 11px; line-height: 1.7; }
.caps-lock { margin: 8px 0 0; color: #906015; font-size: 11px; }

.password-toggle {
    position: absolute;
    right: 5px;
    top: 5px;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #6a7c93;
}

.password-toggle:hover { background: #edf2f8; color: var(--nr-blue); }
.password-toggle .eye-off, .password-toggle[aria-pressed='true'] .eye-on { display: none; }
.password-toggle[aria-pressed='true'] .eye-off { display: block; }

.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin: 2px 0 27px;
    font-size: 11px;
}

.remember-label { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; color: #53647a; }
.remember-label input { width: 16px; height: 16px; margin: 0; accent-color: var(--nr-blue); cursor: pointer; }
.password-link { text-decoration: none; text-underline-offset: 4px; }
.password-link:hover { text-decoration: underline; }

.login-submit {
    width: 100%;
    min-height: 52px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    padding: 13px 20px;
    background: var(--nr-blue);
    color: #fff;
    border: 1px solid var(--nr-blue);
    border-radius: 9px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 5px 12px #244f8c18;
    transition: background 150ms, box-shadow 150ms;
}

.login-submit:hover { background: #193f76; box-shadow: 0 5px 16px #244f8c30; }
.login-submit:disabled { cursor: wait; opacity: 0.75; }
.login-submit:disabled svg { display: none; }
.form-note { display: flex; align-items: center; justify-content: center; gap: 7px; margin: 24px 0 0; color: var(--muted); font-size: 10px; }
.status-message { margin: 0 0 22px; padding: 12px 14px; border: 1px solid #b7daca; border-radius: 8px; background: #f0faf5; color: #276349; font-size: 12px; line-height: 1.7; }
.page-footer { display: flex; justify-content: space-between; gap: 16px; padding-top: 25px; color: #718096; font-size: 10px; }
.page-footer p { margin: 0; }

@media (min-width: 1500px) {
    .login-page { width: min(1200px, calc(100% - 96px)); }
    .login-card { min-height: 560px; }
    .brand-panel { padding: 44px 54px 32px; }
    .form-panel { padding: 40px 80px; }
}

@media (max-width: 1000px) {
    .login-page { width: calc(100% - 48px); padding-top: 28px; }
    .brand-panel { padding: 32px 30px 24px; }
    .form-panel { padding: 32px 36px; }
    .login-title { font-size: 27px; }
}

@media (max-width: 760px) {
    .login-page { width: min(500px, calc(100% - 40px)); padding: 20px 0; }
    .brand-panel { align-items: center; padding: 20px 30px 0; background: #fff; }
    .brand-panel::before, .brand-panel .eyebrow, .brand-accent, .brand-art, .brand-footer { display: none; }
    .brand-logo-surface { max-width: 220px; margin: 0; padding: 0; }
    .login-card { grid-template-columns: 1fr; min-height: 0; border-radius: 18px; border-top: 4px solid var(--nr-blue); }
    .form-panel { padding: 28px 30px; }
    .login-title { font-size: 27px; }
    .form-input { font-size: 16px; }
    .page-footer { justify-content: center; flex-wrap: wrap; gap: 6px; text-align: center; padding-top: 22px; }
    .page-footer p { width: 100%; }
}

@media (max-width: 380px) {
    .login-page { width: calc(100% - 28px); }
    .form-panel { padding: 24px 22px; }
    .login-title { font-size: 24px; }
    .form-options { flex-direction: column; align-items: flex-start; gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; }
}
