Tambour for shadcn/ui

Tambour is a shadcn/ui theme built around a vivid deep green primary color (#0c7939) with muted light green accents (#b4d5c2). The light mode uses a neutral background (#f7fdf9). Dark mode keeps the vivid deep green primary (#0c7939) on a green-tinted background (#041009).

Color palette

TokenLightDark
Background
#f7fdf9mintcream
#041009black
Foreground
#010402black
#f6f9f7whitesmoke
Card
#f7fdf9mintcream
#041009black
Card foreground
#010402black
#f6f9f7whitesmoke
Popover
#f7fdf9mintcream
#041009black
Popover foreground
#010402black
#f6f9f7whitesmoke
Primary
#0c7939forestgreen
#0c7939forestgreen
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#d5e2dagainsboro
#23342adarkslategray
Secondary foreground
#364f40darkslategray
#b9cfc2silver
Muted
#eef1efwhitesmoke
#0e110fblack
Muted foreground
#586a5fdimgray
#95a79ddarkgray
Accent
#b4d5c2silver
#30503ddarkslategray
Accent foreground
#1f3729darkslategray
#cfe2d7gainsboro
Destructive
#6a1b0bmaroon
#e84321orangered
Destructive foreground
#f7bcb1lightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#0c7939forestgreen
#0c7939forestgreen

Contrast

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

Light mode
Text on background19.98:1AAA
Text on card19.98:1AAA
Primary button5.53:1AA
Secondary button6.68:1AA
Muted text5.08:1AA
Accent8.07:1AAA
Destructive7.19:1AAA
Dark mode
Text on background18.26:1AAA
Text on card18.26:1AAA
Primary button5.53:1AA
Secondary button8.03:1AAA
Muted text7.50:1AAA
Accent6.65:1AA
Destructive4.01:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.988 0.008 160.819);
  --foreground: oklch(0.1 0.017 160.927);
  --muted: oklch(0.956 0.004 160.914);
  --muted-foreground: oklch(0.505 0.026 159.719);
  --popover: oklch(0.988 0.008 160.819);
  --popover-foreground: oklch(0.1 0.017 160.927);
  --card: oklch(0.988 0.008 160.819);
  --card-foreground: oklch(0.1 0.017 160.927);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.504 0.133 150.614);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.901 0.018 160.535);
  --secondary-foreground: oklch(0.402 0.04 158.426);
  --accent: oklch(0.843 0.044 159.728);
  --accent-foreground: oklch(0.314 0.04 157.525);
  --destructive: oklch(0.352 0.115 33.107);
  --destructive-foreground: oklch(0.846 0.07 31.439);
  --ring: oklch(0.504 0.133 150.614);
  --chart-1: oklch(0.504 0.133 150.614);
  --chart-2: oklch(0.901 0.018 160.535);
  --chart-3: oklch(0.843 0.044 159.728);
  --chart-4: oklch(0.922 0.014 160.65);
  --chart-5: oklch(0.51 0.136 150.307);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.159 0.024 159.131);
  --foreground: oklch(0.979 0.005 160.902);
  --muted: oklch(0.173 0.006 160.155);
  --muted-foreground: oklch(0.711 0.024 160.18);
  --popover: oklch(0.159 0.024 159.131);
  --popover-foreground: oklch(0.979 0.005 160.902);
  --card: oklch(0.159 0.024 159.131);
  --card-foreground: oklch(0.979 0.005 160.902);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.504 0.133 150.614);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.305 0.028 158.645);
  --secondary-foreground: oklch(0.836 0.03 160.142);
  --accent: oklch(0.399 0.049 157.634);
  --accent-foreground: oklch(0.896 0.025 160.332);
  --destructive: oklch(0.62 0.207 33.034);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.504 0.133 150.614);
  --chart-1: oklch(0.504 0.133 150.614);
  --chart-2: oklch(0.305 0.028 158.645);
  --chart-3: oklch(0.399 0.049 157.634);
  --chart-4: oklch(0.338 0.032 158.555);
  --chart-5: oklch(0.51 0.136 150.307);
}