Toffee for shadcn/ui

Toffee is a shadcn/ui theme built around a muted deep teal primary color (#101414) with muted deep yellow accents (#141410). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted deep teal primary (#101414) on a teal-tinted background (#030b0c).

Color palette

TokenLightDark
Background
#ffffffwhite
#030b0cblack
Foreground
#020c0dblack
#fcfdfdwhite
Card
#ffffffwhite
#030b0cblack
Card foreground
#020c0dblack
#fcfdfdwhite
Popover
#ffffffwhite
#030b0cblack
Popover foreground
#020c0dblack
#fcfdfdwhite
Primary
#101414black
#101414black
Primary foreground
#a2b3b4darkgray
#a2b3b4darkgray
Secondary
#141014black
#141014black
Secondary foreground
#b4a2b3darkgray
#b4a2b3darkgray
Muted
#f5ebf4whitesmoke
#140a14black
Muted foreground
#514d50darkslategray
#b2aeb1darkgray
Accent
#141410black
#141410black
Accent foreground
#b3b4a2darkgray
#b3b4a2darkgray
Destructive
#682003maroon
#f96f39tomato
Destructive foreground
#fcbba1lightpink
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#101414black
#101414black

Contrast

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

Light mode
Text on background19.79:1AAA
Text on card19.79:1AAA
Primary button8.54:1AAA
Secondary button7.87:1AAA
Muted text7.13:1AAA
Accent8.78:1AAA
Destructive7.11:1AAA
Dark mode
Text on background19.46:1AAA
Text on card19.46:1AAA
Primary button8.54:1AAA
Secondary button7.87:1AAA
Muted text8.83:1AAA
Accent8.78:1AAA
Destructive7.37:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.145 0.019 200.062);
  --muted: oklch(0.95 0.016 327.71);
  --muted-foreground: oklch(0.426 0.006 327.691);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.145 0.019 200.062);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.145 0.019 200.062);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.185 0.006 201.906);
  --primary-foreground: oklch(0.753 0.019 201.956);
  --secondary: oklch(0.179 0.01 328.067);
  --secondary-foreground: oklch(0.732 0.032 327.97);
  --accent: oklch(0.189 0.008 110.231);
  --accent-foreground: oklch(0.764 0.026 110.099);
  --destructive: oklch(0.353 0.109 38.936);
  --destructive-foreground: oklch(0.845 0.084 42.518);
  --ring: oklch(0.185 0.006 201.906);
  --chart-1: oklch(0.185 0.006 201.906);
  --chart-2: oklch(0.179 0.01 328.067);
  --chart-3: oklch(0.189 0.008 110.231);
  --chart-4: oklch(0.212 0.013 328.144);
  --chart-5: oklch(0.186 0.007 201.84);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.142 0.015 200.325);
  --foreground: oklch(0.993 0.001 202.206);
  --muted: oklch(0.165 0.025 328.908);
  --muted-foreground: oklch(0.755 0.005 327.617);
  --popover: oklch(0.142 0.015 200.325);
  --popover-foreground: oklch(0.993 0.001 202.206);
  --card: oklch(0.142 0.015 200.325);
  --card-foreground: oklch(0.993 0.001 202.206);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.185 0.006 201.906);
  --primary-foreground: oklch(0.753 0.019 201.956);
  --secondary: oklch(0.179 0.01 328.067);
  --secondary-foreground: oklch(0.732 0.032 327.97);
  --accent: oklch(0.189 0.008 110.231);
  --accent-foreground: oklch(0.764 0.026 110.099);
  --destructive: oklch(0.702 0.182 40.651);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.185 0.006 201.906);
  --chart-1: oklch(0.185 0.006 201.906);
  --chart-2: oklch(0.179 0.01 328.067);
  --chart-3: oklch(0.189 0.008 110.231);
  --chart-4: oklch(0.212 0.013 328.144);
  --chart-5: oklch(0.186 0.007 201.84);
}