/* ── Prometheus Pulse — shares Seraphim Lab design tokens (seraphimlab.ca) ── */
:root {
  --bg: #0a0a0a;
  --bg-raise: #111111;
  --bg-raise-2: #161616;
  --line: #262626;
  --line-strong: #333333;
  --tx: #f5f5f5;
  --tx-2: #c7c7c7;
  --mut: #a3a3a3;
  --gold: #c9a14a;
  --gold-soft: #e0b85d;
  --gold-dim: rgba(201, 161, 74, 0.14);
  --ok: #4CC38A;
  --warn: #E0A93D;
  --bad: #E5685C;
  --radius: 8px;
  --header-h: 62px;
  --font-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--tx);
  font: 400 15.5px/1.6 var(--font-ui);
  position: relative;
  overflow-x: hidden;
}

/* single faint ambient accent, matching the lab's restraint */
.glow { position: fixed; pointer-events: none; z-index: 0; filter: blur(100px); opacity: .4; }
.glow-a { top: -260px; left: 50%; transform: translateX(-50%); width: 900px; height: 460px;
  background: radial-gradient(ellipse at center, rgba(201,161,74,.10), transparent 65%); }
.glow-b { display: none; }

header, main, footer { position: relative; z-index: 1; }

/* ── header ── */
header {
  display: flex; gap: 2.2rem; align-items: center;
  height: var(--header-h);
  padding: 0 clamp(1.2rem, 4vw, 3rem);
  background: rgba(10, 10, 10, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 10;
}
.brand {
  font-weight: 700; font-size: 1.08rem; letter-spacing: 0.01em;
  color: var(--tx); text-decoration: none;
  display: flex; align-items: center; gap: 0.65rem;
}
.brand img { border-radius: 6px; box-shadow: 0 0 0 1px var(--line); }
.brand span { color: var(--gold); }
nav { display: flex; gap: 1.6rem; margin-left: auto; align-items: center; }
nav a {
  color: var(--mut); text-decoration: none; font-size: 0.85rem; font-weight: 500;
  letter-spacing: 0.05em; text-transform: uppercase;
  padding: 0.2rem 0; border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
nav a:hover { color: var(--gold-soft); border-bottom-color: var(--gold); }
nav a.cta {
  color: #161003; background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  border-radius: 99px; padding: 0.34rem 0.95rem; font-weight: 600;
  border-bottom: none; text-transform: none; letter-spacing: 0.02em;
  box-shadow: 0 4px 14px rgba(201, 161, 74, 0.22);
}
nav a.cta:hover { color: #161003; filter: brightness(1.06); }
nav a.home {
  color: var(--tx-2);
  border: 1px solid var(--line); border-radius: 99px;
  padding: 0.32rem 0.85rem;
  text-transform: none; letter-spacing: 0.02em;
}
nav a.home:hover { color: var(--gold-soft); border-color: var(--gold); }

/* ── layout ── */
main { max-width: 1280px; margin: 0 auto; padding: clamp(1.4rem, 3.5vw, 2.6rem); }

h1 {
  font-weight: 700; font-size: clamp(1.6rem, 3vw, 2.1rem);
  letter-spacing: -0.015em; line-height: 1.2;
  margin: 0.4rem 0 0.9rem;
}
h2 {
  font-weight: 600; font-size: 1.15rem; letter-spacing: -0.005em;
  margin: 2.6rem 0 0.9rem; color: var(--tx);
}
h2::after { content: ""; display: block; width: 44px; height: 2px; margin-top: 7px;
  background: linear-gradient(90deg, var(--gold), transparent); border-radius: 2px; }
p { color: var(--tx-2); }
.eyebrow {
  color: var(--gold); font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase; margin: 1rem 0 0;
}
.lede { font-size: 1.02rem; max-width: 56ch; margin-top: -0.2rem; color: var(--mut); }
a { color: var(--gold); text-decoration: none; transition: color .12s ease; }
a:hover { color: var(--gold-soft); }
code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.78rem; color: var(--tx-2);
  background: var(--bg-raise); border: 1px solid var(--line);
  padding: 0.1rem 0.4rem; border-radius: 4px;
}

/* ── stat cards ── */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.9rem; margin: 1.4rem 0; }
.card {
  background: linear-gradient(160deg, var(--bg-raise-2), var(--bg-raise) 60%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.05rem 1.2rem;
  box-shadow: 0 1px 0 rgba(255,255,255,.03) inset, 0 10px 30px rgba(0,0,0,.3);
  transition: border-color .2s ease, transform .2s ease;
}
.card:hover { border-color: var(--line-strong); transform: translateY(-1px); }
.card .v {
  font-size: 1.55rem; font-weight: 600; color: var(--gold);
  font-variant-numeric: tabular-nums; letter-spacing: -0.01em; line-height: 1.25;
}
.card .k { color: var(--mut); font-size: 0.74rem; letter-spacing: 0.05em; text-transform: uppercase; margin-top: 0.3rem; }

/* ── tables ── */
table {
  width: 100%; border-collapse: separate; border-spacing: 0;
  font-size: 0.85rem; font-variant-numeric: tabular-nums;
  background: var(--bg-raise);
  border: 1px solid var(--line); border-radius: var(--radius);
}
th, td { padding: 0.6rem 0.8rem; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
th:first-child, td:first-child { text-align: left; padding-left: 1.1rem; }
th:last-child, td:last-child { padding-right: 1.1rem; }
tr:last-child td { border-bottom: none; }
/* rounded corners on cells (overflow:hidden would break sticky headers) */
thead th:first-child { border-top-left-radius: var(--radius); }
thead th:last-child { border-top-right-radius: var(--radius); }
tbody tr:last-child td:first-child { border-bottom-left-radius: var(--radius); }
tbody tr:last-child td:last-child { border-bottom-right-radius: var(--radius); }
th {
  color: var(--mut); font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.09em; text-transform: uppercase;
  cursor: pointer; user-select: none;
  position: sticky; top: var(--header-h); z-index: 5;
  background: #131313;
  background-clip: padding-box;
}
th:hover { color: var(--gold-soft); }
tbody tr { transition: background .12s ease; }
tbody tr:hover td { background: rgba(201, 161, 74, 0.05); }
td a { font-weight: 500; color: var(--tx); }
td a:hover { color: var(--gold-soft); }

.ok { color: var(--ok); } .warn { color: var(--warn); } .bad { color: var(--bad); } .mut { color: var(--mut); }

.pill {
  display: inline-block; margin-left: 0.45rem;
  padding: 0.08rem 0.55rem; border-radius: 99px;
  font-size: 0.68rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase;
  border: 1px solid var(--line-strong); color: var(--tx-2);
  background: var(--bg-raise);
}
.pill.ok { border-color: rgba(76, 195, 138, 0.4); color: var(--ok); background: rgba(76, 195, 138, 0.08); }
.pill.bad { border-color: rgba(229, 104, 92, 0.4); color: var(--bad); background: rgba(229, 104, 92, 0.08); }

.logo { width: 20px; height: 20px; border-radius: 5px; vertical-align: -4px; margin-right: 0.55rem;
  box-shadow: 0 0 0 1px var(--line); }

/* ── forms ── */
input[type=text], input[type=number], select {
  background: var(--bg-raise-2); color: var(--tx);
  border: 1px solid var(--line-strong); border-radius: 8px;
  padding: 0.55rem 0.85rem; font: inherit; font-size: 0.88rem;
  transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim); }
input#q { min-width: 260px; }
button {
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  color: #161003; border: none; border-radius: 8px;
  padding: 0.58rem 1.25rem; font: 600 0.88rem var(--font-ui); letter-spacing: 0.02em;
  cursor: pointer; box-shadow: 0 6px 18px rgba(201, 161, 74, 0.2);
  transition: transform .15s ease, box-shadow .15s ease;
}
button:hover { transform: translateY(-1px); box-shadow: 0 9px 24px rgba(201, 161, 74, 0.28); }

/* ── misc ── */
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; }
@media (max-width: 900px) { .grid2 { grid-template-columns: 1fr; } }
.elig td { text-align: center; }
.error {
  background: rgba(229, 104, 92, 0.07); border: 1px solid rgba(229, 104, 92, 0.35);
  border-radius: var(--radius); padding: 1.1rem 1.3rem; margin: 1rem 0;
}
svg { max-width: 100%; height: auto; display: block; }

/* ── delegate widget ── */
.dg { max-width: 640px; }
.dg-steps { color: var(--tx-2); line-height: 2; padding-left: 1.2rem; margin-bottom: 1.6rem; }
.dg-status { margin: 0.9rem 0; font-size: 0.88rem; min-height: 1.4em; color: var(--tx-2); }
.dg-status.ok { color: var(--ok); } .dg-status.bad { color: var(--bad); }
.dg-balances span { margin-right: 1.4rem; font-variant-numeric: tabular-nums; }
.dg-balances b { color: var(--gold); font-size: 1.1rem; }
.dg-row { display: flex; gap: 0.7rem; margin: 0.9rem 0; flex-wrap: wrap; }
.dg-row input, .dg-row select { flex: 1; min-width: 180px; }
#dg-current ul { color: var(--tx-2); padding-left: 1.2rem; }
.gold { color: var(--gold); }

/* ── footer ── */
footer {
  max-width: 1280px; margin: 3.5rem auto 0;
  padding: 1.6rem clamp(1.2rem, 3.5vw, 2.6rem) 2.4rem;
  color: var(--mut); font-size: 0.78rem; line-height: 1.7;
  border-top: 1px solid var(--line);
}
footer a { color: var(--tx-2); } footer a:hover { color: var(--gold-soft); }
.prov { font-variant-numeric: tabular-nums; letter-spacing: 0.03em; }
