:root {
  --ink: #171717;
  --muted: #666666;
  --soft: #8a8a8a;
  --line: #e5e5e5;
  --line-dark: #d4d4d4;
  --surface: #fafafa;
  --surface-raised: #ffffff;
  --blue: #2563eb;
  --blue-soft: #eff6ff;
  --green: #18794e;
  --green-soft: #eef8f3;
  --amber: #946200;
  --amber-soft: #fff8e6;
  --red: #b42318;
  --red-soft: #fff1f0;
  --radius: 6px;
  --max-width: 1220px;
  --nav-width: 212px;
  --sans: Inter, Geist, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--surface-raised);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

button,
input { font: inherit; }

button,
a { -webkit-tap-highlight-color: transparent; }

a { color: inherit; }

button { color: inherit; }

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 8px 12px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  background: white;
  transform: translateY(-150%);
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.topbar {
  position: sticky;
  z-index: 50;
  top: 0;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  min-height: 56px;
  padding: 0 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  color: var(--ink);
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 5px;
  background: var(--ink);
  color: white;
  font-family: var(--mono);
  font-size: 12px;
}

.mode-switch {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  font-size: 12px;
}

.mode-active,
.mode-link {
  padding: 4px 9px;
  border-radius: 4px;
}

.mode-active { background: white; box-shadow: 0 0 0 1px var(--line); }

.mode-link {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.menu-button {
  display: none;
  margin-left: 12px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  font-size: 13px;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--nav-width) minmax(0, 1fr);
  width: min(100%, calc(var(--max-width) + var(--nav-width)));
  margin: 0 auto;
}

.sidebar {
  position: sticky;
  top: 56px;
  align-self: start;
  height: calc(100vh - 56px);
  padding: 32px 20px;
  border-right: 1px solid var(--line);
  background: white;
}

.nav-label,
.eyebrow {
  margin: 0;
  color: var(--soft);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.09em;
  line-height: 1.4;
  text-transform: uppercase;
}

.nav-list { display: grid; gap: 2px; margin-top: 8px; }

.nav-list button {
  width: 100%;
  padding: 7px 9px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
}

.nav-list button:hover { color: var(--ink); background: var(--surface); }

.nav-list button[aria-current="page"] {
  color: var(--ink);
  background: var(--surface);
  font-weight: 600;
}

.nav-rule { height: 1px; margin: 22px 0; background: var(--line); }

.sidebar-note {
  margin: 28px 8px 0;
  color: var(--soft);
  font-size: 11px;
  line-height: 1.55;
}

.main-content {
  min-width: 0;
  padding: 60px clamp(28px, 5vw, 72px) 96px;
}

.view { width: 100%; max-width: 1050px; margin: 0 auto; }

.view[hidden] { display: none; }

.page-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line);
}

.overview-intro { align-items: center; }

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

h1 {
  max-width: 760px;
  margin-bottom: 12px;
  font-size: clamp(34px, 4vw, 52px);
  font-weight: 620;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

h2 {
  margin-bottom: 10px;
  font-size: clamp(22px, 2.5vw, 30px);
  font-weight: 620;
  letter-spacing: -0.028em;
  line-height: 1.2;
}

h3 {
  margin-bottom: 6px;
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.page-intro .eyebrow,
.section-heading .eyebrow { margin-bottom: 12px; }

.lede {
  max-width: 690px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.55;
}

.button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  cursor: pointer;
}

.button {
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: white;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.button:hover { border-color: #b7b7b7; background: var(--surface); }

.button-primary { border-color: var(--ink); background: var(--ink); color: white; }

.button-primary:hover { border-color: #333; background: #333; }

.button[hidden] { display: none; }

.text-button {
  padding: 2px 0;
  border: 0;
  background: transparent;
  color: var(--blue);
  font-size: 12px;
  font-weight: 600;
}

.state-row { display: flex; gap: 8px; padding: 18px 0 0; }

.state-label,
.count-label {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.02em;
  line-height: 1.4;
}

.state-implemented,
.state-background { border-color: #bfdfcf; background: var(--green-soft); color: var(--green); }

.state-human { border-color: #ead59d; background: var(--amber-soft); color: var(--amber); }

.state-demo { border-color: #c7d7fb; background: var(--blue-soft); color: var(--blue); }

.hero-flow-section { padding: 54px 0 46px; }

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

.section-heading > p:last-child { margin-bottom: 0; color: var(--muted); }

.compact-heading,
.inline-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  max-width: none;
}

.compact-heading > div > *:last-child,
.inline-heading > div > *:last-child { margin-bottom: 0; }

.mission-trace {
  display: grid;
  grid-template-columns: repeat(7, minmax(90px, 1fr));
  gap: 22px;
  overflow-x: auto;
  padding: 4px 2px 12px;
  scrollbar-width: thin;
}

.trace-step {
  position: relative;
  min-width: 96px;
  min-height: 112px;
  padding: 13px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  transition: border-color 380ms ease, background-color 380ms ease, transform 380ms ease;
}

.trace-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 50%;
  left: calc(100% + 1px);
  width: 22px;
  height: 1px;
  background: var(--line-dark);
}

.trace-step:not(:last-child)::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: calc(50% - 3px);
  left: calc(100% + 18px);
  width: 5px;
  height: 5px;
  border-top: 1px solid var(--soft);
  border-right: 1px solid var(--soft);
  transform: rotate(45deg);
}

.trace-step.active {
  border-color: #9bb8f8;
  background: var(--blue-soft);
  transform: translateY(-2px);
}

.trace-step.complete { border-color: #bfdcca; background: #fbfefc; }

.trace-index { display: block; margin-bottom: 22px; color: var(--soft); font-family: var(--mono); font-size: 10px; }

.trace-step strong { display: block; margin-bottom: 5px; font-size: 13px; line-height: 1.3; }

.trace-step small { display: block; color: var(--muted); font-size: 11px; line-height: 1.45; }

.answer-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.answer-strip article { min-width: 0; padding: 18px; }

.answer-strip article + article { border-left: 1px solid var(--line); }

.answer-strip span,
.answer-strip strong { display: block; }

.answer-strip span { margin-bottom: 6px; color: var(--soft); font-size: 11px; }

.answer-strip strong { font-size: 13px; line-height: 1.45; }

.content-section { padding: 70px 0; border-bottom: 1px solid var(--line); }

.compact-section { padding-bottom: 30px; border-bottom: 0; }

.background-split {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
  gap: 16px;
}

.plain-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
}

.plain-panel .state-label { margin-bottom: 28px; }

.plain-panel p { margin-bottom: 0; color: var(--muted); }

.background-panel { background: #fbfefc; }

.split-arrow { display: grid; place-items: center; color: var(--soft); }

.quiet-note { margin: 18px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }

.comparison-list { border-top: 1px solid var(--line); }

.comparison-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px minmax(0, 1fr);
  align-items: center;
  min-height: 138px;
  border-bottom: 1px solid var(--line);
}

.comparison-row > div:not(.comparison-arrow) { padding: 22px 18px; }

.comparison-row p { margin: 8px 0 3px; }

.comparison-row strong { font-size: 12px; }

.comparison-arrow { color: var(--soft); text-align: center; }

.comparison-label { color: var(--soft); font-family: var(--mono); font-size: 10px; text-transform: uppercase; }

.comparison-label.accent { color: var(--blue); }

code {
  padding: 2px 5px;
  border-radius: 4px;
  background: var(--surface);
  font-family: var(--mono);
  font-size: 0.9em;
}

.benefit-grid { display: grid; grid-template-columns: repeat(2, 1fr); border: 1px solid var(--line); border-radius: var(--radius); }

.benefit-grid article { padding: 22px; }

.benefit-grid article:nth-child(even) { border-left: 1px solid var(--line); }

.benefit-grid article:nth-child(n + 3) { border-top: 1px solid var(--line); }

.benefit-grid span { color: var(--soft); font-family: var(--mono); font-size: 10px; text-transform: uppercase; }

.benefit-grid p { margin: 7px 0 12px; color: var(--muted); }

.benefit-grid strong { font-size: 13px; }

.not-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 60px; }

.not-grid > div:first-child > p:last-child { margin-bottom: 0; color: var(--muted); }

.coordinator-diagram { display: grid; gap: 18px; }

.diagram-core { padding: 17px; border: 1px solid var(--ink); border-radius: var(--radius); text-align: center; font-weight: 650; }

.worker-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }

.worker-row span { padding: 9px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); font-family: var(--mono); font-size: 11px; text-align: center; }

.demo-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr); gap: 30px; padding-top: 40px; }

.telegram-demo,
.demo-progress-panel { border: 1px solid var(--line); border-radius: var(--radius); background: white; }

.telegram-header { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; min-height: 68px; padding: 12px 16px; border-bottom: 1px solid var(--line); }

.telegram-header h2 { margin: 0; font-size: 14px; }

.telegram-header p { margin: 0; color: var(--soft); font-size: 11px; }

.avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: white; font-family: var(--mono); font-size: 12px; }

.chat-body { min-height: 470px; padding: 24px 18px; background: var(--surface); }

.chat-empty { display: grid; min-height: 410px; place-items: center; color: var(--soft); font-size: 13px; text-align: center; }

.chat-message { display: flex; margin-bottom: 13px; opacity: 0; transform: translateY(7px); transition: opacity 320ms ease, transform 320ms ease; }

.chat-message.visible { opacity: 1; transform: none; }

.chat-message.user { justify-content: flex-end; }

.bubble { max-width: 82%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 6px; background: white; font-size: 13px; line-height: 1.5; }

.user .bubble { border-color: #c7d7fb; background: var(--blue-soft); }

.bubble-meta { display: block; margin-bottom: 4px; color: var(--soft); font-family: var(--mono); font-size: 9px; text-transform: uppercase; }

.demo-controls { display: flex; align-items: center; gap: 10px; min-height: 62px; padding: 11px 16px; border-top: 1px solid var(--line); }

.demo-controls .text-button { margin-left: auto; }

.demo-progress-panel { padding: 24px; }

.demo-progress-panel h2 { font-size: 20px; }

.vertical-trace { display: grid; gap: 0; margin-top: 24px; }

.vertical-step { position: relative; display: grid; grid-template-columns: 24px 1fr; gap: 11px; min-height: 64px; color: var(--soft); }

.vertical-step:not(:last-child)::after { content: ""; position: absolute; top: 21px; bottom: -1px; left: 8px; width: 1px; background: var(--line); }

.vertical-dot { position: relative; z-index: 1; width: 17px; height: 17px; border: 1px solid var(--line-dark); border-radius: 50%; background: white; transition: border-color 320ms ease, background-color 320ms ease; }

.vertical-step strong { display: block; font-size: 12px; line-height: 1.35; }

.vertical-step small { display: block; margin-top: 3px; font-size: 10px; line-height: 1.4; }

.vertical-step.active { color: var(--ink); }

.vertical-step.active .vertical-dot { border-color: var(--blue); background: var(--blue-soft); box-shadow: inset 0 0 0 4px white; }

.vertical-step.complete { color: var(--green); }

.vertical-step.complete .vertical-dot { border-color: var(--green); background: var(--green); }

.command-explorer {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  grid-template-areas: "master detail" "master conversation";
  margin-top: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.command-master { grid-area: master; padding: 20px 12px; border-right: 1px solid var(--line); background: var(--surface); }

.command-master h2 { margin: 0 8px 14px; font-size: 12px; }

.command-tabs { display: grid; gap: 2px; }

.command-tab { padding: 8px 10px; border: 0; border-radius: 4px; background: transparent; color: var(--muted); font-family: var(--mono); font-size: 12px; text-align: left; cursor: pointer; }

.command-tab:hover { background: white; color: var(--ink); }

.command-tab[aria-selected="true"] { background: white; color: var(--blue); box-shadow: 0 0 0 1px var(--line); font-weight: 650; }

.command-detail { grid-area: detail; min-width: 0; padding: 28px 30px 30px; }

.command-detail-header { display: flex; align-items: start; justify-content: space-between; gap: 20px; }

.command-name { margin-bottom: 5px; font-family: var(--mono); font-size: 22px; }

.command-purpose { margin-bottom: 26px; color: var(--muted); }

.command-facts { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.command-facts div { padding: 17px 15px 17px 0; }

.command-facts div + div { padding-left: 15px; border-left: 1px solid var(--line); }

.command-facts span { display: block; margin-bottom: 7px; color: var(--soft); font-family: var(--mono); font-size: 9px; text-transform: uppercase; }

.command-facts p { margin-bottom: 0; font-size: 12px; line-height: 1.55; }

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

.command-flow-header { display: flex; align-items: center; justify-content: space-between; margin-top: 25px; }

.command-flow-header h3 { margin: 0; }

.command-flow { display: flex; align-items: stretch; gap: 18px; overflow-x: auto; margin-top: 13px; padding: 2px 1px 9px; }

.command-flow-node { position: relative; display: grid; align-content: center; flex: 1 0 112px; min-height: 62px; padding: 9px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); font-size: 11px; text-align: center; transition: border-color 350ms ease, background-color 350ms ease, color 350ms ease; }

.command-flow-node:not(:last-child)::after { content: "→"; position: absolute; top: 50%; left: calc(100% + 5px); color: var(--soft); transform: translateY(-50%); }

.command-flow-node.active { border-color: #9bb8f8; background: var(--blue-soft); color: var(--ink); }

.command-flow-node.complete { border-color: #bfdcca; color: var(--green); }

.command-conversation { grid-area: conversation; padding: 20px 30px 24px; border-top: 1px solid var(--line); background: var(--surface); }

.mini-chat { display: grid; gap: 9px; }

.mini-message { width: fit-content; max-width: 82%; padding: 8px 11px; border: 1px solid var(--line); border-radius: var(--radius); background: white; font-size: 11px; }

.mini-message.user { justify-self: end; border-color: #c7d7fb; background: var(--blue-soft); }

.search-field input { width: min(260px, 45vw); padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius); background: white; color: var(--ink); font-size: 12px; }

.reference-list { border-top: 1px solid var(--line); }

.reference-item { display: grid; grid-template-columns: 140px repeat(3, 1fr); gap: 20px; padding: 18px 4px; border-bottom: 1px solid var(--line); }

.reference-item code { width: fit-content; align-self: start; color: var(--blue); font-weight: 650; }

.reference-cell span { display: block; margin-bottom: 5px; color: var(--soft); font-family: var(--mono); font-size: 9px; text-transform: uppercase; }

.reference-cell p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }

.reference-empty { padding: 30px 0; color: var(--muted); }

.capability-list { margin-top: 40px; border-top: 1px solid var(--line); }

.capability-row { display: grid; grid-template-columns: 210px 1fr auto; align-items: start; gap: 34px; padding: 26px 0; border-bottom: 1px solid var(--line); }

.capability-row h2 { margin: 0; font-size: 17px; }

.capability-row p { margin: 0; color: var(--muted); }

.capability-examples { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }

.capability-examples span { padding: 3px 7px; border: 1px solid var(--line); border-radius: 4px; background: var(--surface); color: var(--muted); font-family: var(--mono); font-size: 10px; }

.story-list { display: grid; grid-template-columns: repeat(2, 1fr); border: 1px solid var(--line); border-radius: var(--radius); }

.story-card { padding: 25px; }

.story-card:nth-child(even) { border-left: 1px solid var(--line); }

.story-card:nth-child(n + 3) { border-top: 1px solid var(--line); }

.story-card:last-child:nth-child(odd) { grid-column: 1 / -1; }

.story-card h3 { font-size: 16px; }

.story-card > p { color: var(--muted); }

.story-request { padding: 9px 11px; border-left: 2px solid var(--blue); background: var(--blue-soft); color: var(--ink) !important; font-family: var(--mono); font-size: 11px; }

.story-path { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 16px; }

.story-path span { color: var(--muted); font-size: 10px; }

.story-path span:not(:last-child)::after { content: " →"; color: var(--soft); }

.beginner-architecture { display: grid; justify-items: center; padding: 44px 0 20px; }

.architecture-node,
.engine-block { width: min(100%, 680px); padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: white; text-align: center; }

.architecture-node > span { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 10px; border-radius: 50%; background: var(--surface); color: var(--soft); font-family: var(--mono); font-size: 10px; }

.architecture-node strong { font-size: 14px; }

.architecture-node small { display: block; margin-top: 6px; color: var(--muted); }

.architecture-arrow { padding: 11px 0; color: var(--soft); }

.engine-block { border-color: #a9c0f6; background: var(--blue-soft); }

.engine-block h2 { font-size: 20px; }

.engine-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }

.engine-grid span { padding: 8px; border: 1px solid #d8e4fc; border-radius: 4px; background: rgba(255, 255, 255, 0.65); font-size: 11px; }

.architecture-pair { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; width: min(100%, 680px); }

.result-node { border-color: #bfdfcf; background: var(--green-soft); }

.mode-grid { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: var(--radius); }

.mode-grid article { padding: 22px; }

.mode-grid article + article { border-left: 1px solid var(--line); }

.mode-grid .state-label { margin-bottom: 30px; }

.mode-grid p { margin-bottom: 0; color: var(--muted); font-size: 12px; }

.safety-section { border-bottom: 0; }

.safety-points { display: flex; flex-wrap: wrap; gap: 8px; }

.safety-points span { padding: 8px 11px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); font-size: 11px; }

.technical-frame-shell { min-height: 620px; margin-top: 40px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }

.technical-placeholder { display: grid; align-content: center; justify-items: center; min-height: 620px; padding: 40px; text-align: center; }

.technical-placeholder p:last-child { max-width: 470px; color: var(--muted); }

.technical-frame { display: block; width: 100%; height: 78vh; min-height: 620px; border: 0; background: white; }

@media (max-width: 1024px) {
  :root { --nav-width: 190px; }
  .main-content { padding-inline: 32px; }
  .answer-strip { grid-template-columns: repeat(2, 1fr); }
  .answer-strip article:nth-child(3) { border-top: 1px solid var(--line); border-left: 0; }
  .answer-strip article:nth-child(4) { border-top: 1px solid var(--line); }
  .reference-item { grid-template-columns: 120px repeat(3, 1fr); gap: 14px; }
  .mission-trace { grid-template-columns: repeat(7, 118px); }
}

@media (max-width: 768px) {
  .topbar { padding-inline: 16px; }
  .mode-switch { display: none; }
  .menu-button { display: inline-flex; }
  .app-shell { display: block; }
  .sidebar {
    position: fixed;
    z-index: 40;
    top: 56px;
    right: 0;
    left: 0;
    display: none;
    width: 100%;
    height: auto;
    max-height: calc(100vh - 56px);
    padding: 20px 16px 24px;
    overflow-y: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.06);
  }
  .sidebar.open { display: block; }
  .sidebar-note { margin-top: 18px; }
  .main-content { padding: 42px 22px 72px; }
  .page-intro { align-items: flex-start; }
  .mission-trace { grid-template-columns: 1fr; gap: 14px; overflow: visible; }
  .trace-step { min-height: 84px; padding-left: 58px; }
  .trace-index { position: absolute; top: 14px; left: 14px; }
  .trace-step:not(:last-child)::after { top: calc(100% + 1px); left: 29px; width: 1px; height: 14px; }
  .trace-step:not(:last-child)::before { top: calc(100% + 9px); left: 26px; transform: rotate(135deg); }
  .trace-step.active { transform: translateX(2px); }
  .demo-layout { grid-template-columns: 1fr; }
  .chat-body { min-height: 420px; }
  .command-explorer { grid-template-columns: minmax(0, 1fr); grid-template-areas: "master" "detail" "conversation"; }
  .command-master { border-right: 0; border-bottom: 1px solid var(--line); }
  .command-tabs { display: flex; gap: 5px; overflow-x: auto; padding: 1px 1px 8px; }
  .command-tab { flex: 0 0 auto; border: 1px solid var(--line); background: white; }
  .command-facts { grid-template-columns: 1fr; }
  .command-facts div { padding: 13px 0; }
  .command-facts div + div { padding-left: 0; border-top: 1px solid var(--line); border-left: 0; }
  .reference-item { grid-template-columns: 115px 1fr; }
  .reference-cell:nth-child(n + 3) { grid-column: 2; }
  .capability-row { grid-template-columns: 160px 1fr; gap: 20px; }
  .capability-row > .state-label { grid-column: 2; }
  .mode-grid { grid-template-columns: 1fr; }
  .mode-grid article + article { border-top: 1px solid var(--line); border-left: 0; }
}

@media (max-width: 560px) {
  body { font-size: 14px; }
  .main-content { padding: 34px 16px 60px; }
  .page-intro { display: grid; gap: 22px; padding-bottom: 30px; }
  .page-intro .button { width: 100%; }
  h1 { font-size: 34px; }
  .state-row { flex-wrap: wrap; }
  .compact-heading,
  .inline-heading { display: grid; align-items: start; }
  .answer-strip { grid-template-columns: 1fr; }
  .answer-strip article + article,
  .answer-strip article:nth-child(3) { border-top: 1px solid var(--line); border-left: 0; }
  .content-section { padding: 52px 0; }
  .background-split { grid-template-columns: 1fr; }
  .split-arrow { transform: rotate(90deg); }
  .comparison-row { grid-template-columns: 1fr; padding: 8px 0; }
  .comparison-arrow { transform: rotate(90deg); }
  .benefit-grid { grid-template-columns: 1fr; }
  .benefit-grid article:nth-child(even) { border-left: 0; }
  .benefit-grid article + article { border-top: 1px solid var(--line); }
  .not-grid { grid-template-columns: 1fr; gap: 34px; }
  .telegram-header { grid-template-columns: auto 1fr; }
  .telegram-header .state-label { grid-column: 2; }
  .demo-controls { flex-wrap: wrap; }
  .demo-controls .text-button { margin-left: 0; padding: 8px; }
  .command-detail { padding: 22px 18px; }
  .command-detail-header { display: grid; gap: 10px; }
  .command-conversation { padding: 18px; }
  .reference-item { grid-template-columns: 1fr; gap: 10px; }
  .reference-cell:nth-child(n + 3) { grid-column: auto; }
  .search-field input { width: 100%; }
  .capability-row { grid-template-columns: 1fr; gap: 11px; }
  .capability-row > .state-label { grid-column: auto; }
  .story-list { grid-template-columns: 1fr; }
  .story-card:nth-child(even) { border-left: 0; }
  .story-card + .story-card { border-top: 1px solid var(--line); }
  .story-card:last-child:nth-child(odd) { grid-column: auto; }
  .engine-grid,
  .architecture-pair { grid-template-columns: 1fr; }
  .architecture-pair { width: 100%; }
  .technical-frame-shell,
  .technical-placeholder,
  .technical-frame { min-height: 520px; }
}

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