:root {
  --surface: #FFFFFF;
  --surface-muted: #F5F7FA;
  --navy: #1C3B66;
  --navy-600: #2D5A94;
  --ink: #16263F;
  --ink-muted: #4A5568;
  --line: #E5E9F0;
  --field-line: #7A879B;
  --sky: #E6EDF6;
  --gold: #D9A93F;
  --gold-soft: #F7EEDB;
  --gold-ink: #7D5D16;
  --sage: #2F6E57;
  --alert-soft: #FBEAE9;
  --alert-ink: #8F1D17;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--surface-muted);
  color: var(--ink);
  font-family: Jost, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 26px;
}
button, input { font-family: inherit; font-size: 16px; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: 0.6; }
button:focus-visible, input:focus-visible { outline: 3px solid var(--navy-600); outline-offset: 2px; }

.shell { max-width: 460px; min-height: 100vh; min-height: 100dvh; margin: 0 auto; display: flex; flex-direction: column; background: var(--surface-muted); }
.loading { padding: 48px 28px; color: var(--ink-muted); }

.eyebrow { font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold); }
.eyebrow.on-light { color: var(--gold-ink); }
h1 { margin: 0; font-family: "Cormorant Garamond", Georgia, serif; font-weight: 600; color: #FFFFFF; }

/* Sign in */
.hero { background: var(--navy); padding: calc(64px + env(safe-area-inset-top)) 28px 40px; display: flex; flex-direction: column; gap: 12px; }
.hero h1 { font-size: 24px; line-height: 30px; }
.hero .rule { width: 56px; height: 2px; background: var(--gold); }
.panel { flex-grow: 1; background: var(--surface); padding: 32px 28px; display: flex; flex-direction: column; gap: 16px; }
.panel h1 { font-size: 36px; line-height: 42px; color: var(--navy); }
.panel p { margin: 0; color: var(--ink-muted); }
.panel p strong { color: var(--ink); font-weight: 500; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; line-height: 20px; font-weight: 500; }
.field input { height: 52px; padding: 0 14px; border: 1px solid var(--field-line); border-radius: 4px; color: var(--ink); background: var(--surface); width: 100%; }
.field input.code { height: 60px; font-size: 26px; letter-spacing: 0.3em; }
.small { font-size: 14px; line-height: 21px; }

.btn { height: 56px; border: 0; border-radius: 999px; background: var(--navy); color: #FFFFFF; font-weight: 500; width: 100%; }
.btn.big { height: 60px; font-size: 19px; }
.btn.gold { background: var(--gold); color: var(--navy); font-weight: 600; }
.btn.text { height: 48px; background: transparent; color: var(--navy-600); }

/* Home */
.bar { background: var(--navy); padding: calc(20px + env(safe-area-inset-top)) 24px 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.bar h1 { font-size: 30px; line-height: 34px; }
.bar .who { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.bar button { height: 44px; padding: 0 4px; border: 0; background: transparent; color: #FFFFFF; font-size: 14px; font-weight: 500; white-space: nowrap; }
.main { flex-grow: 1; padding: 16px 16px calc(24px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 14px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.card.punch { padding: 20px; gap: 14px; }
.card h2 { margin: 0; font-size: 14px; line-height: 20px; font-weight: 500; color: var(--ink-muted); }
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.status { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 500; }
.dot { width: 12px; height: 12px; border-radius: 999px; background: var(--field-line); }
.dot.in { background: var(--sage); }
.elapsed { font-size: 19px; font-weight: 500; color: var(--navy); }
.num { font-variant-numeric: tabular-nums; }
.label { font-size: 14px; line-height: 20px; font-weight: 500; color: var(--ink-muted); }
.coding-btn { min-height: 48px; padding: 8px 14px; border: 1px solid var(--field-line); border-radius: 4px; background: var(--surface); color: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; text-align: left; font-weight: 500; }
.coding-btn .change { font-size: 14px; color: var(--navy-600); }
.coding-fixed { min-height: 48px; padding: 8px 14px; border-radius: 4px; background: var(--sky); color: var(--navy); font-weight: 500; display: flex; align-items: center; }
.loc { display: flex; align-items: center; gap: 8px; font-size: 14px; line-height: 21px; color: var(--ink-muted); }
.notice { border-radius: 10px; padding: 12px 14px; font-size: 14px; line-height: 21px; }
.notice.alert { background: var(--alert-soft); color: var(--alert-ink); }
.notice.warn { background: var(--gold-soft); color: var(--ink); }
.notice.info { background: var(--sky); color: var(--navy); }
.notice strong { font-weight: 600; }

.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.stat .k { font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.stat .v { font-size: 22px; line-height: 30px; font-weight: 500; }

.line { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 8px; border-top: 1px solid var(--line); }
.line .what { display: flex; flex-direction: column; min-width: 0; }
.line .times { font-weight: 500; }
.line .sub { font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.line .sub.wait { color: var(--gold-ink); font-weight: 500; }
.line .hrs { font-weight: 500; }
.empty { font-size: 14px; color: var(--ink-muted); padding-top: 8px; border-top: 1px solid var(--line); }
.cols { display: flex; align-items: flex-end; gap: 8px; font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.cols h2 { flex-grow: 1; }
.c1 { flex-grow: 1; min-width: 0; }
.c2 { width: 60px; text-align: right; }
.c3 { width: 84px; text-align: right; }
.line .c2, .line .c3 { font-weight: 500; }
.foot { text-align: center; font-size: 12px; line-height: 18px; color: var(--ink-muted); padding: 4px 0; }

/* Coding picker */
.scrim { position: fixed; inset: 0; background: rgba(22, 38, 63, 0.5); display: flex; flex-direction: column; justify-content: flex-end; z-index: 10; }
.sheet { background: var(--surface); border-radius: 16px 16px 0 0; padding: 24px 24px calc(28px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 12px; max-width: 460px; width: 100%; margin: 0 auto; max-height: 85vh; overflow-y: auto; }
.sheet h2 { margin: 0 0 4px; font-family: "Cormorant Garamond", Georgia, serif; font-weight: 600; font-size: 28px; line-height: 32px; color: var(--navy); }
.option { min-height: 60px; padding: 8px 16px; border-radius: 10px; background: var(--surface); border: 1px solid var(--field-line); color: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; font-weight: 500; width: 100%; }
.option.on { background: var(--sky); border: 2px solid var(--navy); }
.option .tag { font-size: 14px; color: var(--gold-ink); }

.panel.top { padding-top: calc(64px + env(safe-area-inset-top)); }

/* Buttons and forms added with transfers and corrections */
.btn.outline { background: var(--surface); color: var(--navy); border: 1px solid var(--navy); height: 48px; }
.btn.small { height: 44px; }
.link { height: 44px; padding: 0 0 0 12px; border: 0; background: transparent; color: var(--navy-600); font-weight: 500; white-space: nowrap; }
.line .end { display: flex; align-items: center; gap: 4px; }
.notice.stack { display: flex; flex-direction: column; gap: 10px; }
.lockline { padding-bottom: 2px; }

.bar.sub { align-items: flex-start; padding-top: calc(6px + env(safe-area-inset-top)); }
.bar.sub .who { gap: 0; }
.bar .back { display: flex; align-items: center; gap: 6px; padding: 0; }

.panel.form { padding: 24px; }
.field select { height: 52px; padding: 0 12px; border: 1px solid var(--field-line); border-radius: 4px; color: var(--ink); background: var(--surface); width: 100%; font-family: inherit; font-size: 16px; }
.summary { background: var(--surface-muted); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; }
.summary .sub { font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.summary .times { font-weight: 500; }
.pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

/* Account screen */
.small.flat { margin: 0; color: var(--ink-muted); }
.card .times { font-weight: 500; }
.card .sub { font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.link.left { align-self: flex-start; padding-left: 0; }
.btn.text.small { height: 44px; }
form.card { gap: 12px; }

/* Alliant logo (the reverse version, for navy backgrounds) */
.logo { display: block; height: 52px; width: auto; aspect-ratio: 3 / 1; flex: none; align-self: flex-start; }
.hero .logo { margin: 0 0 20px -3px; }
.bar.home { flex-direction: column; align-items: stretch; gap: 14px; padding-top: calc(12px + env(safe-area-inset-top)); }
.bar.home .brand { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.bar.home .logo { height: 40px; margin-left: -2px; }
