/* The Sovereign Network: a paper. System type, thin rules, nothing loaded. */
:root {
  --bg: #ffffff;
  --text: #161616;
  --muted: #6b6b6b;
  --rule: #e2e2e2;
  --soft: #f5f5f5;
  --line: #9a9a9a;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111111;
    --text: #e9e9e9;
    --muted: #9a9a9a;
    --rule: #2c2c2c;
    --soft: #1a1a1a;
    --line: #6e6e6e;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
main { max-width: 700px; margin: 0 auto; padding: 72px 24px 64px; }
a { color: inherit; text-decoration-color: var(--line); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
strong, b { font-weight: 600; }
code { font: 0.88em ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: var(--soft); padding: 1px 5px; border-radius: 4px; }

/* Title */
.title { margin-bottom: 40px; }
.mark { width: 30px; height: 30px; display: block; margin-bottom: 28px; }
.mark path, .mark circle { fill: none; stroke: var(--text); stroke-width: 2; stroke-linecap: round; }
h1 { font-size: 34px; line-height: 1.15; font-weight: 500; letter-spacing: -0.015em; margin: 0; }
.home-link { display: block; width: 30px; color: inherit; }
.line { font-size: 21px; line-height: 1.4; color: var(--muted); margin: 8px 0 0; }
.meta { font-size: 14px; color: var(--muted); margin: 20px 0 0; }

/* The opening figure: nodes and links, bytes moving along two of them. */
.nodes { margin: 0 0 48px; padding: 0; }
.nodes svg { display: block; width: 100%; height: auto; }
.nodes .link { fill: none; stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.nodes .node circle { fill: var(--bg); stroke: var(--text); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.nodes .byte { fill: var(--text); opacity: 0; }
.nodes .b1 { animation: b1 4.8s ease-in-out infinite; }
.nodes .b2 { animation: b2 4.8s ease-in-out 2.4s infinite; }
@keyframes b1 {
  0% { transform: translate(265px, 160px); opacity: 0; }
  6% { opacity: 1; }
  30% { transform: translate(390px, 110px); opacity: 1; }
  36%, 100% { transform: translate(390px, 110px); opacity: 0; }
}
@keyframes b2 {
  0% { transform: translate(520px, 60px); opacity: 0; }
  6% { opacity: 1; }
  30% { transform: translate(640px, 110px); opacity: 1; }
  36%, 100% { transform: translate(640px, 110px); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .nodes .byte { animation: none; } }
.nodes figcaption, figure figcaption { font-size: 14px; line-height: 1.5; color: var(--muted); margin-top: 14px; }

/* The landing: what it is, in large plain type. */
.home main { max-width: 1120px; padding-top: 40px; }
.top { max-width: 1120px; margin: 0 auto; padding: 24px 24px 0; display: flex; align-items: center; justify-content: space-between; font-size: 15px; }
.top a { text-decoration: none; }
.top .name { display: flex; align-items: center; gap: 10px; font-weight: 500; }
.top .mark { width: 22px; height: 22px; margin: 0; }
.home h1 { font-size: clamp(40px, 6.6vw, 92px); line-height: 1.02; font-weight: 600; letter-spacing: -0.035em; max-width: 13em; margin: 64px 0 0; }
.home .line { font-size: clamp(20px, 2.1vw, 28px); line-height: 1.35; color: var(--muted); max-width: 30em; margin: 28px 0 0; }
.home .nodes { margin: 56px 0 64px; max-width: 760px; }
.ideas { margin: 0 0 48px; border-top: 1px solid var(--rule); display: grid; grid-template-columns: 1fr 1fr; column-gap: 56px; }
.ideas div { padding: 28px 0 30px; border-bottom: 1px solid var(--rule); }
.ideas dt { font-size: clamp(24px, 2.4vw, 32px); line-height: 1.15; font-weight: 600; letter-spacing: -0.02em; }
.ideas dd { margin: 10px 0 0; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.45; color: var(--muted); }
.next { margin: 0; font-size: 21px; }
.next a { text-decoration: none; font-weight: 500; }
.next a:hover { text-decoration: underline; text-decoration-color: var(--line); }
.home .end { margin-top: 72px; }

/* Abstract and contents */
.label { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.abstract { border-top: 1px solid var(--rule); padding-top: 24px; margin-bottom: 32px; }
.abstract p { margin: 0; }
.toc { border-top: 1px solid var(--rule); padding-top: 24px; margin-bottom: 16px; }
.toc ol { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 32px; }
.toc li { break-inside: avoid; }
.toc a { display: block; padding: 3px 0; text-decoration: none; }
.toc a:hover { text-decoration: underline; text-decoration-color: var(--line); }
.n { display: inline-block; min-width: 1.6em; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Sections */
section { border-top: 1px solid var(--rule); margin-top: 40px; padding-top: 28px; scroll-margin-top: 16px; }
.abstract, .toc { margin-top: 0; }
h2 { font-size: 21px; line-height: 1.3; font-weight: 600; letter-spacing: -0.005em; margin: 0 0 12px; }
p { margin: 0 0 14px; }
ul { margin: 0 0 14px; padding-left: 1.2em; }
li { margin-bottom: 6px; }
li::marker { color: var(--muted); }

/* Tables */
.table { overflow-x: auto; margin: 4px 0 16px; }
table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; }
th { text-align: left; font-weight: 600; color: var(--muted); font-size: 13px; letter-spacing: 0.02em; }
th, td { padding: 9px 16px 9px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
td:first-child { font-weight: 600; white-space: nowrap; }

/* Figure 1 */
figure { margin: 24px 0; }
.plate { border: 1px solid var(--rule); border-radius: 6px; padding: 24px; }
.plate svg { display: block; width: 100%; max-width: 420px; height: auto; margin: 0 auto; }
.tie { fill: none; stroke: var(--line); stroke-width: 1.5; }
.tie.later { stroke-dasharray: 4 5; }
.node { fill: var(--bg); stroke: var(--text); stroke-width: 1.5; }
.node.dim { stroke: var(--line); }
.fig-dot { fill: var(--text); }
.fig-label { font: 600 10px/1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif; letter-spacing: 0.08em; fill: var(--muted); }
.fig-name { font: 12px/1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif; fill: var(--text); }
.fig-name.dim { fill: var(--muted); }
figcaption b { color: var(--text); font-weight: 600; margin-right: 4px; }

/* End */
.end { border-top: 1px solid var(--rule); margin-top: 48px; padding-top: 24px; font-size: 14px; color: var(--muted); }
.end p { margin: 0 0 6px; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  main { padding: 44px 16px 48px; }
  h1 { font-size: 28px; }
  .line { font-size: 18px; }
  .toc ol { columns: 1; }
  .top { padding: 18px 16px 0; }
  .home main { padding-top: 16px; }
  .home h1 { margin-top: 40px; letter-spacing: -0.03em; }
  .home .nodes { margin: 40px 0 44px; }
  .ideas { grid-template-columns: 1fr; }
  .ideas div { padding: 22px 0 24px; }
  .plate { padding: 16px; }
  section { margin-top: 32px; padding-top: 24px; }
}
