/*
 * New design – login pages (design "Login" L00a–L00f / LoginSkaerm).
 * Loaded only by templates/NewDesign/Login/_layout.html.twig; every rule is scoped under body.nd-login.
 * The app shell (new-design.css) is not loaded before login.
 */
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/instrument-sans-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/instrument-sans-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/instrument-sans-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/instrument-sans-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/jetbrains-mono-latin-600-normal.woff2') format('woff2'); }

.nd-login {
    --ndl-font: 'Instrument Sans', 'Helvetica Neue', Arial, sans-serif;
    --ndl-mono: 'JetBrains Mono', ui-monospace, monospace;
    --ndl-text: #10213f;
    --ndl-text-2: #3b4456;
    --ndl-text-3: #2b3445;
    --ndl-muted: #5b6475;
    --ndl-accent: #0b57a3;
    --ndl-accent-hover: #083f78;
    --ndl-bg: #eef1f6;
    --ndl-well: #e6eaf1;
    --ndl-err: #b42318;
    --ndl-ok: #1f7a44;
    --ndl-raise: 5px 5px 12px rgba(16, 33, 63, .13), -5px -5px 12px rgba(255, 255, 255, .95), inset 0 1px 0 rgba(255, 255, 255, .7);
    --ndl-inset: inset 2px 3px 7px rgba(16, 33, 63, .14), inset -2px -2px 5px rgba(255, 255, 255, .9);
    margin: 0;
    background: var(--ndl-bg);
    font-family: var(--ndl-font);
    color: var(--ndl-text);
    -webkit-font-smoothing: antialiased;
}
.nd-login *, .nd-login *::before, .nd-login *::after { box-sizing: border-box; }
.nd-login [hidden] { display: none !important; }
.nd-login a { color: var(--ndl-accent); }
.nd-login a:hover { color: var(--ndl-accent-hover); }
.nd-login .ndl-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Page frame ---------- */
.nd-login .ndl-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: radial-gradient(60% 40% at 50% 35%, #f6f8fb, rgba(246, 248, 251, 0) 70%),
                linear-gradient(180deg, #eef1f6 0%, #eef1f6 70%, #e1eafa 86%, #b8d0f5 100%);
}
.nd-login .ndl-header { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 22px 32px; }
.nd-login .ndl-logo { display: inline-flex; }
.nd-login .ndl-logo img { height: 28px; width: auto; display: block; }
.nd-login .ndl-grow { flex: 1 1 auto; }
.nd-login .ndl-header-text { font-size: 14px; color: var(--ndl-text-2); }
.nd-login .ndl-demo {
    display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px;
    border-radius: 999px; background: var(--ndl-accent); color: #fff; font-size: 14px; font-weight: 600;
    text-decoration: none; box-shadow: 0 4px 12px rgba(11, 87, 163, .25);
}
.nd-login .ndl-demo:hover { background: var(--ndl-accent-hover); color: #fff; }
.nd-login .ndl-demo-dot { width: 7px; height: 7px; border-radius: 999px; background: #fff; }
.nd-login .ndl-center { flex: 1 1 auto; display: flex; align-items: center; justify-content: center; padding: 24px 16px 64px; }
.nd-login .ndl-main { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 24px; }
.nd-login .ndl-mark {
    width: 60px; height: 60px; border-radius: 16px; background: var(--ndl-bg); display: grid; place-items: center;
    box-shadow: 4px 4px 10px rgba(16, 33, 63, .10), -4px -4px 10px rgba(255, 255, 255, .95);
}
.nd-login .ndl-mark img { width: 36px; height: auto; }
.nd-login .ndl-footer {
    display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 18px;
    padding: 0 16px 22px; font-size: 12.5px; color: var(--ndl-text-3);
}
.nd-login .ndl-lang { display: inline-flex; align-items: center; gap: 4px; }
.nd-login .ndl-lang select { border: 0; background: transparent; font-family: inherit; font-size: 12.5px; color: var(--ndl-text-3); cursor: pointer; }

/* ---------- Steps ---------- */
@keyframes ndlIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes ndlSpin { to { transform: rotate(360deg); } }
.nd-login .ndl-step { display: flex; flex-direction: column; gap: 22px; animation: ndlIn .22s ease both; }
.nd-login [data-ndl-guest] { display: flex; flex-direction: column; gap: 24px; }
.nd-login .ndl-head { display: flex; flex-direction: column; gap: 8px; }
.nd-login .ndl-head h1 { margin: 0; font-size: 30px; font-weight: 700; letter-spacing: -0.3px; line-height: 1.2; color: var(--ndl-text); }
.nd-login .ndl-head p { margin: 0; font-size: 15px; line-height: 1.45; color: var(--ndl-text-2); }

/* ---------- Forms ---------- */
.nd-login .ndl-form { display: flex; flex-direction: column; gap: 8px; margin: 0; }
.nd-login .ndl-form--gap { gap: 14px; }
.nd-login .ndl-field { display: flex; flex-direction: column; gap: 8px; }
.nd-login .ndl-label { font-size: 13.5px; font-weight: 600; padding-left: 4px; }
.nd-login .ndl-well {
    display: flex; align-items: center; gap: 10px; height: 58px; padding: 6px 6px 6px 16px;
    border-radius: 16px; background: var(--ndl-well); box-shadow: var(--ndl-inset);
    transition: box-shadow .15s;
}
.nd-login .ndl-well:focus-within { box-shadow: inset 2px 3px 7px rgba(16, 33, 63, .16), inset -2px -2px 5px rgba(255, 255, 255, .9), 0 0 0 3px rgba(11, 87, 163, .22); }
.nd-login .ndl-well[data-err="1"] { box-shadow: inset 2px 3px 7px rgba(16, 33, 63, .14), inset -2px -2px 5px rgba(255, 255, 255, .9), 0 0 0 2px rgba(180, 35, 24, .55); }
.nd-login .ndl-well-ic { flex: 0 0 18px; display: inline-flex; color: var(--ndl-muted); }
.nd-login .ndl-well input {
    flex: 1 1 auto; min-width: 0; height: 100%; border: 0; background: transparent; outline: none;
    font-family: inherit; font-size: 15.5px; color: var(--ndl-text); padding: 0;
}
.nd-login .ndl-well input::placeholder { color: #7b8496; }
/* Chrome / Edge paint a saved or suggested value light blue (:-webkit-autofill) and ignore `background`;
   an inset shadow in the well's colour keeps the field as it was before typing */
.nd-login .ndl-well input:-webkit-autofill,
.nd-login .ndl-well input:-webkit-autofill:hover,
.nd-login .ndl-well input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px var(--ndl-well) inset; box-shadow: 0 0 0 1000px var(--ndl-well) inset;
    -webkit-text-fill-color: var(--ndl-text); caret-color: var(--ndl-text); transition: background-color 9999s ease-out 0s;
}
/* separate rule: a browser that does not know :autofill would drop the whole selector list above */
.nd-login .ndl-well input:autofill { box-shadow: 0 0 0 1000px var(--ndl-well) inset; -webkit-text-fill-color: var(--ndl-text); }
.nd-login .ndl-well input.ndl-code { font-family: var(--ndl-mono); font-size: 22px; font-weight: 600; letter-spacing: 10px; }
.nd-login .ndl-eye {
    flex: 0 0 auto; width: 40px; height: 40px; border: 0; border-radius: 9px; background: transparent;
    color: #4a5366; display: grid; place-items: center; cursor: pointer;
}
.nd-login .ndl-eye[aria-pressed="true"] { color: var(--ndl-accent); }
.nd-login .ndl-err { font-size: 13px; color: var(--ndl-err); padding-left: 4px; }

/* ---------- Buttons and links ---------- */
.nd-login .ndl-primary {
    flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    height: 46px; border: 0; border-radius: 11px; background: var(--ndl-accent); color: #fff; padding: 0 18px;
    font-family: inherit; font-size: 15px; font-weight: 600; white-space: nowrap; cursor: pointer; text-decoration: none;
    box-shadow: 0 3px 8px rgba(11, 87, 163, .30), inset 0 1px 0 rgba(255, 255, 255, .18);
    transition: background-color .15s;
}
.nd-login .ndl-primary:hover { background: var(--ndl-accent-hover); color: #fff; }
.nd-login .ndl-primary--block { height: 52px; border-radius: 14px; font-size: 15.5px; margin-top: 4px; box-shadow: 0 4px 12px rgba(11, 87, 163, .28), inset 0 1px 0 rgba(255, 255, 255, .18); }
.nd-login .ndl-primary[disabled] { opacity: .7; cursor: default; }
.nd-login .ndl-raise {
    display: flex; align-items: center; justify-content: center; gap: 9px; height: 50px; border: 0; border-radius: 14px;
    background: var(--ndl-bg); font-family: inherit; font-size: 15px; font-weight: 600; color: var(--ndl-text-3);
    text-decoration: none; cursor: pointer; text-shadow: 0 1px 0 rgba(255, 255, 255, .95); box-shadow: var(--ndl-raise);
    transition: box-shadow .15s, color .15s, transform .15s;
}
.nd-login .ndl-raise:hover {
    box-shadow: 7px 7px 16px rgba(16, 33, 63, .16), -6px -6px 14px rgba(255, 255, 255, 1), inset 0 1px 0 rgba(255, 255, 255, .7);
    color: var(--ndl-text); transform: translateY(-1px);
}
.nd-login .ndl-raise:active { box-shadow: inset 3px 3px 7px rgba(16, 33, 63, .16), inset -3px -3px 7px rgba(255, 255, 255, .9); transform: none; }
.nd-login .ndl-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.nd-login .ndl-card { height: auto; justify-content: flex-start; gap: 12px; padding: 12px 14px; text-align: left; }
.nd-login .ndl-card-ic {
    width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; background: var(--ndl-bg); color: var(--ndl-accent);
    display: grid; place-items: center; box-shadow: 2px 2px 5px rgba(16, 33, 63, .12), -2px -2px 5px rgba(255, 255, 255, .95);
}
.nd-login .ndl-card-ic svg { width: 16px; height: 16px; }
.nd-login .ndl-card-text { display: flex; flex-direction: column; gap: 1px; flex: 1 1 auto; }
.nd-login .ndl-card-text strong { font-size: 14px; font-weight: 600; }
.nd-login .ndl-card-text span { font-size: 12.5px; font-weight: 400; color: #4a5366; }
.nd-login .ndl-link {
    border: 0; background: transparent; padding: 0; font-family: inherit; font-size: 13.5px; font-weight: 600;
    color: var(--ndl-accent); cursor: pointer; text-decoration: none;
}
.nd-login .ndl-link:hover { color: var(--ndl-accent-hover); text-decoration: underline; }
.nd-login .ndl-link--sm { font-size: 13px; }
.nd-login .ndl-form > .ndl-link { align-self: flex-start; padding-left: 4px; }
.nd-login .ndl-link--muted { color: var(--ndl-text-2); font-weight: 500; }
.nd-login .ndl-links { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.nd-login .ndl-primary:focus-visible, .nd-login .ndl-raise:focus-visible, .nd-login .ndl-link:focus-visible,
.nd-login .ndl-eye:focus-visible, .nd-login .ndl-demo:focus-visible { outline: 2px solid var(--ndl-accent); outline-offset: 3px; }
.nd-login .ndl-divider {
    display: flex; align-items: center; gap: 12px; font-size: 12.5px; color: var(--ndl-muted);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}
.nd-login .ndl-divider span { flex: 1 1 auto; height: 1px; background: #d3d9e3; box-shadow: 0 1px 0 #fff; }

/* ---------- Info boxes, notes, who chip, SSO wait ---------- */
.nd-login .ndl-info {
    display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 14px;
    background: #eef4fb; border: 1px solid #d5e3f3; font-size: 13px; line-height: 1.4; color: var(--ndl-text-3);
}
.nd-login .ndl-info-ic { flex: 0 0 auto; margin-top: 1px; }
.nd-login .ndl-info--list { flex-direction: column; gap: 8px; padding: 14px 16px; }
.nd-login .ndl-info--list strong { font-size: 13.5px; font-weight: 600; color: var(--ndl-text); }
.nd-login .ndl-info--list span { display: flex; gap: 8px; }
.nd-login .ndl-note { padding: 12px 14px; border-radius: 14px; font-size: 13.5px; line-height: 1.4; }
.nd-login .ndl-note--ok { background: #e9f5ee; border: 1px solid #bfe0cc; color: var(--ndl-ok); }
.nd-login .ndl-note--err { background: #fbeceb; border: 1px solid #f1c4c0; color: var(--ndl-err); }
.nd-login .ndl-who {
    display: flex; align-items: center; gap: 10px; align-self: flex-start; max-width: 100%;
    padding: 6px 8px 6px 6px; border-radius: 999px; background: var(--ndl-bg);
    box-shadow: 3px 3px 8px rgba(16, 33, 63, .10), -3px -3px 8px rgba(255, 255, 255, .95);
}
.nd-login .ndl-who-av {
    width: 28px; height: 28px; flex: 0 0 28px; border-radius: 999px; background: var(--ndl-accent); color: #fff;
    display: grid; place-items: center; font-size: 12px; font-weight: 700;
}
.nd-login .ndl-who-mail { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nd-login .ndl-wait {
    display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 16px; background: var(--ndl-well);
    box-shadow: inset 2px 3px 7px rgba(16, 33, 63, .12), inset -2px -2px 5px rgba(255, 255, 255, .9);
    font-size: 14px; color: var(--ndl-text-3);
}
.nd-login .ndl-spin {
    width: 26px; height: 26px; flex: 0 0 26px; border-radius: 999px; border: 3px solid #c9d6e8; border-top-color: var(--ndl-accent);
    animation: ndlSpin .8s linear infinite;
}
.nd-login .ndl-resend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 13.5px; color: var(--ndl-text-2); }
.nd-login .ndl-strength { display: flex; gap: 4px; padding: 0 4px; }
.nd-login .ndl-strength span { flex: 1 1 0; height: 4px; border-radius: 3px; background: #d3d9e3; transition: background-color .15s; }

/* ---------- Phone ---------- */
@media (max-width: 560px) {
    .nd-login .ndl-header { padding: 16px; }
    .nd-login .ndl-header-text { display: none; }
    .nd-login .ndl-center { padding: 16px 16px 40px; align-items: flex-start; }
    .nd-login .ndl-head h1 { font-size: 26px; }
    /* Long button labels go under the field instead of squeezing it. */
    .nd-login .ndl-well--action { flex-wrap: wrap; height: auto; min-height: 58px; padding: 6px; }
    .nd-login .ndl-well--action .ndl-well-ic { margin-left: 10px; }
    .nd-login .ndl-well--action input { height: 46px; }
    .nd-login .ndl-well--action .ndl-primary { flex: 1 1 100%; }
}

/* ---------- Teaser "new look on its way" (design "Proposal · Login with teaser banner"; temporary) ---------- */
.nd-login .ndl-teaser {
    display: flex; align-items: flex-start; gap: 10px; padding: 10px 10px 10px 14px; border-radius: 14px;
    background: linear-gradient(90deg, #e3eefa, #eef4fb); border: 1px solid #c9dcf1;
    box-shadow: 0 4px 12px rgba(11, 87, 163, .10); font-size: 13.5px; line-height: 1.45; color: var(--ndl-text);
    animation: ndlIn .22s ease both;
}
.nd-login .ndl-teaser-ic { font-size: 16px; line-height: 1.3; }
.nd-login .ndl-teaser-text { flex: 1 1 auto; min-width: 0; }
.nd-login .ndl-teaser-text strong { font-weight: 700; }
.nd-login .ndl-teaser-x {
    flex: 0 0 26px; width: 26px; height: 26px; border: 0; border-radius: 7px; background: transparent;
    color: var(--ndl-text-2); font-family: inherit; font-size: 16px; line-height: 1; cursor: pointer;
}
.nd-login .ndl-teaser-x:hover { background: rgba(11, 87, 163, .08); color: var(--ndl-text); }
.nd-login .ndl-teaser-x:focus-visible { outline: 2px solid var(--ndl-accent); outline-offset: 2px; }
