Green Theme for shadcn/ui

Green Theme is a shadcn/ui theme built around a vivid teal primary color (#11ac80) with vivid cyan accents (#118aac). The light mode uses a neutral background (#f8fcfb). Dark mode keeps the vivid teal primary (#11ac80) on a neutral background (#010403).

Color palette

TokenLightDark
Background
#f8fcfbmintcream
#010403black
Foreground
#010907black
#f5faf8mintcream
Card
#f4fbf9mintcream
#030806black
Card foreground
#010503black
#f8fcfbmintcream
Popover
#f4fbf9mintcream
#030806black
Popover foreground
#010503black
#f8fcfbmintcream
Primary
#11ac80darkcyan
#11ac80darkcyan
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#11ac33forestgreen
#11ac33forestgreen
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#e1efe4gainsboro
#101e13black
Muted foreground
#475249darkslategray
#adb8afdarkgray
Accent
#118aacdarkcyan
#118aacdarkcyan
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#9f2a09firebrick
#f24b1corangered
Destructive foreground
#fde4ddmistyrose
#ffffffwhite
Border
#e5e6e6gainsboro
#202222black
Input
#e5e6e6gainsboro
#202222black
Ring
#11ac80darkcyan
#11ac80darkcyan

Contrast

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

Light mode
Text on background19.47:1AAA
Text on card19.50:1AAA
Primary button2.91:1Fail
Secondary button3.02:1AA Large
Muted text6.86:1AA
Accent3.98:1AA Large
Destructive6.17:1AA
Dark mode
Text on background19.52:1AAA
Text on card19.54:1AAA
Primary button2.91:1Fail
Secondary button3.02:1AA Large
Muted text8.44:1AAA
Accent3.98:1AA Large
Destructive3.63:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.988 0.005 177.563);
  --foreground: oklch(0.128 0.02 177.905);
  --muted: oklch(0.938 0.02 152.283);
  --muted-foreground: oklch(0.426 0.019 151.885);
  --popover: oklch(0.982 0.008 177.486);
  --popover-foreground: oklch(0.101 0.016 177.905);
  --card: oklch(0.982 0.008 177.486);
  --card-foreground: oklch(0.101 0.016 177.905);
  --border: oklch(0.924 0.002 177.66);
  --input: oklch(0.924 0.002 177.66);
  --primary: oklch(0.661 0.134 166.344);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.648 0.199 145.059);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.59 0.107 223.557);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.467 0.158 34.659);
  --destructive-foreground: oklch(0.938 0.029 35.946);
  --ring: oklch(0.661 0.134 166.344);
  --chart-1: oklch(0.661 0.134 166.344);
  --chart-2: oklch(0.648 0.199 145.059);
  --chart-3: oklch(0.59 0.107 223.557);
  --chart-4: oklch(0.686 0.211 145.008);
  --chart-5: oklch(0.668 0.137 165.975);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.098 0.01 177.845);
  --foreground: oklch(0.98 0.005 177.552);
  --muted: oklch(0.217 0.028 150.391);
  --muted-foreground: oklch(0.771 0.017 152.273);
  --popover: oklch(0.124 0.013 177.845);
  --popover-foreground: oklch(0.987 0.004 177.607);
  --card: oklch(0.124 0.013 177.845);
  --card-foreground: oklch(0.987 0.004 177.607);
  --border: oklch(0.25 0.003 177.349);
  --input: oklch(0.25 0.003 177.349);
  --primary: oklch(0.661 0.134 166.344);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.648 0.199 145.059);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.59 0.107 223.557);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.644 0.211 35.13);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.661 0.134 166.344);
  --chart-1: oklch(0.661 0.134 166.344);
  --chart-2: oklch(0.648 0.199 145.059);
  --chart-3: oklch(0.59 0.107 223.557);
  --chart-4: oklch(0.686 0.211 145.008);
  --chart-5: oklch(0.668 0.137 165.975);
}