:root {
  --ink: #0F2E2B;
  --ink-deep: #0A2320;
  --panel: #133932;
  --paper: #ECE7D8;
  --amber: #F2A93B;
  --amber-dim: #C98A2C;
  --line: rgba(236, 231, 216, 0.14);

  --font-display: 'IBM Plex Mono', monospace;
  --font-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  line-height: 1.5;
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}

/* ---------- top bar ---------- */

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
}

.dot { color: var(--amber); }

.status {
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--paper);
  opacity: 0.8;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-led {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 8px var(--amber);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

/* ---------- hero ---------- */

main {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 2rem;
}

.hero { padding: 5rem 0 3rem; }

.eyebrow {
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 0 0 1rem;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15;
  font-weight: 600;
  margin: 0 0 1.3rem;
  letter-spacing: -0.01em;
}

.lede {
  font-size: 1.05rem;
  max-width: 52ch;
  opacity: 0.85;
}

/* ---------- flow diagram (signature element) ---------- */

.flow {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 2.5rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
}

.flow-node {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 150px;
}

.flow-label {
  font-family: var(--font-display);
  font-size: 0.85rem;
  color: var(--paper);
}

.flow-sub {
  font-size: 0.75rem;
  opacity: 0.6;
}

.flow-track {
  flex: 1 1 auto;
  min-width: 40px;
  height: 1px;
  background: var(--line);
  position: relative;
  margin: 0 0.5rem;
}

.flow-packet {
  position: absolute;
  top: -3px;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 6px var(--amber);
  animation: travel 2.4s ease-in-out infinite;
}

@keyframes travel {
  0% { left: 0; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { left: calc(100% - 7px); opacity: 0; }
}

/* ---------- payload sample ---------- */

.payload { padding: 3rem 0 5rem; }

pre {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1.25rem 1.4rem;
  overflow-x: auto;
  font-family: var(--font-display);
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--paper);
}

code { color: inherit; }

/* ---------- footer ---------- */

footer {
  text-align: center;
  padding: 2rem;
  font-size: 0.78rem;
  opacity: 0.5;
  border-top: 1px solid var(--line);
}
