Crusader for shadcn/ui

Crusader is a shadcn/ui theme built around a light purple primary color (#e3bfe2) with light green accents (#bfe3c0). The light mode uses a neutral background (#fefbfe). Dark mode keeps the light purple primary (#e3bfe2) on a neutral background (#070307).

Color palette

TokenLightDark
Background
#fefbfewhite
#070307black
Foreground
#000000black
#ffffffwhite
Card
#fefbfewhite
#070307black
Card foreground
#000000black
#ffffffwhite
Popover
#fefbfewhite
#070307black
Popover foreground
#000000black
#ffffffwhite
Primary
#e3bfe2thistle
#e3bfe2thistle
Primary foreground
#4e224ddarkslategray
#4e224ddarkslategray
Secondary
#bfe3c0lightgrey
#bfe3c0lightgrey
Secondary foreground
#224e23darkslategray
#224e23darkslategray
Muted
#f2f3f2whitesmoke
#0c0d0cblack
Muted foreground
#415341darkslategray
#acbeacdarkgray
Accent
#bfe3c0lightgrey
#bfe3c0lightgrey
Accent foreground
#224e23darkslategray
#224e23darkslategray
Destructive
#920901darkred
#fd2217red
Destructive foreground
#fecac7pink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#e3bfe2thistle
#e3bfe2thistle

Contrast

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

Light mode
Text on background20.41:1AAA
Text on card20.41:1AAA
Primary button7.73:1AAA
Secondary button6.85:1AA
Muted text7.42:1AAA
Accent6.85:1AA
Destructive6.38:1AA
Dark mode
Text on background20.46:1AAA
Text on card20.46:1AAA
Primary button7.73:1AAA
Secondary button6.85:1AA
Muted text9.91:1AAA
Accent6.85:1AA
Destructive3.88:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.991 0.006 326.1);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.962 0.002 146.036);
  --muted-foreground: oklch(0.421 0.036 145.324);
  --popover: oklch(0.991 0.006 326.1);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.991 0.006 326.1);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.847 0.062 326.625);
  --primary-foreground: oklch(0.333 0.091 328.001);
  --secondary: oklch(0.881 0.061 145.472);
  --secondary-foreground: oklch(0.381 0.085 143.977);
  --accent: oklch(0.881 0.061 145.472);
  --accent-foreground: oklch(0.381 0.085 143.977);
  --destructive: oklch(0.419 0.167 29.874);
  --destructive-foreground: oklch(0.885 0.06 21.85);
  --ring: oklch(0.847 0.062 326.625);
  --chart-1: oklch(0.847 0.062 326.625);
  --chart-2: oklch(0.881 0.061 145.472);
  --chart-3: oklch(0.881 0.061 145.472);
  --chart-4: oklch(0.9 0.051 145.584);
  --chart-5: oklch(0.846 0.067 326.667);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.111 0.016 327.03);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.159 0.003 145.881);
  --muted-foreground: oklch(0.783 0.031 145.723);
  --popover: oklch(0.111 0.016 327.03);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.111 0.016 327.03);
  --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.847 0.062 326.625);
  --primary-foreground: oklch(0.333 0.091 328.001);
  --secondary: oklch(0.881 0.061 145.472);
  --secondary-foreground: oklch(0.381 0.085 143.977);
  --accent: oklch(0.881 0.061 145.472);
  --accent-foreground: oklch(0.381 0.085 143.977);
  --destructive: oklch(0.634 0.246 29.368);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.847 0.062 326.625);
  --chart-1: oklch(0.847 0.062 326.625);
  --chart-2: oklch(0.881 0.061 145.472);
  --chart-3: oklch(0.881 0.061 145.472);
  --chart-4: oklch(0.9 0.051 145.584);
  --chart-5: oklch(0.846 0.067 326.667);
}