:root {
  --bg: #09090b;
  --bg-elevated: #111113;
  --bg-card: #17171a;
  --border: #27272a;
  --border-hover: #3f3f46;
  --text: #fafafa;
  --text-muted: #a1a1aa;
  --text-dim: #71717a;
  --green: #4ade80;
  --red: #f87171;
  --accent: #fafafa;
  --mono: 'SF Mono', 'Cascadia Code', 'Consolas', 'Menlo', monospace;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Inter, Roboto, sans-serif;
  --radius: 8px;
  --max-width: 880px;
}

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

html {
  color-scheme: dark;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

code, pre {
  font-family: var(--mono);
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Header --- */
header {
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: rgba(9, 9, 11, 0.85);
  backdrop-filter: blur(8px);
  z-index: 10;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.logo-mark {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--text);
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}

/* --- Minimal hero (home) --- */
.hero-minimal {
  min-height: calc(100vh - 57px);
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 64px 48px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 12px;
  margin-bottom: 28px;
}

.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.hero-minimal h1 {
  font-size: 64px;
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 600;
  max-width: 900px;
  margin-bottom: 24px;
}

.hero-minimal .lede {
  font-size: 19px;
  color: var(--text-muted);
  max-width: 620px;
  margin-bottom: 40px;
}

.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.btn-primary {
  background: var(--text);
  color: var(--bg);
}

.btn-primary:hover {
  background: #e4e4e7;
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border-color: var(--border);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
}

/* --- Counters --- */
.counters {
  display: flex;
  gap: 80px;
  margin-top: 80px;
  flex-wrap: wrap;
  justify-content: center;
}

.counter {
  text-align: center;
}

.counter-value {
  font-family: var(--mono);
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.counter-label {
  font-size: 12px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 6px;
}

/* --- Sections (docs page) --- */
section {
  padding: 64px 0;
  border-bottom: 1px solid var(--border);
}

section:last-of-type {
  border-bottom: none;
}

.page-header {
  padding: 56px 0 40px;
  border-bottom: 1px solid var(--border);
}

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

h1 {
  font-size: 36px;
  letter-spacing: -0.02em;
  font-weight: 600;
}

h2 {
  font-size: 26px;
  letter-spacing: -0.01em;
  font-weight: 600;
  margin-bottom: 16px;
}

h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
}

p {
  color: var(--text-muted);
}

.section-intro {
  max-width: 560px;
  margin-bottom: 40px;
}

/* --- Architecture grid --- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.card-number {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 16px;
}

.card p {
  font-size: 14px;
}

/* --- Endpoints --- */
.endpoint {
  margin-bottom: 40px;
}

.endpoint:last-child {
  margin-bottom: 0;
}

.endpoint-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.method {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
  background: rgba(74, 222, 128, 0.1);
  border-radius: 4px;
  padding: 2px 6px;
}

.endpoint-path {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 500;
}

.endpoint-desc {
  font-size: 14px;
  margin-bottom: 16px;
}

.code-block {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 12px;
}

.code-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-dim);
}

.copy-btn {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color 0.15s ease;
}

.copy-btn:hover {
  color: var(--text);
}

pre {
  padding: 14px;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.6;
  color: #d4d4d8;
}

.tok-key { color: #7dd3fc; }
.tok-str { color: #86efac; }
.tok-bool { color: #fca5a5; }
.tok-null { color: var(--text-dim); }
.tok-comment { color: var(--text-dim); }

.field-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 12px;
}

.field-table th {
  text-align: left;
  color: var(--text-dim);
  font-weight: 500;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.field-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}

.field-table code {
  color: var(--text);
  font-size: 12px;
}

/* --- Pricing --- */
.pricing-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  flex-wrap: wrap;
  gap: 16px;
}

.pricing-amount {
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.pricing-amount span {
  font-size: 14px;
  color: var(--text-dim);
  font-weight: 400;
}

.pricing-details {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}

.pricing-detail-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.pricing-detail-value {
  font-family: var(--mono);
  font-size: 13px;
}

/* --- Uptime page --- */
.status-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  margin-bottom: 16px;
}

.status-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.status-card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
}

.status-help {
  color: var(--text-dim);
  font-size: 12px;
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: default;
}

.status-badge {
  font-size: 13px;
  font-weight: 500;
  color: var(--green);
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.status-bars {
  display: flex;
  align-items: flex-end;
  gap: 1px;
  height: 44px;
  margin-bottom: 12px;
  overflow: hidden;
}

.status-bar {
  flex: 1;
  min-width: 1px;
  height: 100%;
  border-radius: 1px;
  background: var(--green);
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.12s ease;
  transform-origin: bottom center;
  position: relative;
}

.status-bar:hover {
  transform: scaleY(1.3) scaleX(2.2);
  filter: brightness(1.3);
  z-index: 2;
}

.status-bar.down {
  background: var(--red);
}

.status-bar.no-data {
  background: var(--border);
}

.status-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-dim);
}

.status-footer-center {
  color: var(--text-muted);
}

.status-note {
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 24px;
}

/* --- Footer --- */
footer {
  padding: 40px 0;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-size: 13px;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--text-muted);
}

.footer-copy {
  font-size: 13px;
  color: var(--text-dim);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .hero-minimal h1 {
    font-size: 32px;
  }

  h1 {
    font-size: 28px;
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
  }

  .pricing-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .counters {
    gap: 32px;
  }

  .counter-value {
    font-size: 26px;
  }

  .status-bars {
    height: 36px;
  }
}
