/* nc-cosmic-tokens.css — the Learning Hub's colour tokens, remapped onto the
 * cosmic palette (MS-528).
 * ===========================================================================
 * `cosmic-shell.js` writes --ink / --surface / --line / --accent on :root and
 * flips them with the theme. Everything the Hub draws is authored against
 * --ncw-* (workspace) or --nc-* (page sheets), so those two sets have to be
 * pointed at the cosmic ones or the page turns dark while the text does not.
 *
 * This lived inside css/newcourses-workspace-cosmic.css, which 55 pages load.
 * The other five load cosmic-shell.css WITHOUT it — the lesson player, the
 * teacher public profile, the operator hub, rubric templates and the question
 * bank editor — because that file also does
 *
 *     .cosmic-rail, .cosmic-rail-burger { display: none !important; }
 *
 * which is right for a workspace page that has its own sidebar and would delete
 * the only navigation those five have. So the tokens move here, where both
 * kinds of page can take them, and the rail rule stays behind.
 *
 * What that looked like before: on rubric-templates in dark, the page went dark
 * while --ncw-text stayed its light-mode navy, so the "Rubric Templates"
 * heading measured 1.18:1 against its own card, and the Search and Scope
 * controls rendered as white boxes.
 *
 * COLOURS ONLY. Layout tokens (--ncw-chrome-top, --ncw-bg) stay in the
 * workspace sheet: they describe the shell's grid, which these pages do not use.
 */

:root {
  --ncw-surface:      var(--surface);
  --ncw-surface-soft: var(--surface-2);
  --ncw-border:       var(--line);
  --ncw-text:         var(--ink);
  --ncw-muted:        var(--ink-2);
  --ncw-accent:       var(--accent);
  --ncw-accent-soft:  var(--accent-soft, color-mix(in srgb, var(--accent) 14%, transparent));
  --ncw-teal:         var(--accent2, var(--accent));
}

/* Some page sheets style content with newcourses.css's --nc-* tokens instead of
   (or alongside) --ncw-*. Remap those too, so content themes regardless of
   which set a given page was authored against. */
:root {
  --nc-primary:        var(--accent);
  --nc-primary-dark:   var(--accent2, var(--accent));
  --nc-secondary:      var(--accent2, var(--accent));
  --nc-info:           var(--accent2, var(--accent));
  --nc-text-primary:   var(--ink);
  --nc-text-secondary: var(--ink-2);
  --nc-text-muted:     var(--ink-3);
  --nc-bg-primary:     var(--surface);
  --nc-bg-secondary:   transparent;
  --nc-bg-tertiary:    var(--surface-2);
  --nc-border:         var(--line);
  --nc-border-dark:    var(--line-strong, var(--line));
}
