/* assets/docs.css — shared chrome for the Orchard docs hub.
 *
 * Prose styling comes from github-markdown-css (loaded per page); this file
 * owns the site header/nav, page layout, landing cards, and a few overrides.
 * No build step — plain CSS, served static. */

:root {
  --bg: #ffffff;
  --fg: #1f2328;
  --muted: #59636e;
  --border: #d1d9e0;
  --accent: #2f7d4f; /* Orchard green */
  --accent-fg: #ffffff;
  --card-bg: #f6f8fa;
  --maxw: 880px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d1117; --fg: #e6edf3; --muted: #9198a1; --border: #2a313c;
    --accent: #3fb950; --accent-fg: #0d1117; --card-bg: #161b22;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* Header / nav */
.site-header {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap;
  padding: 0.7rem 1.25rem;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header .brand {
  font-weight: 700; font-size: 1.02rem; text-decoration: none; color: var(--fg);
  white-space: nowrap;
}
.site-header nav { display: flex; gap: 0.35rem; flex-wrap: wrap; }
.site-header nav a {
  text-decoration: none; color: var(--muted);
  padding: 0.3rem 0.6rem; border-radius: 7px; font-size: 0.92rem;
}
.site-header nav a:hover { color: var(--fg); background: var(--card-bg); }
.site-header nav a.active { color: var(--accent); font-weight: 600; }

/* Page layout */
main.doc { max-width: var(--maxw); margin: 0 auto; padding: 2.2rem 1.25rem 5rem; }
/* Data-heavy pages (e.g. the coverage report's 7-column table) get a wider
   column so the table mostly fits; the table-scroll rule below still catches
   any overflow on narrow viewports. */
main.doc.wide { max-width: 1200px; }
.markdown-body { background: transparent !important; color: var(--fg); }
.markdown-body a { color: var(--accent); }
.markdown-body pre { border: 1px solid var(--border); border-radius: 8px; }
/* Wide tables (e.g. the coverage report) scroll horizontally instead of
   clipping past the content column. */
.markdown-body table { display: block; width: max-content; max-width: 100%; overflow-x: auto; }
.doc-loading { color: var(--muted); padding: 3rem 0; text-align: center; }

footer.site-footer {
  max-width: var(--maxw); margin: 0 auto; padding: 2rem 1.25rem;
  border-top: 1px solid var(--border); color: var(--muted); font-size: 0.85rem;
}
footer.site-footer a { color: var(--accent); }

/* Landing hero + cards */
.hero { max-width: var(--maxw); margin: 0 auto; padding: 3rem 1.25rem 1rem; }
.hero h1 { font-size: 2rem; margin: 0 0 0.4rem; }
.hero p { color: var(--muted); font-size: 1.05rem; margin: 0; max-width: 60ch; }
.cards {
  max-width: var(--maxw); margin: 1.5rem auto 0; padding: 0 1.25rem;
  display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.card {
  display: block; text-decoration: none; color: inherit;
  border: 1px solid var(--border); border-radius: 12px; padding: 1.1rem 1.2rem;
  background: var(--card-bg); transition: border-color .15s, transform .15s;
}
.card:hover { border-color: var(--accent); transform: translateY(-2px); }
.card h2 { margin: 0 0 0.3rem; font-size: 1.08rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.card .tag {
  display: inline-block; margin-bottom: 0.5rem; font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.03em; text-transform: uppercase; color: var(--accent);
}
