:root {
  color-scheme: dark;
  --bg: #080b10;
  --panel: rgba(13, 19, 29, .76);
  --panel-solid: #101720;
  --ink: #edf2f7;
  --muted: #a6b3c2;
  --line: rgba(180, 197, 219, .18);
  --cyan: #40c7c7;
  --green: #71d88a;
  --amber: #e0b85a;
  --violet: #9a8cff;
  --shadow: 0 24px 80px rgba(0, 0, 0, .42);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 12% 18%, rgba(64, 199, 199, .16), transparent 30%),
    radial-gradient(circle at 82% 12%, rgba(154, 140, 255, .14), transparent 28%),
    linear-gradient(135deg, #080b10 0%, #0d1118 48%, #11150f 100%);
  color: var(--ink);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.82), transparent 78%);
}

a { color: inherit; text-decoration: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
  background: rgba(8, 11, 16, .84);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 760;
}

.brand img { display: block; }

nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: var(--muted);
  font-size: 14px;
}

nav a:hover, .resource-list a:hover strong, .tool-card:hover strong { color: var(--green); }

main { overflow: hidden; }

.hero {
  min-height: calc(100vh - 72px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, .92fr);
  gap: clamp(36px, 6vw, 90px);
  align-items: center;
  padding: clamp(56px, 8vw, 112px) clamp(20px, 5vw, 72px);
}

.hero-copy, .page-hero > * { max-width: 830px; }

.page-hero {
  padding: clamp(54px, 8vw, 102px) clamp(20px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--green);
  font-size: 13px;
  font-weight: 760;
  letter-spacing: .12em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: 24px;
  font-size: clamp(44px, 7.7vw, 92px);
  line-height: .96;
  letter-spacing: 0;
}

h2 {
  max-width: 760px;
  margin-bottom: 0;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.04;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 12px;
  font-size: 23px;
}

.lead {
  max-width: 680px;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.62;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: 15px;
  font-weight: 700;
}

.button.primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--cyan), var(--green));
  color: #07100e;
}

.button.ghost {
  color: var(--ink);
  background: rgba(255,255,255,.04);
}

.signal {
  min-height: 420px;
  display: grid;
  place-items: center;
}

.signal-panel {
  width: min(100%, 520px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(16, 23, 32, .92), rgba(7, 11, 17, .84));
  box-shadow: var(--shadow);
  padding: 28px;
}

.metric {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.metric span, .query, .icon, .tag, .case-meta {
  color: var(--muted);
  font-family: "Cascadia Code", Consolas, monospace;
  font-size: 13px;
}

.metric strong {
  color: var(--green);
  font-size: 44px;
}

.matrix {
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 13px 16px;
  padding: 28px 0;
  align-items: center;
}

.matrix span { color: var(--muted); }

.matrix i {
  display: block;
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(64,199,199,.24), rgba(113,216,138,.96));
  box-shadow: 0 0 20px rgba(64,199,199,.14);
}

.query {
  padding: 16px;
  border: 1px solid rgba(64, 199, 199, .2);
  border-radius: 6px;
  background: rgba(64, 199, 199, .06);
  overflow-wrap: anywhere;
}

.section {
  padding: clamp(68px, 9vw, 118px) clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.grid {
  display: grid;
  gap: 18px;
}

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

.grid.five { grid-template-columns: repeat(5, minmax(0, 1fr)); }

.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

article, .tool-card, .case-card, .route-card {
  min-height: 220px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 23, 32, .62);
}

.tool-card, .case-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tool-card strong, .case-card strong {
  font-size: 22px;
  color: var(--ink);
}

.tool-card span, .case-card span, article p, .route-card p, .article-body p, .article-body li {
  color: var(--muted);
  line-height: 1.65;
}

.tool-card { min-height: 180px; }

.case-card { min-height: 240px; }

.icon {
  display: inline-flex;
  margin-bottom: 38px;
  color: var(--amber);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(320px, 1fr);
  gap: clamp(32px, 7vw, 90px);
  align-items: start;
}

.resource-list { border-top: 1px solid var(--line); }

.resource-list a, .resource-list p {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 20px;
  margin: 0;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.resource-list strong { color: var(--ink); }

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.tag {
  display: inline-flex;
  padding: 6px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
}

.article-body {
  max-width: 860px;
  padding: clamp(48px, 7vw, 84px) clamp(20px, 5vw, 72px);
}

.article-body h2 {
  margin-top: 42px;
  margin-bottom: 14px;
  font-size: clamp(26px, 4vw, 38px);
}

.article-body ul, .article-body ol {
  padding-left: 22px;
}

.case-meta { margin-bottom: 18px; color: var(--amber); }

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 28px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: rgba(8, 11, 16, .72);
}

@media (max-width: 1040px) {
  .grid.five { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 880px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    width: 100%;
    justify-content: space-between;
  }

  .hero, .split { grid-template-columns: 1fr; }

  .hero {
    min-height: auto;
    padding-top: 54px;
  }

  .grid.three, .grid.two, .grid.five { grid-template-columns: 1fr; }

  .resource-list a, .resource-list p {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

@media (max-width: 520px) {
  h1 { font-size: 42px; }

  .signal { min-height: 340px; }

  .signal-panel { padding: 18px; }

  .metric strong { font-size: 34px; }

  .site-footer { flex-direction: column; }
}
