:root {
  color-scheme: light;
  font-family: "Segoe UI", system-ui, sans-serif;
  color: #16253c;
  background: #edf2f8;
  line-height: 1.5;
  --blue: #1958ba;
  --muted: #425777;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 4vw, 2.5rem);
  background: radial-gradient(ellipse at 50% 0, #f8fbff, transparent 72%);
}
main { width: min(100%, 28rem); }
.card {
  padding: clamp(1.25rem, 5vw, 2rem);
  background: white;
  border: 1px solid #d2deed;
  border-top: 4px solid var(--blue);
  border-radius: 1.25rem;
  box-shadow: 0 16px 40px #213b6416;
}
.brand { display: flex; align-items: center; gap: .8rem; }
.brand strong { display: block; font-size: 1.08rem; line-height: 1.3; }
.brand div span { display: block; margin-top: .15rem; font-size: .875rem; color: var(--muted); }
.mark {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  flex: none;
  border-radius: .7rem;
  background: var(--blue);
  color: white;
  font-size: 1.55rem;
}
h1 { margin: 1.5rem 0 .25rem; font-size: 2rem; letter-spacing: -.025em; line-height: 1.15; }
.intro { margin: 0 0 1.4rem; color: var(--muted); }
form, .field { display: grid; }
form { gap: 1rem; }
.field { gap: .35rem; }
label, button, summary { font-weight: 650; }
label { font-size: .9375rem; }
input, button { font: inherit; }
input:not([type="hidden"]) {
  width: 100%;
  min-height: 2.9rem;
  border: 1px solid #adbed5;
  border-radius: .6rem;
  padding: .6rem .75rem;
  background: #fff;
  color: inherit;
}
button { font-weight: 650; cursor: pointer; }
.password-field { position: relative; }
.password-field button {
  position: absolute;
  top: .14rem;
  bottom: .14rem;
  right: .19rem;
  min-width: 3.5rem;
  padding: 0 .45rem;
  border: 0;
  border-radius: .4rem;
  background: #fff;
  color: var(--blue);
  font-size: .875rem;
}
.password-field button:hover { background: #eaf2ff; }
.password-field:has(button:not([hidden])) input::-ms-reveal { display: none; }
.password-field:has(button:not([hidden])) input { padding-right: 4rem; }
.primary {
  min-height: 2.95rem;
  margin-top: .15rem;
  padding: .6rem .9rem;
  border: 1px solid transparent;
  border-radius: .65rem;
  background: var(--blue);
  color: #fff;
}
.primary:hover { background: #154a9d; }
:is(input, button, summary, .error):focus-visible { outline: 3px solid #3374ce; outline-offset: 2px; }
.error { margin: 0; padding: .65rem .8rem; border: 1px solid #e7b9b6; border-radius: .6rem; background: #fff2f1; color: #8a2621; }
details { margin-top: 1.4rem; padding-top: .65rem; border-top: 1px solid #dce5f0; font-size: .9375rem; }
summary { width: fit-content; padding: .5rem .2rem .5rem 0; color: var(--blue); cursor: pointer; }
details p { margin: .4rem 0 0; color: var(--muted); }
details p + p { margin-top: .75rem; }
footer { margin-top: 1rem; text-align: center; font-size: .875rem; color: var(--muted); }
footer p { margin: .5rem 0 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
