Radiant for shadcn/ui

Radiant is a shadcn/ui theme built around a muted deep purple primary color (#302432) with muted deep teal accents (#243230). The light mode uses a neutral background (#fcf7fd). Dark mode keeps the muted deep purple primary (#302432) on a neutral background (#030203).

Color palette

TokenLightDark
Background
#fcf7fdghostwhite
#030203black
Foreground
#130515black
#fdfbfdsnow
Card
#faf3fbghostwhite
#060407black
Card foreground
#0f0411black
#ffffffwhite
Popover
#faf3fbghostwhite
#060407black
Popover foreground
#0f0411black
#ffffffwhite
Primary
#302432darkslategray
#302432darkslategray
Primary foreground
#cbbbcethistle
#cbbbcethistle
Secondary
#323024darkslategray
#323024darkslategray
Secondary foreground
#cecbbbsilver
#cecbbbsilver
Muted
#f2f0e4linen
#1b190dblack
Muted foreground
#6d6b5adimgray
#a5a392darkgray
Accent
#243230darkslategray
#243230darkslategray
Accent foreground
#bbcecbsilver
#bbcecbsilver
Destructive
#ac290cfirebrick
#d7340ffirebrick
Destructive foreground
#feefecseashell
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#302432darkslategray
#302432darkslategray

Contrast

WCAG 2 contrast ratios between each background and its foreground color.

Light mode
Text on background18.75:1AAA
Text on card18.49:1AAA
Primary button8.05:1AAA
Secondary button8.08:1AAA
Muted text4.69:1AA
Accent8.09:1AAA
Destructive6.11:1AA
Dark mode
Text on background20.12:1AAA
Text on card20.45:1AAA
Primary button8.05:1AAA
Secondary button8.08:1AAA
Muted text6.89:1AA
Accent8.09:1AAA
Destructive4.80:1AA

CSS variables

Paste this into your globals.css to use Radiant in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(0.982 0.008 321.616);
  --foreground: oklch(0.148 0.043 322.538);
  --muted: oklch(0.952 0.016 99.585);
  --muted-foreground: oklch(0.524 0.026 100.02);
  --popover: oklch(0.973 0.013 321.629);
  --popover-foreground: oklch(0.135 0.037 322.828);
  --card: oklch(0.973 0.013 321.629);
  --card-foreground: oklch(0.135 0.037 322.828);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.282 0.03 321.873);
  --primary-foreground: oklch(0.811 0.032 321.699);
  --secondary: oklch(0.309 0.021 100.212);
  --secondary-foreground: oklch(0.84 0.022 99.718);
  --accent: oklch(0.305 0.019 186.153);
  --accent-foreground: oklch(0.836 0.021 187.135);
  --destructive: oklch(0.489 0.171 33.292);
  --destructive-foreground: oklch(0.963 0.016 32.669);
  --ring: oklch(0.282 0.03 321.873);
  --chart-1: oklch(0.282 0.03 321.873);
  --chart-2: oklch(0.309 0.021 100.212);
  --chart-3: oklch(0.305 0.019 186.153);
  --chart-4: oklch(0.342 0.024 100.236);
  --chart-5: oklch(0.281 0.036 321.92);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.088 0.01 322.541);
  --foreground: oklch(0.991 0.003 321.601);
  --muted: oklch(0.214 0.022 100.538);
  --muted-foreground: oklch(0.712 0.025 99.823);
  --popover: oklch(0.111 0.013 322.541);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.111 0.013 322.541);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.282 0.03 321.873);
  --primary-foreground: oklch(0.811 0.032 321.699);
  --secondary: oklch(0.309 0.021 100.212);
  --secondary-foreground: oklch(0.84 0.022 99.718);
  --accent: oklch(0.305 0.019 186.153);
  --accent-foreground: oklch(0.836 0.021 187.135);
  --destructive: oklch(0.576 0.204 33.13);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.282 0.03 321.873);
  --chart-1: oklch(0.282 0.03 321.873);
  --chart-2: oklch(0.309 0.021 100.212);
  --chart-3: oklch(0.305 0.019 186.153);
  --chart-4: oklch(0.342 0.024 100.236);
  --chart-5: oklch(0.281 0.036 321.92);
}