/* Same values as the application (apps/app/src/app/globals.css): ink on cool paper, one cobalt accent. */
@font-face {
  font-family: "Source Sans 3";
  src: url("fonts/source-sans-3-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 900;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("fonts/spectral-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Spectral";
  src: url("fonts/spectral-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

:root {
  --paper: #f3f4f7;
  --card: #ffffff;
  --ink: #131c2e;
  --muted: #515b70;
  --line: #dde1e9;
  --field: #9aa3b8;
  --accent: #2540a8;
  --accent-ink: #ffffff;
  --bar: #131c2e;
  --bar-muted: #aab4cc;
  --warn-bg: #fcf2dc;
  --warn-ink: #7d4e00;
  --serif: "Spectral", Georgia, serif;
  --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0c111c;
    --card: #141b2a;
    --ink: #e8ebf3;
    --muted: #a8b1c5;
    --line: #29334a;
    --field: #5d6a88;
    --accent: #9db0ff;
    --accent-ink: #0c1230;
    --bar: #172036;
    --warn-bg: #3d2f08;
    --warn-ink: #f6dc93;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1.0625rem/1.6 var(--sans);
  overflow-wrap: break-word;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
.wrap { width: min(100% - 2.5rem, 64rem); margin-inline: auto; }
a { color: var(--accent); text-underline-offset: 0.2em; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; text-wrap: balance; }
h1 { font-size: clamp(1.85rem, 8.5vw - 0.2rem, 3.25rem); margin: 0 0 1.25rem; max-width: 26ch; }
h2 { font-size: clamp(1.5rem, 3.2vw, 1.9rem); margin: 0 0 1.5rem; }
h3 { font-size: 1.1rem; margin: 0 0 .4rem; }
p { margin: 0 0 1rem; max-width: 44rem; }

/* The dark bar of the application, drawn to both edges of the window. */
header.top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding-block: 1rem;
  background: var(--bar);
  box-shadow: 0 0 0 100vmax var(--bar);
  clip-path: inset(0 -100vmax);
}
header.top a { color: var(--bar-muted); }
header.top a:focus-visible { outline-color: #fff; }
header.top .brand {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  color: #fff;
  font: 600 1.15rem var(--serif);
  text-decoration: none;
}
/* The mark of the application: a footbridge over the double rule that closes a proven total. */
.brand::before {
  content: "";
  flex: none;
  width: 1.75rem;
  height: 1.75rem;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2'%3E%3Cpath d='M3 14c3-10 15-10 18 0M8.5 8v6M15.5 8v6M3 17.5h18M3 21h18'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hero { padding-block: clamp(3rem, 8vw, 5.5rem) clamp(3rem, 7vw, 4.5rem); }
.lead { font-size: 1.25rem; color: var(--muted); max-width: 38rem; margin-bottom: 1.75rem; }
.status {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: var(--warn-bg);
  color: var(--warn-ink);
  border-radius: 999px;
  padding: .2rem .85rem;
  margin-bottom: 1.5rem;
  font-size: .9rem;
  font-weight: 600;
}
.status::before { content: ""; width: .45rem; height: .45rem; border-radius: 50%; background: currentColor; }
.button {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  border: 0;
  border-radius: .375rem;
  padding: .7rem 1.5rem;
  font: 600 1.0625rem var(--sans);
  text-decoration: none;
  cursor: pointer;
}
.button:hover { filter: brightness(1.1); }

section.block { border-top: 1px solid var(--line); padding-block: clamp(2.75rem, 6vw, 4rem); }

/* Reform timeline: a solid line for what applies, a dashed one for what is to come. */
.timeline { list-style: none; margin: 0 0 1.75rem; padding: 0; display: grid; gap: 1.75rem; }
.timeline li { border-left: 3px solid var(--accent); padding-left: 1.25rem; }
.timeline li.upcoming { border-left-style: dashed; }
.timeline time { display: block; font: 500 1.75rem/1.3 var(--serif); font-variant-numeric: lining-nums; margin-bottom: .6rem; }
.note { font-size: .95rem; color: var(--muted); }

/* Bridge: Xero <-> app <-> approved platform */
.bridge { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; gap: .5rem; text-align: center; }
.bridge li { background: var(--card); border: 1px solid var(--line); border-radius: .5rem; padding: 1.1rem; }
.bridge li.ours { background: var(--bar); border-color: var(--bar); color: #fff; font: 600 1.15rem var(--serif); }
.bridge li.link { background: none; border: 0; padding: 0; color: var(--accent); font-size: 1.4rem; line-height: 1; }
.bridge li.link span { display: inline-block; transform: rotate(90deg); }

/* One panel ruled into parts, as the application lists its tasks. */
.cards { display: grid; background: var(--card); border: 1px solid var(--line); border-radius: .5rem; overflow: hidden; }
.card { padding: 1.5rem; border-top: 1px solid var(--line); margin-top: -1px; }
.card p:last-child { margin-bottom: 0; }
.after-cards { margin-top: 1.5rem; }

form { background: var(--card); border: 1px solid var(--line); border-radius: .5rem; padding: clamp(1.25rem, 4vw, 2rem); max-width: 36rem; }
.field { margin-bottom: 1.25rem; }
label, legend { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .35rem; padding: 0; }
input[type="text"], input[type="email"], select {
  width: 100%;
  height: 2.75rem;
  font: inherit;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--field);
  border-radius: .375rem;
  padding: 0 .75rem;
}
input[type="radio"], input[type="checkbox"] { accent-color: var(--accent); width: 1rem; height: 1rem; }
fieldset { border: 0; margin: 0 0 1.25rem; padding: 0; }
.choice { display: inline-flex; gap: .45rem; align-items: center; margin-right: 1.75rem; font-weight: 400; font-size: 1rem; }
.consent label { display: flex; gap: .65rem; align-items: flex-start; font-weight: 400; }
.consent input { margin-top: .2rem; flex: none; }
/* Honeypot: hidden from people, visible to naive bots */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

footer { border-top: 1px solid var(--line); padding-block: 2rem 3rem; font-size: .95rem; color: var(--muted); }

.doc { max-width: 45rem; padding-block: 3rem 4rem; }
.doc h1 { font-size: clamp(1.8rem, 5vw, 2.35rem); }
.doc h2 { font-size: 1.3rem; margin: 2.25rem 0 .75rem; }
mark.todo { background: var(--warn-bg); color: var(--warn-ink); padding: 0 .25rem; }

@media (min-width: 46rem) {
  .timeline { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .timeline li { border-left: 0; border-top: 3px solid var(--accent); padding: 1.25rem 0 0; }
  .timeline li.upcoming { border-top-style: dashed; }
  .bridge { grid-template-columns: 1fr auto 1.3fr auto 1fr; align-items: stretch; }
  .bridge li { display: flex; align-items: center; justify-content: center; }
  .bridge li.link span { transform: none; }
  .cards { grid-template-columns: 1fr 1fr; }
  .card { border-left: 1px solid var(--line); margin-left: -1px; }
}
