:root {
  color-scheme: dark;
  --bg: #070b12;
  --bg-soft: #0a111d;
  --panel: #0e1728;
  --panel-2: #111c30;
  --border: rgba(148, 163, 184, 0.15);
  --border-strong: rgba(148, 163, 184, 0.26);
  --text: #e8eef8;
  --muted: #94a4bb;
  --faint: #64748b;
  --accent: #ffc857;
  --accent-soft: #ffe3a3;
  --accent-2: #65d6ff;
  --accent-3: #8ef0b6;
  --danger: #ff6b6b;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.45);
  --radius: 18px;
  --max: 1160px;
  --font: "Inter", "Segoe UI", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    sans-serif;
  --mono: "JetBrains Mono", "SFMono-Regular", "Cascadia Code", Consolas, "Liberation Mono",
    monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(1100px 650px at 10% -10%, rgba(101, 214, 255, 0.13), transparent 62%),
    radial-gradient(900px 560px at 94% 0%, rgba(255, 200, 87, 0.1), transparent 58%),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.035) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, transparent 72%);
  mask-image: linear-gradient(to bottom, #000 0%, transparent 72%);
}

.site-header,
main,
.site-footer {
  position: relative;
  z-index: 1;
}

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

h1,
h2,
h3 {
  font-weight: 650;
  letter-spacing: -0.035em;
}

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

svg {
  display: block;
}

code,
pre {
  font-family: var(--mono);
}

::selection {
  background: rgba(255, 200, 87, 0.3);
  color: #fff;
}

[hidden] {
  display: none !important;
}

.shell {
  width: min(calc(100% - 48px), var(--max));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #161006;
  font-weight: 700;
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--border);
  background: rgba(7, 11, 18, 0.76);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 1.18rem;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.brand-mark {
  width: 25px;
  height: 25px;
  fill: var(--accent);
  filter: drop-shadow(0 0 14px rgba(255, 200, 87, 0.32));
}

.nav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 0.86rem;
  font-weight: 550;
  color: var(--muted);
}

.nav a {
  transition: color 140ms ease;
}

.nav a:hover {
  color: var(--text);
}

.nav-github {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.025);
}

.nav-github svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.nav-github:hover {
  border-color: rgba(255, 200, 87, 0.45);
  color: var(--accent-soft);
}

/* Hero */

.hero {
  padding: 96px 0 88px;
  overflow: clip;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
  gap: clamp(42px, 6vw, 84px);
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(14, 23, 40, 0.62);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.01em;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-3);
  box-shadow: 0 0 0 4px rgba(142, 240, 182, 0.12);
}

.hero h1 {
  margin: 26px 0 24px;
  font-size: clamp(3.15rem, 6.5vw, 5.65rem);
  line-height: 0.94;
  letter-spacing: -0.06em;
  font-weight: 650;
}

.gradient-text {
  background: linear-gradient(105deg, var(--accent) 0%, #ffe8b3 42%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  max-width: 620px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.72;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.2;
  transition:
    transform 150ms ease,
    background 150ms ease,
    border-color 150ms ease,
    color 150ms ease;
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn-primary {
  background: var(--accent);
  color: #171006;
  box-shadow: 0 12px 34px rgba(255, 200, 87, 0.18);
}

.btn-primary:hover {
  background: #ffd47a;
  transform: translateY(-1px);
}

.btn-ghost {
  border-color: var(--border-strong);
  background: rgba(14, 23, 40, 0.5);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: rgba(255, 200, 87, 0.42);
  background: rgba(255, 200, 87, 0.06);
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
  color: var(--faint);
  font-size: 0.8rem;
}

.hero-points li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-points li::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-2);
}

.hero-panel {
  position: relative;
  min-width: 0;
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: -18% -8%;
  z-index: -1;
  background: radial-gradient(circle, rgba(101, 214, 255, 0.14), transparent 62%);
  filter: blur(20px);
}

.terminal {
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  background: linear-gradient(180deg, #0d1728, #080e18);
  box-shadow: var(--shadow);
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.terminal-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #2a3850;
}

.terminal-dot.is-red {
  background: var(--danger);
}

.terminal-dot.is-yellow {
  background: var(--accent);
}

.terminal-dot.is-green {
  background: var(--accent-3);
}

.terminal-title {
  margin-left: auto;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.7rem;
}

.terminal-body {
  margin: 0;
  padding: 24px;
  overflow-x: auto;
  color: #d6e2f3;
  font-family: var(--mono);
  font-size: 0.84rem;
  line-height: 1.85;
}

.cmd-prompt {
  color: var(--accent);
}

.cmd-muted {
  color: #62748e;
}

.cmd-success {
  color: var(--accent-3);
}

.cmd-link {
  color: var(--accent-2);
}

.hero-stamp {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(14, 23, 40, 0.55);
}

.hero-stamp > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.stamp-label {
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-stamp strong {
  font-size: 0.88rem;
  font-weight: 600;
}

.stamp-arrow {
  color: var(--faint);
  font-family: var(--mono);
}

/* Sections */

.section {
  padding: 100px 0;
}

.section-alt {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(12, 20, 35, 0.48), rgba(7, 11, 18, 0));
}

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

.kicker {
  margin-bottom: 12px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.section-heading h2 {
  margin-bottom: 16px;
  font-size: clamp(2rem, 3.8vw, 3rem);
  line-height: 1.05;
}

.section-heading > p:last-child {
  max-width: 650px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

/* Features */

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

.feature-card {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(17, 28, 48, 0.72), rgba(10, 16, 28, 0.52));
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.feature-card:hover {
  border-color: rgba(101, 214, 255, 0.3);
  background: linear-gradient(180deg, rgba(20, 34, 58, 0.78), rgba(10, 16, 28, 0.56));
  transform: translateY(-2px);
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 20px;
  border: 1px solid rgba(101, 214, 255, 0.16);
  border-radius: 11px;
  background: rgba(101, 214, 255, 0.07);
}

.feature-icon svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: var(--accent-2);
  stroke-width: 1.55;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-card h3 {
  margin-bottom: 8px;
  font-size: 1.02rem;
}

.feature-card p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.66;
}

/* Architecture */

.architecture-card {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(10, 17, 30, 0.52);
}

.arch-flow {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(7, 11, 18, 0.6);
}

.arch-node {
  flex: 1;
  min-width: 0;
  padding: 14px 8px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: rgba(17, 28, 48, 0.72);
  text-align: center;
}

.arch-node span {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
}

.arch-node small {
  display: block;
  margin-top: 4px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.66rem;
  line-height: 1.4;
}

.arch-node.is-rust {
  border-color: rgba(255, 200, 87, 0.3);
}

.arch-node.is-rust small {
  color: var(--accent);
}

.arch-node.is-lua {
  border-color: rgba(101, 214, 255, 0.3);
}

.arch-node.is-lua small {
  color: var(--accent-2);
}

.arch-arrow {
  flex: none;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.9rem;
}

.layer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.layer {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(17, 28, 48, 0.34);
}

.layer-index {
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.68rem;
}

.layer h3 {
  margin: 8px 0 6px;
  font-size: 0.96rem;
}

.layer p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.83rem;
  line-height: 1.6;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(28px, 4vw, 52px);
  align-items: center;
  margin-top: 48px;
}

.split-copy h3 {
  margin-bottom: 14px;
  font-size: 1.35rem;
}

.split-copy p {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.72;
}

.split-copy code,
.field-note code {
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.045);
  color: #dbe7f7;
  font-family: var(--mono);
  font-size: 0.84em;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 600;
}

.text-link:hover {
  color: var(--accent-soft);
}

.code-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #080e18;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.code-card-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.7rem;
}

.code-lang {
  color: var(--accent-3);
  letter-spacing: 0.08em;
}

.code-block {
  margin: 0;
  padding: 22px;
  overflow-x: auto;
  color: #d6e2f3;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.82;
  tab-size: 2;
}

.tok-comment {
  color: #61738d;
}

.tok-kw {
  color: #ff9e64;
}

.tok-fn {
  color: var(--accent-2);
}

.tok-str {
  color: #a8e6a3;
}

/* Performance */

.benchmark-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.benchmark-stat {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(18, 30, 50, 0.72), rgba(10, 17, 29, 0.5));
}

.benchmark-stat span {
  display: block;
  margin-bottom: 10px;
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.benchmark-stat strong {
  display: block;
  margin-bottom: 6px;
  color: var(--text);
  font-family: var(--mono);
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  font-weight: 600;
  letter-spacing: -0.04em;
}

.benchmark-stat small {
  color: var(--muted);
  font-size: 0.78rem;
}

.benchmark-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(10, 17, 29, 0.55);
}

.benchmark-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.benchmark-table th,
.benchmark-table td {
  padding: 13px 18px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: 0.86rem;
}

.benchmark-table th {
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.benchmark-table td {
  color: var(--muted);
}

.benchmark-table td:first-child {
  color: var(--text);
  font-weight: 600;
}

.benchmark-table td code {
  color: var(--accent-2);
  font-size: 0.8rem;
}

.benchmark-table .num {
  text-align: right;
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.benchmark-table tbody tr:hover {
  background: rgba(101, 214, 255, 0.04);
}

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

.benchmark-note {
  margin: 14px 0 0;
  color: var(--faint);
  font-size: 0.78rem;
  line-height: 1.65;
}

/* Install */

.install-card {
  max-width: 900px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(17, 28, 48, 0.85), rgba(8, 14, 24, 0.8));
  box-shadow: var(--shadow);
}

.os-tabs {
  display: flex;
  gap: 4px;
  padding: 10px 10px 0;
  border-bottom: 1px solid var(--border);
  background: rgba(7, 11, 18, 0.5);
}

.os-tab {
  padding: 10px 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 8px 8px 0 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 600;
}

.os-tab:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.os-tab.is-active {
  border-bottom-color: var(--accent);
  background: rgba(255, 200, 87, 0.05);
  color: var(--accent);
}

.install-pane {
  padding: 24px;
}

.command-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #050a12;
}

.command-row code {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  color: #e8eef8;
  font-family: var(--mono);
  font-size: 0.82rem;
  white-space: nowrap;
}

.copy-btn {
  flex: none;
  padding: 7px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 650;
  transition:
    background 140ms ease,
    border-color 140ms ease,
    color 140ms ease;
}

.copy-btn:hover {
  border-color: rgba(255, 200, 87, 0.45);
  color: var(--text);
}

.copy-btn.is-copied {
  border-color: var(--accent-3);
  background: var(--accent-3);
  color: #08120d;
}

.field-note {
  margin: 12px 0 0;
  color: var(--faint);
  font-size: 0.78rem;
  line-height: 1.6;
}

.install-next {
  padding: 20px 24px 24px;
  border-top: 1px solid var(--border);
}

.install-next > span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.8rem;
}

.command-row-compact code {
  font-size: 0.8rem;
}

.platform-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 900px;
  margin-top: 16px;
}

.platform-grid div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(14, 23, 40, 0.5);
}

.platform-grid strong {
  font-size: 0.84rem;
}

.platform-grid span {
  color: var(--faint);
  font-size: 0.76rem;
}

.install-footnote {
  max-width: 900px;
  margin: 18px 0 0;
  color: var(--faint);
  font-size: 0.78rem;
}

.install-footnote a {
  color: var(--accent);
}

.install-footnote a:hover {
  color: var(--accent-soft);
}

/* Docs */

.docs-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.doc-card {
  position: relative;
  display: block;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(14, 23, 40, 0.55);
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.doc-card:hover {
  border-color: rgba(255, 200, 87, 0.35);
  background: rgba(20, 32, 54, 0.65);
  transform: translateY(-2px);
}

.doc-number {
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.68rem;
}

.doc-card h3 {
  margin: 10px 0 8px;
  font-size: 0.98rem;
}

.doc-card p {
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.6;
}

.doc-arrow {
  position: absolute;
  right: 18px;
  bottom: 15px;
  color: var(--faint);
}

.doc-card:hover .doc-arrow {
  color: var(--accent);
}

.docs-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 24px;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: linear-gradient(110deg, rgba(255, 200, 87, 0.075), rgba(101, 214, 255, 0.055));
}

.docs-cta h3 {
  margin-bottom: 4px;
  font-size: 1.08rem;
}

.docs-cta p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.docs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* Footer */

.site-footer {
  padding: 48px 0 24px;
  border-top: 1px solid var(--border);
  background: rgba(5, 9, 16, 0.6);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 32px;
}

.footer-brand p {
  margin: 12px 0 0;
  color: var(--faint);
  font-size: 0.83rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px;
  color: var(--muted);
  font-size: 0.84rem;
}

.footer-links a {
  transition: color 140ms ease;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: 0.74rem;
}

/* Responsive */

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

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

@media (max-width: 900px) {
  .hero {
    padding: 72px 0 64px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .hero-panel {
    max-width: 620px;
  }

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

  .arch-flow {
    flex-wrap: wrap;
  }

  .arch-node {
    flex: 1 1 42%;
  }

  .arch-arrow {
    display: none;
  }
}

@media (max-width: 760px) {
  .shell {
    width: min(calc(100% - 32px), var(--max));
  }

  .hero h1 {
    font-size: clamp(2.6rem, 8.5vw, 3.4rem);
  }

  .header-inner {
    min-height: 64px;
  }

  .nav {
    gap: 14px;
  }

  .nav a:not(.nav-github) {
    display: none;
  }

  .section {
    padding: 72px 0;
  }

  .section-heading {
    margin-bottom: 32px;
  }

  .feature-grid,
  .benchmark-grid,
  .layer-grid,
  .platform-grid,
  .docs-grid {
    grid-template-columns: 1fr;
  }

  .architecture-card {
    padding: 18px;
  }

  .arch-flow {
    padding: 12px;
  }

  .arch-node {
    flex-basis: 100%;
  }

  .docs-cta {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-inner,
  .footer-bottom {
    flex-direction: column;
    gap: 18px;
  }
}

@media (max-width: 540px) {
  .hero h1 {
    font-size: clamp(2.2rem, 9.5vw, 2.8rem);
    line-height: 1;
  }

  .hero-actions .btn {
    flex: 1;
  }

  .hero-stamp {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .stamp-arrow {
    transform: rotate(90deg);
  }

  .install-pane,
  .install-next {
    padding: 18px;
  }

  .os-tab {
    flex: 1;
    padding-inline: 10px;
  }

  .command-row {
    align-items: stretch;
    flex-direction: column;
  }

  .copy-btn {
    align-self: flex-end;
  }

  .command-row code {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

@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;
  }
}
