/* THIS FILE IS TOKENS ONLY. Structure lives in the engine sheet the shell
   links first.

   _engine.css is the shared structural stylesheet, one copy on disk, hard
   linked from the engine theme: layout, components, base element rules
   (*, html, body, a, .wrap, main and the rest). The shell (Site.master.vb)
   emits it as its own versioned link BEFORE this file's link, so this
   file's job is only to re-declare the accent tokens after the engine's
   own, landing this atlas's own hue on top of shared structure.

   OWNER REQUEST 985, 2026-08-20, second pass. The first pass fixed the
   @import cache-busting problem below, but the owner still saw the narrow,
   pre-full-width layout after a hard refresh, because this file used to
   carry a second copy of the ORIGINAL SKELETON SITE's base rules below the
   tokens (*{box-sizing}, html, body, a, .wrap, main, plus .site-header,
   .site-footer and .family-line, none of which any served page still uses,
   confirmed by grepping the engine sheet, Site.master and every served
   page for those three class names: no hits). Loading after _engine.css,
   that copy's .wrap{max-width:var(--measure)} (40.5rem) beat the engine's
   own .wrap{max-width:none} in cascade order, which is the actual
   narrowness the owner reported, and its body/a rules fought the engine's
   on the same terms. Deleted entirely; only the token blocks below are
   this atlas's own.

   Before this fix reached _engine.css at all with a CSS @import, replaced
   in the first pass because @import carries no cache-busting version stamp
   and the response carries no Cache-Control header, so a browser that had
   ever loaded the engine sheet held it forever.

   Tokens below: the neutrals, ink/muted/faint text colours, the two
   semantic colours, the serif and sans stacks, the shadow and the reading
   measure are copied verbatim from
   sites\DivinityAtlas\App_Themes\Divinity\site.css, dark :root and
   prefers-color-scheme: light blocks, so this site reads as a sibling of
   Divinity Atlas. Only --gold and --gold-soft, the accent tokens, differ
   from Divinity. Values are ScienceAtlas's proposed azure accent from the
   palette lane's sibling_palettes.md (2026-08-19), used exactly as given,
   chosen because it clears 4.5:1 as text against every one of --ground,
   --panel and --panel2 in both themes. This page uses the accent only as
   link text, never as a background fill behind text, per the same file's
   finding that no single hue clears 4.5:1 in both the text role and the
   filled-button role at once. */

:root{
  --ground:#0b0d1a; --panel:#141731; --panel2:#1b1f3d; --edge:#2b2f55; --edge2:#3a3f6b;
  --ink:#eae7f3; --muted:#a7a5c4; --faint:#8785a7;
  --shared:#79bcb0; --shared-bg:rgba(111,178,168,.14); --dark-c:#d27a92; --dark-bg:rgba(181,84,106,.16);
  --gold:#5e97d9; --gold-soft:#8fb7e5;
  /* --gold-bg, added 2026-08-19 so all three atlases carry the paired token from
     the start, matching Divinity's site.css (see its own --gold-bg comments for
     the full defect history). This page has no fill-behind-text rule yet, so
     nothing here repoints, but a future primary button, active pager or active
     tab wants --gold-bg for its background rather than --gold. In THIS theme
     --gold-bg is simply --gold's own value, no change: #1a1508 (Divinity's
     hardcoded button ink) on #5e97d9 measures 5.98:1, clear of 4.5. See the
     light block below, whose shape is the opposite of Divinity's. */
  --gold-bg:#5e97d9;
  --serif:"Iowan Old Style","Palatino Linotype",Palatino,"Book Antiqua",Georgia,serif;
  --sans:ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
  --shadow:0 12px 34px -14px rgba(0,0,0,.6);
  --measure:40.5rem;
}
@media (prefers-color-scheme: light){:root{
  --ground:#f4efe3; --panel:#eee7d6; --panel2:#f8f4ea; --edge:#ddd2ba; --edge2:#cabfa3;
  --ink:#282540; --muted:#655f74; --faint:#6d6759;
  --shared:#2f685e; --shared-bg:rgba(60,133,120,.12); --dark-c:#9c3f57; --dark-bg:rgba(162,65,90,.10);
  --gold:#235997; --gold-soft:#3069ab;
  /* --gold-bg here is ALSO simply --gold's own value, unlike Divinity's light
     theme, and that is the point of naming both shapes: Divinity's light --gold
     is mid-dark (#9a7420), so a DARK ink (#1a1508) on it fails at 4.24:1 and
     wants a LIGHTER fill. Science's light --gold is dark and saturated
     (#235997), the opposite case: #1a1508 on it manages only 2.55:1, but white
     on the SAME #235997 measures 7.13:1, well clear of 4.5. So no fill move is
     needed here either, only a foreground move: a future fill rule pairs
     --gold-bg with a light/white ink in this theme, never Divinity's hardcoded
     #1a1508. 2026-08-19. */
  --gold-bg:#235997;
  --shadow:0 14px 30px -18px rgba(60,48,20,.45);
}}

/* DEFECT, owner request 989, 2026-08-20: the engine sheet declares its tokens in
   FOUR states (bare :root for dark default, the prefers-color-scheme: light media
   block above for system light, and these two explicit :root[data-theme] blocks
   for the A11y theme toggle), and its own two data-theme blocks below carry an
   attribute selector, which outranks this wrapper's bare :root on specificity.
   Without a matching pair here, toggling the theme explicitly (System/Light/Dark
   in the header) always fell through to the ENGINE's own dark or light values,
   so Science read all Divinity gold with no azure accent in sight the moment a
   visitor picked a theme by hand rather than leaving it on System. These two
   blocks carry this wrapper's own dark and light token sets so this wrapper's
   attribute selector, sitting after the engine's own in served order, wins the
   specificity tie and gives Science the last word in all four states. Mirrors
   the engine's own shape exactly: the media-light block above is left
   unguarded, same as the engine's, because the engine's data-theme blocks are
   plain [data-theme] selectors with no :not() guard either; guarding here would
   fight nothing the engine does not already resolve by order and specificity
   alone. */
:root[data-theme="dark"]{
  --ground:#0b0d1a; --panel:#141731; --panel2:#1b1f3d; --edge:#2b2f55; --edge2:#3a3f6b;
  --ink:#eae7f3; --muted:#a7a5c4; --faint:#8785a7;
  --shared:#79bcb0; --shared-bg:rgba(111,178,168,.14); --dark-c:#d27a92; --dark-bg:rgba(181,84,106,.16);
  --gold:#5e97d9; --gold-soft:#8fb7e5; --gold-bg:#5e97d9;
  --shadow:0 12px 34px -14px rgba(0,0,0,.6);
}
:root[data-theme="light"]{
  --ground:#f4efe3; --panel:#eee7d6; --panel2:#f8f4ea; --edge:#ddd2ba; --edge2:#cabfa3;
  --ink:#282540; --muted:#655f74; --faint:#6d6759;
  --shared:#2f685e; --shared-bg:rgba(60,133,120,.12); --dark-c:#9c3f57; --dark-bg:rgba(162,65,90,.10);
  --gold:#235997; --gold-soft:#3069ab; --gold-bg:#235997;
  --shadow:0 14px 30px -18px rgba(60,48,20,.45);
}
