
:root {
  color-scheme: dark;
  --bg: #0e1116;
  --surface: #161b22;
  --surface-2: #1c2230;
  --border: #2a3140;
  --text: #e6edf3;
  --muted: #8b96a8;
  --accent: #4f8cff;
  --accent-soft: rgba(79, 140, 255, 0.14);
  --code-bg: #0b0f15;
  --shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text); }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.55;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  padding: 0.1em 0.35em;
  border-radius: 4px;
  border: 1px solid var(--border);
}
pre {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  overflow-x: auto;
  box-shadow: var(--shadow);
}
pre code {
  background: transparent;
  border: 0;
  padding: 0;
  font-size: 13px;
  line-height: 1.5;
}
hr { border: 0; border-top: 1px solid var(--border); margin: 24px 0; }
blockquote {
  margin: 16px 0;
  padding: 8px 14px;
  border-left: 3px solid var(--accent);
  background: var(--surface-2);
  border-radius: 0 6px 6px 0;
  color: var(--muted);
}
blockquote p:first-child { margin-top: 0; }
blockquote p:last-child { margin-bottom: 0; }
img { max-width: 100%; height: auto; border-radius: 6px; }
table { border-collapse: collapse; width: 100%; }
.table-wrap { overflow-x: auto; margin: 16px 0; border: 1px solid var(--border); border-radius: 8px; }
table th, table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
table th { background: var(--surface-2); text-align: left; font-weight: 600; }
table tr:last-child td { border-bottom: 0; }

/* Layout */
.site {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 100vh;
}
/* Full-width layout (landing page has no sidebar). */
.site--full {
  grid-template-columns: minmax(0, 1fr);
}
.site--full .main {
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
}
.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  padding: 20px 16px;
  position: sticky;
  top: 0;
  align-self: start;
  max-height: 100vh;
  overflow-y: auto;
}
.sidebar h1 {
  font-size: 18px;
  margin: 0 0 4px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar .logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
}
.sidebar .tag { color: var(--muted); font-size: 12px; margin-bottom: 16px; }
.sidebar h2 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin: 18px 0 6px 0;
}
.sidebar ul { list-style: none; padding: 0; margin: 0; }
.sidebar li a {
  display: block;
  padding: 6px 8px;
  border-radius: 6px;
  color: var(--text);
  font-size: 14px;
  line-height: 1.3;
}
.sidebar li a:hover { background: var(--surface-2); text-decoration: none; }
.sidebar li a.is-active {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}
.main { padding: 28px 32px 64px 32px; max-width: 920px; min-width: 0; }
.main h1 { font-size: 28px; margin: 0 0 4px 0; }
.main h1 + p { color: var(--muted); margin-top: 0; }
.main h2 { font-size: 20px; margin-top: 32px; padding-top: 12px; border-top: 1px solid var(--border); }
.main h3 { font-size: 16px; margin-top: 24px; }
.main p, .main li { line-height: 1.6; }
.main p, .main li, .main a, .main td, .main th { overflow-wrap: break-word; word-break: break-word; }
.main ul, .main ol { padding-left: 22px; }
.main li + li { margin-top: 4px; }

/* Index page: feature cards. */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.feature-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
  color: var(--text);
  transition: border-color 120ms ease, transform 120ms ease;
}
.feature-card:hover {
  border-color: var(--accent);
  text-decoration: none;
  transform: translateY(-1px);
}
.feature-card h3 { margin: 0 0 6px 0; font-size: 15px; color: var(--accent); }
.feature-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.5; }

.footer {
  margin-top: 40px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 12px;
}

/* Keep an anchored heading clear of the sticky top navigation. */
html { scroll-padding-top: 72px; }
/* Top navigation (shared across pages). */
.topnav {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 12px 24px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 20;
  flex-wrap: wrap;
}
.topnav-brand {
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.topnav-brand .logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
}
.topnav-links {
  display: flex;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}
.topnav-links a {
  padding: 7px 10px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}
.topnav-links a:hover {
  background: var(--surface-2);
  color: var(--text);
  text-decoration: none;
}
/* Landing page. */
.hero {
  padding: 56px 32px 40px;
  text-align: center;
}
.hero .eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 600;
}
.hero h1 {
  font-size: 52px;
  margin: 0 0 14px;
  letter-spacing: -0.02em;
}
.hero .tagline {
  max-width: 640px;
  margin: 0 auto 24px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.6;
}
.hero-install {
  max-width: 640px;
  margin: 0 auto 24px;
  text-align: left;
}
.hero-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}
.btn:hover { text-decoration: none; border-color: var(--accent); }
.btn--primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.btn--primary:hover { filter: brightness(1.06); }
/* GitHub action button: the mark sits before the label, none of the row's
  other buttons carry an icon, so it needs its own gap. */
.btn__icon { display: block; margin-right: 8px; flex: none; }
/* Feature sections with a screenshot + copy. */
.feature {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
  margin: 56px 0;
}
.feature--flip .shot { order: 2; }
.feature--flip .feature-copy { order: 1; }
.feature-copy h2 { margin-top: 0; padding-top: 0; border-top: 0; }
.feature-copy p, .feature-copy li { color: var(--muted); }
.shot {
  position: relative;
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.shot-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: 11px;
  font-size: 13px;
  text-align: center;
  padding: 16px;
  z-index: 0;
}
.shot img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}
.shot figcaption {
  padding: 10px 12px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}
/* Landing-page screenshot row: phone-proportioned captures of the real UI.
  Four per row on a laptop (eight captures = two full rows, so no row is left
  with a single orphan card), a centred two-up in the middle width, and one
  stacked column on a phone (see the media query). A fixed 4-column grid with
  a cap per card rather than auto-fit: auto-fit sizes the tracks from the
  container, which left the last card of a row alone on its own line and much
  wider than the others. */
.shot-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
  margin: 24px 0;
}
.shot-row .shot img {
  border-radius: 0;
}
.section {
  margin: 56px 0;
}
.section h2 {
  font-size: 22px;
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.section p, .section li { color: var(--muted); }
.section .lead { color: var(--text); }
@media (max-width: 760px) {
.site { grid-template-columns: minmax(0, 1fr); }
.site.site--full .main { margin: 0; max-width: none; }
.sidebar { position: static; max-height: none; order: 2; }
.main { padding: 20px 16px 48px 16px; order: 1; }
/* Compact top nav: the brand always occupies its own full-width line, so the
* links reliably drop to a full-width second row beneath it at every mobile
* width (there is no awkward mid-range state where the links sit beside the
* brand but are no longer right-pushed). Both rows fill the available width;
* links stay on one horizontally-scrolling row with tap-friendly ≥44px height. */
.topnav { padding: 6px 14px; gap: 6px 14px; align-items: center; }
.topnav-brand { flex: 1 0 100%; min-height: 44px; }
.topnav-links { flex: 1 1 100%; min-width: 0; gap: 4px; margin-left: 0; overflow-x: auto; flex-wrap: nowrap; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.topnav-links::-webkit-scrollbar { display: none; }
.topnav-links a { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 12px; font-size: 13px; }
/* The link row scrolls sideways; fade its trailing edge so a clipped label
   reads as "more to the right" instead of a cut-off word. */
.topnav-links { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); padding-right: 24px; }
/* Two rows of sticky navigation (~110 px). */
html { scroll-padding-top: 120px; }
.hero { padding: 40px 16px 32px; }
.hero h1 { font-size: 40px; }
.hero .tagline { font-size: 15px; }
.feature { grid-template-columns: 1fr; gap: 20px; }
.feature--flip .shot { order: 0; }
.feature--flip .feature-copy { order: 0; }
/* Landing screenshots: one full-width column, so each phone capture is
   readable at 360–430 px instead of shrinking beside its neighbours. */
.shot-row { grid-template-columns: minmax(0, 1fr); gap: 18px; }
.shot-row .shot { max-width: 340px; margin: 0 auto; }
}
/* Landing screenshots between the phone and a full three-up: two captures per
   row, centred, so neither a 2-up stretch nor a cramped three-up is left at
   tablet widths. Sits outside the 760 px block so it only applies above it. */
@media (min-width: 761px) and (max-width: 1040px) {
.shot-row { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 760px; margin-left: auto; margin-right: auto; }
}
