:root {
  color-scheme: dark;
  --bg: #0d1117;
  --bg-raised: #161b22;
  --border: #21262d;
  --text: #c9d1d9;
  --text-dim: #8b949e;
  --text-faint: #6e7681;
  --accent: #4ade80;
  --accent-dim: #2ea25f;
  --bad: #f85149;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
}

.scan {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 60% at 50% 15%, transparent 0%, rgba(13, 17, 23, 0.9) 75%);
  z-index: 0;
}

.landing > *:not(.scan), body > .top, body > .wrap, body > .auth {
  position: relative;
  z-index: 1;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.top {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
  background: rgba(13, 17, 23, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.top.public { border-bottom: 0; background: transparent; max-width: 780px; }
.top nav { display: flex; flex-wrap: wrap; gap: 12px; margin-right: auto; font-size: 14px; }
.top nav a { color: var(--text-dim); text-decoration: none; }
.top nav a:hover { color: var(--text); }

.brand { font-family: var(--mono); color: var(--text-dim); text-decoration: none; }
.brand b { color: var(--accent); font-weight: 600; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #04120a;
  font-weight: 650;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { filter: brightness(1.05); text-decoration: none; }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.linkish {
  background: none;
  border: 0;
  color: var(--accent);
  cursor: pointer;
  font: inherit;
}

.hero, .section, .foot, .auth {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
}

.hero { padding-top: 64px; padding-bottom: 48px; }
.kicker { font-family: var(--mono); font-size: 13px; color: var(--text-faint); margin-bottom: 20px; }
.hero h1 {
  font-size: clamp(36px, 7vw, 56px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: #f0f6fc;
  font-weight: 750;
}
.accent { color: var(--accent); }
.lead { margin-top: 22px; font-size: 19px; color: var(--text-dim); max-width: 60ch; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 28px; }
.terminal {
  margin-top: 32px;
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text-dim);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
}
.terminal .prompt { color: var(--accent); }

.section { margin-top: 72px; }
.section h2 {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  text-transform: lowercase;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  color: #f0f6fc;
}
.sec-no { color: var(--accent); margin-right: 10px; }
.sec-no::after { content: " /"; color: var(--text-faint); }
.section p { color: var(--text); max-width: 66ch; }

.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 18px; }
.card, .card-panel {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
}
.card .tag { font-family: var(--mono); font-size: 12px; color: var(--accent); }
.card h3 { margin-top: 8px; color: #f0f6fc; }
.card p { margin-top: 8px; color: var(--text-dim); font-size: 14px; }

.foot {
  margin-top: 80px;
  padding: 28px 24px 48px;
  border-top: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-faint);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.auth { padding: 80px 24px; max-width: 420px; }
.auth h1 { margin: 18px 0 8px; color: #f0f6fc; }
.muted { color: var(--text-dim); margin-bottom: 18px; font-family: var(--mono); font-size: 13px; }
.stack { display: grid; gap: 12px; }
.stack label { display: grid; gap: 6px; font-size: 13px; color: var(--text-dim); }
.stack input, .stack select {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  padding: 10px 12px;
  font: inherit;
}
.check { display: flex !important; align-items: center; gap: 8px; grid-template-columns: none !important; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 28px 20px 64px; }
.wrap.narrow { max-width: 640px; }
.page-head { display: flex; justify-content: space-between; gap: 16px; align-items: end; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { color: #f0f6fc; font-size: 28px; letter-spacing: -0.02em; }
.eyebrow { font-family: var(--mono); font-size: 12px; color: var(--text-faint); margin-bottom: 6px; }

.kpi { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 28px; }
.kpi-card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
}
.kpi-card span { display: block; color: var(--text-dim); font-size: 13px; margin-bottom: 8px; }
.kpi-card strong { font-size: 28px; color: #f0f6fc; letter-spacing: -0.03em; }

.grid-2 { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 20px; }
.grid-2 h2, .wrap h2 { font-size: 15px; font-family: var(--mono); color: #f0f6fc; margin-bottom: 12px; }

.table-wrap {
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(22, 27, 34, 0.8);
}
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
th { color: var(--text-faint); font-weight: 600; font-size: 12px; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.bad { color: var(--bad); font-weight: 650; }
.dim { opacity: 0.5; }
.error { color: var(--bad); margin-bottom: 12px; }
.ok { color: var(--accent); margin-bottom: 12px; }

.filters { display: flex; gap: 8px; }
.filters a {
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 13px;
}
.filters a.on, .filters a:hover { border-color: var(--accent-dim); color: var(--accent); }

.todo {
  margin-top: 18px;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  padding: 14px 16px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--text-dim);
  line-height: 1.7;
}

@media (max-width: 900px) {
  .kpi, .grid-2, .cards { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .kpi, .grid-2, .cards { grid-template-columns: 1fr; }
  .top nav { width: 100%; order: 3; }
}
