/* Vista web — "Field Notes" theme. Tokens come from tokens.css; see DESIGN.md. */
:root {
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
header {
  height: 72px;
  border-bottom: 1px solid var(--line);
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 22px;
}
header .brand {
  font: 500 26px/1 var(--serif);
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--ink);
}
header > .muted {
  font-size: 15px;
  padding-left: 22px;
  border-left: 1px solid var(--line);
  line-height: 1;
}
header #signout {
  margin-left: auto;
}

/* Hamburger menu + side drawer */
.menu-button {
  width: 42px;
  height: 42px;
  flex: none;
  display: grid;
  place-content: center;
  gap: 4px;
  padding: 0;
  margin: 0;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  box-shadow: none;
}
.menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
}
.menu-button:hover {
  background: var(--cream-2);
}
.drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: min(300px, 82vw);
  background: var(--cream);
  border-right: 1px solid var(--line);
  padding: 28px 24px;
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto;
}
.drawer .eyebrow {
  margin: 0 0 14px;
}
.drawer a {
  font: 500 19px/1.3 var(--serif);
  color: var(--ink);
  text-decoration: none;
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
}
.drawer a:hover {
  color: var(--rust);
}
.drawer a[aria-current="page"] {
  color: var(--rust);
}
.scrim {
  position: fixed;
  inset: 0;
  background: rgba(46, 41, 34, 0.35);
  z-index: 30;
}

/* Landing / static pages */
.cta-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 30px;
}
a.button {
  display: inline-flex;
  align-items: center;
  height: 46px;
  padding: 0 22px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 15px;
  text-decoration: none;
}
a.button.solid {
  background: var(--ink);
  color: var(--cream);
}
a.button.solid:hover {
  background: #3a342c;
}
a.button.quiet {
  border: 1px solid var(--line);
  color: var(--ink);
}
a.button.quiet:hover {
  background: var(--cream-2);
}
.page-grid {
  display: grid;
  gap: 22px;
  padding-top: 28px;
}
.steps {
  margin: 0;
  padding-left: 20px;
}
.steps li {
  padding: 8px 0 8px 6px;
  border-bottom: 1px solid var(--line);
}
.steps li:last-child {
  border-bottom: 0;
}
main {
  flex: 1;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 56px 28px 96px;
}
h1 {
  font: 400 clamp(34px, 4vw, 48px) / 1.05 var(--serif);
  letter-spacing: -0.02em;
  margin: 10px 0 14px;
  text-wrap: balance;
}
h1 i {
  font-style: italic;
  font-weight: 300;
  color: var(--rust);
}
h2 {
  font: 500 22px/1.2 var(--serif);
  letter-spacing: -0.01em;
  margin: 0 0 12px;
}
p {
  margin: 0 0 14px;
}
.muted,
small {
  color: var(--ink-2);
}
small {
  display: block;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-3);
}
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0;
}
.lede {
  font: 400 21px/1.5 var(--serif);
  color: var(--ink-2);
  max-width: 46ch;
}

/* Sign-in */
.login {
  display: grid;
  grid-template-columns: 6fr 5fr;
  gap: 64px;
  align-items: center;
  padding: 24px 0 40px;
}
.login > * {
  min-width: 0;
}
.login h1 {
  font-size: clamp(44px, 5.6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin: 14px 0 26px;
}
.facts {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  border-top: 1px solid var(--line);
  max-width: 52ch;
}
.facts li {
  padding: 12px 0 12px 22px;
  border-bottom: 1px solid var(--line);
  font-size: 15.5px;
  color: var(--ink-2);
  position: relative;
}
.facts li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 21px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--ink);
}
.facts li:nth-child(2)::before {
  background: var(--rust);
}
.facts li:nth-child(3)::before {
  background: var(--moss);
}
.login .card {
  margin: 0;
  box-shadow: 0 30px 50px -40px rgba(31, 28, 24, 0.5);
}

/* Surfaces */
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 28px;
  margin: 28px 0;
}
.card > .muted {
  max-width: 68ch;
}
label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
}
input,
select {
  display: block;
  width: 100%;
  font: 400 15px/1.4 var(--sans);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 12px 14px;
  margin: 6px 0 18px;
  background: var(--paper);
  color: var(--ink);
}
input::placeholder {
  color: var(--ink-3);
}
button,
.downloads a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 14px;
  font: 500 14px/1 var(--sans);
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s;
}
button:hover,
.downloads a:hover {
  background: var(--cream-2);
}
button:disabled {
  opacity: 0.45;
  cursor: default;
  background: transparent;
}
.primary {
  height: 44px;
  padding: 0 20px;
  font-size: 15px;
  background: var(--ink);
  color: var(--cream);
  box-shadow: none;
  margin: 4px 0 16px;
  width: 100%;
}
.primary:hover {
  background: #3a342c;
}
button.link {
  box-shadow: none;
  padding: 0;
  height: auto;
  color: var(--ink-2);
  font-weight: 500;
  margin-bottom: 18px;
}
button.link:hover {
  background: none;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--rust);
}
.heading {
  display: flex;
  gap: 30px;
  justify-content: space-between;
  align-items: flex-end;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}
.heading .muted {
  margin: 0;
  max-width: 52ch;
}
.heading > label {
  min-width: 260px;
}
.heading > label select {
  margin-bottom: 0;
}
.instructions {
  background: var(--cream-2);
  border-color: var(--line);
}
.instructions p {
  color: var(--ink-2);
  max-width: 68ch;
}
.instructions b {
  color: var(--ink);
  font-weight: 600;
}
.copyline {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 8px 0 18px;
  flex-wrap: wrap;
}
code {
  font:
    13.5px/1.4 ui-monospace,
    SFMono-Regular,
    Menlo,
    monospace;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 6px 10px;
  word-break: break-all;
}

/* Report ledger */
.report-list {
  margin-top: 8px;
  border-top: 1px solid var(--line);
}
.report {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.report h2 {
  font-size: 22px;
  margin: 0 0 6px;
}
.report small {
  font-variant-numeric: tabular-nums;
}
.report .figures {
  display: flex;
  gap: 24px;
  margin-left: auto;
  margin-right: 24px;
  color: var(--ink-2);
}
.report .mono-figure {
  font-size: 14px;
  text-align: left;
}
.candidate .mono-figure {
  font-size: inherit;
  color: var(--ink);
}
.pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
  font-size: 13.5px;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

/* Metrics as a ruled row */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 32px 0 8px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.metric {
  padding: 20px 22px 22px 0;
  border-right: 1px solid var(--line);
  margin-right: 22px;
}
.metric:last-child {
  border-right: 0;
  margin-right: 0;
}
.metric span {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.metric b {
  display: block;
  font: 400 40px/1.1 var(--serif);
  letter-spacing: -0.02em;
  margin-top: 10px;
  font-variant-numeric: tabular-nums;
}
.downloads {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.candidate {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}
.candidate strong {
  font: 500 19px/1.3 var(--serif);
  display: block;
}
.candidate small {
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}

/* Evidence table */
.table-wrap {
  overflow-x: auto;
  margin-top: 6px;
}
table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
  font-size: 14px;
}
th {
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  text-transform: uppercase;
}
td,
th {
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th:first-child,
td:first-child {
  padding-left: 0;
  color: var(--ink-3);
}
th.num,
td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
td.mono {
  font-size: 13px;
  white-space: nowrap;
}
td .badge + .badge {
  margin-left: 4px;
}
td:nth-child(5),
td:last-child {
  white-space: nowrap;
}
th:last-child,
td:last-child {
  padding-right: 0;
}
td {
  max-width: 330px;
  overflow-wrap: anywhere;
}
td small {
  font-size: 12.5px;
  margin-top: 3px;
}

/* Status */
#message:not(:empty) {
  padding: 14px 18px;
  background: var(--cream-2);
  border-left: 3px solid var(--rust);
  border-radius: 4px;
  margin-bottom: 28px;
  font-size: 15px;
  overflow-wrap: anywhere;
}
.empty {
  margin: 0;
  padding: 48px 20px;
  text-align: center;
  font: 400 19px/1.4 var(--serif);
  color: var(--ink-3);
  border: 1px dashed var(--line);
  border-radius: 4px;
}
footer {
  border-top: 1px solid var(--line);
  padding: 28px;
  color: var(--ink-3);
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
[hidden] {
  display: none !important;
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
@media (max-width: 900px) {
  .login {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .metric:nth-child(2) {
    border-right: 0;
    margin-right: 0;
  }
  .metric:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }
}
@media (max-width: 700px) {
  main {
    padding: 32px 18px 64px;
  }
  header,
  footer {
    padding-left: 18px;
    padding-right: 18px;
  }
  header > .muted {
    display: none;
  }
  .login h1 {
    font-size: 40px;
  }
  h1 {
    font-size: 30px;
  }
  .heading {
    display: block;
  }
  .heading > label {
    min-width: 0;
    margin-top: 18px;
  }
  .card {
    padding: 20px;
  }
  .report,
  .candidate {
    align-items: flex-start;
    flex-direction: column;
  }
  .metric b {
    font-size: 32px;
  }
}
