/* shardpost.de — palette and rhythm follow nauthilus.org and jmapper.de (navy, slate-blue bars, lime accent). */

:root {
  --navy-950: #0a1528;
  --navy-900: #132034;
  --navy-850: #172742;
  --navy-800: #1b2c4b;
  --navy-700: #263a5f;
  --bar: #516291;
  --lime: #8cc63e;
  --lime-strong: #a3d65c;
  --cyan: #1cbadf;
  --teal: #6fd0c3;
  --rose: #f0708a;
  --amber: #f2c14e;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, Cantarell, "Noto Sans", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --radius: 14px;
  --radius-small: 8px;
  --max: 1180px;
  --nav-h: 60px;

  /* light scheme (doc pages) */
  --bg: #e7ebf3;
  --surface: #ffffff;
  --surface-2: #f3f5fa;
  --text: #1c1e21;
  --muted: #4d5869;
  --border: #d3d9e6;
  --link: #3f6d14;
  --accent-text: #4b8017;
  --code-bg: #eef1f7;
  --shadow: 0 1px 2px rgba(10, 21, 40, .06), 0 8px 24px rgba(10, 21, 40, .06);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: var(--navy-950);
    --surface: var(--navy-900);
    --surface-2: var(--navy-850);
    --text: #e8ecf4;
    --muted: #a8b3c7;
    --border: #2a3b5c;
    --link: var(--lime);
    --accent-text: var(--lime);
    --code-bg: #1d2d4a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  }
}

:root[data-theme="dark"] {
  --bg: var(--navy-950);
  --surface: var(--navy-900);
  --surface-2: var(--navy-850);
  --text: #e8ecf4;
  --muted: #a8b3c7;
  --border: #2a3b5c;
  --link: var(--lime);
  --accent-text: var(--lime);
  --code-bg: #1d2d4a;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
}

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

html { scroll-padding-top: calc(var(--nav-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* The landing page is dark in both schemes, like nauthilus.org. */
body.layout-home { background: var(--navy-950); color: #e8ecf4; }

img { max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 100;
  background: var(--lime); color: var(--navy-950); padding: 8px 14px; border-radius: 8px; font-weight: 700;
}
.skip-link:focus { top: 10px; }

/* ---------- navbar ---------- */
.navbar {
  position: sticky; top: 0; z-index: 50;
  background: var(--bar);
  color: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .06), 0 4px 18px rgba(10, 21, 40, .25);
}
.navbar-inner {
  max-width: var(--max); margin: 0 auto; height: var(--nav-h);
  display: flex; align-items: center; gap: 16px; padding: 0 20px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 700; font-size: 18px; margin-right: auto; }
.brand img { width: 32px; height: 32px; }
.brand-sub { font-weight: 500; opacity: .8; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav-link { color: #fff; text-decoration: none; padding: 6px 12px; border-radius: 8px; font-weight: 500; }
.nav-link:hover { background: rgba(255, 255, 255, .12); }
.nav-link[aria-current="page"] { background: rgba(10, 21, 40, .28); }
.nav-toggle, .theme-toggle {
  display: inline-grid; place-items: center; width: 40px; height: 40px;
  background: transparent; border: 0; color: #fff; border-radius: 8px; cursor: pointer;
}
.nav-toggle:hover, .theme-toggle:hover { background: rgba(255, 255, 255, .12); }
.nav-toggle { display: none; }
.theme-toggle svg { display: none; }
.theme-toggle[data-choice="system"] .icon-system,
.theme-toggle:not([data-choice]) .icon-system,
.theme-toggle[data-choice="light"] .icon-light,
.theme-toggle[data-choice="dark"] .icon-dark { display: block; }
.nav .button-small { margin-left: 6px; }

@media (max-width: 760px) {
  .nav-toggle { display: inline-grid; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: var(--nav-h);
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--bar); padding: 8px 16px 16px; box-shadow: 0 12px 24px rgba(10, 21, 40, .35);
  }
  .nav.open { display: flex; }
  .nav-link { padding: 10px 12px; }
  .theme-toggle { align-self: flex-start; }
  .nav .button-small { margin: 6px 0 0; text-align: center; }
}

/* ---------- buttons ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 26px; border-radius: 8px; border: 2px solid var(--lime);
  background: var(--lime); color: var(--navy-950); font-weight: 700; font-size: 18px; text-decoration: none;
  transition: background .15s, border-color .15s, transform .15s;
}
.button:hover { background: var(--lime-strong); border-color: var(--lime-strong); text-decoration: none; }
.button-outline { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); }
.button-outline:hover { background: rgba(255, 255, 255, .08); border-color: #fff; }
.button-small { padding: 6px 14px; font-size: 15px; }
.button svg { flex: none; }

/* ---------- shared section scaffolding (home) ---------- */
.section { padding: 104px 20px; }
.section-inner { max-width: var(--max); margin: 0 auto; }
.eyebrow {
  margin: 0 0 12px; color: var(--lime); font-size: 13px; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
}
.section h2 {
  margin: 0 0 16px; font-size: clamp(30px, 4.4vw, 44px); line-height: 1.12; letter-spacing: -.02em; color: #fff;
}
.accent { color: var(--lime); }
.lede { margin: 0 auto; max-width: 720px; color: #b4bfd3; font-size: 18px; }
.center { text-align: center; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden; padding: 72px 20px 0; text-align: center;
  background:
    radial-gradient(960px 480px at 50% -10%, rgba(140, 198, 62, .16), transparent 60%),
    radial-gradient(800px 480px at 50% 110%, rgba(81, 98, 145, .5), transparent 70%),
    linear-gradient(180deg, #1c2d50 0%, var(--navy-950) 100%);
}
.pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px;
  border: 1px solid rgba(140, 198, 62, .5); border-radius: 999px; background: rgba(10, 21, 40, .5);
  color: #e8ecf4; font-size: 14px; font-weight: 600;
}
.pill .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 4px rgba(140, 198, 62, .2); }
.hero-icon { position: relative; width: 168px; margin: 36px auto 8px; }
.hero-icon::before {
  content: ""; position: absolute; inset: -40px; border-radius: 50%;
  background: radial-gradient(circle, rgba(111, 208, 195, .35), transparent 65%);
}
.hero-icon img { position: relative; width: 168px; height: 168px; filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .45)); }
.hero h1 {
  margin: 24px auto 0; max-width: 960px; color: #fff;
  font-size: clamp(36px, 6vw, 62px); line-height: 1.06; letter-spacing: -.03em;
}
.hero .lede { margin-top: 22px; font-size: clamp(17px, 2vw, 19px); }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 34px; }
.hero-note { margin: 16px 0 0; color: #8f9bb3; font-size: 14px; }
.hero-note a { color: #c9d3e6; }
.by-line { display: inline-flex; align-items: center; gap: 10px; margin-top: 28px; color: #a8b3c7; font-size: 14px; text-decoration: none; }
.by-line img { width: 38px; height: 28px; }
.by-line:hover { color: #fff; }

/* ---------- value strip ---------- */
.strip { background: var(--navy-900); border-top: 1px solid rgba(255, 255, 255, .06); padding: 28px 20px; }
.strip ul {
  list-style: none; margin: 0 auto; padding: 0; max-width: var(--max);
  display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 36px; color: #c9d3e6; font-weight: 600;
}
.strip li { display: inline-flex; align-items: center; gap: 10px; }
.strip li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--lime); }

/* ---------- sign-in flow diagram ---------- */
.flow-section { background: linear-gradient(180deg, var(--navy-900), var(--navy-950)); }
.flow {
  display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: center; gap: 0;
  max-width: 1040px; margin: 56px auto 0;
}
.node {
  background: var(--navy-800); border: 1px solid rgba(255, 255, 255, .1); border-radius: var(--radius);
  padding: 22px; text-align: left; min-height: 100%;
}
.node.center-node { border-color: rgba(140, 198, 62, .55); box-shadow: 0 0 40px rgba(140, 198, 62, .12); }
.node-kicker { margin: 0; color: #8f9bb3; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.node h3 { margin: 6px 0 10px; color: #fff; font-size: 21px; }
.node ul { margin: 0; padding: 0; list-style: none; }
.node li { font-family: var(--mono); font-size: 13.5px; color: #c9d3e6; padding: 3px 0; }
.node li::before { content: "• "; color: var(--lime); }
.wire { width: 56px; height: 2px; background: repeating-linear-gradient(90deg, var(--lime) 0 6px, transparent 6px 12px); }
.flow-caption { margin: 34px 0 0; color: #b4bfd3; }
@media (max-width: 860px) {
  .flow { grid-template-columns: 1fr; }
  .wire { width: 2px; height: 28px; margin: 0 auto; background: repeating-linear-gradient(180deg, var(--lime) 0 6px, transparent 6px 12px); }
}

/* ---------- feature rows ---------- */
.features { background: var(--navy-950); }
.feature-row {
  display: grid; grid-template-columns: 1fr 1.15fr; gap: 56px; align-items: center; margin-top: 88px;
}
.feature-row:first-of-type { margin-top: 64px; }
.feature-row.flip .feature-media { order: -1; }
.feature-copy h3 { margin: 0 0 12px; color: #fff; font-size: clamp(24px, 3vw, 32px); line-height: 1.15; letter-spacing: -.015em; }
.feature-copy p { color: #b4bfd3; margin: 0 0 18px; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.checks li { position: relative; padding-left: 30px; color: #dbe2ee; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .3em; width: 18px; height: 18px; border-radius: 50%;
  background: rgba(140, 198, 62, .18) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%238cc63e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.feature-media { position: relative; }
.feature-media img { display: block; border-radius: var(--radius); border: 1px solid rgba(255, 255, 255, .1); box-shadow: 0 24px 60px rgba(0, 0, 0, .45); }
@media (max-width: 900px) {
  .feature-row, .feature-row.flip { grid-template-columns: 1fr; gap: 32px; margin-top: 72px; }
  .feature-row.flip .feature-media { order: 0; }
}

/* ---------- cards ---------- */
.cards-section { background: linear-gradient(180deg, var(--navy-950), var(--navy-900)); }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 48px; }
.card {
  background: var(--navy-800); border: 1px solid rgba(255, 255, 255, .08); border-radius: var(--radius);
  padding: 24px; border-left: 3px solid var(--lime);
}
.card:nth-child(3n+2) { border-left-color: var(--cyan); }
.card:nth-child(3n) { border-left-color: var(--amber); }
.card h3 { margin: 0 0 8px; color: #fff; font-size: 19px; }
.card p { margin: 0; color: #b4bfd3; font-size: 16px; }
@media (max-width: 900px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .cards { grid-template-columns: 1fr; } }

/* ---------- requirements / privacy band ---------- */
.req-section { background: var(--navy-950); }
.req-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 48px; }
.panel {
  background: var(--navy-850); border: 1px solid rgba(255, 255, 255, .08); border-radius: var(--radius); padding: 28px;
}
.panel h3 { margin: 0 0 12px; color: #fff; font-size: 21px; }
.panel p { color: #b4bfd3; margin: 0 0 14px; }
.panel .checks li { color: #dbe2ee; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.tags li { font-family: var(--mono); font-size: 13px; padding: 4px 10px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .14); color: #c9d3e6; background: rgba(10, 21, 40, .5); }
@media (max-width: 800px) { .req-grid { grid-template-columns: 1fr; } }

.cta-section {
  text-align: center;
  background:
    radial-gradient(640px 320px at 50% 0, rgba(140, 198, 62, .14), transparent 70%),
    var(--navy-900);
}
.cta-section .hero-actions { margin-top: 28px; }

/* ---------- doc pages ---------- */
.page-head {
  background:
    radial-gradient(700px 300px at 50% -20%, rgba(140, 198, 62, .16), transparent 65%),
    linear-gradient(180deg, #1c2d50, var(--navy-950));
  color: #fff; padding: 64px 20px 56px; text-align: center;
}
.page-head h1 { margin: 0; font-size: clamp(32px, 5vw, 48px); line-height: 1.1; letter-spacing: -.02em; }
.page-head p { margin: 14px auto 0; max-width: 680px; color: #b4bfd3; font-size: 18px; }
.page-head .eyebrow { margin-bottom: 10px; }

.doc-shell { max-width: var(--max); margin: 0 auto; padding: 48px 20px 96px; }
.doc-shell.has-toc { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 48px; align-items: start; }
.doc { max-width: 820px; margin: 0 auto; width: 100%; }
.has-toc .doc { margin: 0; }
.toc {
  position: sticky; top: calc(var(--nav-h) + 24px); max-height: calc(100vh - var(--nav-h) - 48px); overflow: auto;
  font-size: 15px; padding: 18px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
}
.toc-title { margin: 0 0 10px; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a { display: block; padding: 5px 8px; border-radius: 6px; color: var(--text); text-decoration: none; line-height: 1.35; }
.toc a::before { content: counter(toc, decimal-leading-zero) "  "; color: var(--muted); font-family: var(--mono); font-size: 12px; }
.toc a:hover { background: var(--surface-2); }
.toc a[aria-current] { background: var(--surface-2); color: var(--accent-text); font-weight: 600; box-shadow: inset 3px 0 0 var(--lime); }
@media (max-width: 960px) {
  .doc-shell.has-toc { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .toc { position: static; max-height: none; }
}

.prose { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 40px 44px; box-shadow: var(--shadow); }
@media (max-width: 640px) { .prose { padding: 26px 20px; } }
.prose > :first-child { margin-top: 0; }
.prose h2 { margin: 2.2em 0 .6em; font-size: 27px; line-height: 1.2; letter-spacing: -.01em; padding-top: .9em; border-top: 1px solid var(--border); }
.prose h2:first-child, .prose .intro + h2 { border-top: 0; padding-top: 0; }
.prose h3 { margin: 1.7em 0 .5em; font-size: 20px; line-height: 1.3; }
.prose h4 { margin: 1.4em 0 .4em; font-size: 17px; }
.prose p, .prose ul, .prose ol, .prose dl, .prose table { margin: 0 0 1em; }
.prose li { margin: .3em 0; }
.prose li::marker { color: var(--accent-text); }
.prose code, .prose kbd {
  font-family: var(--mono); font-size: .86em; background: var(--code-bg); border: 1px solid var(--border);
  border-radius: 5px; padding: .08em .38em; white-space: nowrap;
}
.prose kbd { border-bottom-width: 2px; }
.prose .path { font-weight: 600; white-space: nowrap; }
.prose .intro { font-size: 18.5px; color: var(--muted); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15.5px; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.prose address { font-style: normal; }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }
.prose figure { margin: 1.4em 0; }
.prose figure img { border-radius: var(--radius-small); border: 1px solid var(--border); }
.prose figcaption { font-size: 14px; color: var(--muted); margin-top: 6px; }
.prose .stand { color: var(--muted); font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }

.note {
  margin: 1.2em 0; padding: 14px 18px; border-radius: var(--radius-small);
  background: var(--surface-2); border: 1px solid var(--border); border-left: 4px solid var(--lime);
}
.note.warn { border-left-color: var(--amber); }
.note > :last-child { margin-bottom: 0; }
.note strong:first-child { color: var(--accent-text); }

.lang-note {
  display: flex; gap: 10px; align-items: baseline; margin: 0 0 1.6em; padding: 12px 16px;
  border-radius: var(--radius-small); background: var(--surface-2); border: 1px dashed var(--border); font-size: 15px; color: var(--muted);
}

/* ---------- FAQ ---------- */
.faq-tools { margin: 0 0 28px; }
.faq-tools input {
  width: 100%; font: inherit; padding: 13px 16px 13px 44px; border-radius: 10px; color: var(--text);
  border: 1px solid var(--border); background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='11' cy='11' r='7' fill='none' stroke='%237d8799' stroke-width='2'/%3E%3Cpath d='M20 20l-4-4' stroke='%237d8799' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") 14px center / 20px no-repeat;
}
.faq-group h2 { font-size: 22px; }
.faq-item { border: 1px solid var(--border); border-radius: 10px; margin: 0 0 10px; background: var(--surface-2); }
.faq-item summary {
  cursor: pointer; list-style: none; padding: 14px 48px 14px 18px; font-weight: 600; position: relative;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ""; position: absolute; right: 18px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
  border-right: 2px solid var(--accent-text); border-bottom: 2px solid var(--accent-text); transform: rotate(45deg); transition: transform .15s;
}
.faq-item[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq-item .answer { padding: 0 18px 6px; }
.faq-item[open] { background: var(--surface); }

/* ---------- support cards ---------- */
.support-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0 0 1.6em; }
.support-card { display: block; padding: 20px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text); text-decoration: none; }
.support-card:hover { border-color: var(--lime); }
.support-card strong { display: block; font-size: 18px; margin-bottom: 4px; color: var(--accent-text); }
.support-card span { color: var(--muted); font-size: 15px; }
@media (max-width: 760px) { .support-grid { grid-template-columns: 1fr; } }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 96px 20px 120px; }
.notfound img { width: 120px; }

/* ---------- footer ---------- */
.footer { background: var(--bar); color: #e8ecf4; padding: 48px 20px 24px; }
.footer-inner { max-width: var(--max); margin: 0 auto; display: flex; flex-wrap: wrap; gap: 40px; justify-content: space-between; }
.footer-brand { display: flex; gap: 16px; align-items: center; max-width: 340px; }
.footer-brand p { margin: 0; font-size: 15px; line-height: 1.5; }
.rns-mark { flex: none; display: grid; place-items: center; width: 92px; height: 72px; border-radius: 12px; background: #fff; }
.rns-mark img { width: 72px; height: 52px; }
.footer-cols { display: flex; flex-wrap: wrap; gap: 32px 64px; }
.footer-cols div { display: flex; flex-direction: column; gap: 6px; }
.footer-title { margin: 0 0 4px; font-weight: 700; color: #fff; }
.footer a { color: #e8ecf4; text-decoration: none; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer-copy { max-width: var(--max); margin: 36px auto 0; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .18); font-size: 14px; color: #d0d7e6; text-align: center; }

@media print {
  .navbar, .footer, .toc, .skip-link { display: none; }
  .prose { border: 0; box-shadow: none; padding: 0; }
  body { background: #fff; color: #000; }
}

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.feature-copy code { font-family: var(--mono); font-size: .9em; padding: .05em .35em; border-radius: 5px; background: rgba(255, 255, 255, .08); color: #fff; }
.panel .spaced { margin-top: 16px; }
body.layout-home .section a:not(.button) { color: var(--lime); }
.page-head p.eyebrow { color: var(--lime); margin: 0 0 10px; }
.feature-row > * { min-width: 0; }
.doc-shell > * { min-width: 0; }
.prose .path { white-space: normal; }
.prose code { white-space: normal; overflow-wrap: anywhere; }

/* ---------- sister projects ---------- */
.family-section { background: linear-gradient(180deg, var(--navy-950), var(--navy-900)); }
.family { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 52px; }
.project {
  display: flex; flex-direction: column; gap: 12px; padding: 26px; border-radius: var(--radius);
  background: var(--navy-800); border: 1px solid rgba(255, 255, 255, .08); color: inherit; text-decoration: none;
  transition: border-color .15s, transform .15s;
}
a.project:hover { border-color: rgba(140, 198, 62, .6); transform: translateY(-2px); }
.project.current { border-color: rgba(111, 208, 195, .45); }
.project-logo { height: 56px; display: flex; align-items: center; }
.project-logo img { max-height: 56px; width: auto; }
.project-logo .wordmark { font-family: var(--mono); font-weight: 700; font-size: 15px; color: var(--lime); border: 1px solid rgba(140, 198, 62, .5); border-radius: 10px; padding: 12px 14px; }
.project .node-kicker { margin: 0; }
.project h3 { margin: 0; color: #fff; font-size: 22px; }
.project p { margin: 0; color: #b4bfd3; font-size: 16px; }
.project .more { margin-top: auto; padding-top: 6px; color: var(--lime); font-weight: 600; font-size: 15px; }
.family-note { margin: 28px auto 0; max-width: 760px; text-align: center; color: #8f9bb3; font-size: 15px; }
@media (max-width: 900px) { .family { grid-template-columns: 1fr; } }

/* ---------- navbar extras ---------- */
.button-github { gap: 6px; margin-left: 8px; background: transparent; color: #fff; border-color: rgba(255, 255, 255, .55); font-size: 15px; }
.button-github:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }
@media (max-width: 760px) { .button-github { margin: 8px 0 0; align-self: flex-start; } }

/* ---------- hero (product) ---------- */
.hero-mark { position: relative; width: 132px; margin: 36px auto 4px; }
.hero-mark::before {
  content: ""; position: absolute; inset: -44px; border-radius: 50%;
  background: radial-gradient(circle, rgba(28, 186, 223, .3), transparent 65%);
}
.hero-mark img { position: relative; width: 132px; height: 132px; filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .45)); }
.hero { padding-bottom: 88px; }
.hero .stack-figure { margin-top: 56px; }

/* ---------- stack diagram ---------- */
.stack-figure { max-width: 1180px; margin: 48px auto 0; text-align: left; }
.stack-scroll { overflow-x: auto; border-radius: var(--radius); border: 1px solid rgba(255, 255, 255, .1);
  background: radial-gradient(900px 400px at 60% 40%, rgba(81, 98, 145, .35), transparent 70%), rgba(10, 21, 40, .65);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .4); }
.stack-svg { display: block; width: 100%; min-width: 900px; height: auto; }
.stack-svg text { font-family: var(--font); fill: #e8ecf4; }
.stack-svg .t-kicker { font-size: 11px; font-weight: 700; letter-spacing: .14em; fill: #8f9bb3; }
.stack-svg .t-title { font-size: 19px; font-weight: 700; fill: #fff; }
.stack-svg .t-line { font-size: 13px; fill: #c9d3e6; font-family: var(--mono); }
.stack-svg .t-small { font-size: 12px; fill: #b4bfd3; }
.stack-svg .t-edge { font-size: 11.5px; fill: #c9d3e6; font-family: var(--mono); }
.stack-svg .box { fill: #1b2c4b; stroke: rgba(255, 255, 255, .14); stroke-width: 1; }
.stack-svg .box-inner { fill: #263a5f; stroke: rgba(255, 255, 255, .12); stroke-width: 1; }
.stack-svg .chip { fill: rgba(140, 198, 62, .14); stroke: rgba(140, 198, 62, .55); stroke-width: 1; }
.stack-svg .chip-text { font-size: 11px; font-family: var(--mono); fill: #dbefc0; }
.stack-svg .pool { stroke-width: 1; }
.stack-svg .pool-index { fill: rgba(111, 208, 195, .2); stroke: #6fd0c3; }
.stack-svg .pool-data { fill: rgba(28, 186, 223, .18); stroke: #1cbadf; }
.stack-svg .pool-system { fill: rgba(242, 193, 78, .16); stroke: #f2c14e; }
.stack-svg .accent-sp { stroke: rgba(140, 198, 62, .7); stroke-width: 1.5; }
.stack-svg .accent-na { stroke: rgba(28, 186, 223, .7); stroke-width: 1.5; }
.stack-svg .accent-jm { stroke: rgba(111, 208, 195, .7); stroke-width: 1.5; }
.stack-svg .accent-ce { stroke: rgba(242, 193, 78, .7); stroke-width: 1.5; }
.stack-svg .wire { fill: none; stroke: rgba(200, 212, 235, .35); stroke-width: 1.6; }
.stack-svg .flow { fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: 2 12; }
.stack-svg .flow-lime { stroke: #8cc63e; }
.stack-svg .flow-cyan { stroke: #1cbadf; }
.stack-svg .flow-teal { stroke: #6fd0c3; }
.stack-svg .flow-amber { stroke: #f2c14e; }
.stack-svg .flow-rose { stroke: #f0708a; }
.stack-svg .arrow { fill: rgba(200, 212, 235, .6); }
@media (prefers-reduced-motion: no-preference) {
  .stack-svg .flow { animation: flow 1.6s linear infinite; }
  .stack-svg .flow-slow { animation-duration: 2.6s; }
}
@keyframes flow { to { stroke-dashoffset: -28; } }
.stack-svg .node { cursor: pointer; outline: none; }
.stack-svg .node .box, .stack-svg .node .box-inner { transition: fill .15s, stroke .15s; }
.stack-svg .node:hover .box, .stack-svg .node:focus-visible .box { fill: #22365b; stroke: rgba(140, 198, 62, .8); }
.stack-svg .node[aria-pressed="true"] .box { fill: #22365b; stroke: #8cc63e; stroke-width: 2; }
.stack-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 14px 4px 0; color: #a8b3c7; font-size: 14px; }
.stack-legend span { display: inline-flex; align-items: center; gap: 8px; }
.stack-legend i { width: 22px; height: 0; border-top: 3px dotted; }
.legend-lime i { border-color: #8cc63e; } .legend-cyan i { border-color: #1cbadf; }
.legend-teal i { border-color: #6fd0c3; } .legend-amber i { border-color: #f2c14e; } .legend-rose i { border-color: #f0708a; }
.stack-hint { margin: 10px 4px 0; color: #8f9bb3; font-size: 14px; }
.stack-detail {
  margin-top: 18px; padding: 22px 26px; border-radius: var(--radius); background: var(--navy-800);
  border: 1px solid rgba(255, 255, 255, .1); border-left: 3px solid var(--lime); color: #dbe2ee; min-height: 120px;
}
.stack-detail h3 { margin: 0 0 8px; color: #fff; font-size: 20px; }
.stack-detail p { margin: 0 0 10px; color: #c9d3e6; }
.stack-detail p:last-child { margin-bottom: 0; }
.stack-detail code { font-family: var(--mono); font-size: .9em; padding: .05em .35em; border-radius: 5px; background: rgba(255, 255, 255, .08); color: #fff; }
.stack-details-src { display: none; }

/* ---------- product sections ---------- */
.pool-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 48px; }
.pool-card { background: var(--navy-800); border: 1px solid rgba(255, 255, 255, .08); border-radius: var(--radius); padding: 24px; border-top: 3px solid var(--teal); }
.pool-card.data { border-top-color: var(--cyan); }
.pool-card.system { border-top-color: var(--amber); }
.pool-card h3 { margin: 6px 0 8px; color: #fff; font-size: 20px; }
.pool-card p { margin: 0 0 10px; color: #b4bfd3; font-size: 16px; }
.pool-card code, .card code, .panel code, .project code {
  font-family: var(--mono); font-size: .88em; padding: .05em .35em; border-radius: 5px; background: rgba(255, 255, 255, .08); color: #fff;
}
@media (max-width: 900px) { .pool-grid { grid-template-columns: 1fr; } }

.terminal {
  margin: 0; border-radius: var(--radius); overflow: hidden; background: #0d1830;
  border: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 24px 60px rgba(0, 0, 0, .45);
}
.terminal-bar { display: flex; align-items: center; gap: 7px; padding: 10px 14px; background: #172742; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.terminal-bar i { width: 11px; height: 11px; border-radius: 50%; background: #f0708a; }
.terminal-bar i:nth-child(2) { background: #f2c14e; } .terminal-bar i:nth-child(3) { background: #8cc63e; }
.terminal-bar span { margin-left: 8px; color: #8f9bb3; font-size: 13px; font-family: var(--mono); }
.terminal pre { margin: 0; padding: 18px 20px; overflow-x: auto; font-family: var(--mono); font-size: 13.5px; line-height: 1.65; color: #dbe2ee; }
.terminal .c { color: #8f9bb3; } .terminal .p { color: var(--lime); }
.terminal figcaption { padding: 0 20px 16px; color: #8f9bb3; font-size: 13px; }

.rfc-cloud { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.rfc-cloud li { font-family: var(--mono); font-size: 13px; padding: 5px 11px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .14); color: #c9d3e6; background: rgba(10, 21, 40, .5); }
.rfc-cloud li.k { border-color: rgba(140, 198, 62, .55); color: #dbefc0; }

.not-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.not-list li { position: relative; padding-left: 30px; color: #dbe2ee; }
.not-list li::before {
  content: ""; position: absolute; left: 0; top: .3em; width: 18px; height: 18px; border-radius: 50%;
  background: rgba(240, 112, 138, .16) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5 5l6 6M11 5l-6 6' fill='none' stroke='%23f0708a' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.steps { counter-reset: step; list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; }
.steps li { counter-increment: step; position: relative; padding: 16px 18px 16px 62px; border-radius: 12px; background: var(--navy-800); border: 1px solid rgba(255, 255, 255, .08); color: #c9d3e6; }
.steps li::before {
  content: counter(step); position: absolute; left: 16px; top: 14px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(140, 198, 62, .16); color: var(--lime); font-weight: 700; font-size: 15px;
}
.steps strong { color: #fff; }
.steps code { font-family: var(--mono); font-size: .88em; padding: .05em .35em; border-radius: 5px; background: rgba(255, 255, 255, .08); color: #fff; }
.walk { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; margin-top: 56px; align-items: start; }
.walk h3 { margin: 0 0 6px; color: #fff; font-size: 24px; }
.walk > div > p { color: #b4bfd3; margin: 0; }
.walk-more { margin-top: 16px !important; font-size: 15px; }
@media (max-width: 900px) { .walk { grid-template-columns: 1fr; gap: 40px; } }

/* ---------- docs ---------- */
body.layout-docs .page-head { padding: 52px 20px 44px; }
.docs-shell { max-width: 1440px; margin: 0 auto; padding: 36px 20px 96px; display: grid; gap: 32px; align-items: start;
  grid-template-columns: 250px minmax(0, 1fr); }
.docs-shell.has-toc { grid-template-columns: 250px minmax(0, 1fr) 230px; }
.docs-shell > * { min-width: 0; }
.docs-shell .doc { max-width: none; margin: 0; }
.docs-side { position: sticky; top: calc(var(--nav-h) + 20px); max-height: calc(100vh - var(--nav-h) - 40px); overflow: auto; padding-right: 4px; }
.docnav { font-size: 15px; margin-top: 16px; }
.docnav-title { margin: 18px 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.docnav ul { list-style: none; margin: 0; padding: 0; }
.docnav a { display: block; padding: 4px 10px; border-radius: 6px; color: var(--text); text-decoration: none; line-height: 1.35; }
.docnav a:hover { background: var(--surface); }
.docnav a[aria-current] { background: var(--surface); color: var(--accent-text); font-weight: 600; box-shadow: inset 3px 0 0 var(--lime); }
.docs-shell .toc { font-size: 14px; }
.toc-inline { display: none; margin: 0 0 1.6em; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius-small); background: var(--surface-2); font-size: 15px; }
.toc-inline ol { margin: 0; padding-left: 1.4em; columns: 2; column-gap: 32px; }
.toc-inline li { break-inside: avoid; margin: .15em 0; }
.toc-inline a { color: var(--text); }
@media (max-width: 1280px) {
  .docs-shell.has-toc { grid-template-columns: 250px minmax(0, 1fr); }
  .docs-shell > .toc { display: none; }
  .toc-inline { display: block; }
}
@media (max-width: 900px) {
  .docs-shell, .docs-shell.has-toc { grid-template-columns: minmax(0, 1fr); }
  .docs-side { position: static; max-height: none; }
  .docnav { display: none; }
  .docs-home .docnav { display: block; }
  .toc-inline ol { columns: 1; }
}
.docsearch { position: relative; }
.docsearch input {
  width: 100%; font: inherit; font-size: 15px; padding: 10px 12px 10px 38px; border-radius: 10px; color: var(--text);
  border: 1px solid var(--border); background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='11' cy='11' r='7' fill='none' stroke='%237d8799' stroke-width='2'/%3E%3Cpath d='M20 20l-4-4' stroke='%237d8799' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") 11px center / 18px no-repeat;
}
.doc-results {
  position: absolute; z-index: 40; left: 0; top: calc(100% + 6px); width: min(560px, calc(100vw - 40px)); max-height: 70vh; overflow: auto;
  margin: 0; padding: 6px; list-style: none; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow);
}
.doc-results a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--text); text-decoration: none; }
.doc-results a:hover, .doc-results a:focus, .doc-results a.active { background: var(--surface-2); outline: none; }
.doc-results .r-where { display: block; font-size: 12px; color: var(--muted); letter-spacing: .04em; }
.doc-results .r-title { display: block; font-weight: 600; color: var(--accent-text); }
.doc-results .r-snip { display: block; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.doc-results mark { background: rgba(140, 198, 62, .3); color: inherit; border-radius: 3px; padding: 0 1px; }
.doc-results .r-empty { padding: 10px 12px; color: var(--muted); font-size: 14px; }

.prose pre {
  margin: 0 0 1.2em; padding: 14px 16px; overflow-x: auto; border-radius: var(--radius-small);
  background: #0d1830; color: #dbe2ee; border: 1px solid var(--border); font-size: 13.5px; line-height: 1.55;
}
.prose pre code { font-family: var(--mono); font-size: inherit; background: none; border: 0; padding: 0; white-space: pre; overflow-wrap: normal; color: inherit; }
.prose img { display: block; margin: 1.2em auto; background: #fff; border-radius: var(--radius-small); border: 1px solid var(--border); padding: 12px; }
.prose blockquote { margin: 0 0 1em; padding: 4px 18px; border-left: 4px solid var(--border); color: var(--muted); }
.prose table code { white-space: normal; }
.prose h2 code, .prose h3 code, .prose h4 code { font-size: .82em; }
.prose h3[id], .prose h4[id] { scroll-margin-top: calc(var(--nav-h) + 16px); }
.doc-source { margin-top: 2.4em !important; padding-top: 1em; border-top: 1px solid var(--border); font-size: 14px; color: var(--muted); }

.doc-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 0 0 1.2em; }
.doc-card { display: block; padding: 16px 18px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text); text-decoration: none; }
.doc-card:hover { border-color: var(--lime); }
.doc-card strong { display: block; color: var(--accent-text); margin-bottom: 2px; }
.doc-card span { color: var(--muted); font-size: 15px; line-height: 1.45; display: block; }
@media (max-width: 700px) { .doc-cards { grid-template-columns: 1fr; } }
.paths { display: grid; gap: 12px; margin: 0 0 1.4em; }
.path-card { padding: 14px 18px; border-radius: 12px; border: 1px solid var(--border); border-left: 4px solid var(--lime); background: var(--surface-2); }
.path-card .node-kicker { color: var(--muted); }
.path-card p:last-child { margin: 4px 0 0; }
.man-list { padding-left: 1.2em; }

/* mandoc output */
.manpage table.head, .manpage table.foot { width: 100%; display: table; font-size: 13px; color: var(--muted); margin: 0 0 1.2em; }
.manpage table.head td, .manpage table.foot td { border: 0; padding: 0; }
.manpage .head-vol { text-align: center; }
.manpage .head-rtitle, .manpage .foot-os { text-align: right; }
.manpage section.Sh > h2 { font-size: 21px; letter-spacing: .04em; }
.manpage dl.Bl-tag dt { font-weight: 600; margin-top: .7em; }
.manpage dl.Bl-tag dd { margin: .2em 0 0 1.6em; }
.manpage .Bd-indent { margin-left: 1.6em; }
.manpage pre { white-space: pre; }
.manpage .Pp { margin: 0 0 1em; }
/* In the sidebar the results flow with the page; an absolute list would be clipped by its scroll box. */
.docs-side .doc-results { position: static; width: auto; max-height: 60vh; margin-top: 8px; }
.prose table code { overflow-wrap: break-word; white-space: normal; }
.docs-back { display: none; margin: 0 0 12px; font-weight: 600; text-decoration: none; }
@media (max-width: 900px) { .docs-back { display: inline-block; } }
