/* Zcash Agora: one stylesheet, no framework. */
:root {
  --bg: #fbf8f1;
  --bg-2: #f1ebdd;
  --ink: #1c1a16;
  --ink-2: #514b40;
  --muted: #7d7565;
  --line: #d9d0bd;
  --accent: #b8860b;      /* lantern amber */
  --accent-ink: #6e4f00;
  --people: #2f6b3a;
  --coins: #8a5a00;
  --warn-bg: #fff4d6;
  --code-bg: #f3efe5;
  --max: 72ch;
  --wide: 100ch;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #15130f; --bg-2: #1e1b15; --ink: #ece6d8; --ink-2: #c9c1ad; --muted: #928a76;
    --line: #3a3528; --accent: #e3b341; --accent-ink: #f1cf74; --people: #7fc48c; --coins: #e0a83a;
    --warn-bg: #2b2412; --code-bg: #221f18;
  }
}
:root[data-theme="dark"] {
  --bg: #15130f; --bg-2: #1e1b15; --ink: #ece6d8; --ink-2: #c9c1ad; --muted: #928a76;
  --line: #3a3528; --accent: #e3b341; --accent-ink: #f1cf74; --people: #7fc48c; --coins: #e0a83a;
  --warn-bg: #2b2412; --code-bg: #221f18;
}
* { box-sizing: border-box; }
html { font-size: 17px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  line-height: 1.55;
}
a { color: var(--accent-ink); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent); }
h1, h2, h3 { font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; }
h1 { font-size: 2.2rem; margin: 0 0 .5rem; }
h2 { font-size: 1.5rem; margin: 2.4rem 0 .6rem; }
h3 { font-size: 1.15rem; margin: 1.6rem 0 .4rem; }
p, ul, ol { margin: 0 0 1rem; }
li { margin: .25rem 0; }
code, pre { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .88em; }
code { background: var(--code-bg); padding: .1em .35em; border-radius: 4px; }
pre { background: var(--code-bg); padding: .9rem 1rem; border-radius: 8px; overflow-x: auto; line-height: 1.45; }
pre code { background: none; padding: 0; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }
blockquote { margin: 1rem 0; padding: .2rem 0 .2rem 1rem; border-left: 3px solid var(--accent); color: var(--ink-2); }
small, .muted { color: var(--muted); }
table { border-collapse: collapse; width: 100%; margin: 1rem 0 1.5rem; font-size: .95rem; }
th, td { text-align: left; vertical-align: top; padding: .5rem .6rem; border-bottom: 1px solid var(--line); }
th { font-weight: 600; color: var(--ink-2); border-bottom: 2px solid var(--line); }
td.ok { color: var(--people); } td.bad { color: var(--coins); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.wrap.wide { max-width: var(--wide); }

/* header */
header.top { border-bottom: 1px solid var(--line); background: var(--bg); }
header.top .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1.2rem; padding-top: .8rem; padding-bottom: .8rem; }
.brand { font-weight: 700; font-size: 1.1rem; text-decoration: none; color: var(--ink); display: flex; align-items: center; gap: .5rem; }
.brand svg { width: 22px; height: 22px; }
nav.main { display: flex; flex-wrap: wrap; gap: .2rem .9rem; font-size: .95rem; margin-left: auto; }
nav.main a { text-decoration: none; color: var(--ink-2); padding: .2rem 0; border-bottom: 2px solid transparent; }
nav.main a[aria-current="page"] { border-bottom-color: var(--accent); color: var(--ink); }
nav.main a.cta { background: var(--accent); color: #1c1a16; padding: .25rem .7rem; border-radius: 999px; border: 0; font-weight: 600; }

main { padding: 2.2rem 0 3rem; }
.lede { font-size: 1.2rem; color: var(--ink-2); max-width: 60ch; }
.hero { padding: 1.5rem 0 1rem; }
.hero h1 { font-size: 2.8rem; }
.hero .tag { color: var(--accent-ink); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: .8rem; }

/* the two counts */
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 1.5rem 0; }
@media (max-width: 640px) { .two { grid-template-columns: 1fr; } }
.count { border: 1px solid var(--line); border-radius: 12px; padding: 1.1rem 1.2rem; background: var(--bg-2); }
.count h3 { margin: 0 0 .3rem; font-size: 1rem; text-transform: uppercase; letter-spacing: .06em; }
.count.coins h3 { color: var(--coins); } .count.people h3 { color: var(--people); }
.count .big { font-size: 2.4rem; font-weight: 700; line-height: 1; margin: .3rem 0; }
.count .unit { color: var(--muted); font-size: .9rem; }
.count dl { display: grid; grid-template-columns: auto 1fr; gap: .15rem .8rem; margin: .8rem 0 0; font-size: .92rem; }
.count dt { color: var(--muted); } .count dd { margin: 0; }
.bar { height: 10px; border-radius: 5px; background: var(--line); overflow: hidden; margin: .5rem 0; }
.bar > span { display: block; height: 100%; }
.coins .bar > span { background: var(--coins); } .people .bar > span { background: var(--people); }

.card { border: 1px solid var(--line); border-radius: 12px; padding: 1.1rem 1.2rem; margin: 1.2rem 0; background: var(--bg-2); }
.card.warn { background: var(--warn-bg); border-color: var(--accent); }
.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: .8rem; }
.steps li { position: relative; padding-left: 2.6rem; }
.steps li::before { counter-increment: s; content: counter(s); position: absolute; left: 0; top: .05rem; width: 1.9rem; height: 1.9rem; border-radius: 50%; background: var(--accent); color: #1c1a16; font-weight: 700; display: grid; place-items: center; font-size: .95rem; }
.btn { display: inline-block; background: var(--accent); color: #1c1a16; font-weight: 600; padding: .55rem 1.1rem; border-radius: 999px; text-decoration: none; border: 0; font: inherit; cursor: pointer; }
.btn.secondary { background: transparent; border: 1px solid var(--line); color: var(--ink); }
/* A button that is a link keeps its ink on hover (a:hover would paint it the button's own amber). */
.btn:hover { color: #1c1a16; filter: brightness(1.08); }
.btn.secondary:hover { color: var(--ink); border-color: var(--accent); filter: none; }
.btn:disabled { opacity: .5; cursor: default; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 760px) { .grid3 { grid-template-columns: 1fr; } }
.cite { font-size: .82rem; color: var(--muted); }
.cite a { color: inherit; }
sup a { text-decoration: none; }
footer.bottom { border-top: 1px solid var(--line); padding: 1.5rem 0 2.5rem; font-size: .9rem; color: var(--muted); }
footer.bottom a { color: inherit; }
.toc a { text-decoration: none; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .3rem 1rem; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; overflow-wrap: anywhere; }
.pill { display: inline-block; font-size: .78rem; padding: .1rem .5rem; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); margin-left: .4rem; vertical-align: middle; }

/* A page whose text is centered throughout, tables included. */
.wrap.centered, .wrap.centered h1, .wrap.centered h2, .wrap.centered h3, .wrap.centered p, .wrap.centered th, .wrap.centered td { text-align: center; }
.wrap.centered .lede { margin-left: auto; margin-right: auto; }
.wrap.centered ul { display: inline-block; text-align: left; margin-left: auto; margin-right: auto; }
.wrap.centered td ul { display: block; text-align: center; padding-left: 0; list-style-position: inside; }
.btn.danger { background: transparent; border: 1px solid #b3261e; color: #b3261e; }
.btn.danger:hover { color: #b3261e; filter: none; }

/* The comparison page: two sides, six questions. */
.cmp h1, .cmp h2, .cmp > .lede { text-align: center; }
.cmp > .lede { margin-left: auto; margin-right: auto; }
.cmp .two { gap: 1.2rem; align-items: start; }
.side { border: 1px solid var(--line); border-radius: 12px; padding: 1rem 1.2rem; background: var(--bg-2); }
.side h3, .side h4 { margin: 0 0 .6rem; font-size: .95rem; text-transform: uppercase; letter-spacing: .06em; }
.side.coins h3, .side.coins h4 { color: var(--coins); } .side.people h3, .side.people h4 { color: var(--people); }
.side p:last-child, .side ul:last-child { margin-bottom: 0; }
.side ul { padding-left: 1.1rem; }
.who { font-size: .95rem; margin-top: .8rem; }
.faq { margin: 2.2rem 0; }
.faq h3 { font-size: 1.25rem; text-align: center; margin: 0 0 .8rem; }
.cmp a.q { color: inherit; text-decoration-style: dotted; }
.cmp a.q:hover { color: var(--accent); }
.anim.actors { max-width: none; width: 100%; margin: 0 auto .4rem; }
.anim.fig { max-width: 34rem; margin: 1rem auto 0; }
.anim .vals rect { fill: var(--bg); stroke: var(--ink-2); stroke-width: 1; }
.anim .vals rect.bad { fill: var(--coins); stroke: var(--coins); opacity: .85; }
.anim .chain rect { fill: var(--code-bg); stroke: var(--line); }
.anim .ring .orbit { fill: none; stroke: var(--line); stroke-dasharray: 2 3; }
.anim .ring > circle:not(.orbit) { fill: var(--people); }
.anim .pick line { stroke: var(--coins); stroke-width: 1; opacity: .7; }
.two.single { grid-template-columns: 1fr; }
.side.wide .pair { display: grid; grid-template-columns: 3fr 2fr; gap: 1.2rem; align-items: center; }
@media (max-width: 760px) { .side.wide .pair { grid-template-columns: 1fr; } }
.anim .envl rect { fill: var(--accent); } .anim .envl path { fill: none; stroke: #1c1a16; stroke-width: 1.4; }
.anim .group { fill: none; stroke: var(--coins); stroke-width: 1.2; stroke-dasharray: 4 3; }
.anim .role rect { fill: var(--bg); stroke: var(--line); }
.anim .envs rect { fill: var(--accent); }
/* technical page: table of contents */
.toc { border: 1px solid var(--line); border-radius: 12px; background: var(--bg-2); padding: 1rem 1.3rem; margin: 1.5rem 0 2rem; font-size: .95rem; }
.toc ol { margin: .3rem 0 0; padding-left: 1.4rem; }
.toc .cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2.5rem; }
.toc .cols > ol { margin-top: .4rem; }
.toc .cols > ol > li { margin-bottom: .6rem; }
.toc ol ol { margin: .15rem 0 0; }
.toc li { margin: .15rem 0; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }
@media (max-width: 760px) { .toc .cols { grid-template-columns: 1fr; } }
.tech h2 { margin-top: 2.6rem; }
.tech h3 { margin-top: 1.6rem; }
.tech table { font-size: .9rem; }
.anim.fig.wide { max-width: 40rem; margin: .8rem auto 1.2rem; }
.anim .arr { stroke: var(--ink-2); stroke-width: 1.2; fill: none; }
.anim .ahd { fill: var(--ink-2); }

/* the poll, on the home page */
.poll { border: 2px solid var(--people); border-radius: 14px; padding: 1.3rem 1.5rem 1rem; margin: 1.6rem 0 .5rem; background: var(--bg-2); }
.poll .when { color: var(--people); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: .8rem; margin: 0 0 .5rem; }
.poll h2 { margin: 0 0 .7rem; font-size: 1.8rem; line-height: 1.2; }
.poll .actions { margin: .2rem 0 .8rem; }
.poll .actions .btn { margin: 0 .4rem .5rem 0; }
.poll .muted { margin: 0; font-size: .95rem; }
