/* PeopleOS — sign-in screens. Night indigo art panel + quiet form; marigold is the single accent. */
:root {
  --night: #131B3F;
  --indigo: #26357E;
  --blue: #2563EB;
  --marigold: #F2A93B;
  --mist: #EEF1F8;
  --ink: #1A2138;
  --muted: #5B6480;
  --line: #D9DEEA;
  --surface: #FFFFFF;
  --field: #F7F8FC;
  --display: 'Geist', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --text: 'Geist', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --ink: #E6E9F5; --muted: #9AA3BF; --line: #2C3557; --surface: #0F1530; --field: #161E40; --mist: #0C1129; }
}
:root[data-theme="dark"] { --ink: #E6E9F5; --muted: #9AA3BF; --line: #2C3557; --surface: #0F1530; --field: #161E40; --mist: #0C1129; }

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: var(--text); color: var(--ink); background: var(--surface); -webkit-font-smoothing: antialiased; }

.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 58fr) minmax(380px, 42fr); }

/* ---- art panel ---- */
.auth-art {
  position: relative; overflow: hidden; color: #fff; padding: 36px 48px 44px;
  background: radial-gradient(900px 600px at 85% 15%, #22306F 0%, transparent 60%), var(--night);
  display: flex; flex-direction: column;
}
.clock { position: relative; z-index: 2; }
.clock-day { font-size: 15px; color: #C7D2FE; letter-spacing: .01em; }
.clock-time { font-family: var(--display); font-weight: 650; letter-spacing: -.04em; font-size: clamp(44px, 5.4vw, 76px); line-height: 1; color: var(--marigold);
  font-variant-numeric: tabular-nums; display: flex; align-items: baseline; gap: 10px; margin: 6px 0 8px; }
.clock-sec { font-size: .38em; color: #F7C878; opacity: .85; width: 1.3em; }
.clock-ampm { font-size: .3em; font-weight: 500; color: #fff; opacity: .9; }
.clock-date { font-size: 15px; color: #fff; opacity: .9; }

.art { position: relative; z-index: 1; width: 100%; max-width: 640px; max-height: calc(100vh - 330px); min-height: 220px; height: auto; margin: auto; display: block; font-family: var(--text); }
.art .chip { filter: drop-shadow(0 8px 18px rgba(5, 9, 30, .35)); }

.art-copy { position: relative; z-index: 2; max-width: 34rem; }
.art-copy h2 { font-family: var(--display); font-weight: 550; letter-spacing: -.025em; font-size: clamp(24px, 2.3vw, 34px); line-height: 1.15; margin: 0 0 10px; letter-spacing: -.01em; }
.art-copy p { margin: 0; color: #C7D2FE; font-size: 15px; line-height: 1.55; max-width: 30rem; }

/* one orchestrated moment: the network draws itself on first load */
@media (prefers-reduced-motion: no-preference) {
  .art .links path { stroke-dasharray: 400; stroke-dashoffset: 400; animation: draw 1.4s cubic-bezier(.4, 0, .2, 1) .2s forwards; }
  .art .nodes g, .art .chip { opacity: 0; animation: appear .5s ease-out forwards; }
  .art .nodes g:nth-child(1) { animation-delay: .9s; } .art .nodes g:nth-child(2) { animation-delay: 1s; }
  .art .nodes g:nth-child(3) { animation-delay: 1.1s; } .art .nodes g:nth-child(4) { animation-delay: 1.2s; }
  .art .nodes g:nth-child(5) { animation-delay: 1.3s; } .art .nodes g:nth-child(6) { animation-delay: 1.4s; }
  .art .chip:nth-of-type(1) { animation-delay: 1.6s; } .art .chip:nth-of-type(2) { animation-delay: 1.75s; } .art .chip:nth-of-type(3) { animation-delay: 1.9s; }
}
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes appear { to { opacity: 1; } }

/* ---- form panel ---- */
.auth-form { display: flex; align-items: center; justify-content: center; padding: 48px 40px; background: var(--surface); }
.form-wrap { width: 100%; max-width: 380px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--display); font-size: 22px; font-weight: 500; margin-bottom: 44px; }
.brand b { font-weight: 700; color: var(--blue); }
.brand-mark { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: #fff; font-size: 20px; background: linear-gradient(140deg, var(--blue), var(--indigo)); }

.form-wrap h1 { font-family: var(--display); font-weight: 650; font-size: 32px; line-height: 1.1; margin: 0 0 8px; letter-spacing: -.03em; }
.form-wrap .lead { color: var(--muted); margin: 0 0 28px; font-size: 15px; line-height: 1.5; }

.field { margin-bottom: 18px; }
.field-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 7px; }
.field label { font-weight: 600; font-size: 14px; }
.field-head a, .link { color: var(--blue); font-size: 13.5px; text-decoration: none; font-weight: 500; }
.field-head a:hover, .link:hover { text-decoration: underline; }
.control { position: relative; }
.control > i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 18px; pointer-events: none; }
.control input {
  width: 100%; height: 48px; padding: 0 44px 0 42px; font: inherit; font-size: 15px; color: var(--ink);
  background: var(--field); border: 1px solid var(--line); border-radius: 10px; transition: border-color .15s, box-shadow .15s, background .15s;
}
.control input::placeholder { color: var(--muted); opacity: .7; }
.control input:focus { outline: none; border-color: var(--blue); background: var(--surface); box-shadow: 0 0 0 4px rgba(37, 99, 235, .15); }
.control .eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--muted); width: 36px; height: 36px; border-radius: 8px; cursor: pointer; font-size: 18px; }
.control .eye:hover { color: var(--ink); background: var(--mist); }
.control .eye:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
.otp input { padding: 0 14px; text-align: center; font-family: var(--display); font-size: 26px; letter-spacing: .35em; height: 58px; }
.hint { font-size: 13px; color: var(--muted); margin-top: 6px; }
.caps { font-size: 13px; color: #B45309; margin-top: 7px; display: flex; gap: 6px; align-items: center; }

.btn {
  width: 100%; height: 50px; margin-top: 8px; border: 0; border-radius: 10px; font: inherit; font-size: 15.5px; font-weight: 600; cursor: pointer;
  color: #fff; background: var(--blue); display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: background .15s, transform .05s;
}
.btn:hover { background: #1D4FD8; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 3px solid rgba(37, 99, 235, .45); outline-offset: 2px; }
.btn.is-busy { opacity: .8; cursor: progress; }
.btn.is-busy i { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.back { display: block; text-align: center; margin-top: 18px; }

.note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; font-size: 14px; line-height: 1.45; margin-bottom: 22px; border: 1px solid; }
.note i { font-size: 18px; margin-top: 1px; }
.note-error { background: #FEF2F2; color: #991B1B; border-color: #FECACA; }
.note-success { background: #F0FDF4; color: #166534; border-color: #BBF7D0; }
.note-warning { background: #FFFBEB; color: #92400E; border-color: #FDE68A; }
:root[data-theme="dark"] .note { background: transparent; }

.fine { margin: 36px 0 0; font-size: 12.5px; color: var(--muted); display: flex; gap: 6px; align-items: center; line-height: 1.4; }

/* ---- responsive ---- */
@media (max-width: 1100px) { .auth-art { padding: 32px 32px 36px; } }
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth-art { padding: 22px 16px 18px; min-height: 0; }
  .art, .art-copy p { display: none; }
  .art-copy h2 { font-size: 19px; margin: 14px 0 0; }
  .clock-time { font-size: 40px; }
  .auth-form { padding: 32px 16px 40px; align-items: flex-start; }
  .brand { margin-bottom: 28px; }
}
