:root {
  color-scheme: dark;
  --bg: #070a08;
  --bg-soft: #0d110f;
  --panel: #111713;
  --panel-strong: #172019;
  --line: rgba(179, 255, 207, 0.14);
  --line-strong: rgba(179, 255, 207, 0.28);
  --text: #f4fff7;
  --muted: #9aa89d;
  --faint: #647168;
  --green: #3bea8f;
  --green-strong: #17c964;
  --amber: #f3c969;
  --red: #ff6b6b;
  --radius: 8px;
  --header-height: 72px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at 22% 0%, rgba(59, 234, 143, 0.18), transparent 28rem),
    radial-gradient(circle at 85% 12%, rgba(243, 201, 105, 0.08), transparent 22rem),
    linear-gradient(180deg, #070a08 0%, #0b0f0d 44%, #070a08 100%);
  color: var(--text);
  margin: 0;
  overflow-x: hidden;
}

body::before {
  background-image: radial-gradient(rgba(244, 255, 247, 0.13) 1px, transparent 1px);
  background-size: 26px 26px;
  content: "";
  inset: 0;
  mask-image: linear-gradient(180deg, black, transparent 62%);
  opacity: 0.38;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

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

.topline {
  align-items: center;
  background: #101611;
  border-bottom: 1px solid var(--line);
  color: var(--green);
  display: flex;
  font-size: 0.88rem;
  font-weight: 750;
  height: 38px;
  justify-content: center;
  padding: 0 18px;
}

.topline a {
  border-bottom: 1px solid rgba(59, 234, 143, 0.45);
}

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

.brand,
.nav-links,
.hero-actions,
.hero-stats,
.strip,
.site-footer {
  align-items: center;
  display: flex;
}

.brand {
  font-size: 0.98rem;
  font-weight: 850;
  gap: 10px;
}

.brand-mark {
  align-items: center;
  background: linear-gradient(135deg, var(--green), #b6ffd2);
  border-radius: 7px;
  color: #041108;
  display: inline-flex;
  font-size: 0.72rem;
  font-weight: 950;
  height: 34px;
  justify-content: center;
  width: 34px;
}

.nav-links {
  color: var(--muted);
  font-size: 0.92rem;
  gap: clamp(16px, 3vw, 34px);
}

.nav-links a,
.header-action,
.resource-grid a,
.example-grid a,
.site-footer a {
  transition: border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.nav-links a:hover,
.site-footer a:hover {
  color: var(--green);
}

.header-action,
.button {
  border-radius: var(--radius);
  font-weight: 850;
}

.header-action {
  border: 1px solid var(--line-strong);
  color: var(--text);
  padding: 10px 14px;
}

.header-action:hover {
  border-color: var(--green);
  color: var(--green);
}

.hero {
  padding: clamp(60px, 8vw, 108px) clamp(20px, 5vw, 70px) clamp(64px, 8vw, 108px);
}

.hero-grid {
  align-items: center;
  display: grid;
  gap: clamp(34px, 6vw, 78px);
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.82fr);
  margin: 0 auto;
  max-width: 1220px;
}

.eyebrow {
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  margin: 0 0 18px;
  text-transform: uppercase;
}

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

h1 {
  font-size: clamp(3.4rem, 8vw, 6.9rem);
  letter-spacing: 0;
  line-height: 0.92;
  margin-bottom: 28px;
  max-width: 780px;
}

.hero-copy {
  color: var(--muted);
  font-size: clamp(1.06rem, 2vw, 1.32rem);
  line-height: 1.76;
  margin-bottom: 34px;
  max-width: 670px;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  border: 1px solid transparent;
  display: inline-flex;
  justify-content: center;
  min-height: 48px;
  padding: 13px 18px;
}

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

.button.primary {
  background: var(--green);
  color: #041108;
}

.button.primary:hover {
  background: #9bffbf;
}

.button.secondary {
  background: rgba(244, 255, 247, 0.03);
  border-color: var(--line-strong);
  color: var(--text);
}

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

.hero-stats {
  border-top: 1px solid var(--line);
  gap: clamp(22px, 4vw, 42px);
  margin: 44px 0 0;
  padding: 26px 0 0;
}

.hero-stats div {
  min-width: 96px;
}

.hero-stats dt {
  color: var(--text);
  font-size: 1.55rem;
  font-weight: 950;
}

.hero-stats dd {
  color: var(--faint);
  font-size: 0.88rem;
  margin: 4px 0 0;
}

.hero-panel {
  background:
    linear-gradient(180deg, rgba(23, 32, 25, 0.92), rgba(13, 17, 15, 0.96)),
    radial-gradient(circle at 50% 0%, rgba(59, 234, 143, 0.24), transparent 22rem);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
  overflow: hidden;
  position: relative;
}

.hero-panel::before {
  background-image: linear-gradient(rgba(179, 255, 207, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(179, 255, 207, 0.08) 1px, transparent 1px);
  background-size: 34px 34px;
  content: "";
  inset: 0;
  opacity: 0.28;
  pointer-events: none;
  position: absolute;
}

.panel-toolbar {
  align-items: center;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  gap: 8px;
  padding: 14px 16px;
  position: relative;
}

.panel-toolbar span {
  border-radius: 999px;
  display: inline-block;
  height: 10px;
  width: 10px;
}

.panel-toolbar span:nth-child(1) {
  background: var(--red);
}

.panel-toolbar span:nth-child(2) {
  background: var(--amber);
}

.panel-toolbar span:nth-child(3) {
  background: var(--green);
}

.panel-toolbar strong {
  font-size: 0.84rem;
  font-weight: 750;
  margin-left: 8px;
}

.pipeline {
  display: grid;
  gap: 12px;
  padding: 20px;
  position: relative;
}

.pipeline-node {
  background: rgba(7, 10, 8, 0.78);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 4px;
  grid-template-columns: 42px 1fr;
  padding: 15px;
  position: relative;
}

.pipeline-node.active {
  border-color: rgba(59, 234, 143, 0.7);
  box-shadow: inset 0 0 0 1px rgba(59, 234, 143, 0.12);
}

.pipeline-node span {
  color: var(--green);
  font-weight: 950;
  grid-row: span 2;
}

.pipeline-node strong {
  font-size: 1rem;
}

.pipeline-node small {
  color: var(--muted);
}

pre {
  margin: 0;
  white-space: pre-wrap;
}

.code-window,
.checklist-code {
  background: #050705;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: #c9ffd8;
  font: 0.92rem/1.7 "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.code-window {
  margin: 0 20px 20px;
  padding: 18px;
  position: relative;
}

.signal-image {
  margin: 0;
  position: relative;
}

.signal-image img {
  display: block;
  filter: saturate(0.9) contrast(1.06);
  height: 210px;
  object-fit: cover;
  opacity: 0.48;
  width: 100%;
}

.signal-image figcaption {
  bottom: 16px;
  color: var(--text);
  font-size: 0.94rem;
  font-weight: 850;
  left: 20px;
  position: absolute;
}

.strip {
  border-block: 1px solid var(--line);
  color: var(--muted);
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  padding: 18px clamp(20px, 5vw, 70px);
}

.strip span {
  background: rgba(244, 255, 247, 0.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 9px 12px;
}

.section {
  padding: clamp(72px, 10vw, 122px) clamp(20px, 5vw, 70px);
}

.section-head {
  margin: 0 auto clamp(30px, 5vw, 58px);
  max-width: 920px;
  text-align: center;
}

.section-head h2,
.cta-panel h2 {
  font-size: clamp(2rem, 5vw, 4.65rem);
  letter-spacing: 0;
  line-height: 1;
  margin-bottom: 18px;
}

.section-head p:not(.eyebrow),
.cta-panel p {
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.72;
}

.lab-grid,
.resource-grid,
.example-grid {
  display: grid;
  gap: 16px;
  margin: 0 auto;
  max-width: 1180px;
}

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

.lab-card,
.resource-grid a,
.example-grid a,
.cta-panel {
  background: rgba(17, 23, 19, 0.86);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.lab-card,
.resource-grid a {
  min-height: 230px;
  padding: 24px;
}

.lab-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lab-card:hover,
.resource-grid a:hover,
.example-grid a:hover {
  border-color: var(--green);
  transform: translateY(-4px);
}

.lab-card span,
.resource-grid span {
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 950;
  text-transform: uppercase;
}

.lab-card h3 {
  font-size: 1.45rem;
  line-height: 1.15;
  margin: 56px 0 12px;
}

.lab-card p,
.resource-grid strong {
  color: var(--muted);
  line-height: 1.65;
}

.lab-card.wide {
  grid-column: span 2;
}

.workflow-section {
  background: linear-gradient(180deg, rgba(59, 234, 143, 0.05), transparent);
  border-block: 1px solid var(--line);
}

.workflow-layout {
  align-items: stretch;
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  margin: 0 auto;
  max-width: 1180px;
}

.workflow-list {
  counter-reset: step;
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.workflow-list li {
  background: rgba(17, 23, 19, 0.86);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.workflow-list span {
  color: var(--green);
  display: block;
  font-size: 0.78rem;
  font-weight: 950;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.workflow-list strong {
  display: block;
  font-size: 1.1rem;
  line-height: 1.55;
}

.checklist-code {
  padding: 24px;
}

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

.resource-grid a {
  display: flex;
  flex-direction: column;
  gap: 52px;
}

.resource-grid strong {
  font-size: 1.22rem;
}

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

.example-grid a {
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 900;
  min-height: 128px;
  padding: 22px;
}

.contribute-section {
  padding-top: 32px;
}

.cta-panel {
  margin: 0 auto;
  max-width: 1040px;
  padding: clamp(32px, 6vw, 70px);
  text-align: center;
}

.cta-panel .hero-actions {
  justify-content: center;
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  gap: 18px;
  justify-content: space-between;
  padding: 30px clamp(20px, 5vw, 70px);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .nav-links {
    display: none;
  }

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

  .lab-grid,
  .resource-grid,
  .example-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 680px) {
  .topline {
    font-size: 0.8rem;
    text-align: center;
  }

  .site-header {
    padding: 0 16px;
  }

  .header-action {
    display: none;
  }

  .brand span:last-child {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  h1 {
    font-size: clamp(2.75rem, 16vw, 4.25rem);
  }

  .hero {
    padding-inline: 18px;
  }

  .hero-copy {
    max-width: 320px;
    word-break: break-all;
  }

  .hero-panel {
    margin-inline: -4px;
  }

  .hero-stats {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }

  .lab-grid,
  .resource-grid,
  .example-grid {
    grid-template-columns: 1fr;
  }

  .lab-card.wide {
    grid-column: auto;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
