:root {
  --bg: #0d1117;
  --bg-elevated: #161b22;
  --bg-panel: #161b22;
  --bg-subtle: #0f141b;
  --code-bg: #010409;
  --border: #30363d;
  --border-soft: #21262d;
  --text: #c9d1d9;
  --muted: #8b949e;
  --accent: #58a6ff;
  --accent-strong: #79c0ff;
  --success: #3fb950;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.025;
  background-image:
    linear-gradient(rgba(201, 209, 217, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201, 209, 217, 0.08) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black, transparent 85%);
}

.shell {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0 4rem;
}

.hero,
.panel,
.card {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.hero {
  padding: clamp(1.6rem, 4vw, 3rem);
  border-radius: 20px;
  transform: translateY(18px);
  opacity: 0;
  animation: rise 600ms ease forwards;
}

.topnav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  margin-top: 1rem;
  padding: 1rem 1.25rem;
  border-radius: 16px;
}

.nav-links,
.social-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem;
}

.topnav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.topnav a:hover {
  color: var(--accent-strong);
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-subtle);
}

.social-links svg {
  width: 1.1rem;
  height: 1.1rem;
}

.eyebrow,
.section-label,
.timeline-step {
  margin: 0 0 0.75rem;
  color: var(--accent-strong);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  font-weight: 700;
}

h1,
h2,
h3 {
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  letter-spacing: -0.03em;
}

h1 {
  margin: 0;
  max-width: 14ch;
  font-size: clamp(2.5rem, 7vw, 4.8rem);
  line-height: 0.96;
}

h2 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
}

h3 {
  margin-top: 0;
  margin-bottom: 0.75rem;
  font-size: 1.2rem;
}

h3 a {
  color: var(--text);
  text-decoration: none;
}

h3 a:hover {
  color: var(--accent-strong);
}

.lede,
.panel-copy,
.section-head p,
.timeline-item p,
.card p,
.card li,
.panel li {
  color: var(--muted);
  line-height: 1.75;
}

.lede {
  max-width: 68ch;
  margin: 1.2rem 0 0;
  font-size: 1.02rem;
}

.actions {
  display: flex;
  gap: 0.9rem;
  flex-wrap: wrap;
  margin-top: 1.8rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.1rem;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  border: 1px solid var(--border);
  transition:
    transform 160ms ease,
    background-color 160ms ease,
    color 160ms ease,
    border-color 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button.primary {
  color: #ffffff;
  background: #1f6feb;
  border-color: #1f6feb;
}

.button.secondary {
  color: var(--text);
  background: transparent;
}

.section-head {
  margin-top: 1.6rem;
  padding: 0.4rem 0 0;
}

.section-head p {
  max-width: 60ch;
  margin: 0.8rem 0 0;
}

.grid,
.timeline,
.mini-grid,
.columns {
  display: grid;
  gap: 1rem;
}

.grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 1rem;
}

.timeline {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 1rem;
}

.single-column {
  grid-template-columns: 1fr;
}

.mini-grid,
.columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 1rem;
}

.card,
.panel {
  transform: translateY(12px);
  opacity: 0;
}

.card {
  padding: 1.4rem;
  border-radius: 16px;
}

.compact {
  min-height: 100%;
}

.panel {
  margin-top: 1rem;
  padding: 1.4rem;
  border-radius: 16px;
}

.is-static {
  transform: none;
  opacity: 1;
}

.topic-list {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--muted);
  line-height: 1.8;
}

.topic-list li + li {
  margin-top: 0.3rem;
}

.security-note {
  margin-top: 0.8rem;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

code {
  background: rgba(110, 118, 129, 0.14);
  border: 1px solid rgba(110, 118, 129, 0.2);
  border-radius: 6px;
  padding: 0.15rem 0.35rem;
  color: #7ee787;
  font-size: 0.95em;
}

pre {
  margin: 1rem 0;
  padding: 1rem;
  background: var(--code-bg);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  overflow-x: auto;
  line-height: 1.65;
  color: #adbac7;
  text-shadow: none;
}

pre code {
  background: transparent;
  border: 0;
  padding: 0;
  color: #8b949e;
}

pre code * {
  color: inherit;
}

.cmd { color: #adbac7; }
.cmt { color: #768390; }
.bin { color: #7ee787; }
.flag { color: #79c0ff; }
.str { color: #a5d6ff; }
.path { color: #d2a8ff; }
.val { color: #ffa657; }

a {
  color: var(--accent);
}

a:hover {
  color: var(--accent-strong);
}

.is-visible {
  animation: rise 600ms ease forwards;
}

@keyframes rise {
  from {
    transform: translateY(18px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (max-width: 820px) {
  .grid,
  .timeline,
  .mini-grid,
  .columns {
    grid-template-columns: 1fr;
  }

  .shell {
    width: min(100% - 1rem, 1100px);
    padding-top: 1rem;
  }

  h1 {
    max-width: none;
  }
}
