Mira
All docs

Theming

Pick light or dark, change colors, type, spacing, and motion from mira.config.json, and style pages without fighting the defaults.

Every Mira page starts with a theme written as CSS custom properties. Change any of them from config, or use them in your own CSS.

Light or dark

{ "scheme": "dark" }
ValueResult
darkDark theme, the default
lightLight theme
systemFollows the reader’s setting

Color tokens use light-dark(), so the same names work in both themes.

Change tokens

Set values under theme. Nested keys join with dashes into the property name:

{
  "theme": {
    "ink": "#f4f1ea",
    "radius": { "md": "10px" },
    "font": { "display": "Inter, system-ui, sans-serif" },
    "motion": { "morph": "640ms" }
  }
}

That sets --ink, --radius-md, --font-display, and --motion-morph above the defaults. Values cannot contain {, }, ;, or <.

Tokens

TokenUse
--surface-0, --surface-1, --surface-2Page ground, raised panels, and wells such as code blocks
--ink, --ink-muted, --ink-faintText, from primary to captions
--line, --line-strongDividers and control borders
--focusFocus rings
--font-text, --font-display, --font-monoBody, headings, and code
--text-sm, --text-base, --text-lgText sizes
--display-sm to --display-xlFluid heading sizes
--space-1, -2, -3, -4, -6, -8, -12, -16, -24Spacing: the step times 4px, so --space-6 is 24px
--radius-sm, --radius-md, --radius-lg, --radius-xlCorner radii
--motion-fast, --motion-control, --motion-morphDurations for crossfades, controls, and shared elements

Your CSS wins

Mira’s CSS sits in ordered cascade layers, so styles in your layouts and pages override it without !important:

@layer mira.reset, mira.tokens, mira.theme, mira.base, mira.prose,
       mira.components, mira.transitions, layout, page;

A layout’s <style> lands in layout, and a page’s in page.