Core Tokens
The shared color roles, shade scale, and naming rules behind Natcore components and utilities.
Token model
Choose a palette by intent: primary, surface, danger, success, and the rest of the core roles.
Use the shade scale for hierarchy: lower numbers are softer, higher numbers carry stronger contrast.
Pair background and foreground tokens so text follows the active palette and theme.
Palette roles
Primary actions, selected states, and the main brand direction.
bg-primary-500text-on-primary-500palette-primarySupporting actions and secondary moments that still need color.
bg-secondary-500text-on-secondary-500palette-secondaryHighlights, emphasis, and moments that should stand apart.
bg-accent-500text-on-accent-500palette-accentPage backgrounds, containers, borders, and neutral text.
bg-surface-500text-on-surface-500palette-surfacePositive outcomes, confirmations, and valid states.
bg-success-500text-on-success-500palette-successDestructive actions, errors, and blocking states.
bg-danger-500text-on-danger-500palette-dangerUnavailable controls, subdued text, and inactive surfaces.
bg-disabled-500text-on-disabled-500palette-disabledShade scale
Using tokens
<button class="btn-solid/primary btn-size-md">
Save changes
</button>
<div class="card card-soft/surface">
<p class="text-surface-950/70">
Tokens stay readable in markup.
</p>
</div>
A class like btn-solid/primary says what the element is doing. Theme values can move underneath it without changing the markup.
Theme anchors
:root[data-theme="citrine-reef"] {
--theme-primary: #087f8c;
--theme-secondary: #f59e0b;
--theme-accent: #ef476f;
--theme-surface-50: #f4fbf7;
--theme-surface-500: #678f82;
--theme-surface-950: #071c18;
}Soft surface and low-emphasis fills.
The theme's central role color.
Strong contrast for text and deep surfaces.