Worse for shadcn/ui

Worse is a shadcn/ui theme built around a deep green primary color (#3a4f0d) with neutral gray accents (#dcdcda). The light mode uses a neutral background (#fdfefb). Dark mode keeps the deep green primary (#3a4f0d) on a green-tinted background (#0c1004).

Color palette

TokenLightDark
Background
#fdfefbwhite
#0c1004black
Foreground
#030401black
#fafcf8snow
Card
#fbfdf7snow
#0f1405black
Card foreground
#000000black
#fdfdfcwhite
Popover
#fdfefbwhite
#0c1004black
Popover foreground
#030401black
#fafcf8snow
Primary
#3a4f0ddarkolivegreen
#3a4f0ddarkolivegreen
Primary foreground
#d6ef9fpalegoldenrod
#d6ef9fpalegoldenrod
Secondary
#dcdcdagainsboro
#242522black
Secondary foreground
#434440darkslategray
#bec0b9silver
Muted
#e8ecdfbeige
#1c2013black
Muted foreground
#575b4ddarkolivegreen
#adb2a4darkgray
Accent
#dcdcdagainsboro
#242522black
Accent foreground
#434440darkslategray
#bec0b9silver
Destructive
#b32a00firebrick
#ff3c00orangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#3a4f0ddarkolivegreen
#3a4f0ddarkolivegreen

Contrast

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

Light mode
Text on background20.28:1AAA
Text on card20.44:1AAA
Primary button7.25:1AAA
Secondary button7.16:1AAA
Muted text5.80:1AA
Accent7.16:1AAA
Destructive6.49:1AA
Dark mode
Text on background18.61:1AAA
Text on card18.34:1AAA
Primary button7.25:1AAA
Secondary button8.34:1AAA
Muted text7.66:1AAA
Accent8.34:1AAA
Destructive3.56:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.995 0.004 120.829);
  --foreground: oklch(0.101 0.014 120.55);
  --muted: oklch(0.936 0.017 121.076);
  --muted-foreground: oklch(0.463 0.022 121.554);
  --popover: oklch(0.995 0.004 120.829);
  --popover-foreground: oklch(0.101 0.014 120.55);
  --card: oklch(0.99 0.007 120.892);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.396 0.092 126.142);
  --primary-foreground: oklch(0.915 0.107 122.81);
  --secondary: oklch(0.894 0.003 120.823);
  --secondary-foreground: oklch(0.385 0.007 121.06);
  --accent: oklch(0.894 0.003 120.823);
  --accent-foreground: oklch(0.385 0.007 121.06);
  --destructive: oklch(0.502 0.178 34.486);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.396 0.092 126.142);
  --chart-1: oklch(0.396 0.092 126.142);
  --chart-2: oklch(0.894 0.003 120.823);
  --chart-3: oklch(0.894 0.003 120.823);
  --chart-4: oklch(0.917 0.002 120.809);
  --chart-5: oklch(0.4 0.095 126.346);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.165 0.026 122.241);
  --foreground: oklch(0.988 0.004 120.842);
  --muted: oklch(0.235 0.024 122.527);
  --muted-foreground: oklch(0.755 0.019 121.194);
  --popover: oklch(0.165 0.026 122.241);
  --popover-foreground: oklch(0.988 0.004 120.842);
  --card: oklch(0.182 0.03 123.102);
  --card-foreground: oklch(0.994 0.002 120.804);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.396 0.092 126.142);
  --primary-foreground: oklch(0.915 0.107 122.81);
  --secondary: oklch(0.264 0.007 121.188);
  --secondary-foreground: oklch(0.804 0.009 120.962);
  --accent: oklch(0.264 0.007 121.188);
  --accent-foreground: oklch(0.804 0.009 120.962);
  --destructive: oklch(0.652 0.236 33.804);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.396 0.092 126.142);
  --chart-1: oklch(0.396 0.092 126.142);
  --chart-2: oklch(0.264 0.007 121.188);
  --chart-3: oklch(0.264 0.007 121.188);
  --chart-4: oklch(0.296 0.008 121.209);
  --chart-5: oklch(0.4 0.095 126.346);
}