/* Syrup site: the styles every page shares. Tokens, type, buttons, header and footer.
   Each page keeps its own layout CSS inline. Reference pages (docs, the SRP language)
   read on the light "paper" colours inside the same dark header and footer. */

:root {
  --bg: #0e1113;
  --panel: #161a1d;
  --panel-deep: #131719;
  --tile: #1c2125;
  --tile-active: #1f2529;
  --line: #22282d;
  --line-strong: #2c3338;
  --line-btn: #3a4248;
  --text: #eceff1;
  --text-muted: #a3acb3;
  --text-dim: #8b959c;
  --bar-idle: #6b767e;
  --accent: #f2a541;
  --accent-hover: #f7c27a;
  --on-accent: #111416;
  --live: #4ade80;

  --paper: #f3f1ec;
  --paper-card: #ffffff;
  --paper-line: #e0ddd4;
  --paper-text: #15191c;
  --paper-muted: #444c52;
  --paper-dim: #5f676d;
  --paper-accent: #8a4b05;

  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --max-w: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); }
a:hover { color: var(--accent-hover); }
.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--font-mono); }
.eyebrow { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.02em; color: var(--accent); }
.h2 { font-size: clamp(30px, 3.8vw, 44px); line-height: 1.1; letter-spacing: -0.02em; font-weight: 700; }
.lede { font-size: 17px; line-height: 1.6; color: var(--text-muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 13px 22px; border-radius: 10px;
  font-weight: 600; font-size: 16px; text-decoration: none;
}
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn-ghost { color: var(--text); border: 1px solid var(--line-btn); }
.btn-ghost:hover { color: var(--text); border-color: var(--text-dim); }
.btn-sm { padding: 10px 16px; font-size: 14px; border-radius: 8px; }

/* Header and footer: always dark. They set their own colours, so a page that
   redefines the tokens for a light body can't reach them. */
.site-header, .site-footer {
  --bg: #0e1113; --line: #22282d; --line-btn: #3a4248;
  --text: #eceff1; --text-muted: #a3acb3; --text-dim: #8b959c;
  --accent: #f2a541; --accent-hover: #f7c27a; --on-accent: #111416;
  background: var(--bg); color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  line-height: 1.5;
}
.site-header .wrap, .site-footer .wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap {
  min-height: 64px; display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: 12px;
}
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 700; font-size: 18px; }
.logo:hover { color: var(--text); }
.logo-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.header-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 22px; font-size: 14px; }
.header-nav a:not(.btn) { color: var(--text-muted); text-decoration: none; }
.header-nav a:not(.btn):hover, .header-nav a[aria-current="page"] { color: var(--text); }

.site-footer { border-top: 1px solid var(--line); }
.site-footer .wrap {
  padding-top: 28px; padding-bottom: 28px; display: flex; flex-wrap: wrap; gap: 16px;
  justify-content: space-between; font-size: 13px; color: var(--text-dim);
}
.footer-nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer-nav a { color: var(--text-muted); }
.footer-nav a:hover { color: var(--text); }

/* A page's own .btn rules mustn't restyle the header's button. */
.site-header .btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px;
  padding: 10px 16px; border-radius: 8px; border: 0;
  font: 600 14px/1.5 'Inter', system-ui, -apple-system, sans-serif;
  letter-spacing: normal; text-transform: none; text-decoration: none; box-shadow: none;
}
.site-header .btn-primary, .site-header .btn-primary:hover { color: var(--on-accent); }
.site-header .btn-primary { background: var(--accent); }
.site-header .btn-primary:hover { background: var(--accent-hover); }

@media (max-width: 640px) {
  .header-nav .hide-sm { display: none; }
}

/* Reference pages: the light reading body (body class="paper-page"). */
.paper-page { background: var(--paper); color: var(--paper-text); }
