/*
 * Pages outside the dashboard (sign-in, recovery, password, registration, activation, verification, blocked access,
 * legal documents) in the researcher-signature design (/dev/components):
 * the form on the reading-start side over a faint field grid, and an illustrated panel on the other side — the
 * field's contour lines, a dotted route ending in a pin, the researchers' illustration and the welcome. On phones
 * the panel shrinks to a short band above the form. Colours come from theme tokens only; logical properties only.
 */

body { margin: 0; background: var(--dk-surface); color: var(--dk-text); }
.auth-body { min-block-size: 100vh; }

/* ---------- The split ---------- */
.auth { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); min-block-size: 100vh; }
.auth__form { position: relative; isolation: isolate; display: flex; flex-direction: column; min-inline-size: 0; padding: 24px 44px; background: var(--dk-surface); }
.auth__form::before { /* the faint dotted field grid, fading downwards */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(color-mix(in srgb, var(--dk-line-strong) 60%, transparent) 1px, transparent 1.4px);
  background-size: 22px 22px; opacity: 0.5;
  -webkit-mask: linear-gradient(to bottom, #000, transparent 55%); mask: linear-gradient(to bottom, #000, transparent 55%);
}
.auth__top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.auth__tools { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.auth__body { flex: 1; display: grid; place-items: center; padding-block: 32px; }
.auth__inner { inline-size: min(420px, 100%); animation: auth-in 0.4s var(--ui-ease, ease) both; }
@keyframes auth-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) { .auth__inner { animation: none; } }

/* ---------- Organization, language and theme ---------- */
.auth-brand { display: flex; align-items: center; gap: 12px; min-inline-size: 0; }
.auth-brand strong { display: block; font-size: 15.5px; font-weight: 700; line-height: 1.35; }
.auth-brand__name { min-inline-size: 0; }
.auth-brand__name span, .auth-brand div span { display: block; font-size: 12px; line-height: 1.5; color: var(--dk-muted); }
.auth-logo {
  inline-size: 46px; block-size: 46px; border-radius: 14px; flex: none; display: grid; place-items: center;
  background: linear-gradient(140deg, color-mix(in srgb, var(--brand) 82%, var(--on-color)), var(--brand)); color: var(--brand-ink);
  box-shadow: 0 6px 16px color-mix(in srgb, var(--brand) 30%, transparent);
}
.auth-logo .icon { inline-size: 24px; block-size: 24px; }
.auth-logo .mark { inline-size: 28px; block-size: 28px; }
.auth-logo .mark__pin { fill: color-mix(in srgb, var(--on-color) 22%, transparent); stroke: var(--on-color); stroke-width: 1.6; }
.auth-logo .mark__check { stroke: var(--on-color); }
.auth-brand:hover .mark__check { animation: draw 0.6s var(--ui-ease) both; }
.auth-logo.has-image { background: var(--dk-logo-bg); border: 1px solid var(--dk-border); box-shadow: none; overflow: hidden; }
.auth-logo.has-image img { inline-size: 100%; block-size: 100%; object-fit: contain; }

.auth-body .lang-switch { block-size: 38px; border: 1px solid var(--dk-border); border-radius: 10px; background: var(--dk-surface); overflow: hidden; }
.auth-body .lang-switch :is(button, a) { display: grid; place-items: center; padding: 0 12px; border: 0; background: transparent; color: var(--dk-text-2); font: inherit; font-size: 13px; font-weight: 600; text-decoration: none; cursor: pointer; }
.auth-body .lang-switch :is(button, a):hover { background: var(--dk-hover); }
.auth-body .lang-switch :is(button[aria-pressed="true"], a[aria-current="true"]) { background: var(--brand-soft); color: var(--brand-text); }
.auth-body .theme-switch { block-size: 38px; }
.auth-body .theme-switch button { block-size: 36px; inline-size: 34px; }

/* ---------- Heading, links and notes ---------- */
.auth-head { display: flex; align-items: flex-start; gap: 14px; margin-block-end: 24px; }
.auth-head .tile { inline-size: 46px; block-size: 46px; border-radius: 14px; }
.auth-head .tile .icon { inline-size: 22px; block-size: 22px; }
.auth-title { margin: 0 0 4px; font-size: 24px; font-weight: 800; line-height: 1.35; }
.auth-sub { margin: 0 0 22px; font-size: 13.5px; line-height: 1.7; color: var(--dk-muted); }
.auth-head .auth-sub { margin: 0; }
.auth-foot { display: flex; align-items: flex-start; gap: 8px; margin: 0; font-size: 12.5px; line-height: 1.7; color: var(--dk-muted); }
.auth-foot .icon { inline-size: 16px; block-size: 16px; flex: none; margin-block-start: 2px; color: var(--dk-faint); }
.auth-inner__foot { margin-block-start: 18px; }
.auth-link { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 0; font: inherit; font-size: 13px; font-weight: 600; color: var(--brand-text); cursor: pointer; text-decoration: none; }
.auth-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.auth-link .icon { inline-size: 16px; block-size: 16px; }
.auth-links { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-block-start: 18px; }
.auth-req { color: var(--st-danger); }
.auth-body .divider-star { margin-block: 22px 14px; }

/* ---------- Fields: the kit's one-frame control, a little taller for thumbs ---------- */
.auth-field { margin-block-end: 18px; gap: 7px; }
.auth-body .auth-field > label, .auth-body .auth-field .field__label-row label { font-size: 13px; font-weight: 600; color: var(--dk-text); }
.auth-body .field:focus-within > label, .auth-body .field:focus-within .field__label-row label { color: var(--brand-text); }
.auth-body .control { --c-h: 48px; border-radius: 12px; }
.auth-body .control > input { font-size: 15px; }
.auth-body .control > input[dir="ltr"]::placeholder { text-align: start; }
.auth-body .control:has(> input.input-validation-error) { border-color: var(--st-danger); background: var(--st-field-bad-bg); }
.auth-body .control:has(> input.input-validation-error):focus-within { box-shadow: var(--ui-ring-danger); }
.auth-body .control:has(> input.input-validation-error) .control__icon { color: var(--st-danger); }
.auth-body .control:has(> input[readonly]) { background: var(--dk-surface-2); border-style: dashed; }
.auth-body .control:has(> input[readonly]) > input { color: var(--dk-muted); }
.auth-field .field__error { font-size: 12px; color: var(--st-danger); }
.auth-field .field__error.field-validation-valid, .auth-field .field__error:empty { display: none; }
.auth-field .field__hint { font-size: 12px; color: var(--dk-muted); }
.auth-eye[aria-pressed="true"] { color: var(--brand-text); background: var(--brand-soft); }
/* The six-digit recovery code: wide, spaced digits. */
.auth-body .control--code > input { text-align: center !important; font: 700 22px var(--font-mono); letter-spacing: 0.45em; padding-inline-start: 0.45em; }
.auth-code { letter-spacing: 0.4em; text-align: center; }

/* ---------- The one primary action ---------- */
.auth-submit {
  position: relative; inline-size: 100%; min-block-size: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  margin-block-start: 6px; padding-inline: 18px; border: 0; border-radius: 12px; background: var(--brand); color: var(--brand-ink);
  font: inherit; font-size: 15px; font-weight: 700; text-decoration: none; cursor: pointer;
  box-shadow: 0 8px 20px color-mix(in srgb, var(--brand) 26%, transparent);
  transition: transform var(--ui-fast) var(--ui-ease), box-shadow var(--ui-fast) var(--ui-ease), filter var(--ui-fast);
}
.auth-submit:hover { filter: brightness(1.06); box-shadow: 0 10px 24px color-mix(in srgb, var(--brand) 32%, transparent); }
.auth-submit:not(:disabled):active { transform: translateY(1px); }
.auth-submit:disabled { opacity: 0.85; cursor: progress; }
.auth-submit .icon { inline-size: 18px; block-size: 18px; transition: transform 0.2s var(--ui-ease); }
[dir="rtl"] .auth-submit__arrow { transform: scaleX(-1); }
.auth-submit:hover .auth-submit__arrow { transform: translateX(3px); }
[dir="rtl"] .auth-submit:hover .auth-submit__arrow { transform: scaleX(-1) translateX(3px); }
.auth-submit.is-busy .auth-submit__arrow { display: none; }

/* «تذكرني» and the activation link's resend (N-21) */
.auth-remember { margin-block: -2px 18px; font-size: 13px; color: var(--dk-text-2); }
.auth-resend { margin-block: 14px 0; text-align: center; }

/* Result messages above the form */
[data-form-result] .alert { border-radius: 12px; border-inline-start: 4px solid; margin-block-end: 18px; font-size: 13px; line-height: 1.7; }
[data-form-result] .alert strong { display: block; font-size: 14px; }
[data-form-result] .alert .icon { inline-size: 18px; block-size: 18px; flex: none; margin-block-start: 3px; }
[data-form-result] .alert--danger .icon { color: var(--st-danger); }
[data-form-result] .alert--success .icon { color: var(--st-ok); }
[data-form-result] .alert--info { background: var(--st-info-bg); border-color: var(--st-info); color: var(--st-info-ink); }
[data-form-result] .alert--info .icon { color: var(--st-info); }

/* ---------- Password rules: circles that tick as the password is typed (users.js) ---------- */
.auth-rules-box { margin: -6px 0 18px; padding: 12px 14px; border: 1px dashed var(--dk-line-strong); border-radius: 12px; background: color-mix(in srgb, var(--dk-surface-muted) 55%, transparent); }
.auth-rules__title { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; font-size: 12.5px; font-weight: 700; color: var(--dk-text-2); }
.auth-rules__title .icon { inline-size: 16px; block-size: 16px; color: var(--brand-text); }
.auth-rules-box .rules { margin: 0; }
.auth-rules-box .rules li { line-height: 1.5; }

/* ---------- End states (done, expired, invalid) ---------- */
.auth-state { display: grid; justify-items: center; gap: 4px; text-align: center; padding-block: 4px 8px; }
.auth-state .ill { inline-size: min(240px, 80%); margin-block-end: 6px; }
.auth-state__badge { position: relative; inline-size: 72px; block-size: 72px; display: grid; place-items: center; margin-block-end: 10px; }
.auth-state__badge::before { content: ""; position: absolute; inset: -14px; background: var(--brand-soft); -webkit-mask: var(--orn-star) center / contain no-repeat; mask: var(--orn-star) center / contain no-repeat; animation: spin 40s linear infinite; }
.auth-state__badge > span { position: relative; inline-size: 56px; block-size: 56px; border-radius: 18px; display: grid; place-items: center; background: var(--dk-surface); color: var(--st-info); box-shadow: var(--dk-shadow), 0 0 0 1px var(--dk-border); }
.auth-state__badge .icon { inline-size: 28px; block-size: 28px; }
.auth-state.is-ok .auth-state__badge > span { color: var(--st-ok); }
.auth-state.is-ok .auth-state__badge::before { background: var(--st-ok-bg); }
.auth-state.is-bad .auth-state__badge > span { color: var(--st-danger); }
.auth-state.is-bad .auth-state__badge::before { background: var(--st-danger-bg); }
.auth-state > .icon { inline-size: 44px; block-size: 44px; color: var(--st-info); }
.auth-state.is-ok > .icon { color: var(--st-ok); }
.auth-state.is-bad > .icon { color: var(--st-danger); }
.auth-state h1 { margin: 6px 0 4px; font-size: 21px; font-weight: 800; line-height: 1.4; }
.auth-state p { margin: 0 0 18px; max-inline-size: 42ch; font-size: 14px; line-height: 1.8; color: var(--dk-muted); }
@media (prefers-reduced-motion: reduce) { .auth-state__badge::before { animation: none; } }

/* ---------- The illustrated panel (Pages/Account/_AuthArt.cshtml) ---------- */
.auth__brand {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center; gap: 28px;
  margin: 14px; margin-inline-start: 0; padding: 48px 52px; border-radius: 28px; color: var(--dk-text);
  background:
    radial-gradient(120% 80% at 100% 0%, color-mix(in srgb, var(--brand2-soft) 80%, transparent) 0%, transparent 60%),
    linear-gradient(160deg, var(--brand-soft) 0%, color-mix(in srgb, var(--brand-soft) 55%, var(--dk-surface)) 100%);
  border: 1px solid color-mix(in srgb, var(--brand) 12%, var(--dk-border));
}
.auth-art__grid { position: absolute; inset: 0; z-index: -2; opacity: 0.6; pointer-events: none;
  background-image: radial-gradient(color-mix(in srgb, var(--brand) 22%, transparent) 1px, transparent 1.5px); background-size: 24px 24px;
  -webkit-mask: radial-gradient(80% 60% at 50% 40%, #000, transparent); mask: radial-gradient(80% 60% at 50% 40%, #000, transparent); }
.auth__brand > .auth-art__topo { z-index: -1; inset-block-start: -60px; inset-inline-end: -90px; inline-size: 620px; block-size: 460px; opacity: 0.16; }
.auth__brand > .auth-art__route { z-index: -1; inset-block-end: 3%; inset-inline-start: 8%; inline-size: 58%; block-size: 100px; opacity: 0.3; }
[dir="rtl"] .auth__brand > .auth-art__route { transform: scaleX(-1); }
.auth-art__stage { position: relative; display: grid; place-items: center; }
.auth-art__stage::before { /* a soft paper disc behind the illustration */
  content: ""; position: absolute; inline-size: 78%; aspect-ratio: 1.6; border-radius: 50%; z-index: -1;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--dk-surface) 75%, transparent), transparent);
}
.auth-art__ill { inline-size: min(520px, 100%); filter: drop-shadow(0 18px 30px color-mix(in srgb, var(--brand) 14%, transparent)); }
.auth-art__ill--small { inline-size: min(360px, 82%); }
.auth-art__text { position: relative; display: grid; gap: 10px; max-inline-size: 480px; }
.auth-art__kicker { display: inline-flex; align-items: center; gap: 8px; inline-size: fit-content; padding: 5px 12px; border-radius: 999px; background: var(--dk-surface); color: var(--brand-text); font-size: 12.5px; font-weight: 700; box-shadow: var(--dk-shadow); }
.auth-art__kicker .orn--star { position: static; display: inline-block; inline-size: 12px; block-size: 12px; }
.auth__brand h2 { margin: 0; font-size: 28px; font-weight: 800; line-height: 1.4; color: var(--dk-text); }
.auth__brand p { margin: 0; font-size: 15px; line-height: 1.85; color: var(--dk-muted-2); }
.auth-art__steps { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 0; }
.auth-art__steps li { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; align-items: start; padding-block: 8px; font-size: 14.5px; line-height: 1.7; color: var(--dk-text-2); }
.auth-art__steps li + li::before { /* the dotted route between steps */
  content: ""; position: absolute; inset-inline-start: 14px; inset-block-start: -10px; block-size: 18px;
  border-inline-start: 2px dotted color-mix(in srgb, var(--brand) 45%, transparent);
}
.auth-art__n { inline-size: 30px; block-size: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--dk-surface); color: var(--brand-text); font-size: 13px; font-weight: 800; box-shadow: 0 0 0 1px color-mix(in srgb, var(--brand) 25%, transparent), var(--dk-shadow); }

/* ---------- Phones: the panel becomes a short band above the form ---------- */
@media (max-width: 900px) {
  /* The form side dissolves so its parts and the panel stack as: the organization bar, the band, the form. */
  .auth { grid-template-columns: minmax(0, 1fr); align-content: start; }
  .auth__form { display: contents; }
  .auth__top { order: 0; padding: 10px 14px; background: var(--dk-surface); border-block-end: 1px solid var(--dk-border); }
  .auth__body { order: 2; }
  .auth__brand { order: 1; margin: 10px 10px 0; padding: 18px 18px 16px; border-radius: 20px; gap: 6px; flex-direction: row; align-items: center; }
  .auth-art__stage { flex: 0 0 112px; order: 2; }
  .auth-art__stage::before { display: none; }
  .auth-art__ill, .auth-art__ill--small { inline-size: 112px; filter: none; }
  .auth-art__text { flex: 1; gap: 4px; }
  .auth-art__kicker { padding: 3px 10px; font-size: 11.5px; }
  .auth__brand h2 { font-size: 16px; line-height: 1.5; }
  .auth__brand p, .auth-art__steps { display: none; }
  .auth__brand > .auth-art__topo { inline-size: 360px; block-size: 260px; inset-block-start: -70px; }
  .auth__brand > .auth-art__route { display: none; }
  .auth__body { place-items: start center; padding: 22px 16px 28px; }
  .auth-title { font-size: 21px; }
  .auth-head .tile { inline-size: 42px; block-size: 42px; }
}
@media (max-width: 520px) {
  .auth__tools { inline-size: 100%; justify-content: space-between; }
  .auth-brand__name span:not(.org-desc) { display: none; }
  .auth-logo { inline-size: 40px; block-size: 40px; border-radius: 12px; }
}

.toasts { z-index: 400; }

/* ---------- Blocked access (approved P0-01 screen 7, option B) ---------- */
.blocked { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.blocked .auth__brand { justify-content: space-between; margin: 14px; margin-inline-end: 0; }
.blocked .auth__brand > .auth-art__route { inset-block-end: auto; inset-block-start: 30%; }
.blocked__org { display: flex; align-items: center; gap: 14px; }
.blocked__org h2 { font-size: 22px; }
.blocked__org .org-desc { display: block; margin: 2px 0 0; font-size: 13px; line-height: 1.6; color: var(--dk-muted); }
.blocked__top { justify-content: flex-end; }
.blocked__body { display: grid; gap: 14px; }
.blocked__badge { position: relative; inline-size: 72px; block-size: 72px; display: grid; place-items: center; margin-block-end: 4px; }
.blocked__badge::before { content: ""; position: absolute; inset: -14px; background: var(--st-danger-bg); -webkit-mask: var(--orn-star) center / contain no-repeat; mask: var(--orn-star) center / contain no-repeat; }
.blocked__badge > span { position: relative; inline-size: 56px; block-size: 56px; border-radius: 18px; display: grid; place-items: center; background: var(--dk-surface); color: var(--st-danger); box-shadow: var(--dk-shadow), 0 0 0 1px var(--dk-border); }
.blocked__badge .icon { inline-size: 28px; block-size: 28px; }
.blocked__body .auth-title { font-size: 24px; line-height: 1.5; margin: 0; }
.blocked__text { margin: 0; font-size: 15px; color: var(--dk-muted); line-height: 1.8; }
.blocked__ip { justify-self: start; margin: 0; }
.blocked__contact { display: flex; align-items: center; gap: 10px; margin: 10px 0 0; font-size: 13px; font-weight: 700; color: var(--dk-text-2); }
.blocked__contact::after { content: ""; flex: 1; block-size: 1px; background: var(--dk-border); }
.blocked__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.blocked__list li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--dk-border); border-radius: 14px; background: var(--dk-surface); box-shadow: var(--dk-shadow); }
.blocked__list .tile { inline-size: 38px; block-size: 38px; border-radius: 11px; }
.blocked__list .tile .icon { inline-size: 18px; block-size: 18px; }
.blocked__list small { display: block; font-size: 11.5px; color: var(--dk-muted); }
.blocked__list a, .blocked__list span:not(.tile) { font-size: 14px; font-weight: 600; color: var(--dk-text); text-decoration: none; overflow-wrap: anywhere; }
.blocked__list a:hover { color: var(--brand-text); }

/* ---------- Privacy policy and terms (Phase 0 §8): a document on a clipboard ---------- */
.legal { position: relative; isolation: isolate; min-block-size: 100vh; background: var(--dk-bg); }
.legal::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(color-mix(in srgb, var(--dk-line-strong) 55%, transparent) 1px, transparent 1.4px); background-size: 22px 22px; opacity: 0.45;
  -webkit-mask: linear-gradient(to bottom, #000, transparent 70%); mask: linear-gradient(to bottom, #000, transparent 70%); }
.legal__top { position: sticky; inset-block-start: 0; z-index: 5; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px 12px; padding: 12px 24px; background: color-mix(in srgb, var(--dk-surface) 88%, transparent); backdrop-filter: blur(8px); border-block-end: 1px solid var(--dk-border); }
.legal__wrap { max-inline-size: 800px; margin: 0 auto; padding: 40px 20px 56px; }
.legal__body { position: relative; padding: 40px 44px 44px; background: var(--dk-surface); border: 1px solid var(--dk-border); border-radius: 20px; box-shadow: var(--ui-shadow-lg); }
.legal__head { display: flex; align-items: center; gap: 14px; margin-block-end: 6px; }
.legal__body h1 { margin: 0; font-size: 26px; font-weight: 800; color: var(--dk-text); }
.legal__text { font-size: 15px; line-height: 2; color: var(--dk-text-2); }
.legal__text h3 { display: flex; align-items: center; gap: 10px; margin: 26px 0 6px; font-size: 17px; color: var(--dk-text); }
.legal__text h3::before { content: ""; inline-size: 12px; block-size: 12px; flex: none; background: var(--brand2); -webkit-mask: var(--orn-star) center / contain no-repeat; mask: var(--orn-star) center / contain no-repeat; }
.legal__text a { color: var(--brand-text); text-underline-offset: 3px; }
.legal__text ul, .legal__text ol { padding-inline-start: 22px; }
.legal__empty { display: grid; justify-items: center; gap: 6px; padding-block: 12px 4px; text-align: center; color: var(--dk-muted); }
.legal__empty .ill { inline-size: min(240px, 80%); }
@media (max-width: 700px) {
  .legal__top { padding: 10px 14px; }
  .legal__wrap { padding: 26px 12px 36px; }
  .legal__body { padding: 28px 18px 24px; border-radius: 16px; }
  .legal__body h1 { font-size: 21px; }
}

/* ---------- Registration (Phase 1): the whole record, so a wider form side ---------- */
.auth--wide { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.auth--wide .auth__body { place-items: start center; }
.auth--wide .auth__brand { position: sticky; inset-block-start: 14px; block-size: calc(100vh - 28px); padding: 40px 36px; }
.auth__inner--wide { inline-size: min(820px, 100%); }
.auth__inner--wide .person-sec { margin-block-start: var(--space-4); padding: 20px 22px 6px; border: 1px solid var(--dk-border); border-radius: 16px; background: var(--dk-surface); box-shadow: var(--dk-shadow); }
.auth__inner--wide .person-sec + .person-sec { border-block-start: 1px solid var(--dk-border); padding-block-start: 20px; }
.auth__inner--wide .person-sec__title { display: flex; align-items: center; gap: 10px; float: inline-start; inline-size: 100%; margin-block-end: 14px; font-size: 15px; }
.auth__inner--wide .person-sec__title::before { content: ""; inline-size: 13px; block-size: 13px; flex: none; background: var(--brand2); -webkit-mask: var(--orn-star) center / contain no-repeat; mask: var(--orn-star) center / contain no-repeat; }
.auth__inner--wide .person-sec__title + * { clear: both; }
.auth__inner--wide .field input, .auth__inner--wide .field select, .auth__inner--wide .field textarea { inline-size: 100%; box-sizing: border-box; min-block-size: 44px; border-radius: 10px; border-color: var(--dk-line); background-color: var(--dk-surface); color: var(--dk-text); }
.auth__inner--wide .field :is(input, select, textarea):focus { outline: none; border-color: var(--brand); box-shadow: var(--ui-ring); }
.auth__inner--wide .auth-submit { margin-block-start: 18px; }
.auth__inner--wide > [data-register-form] > .auth-foot { margin-block-start: 14px; }
@media (max-width: 900px) {
  .auth--wide { grid-template-columns: 1fr; }
  .auth--wide .auth__brand { position: relative; inset-block-start: 0; block-size: auto; padding: 18px 18px 16px; }
  .auth__inner--wide .person-sec { padding: 16px 14px 2px; }
}

/* ---------- The public verification page of a contract (2026-11-10) ---------- */
.vf-facts { display: grid; gap: 0; margin: 18px 0 0; padding: 6px 16px; border: 1px solid var(--dk-border); border-radius: 14px; background: var(--dk-surface); box-shadow: var(--dk-shadow); }
.vf-facts div { display: grid; gap: 2px; padding-block: 10px; border-block-end: 1px dashed var(--dk-line); }
.vf-facts div:last-child { border-block-end: 0; }
.vf-facts dt { font-size: 12px; color: var(--dk-muted); }
.vf-facts dd { margin: 0; font-size: 14px; font-weight: 600; }
.vf-hash { font-family: var(--font-mono); font-size: 11px !important; word-break: break-all; text-align: start; }
.vf-open { display: grid; gap: 12px; margin-block-start: 18px; padding-block-start: 16px; border-block-start: 1px dashed var(--dk-line-strong); }
.vf .auth-foot { margin-block-start: 14px; }

/* Registration: password and confirmation side by side, the rules under both. */
.auth-pass-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.auth-pass-grid + .auth-rules-box { margin-block-start: -4px; }
.auth-field__lock { padding-inline: 0 13px; }
@media (max-width: 640px) { .auth-pass-grid { grid-template-columns: minmax(0, 1fr); } }

/* The status page for a visitor (404, 403, errors) in the sign-in frame. */
.auth-status { display: grid; justify-items: center; gap: 6px; text-align: center; }
.auth-status .ill { inline-size: min(300px, 90%); margin-block-end: 8px; }
.auth-status h1 { margin: 0; font-size: 24px; font-weight: 800; }
.auth-status p { margin: 0 0 18px; max-inline-size: 40ch; font-size: 14.5px; line-height: 1.8; color: var(--dk-muted); }
.auth-status .auth-submit { inline-size: auto; padding-inline: 26px; }
@media (max-width: 900px) {
  .blocked { grid-template-columns: minmax(0, 1fr); }
  .blocked .auth__brand { margin: 10px 10px 0; }
  .blocked__top { justify-content: flex-start; }
  .blocked .auth-art__stage { display: none; }
  .blocked__org h2 { font-size: 16px; }
  .blocked__org .auth-logo { inline-size: 40px; block-size: 40px; }
}
.blocked__ipv { font-family: var(--font-mono); }
.auth--wide .auth__body:has(> .auth__inner > .auth-state:first-child) { place-items: center; }
