/* Scythe — shared styles for the landing page and docs */
:root {
  --bg: #000;
  --green: #00c76b;
  --green-hi: #12e07f;
  --ink: #00c76b;
  --dim: #23b56e;
  --dimmer: rgba(0, 199, 107, 0.62);
  --faint: rgba(0, 199, 107, 0.42);
  --line: rgba(0, 199, 107, 0.28);
  --tint: rgba(0, 199, 107, 0.06);
  --tint-2: rgba(0, 199, 107, 0.12);
  --sans: Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --radius: 14px;
  --pad-x: clamp(20px, 3vw, 56px);
}

* { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 500;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--green-hi); }
::selection { background: var(--green); color: #000; }
:focus-visible { outline: 2px solid var(--green-hi); outline-offset: 3px; border-radius: 6px; }

/* ---------- brand mark ---------- */
.brand {
  position: fixed;
  top: 28px; left: var(--pad-x);
  z-index: 5;
  display: inline-flex; align-items: center; gap: 11px;
  font-size: 24px; font-weight: 700; letter-spacing: -0.02em;
  color: var(--green);
}
.brand .logo { width: 36px; height: 36px; display: block; }
.brand:hover { color: var(--green-hi); }

/* ---------- landing ---------- */
body.home { min-height: 100dvh; display: flex; flex-direction: column; overflow-x: hidden; }
#warp {
  position: fixed; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.hero {
  position: relative; z-index: 1;
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 110px var(--pad-x) 40px;
}
.eyebrow {
  margin: 0 0 22px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dimmer);
}
.hero h1 {
  margin: 0;
  font-size: clamp(54px, 9.8vw, 160px);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.05em;
  color: var(--green);
  text-wrap: balance;
}
.lede {
  max-width: 640px;
  margin: 34px auto 0;
  font-size: clamp(17px, 1.35vw, 21px);
  line-height: 1.6;
  color: var(--dim);
  text-wrap: pretty;
}
.tweet {
  display: inline-flex; align-items: center; flex-wrap: wrap; justify-content: center; gap: 10px;
  margin-top: 34px;
  padding: 14px 24px;
  border: 1.5px solid var(--green);
  border-radius: var(--radius);
  background: var(--tint);
  font-size: clamp(16px, 1.3vw, 20px);
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow: 0 0 40px -10px rgba(0, 199, 107, 0.35);
}
.chip {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 7px;
  background: var(--green);
  color: #000;
  font-weight: 800;
}
.actions {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 20px;
  margin-top: 30px;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 140px;
  padding: 22px 42px;
  border: 0;
  border-radius: 13px;
  background: var(--green);
  color: #000;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { background: var(--green-hi); color: #000; transform: translateY(-1px); box-shadow: 0 10px 30px -12px rgba(0, 199, 107, 0.7); }
.btn:active { transform: translateY(0); }
.ca { margin: 30px 0 0; font-size: 16px; color: var(--dim); }
.ca-value { text-decoration: underline dotted; text-underline-offset: 5px; }
.ca-value.is-set { font-family: var(--mono); font-size: 14px; word-break: break-all; }
.foot {
  position: relative; z-index: 1;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 12px;
  padding: 22px var(--pad-x) 26px;
  font-size: 14px;
  color: var(--dimmer);
}
.foot a { text-decoration: underline dotted; text-underline-offset: 4px; }
.sep { opacity: 0.7; }

#toast {
  position: fixed; left: 50%; bottom: 84px; z-index: 10;
  transform: translate(-50%, 12px);
  max-width: min(92vw, 520px);
  padding: 12px 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #041a0f;
  color: var(--green);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- docs ---------- */
body.docs-page { padding-bottom: 80px; }
.docs {
  max-width: 880px;
  margin: 0 auto;
  padding: 140px var(--pad-x) 40px;
}
.docs .eyebrow { margin-bottom: 18px; }
.docs h1 {
  margin: 0 0 34px;
  font-size: clamp(46px, 7.4vw, 86px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.045em;
}
.docs h2 {
  margin: 78px 0 18px;
  font-size: clamp(26px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: -0.03em;
  scroll-margin-top: 24px;
}
.docs h3 {
  margin: 40px 0 10px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.docs p, .docs li { font-size: clamp(17px, 1.25vw, 19px); line-height: 1.62; color: var(--dim); }
.docs p { margin: 0 0 20px; text-wrap: pretty; }
.docs p strong, .docs li strong { color: var(--green); font-weight: 700; }
.docs a { text-decoration: underline dotted; text-underline-offset: 4px; }
.docs ul, .docs ol { margin: 0 0 22px; padding-left: 26px; }
.docs li { margin: 0 0 10px; padding-left: 4px; }
.docs li::marker { color: var(--green); }
.docs ol li::marker { font-weight: 700; }
.docs code {
  font-family: var(--mono);
  font-size: 0.92em;
  padding: 1px 6px;
  border-radius: 5px;
  background: var(--tint-2);
  color: var(--green);
}
.docs .lead { font-size: clamp(18px, 1.4vw, 21px); }

.toc {
  display: flex; flex-wrap: wrap; gap: 8px 22px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}
.toc li { margin: 0; padding: 0; font-size: 14px; }
.toc a { text-decoration: none; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dimmer); }
.toc a:hover { color: var(--green-hi); }

.tweet-block {
  margin: 24px 0 28px;
  padding: 22px 28px;
  border: 1.5px solid var(--green);
  border-radius: var(--radius);
  background: var(--tint);
  overflow-x: auto;
}
.tweet-block .line {
  display: grid;
  grid-template-columns: minmax(0, max-content) minmax(0, 1fr);
  gap: 6px 36px;
  align-items: baseline;
  padding: 6px 0;
  font-size: 17px;
  white-space: nowrap;
}
.tweet-block .line b { font-weight: 700; color: var(--green); }
.tweet-block .line .note { color: var(--faint); font-weight: 500; }

.callout {
  margin: 26px 0 30px;
  padding: 18px 22px;
  border-left: 3px solid var(--green);
  background: var(--tint);
  border-radius: 0 10px 10px 0;
}
.callout p { margin: 0; }
.callout p + p { margin-top: 10px; }

.scroll { overflow-x: auto; margin: 22px 0 28px; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 16px; }
th, td { padding: 12px 14px 12px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dimmer); }
td { color: var(--dim); }
td:first-child { color: var(--green); font-weight: 700; white-space: nowrap; }
td.num { white-space: nowrap; font-variant-numeric: tabular-nums; }
td.addr, td.addr a { font-family: var(--mono); font-size: 14px; white-space: nowrap; }
.params td:first-child { width: 34%; }
.pairs td code { background: none; padding: 0; font-family: var(--sans); font-size: inherit; }

.live-note { font-size: 14px; color: var(--faint); }
[data-live] { transition: color 0.3s ease; }
[data-live].is-live { color: var(--green); }
.live-badge {
  display: none;
  margin-left: 8px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--green);
  vertical-align: middle;
}
.live-badge.show { display: inline-flex; align-items: center; gap: 6px; }
.live-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--green); }

.qa dt { margin: 26px 0 6px; font-size: 19px; font-weight: 700; color: var(--green); }
.qa dd { margin: 0; font-size: clamp(17px, 1.25vw, 19px); line-height: 1.62; color: var(--dim); }
.docs-foot { margin-top: 90px; padding-top: 26px; border-top: 1px solid var(--line); font-size: 14px; color: var(--dimmer); }

/* ---------- small screens ---------- */
@media (max-width: 720px) {
  .brand { top: 18px; font-size: 21px; }
  .brand .logo { width: 30px; height: 30px; }
  .hero { padding-top: 96px; }
  .hero h1 { font-size: clamp(50px, 15.5vw, 92px); }
  .lede { margin-top: 28px; }
  .tweet { margin-top: 30px; padding: 12px 18px; }
  .actions { gap: 12px; }
  .btn { flex: 1 1 calc(50% - 12px); padding: 18px 20px; min-width: 0; }
  .docs { padding-top: 104px; }
  .tweet-block { padding: 16px 18px; }
  .tweet-block .line { grid-template-columns: 1fr; gap: 2px; white-space: normal; }
  th, td { padding: 10px 10px 10px 0; font-size: 15px; }
}
