Foundations

Design tokens

195 tokens, all prefixed --lb-. Components consume semantic tokens only — never a palette ramp, never a raw value. That is what makes a re-theme a values-only change.

Colour

Defined in OKLCH so the greyscale ramp is perceptually even and the dark theme is a lightness inversion rather than a second hand-tuned palette. The system is achromatic by construction: chroma appears only where it carries meaning — status and syntax.

Semantic — surfaces

--lb-backgroundoklch(0.965 0 0)
--lb-surfaceoklch(1 0 0)
--lb-surface-2oklch(0.98 0 0)
--lb-surface-3oklch(0.95 0 0)

Semantic — ink

--lb-on-surfaceoklch(0.18 0 0)
--lb-on-surface-2oklch(0.38 0 0)
--lb-on-surface-3oklch(0.52 0 0)
--lb-on-primaryoklch(0.98 0 0)

Semantic — lines

--lb-outlineoklch(0.92 0 0)
--lb-outline-softoklch(0.95 0 0)
--lb-outline-strongoklch(0.62 0 0)

Semantic — action

--lb-primaryoklch(0.18 0 0)
--lb-primary-hoveroklch(0.28 0 0)
--lb-primary-activeoklch(0.12 0 0)
--lb-focusvar(--lb-primary)

Status

--lb-successoklch(0.50 0.13 150)
--lb-warningoklch(0.50 0.11 75)
--lb-erroroklch(0.52 0.20 25)
--lb-infooklch(0.50 0.16 250)

Status surfaces

--lb-success-surfaceoklch(0.96 0.02 150)
--lb-warning-surfaceoklch(0.96 0.03 75)
--lb-error-surfaceoklch(0.96 0.02 25)
--lb-info-surfaceoklch(0.96 0.02 250)

The interactive-boundary rule

--lb-outline is a decorative hairline. The perimeter of any control a person must find and operate uses --lb-outline-strong, which clears 3:1 for WCAG 1.4.11. Drawing an input with --lb-outline looks correct and fails.

Type

One geometric sans at weights 400 and 500 for every human sentence; one monospace for everything machine-authored. Hierarchy comes from size, colour and space — weight 600 and above is not in the system.

Scale

TokenValue
--lb-type-display500 clamp(36px, 8vw, 56px)/1.05 var(--lb-font-sans)
--lb-type-h1500 clamp(32px, 6vw, 44px)/1.1 var(--lb-font-sans)
--lb-type-h2500 clamp(26px, 4vw, 32px)/1.15 var(--lb-font-sans)
--lb-type-h3500 22px/1.25 var(--lb-font-sans)
--lb-type-h4500 18px/1.3 var(--lb-font-sans)
--lb-type-body-lg400 18px/1.55 var(--lb-font-sans)
--lb-type-body400 17px/1.7 var(--lb-font-sans)
--lb-type-body-sm400 15px/1.55 var(--lb-font-sans)
--lb-type-body-xs400 14px/1.5 var(--lb-font-sans)
--lb-type-label-lg500 15px/1.2 var(--lb-font-sans)
--lb-type-label500 14px/1.2 var(--lb-font-sans)
--lb-type-label-sm500 13px/1.2 var(--lb-font-sans)
--lb-type-caption500 12px/1.4 var(--lb-font-sans)
--lb-type-mono400 13px/1.65 var(--lb-font-mono)
--lb-type-mono-sm500 12px/1.4 var(--lb-font-mono)
--lb-type-mono-xs500 11px/1.4 var(--lb-font-mono)

Space

Every spatial value is a multiple of 4. If a gap is not on this scale, it is a bug.

Rhythm

TokenValue
--lb-s-14px
--lb-s-28px
--lb-s-312px
--lb-s-416px
--lb-s-520px
--lb-s-624px
--lb-s-732px
--lb-s-840px
--lb-s-948px
--lb-s-1064px
--lb-s-1180px
--lb-s-12112px

Layout

TokenValue
--lb-page600px
--lb-wide1120px
--lb-measure60ch
--lb-gutter16px
--lb-gutter-md24px
--lb-control-h44px
--lb-control-h-sm36px
--lb-control-h-lg52px
--lb-field-h48px
--lb-tap-min44px

Shape

Radius is bimodal and carries meaning: pill means press me, sm/md means type in me or read me, md/lg means I contain other controls. In a palette with no accent colour, shape is the affordance signal.

Radius

TokenValue
--lb-r-none0px
--lb-r-xs6px
--lb-r-sm10px
--lb-r-md16px
--lb-r-lg24px
--lb-r-xl32px
--lb-r-pill999px
--lb-r-full50%

Elevation

Separation is drawn, not implied: a 1px rule is the default boundary. Shadow is reserved for things that genuinely float. A component may not invent a shadow — if flat is wrong, the answer is the next tier up or a border.

Tiers

TokenValue
--lb-elev-flatnone
--lb-elev-raised0 1px 2px oklch(0.18 0 0 / 0.04), 0 2px 8px oklch(0.18 0 0 / 0.04)
--lb-elev-float0 2px 6px oklch(0.18 0 0 / 0.05), 0 12px 28px oklch(0.18 0 0 / 0.07)
--lb-elev-popover0 4px 10px oklch(0.18 0 0 / 0.06), 0 18px 42px oklch(0.18 0 0 / 0.10)
--lb-elev-modal0 8px 20px oklch(0.18 0 0 / 0.08), 0 36px 72px oklch(0.18 0 0 / 0.16)

Motion

Motion explains state changes; it never entertains. Only transform, opacity and colour are animated — never height, width, top or left.

Duration and easing

TokenValue
--lb-dur-instant90ms
--lb-dur-fast180ms
--lb-dur-normal280ms
--lb-dur-slow520ms
--lb-easecubic-bezier(0.22, 1, 0.36, 1)
--lb-ease-outcubic-bezier(0.16, 1, 0.3, 1)
--lb-ease-in-outcubic-bezier(0.65, 0, 0.35, 1)
--lb-ease-springcubic-bezier(0.34, 1.4, 0.64, 1)

Full manifest

Machine-readable at dist/tokens.json, and as CSS at dist/tokens.css.

Navigation

Start here

Foundations

Components

See it

On this page