Iridescence for shadcn/ui

Iridescence is a shadcn/ui theme built around a light green primary color (#c9efc8) with light purple accents (#eec8ef). The light mode uses a neutral background (#fcfdfc). Dark mode keeps the light green primary (#c9efc8) on a neutral background (#040703).

Color palette

TokenLightDark
Background
#fcfdfcwhite
#040703black
Foreground
#031703black
#ffffffwhite
Card
#f8fcf8mintcream
#050a05black
Card foreground
#021202black
#ffffffwhite
Popover
#f8fcf8mintcream
#050a05black
Popover foreground
#021202black
#ffffffwhite
Primary
#c9efc8lightgrey
#c9efc8lightgrey
Primary foreground
#071807black
#071807black
Secondary
#eec8efgainsboro
#eec8efgainsboro
Secondary foreground
#651e66purple
#651e66purple
Muted
#e6d0e7gainsboro
#2f182fdarkslategray
Muted foreground
#4e4b4edarkslategray
#b4b1b4darkgray
Accent
#eec8efgainsboro
#eec8efgainsboro
Accent foreground
#651e66purple
#651e66purple
Destructive
#dc4909orangered
#f04f0aorangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#c9efc8lightgrey
#c9efc8lightgrey

Contrast

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

Light mode
Text on background18.27:1AAA
Text on card18.55:1AAA
Primary button14.53:1AAA
Secondary button7.32:1AAA
Muted text5.95:1AA
Accent7.32:1AAA
Destructive4.20:1AA Large
Dark mode
Text on background20.28:1AAA
Text on card19.94:1AAA
Primary button14.53:1AAA
Secondary button7.32:1AAA
Muted text7.64:1AAA
Accent7.32:1AAA
Destructive3.60:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.993 0.003 145.081);
  --foreground: oklch(0.18 0.051 142.693);
  --muted: oklch(0.882 0.039 325.404);
  --muted-foreground: oklch(0.417 0.006 325.206);
  --popover: oklch(0.986 0.005 145.062);
  --popover-foreground: oklch(0.162 0.045 142.7);
  --card: oklch(0.986 0.005 145.062);
  --card-foreground: oklch(0.162 0.045 142.7);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.914 0.065 144.585);
  --primary-foreground: oklch(0.187 0.04 143.401);
  --secondary: oklch(0.877 0.066 325.608);
  --secondary-foreground: oklch(0.378 0.136 327.164);
  --accent: oklch(0.877 0.066 325.608);
  --accent-foreground: oklch(0.378 0.136 327.164);
  --destructive: oklch(0.606 0.194 38.201);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.914 0.065 144.585);
  --chart-1: oklch(0.914 0.065 144.585);
  --chart-2: oklch(0.877 0.066 325.608);
  --chart-3: oklch(0.877 0.066 325.608);
  --chart-4: oklch(0.903 0.052 325.489);
  --chart-5: oklch(0.915 0.069 144.557);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.119 0.014 144.164);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.251 0.052 326.405);
  --muted-foreground: oklch(0.764 0.005 325.15);
  --popover: oklch(0.137 0.016 144.164);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.137 0.016 144.164);
  --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.914 0.065 144.585);
  --primary-foreground: oklch(0.187 0.04 143.401);
  --secondary: oklch(0.877 0.066 325.608);
  --secondary-foreground: oklch(0.378 0.136 327.164);
  --accent: oklch(0.877 0.066 325.608);
  --accent-foreground: oklch(0.378 0.136 327.164);
  --destructive: oklch(0.645 0.207 38.068);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.914 0.065 144.585);
  --chart-1: oklch(0.914 0.065 144.585);
  --chart-2: oklch(0.877 0.066 325.608);
  --chart-3: oklch(0.877 0.066 325.608);
  --chart-4: oklch(0.903 0.052 325.489);
  --chart-5: oklch(0.915 0.069 144.557);
}