/* frizz.sh — reads like a rendered markdown document in the board's own skin: the same dark tokens as
   packages/web/src/styles.css, JetBrains Mono (first in the app's --font-mono stack) for headings and
   code, the system sans for reading text. Heading rules and code chips mirror GitHub's markdown. */

@font-face { font-family: "JetBrains Mono"; font-weight: 400; font-style: normal; font-display: swap; src: url("/fonts/JetBrainsMono-Regular.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 500; font-style: normal; font-display: swap; src: url("/fonts/JetBrainsMono-Medium.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 600; font-style: normal; font-display: swap; src: url("/fonts/JetBrainsMono-SemiBold.woff2") format("woff2"); }

:root {
  --bg: #0d0e10;
  --panel: #131519;
  --elevated: #1c1f25;
  --border: #26282d;
  --border-strong: #33363c;
  --fg: #e6e7e9;
  --fg-2: #b6b9bf;
  --muted: #8b8f96;
  --accent: #e8b923;
  --radius: 12px;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", "Cascadia Mono", Consolas, Menlo, monospace;
  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --measure: 760px;
  --wide: 1120px;
  --gutter: 24px;
}

* { box-sizing: border-box; }
html { color-scheme: dark; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: underline; text-decoration-color: var(--border-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }
code, pre { font-family: var(--mono); }
p code, li code { font-size: 0.875em; background: var(--panel); border: 1px solid var(--border); border-radius: 5px; padding: 0.08em 0.36em; white-space: nowrap; }
p { margin: 0 0 1em; }

/* Top bar. */
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 28px;
  height: 52px; padding: 0 var(--gutter);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  font-family: var(--mono); font-size: 13px;
}
.wordmark { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font-weight: 500; font-size: 14px; }
.wordmark img { border-radius: 5px; display: block; }
.top-nav { display: flex; gap: 22px; margin-left: auto; }
.top-nav a { color: var(--muted); text-decoration: none; white-space: nowrap; }
.top-nav a:hover { color: var(--fg); }
.top-nav a.ext::after { content: "\2197"; margin-left: 3px; font-size: 11px; }

main { padding: 0 var(--gutter) 40px; }

/* The document column. */
.doc { max-width: var(--measure); margin: 0 auto; }
.doc:first-child { padding-top: 56px; }
.mark { width: 112px; margin-bottom: 20px; }
.mark svg { display: block; width: 100%; height: auto; }
/* JS sets the dash to the path length and lets the transition unroll it — a single stroke, drawn once. */
#fff-path { transition: stroke-dashoffset 1.7s cubic-bezier(0.55, 0, 0.2, 1) 0.12s; }
h1, h2, h3 { font-family: var(--mono); font-weight: 500; line-height: 1.25; margin: 0; }
h1 { font-size: 40px; letter-spacing: -0.03em; margin-bottom: 8px; }
.lede { font-size: 19px; color: var(--fg-2); margin-bottom: 20px; }
/* GitHub-markdown H2: a hairline under the heading, generous space above. */
h2 { font-size: 22px; letter-spacing: -0.01em; padding-bottom: 8px; border-bottom: 1px solid var(--border); margin: 44px 0 14px; }
h3 { font-size: 17px; margin-bottom: 8px; }
.doc ul { margin: 0 0 1em; padding-left: 1.4em; }
.doc li { margin: 0.3em 0; }
.doc li::marker { color: var(--muted); }

.term {
  margin: 4px 0 16px; padding: 14px 18px;
  background: var(--panel); border: 1px solid var(--border-strong); border-radius: 8px;
  font-size: 15px; line-height: 1.5; overflow-x: auto; white-space: pre;
}
.term .prompt { color: var(--accent); }

.shot { margin: 0; background: var(--panel); border: 1px solid var(--border-strong); border-radius: var(--radius); overflow: hidden; }
.shot img { display: block; width: 100%; height: auto; }
.doc .shot { margin: 28px 0 8px; }

/* Feature rows: text beside its screenshot, sides alternating. Wider than the document column so the
   screenshots stay legible; the text column's inner edge lines up with the column's edge. */
.rows { max-width: var(--wide); margin: 56px auto 0; display: grid; gap: 64px; }
.row { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; align-items: center; }
.row:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.row:nth-child(even) .row-text { order: 2; }
.row-text p { color: var(--fg-2); margin: 0; }

.foot {
  max-width: var(--measure); margin: 0 auto; padding: 28px var(--gutter) 48px;
  display: flex; gap: 22px; align-items: center;
  font-family: var(--mono); font-size: 13px; color: var(--muted);
  border-top: 1px solid var(--border);
}
.foot .spacer { flex: 1; }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--fg); }

@media (max-width: 760px) {
  .doc:first-child { padding-top: 40px; }
  h1 { font-size: 34px; }
  .rows { gap: 44px; margin-top: 44px; }
  .row, .row:nth-child(even) { grid-template-columns: 1fr; gap: 16px; }
  .row:nth-child(even) .row-text { order: 0; }
}
