Colors

Axiom's color system uses OKLCH with hand-tuned lightness and chroma per shade. Six chromatic hues, eleven neutral steps, and a set of semantic tokens that auto-invert for dark mode. Plain CSS, custom properties, no build step.

Color Philosophy

Axiom provides six vibrant colors (red, orange, yellow, green, blue, purple) and an 11-step neutral scale. Each vibrant color has five swatches (100, 300, 500, 700, 900) instead of the typical ten-step scale you might expect from other systems.

Why five? Smaller CSS footprint, and frankly, fewer choices can be liberating. Five swatches cover the range from light tints to dark shades while encouraging consistency. When everyone on a team (or every LLM) has fewer options, you are more likely to converge on the same choices.

Why purple instead of separate indigo and violet? Pragmatism. Purple serves both roles well enough while keeping the palette lean. If you need indigo, add it. This is your CSS.

Color Ramps

Each vibrant color shares a hue variable (e.g. --blue-hue: 260) across all five shades. Lightness and chroma are set per shade for clean results -- no muddy dark yellows or washed-out tints.

Rotate --blue-hue and the entire blue ramp follows. Need finer control? Adjust the lightness or chroma of any individual shade directly. The system uses OKLCH throughout for perceptually uniform results.

Vibrant Colors

Six colors spanning the spectrum. Each includes text and background utilities with dark mode variants:

Red

.bg-red-100
.bg-red-300
.bg-red-500
.bg-red-700
.bg-red-900
.text-red-100 .text-red-300 .text-red-500 .text-red-700 .text-red-900

Orange

.bg-orange-100
.bg-orange-300
.bg-orange-500
.bg-orange-700
.bg-orange-900
.text-orange-100 .text-orange-300 .text-orange-500 .text-orange-700 .text-orange-900

Yellow

.bg-yellow-100
.bg-yellow-300
.bg-yellow-500
.bg-yellow-700
.bg-yellow-900
.text-yellow-100 .text-yellow-300 .text-yellow-500 .text-yellow-700 .text-yellow-900

Green

.bg-green-100
.bg-green-300
.bg-green-500
.bg-green-700
.bg-green-900
.text-green-100 .text-green-300 .text-green-500 .text-green-700 .text-green-900

Blue

.bg-blue-100
.bg-blue-300
.bg-blue-500
.bg-blue-700
.bg-blue-900
.text-blue-100 .text-blue-300 .text-blue-500 .text-blue-700 .text-blue-900

Purple

.bg-purple-100
.bg-purple-300
.bg-purple-500
.bg-purple-700
.bg-purple-900
.text-purple-100 .text-purple-300 .text-purple-500 .text-purple-700 .text-purple-900

Neutral Colors

Eleven steps from near-white to near-black. Neutrals need finer control than vibrant colors because they do the heavy lifting for borders, backgrounds, and text hierarchy:

.bg-neutral-25
.bg-neutral-50
.bg-neutral-100
.bg-neutral-200
.bg-neutral-300
.bg-neutral-400
.bg-neutral-500
.bg-neutral-600
.bg-neutral-700
.bg-neutral-800
.bg-neutral-900

Text utilities follow the same pattern: .text-neutral-25 through .text-neutral-900

Invertible Color System

The i-* utilities are semantic tokens that adapt to light and dark modes automatically. Write your markup once, works in both themes. Toggle the theme in the sidebar to see them flip.

Background elevation: Four layers that stack logically. In light mode, they descend from white. In dark mode, they ascend from near-black.

.i-bg-floor
.i-bg-surface
.i-bg-raised
.i-bg-float

Text hierarchy: Three levels of contrast, from strong to soft. Values invert for readability in each theme.

.i-text-strong .i-text-regular .i-text-soft

Border contrast: Three levels for different emphasis needs. These also set border-style: solid automatically.

.i-border-strong
.i-border-regular
.i-border-soft

Accent color: The --i-accent token provides a single interactive color for links, buttons, and focus rings. It defaults to --blue-500 in light mode and --blue-300 in dark mode.

Status colors: Four semantic palettes for callouts, alerts, badges, and form validation. Each has a background, text, and border class. They auto-invert with .dark just like the rest of the system.

Info -- something worth knowing about.
Success -- the operation completed.
Warning -- proceed with caution.
Error -- something went wrong.

Classes follow the pattern .i-status-{info,success,warning,error}-{bg,text,border}. Compose all three for a complete callout, or use them individually.

The base layer uses these tokens extensively. Forms, tables, and other elements automatically adapt to theme changes without additional markup.

Opacity Utilities

Control transparency for backgrounds, text, and borders. These set custom properties that the color utilities read:

Background opacity
100%
70%
50%
30%
10%

Classes: .bg-opacity-0 through .bg-opacity-100 in 10% increments

Text opacity
100% 70% 50% 30% 10%

Classes: .text-opacity-0 through .text-opacity-100 in 10% increments

Border opacity
100%
70%
50%
30%
10%

Classes: .border-opacity-0 through .border-opacity-100 in 10% increments

Dark Mode Variants

All vibrant and neutral color utilities include dark: variants that apply only when the .dark class is present on a parent element:

.bg-blue-100 .dark:bg-blue-900

Toggle dark mode in the sidebar to see this swap backgrounds

For many cases, the invertible system (i-* utilities) handles theme switching without explicit dark variants. Use dark: variants when you need specific color choices in each theme.