/* login.css - the sign-in page at /login. Same tokens and faces as the landing page. */
:root {
  --bg: #f6f7f9; --surface: #eceff4; --ink: #101a33; --muted: #5e667a; --line: rgba(16, 26, 51, .13);
  --action: #284ea6; --action-hover: #213f86; --action-ink: #f6f7f9; --yellow: #f2c51b; --error: #b42318;
  --font-display: "Geist", system-ui, sans-serif; --font-text: "Geist", system-ui, sans-serif;
  --r: 12px; --ease: cubic-bezier(.22, 1, .36, 1);
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body { min-height: 100svh; background: var(--bg); color: var(--ink); font: 400 16px/1.6 var(--font-text); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: var(--action); }
:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; }

.signin { min-height: 100svh; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }

/* brand side: the logo, one line on what this is, DIA's parcels standing at the foot */
.signin__brand {
  position: relative; display: grid; grid-template-rows: auto 1fr auto; gap: 32px;
  padding: clamp(32px, 5vw, 72px) clamp(24px, 5vw, 80px) 0; background: var(--surface); overflow: hidden;
}
.signin__logo { justify-self: start; border-radius: 8px; }
.signin__logo img { width: 214px; height: auto; }
.signin__pitch { align-self: center; display: grid; gap: 16px; max-width: 30ch; }
.signin__kicker { margin: 0; font: 400 clamp(34px, 3.6vw, 52px)/1.04 var(--font-display); letter-spacing: -0.035em; }
.signin__line { margin: 0; font-size: 18px; line-height: 1.55; max-width: 40ch; }
.signin__stage { align-self: end; width: min(100%, 640px); margin: 0 auto -2%; }
.signin__stage img { width: 100%; animation: stage-in 1100ms var(--ease) 120ms backwards; }
@keyframes stage-in { from { opacity: 0; transform: translateY(18px) scale(.985); } }

/* form side */
.signin__panel { display: grid; place-items: center; padding: clamp(32px, 6vw, 96px) clamp(24px, 5vw, 72px); }
.signin__card { width: min(100%, 400px); display: grid; gap: 8px; }
.signin__card h1 { margin: 0; font: 400 40px/1.1 var(--font-display); letter-spacing: -0.03em; }
.signin__sub { margin: 0 0 24px; color: var(--muted); }
.signin__form { display: grid; gap: 20px; }
.signin__field { display: grid; gap: 8px; }
.signin__field label { font-size: 14px; font-weight: 500; }
.signin__field input {
  width: 100%; height: 48px; padding: 0 16px; font: 400 16px/1 var(--font-text); color: var(--ink);
  background: #fff; border: 1px solid rgba(16, 26, 51, .22); border-radius: 8px;
  transition: border-color 140ms var(--ease), box-shadow 140ms var(--ease);
}
.signin__field input:focus { outline: none; border-color: var(--action); box-shadow: 0 0 0 3px rgba(40, 78, 166, .2); }
.signin__pw { position: relative; }
.signin__pw input { padding-right: 52px; }
.signin__eye {
  position: absolute; top: 2px; right: 2px; width: 44px; height: 44px; display: grid; place-items: center;
  border: 0; border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer;
}
.signin__eye:hover { color: var(--ink); }
.signin__eye svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.signin__hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.signin__btn {
  height: 48px; margin-top: 4px; border: 0; border-radius: 8px; background: var(--action); color: var(--action-ink);
  font: 500 16px/1 var(--font-text); cursor: pointer;
  transition: background 150ms var(--ease), transform 150ms var(--ease);
}
@media (hover: hover) and (pointer: fine) { .signin__btn:hover { background: var(--action-hover); transform: translateY(-1px); } }
.signin__btn:active { transform: translateY(1px) scale(.985); transition-duration: 90ms; }
.signin__btn:disabled { opacity: .7; cursor: progress; transform: none; }
.signin__error { padding: 12px 14px; border-radius: 8px; background: #fdecea; color: var(--error); font-size: 15px; line-height: 1.5; }
.signin__error[hidden] { display: none; }
.signin__foot { margin: 24px 0 0; color: var(--muted); font-size: 15px; }
.signin__foot a { font-weight: 500; text-underline-offset: 3px; }

@media (max-width: 899px) {
  .signin { grid-template-columns: 1fr; }
  .signin__brand { grid-template-rows: auto auto; padding-bottom: 32px; }
  .signin__pitch { display: none; }
  .signin__stage { display: none; }
  .signin__logo img { width: 160px; }
  .signin__panel { place-items: start center; padding-top: 32px; }
}
@media (prefers-reduced-motion: reduce) {
  .signin__stage img { animation: none; }
  .signin__btn { transition: none; }
}
.signin__eye .eye-closed, .signin__eye.is-shown .eye-open { display: none; }
.signin__eye.is-shown .eye-closed { display: block; }

/* ---------- the brand side on flat DIA navy, its parcels rendered in 3D standing in a soft light;
   the form side on a slowly moving light. Transform and opacity only; nothing moves under reduced motion. ---------- */
.signin__brand { isolation: isolate; color: #f6f7f9; background: #0c1838; }
.signin__kicker { font-weight: 600; letter-spacing: -0.035em; }
.signin__kicker em { font-style: normal; color: #f8cd15; }
.signin__line { color: rgba(246, 247, 249, .78); }
.signin__logo:focus-visible { outline-color: #f8cd15; }
.signin__stage { position: relative; }
.signin__stage::before { content: ""; position: absolute; z-index: -1; left: 10%; right: 10%; bottom: 6%; height: 48%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(91, 140, 255, .22), rgba(91, 140, 255, 0)); }
.signin__stage img { filter: drop-shadow(0 30px 40px rgba(0, 0, 0, .35)); }
.signin__card h1 { font-weight: 600; letter-spacing: -0.035em; }
.signin__panel { position: relative; isolation: isolate; overflow: hidden; }
.signin__panel::before, .signin__panel::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; }
.signin__panel::before { width: 70vmax; height: 70vmax; right: -40vmax; top: -40vmax; background: radial-gradient(closest-side, rgba(40, 78, 166, .10), rgba(40, 78, 166, 0) 72%); animation: si-drift-a 22s cubic-bezier(.45, 0, .55, 1) infinite alternate; }
.signin__panel::after { width: 50vmax; height: 50vmax; left: -20vmax; bottom: -30vmax; background: radial-gradient(closest-side, rgba(248, 205, 21, .16), rgba(248, 205, 21, 0) 72%); animation: si-drift-b 26s cubic-bezier(.45, 0, .55, 1) infinite alternate; }
@keyframes si-drift-a { to { transform: translate3d(-8vw, 10vh, 0); } }
@keyframes si-drift-b { to { transform: translate3d(10vw, -8vh, 0); } }
.signin__card { animation: si-card .7s cubic-bezier(.22, 1, .36, 1) .1s backwards; }
@keyframes si-card { from { opacity: 0; transform: translateY(32px); } }
@media (prefers-reduced-motion: reduce) {
  .signin__panel::before, .signin__panel::after, .signin__card { animation: none; }
}
