:root {
  --navy: #16213B;
  --navy-deep: #0E1629;
  --ink: #1D2433;
  --slate: #4A5366;
  --muted: #6B7385;
  --line: #E1DCCF;
  --paper: #F8F6F1;
  --card: #FFFFFF;
  --accent: #8A7748;      /* overridden per brand */
  --accent-soft: #F1EBDC;
  --good: #1E6B3A;
  --bad: #B3261E;
  --radius: 14px;
  color-scheme: light;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, 'Segoe UI', Roboto, sans-serif;
  background: var(--paper); color: var(--ink); line-height: 1.5; font-size: 16px;
  -webkit-font-smoothing: antialiased;
  padding-bottom: env(safe-area-inset-bottom);
}
h1, h2, h3 { font-family: 'Fraunces', Georgia, serif; color: var(--navy); font-weight: 600; letter-spacing: -0.01em; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--navy); }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; border-radius: 6px; }

.shell { max-width: 520px; margin: 0 auto; padding: 0 16px 32px; }
.topbar {
  position: sticky; top: 0; z-index: 5; background: rgba(248, 246, 241, 0.94);
  backdrop-filter: saturate(1.4) blur(8px); -webkit-backdrop-filter: saturate(1.4) blur(8px);
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px; border-bottom: 1px solid var(--line);
}
.topbar-inner { max-width: 520px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.topbar img { height: 36px; width: auto; }
.linkbtn { background: none; border: none; color: var(--slate); font-size: 14px; padding: 8px 4px; cursor: pointer; text-decoration: underline; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 18px; margin-top: 16px; }
.eyebrow { font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }

.btn {
  display: block; width: 100%; border: none; cursor: pointer; text-align: center; text-decoration: none;
  background: var(--navy); color: #fff; font-weight: 600; font-size: 16px; padding: 15px 18px; border-radius: 12px;
}
.btn:active { background: var(--navy-deep); }
.btn[disabled] { opacity: .6; }
.btn.secondary { background: var(--card); color: var(--navy); border: 1.5px solid var(--navy); }
.btn + .btn { margin-top: 10px; }

/* login */
.login { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding: 32px 0; }
.login-logo { width: 240px; max-width: 75%; margin: 0 auto 28px; }
.login h1 { font-size: 28px; text-align: center; line-height: 1.15; }
.login p.sub { text-align: center; color: var(--slate); margin: 10px auto 24px; max-width: 34ch; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 14px; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; font-size: 17px; padding: 13px 14px; border-radius: 12px; border: 1px solid #CFC8B8; background: #fff;
}
.field input.code { text-transform: uppercase; letter-spacing: 0.12em; font-weight: 600; }
.hint { font-size: 13px; color: var(--muted); margin-top: 6px; }
.msg { font-size: 15px; margin-top: 12px; min-height: 1px; }
.msg.err { color: var(--bad); font-weight: 600; }
.msg.ok { color: var(--good); font-weight: 600; }
.help-line { text-align: center; font-size: 14px; color: var(--slate); margin-top: 22px; }

/* home */
.hello { margin-top: 22px; }
.hello h1 { font-size: 26px; line-height: 1.15; }
.hello p { color: var(--slate); margin-top: 4px; font-size: 15px; }

.status-now h2 { font-size: 23px; line-height: 1.2; margin: 2px 0 6px; }
.status-now p { color: var(--slate); font-size: 15px; }
.progress { margin-top: 16px; height: 8px; background: var(--accent-soft); border-radius: 99px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--accent); border-radius: 99px; transition: width .6s ease; }
.progress-label { font-size: 13px; color: var(--muted); margin-top: 8px; }

.timeline { list-style: none; margin-top: 18px; position: relative; }
.timeline li { position: relative; padding: 0 0 16px 34px; font-size: 15px; color: var(--muted); }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: ''; position: absolute; left: 9px; top: 18px; bottom: -2px; width: 2px; background: var(--line);
}
.timeline li:last-child::before { display: none; }
.timeline .dot {
  position: absolute; left: 0; top: 1px; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--line); background: #fff; display: grid; place-items: center;
}
.timeline li.done { color: var(--ink); }
.timeline li.done .dot { background: var(--navy); border-color: var(--navy); }
.timeline li.done .dot::after { content: ''; width: 8px; height: 4px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px); }
.timeline li.done::before { background: var(--navy); }
.timeline li.current { color: var(--navy); font-weight: 700; }
.timeline li.current .dot { border-color: var(--accent); background: #fff; box-shadow: 0 0 0 4px var(--accent-soft); }
.timeline li.current .dot::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

.money .amount { font-family: 'Fraunces', Georgia, serif; font-size: 40px; font-weight: 600; color: var(--navy); line-height: 1.1; margin: 4px 0 8px; font-variant-numeric: tabular-nums; }
.money .amount.pending { font-size: 20px; color: var(--slate); font-family: 'Inter', sans-serif; font-weight: 500; }
.money p { font-size: 14px; color: var(--slate); }

.notify h3, .updates h3, .contact h3 { font-size: 19px; margin-bottom: 6px; }
.notify p { font-size: 15px; color: var(--slate); margin-bottom: 14px; }
.notify .on { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--good); }
.notify ol { margin: 0 0 4px 20px; font-size: 15px; color: var(--ink); }
.notify ol li { margin-bottom: 6px; }

.updates ul { list-style: none; margin-top: 6px; }
.updates li { padding: 14px 0; border-top: 1px solid var(--line); }
.updates li:first-child { border-top: none; padding-top: 6px; }
.updates .when { font-size: 13px; color: var(--muted); }
.updates .tag { display: inline-block; font-size: 12px; font-weight: 600; color: var(--navy); background: var(--accent-soft); border-radius: 99px; padding: 2px 9px; margin-left: 6px; }
.updates .text { margin-top: 4px; font-size: 15.5px; white-space: pre-wrap; }

.contact .row { display: flex; gap: 10px; margin-top: 12px; }
.contact .row .btn { flex: 1; margin: 0; }
.contact p { font-size: 14px; color: var(--slate); }

.foot { text-align: center; font-size: 12.5px; color: var(--muted); margin-top: 26px; padding: 0 8px; }

.skeleton { height: 120px; border-radius: var(--radius); background: linear-gradient(90deg, #eee9dd, #f6f2e8, #eee9dd); background-size: 200% 100%; animation: sk 1.2s infinite; margin-top: 16px; }
@keyframes sk { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .skeleton, .progress > span { animation: none; transition: none; } }

.demo-bar { background: var(--navy); color: #fff; font-size: 13px; text-align: center; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; }
.demo-bar a { color: #fff; font-weight: 700; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.money p.disclaimer { font-size: 13px; color: var(--muted); line-height: 1.45; }

/* ---- money card drawn as a check ---- */
.check { position: relative; margin: 12px 0 10px; padding: 14px 16px 12px; border-radius: 10px;
  background: repeating-linear-gradient(135deg, #f4f8f2 0 10px, #eef4ec 10px 20px);
  border: 1px solid #cfdccb; box-shadow: 0 2px 6px rgba(0,0,0,.06); font-family: Georgia, 'Times New Roman', serif; color: #23312a; overflow: hidden; }
.check-top { display: flex; justify-content: space-between; font-size: .85rem; margin-bottom: 10px; }
.check-brand { font-weight: 700; letter-spacing: .02em; }
.check-no { color: #5b6b62; }
.check-row { display: flex; gap: 8px; align-items: baseline; border-bottom: 1px solid #b9c8b4; padding: 4px 0; font-size: .95rem; }
.check-k { font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; color: #5b6b62; white-space: nowrap; }
.check-payee { font-style: italic; font-size: 1.1rem; }
.check-pay { padding: 8px 0 6px; border-bottom: 1.5px solid #7f9478; }
.check-pay .check-k { font-size: .82rem; font-weight: 700; color: #2f3d35; letter-spacing: .07em; }
.check-pay .check-payee { font-size: 1.6rem; font-weight: 700; color: #1d2a22; line-height: 1.1; }
.check-amtbox { position: relative; margin: 10px 0 8px; padding: 8px 12px; border: 1.5px solid #9fb39a; border-radius: 6px; background: #fff; min-height: 2.6rem; display: flex; align-items: center; }
.check-amtbox .amount { margin: 0; font-family: inherit; }
.check-amtbox .amount.pending { display: flex; align-items: center; gap: 10px; font-size: 1.4rem; }
.blurred { filter: blur(7px); user-select: none; color: #2b6a3f; font-weight: 700; }
.stamp { position: absolute; right: 10px; top: 50%; transform: translateY(-50%) rotate(-8deg); padding: 2px 10px; border: 2px solid var(--accent, #b8860b); color: var(--accent, #b8860b);
  border-radius: 6px; font-family: system-ui, sans-serif; font-weight: 800; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; background: rgba(255,255,255,.85); }
.stamp-paid { border-color: #2b8a3e; color: #2b8a3e; }
.stamp-est { opacity: .8; }
.check-memo { border-bottom: none; font-size: .85rem; }
.check-micr { margin-top: 6px; font-family: 'Courier New', monospace; font-size: .75rem; letter-spacing: .2em; color: #6f7d75; }

.check-amtbox { overflow: hidden; }
.magnifier { position: absolute; top: 50%; left: 0; color: #23312a; transform: translate(-10%, -50%);
  animation: gp-search 4.5s ease-in-out infinite; filter: drop-shadow(0 2px 2px rgba(0,0,0,.2)); pointer-events: none; }
@keyframes gp-search {
  0%   { left: 2%;  transform: translate(0, -55%) rotate(-6deg); }
  25%  { left: 30%; transform: translate(0, -40%) rotate(4deg); }
  50%  { left: 52%; transform: translate(0, -60%) rotate(-4deg); }
  75%  { left: 22%; transform: translate(0, -45%) rotate(6deg); }
  100% { left: 2%;  transform: translate(0, -55%) rotate(-6deg); }
}
@media (prefers-reduced-motion: reduce) { .magnifier { animation: none; left: 30%; } }
.audit-line { margin: 4px 0 2px; color: var(--accent, #b8860b); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; }

/* sign-in: brand logo, wrong-site pointer */
.login .login-logo { width: 260px; max-width: 80%; height: auto; }
.login .foot { margin-top: 14px; }
.msg.note { color: var(--navy); font-weight: 600; }
.msg .goto { margin-top: 12px; font-size: 15px; padding: 12px 16px; }
