@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;700&display=swap");

:root {
  color-scheme: light;
  --bg: #ffffff;
  --paper: #f7fafb;
  --ink: #142033;
  --muted: #59677a;
  --line: #d8e1e8;
  --line-strong: #aebdca;
  --blue: #168ac4;
  --cyan: #19b9c5;
  --green: #31a852;
  --green-soft: #eaf8ef;
  --shadow: 0 18px 50px rgba(20, 32, 51, 0.09);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(22, 138, 196, 0.05), transparent 420px),
    var(--bg);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(20, 32, 51, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(20, 32, 51, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 74px;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  border-bottom: 1px solid rgba(216, 225, 232, 0.9);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
}

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

.brand-mark {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  clip-path: polygon(50% 100%, 0 0, 30% 0, 50% 45%, 70% 0, 100% 0);
  background: linear-gradient(160deg, var(--blue), var(--cyan));
  color: transparent;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.8vw, 36px);
  color: #25354b;
  font-size: 14px;
  font-weight: 500;
}

.nav a {
  padding: 10px 0;
  border-bottom: 2px solid transparent;
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

.section-pad {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 58px 0;
}

.hero {
  min-height: calc(100vh - 74px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(340px, 0.72fr);
  align-items: center;
  gap: clamp(40px, 6vw, 88px);
  padding-top: 78px;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 0;
  color: #172239;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 1.05;
  letter-spacing: 0;
  font-weight: 800;
}

.hero-copy p {
  max-width: 690px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.75;
}

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

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

.button.primary {
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
  box-shadow: 0 10px 24px rgba(22, 138, 196, 0.22);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.7);
}

.hero-points {
  display: grid;
  gap: 20px;
}

.hero-points article {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 16px;
  align-items: start;
}

.hero-points svg {
  width: 38px;
  height: 38px;
  color: var(--blue);
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.hero-points article:nth-child(3) svg,
.hero-points article:nth-child(4) svg {
  color: var(--green);
}

.hero-points h2,
.hero-points p,
.section-heading h2,
.section-heading p {
  margin: 0;
}

.hero-points h2 {
  font-size: 18px;
  line-height: 1.25;
}

.hero-points p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(300px, 0.55fr);
  gap: 32px;
  align-items: end;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.section-heading.narrow {
  grid-template-columns: minmax(0, 720px);
}

.section-heading h2 {
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.15;
  letter-spacing: 0;
}

.section-heading p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.flow {
  display: grid;
  grid-template-columns:
    minmax(150px, 1fr) 34px minmax(150px, 1fr) 34px minmax(170px, 1.1fr)
    34px minmax(150px, 1fr) 34px minmax(150px, 1fr);
  gap: 0;
  align-items: center;
  margin-top: 36px;
}

.flow-node {
  min-height: 258px;
  padding: 22px 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(247, 250, 251, 0.74)),
    #fff;
  box-shadow: 0 8px 24px rgba(20, 32, 51, 0.04);
}

.flow-node.blue {
  border-color: rgba(22, 138, 196, 0.55);
}

.flow-node.green {
  border-color: rgba(49, 168, 82, 0.62);
}

.flow-node.core {
  border-color: rgba(25, 185, 197, 0.72);
  background:
    linear-gradient(180deg, rgba(25, 185, 197, 0.07), rgba(255, 255, 255, 0.92)),
    #fff;
}

.node-number {
  display: inline-grid;
  place-items: center;
  min-width: 28px;
  height: 28px;
  margin-bottom: 14px;
  border: 1px solid currentColor;
  border-radius: 6px;
  color: var(--blue);
  font-family:
    "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
}

.flow-node h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.25;
}

.flow-node ul,
.principles ul,
.wave-line ul,
.deploy-steps ol {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.flow-node li,
.principles li,
.wave-line li {
  position: relative;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.flow-node li + li,
.principles li + li,
.wave-line li + li {
  margin-top: 10px;
}

.flow-node li::before,
.principles li::before,
.wave-line li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 6px;
  height: 6px;
  border: 1px solid var(--blue);
  transform: translateY(-50%) rotate(45deg);
}

.flow-arrow {
  position: relative;
  height: 2px;
  background: #26344b;
}

.flow-arrow::after {
  content: "";
  position: absolute;
  right: -1px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-top: 2px solid #26344b;
  border-right: 2px solid #26344b;
  transform: translateY(-50%) rotate(45deg);
}

.flow-arrow.bidirectional::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-left: 2px solid #26344b;
  border-bottom: 2px solid #26344b;
  transform: translateY(-50%) rotate(45deg);
}

.governance-rail {
  width: min(820px, 100%);
  margin: 26px auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  padding: 18px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
}

.governance-rail div {
  display: grid;
  gap: 6px;
}

.governance-rail strong {
  font-size: 14px;
}

.governance-rail span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.principles {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  margin-top: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.principles article {
  min-height: 306px;
  padding: 28px 22px;
  border-right: 1px solid var(--line);
}

.principles article:last-child {
  border-right: 0;
  background: linear-gradient(140deg, #fff, var(--green-soft));
}

.principles h3 {
  margin: 0;
  color: var(--blue);
  font-size: 17px;
}

.principles article:nth-child(4) h3,
.principles article:nth-child(5) h3 {
  color: var(--green);
}

.principles p {
  margin: 12px 0 0;
  color: #2f4056;
  font-size: 14px;
  line-height: 1.52;
}

.principles code,
.deploy-grid code {
  font-size: 0.92em;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.wave-line {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
  margin-top: 40px;
}

.wave-line::before {
  content: "";
  position: absolute;
  top: 35px;
  left: 9%;
  right: 9%;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--cyan), var(--green));
}

.wave-line article {
  position: relative;
  padding: 0 2px;
  background: transparent;
}

.wave-line span {
  position: relative;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  min-width: 70px;
  height: 70px;
  border: 1px solid currentColor;
  border-radius: var(--radius);
  background: #fff;
  color: var(--blue);
  font-family:
    "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 18px;
  font-weight: 700;
}

.wave-line article:nth-child(n + 3) span {
  color: var(--green);
}

.wave-line h3 {
  margin: 22px 0 0;
  font-size: 19px;
}

.wave-line strong {
  display: inline-flex;
  margin-top: 18px;
  color: var(--blue);
  font-size: 13px;
}

.prompt-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  margin-top: 34px;
}

.download-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 34px;
}

.download-list a {
  display: grid;
  gap: 9px;
  min-height: 134px;
  padding: 24px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(145deg, #fff, #f5fbfc);
  box-shadow: 0 8px 24px rgba(20, 32, 51, 0.04);
}

.download-list a::before {
  content: "MD";
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 30px;
  border: 1px solid var(--green);
  border-radius: 6px;
  color: var(--green);
  font-family:
    "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
}

.download-list strong {
  font-size: 17px;
}

.download-list span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.download-list a:hover,
.download-list a:focus-visible {
  border-color: var(--green);
  transform: translateY(-2px);
}

.prompt-card {
  position: relative;
  min-height: 310px;
  padding: 24px 22px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 8px 26px rgba(20, 32, 51, 0.04);
}

.prompt-card::before {
  content: ">";
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin-bottom: 22px;
  border: 1px solid var(--blue);
  border-radius: 6px;
  color: var(--blue);
  font-family:
    "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 20px;
  font-weight: 700;
}

.prompt-card h3 {
  margin: 0;
  color: var(--blue);
  font-size: 16px;
}

.prompt-card p {
  min-height: 138px;
  margin: 16px 0 0;
  padding: 14px;
  border: 1px solid rgba(216, 225, 232, 0.9);
  border-radius: 6px;
  background: var(--paper);
  color: #314257;
  font-size: 13px;
  line-height: 1.58;
}

.copy-button {
  position: absolute;
  right: 14px;
  top: 14px;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  font: 700 12px/1 Inter, sans-serif;
  cursor: pointer;
}

.copy-button:hover,
.copy-button:focus-visible {
  border-color: var(--blue);
  color: var(--blue);
}

.deploy-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(360px, 0.62fr);
  gap: 24px;
  margin-top: 34px;
}

.deploy-steps,
.deploy-code {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.deploy-steps h3,
.deploy-code h3 {
  margin: 0;
  font-size: 18px;
}

.deploy-steps li {
  padding-left: 10px;
  margin-left: 20px;
  color: #314257;
  font-size: 14px;
  line-height: 1.75;
}

.deploy-steps li + li {
  margin-top: 10px;
}

.deploy-code pre {
  overflow: auto;
  margin: 18px 0 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f5f8fb;
  color: #172239;
  font-size: 13px;
  line-height: 1.65;
}

.footer {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 28px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 13px;
}

@media (max-width: 1080px) {
  .hero,
  .section-heading,
  .deploy-grid {
    grid-template-columns: 1fr;
  }

  .flow {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .flow-arrow {
    width: 2px;
    height: 28px;
    justify-self: center;
  }

  .flow-arrow::after {
    right: auto;
    left: 50%;
    top: auto;
    bottom: -1px;
    transform: translateX(-50%) rotate(135deg);
  }

  .flow-arrow.bidirectional::before {
    left: 50%;
    top: -1px;
    transform: translateX(-50%) rotate(135deg);
  }

  .flow-node {
    min-height: auto;
  }

  .principles,
  .download-list,
  .prompt-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .principles article:nth-child(2n) {
    border-right: 0;
  }

  .wave-line {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .nav {
    width: 100%;
    overflow-x: auto;
    gap: 22px;
    padding-bottom: 2px;
  }

  .section-pad {
    width: min(100% - 28px, 1180px);
    padding: 42px 0;
  }

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

  .hero-copy h1 {
    font-size: clamp(34px, 12vw, 50px);
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .governance-rail,
  .principles,
  .download-list,
  .wave-line,
  .prompt-grid {
    grid-template-columns: 1fr;
  }

  .principles article,
  .principles article:nth-child(2n) {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .principles article:last-child {
    border-bottom: 0;
  }

  .wave-line::before {
    display: none;
  }

  .prompt-card {
    min-height: auto;
  }

  .prompt-card p {
    min-height: auto;
  }

  .deploy-code pre {
    font-size: 12px;
  }

  .footer {
    width: min(100% - 28px, 1180px);
    flex-direction: column;
  }
}
