/* site.css — the only CSS this page needs beyond the compiled design sheet.
 *
 * What is already provided, and therefore NOT repeated here
 * -------------------------------------------------------
 * /assets/aegis.css is the compiled Tailwind v4 output for this design
 * (aegis-design/.vercel/output/static/assets/styles-DBfSWPL1.css). That file
 * already contains, in one stylesheet:
 *
 *   @layer theme     every token from aegis-design/src/styles.css
 *                    (--color-bg, --color-gold, --color-gain, --color-surface,
 *                    --color-line, --color-fg, --color-muted, --color-faint,
 *                    --color-ink, --color-gold-ink, --color-raised,
 *                    --color-loss, --font-sans, --font-serif, --font-mono)
 *   @layer base      preflight, plus
 *                    `html, body { background: var(--color-bg);
 *                                  color: var(--color-fg);
 *                                  font-family: var(--font-sans) }`
 *   @layer utilities every class site.tsx uses — all 122 verified present,
 *                    including bg-bg/95, size-8, place-items-center,
 *                    md:last:border-r-0, text-balance, text-pretty, gap-px
 *   html.light       the light-theme token overrides, at the top level of the
 *                    sheet, so the light theme works with no help from here.
 *
 * So this file does not redefine a token, a utility or the light theme.
 */

/* 1. Canvas guard.
 *
 *    Unlayered on purpose: an unlayered rule outranks anything inside
 *    @layer base, so the dark canvas survives even if a later theme sheet
 *    drops or reorders the base rule. The var() fallbacks keep the design's
 *    colours if theme.css is ever missing, while the tokens still win when
 *    they are present — which is what keeps the html.light swap working,
 *    since custom properties inherit from <html> down to <body>. */
html,
body {
  background: var(--color-bg, #07090c);
  color: var(--color-fg, #e8ecf1);
  font-family: var(--font-sans, "IBM Plex Sans", system-ui, sans-serif);
}

/* 2. Native chrome. The design is dark-first and offers an html.light theme,
 *    so the UA's own widgets (scrollbars, selection, form controls) are told
 *    which one is in play instead of guessing. */
html {
  color-scheme: dark;
}

html.light {
  color-scheme: light;
}

/* 3. Anchor offset. The header is sticky and h-16 (4rem); the compiled sheet
 *    has no scroll-margin, so #books and #rule would open with their first
 *    line hidden under it. This is the only rule here that changes behaviour
 *    rather than restating a token, and it is the reason this file exists. */
#books,
#rule {
  scroll-margin-top: 4rem;
}
