/* Resolution — the product website. Same tokens and faces as the app (web/app.css, docs/design.md):
   borders, not boxes; no shadows; Night by default, Paper when the system or the owner asks for it.
   No inline styles anywhere, so the site's Content-Security-Policy can allow only this file. */

@font-face { font-family: "Instrument Sans"; font-style: normal; font-display: swap; font-weight: 400 700; src: url("/fonts/instrument-sans-latin-wght-normal.woff2") format("woff2"); }
@font-face { font-family: "Instrument Sans"; font-style: italic; font-display: swap; font-weight: 400 700; src: url("/fonts/instrument-sans-latin-wght-italic.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 400; src: url("/fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 500; src: url("/fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 600 700; src: url("/fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Newsreader"; font-style: normal; font-display: swap; font-weight: 200 800; src: url("/fonts/newsreader-latin-opsz-normal.woff2") format("woff2"); }
@font-face { font-family: "Newsreader"; font-style: italic; font-display: swap; font-weight: 200 800; src: url("/fonts/newsreader-latin-wght-italic.woff2") format("woff2"); }

:root {
  --ground: #0a0c10; --surface: #10131a; --raised: #161a22; --sunk: #07080b;
  --line: #1d222c; --line-strong: #2b313d;
  --text: #e8eaef; --muted: #9aa1ae; --faint: #7b8391;
  --brass: #8196ff; --brass-ink: #070b24; --brass-soft: rgba(129, 150, 255, .13);
  --pass: #3ec79d; --fail: #ff7a59; --warn: #e9b949; --info: #9fb0ff; --bench: #8d95a4;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --gutter: 24px; --measure: 68ch;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="night"]) {
    --ground: #f3f4f6; --surface: #fff; --raised: #f8f9fb; --sunk: #eceef2;
    --line: #e3e6ec; --line-strong: #cfd4dd;
    --text: #0e1320; --muted: #525b6b; --faint: #636b7b;
    --brass: #2e45c8; --brass-ink: #fff; --brass-soft: rgba(46, 69, 200, .10);
    --pass: #057654; --fail: #c23b1a; --warn: #8f6300; --info: #2e45c8; --bench: #808897;
    color-scheme: light;
  }
  :root:not([data-theme="night"]) .when-night { display: none; }
}
:root[data-theme="paper"] {
  --ground: #f3f4f6; --surface: #fff; --raised: #f8f9fb; --sunk: #eceef2;
  --line: #e3e6ec; --line-strong: #cfd4dd;
  --text: #0e1320; --muted: #525b6b; --faint: #636b7b;
  --brass: #2e45c8; --brass-ink: #fff; --brass-soft: rgba(46, 69, 200, .10);
  --pass: #057654; --fail: #c23b1a; --warn: #8f6300; --info: #2e45c8; --bench: #808897;
  color-scheme: light;
}
.when-paper { display: none; }
:root[data-theme="paper"] .when-night { display: none; }
:root[data-theme="paper"] .when-paper { display: inline; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="night"]) .when-paper { display: inline; }
}

/* ---- Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 96px; }
body {
  margin: 0; background: var(--ground); color: var(--text);
  font: 400 15px/1.55 var(--sans); font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
a { color: var(--brass); text-decoration: none; text-underline-offset: 2px; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; border-radius: 2px; }
img { max-width: 100%; height: auto; display: block; }
code, pre, kbd, .mono { font-family: var(--mono); font-size: .92em; }
.mono { font-size: 13px; }
.break { overflow-wrap: anywhere; }
h1, h2, h3, h4 { font-weight: 600; line-height: 1.2; margin: 0; letter-spacing: -.005em; text-wrap: balance; }
p { margin: 0; }
button { font: inherit; color: inherit; }
::selection { background: var(--brass-soft); }

/* ---- Header */
.top {
  position: sticky; top: 0; z-index: 5; background: var(--ground);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px;
  height: 52px; padding: 0 var(--gutter);
}
.mark { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; font-size: 15px; letter-spacing: .01em; }
.mark:hover { text-decoration: none; }
.mark svg { flex: none; }
.top nav { display: flex; gap: 2px; margin-left: auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.top nav::-webkit-scrollbar { display: none; }
.top nav a { color: var(--muted); padding: 6px 10px; border-radius: 6px; white-space: nowrap; font-size: 14px; }
.top nav a:hover { color: var(--text); background: var(--raised); text-decoration: none; }
.top nav a[aria-current="page"] { color: var(--text); box-shadow: inset 0 -2px 0 var(--brass); border-radius: 0; }
.theme {
  flex: none; width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center;
  background: none; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); cursor: pointer; padding: 0;
}
.theme:hover { color: var(--text); border-color: var(--line-strong); }

/* ---- Page frame */
main { display: block; max-width: 1120px; margin: 0 auto; padding: 0 var(--gutter); }
.lede { font-size: 17px; line-height: 1.5; color: var(--muted); max-width: var(--measure); }
.fine { color: var(--muted); font-size: 14px; max-width: var(--measure); }
section { padding: 40px 0; border-top: 1px solid var(--line); }
section:first-child, .hero { border-top: 0; }

/* ---- Hero */
.hero { padding: 64px 0 40px; }
.hero h1 {
  font-family: var(--serif); font-weight: 450; font-size: 46px; line-height: 1.08; letter-spacing: -.01em;
  max-width: 20ch; margin-bottom: 20px; font-variation-settings: "opsz" 60;
}
.hero .lede { font-size: 19px; margin-bottom: 28px; max-width: 58ch; }
.under { margin-top: 14px; color: var(--muted); font-size: 14px; max-width: var(--measure); }
.hero.pair { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; align-items: end; padding-bottom: 48px; }

/* A command with a copy button. */
.cmd {
  display: flex; align-items: stretch; max-width: 720px;
  border: 1px solid var(--line-strong); border-radius: 8px; background: var(--sunk); overflow: hidden;
}
.cmd pre { margin: 0; padding: 12px 14px; flex: 1; min-width: 0; overflow-x: auto; font-size: 13.5px; line-height: 1.5; }
.cmd code { font-size: inherit; }
.cmd button {
  flex: none; padding: 0 14px; border: 0; border-left: 1px solid var(--line-strong); background: var(--raised);
  color: var(--muted); cursor: pointer; font-size: 13px; min-width: 88px;
}
.cmd button:hover { color: var(--text); background: var(--surface); }
.cmd.block { align-items: flex-start; }
.cmd.block button { align-self: stretch; }

/* ---- Screenshots: hairline frame, the app's own chrome does the rest. */
.shot { margin: 0; }
.shot img { border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); }
.shot figcaption { color: var(--faint); font-size: 13px; margin-top: 10px; max-width: var(--measure); }
.shot.phone { max-width: 300px; }
.shot.phone img { border-radius: 14px; }
main > .shot { padding: 0 0 40px; }

/* ---- Strips: cells separated by hairlines, never boxes. */
.strip { display: grid; gap: 0; }
.strip.four { grid-template-columns: repeat(4, 1fr); }
.strip.three { grid-template-columns: repeat(3, 1fr); }
.strip > div { padding: 4px 24px 8px 0; border-left: 1px solid var(--line); padding-left: 20px; }
.strip > div:first-child { border-left: 0; padding-left: 0; }
.strip h2, .strip h3 { font-size: 16px; font-weight: 600; margin-bottom: 10px; }
.strip p { color: var(--muted); font-size: 14px; }
.strip p + p { margin-top: 8px; }
.doc .strip { margin: 20px 0 8px; }

/* ---- The verdict: the one bold element on the page. */
.verdict { padding: 56px 0; }
.verdict-q { font-size: 14px; color: var(--muted); margin-bottom: 8px; }
.verdict-word {
  font-family: var(--serif); font-weight: 400; font-style: italic; font-size: 88px; line-height: 1; letter-spacing: -.02em;
  font-variation-settings: "opsz" 72; margin: 0 0 18px -3px; color: var(--text); text-wrap: balance;
}
.verdict-why { font-size: 17px; max-width: 60ch; }
.verdict-note { color: var(--muted); font-size: 14px; max-width: var(--measure); margin-top: 14px; }

/* ---- Split: text beside a screenshot, alternating. */
.split { display: grid; grid-template-columns: 5fr 7fr; gap: 40px; align-items: start; }
.split.flip .text { order: 2; }
.split .text h2 { font-size: 22px; margin-bottom: 14px; max-width: 26ch; }
.split .text p, .split .text li { color: var(--muted); }
.split .text p + p, .split .text ul + p { margin-top: 12px; }
.split .text ul { margin: 0; padding-left: 18px; }
.split .text li { margin: 6px 0; }
.split .text .fine { margin-top: 14px; }
.split .shot.phone { justify-self: center; }

.closing { padding: 48px 0 64px; max-width: var(--measure); }
.closing h2 { font-family: var(--serif); font-weight: 450; font-size: 30px; margin-bottom: 14px; }
.closing p { font-size: 17px; }
.closing .fine { margin-top: 16px; font-size: 14px; }

/* ---- Documents (docs, changelog, security, install, features, source) */
.docs { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 0; margin: 0 calc(-1 * var(--gutter)); }
.side {
  background: var(--sunk); border-right: 1px solid var(--line);
  padding: 24px 16px 40px 24px; font-size: 13.5px;
  position: sticky; top: 52px; align-self: start; max-height: calc(100vh - 52px); overflow-y: auto;
}
.side h2 { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin: 20px 0 6px; }
.side h2:first-child { margin-top: 0; }
.side ul { list-style: none; margin: 0; padding: 0; }
.side li a { display: block; padding: 4px 10px; margin-left: -10px; border-left: 2px solid transparent; color: var(--muted); border-radius: 0 4px 4px 0; }
.side li a:hover { color: var(--text); text-decoration: none; background: var(--raised); }
.side li a[aria-current="page"] { color: var(--text); border-left-color: var(--brass); background: var(--brass-soft); }
.crumb { display: none; }

.doc { padding: 40px var(--gutter) 64px; max-width: calc(var(--measure) + 2 * var(--gutter) + 40px); min-width: 0; }
.doc.narrow { padding-left: 0; padding-right: 0; max-width: calc(var(--measure) + 40px); }
.doc h1 { font-family: var(--serif); font-weight: 500; font-size: 32px; line-height: 1.15; margin: 0 0 14px; font-variation-settings: "opsz" 40; }
.doc h1 + p { margin-top: 0; }
.doc h2 { font-size: 21px; margin: 40px 0 12px; padding-top: 20px; border-top: 1px solid var(--line); }
.doc h3 { font-size: 16px; margin: 28px 0 8px; }
.doc h4 { font-size: 14px; margin: 20px 0 6px; color: var(--muted); }
.doc p { margin: 0 0 14px; }
.doc .lede { margin-bottom: 24px; }
.doc ul, .doc ol { margin: 0 0 14px; padding-left: 22px; }
.doc li { margin: 4px 0; }
.doc li > ul, .doc li > ol { margin: 4px 0 0; }
.doc li > p { margin-bottom: 8px; }
.doc blockquote { margin: 0 0 14px; padding: 2px 0 2px 16px; border-left: 2px solid var(--line-strong); color: var(--muted); }
.doc blockquote p:last-child { margin-bottom: 0; }
.doc hr { border: 0; border-top: 1px solid var(--line); margin: 28px 0; }
.doc strong { font-weight: 600; }
.doc img { border: 1px solid var(--line-strong); border-radius: 8px; margin: 6px 0 14px; }
.doc .shot { margin: 16px 0 20px; }
.doc .shot.phone { margin-left: 0; }
.doc code { background: var(--raised); border: 1px solid var(--line); border-radius: 4px; padding: .05em .35em; font-size: .88em; }
.doc pre { background: var(--sunk); border: 1px solid var(--line); border-radius: 6px; padding: 12px 14px; overflow-x: auto; margin: 0 0 16px; font-size: 13px; line-height: 1.5; }
.doc pre code { background: none; border: 0; padding: 0; font-size: inherit; }
.doc .cmd { margin: 0 0 16px; }
.doc .cmd pre { margin: 0; border: 0; border-radius: 0; background: none; }
.doc .licence { font-size: 12px; white-space: pre-wrap; }
.doc .tbl { overflow-x: auto; margin: 0 0 16px; border: 1px solid var(--line); border-radius: 6px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 13.5px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 8px 12px; border-top: 1px solid var(--line); }
.doc th { border-top: 0; background: var(--raised); font-weight: 600; font-size: 12.5px; color: var(--muted); }
.doc td.center, .doc th.center { text-align: center; }
.doc td.right, .doc th.right { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; }
.doc td code { white-space: nowrap; }
.doc .facts th { width: 7em; white-space: nowrap; background: none; font-size: 13.5px; color: var(--muted); border-top: 1px solid var(--line); }
.doc .facts tr:first-child th { border-top: 0; }
.doc h2 code, .doc h3 code { font-size: .85em; }
.features .shot { margin-top: 12px; }
.doc.features { max-width: 880px; }
.doc.features ul { max-width: var(--measure); }

/* ---- Footer */
.foot { border-top: 1px solid var(--line); padding: 24px var(--gutter) 40px; max-width: 1120px; margin: 24px auto 0; color: var(--muted); font-size: 13px; }
.foot-note { margin-bottom: 10px; color: var(--text); }
.foot nav { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.foot nav a { color: var(--muted); }
.foot nav a:hover { color: var(--text); }

/* ---- Fold points */
@media (max-width: 900px) {
  .strip.four { grid-template-columns: 1fr 1fr; }
  .strip.four > div:nth-child(3) { border-left: 0; padding-left: 0; }
  .strip.four > div { padding-bottom: 20px; }
  .split { grid-template-columns: 1fr; gap: 24px; }
  .hero.pair { grid-template-columns: 1fr; gap: 32px; }
  .split.flip .text { order: 0; }
  .split .shot.phone { justify-self: start; }
  .docs { grid-template-columns: 1fr; }
  .side { order: 2; position: static; max-height: none; border-right: 0; border-top: 1px solid var(--line); padding: 24px var(--gutter) 32px; }
  .side ul { columns: 2; column-gap: 24px; }
  .side li { break-inside: avoid; }
  .crumb { display: block; font-size: 13px; margin: 0 0 20px; }
  .doc { padding-top: 28px; }
  .hero { padding-top: 44px; }
  .hero h1 { font-size: 38px; }
  .verdict-word { font-size: 64px; }
}
@media (max-width: 560px) {
  :root { --gutter: 16px; }
  .top { height: auto; flex-wrap: wrap; gap: 4px 8px; padding: 8px var(--gutter) 4px; }
  .top nav { order: 3; width: 100%; margin-left: -8px; }
  .top nav a { padding: 6px 8px; font-size: 13px; }
  .theme { margin-left: auto; }
  .hero { padding-top: 32px; }
  .hero h1 { font-size: 31px; }
  .hero .lede { font-size: 16px; }
  .cmd { flex-direction: column; }
  .cmd button { border-left: 0; border-top: 1px solid var(--line-strong); padding: 8px 14px; text-align: left; }
  .strip.four, .strip.three { grid-template-columns: 1fr; }
  .strip > div, .strip.four > div:nth-child(3) { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 16px; padding-bottom: 16px; }
  .strip > div:first-child { border-top: 0; padding-top: 0; }
  .verdict { padding: 40px 0; }
  .verdict-word { font-size: 44px; }
  .verdict-why { font-size: 16px; }
  .closing h2 { font-size: 26px; }
  .side ul { columns: 1; }
  .doc h1 { font-size: 27px; }
  .doc h2 { font-size: 19px; }
  .doc pre, .cmd pre { font-size: 12.5px; }
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .theme, .top nav a, .cmd button { transition: background-color .12s, color .12s, border-color .12s; }
}
@media print {
  .top, .foot nav, .theme, .side, .crumb, .cmd button { display: none; }
  body { background: #fff; color: #000; }
}
