@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&family=IBM+Plex+Sans:wght@400;500;600&family=Space+Grotesk:wght@500;600;700&display=swap');

:root {
  --ink: #0f1715;
  --ink-raised: #172422;
  --paper: #f2f5f2;
  --paper-dim: #e5eae5;
  --mint: #8fe3c0;
  --teal: #4fb6c4;
  --amber: #e8b65a;
  --on-dark: #eef3f0;
  --muted-dark: rgba(238, 243, 240, 0.62);
  --on-light: #10201c;
  --muted-light: rgba(16, 32, 28, 0.62);
  --line-dark: rgba(230, 255, 245, 0.14);
  --line-light: rgba(16, 32, 28, 0.14);
  --gradient: linear-gradient(135deg, var(--mint), var(--teal));
  --display: 'Space Grotesk', system-ui, sans-serif;
  --body: 'IBM Plex Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  background: var(--paper);
  color: var(--on-light);
  font-family: var(--body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

button {
  color: inherit;
  font: inherit;
}

a,
button {
  outline-offset: 3px;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--teal);
}

.container {
  width: min(1120px, calc(100% - 56px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--line-light);
  background: rgba(242, 245, 242, 0.92);
  backdrop-filter: blur(16px);
}

.nav {
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--on-light);
}

.brand,
.nav-links,
.nav-actions {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 600;
}

.brand img {
  display: block;
}

.nav-links {
  gap: 28px;
}

.nav-links a,
.language-button,
.github-link {
  font-family: var(--mono);
  font-size: 0.76rem;
}

.nav-links a {
  border-bottom: 1px solid transparent;
  color: var(--muted-light);
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.nav-links a:hover {
  border-color: var(--teal);
  color: var(--on-light);
}

.nav-actions {
  gap: 10px;
}

.language-button,
.github-link {
  border: 1px solid var(--line-light);
  border-radius: 999px;
  background: transparent;
  color: var(--on-light);
  cursor: pointer;
  padding: 7px 15px;
}

.language-button:hover {
  border-color: var(--teal);
  background: #fff;
  color: var(--teal);
}

.github-link {
  border-color: var(--on-light);
  background: var(--on-light);
  color: #fff;
}

.github-link:hover {
  border-color: var(--teal);
  background: var(--teal);
  color: #fff;
}

.hero {
  border-bottom: 1px solid var(--line-light);
  background: var(--paper);
  color: var(--on-light);
  padding: 58px 0 76px;
}

.hero-inner {
  display: flex;
  flex-direction: column;
}

.hero-copy {
  max-width: 880px;
}

.eyebrow {
  margin-bottom: 18px;
  color: var(--teal);
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow::before {
  color: var(--teal);
  content: '> ';
}

.quickstart-section .eyebrow {
  color: var(--teal);
}

h1,
h2,
h3 {
  font-family: var(--display);
}

h1 {
  max-width: 820px;
  margin-bottom: 22px;
  font-size: clamp(2.8rem, 5.6vw, 4.8rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.06;
}

.hero-lead {
  max-width: 68ch;
  margin-bottom: 32px;
  color: var(--muted-light);
  font-size: 1.04rem;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 11px 21px;
  font-size: 0.92rem;
  font-weight: 600;
}

.button-primary {
  background: var(--gradient);
  color: #0b1412;
}

.button-primary:hover {
  filter: brightness(1.06);
}

.button-secondary {
  border-color: var(--line-light);
  background: #fff;
  color: var(--on-light);
}

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

.terminal {
  overflow: hidden;
  border: 1px solid var(--line-dark);
  border-radius: 14px;
  background: var(--ink-raised);
}

.terminal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line-dark);
  padding: 11px 17px;
  color: var(--muted-dark);
  font-family: var(--mono);
  font-size: 0.76rem;
}

.demo-showcase {
  width: min(100%, 1000px);
  margin: 46px auto 0;
  padding: 9px;
  border: 1px solid var(--line-light);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(16, 32, 28, 0.12);
}

.demo-label {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  margin: 1px 8px 10px;
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.demo-label span:first-child {
  color: var(--teal);
  font-weight: 500;
}

.demo-label i {
  color: var(--line-light);
  font-style: normal;
}

.demo-showcase video {
  display: block;
  width: 100%;
  aspect-ratio: 1644 / 1080;
  border-radius: 15px;
  background: var(--ink);
  object-fit: contain;
}


.section {
  padding: 84px 0;
}

.section-tinted {
  background: var(--paper-dim);
}

.section-heading {
  max-width: 66ch;
  margin-bottom: 44px;
}

.section-heading.compact {
  margin-bottom: 38px;
}

.section-heading h2,
.quickstart h2 {
  margin-bottom: 14px;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

.section-heading > p:last-child,
.quickstart > div:first-child > p:last-child {
  color: var(--muted-light);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  border: 1px solid var(--line-light);
  border-left: 3px solid var(--teal);
  border-radius: 10px;
  background: #fff;
  padding: 26px 24px;
}

.feature-card:nth-child(2) { border-left-color: var(--mint); }
.feature-card:nth-child(3) { border-left-color: var(--amber); }

.feature-number {
  display: inline-block;
  margin-bottom: 14px;
  border-radius: 5px;
  background: var(--paper-dim);
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 0.7rem;
  padding: 3px 8px;
}

.feature-card h3,
.status-card h3 {
  margin-bottom: 10px;
  font-size: 1.08rem;
  font-weight: 600;
}

.feature-card p {
  color: var(--muted-light);
  font-size: 0.93rem;
}

.safety-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line-light);
  border-radius: 10px;
  background: #fff;
}

.safety-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.safety-table caption {
  padding: 14px 18px 0;
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
}

.safety-table th,
.safety-table td {
  border-bottom: 1px solid var(--line-light);
  padding: 14px 18px;
  line-height: 1.52;
  text-align: left;
  vertical-align: top;
}

.safety-table th {
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 0.71rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.safety-table td:first-child {
  font-weight: 600;
}

.safety-table tbody tr:last-child td {
  border-bottom: 0;
}

.status-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 72px;
}

.status-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.status-card {
  border: 1px solid var(--line-light);
  border-radius: 10px;
  background: #fff;
  padding: 25px;
}

.status-card.muted {
  border-style: dashed;
  background: var(--paper-dim);
}

.status-card ul {
  display: grid;
  gap: 10px;
  list-style: none;
}

.status-card li {
  display: flex;
  gap: 10px;
  color: var(--muted-light);
  font-size: 0.9rem;
}

.status-card li::before {
  color: var(--teal);
  content: '✓';
  font-family: var(--mono);
}

.status-card.muted li::before {
  color: var(--amber);
  content: '◐';
}

.download-section {
  border-top: 1px solid var(--line-light);
  background: var(--paper);
  padding: 80px 0;
}

.download-card {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 40px;
  border: 1px solid var(--line-light);
  border-radius: 16px;
  background: #fff;
  padding: 44px;
  box-shadow: 0 4px 20px rgba(15, 23, 21, 0.04);
}

.download-desc {
  margin: 12px 0 20px;
  color: var(--muted-light);
  font-size: 1rem;
  line-height: 1.6;
}

.download-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.spec-tag {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-light);
  border-radius: 6px;
  background: var(--paper);
  padding: 4px 10px;
  color: var(--on-light);
  font-family: var(--mono);
  font-size: 0.76rem;
}

.download-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

.button-large {
  padding: 14px 28px;
  font-size: 1rem;
  width: 100%;
  max-width: 320px;
}

.download-subtext {
  color: var(--muted-light);
  font-size: 0.84rem;
}

.download-subtext a {
  color: var(--teal);
  font-weight: 500;
}

.download-subtext a:hover {
  text-decoration: underline;
}

.quickstart-section {
  border-top: 1px solid var(--line-light);
  background: var(--paper-dim);
  color: var(--on-light);
}

.quickstart {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  align-items: center;
  gap: 48px;
}

.quickstart > div:first-child > p:last-child {
  color: var(--muted-light);
}

.terminal-header button {
  border: 1px solid var(--line-dark);
  border-radius: 6px;
  background: transparent;
  color: var(--on-dark);
  cursor: pointer;
  padding: 4px 10px;
}

.terminal-header button:hover {
  border-color: var(--mint);
  color: var(--mint);
}

.terminal pre {
  overflow-x: auto;
  padding: 18px;
}

.terminal code {
  color: var(--on-dark);
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.75;
}

.site-footer {
  border-top: 1px solid var(--line-light);
  background: var(--paper);
  padding: 30px 0;
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 0.78rem;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
}

.footer-brand {
  color: var(--on-light);
}

.site-footer a {
  justify-self: end;
}

.site-footer a:hover {
  color: var(--teal);
}

@media (min-width: 881px) {
  html[lang='zh-CN'] .hero h1 {
    max-width: 1000px;
    font-size: clamp(2.8rem, 5vw, 4.2rem);
  }
}

@media (max-width: 880px) {
  .status-grid,
  .quickstart,
  .download-card {
    grid-template-columns: 1fr;
  }

  .download-card {
    padding: 30px 24px;
    gap: 28px;
  }

  .nav-links {
    display: none;
  }

  .feature-grid,
  .status-columns {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 64px 0;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 28px, 1120px);
  }

  .github-link {
    display: none;
  }

  .hero {
    padding: 56px 0 66px;
  }

  h1 {
    font-size: clamp(2.55rem, 13vw, 4.2rem);
  }

  .demo-showcase {
    margin-top: 36px;
    padding: 5px;
    border-radius: 15px;
  }

  .demo-showcase video {
    border-radius: 10px;
  }

  .demo-label {
    gap: 5px;
    margin: 3px 7px 9px;
    font-size: 0.61rem;
  }

  .safety-table-wrap {
    overflow: visible;
    border: 0;
    background: transparent;
  }

  .safety-table {
    min-width: 0;
  }

  .safety-table caption,
  .safety-table thead {
    display: none;
  }

  .safety-table tbody,
  .safety-table tr,
  .safety-table td {
    display: block;
    width: 100%;
  }

  .safety-table tr {
    margin-bottom: 12px;
    border: 1px solid var(--line-light);
    border-radius: 10px;
    background: #fff;
    padding: 17px;
  }

  .safety-table tr:last-child {
    margin-bottom: 0;
  }

  .safety-table td,
  .safety-table tbody tr:last-child td {
    border: 0;
    padding: 0;
  }

  .safety-table td + td {
    margin-top: 11px;
    border-top: 1px solid var(--line-light);
    padding-top: 10px;
    color: var(--muted-light);
  }

  .safety-table td:nth-child(2)::before,
  .safety-table td:nth-child(3)::before {
    display: block;
    margin-bottom: 4px;
    color: var(--teal);
    font-family: var(--mono);
    font-size: 0.63rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
  }

  .safety-table td:nth-child(2)::before {
    content: 'Where it lives';
  }

  .safety-table td:nth-child(3)::before {
    content: 'Boundary';
  }

  html[lang='zh-CN'] .safety-table td:nth-child(2)::before {
    content: '存放位置';
  }

  html[lang='zh-CN'] .safety-table td:nth-child(3)::before {
    content: '边界';
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .site-footer a {
    justify-self: start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
