/* SIGN-IN AND SIGN-UP PAGES IN DARK MODE (2026-10-18).
   These pages are standalone documents with their own <style> (see
   auth/_page_top.ejs) and nobody is signed in, so there is no saved choice:
   they follow the device's light/dark setting. Linked after each page's own
   styles; a partner's own gold for links is set after this file. Every text
   color here reads at 4.5:1 or better on the dark surfaces below. */
@media (prefers-color-scheme: dark) {
  :root { color-scheme: dark; --ink: #e7ecf5; --muted: #a6b3c8; --line: #2d3b57; --gold-dark: #e0c375; }
  html, body { background: #0d1320; color: var(--ink); }
  .card { background: #161f31; border-color: var(--line); }
  h1, h2, h3 { color: #f4f7fc; }
  p { color: inherit; }
  .login__head h1 { color: #f4f7fc; }
  .login__head p, .sub, .hint, .help, .fine, .login__help, .login__hint, .text-muted, .small, .ts-small { color: var(--muted); }
  label, .login__label { color: var(--muted); }
  input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]), select, textarea, .login__input {
    background: #1e2940; color: var(--ink); border-color: var(--line);
  }
  input::placeholder, textarea::placeholder { color: #8391a8; }
  /* Gold buttons keep dark ink (the page's --ink is light in dark mode). */
  .login__btn, .btn { color: #0d1b2e; }
  /* The quiet (Cancel) button and the grey note box (AI-connector consent, invitation, two-step) were white-on-white (2026-10-25). */
  .login__btn--quiet { color: var(--muted); }
  .login__btn--quiet:hover { background: #26324b; }
  .login__note { background: #1e2940; border-color: var(--line); color: var(--ink); }
  .login__resend-btn, .resend button { background: #2b3d63; color: #fff; }
  a:not(.btn):not(.login__btn) { color: var(--gold-dark); }
  /* Red = refused / error; orange-gold = something to check; green = OK. */
  .alert, .login__alert { background: rgba(255,131,145,.12); border-color: rgba(255,131,145,.45); color: #ffc2c9; }
  .login__alert--info, .notice { background: rgba(214,182,96,.12); border-color: rgba(214,182,96,.45); color: #ecd492; }
  .ferr { color: #ffb3bc; }
  .ok { background: rgba(78,203,150,.12); border-color: rgba(78,203,150,.4); color: #8ce0bb; }
  .login__concierge, .concierge-line { color: #8ce0bb; }
  .gets { background: #1e2940; }
  .gets li::before { color: #8ce0bb; }
  .steps, .rules, .courts-box { background: #1e2940; border-color: var(--line); color: var(--ink); }
  .steps ol, .rules { color: #d3dae6; }
  .login__help, .resend { border-top-color: var(--line); }
  .ts-key { background: #1e2940; border-color: var(--line); color: var(--ink); }
  /* The QR code stays black on white so a phone can read it. */
  .ts-qr { background: #fff; }
  /* A partner's name in place of a logo: its navy is unreadable on dark. */
  :root { --brand-ink: #f4f7fc; }
  .courts-box:hover, .courts-box:focus-visible { background: #26324b; }
  .courts-box-sub { color: var(--muted); }
  .legend, .county, .empty, .cta { background: #161f31; }
  .pill-not_efiled { background: #161f31; color: #b4c0d2; }
  .resend label, .next label { color: var(--muted); }
}
