:root {
  color-scheme: light;
  --canvas: #f7f8f7;
  --surface: #ffffff;
  --ink: #151817;
  --muted: #59635d;
  --line: #d9dfd7;
  --line-strong: #b7c0b8;
  --glass-surface: rgba(255, 255, 255, 0.62);
  --glass-surface-strong: rgba(255, 255, 255, 0.78);
  --glass-edge: rgba(255, 255, 255, 0.72);
  --glass-line: rgba(21, 24, 23, 0.12);
  --glass-highlight: rgba(255, 255, 255, 0.88);
  --blue: #1f6feb;
  --blue-dark: #174ea6;
  --green: #2d9b57;
  --amber: #9a650c;
  --red: #bd3f36;
  --resource-blue-ink: oklch(38% 0.17 257);
  --resource-blue-muted: oklch(36% 0.075 257);
  --resource-blue-line: oklch(80% 0.065 257);
  --resource-blue-top: oklch(98% 0.018 257);
  --resource-blue-surface: oklch(95% 0.034 257);
  --resource-green-ink: oklch(35% 0.13 150);
  --resource-green-muted: oklch(34% 0.07 150);
  --resource-green-line: oklch(79% 0.07 150);
  --resource-green-top: oklch(98% 0.02 150);
  --resource-green-surface: oklch(94% 0.042 150);
  --resource-amber-ink: oklch(36% 0.105 76);
  --resource-amber-muted: oklch(35% 0.07 76);
  --resource-amber-line: oklch(80% 0.075 76);
  --resource-amber-top: oklch(98% 0.02 76);
  --resource-amber-surface: oklch(94% 0.046 76);
  --resource-red-ink: oklch(36% 0.145 28);
  --resource-red-muted: oklch(35% 0.08 28);
  --resource-red-line: oklch(80% 0.062 28);
  --resource-red-top: oklch(98% 0.018 28);
  --resource-red-surface: oklch(95% 0.034 28);
  --terminal: #111716;
  --terminal-soft: #17211f;
  --radius: 8px;
  --shadow: 0 6px 8px rgba(21, 24, 23, 0.1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",
    monospace;
  --sans: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  --gutter: clamp(1rem, 4vw, 4rem);
  --content: 1180px;
  --space-2xs: 0.5rem;
  --space-xs: 0.75rem;
  --space-sm: 1rem;
  --space-md: clamp(1.25rem, 2vw, 1.75rem);
  --space-lg: clamp(2rem, 4vw, 3.5rem);
  --space-xl: clamp(3.5rem, 7vw, 6rem);
}

* {
  box-sizing: border-box;
}

html {
  scroll-padding-top: 7rem;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--sans);
  text-rendering: optimizeLegibility;
}

body {
  min-width: 320px;
  margin: 0;
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.88) 0,
      rgba(247, 248, 247, 0.56) 24rem,
      rgba(239, 243, 241, 0.84) 100%
    ),
    linear-gradient(90deg, rgba(21, 24, 23, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(21, 24, 23, 0.035) 1px, transparent 1px),
    var(--canvas);
  background-size:
    auto,
    36px 36px,
    36px 36px,
    auto;
}

body::selection {
  color: #ffffff;
  background: var(--blue-dark);
}

main {
  overflow: clip;
}

a {
  color: inherit;
}

:where(a, button, summary) {
  transition:
    background-color 180ms var(--ease-out),
    border-color 180ms var(--ease-out),
    color 180ms var(--ease-out),
    transform 180ms var(--ease-out);
}

button {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

code,
pre,
.brand,
.site-nav,
.hero-command,
.hero-note,
.button,
.artifact-titlebar,
.artifact-terminal,
.artifact-footer,
.agent-rules,
.recovery-row,
.step-number,
.runbook-list code,
.source-note,
.panel-bar,
.resource-coverage,
.resource-links,
.safety-list,
.docs-grid,
.doc-links,
.site-footer {
  font-family: var(--mono);
}

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

h1 {
  max-width: 9ch;
  margin-bottom: 1rem;
  color: var(--ink);
  font-size: clamp(3.35rem, 9vw, 6rem);
  line-height: 0.92;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

h2 {
  margin-bottom: 0.9rem;
  font-size: clamp(2rem, 5vw, 3.35rem);
  line-height: 1;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

h3 {
  margin-bottom: 0.65rem;
  font-size: 1.08rem;
  line-height: 1.25;
}

p {
  color: var(--muted);
  line-height: 1.65;
  text-wrap: pretty;
}

p code {
  color: var(--blue-dark);
  font-family: var(--mono);
  font-size: 0.92em;
  font-variant-ligatures: none;
}

:where(a, button, summary):focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.command-loop,
.agent-section,
.schema-section,
.output-section,
.safety-section,
.install-section,
.docs-section,
.site-footer {
  width: min(calc(100% - (var(--gutter) * 2)), var(--content));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  width: 100%;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  margin: 0;
  padding-block: 0.55rem;
  padding-inline: max(var(--gutter), calc((100vw - var(--content)) / 2));
  border-block: 0 1px;
  border-inline: 0;
  border-style: solid;
  border-color: var(--glass-edge);
  border-radius: 0;
  background:
    linear-gradient(
      180deg,
      var(--glass-surface-strong),
      var(--glass-surface)
    );
  box-shadow:
    var(--shadow),
    inset 0 1px 0 var(--glass-highlight);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  backdrop-filter: saturate(160%) blur(18px);
}

.brand {
  display: grid;
  gap: 0.1rem;
  min-width: 12rem;
  text-decoration: none;
}

.brand-mark {
  font-size: 1.55rem;
  font-weight: 800;
}

.brand-line {
  color: var(--muted);
  font-size: 0.76rem;
}

.site-nav {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.25rem;
  font-size: 0.78rem;
  font-weight: 700;
}

.site-nav > a,
.nav-more summary {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 0.7rem 0.78rem;
  border-radius: 6px;
  color: var(--muted);
  text-decoration: none;
}

.nav-more {
  position: relative;
}

.nav-more summary {
  gap: 0.42rem;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.nav-more summary::-webkit-details-marker {
  display: none;
}

.nav-more summary::after {
  content: "+";
  color: var(--blue-dark);
  font-weight: 800;
}

.nav-more[open] summary::after {
  content: "-";
}

.site-nav > a:hover,
.nav-more summary:hover,
.nav-more[open] summary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
}

.nav-menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 0.42rem);
  right: 0;
  display: grid;
  width: min(16rem, calc(100vw - 2rem));
  gap: 1px;
  overflow: hidden;
  padding: 0.35rem;
  border: 1px solid var(--glass-edge);
  border-radius: calc(var(--radius) + 2px);
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.995),
      rgba(247, 248, 247, 0.98)
    );
  box-shadow:
    var(--shadow),
    inset 0 1px 0 var(--glass-highlight);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  backdrop-filter: saturate(160%) blur(18px);
}

.nav-menu a {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  padding: 0.62rem 0.68rem;
  border-radius: 6px;
  color: var(--muted);
  text-decoration: none;
}

.nav-menu a:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
}

.nav-menu-github {
  display: none !important;
}

.site-nav .nav-strong {
  color: #ffffff;
  background: linear-gradient(180deg, #202523, var(--ink));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.site-nav .nav-strong:hover {
  color: #ffffff;
  background: var(--blue-dark);
}

.hero {
  position: relative;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background:
    linear-gradient(
      118deg,
      rgba(31, 111, 235, 0.1) 0,
      rgba(255, 255, 255, 0) 34%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.64),
      rgba(255, 255, 255, 0.36)
    );
}

.hero-inner {
  display: grid;
  width: min(calc(100% - (var(--gutter) * 2)), var(--content));
  grid-template-columns: minmax(17rem, 0.72fr) minmax(24rem, 1.28fr);
  gap: clamp(1.25rem, 4vw, 4rem);
  align-items: center;
  margin-inline: auto;
  padding-block: clamp(1.75rem, 4vw, 4rem);
}

.hero-copy {
  display: grid;
  min-width: 0;
  align-content: start;
}

.hero-text {
  max-width: 36rem;
  margin-bottom: var(--space-md);
  color: var(--muted);
  font-size: 1.2rem;
}

.hero-command {
  display: inline-grid;
  max-width: min(100%, 35rem);
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: var(--space-sm);
  padding: 0.38rem;
  border: 1px solid rgba(234, 244, 239, 0.16);
  border-radius: var(--radius);
  color: #eaf4ef;
  background:
    linear-gradient(180deg, rgba(31, 42, 39, 0.96), rgba(17, 23, 22, 0.95)),
    var(--terminal);
  box-shadow:
    0 4px 8px rgba(21, 24, 23, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.hero-command .prompt {
  padding-left: 0.45rem;
  color: #86d99f;
  font-weight: 800;
}

.hero-command code {
  min-width: 0;
  font-size: 0.86rem;
  font-variant-ligatures: none;
  overflow: hidden;
  overflow-wrap: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-command button,
.panel-bar button {
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 800;
}

.hero-command button {
  grid-column: auto;
  width: auto;
  min-width: 7rem;
  min-height: 36px;
  padding-inline: 0.72rem;
  border: 1px solid rgba(234, 244, 239, 0.28);
  color: #eaf4ef;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.panel-bar button {
  position: relative;
  min-width: 4.65rem;
  min-height: 34px;
  padding: 0.42rem 0.64rem;
  border: 1px solid rgba(234, 244, 239, 0.22);
  color: #eaf4ef;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  line-height: 1;
}

.panel-bar button::before {
  position: absolute;
  inset: -5px 0;
  content: "";
}

.hero-note {
  max-width: 34rem;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.55;
}

.hero-command button:hover {
  background: var(--blue-dark);
}

.panel-bar button:hover {
  border-color: rgba(234, 244, 239, 0.4);
  background: rgba(255, 255, 255, 0.14);
}

.hero-command button:active,
.panel-bar button:active,
.button:active,
.site-nav a:active {
  transform: translateY(1px);
}

:where(.hero-command button, .panel-bar button)[data-copy-state="copied"] {
  color: #ffffff;
  background: var(--green);
}

:where(.hero-command button, .panel-bar button)[data-copy-state="fallback"] {
  color: var(--ink);
  background: #f1c84c;
}

.panel-bar button[data-copy-state] {
  border-color: transparent;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-bottom: var(--space-sm);
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0.78rem 0.96rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.button.primary {
  color: #ffffff;
  background: linear-gradient(180deg, #202523, var(--ink));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.button.primary:hover {
  background: var(--blue-dark);
}

.button.secondary {
  color: var(--blue-dark);
  border: 1px solid var(--glass-edge);
  background:
    linear-gradient(
      180deg,
      var(--glass-surface-strong),
      var(--glass-surface)
    );
  box-shadow: inset 0 1px 0 var(--glass-highlight);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  backdrop-filter: saturate(150%) blur(14px);
}

.button.secondary:hover {
  color: var(--ink);
  border-color: var(--blue-dark);
  background: #ffffff;
}

.kitout-artifact {
  display: grid;
  min-width: 0;
  gap: var(--space-xs);
  margin: 0;
}

.artifact-shell {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(
      180deg,
      var(--glass-surface-strong),
      rgba(255, 255, 255, 0.42)
    );
  box-shadow:
    var(--shadow),
    inset 0 1px 0 var(--glass-highlight);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  backdrop-filter: saturate(160%) blur(18px);
}

.artifact-titlebar {
  display: flex;
  min-height: 2.75rem;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.96),
      rgba(247, 248, 247, 0.84)
    );
  font-size: 0.84rem;
  font-weight: 800;
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  backdrop-filter: saturate(150%) blur(14px);
}

.artifact-titlebar strong {
  padding: 0.2rem 0.45rem;
  border: 1px solid rgba(45, 155, 87, 0.24);
  border-radius: 999px;
  color: #176b38;
  background: rgba(45, 155, 87, 0.1);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.artifact-terminal {
  min-width: 0;
  background: var(--terminal);
}

.artifact-terminal pre {
  min-height: 0;
  padding: 1.05rem 1.1rem 1.15rem;
  color: #eaf4ef;
  background: var(--terminal);
  font-size: 0.875rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.artifact-terminal code {
  display: block;
  min-width: 0;
  white-space: normal;
}

.artifact-terminal .terminal-line {
  display: block;
  overflow-wrap: anywhere;
}

.artifact-terminal .terminal-gap {
  display: block;
  height: 0.95rem;
}

.artifact-footer {
  display: flex;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  background: rgba(248, 250, 248, 0.72);
}

.artifact-footer span {
  flex: 1 1 18rem;
  padding: 0.58rem 0.75rem;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 800;
}

.artifact-footer span + span {
  border-left: 1px solid var(--line);
}

.kitout-artifact figcaption {
  max-width: 68ch;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.875rem;
  line-height: 1.55;
}

.command-loop,
.agent-section,
.schema-section,
.output-section,
.safety-section,
.install-section,
.docs-section {
  padding-block: var(--space-xl);
}

.command-loop {
  padding-block-start: var(--space-lg);
}

.section-intro {
  display: grid;
  grid-template-columns: minmax(16rem, 0.62fr) minmax(0, 0.9fr);
  gap: var(--space-lg);
  align-items: end;
  margin-bottom: var(--space-md);
}

.section-intro h2 {
  max-width: 13ch;
  margin-bottom: 0;
}

.section-intro p {
  max-width: 42rem;
  margin-bottom: 0;
  font-size: 1.05rem;
}

.section-intro.compact {
  align-items: start;
  grid-template-columns: minmax(0, 44rem);
}

.section-intro.compact h2 {
  max-width: 14ch;
}

.code-panel {
  min-width: 0;
  border: 1px solid var(--glass-edge);
  border-radius: var(--radius);
  background: var(--glass-surface);
  box-shadow: inset 0 1px 0 var(--glass-highlight);
  -webkit-backdrop-filter: saturate(145%) blur(12px);
  backdrop-filter: saturate(145%) blur(12px);
}

.runbook-list {
  display: grid;
  gap: 1px;
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  background: var(--line);
  list-style: none;
}

.runbook-list li {
  display: grid;
  min-width: 0;
  grid-template-columns: auto minmax(17rem, 1fr) minmax(21rem, 0.72fr);
  gap: var(--space-sm);
  align-items: center;
  padding: var(--space-sm);
  background: rgba(255, 255, 255, 0.88);
}

.step-number {
  display: inline-grid;
  width: 2rem;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--blue-dark);
  background: var(--canvas);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 800;
}

.runbook-list h3 {
  margin-bottom: 0.2rem;
}

.runbook-list p,
.resource-stack p {
  margin-bottom: 0;
  font-size: 0.95rem;
}

.runbook-list > li > code {
  display: block;
  min-width: 0;
  padding: 0.55rem;
  border-radius: 6px;
  color: #eaf4ef;
  background: var(--terminal);
  font-family: var(--mono);
  font-size: 0.74rem;
  font-variant-ligatures: none;
  line-height: 1.45;
  overflow-x: auto;
  overflow-y: hidden;
  overflow-wrap: normal;
  white-space: nowrap;
}

.source-note {
  margin: var(--space-sm) 0 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.source-note a {
  color: var(--blue-dark);
  font-weight: 800;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.22em;
}

.source-note a:hover {
  color: var(--ink);
}

.agent-section {
  border-top: 1px solid var(--line);
}

.agent-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(18rem, 0.92fr);
  gap: var(--space-sm);
  align-items: stretch;
}

.agent-panels {
  display: grid;
  gap: var(--space-sm);
  min-width: 0;
}

.agent-panels .code-panel {
  box-shadow: none;
}

.agent-panels pre {
  min-height: 0;
  white-space: pre-wrap;
}

.agent-rules {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.agent-rules article {
  display: grid;
  grid-template-columns: minmax(6.5rem, 0.32fr) minmax(0, 1fr);
  gap: var(--space-xs);
  align-items: baseline;
  padding: var(--space-sm);
  background: rgba(255, 255, 255, 0.88);
}

.agent-rules article + article {
  border-top: 1px solid var(--line);
}

.agent-rules span {
  color: var(--blue-dark);
  font-size: 0.78rem;
  font-weight: 800;
}

.agent-rules p {
  margin-bottom: 0;
  font-size: 0.92rem;
  line-height: 1.5;
}

.schema-section {
  border-top: 1px solid var(--line);
}

.schema-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(22rem, 0.95fr);
  gap: var(--space-sm);
  align-items: start;
}

.code-panel {
  overflow: hidden;
  background: var(--terminal);
  box-shadow:
    var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.panel-bar {
  display: flex;
  min-height: 3.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0.65rem 0.55rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #dce8e1;
  background:
    linear-gradient(180deg, rgba(31, 42, 39, 0.96), rgba(23, 33, 31, 0.9)),
    var(--terminal-soft);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  font-size: 0.78rem;
  font-weight: 800;
}

.starter-config-panel .panel-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 3rem;
  padding: 0.5rem 0.55rem 0.5rem 1rem;
}

.starter-config-panel .panel-bar span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

pre {
  margin: 0;
  overflow: auto;
  padding: 1rem;
  color: #eaf4ef;
  background: var(--terminal);
  font-family: var(--mono);
  font-size: 0.82rem;
  font-variant-ligatures: none;
  line-height: 1.58;
  scrollbar-color: #43534e transparent;
  tab-size: 2;
}

.schema-grid .code-panel pre {
  max-height: clamp(34rem, 72vh, 56rem);
}

.syntax-yaml {
  color: #eaf4ef;
}

.syntax-yaml .yaml-section {
  color: #b7f2cb;
  font-weight: 800;
}

.syntax-yaml .yaml-key {
  color: #8dc8ff;
  font-weight: 800;
}

.syntax-yaml .yaml-punct,
.syntax-yaml .yaml-dash {
  color: #8fa19a;
}

.syntax-yaml .yaml-value {
  color: #eef7f2;
}

.syntax-yaml .yaml-string,
.syntax-yaml .yaml-number,
.syntax-yaml .yaml-bool {
  color: #f1c84c;
  font-weight: 800;
}

.resource-stack {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
}

.resource-stack article {
  display: grid;
  grid-template-columns: minmax(5.5rem, 0.28fr) minmax(0, 1fr);
  gap: var(--space-xs);
  align-items: start;
  padding: var(--space-sm);
}

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

.resource-stack span {
  display: inline-flex;
  min-width: 5.5rem;
  min-height: 1.5rem;
  align-items: center;
  color: var(--blue-dark);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 800;
}

.resource-coverage {
  display: grid;
  position: sticky;
  top: var(--space-sm);
  align-self: start;
  align-content: start;
  gap: var(--space-sm);
  min-width: 0;
}

.resource-coverage-heading {
  display: grid;
  gap: 0.35rem;
}

.resource-coverage-heading h3,
.resource-coverage-heading p {
  margin-bottom: 0;
}

.resource-coverage-heading p {
  max-width: 35rem;
  font-family: var(--sans);
  font-size: 0.95rem;
  line-height: 1.5;
}

.resource-map {
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.resource-group {
  display: grid;
  grid-template-columns: minmax(7.5rem, 0.34fr) minmax(0, 1fr);
  gap: var(--space-sm);
  min-width: 0;
  align-items: start;
  padding: var(--space-sm);
  background: rgba(255, 255, 255, 0.88);
}

.resource-group-copy {
  display: grid;
  gap: 0.28rem;
}

.resource-group-copy span {
  color: var(--blue-dark);
  font-size: 0.78rem;
  font-weight: 800;
}

.resource-group-copy p {
  margin-bottom: 0;
  font-family: var(--sans);
  font-size: 0.88rem;
  line-height: 1.45;
}

.resource-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.resource-links a {
  --resource-ink: var(--blue-dark);
  --resource-muted: var(--muted);
  --resource-line: var(--glass-edge);
  --resource-top: var(--glass-surface-strong);
  --resource-surface: var(--glass-surface);
  display: inline-grid;
  min-width: 8.35rem;
  min-height: 44px;
  align-content: center;
  gap: 0.08rem;
  padding: 0.45rem 0.56rem;
  border: 1px solid var(--resource-line);
  border-radius: 6px;
  background:
    linear-gradient(
      180deg,
      var(--resource-top),
      var(--resource-surface)
    );
  box-shadow: inset 0 1px 0 var(--glass-highlight);
  text-decoration: none;
  -webkit-backdrop-filter: saturate(145%) blur(10px);
  backdrop-filter: saturate(145%) blur(10px);
}

.resource-links a[data-resource-tone="blue"] {
  --resource-ink: var(--resource-blue-ink);
  --resource-muted: var(--resource-blue-muted);
  --resource-line: var(--resource-blue-line);
  --resource-top: var(--resource-blue-top);
  --resource-surface: var(--resource-blue-surface);
}

.resource-links a[data-resource-tone="green"] {
  --resource-ink: var(--resource-green-ink);
  --resource-muted: var(--resource-green-muted);
  --resource-line: var(--resource-green-line);
  --resource-top: var(--resource-green-top);
  --resource-surface: var(--resource-green-surface);
}

.resource-links a[data-resource-tone="amber"] {
  --resource-ink: var(--resource-amber-ink);
  --resource-muted: var(--resource-amber-muted);
  --resource-line: var(--resource-amber-line);
  --resource-top: var(--resource-amber-top);
  --resource-surface: var(--resource-amber-surface);
}

.resource-links a[data-resource-tone="red"] {
  --resource-ink: var(--resource-red-ink);
  --resource-muted: var(--resource-red-muted);
  --resource-line: var(--resource-red-line);
  --resource-top: var(--resource-red-top);
  --resource-surface: var(--resource-red-surface);
}

.resource-links a:hover {
  border-color: var(--resource-ink);
  background: linear-gradient(180deg, #ffffff, var(--resource-top));
}

.resource-links span {
  color: var(--resource-ink);
  font-size: 0.78rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.resource-links small {
  color: var(--resource-muted);
  font-family: var(--sans);
  font-size: 0.76rem;
  line-height: 1.35;
}

.schema-note {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.output-section {
  border-top: 1px solid var(--line);
}

.output-proof {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(18rem, 0.72fr);
  gap: var(--space-sm);
  align-items: stretch;
}

.run-terminal {
  overflow: hidden;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: var(--radius);
  background: var(--terminal);
  box-shadow:
    var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.terminal-bar {
  display: flex;
  min-height: 2.85rem;
  align-items: center;
  gap: 0.45rem;
  padding-inline: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #b9c8c1;
  background:
    linear-gradient(180deg, rgba(31, 42, 39, 0.96), rgba(23, 33, 31, 0.9)),
    var(--terminal-soft);
  font-family: var(--mono);
  font-size: 0.76rem;
}

.terminal-bar span {
  width: 0.58rem;
  aspect-ratio: 1;
  border-radius: 50%;
}

.terminal-bar span:nth-child(1) {
  background: #ff6b64;
}

.terminal-bar span:nth-child(2) {
  background: #f1c84c;
}

.terminal-bar span:nth-child(3) {
  background: #62d37b;
}

.terminal-bar strong {
  margin-left: 0.35rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.run-terminal pre {
  min-height: 22rem;
  max-height: none;
  overflow: auto;
  padding: 1.05rem 1.1rem;
  background: var(--terminal);
  font-size: 0.78rem;
  line-height: 1.56;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.term-prompt,
.term-progress {
  color: #6ea8ff;
  font-weight: 800;
}

.term-ok {
  color: #62d37b;
  font-weight: 800;
}

.term-warn {
  color: #f1c84c;
  font-weight: 800;
}

.term-fail {
  color: #ff6b64;
  font-weight: 800;
}

.term-skip {
  color: #67d4ef;
  font-weight: 800;
}

.output-notes {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
}

.output-notes article {
  display: grid;
  align-content: start;
  gap: 0.35rem;
  padding: var(--space-sm);
}

.output-notes article + article {
  border-top: 1px solid var(--line);
}

.output-notes h3,
.output-notes p {
  margin-bottom: 0;
}

.output-notes p {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.recovery-strip {
  display: grid;
  gap: 0.75rem;
  overflow: visible;
  margin-top: var(--space-sm);
}

.recovery-row {
  display: grid;
  grid-template-columns: minmax(9.5rem, 0.34fr) minmax(16rem, 0.56fr) minmax(0, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.recovery-row > * {
  min-width: 0;
  margin: 0;
  padding: var(--space-sm);
  background: rgba(255, 255, 255, 0.88);
}

.recovery-row span {
  color: var(--red);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 800;
}

.recovery-row code {
  color: var(--ink);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

.recovery-row p {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.recovery-row p code {
  color: var(--blue-dark);
}

.safety-section {
  display: grid;
  grid-template-columns: minmax(16rem, 0.55fr) minmax(0, 1.45fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
  border-top: 1px solid var(--line);
}

.safety-copy {
  display: grid;
  gap: var(--space-sm);
  max-width: 27rem;
}

.safety-copy h2 {
  margin-bottom: 0;
}

.safety-copy p {
  max-width: 34rem;
  margin-bottom: 0;
  font-size: 1rem;
}

.safety-list {
  display: grid;
  gap: 1px;
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  background: var(--line);
  list-style: none;
}

.safety-list li {
  display: grid;
  grid-template-columns: minmax(6.8rem, 0.32fr) minmax(0, 1fr);
  gap: var(--space-md);
  align-items: baseline;
  min-height: 0;
  padding: 0.95rem var(--space-sm);
  border: 0;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.5;
}

.safety-list li::before {
  display: none;
}

.safety-list strong {
  color: var(--blue-dark);
  font-size: 0.76rem;
  font-weight: 800;
}

.safety-list span {
  min-width: 0;
}

.safety-list code {
  color: var(--blue-dark);
  font-size: 0.94em;
}

.install-section {
  border-top: 1px solid var(--line);
}

.install-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--space-sm);
}

.install-grid .code-panel:nth-child(1) {
  grid-column: span 4;
}

.install-grid .code-panel:nth-child(2) {
  grid-column: span 3;
}

.install-grid .code-panel:nth-child(3) {
  grid-column: span 5;
}

.install-grid .code-panel {
  box-shadow: none;
}

.install-grid pre {
  min-height: 8.5rem;
  white-space: pre-wrap;
}

.doc-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-top: var(--space-sm);
}

.doc-links a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 0.7rem 0.78rem;
  border: 1px solid var(--glass-edge);
  border-radius: 6px;
  color: var(--blue-dark);
  background:
    linear-gradient(
      180deg,
      var(--glass-surface-strong),
      var(--glass-surface)
    );
  box-shadow: inset 0 1px 0 var(--glass-highlight);
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
  -webkit-backdrop-filter: saturate(145%) blur(10px);
  backdrop-filter: saturate(145%) blur(10px);
}

.doc-links a:hover {
  color: var(--ink);
  border-color: var(--blue-dark);
  background: #ffffff;
}

.docs-section {
  border-top: 1px solid var(--line);
}

.docs-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-sm);
}

.docs-grid article {
  display: grid;
  align-content: start;
  gap: 0.42rem;
  min-width: 0;
  padding: var(--space-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
}

.docs-grid h3 {
  margin-bottom: 0.25rem;
}

.docs-grid a {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  color: var(--blue-dark);
  font-size: 0.78rem;
  font-weight: 800;
  overflow-wrap: anywhere;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.22em;
}

.docs-grid a:hover {
  color: var(--ink);
}

.site-footer {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.78rem;
}

.site-footer a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--blue-dark);
  font-weight: 800;
  text-decoration: none;
}

@media (max-width: 1040px) {
  h1 {
    font-size: 5.2rem;
  }

  h2 {
    font-size: 2.7rem;
  }

  .output-proof {
    grid-template-columns: 1fr;
  }

  .install-grid .code-panel:nth-child(1),
  .install-grid .code-panel:nth-child(2) {
    grid-column: span 6;
  }

  .install-grid .code-panel:nth-child(3) {
    grid-column: 1 / -1;
  }

  .agent-grid,
  .schema-grid,
  .safety-section {
    grid-template-columns: 1fr;
  }

  .resource-coverage {
    position: static;
    order: -1;
  }

  .safety-copy {
    max-width: 42rem;
  }
}

@media (max-width: 880px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .kitout-artifact {
    max-width: 54rem;
  }
}

@media (max-width: 760px) {
  html {
    scroll-padding-top: 5rem;
  }

  h1 {
    font-size: 4rem;
  }

  h2 {
    font-size: 2.2rem;
  }

  .site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    display: grid;
    padding-block: 0.55rem;
  }

  .brand {
    min-width: 0;
  }

  .brand-line {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .site-nav {
    width: auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
  }

  .site-nav a {
    padding-inline: 0.6rem;
  }

  .site-nav > .nav-plan,
  .site-nav > .nav-strong {
    display: none;
  }

  .nav-menu {
    width: min(17rem, calc(100vw - 2rem));
  }

  .nav-menu-github {
    display: flex !important;
  }

  .hero-inner {
    padding-block: 2.25rem;
  }

  .artifact-titlebar {
    align-items: flex-start;
    flex-direction: column;
  }

  .artifact-terminal pre {
    padding: 0.9rem;
  }

  .hero-text {
    font-size: 1.08rem;
  }

  .section-intro {
    grid-template-columns: 1fr;
  }

  .section-intro p {
    grid-column: auto;
  }

  .runbook-list li {
    grid-template-columns: 1fr;
  }

  .runbook-list > li > code {
    overflow-wrap: anywhere;
    white-space: normal;
  }

  .recovery-row {
    grid-template-columns: 1fr;
  }

  .agent-rules article {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .resource-group {
    grid-template-columns: 1fr;
    gap: var(--space-xs);
  }

  .step-number {
    width: 1.75rem;
  }

  .install-grid .code-panel:nth-child(1),
  .install-grid .code-panel:nth-child(2),
  .install-grid .code-panel:nth-child(3) {
    grid-column: 1 / -1;
  }

  .command-loop,
  .agent-section,
  .schema-section,
  .output-section,
  .safety-section,
  .install-section,
  .docs-section {
    padding-block: 3.5rem;
  }

  .safety-list {
    grid-template-columns: 1fr;
  }

  .safety-list li {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .run-terminal pre {
    min-height: 18rem;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding-block: 1rem;
  }
}

@media (max-width: 540px) {
  h1 {
    font-size: 3.35rem;
  }

  h2 {
    font-size: 1.9rem;
  }

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

  .hero-command {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .hero-command code {
    overflow: visible;
    overflow-wrap: anywhere;
    text-overflow: clip;
    white-space: normal;
  }

  .hero-command button {
    grid-column: 1 / -1;
    width: 100%;
  }

  .artifact-wide {
    display: none !important;
  }

  .artifact-footer span {
    flex: 1 1 0;
  }

  .artifact-footer span + span {
    border-left: 1px solid var(--line);
  }

  .hero-actions {
    width: 100%;
  }

  .hero-actions .button {
    flex: 1 1 0;
    width: auto;
    min-width: 0;
    padding-inline: 0.7rem;
  }

  .schema-grid .code-panel pre {
    max-height: 34rem;
  }

  .resource-links a {
    flex: 1 1 8.75rem;
  }

  .site-nav .nav-strong {
    width: 100%;
    justify-content: center;
  }

  .doc-links,
  .doc-links a,
  .docs-grid {
    width: 100%;
  }

  .doc-links a {
    justify-content: center;
  }

  .resource-stack article {
    grid-template-columns: 1fr;
  }

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

@media (prefers-reduced-motion: no-preference) {
  .kitout-artifact {
    animation: proof-settle 720ms var(--ease-out) both;
  }

  .hero-inner {
    animation: hero-copy-settle 620ms var(--ease-out) both;
  }

  .runbook-list li,
  .resource-stack article,
  .resource-links a,
  .agent-rules article,
  .output-notes article,
  .safety-list li,
  .install-grid .code-panel,
  .docs-grid article {
    transition: background-color 180ms var(--ease-out);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
  }
}

@keyframes proof-settle {
  from {
    transform: translateY(8px);
  }
}

@keyframes hero-copy-settle {
  from {
    transform: translateY(10px);
  }
}
