
:root {
  --paper: #efe6d4;
  --paper-2: #f7f1e4;
  --ink: #1c1712;
  --rule: #cbbfa6;
  --muted: #6b5e4e;
  --red: #8f1d1d;
  --green: #215c3a;
  --fill: #1c1712;
  --fill-ink: #f7f1e4;
  --warn: #8a5a12;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, "Times New Roman", serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.45;
  min-height: 100vh;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 27px,
    rgba(143, 29, 29, 0.045) 28px
  );
  z-index: 0;
}
a { color: inherit; }
code, .mono, .amt, input, textarea, select, button {
  font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace;
}
header.top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem 0.75rem;
  border-bottom: 2px solid var(--ink);
}
.brand { font-size: 1.35rem; letter-spacing: 0.02em; text-decoration: none; font-weight: 700; }
.brand small { display: block; font-size: 0.7rem; font-weight: 400; color: var(--muted); letter-spacing: 0.08em; text-transform: uppercase; }
nav { display: flex; gap: 1rem; flex-wrap: wrap; font-size: 0.95rem; }
nav a { text-decoration: none; border-bottom: 1px solid transparent; }
nav a:hover { border-bottom-color: var(--ink); }
main { position: relative; z-index: 1; max-width: 920px; margin: 0 auto; padding: 1.5rem; }
.hero { margin: 1.5rem 0 2rem; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.1; margin: 0 0 0.75rem; max-width: 18ch; }
.hero p { max-width: 42em; margin: 0; font-size: 1.1rem; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.75rem; margin: 1.75rem 0 2.25rem; }
.step { border: 1px solid var(--ink); padding: 0.85rem 1rem; background: var(--paper-2); }
.step b { display: block; font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 0.35rem; }
.grid { display: grid; gap: 0.85rem; }
.card {
  display: block;
  text-decoration: none;
  border: 1px solid var(--ink);
  background: var(--paper-2);
  padding: 1rem 1.1rem;
}
.card:hover { background: #fffaf0; }
.kicker { font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
h2 { font-size: 1.35rem; margin: 2rem 0 0.75rem; border-bottom: 1px solid var(--rule); padding-bottom: 0.25rem; }
.meta { color: var(--muted); font-size: 0.95rem; }
.amt { font-variant-numeric: tabular-nums; }
.badge {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  padding: 0.1rem 0.4rem;
}
.badge.open { color: var(--green); }
.badge.locked { color: var(--warn); }
.badge.delivered, .badge.completed { color: var(--green); }
.badge.cancelled, .badge.disputed { color: var(--red); }
form.stack { display: grid; gap: 0.85rem; max-width: 36rem; }
label { display: grid; gap: 0.25rem; font-size: 0.9rem; }
input, textarea, select {
  font-size: 1rem;
  padding: 0.45rem 0.5rem;
  border: 1px solid var(--ink);
  background: #fffdf8;
  color: var(--ink);
}
textarea { min-height: 7rem; }
button, .btn {
  cursor: pointer;
  border: 1px solid var(--ink);
  background: var(--fill);
  color: var(--fill-ink);
  padding: 0.55rem 0.9rem;
  font-size: 0.95rem;
  text-decoration: none;
  display: inline-block;
}
button.ghost, a.btn.ghost { background: transparent; color: var(--ink); }
button.danger { background: var(--red); border-color: var(--red); }
.flash { padding: 0.65rem 0.8rem; border: 1px solid var(--ink); margin: 0 0 1rem; }
.flash.err { border-color: var(--red); color: var(--red); }
.flash.ok { border-color: var(--green); color: var(--green); }
.ledger { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.ledger th, .ledger td { text-align: left; padding: 0.4rem 0.35rem; border-bottom: 1px solid var(--rule); }
.ledger th { font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.row-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; margin: 1rem 0; }
.comment { border-top: 1px solid var(--rule); padding: 0.75rem 0; }
.blocked { max-width: 36rem; margin: 12vh auto; padding: 1.5rem; border: 2px solid var(--ink); background: var(--paper-2); }
footer.site { position: relative; z-index: 1; max-width: 920px; margin: 0 auto; padding: 2rem 1.5rem 3rem; color: var(--muted); font-size: 0.85rem; border-top: 1px solid var(--rule); }
.notice { font-size: 0.9rem; color: var(--muted); max-width: 46em; }
