Heartwood for shadcn/ui

Heartwood is a shadcn/ui theme built around a muted yellow primary color (#a2a385) with muted purple accents (#a385a2). The light mode uses a neutral background (#fefefb). Dark mode keeps the muted yellow primary (#a2a385) on a yellow-tinted background (#0b0b05).

Color palette

TokenLightDark
Background
#fefefbwhite
#0b0b05black
Foreground
#141405black
#ffffffwhite
Card
#fefefbwhite
#0b0b05black
Card foreground
#141405black
#ffffffwhite
Popover
#fefefbwhite
#0b0b05black
Popover foreground
#141405black
#ffffffwhite
Primary
#a2a385darkseagreen
#a2a385darkseagreen
Primary foreground
#000000black
#000000black
Secondary
#85a2a3lightslategray
#85a2a3lightslategray
Secondary foreground
#000000black
#000000black
Muted
#e9ececlavender
#131616black
Muted foreground
#494f50darkslategray
#afb5b6darkgray
Accent
#a385a2rosybrown
#a385a2rosybrown
Accent foreground
#000000black
#000000black
Destructive
#870e08darkred
#ec190ered
Destructive foreground
#fcc8c5pink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#a2a385darkseagreen
#a2a385darkseagreen

Contrast

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

Light mode
Text on background18.34:1AAA
Text on card18.34:1AAA
Primary button8.11:1AAA
Secondary button7.71:1AAA
Muted text7.01:1AAA
Accent6.42:1AA
Destructive6.77:1AA
Dark mode
Text on background19.76:1AAA
Text on card19.76:1AAA
Primary button8.11:1AAA
Secondary button7.71:1AAA
Muted text8.78:1AAA
Accent6.42:1AA
Destructive4.45:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.996 0.004 107.24);
  --foreground: oklch(0.187 0.028 109.666);
  --muted: oklch(0.941 0.003 198.321);
  --muted-foreground: oklch(0.424 0.008 198.092);
  --popover: oklch(0.996 0.004 107.24);
  --popover-foreground: oklch(0.187 0.028 109.666);
  --card: oklch(0.996 0.004 107.24);
  --card-foreground: oklch(0.187 0.028 109.666);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.707 0.042 108.215);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.691 0.033 197.694);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.654 0.055 326.71);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.398 0.154 29.349);
  --destructive-foreground: oklch(0.877 0.059 21.851);
  --ring: oklch(0.707 0.042 108.215);
  --chart-1: oklch(0.707 0.042 108.215);
  --chart-2: oklch(0.691 0.033 197.694);
  --chart-3: oklch(0.654 0.055 326.71);
  --chart-4: oklch(0.714 0.03 197.758);
  --chart-5: oklch(0.715 0.051 108.403);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.145 0.015 108.787);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.196 0.004 198.079);
  --muted-foreground: oklch(0.77 0.007 198.231);
  --popover: oklch(0.145 0.015 108.787);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.145 0.015 108.787);
  --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.707 0.042 108.215);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.691 0.033 197.694);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.654 0.055 326.71);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.599 0.237 29.47);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.707 0.042 108.215);
  --chart-1: oklch(0.707 0.042 108.215);
  --chart-2: oklch(0.691 0.033 197.694);
  --chart-3: oklch(0.654 0.055 326.71);
  --chart-4: oklch(0.714 0.03 197.758);
  --chart-5: oklch(0.715 0.051 108.403);
}