Hateful for shadcn/ui

Hateful is a shadcn/ui theme built around a light green primary color (#cde6c6) with light red accents (#e6c6cd). The light mode uses a neutral background (#fcfefb). Dark mode keeps the light green primary (#cde6c6) on a neutral background (#040703).

Color palette

TokenLightDark
Background
#fcfefbwhite
#040703black
Foreground
#061103black
#fafbf9snow
Card
#fcfefbwhite
#040703black
Card foreground
#061103black
#fafbf9snow
Popover
#fcfefbwhite
#040703black
Popover foreground
#061103black
#fafbf9snow
Primary
#cde6c6lightgrey
#cde6c6lightgrey
Primary foreground
#305525darkslategray
#305525darkslategray
Secondary
#c6cde6lightgrey
#c6cde6lightgrey
Secondary foreground
#253055darkslategray
#253055darkslategray
Muted
#d0d5e6gainsboro
#191d2fblack
Muted foreground
#5c5c5cdimgray
#a3a3a3darkgray
Accent
#e6c6cdthistle
#e6c6cdthistle
Accent foreground
#552530darkslategray
#552530darkslategray
Destructive
#8b0f04darkred
#e01806red
Destructive foreground
#fdc8c3pink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#cde6c6lightgrey
#cde6c6lightgrey

Contrast

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

Light mode
Text on background18.95:1AAA
Text on card18.95:1AAA
Primary button6.42:1AA
Secondary button8.14:1AAA
Muted text4.57:1AA
Accent7.88:1AAA
Destructive6.55:1AA
Dark mode
Text on background19.52:1AAA
Text on card19.52:1AAA
Primary button6.42:1AA
Secondary button8.14:1AAA
Muted text6.60:1AA
Accent7.88:1AAA
Destructive4.89:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.994 0.003 138.892);
  --foreground: oklch(0.163 0.037 137.386);
  --muted: oklch(0.875 0.024 273.532);
  --muted-foreground: oklch(0.474 0 198.435);
  --popover: oklch(0.994 0.003 138.892);
  --popover-foreground: oklch(0.163 0.037 137.386);
  --card: oklch(0.994 0.003 138.892);
  --card-foreground: oklch(0.163 0.037 137.386);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.898 0.05 138.916);
  --primary-foreground: oklch(0.409 0.086 139.222);
  --secondary: oklch(0.851 0.035 273.352);
  --secondary-foreground: oklch(0.318 0.068 270.481);
  --accent: oklch(0.856 0.037 3.233);
  --accent-foreground: oklch(0.336 0.072 8.078);
  --destructive: oklch(0.407 0.158 30.327);
  --destructive-foreground: oklch(0.879 0.061 24.4);
  --ring: oklch(0.898 0.05 138.916);
  --chart-1: oklch(0.898 0.05 138.916);
  --chart-2: oklch(0.851 0.035 273.352);
  --chart-3: oklch(0.856 0.037 3.233);
  --chart-4: oklch(0.88 0.029 273.474);
  --chart-5: oklch(0.9 0.054 138.919);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.121 0.013 137.867);
  --foreground: oklch(0.986 0.002 138.891);
  --muted: oklch(0.237 0.034 271.747);
  --muted-foreground: oklch(0.716 0 165.964);
  --popover: oklch(0.121 0.013 137.867);
  --popover-foreground: oklch(0.986 0.002 138.891);
  --card: oklch(0.121 0.013 137.867);
  --card-foreground: oklch(0.986 0.002 138.891);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.898 0.05 138.916);
  --primary-foreground: oklch(0.409 0.086 139.222);
  --secondary: oklch(0.851 0.035 273.352);
  --secondary-foreground: oklch(0.318 0.068 270.481);
  --accent: oklch(0.856 0.037 3.233);
  --accent-foreground: oklch(0.336 0.072 8.078);
  --destructive: oklch(0.575 0.227 30.041);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.898 0.05 138.916);
  --chart-1: oklch(0.898 0.05 138.916);
  --chart-2: oklch(0.851 0.035 273.352);
  --chart-3: oklch(0.856 0.037 3.233);
  --chart-4: oklch(0.88 0.029 273.474);
  --chart-5: oklch(0.9 0.054 138.919);
}