/* Deliberately close to wayleave.dev: dark, high contrast, mono for anything
   numeric or machine-generated. A billing surface should look like a terminal,
   not like a marketing page — it is read by people checking arithmetic. */

:root {
  --bg: #0a0c0a;
  --panel: #101310;
  --line: #1e241e;
  --text: #e8ece8;
  --dim: #7d857d;
  --green: #6ee7a0;
  --amber: #e7c86e;
  --red: #e78b6e;
  --mono: ui-monospace, "JetBrains Mono", SFMono-Regular, Menlo, monospace;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
}

.bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: var(--bg); z-index: 5;
}
.brand { font-weight: 600; letter-spacing: -0.01em; }
.mark {
  display: inline-block; width: 1.5em; height: 1.5em; line-height: 1.5em;
  text-align: center; border: 1px solid var(--green); border-radius: 5px;
  color: var(--green); margin-right: .4rem; transform: rotate(45deg);
}
.bar-right { display: flex; align-items: center; gap: 1rem; }
.dim { color: var(--dim); }
.mono { font-family: var(--mono); font-size: 13px; }

.btn {
  border: 1px solid var(--line); border-radius: 7px;
  padding: .45rem .9rem; color: var(--text); text-decoration: none;
  font-size: 13px; background: var(--panel);
}
.btn:hover { border-color: var(--green); color: var(--green); }

.link {
  background: none; border: none; padding: 0;
  color: var(--green); text-decoration: underline; cursor: pointer;
  font: inherit; font-size: inherit;
}

.banner {
  background: #241f10; border-bottom: 1px solid #3a3117;
  color: var(--amber); padding: .75rem 1.5rem; font-size: 14px;
}
.banner .link { color: var(--amber); }

main { max-width: 1100px; margin: 0 auto; padding: 2rem 1.5rem 4rem; }

.hero {
  display: grid; grid-template-columns: 2fr 1fr; gap: 1rem; margin-bottom: 1rem;
}
.row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem;
  margin-bottom: 2rem;
}
@media (max-width: 820px) {
  .hero, .row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .hero, .row { grid-template-columns: 1fr; }
}

.stat {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 12px; padding: 1.1rem 1.2rem;
}
.stat--hero { border-color: #24402e; }

.label {
  font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--dim); margin-bottom: .5rem;
}
.value {
  font-family: var(--mono); font-size: 3.4rem; line-height: 1.05;
  font-weight: 600; letter-spacing: -0.03em; color: var(--green);
}
.value--mid { font-size: 2.2rem; color: var(--amber); }
.value--sm  { font-size: 1.5rem; color: var(--text); }
.money { color: var(--green); }
.note { margin-top: .5rem; font-size: 12.5px; color: var(--dim); }

.warn {
  border: 1px solid #4a2f1c; background: #1e1410; color: var(--red);
  border-radius: 10px; padding: .8rem 1rem; margin-bottom: 2rem; font-size: 14px;
}

h2 {
  font-size: 13px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--dim); font-weight: 600; margin: 0 0 .75rem;
}

/* Wide content scrolls inside its own container so the page body never does. */
.table-wrap {
  overflow-x: auto; border: 1px solid var(--line); border-radius: 12px;
  background: var(--panel);
}
table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 720px; }
th, td { padding: .7rem 1rem; text-align: left; border-bottom: 1px solid var(--line); }
th {
  font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase;
  color: var(--dim); font-weight: 600;
}
tr:last-child td { border-bottom: none; }
td.num, th.num { text-align: right; font-family: var(--mono); }
td.id { font-family: var(--mono); font-size: 13px; }

.lane {
  font-family: var(--mono); font-size: 11.5px; padding: .15rem .5rem;
  border-radius: 5px; border: 1px solid var(--line);
}
.lane--verified_agent { color: var(--green); border-color: #24402e; }
.lane--declared_agent { color: var(--amber); border-color: #3a3117; }
.lane--suspected_bot  { color: var(--red);   border-color: #4a2f1c; }

.yes { color: var(--green); }
.no  { color: var(--dim); }

.empty { color: var(--dim); padding: 2rem 0; text-align: center; }

.foot {
  margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line);
  color: var(--dim); font-size: 13px;
}

/* ── auth + account pages ────────────────────────────────────────────── */

main.narrow { max-width: 720px; }

.h1 { font-size: 1.6rem; letter-spacing: -0.02em; margin: 0 0 .5rem; }
.lede { color: var(--dim); margin: 0 0 1.5rem; }

.block {
  border: 1px solid var(--line); background: var(--panel);
  border-radius: 12px; padding: 1.25rem 1.4rem; margin-bottom: 1.25rem;
}
.block h2 { margin-top: 0; }

.stack { display: flex; flex-direction: column; gap: .6rem; align-items: flex-start; }
.row-form { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1rem; }

.label { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }

.input {
  background: #0c0f0c; border: 1px solid var(--line); border-radius: 8px;
  color: var(--text); padding: .6rem .8rem; font: inherit; min-width: 280px; flex: 1;
}
.input:focus { outline: none; border-color: var(--green); }

.submit {
  background: var(--green); color: #06210f; border: none; border-radius: 8px;
  padding: .6rem 1.1rem; font: inherit; font-weight: 600; cursor: pointer;
}
.submit:hover { filter: brightness(1.08); }
.submit:disabled { opacity: .5; cursor: default; }

.msg { font-size: 13.5px; border-radius: 8px; padding: .6rem .8rem; margin-top: .8rem; }
.msg--ok   { background: #0e2117; color: var(--green); border: 1px solid #24402e; }
.msg--warn { background: #241f10; color: var(--amber); border: 1px solid #3a3117; }

.fine { font-size: 12.5px; color: var(--dim); }

.newkey {
  border: 1px solid #24402e; background: #0e2117; border-radius: 10px;
  padding: .9rem 1rem; margin-bottom: 1rem;
  display: flex; flex-direction: column; gap: .5rem; align-items: flex-start;
}
.keyvalue {
  font-family: var(--mono); font-size: 13px; color: var(--green);
  word-break: break-all; user-select: all;
}

.danger { color: var(--red); }
tr.revoked { opacity: .45; }

/* ── docs ────────────────────────────────────────────────────────────── */

.docs { max-width: 780px; }
.docs .step { margin: 2.5rem 0; }
.docs h2 {
  font-size: 1.05rem; text-transform: none; letter-spacing: -0.01em;
  color: var(--text); margin-bottom: .75rem;
}
.num {
  display: inline-block; width: 1.7em; height: 1.7em; line-height: 1.7em;
  text-align: center; margin-right: .5rem; border-radius: 50%;
  background: #0e2117; color: var(--green); border: 1px solid #24402e;
  font-family: var(--mono); font-size: .8em;
}
.docs p { margin: .6rem 0; }
.docs a { color: var(--green); }

pre {
  background: #0c0f0c; border: 1px solid var(--line); border-radius: 10px;
  padding: 1rem; overflow-x: auto; margin: .9rem 0;
}
code { font-family: var(--mono); font-size: 13px; }
p code, li code, dd code {
  background: #0c0f0c; border: 1px solid var(--line);
  border-radius: 4px; padding: .05em .35em;
}
pre code { background: none; border: none; padding: 0; }

.callout {
  border: 1px solid #3a3117; background: #1a1710; color: var(--amber);
  border-radius: 10px; padding: .9rem 1.1rem; margin: 1.25rem 0; font-size: 14px;
}
.callout--ok { border-color: #24402e; background: #0e2117; color: var(--green); }
.callout pre { background: #060906; margin-bottom: 0; }

.defs { margin: 1rem 0; }
.defs dt {
  font-weight: 600; margin-top: 1rem; color: var(--text);
}
.defs dd { margin: .3rem 0 0; padding-left: 0; color: var(--dim); font-size: 14px; }

ul.plain { padding-left: 1.1rem; color: var(--dim); font-size: 14px; }
ul.plain li { margin: .7rem 0; }
ul.plain strong { color: var(--text); }
