
:root {
  --page-bg: #eef2f5;
  --surface: #ffffff;
  --surface-alt: #f7f9fb;
  --surface-glow: #f7fbf8;
  --subtle: #f4f8f6;
  --border: #d7dfe8;
  --text: #132130;
  --text-muted: #5e7286;
  --quiet-text: #496176;
  --accent: #0b8f5d;
  --accent-soft: #e9fff4;
  --accent-hover: rgba(11, 143, 93, 0.06);
  --proof-accent: #6f42d6;
  --proof-accent-surface: rgba(111, 66, 214, 0.045);
  --proof-accent-line: rgba(111, 66, 214, 0.28);
  --shadow: 0 16px 42px rgba(19, 33, 48, 0.08);
  --code-inline-bg: #edf2f7;
  --code-bg: #0a1220;
  --code-text: #edf4ff;
  --table-header-bg: #eff9f3;
  --quote-bg: #f7fffa;
  --diagram-fallback-bg: #f5f9ff;
  --note-bg: #fff9db;
  --note-border: #dfcf7a;
  --signal: #607080;
  --activation-bg: #eef4ff;
  --actor-border: #b7c4d4;
  --activation-border: #92a4b7;
  --diagram-node-border: #b9c7d6;
  --source-border: #c7d2de;
  --contrast-text: #ffffff;
  --accent-glow: rgba(90, 242, 169, 0.1);
  --code-inset-highlight: rgba(255, 255, 255, 0.03);
  --frame-outline: rgba(0, 0, 0, 0.08);
  --mark-bg: #07111c;
  --mark-shell: #0f1724;
  --mark-visor-bg: #030712;
  --mark-glow-start: #7affc4;
  --mark-glow-end: #1ec86f;
  --mark-visor-stroke: #9fffd4;
  --mark-eye: #8dffcb;
  --mark-chevron: #59f0a4;
  --mark-mouth: #264052;
  --favicon-stroke: #5af2a9;
  --topbar-sticky-offset: 96px;
  --sticky-stack-overlap: 2px;
  --anchor-offset: calc(var(--topbar-sticky-offset) + var(--space-4));
  --measure-content: 80ch;
  --measure-support: 68ch;
  --section-measure: min(100%, var(--measure-content));
  --space-2: 10px;
  --space-3: 15px;
  --space-4: 20px;
  --space-5: 25px;
  --space-6: 30px;
  --space-7: 40px;
  --surface-divider-gap: var(--space-5);
}
* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  background: var(--page-bg);
  color: var(--text);
  font-family: "Inter", sans-serif;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html {
  scroll-padding-top: var(--anchor-offset);
}
body { padding: var(--space-4); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code {
  font-family: "IBM Plex Mono", monospace;
  background: var(--code-inline-bg);
  color: var(--text);
  padding: 0.18em 0.38em;
  border-radius: 8px;
}
.shell {
  max-width: 1380px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: visible;
  box-shadow: var(--shadow);
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--border);
  background:
    radial-gradient(circle at top right, var(--accent-glow), transparent 32%),
    linear-gradient(180deg, var(--surface-glow) 0%, var(--surface) 100%);
}
.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.topbar-actions {
  flex: 0 1 380px;
  min-width: 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;
}
.brand strong {
  display: block;
  font-size: 24px;
  letter-spacing: -0.03em;
}
.brand span {
  display: block;
  margin-top: 4px;
  color: var(--text-muted);
  font-family: "IBM Plex Mono", monospace;
  font-size: 13px;
}
.brand-copy {
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
}
.brand strong,
.brand span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.brand-mark {
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
  display: block;
}
.content {
  padding: var(--space-5) var(--space-6) var(--space-7);
  min-width: 0;
}
.page-header {
  width: var(--section-measure);
  padding-bottom: var(--surface-divider-gap);
  margin-bottom: var(--surface-divider-gap);
  border-bottom: 1px solid var(--border);
}
.page-header h1 {
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.page-summary {
  margin: 0;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.surface-footer {
  width: var(--section-measure);
  margin-top: var(--space-7);
}
.surface-footer-body {
  margin-bottom: var(--surface-divider-gap);
}
.content .surface-footer .surface-meta {
  margin: 0;
  width: 100%;
  max-width: none;
  padding-top: var(--surface-divider-gap);
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.6;
}
.content .surface-footer .surface-meta time {
  font-family: "IBM Plex Mono", monospace;
  color: var(--text);
  white-space: nowrap;
}
@media (max-width: 1180px) {
  :root {
    --topbar-sticky-offset: 88px;
  }
  .topbar {
    padding: var(--space-3) var(--space-4);
  }
  .brand {
    gap: 12px;
  }
  .brand strong {
    font-size: 22px;
  }
  .brand span {
    font-size: 12px;
  }
  .brand-mark {
    width: 46px;
    height: 46px;
  }
  .topbar-actions {
    flex-basis: 340px;
  }
}
@media (max-width: 1024px) {
  body { padding: var(--space-3); }
  :root { --topbar-sticky-offset: 84px; }
  .topbar-inner {
    flex-direction: column;
    align-items: stretch;
  }
  .topbar-actions {
    flex: 1 1 auto;
    width: 100%;
  }
}
@media (max-width: 720px) {
  :root { --topbar-sticky-offset: 81px; }
  .shell {
    width: 100%;
  }
  .brand {
    align-items: flex-start;
    gap: 12px;
  }
  .brand strong {
    font-size: 20px;
    line-height: 1.08;
  }
  .brand span {
    font-size: 12px;
    white-space: normal;
    text-overflow: clip;
  }
  .brand-mark {
    width: 44px;
    height: 44px;
  }
  .brand strong {
    white-space: normal;
    text-overflow: clip;
  }
  .page-header h1 { font-size: 28px; }
  .page-summary { font-size: 14px; }
  .content { padding: var(--space-5) var(--space-4) var(--space-6); }
  .topbar { padding-left: var(--space-4); padding-right: var(--space-4); }
}
