Unselfish for shadcn/ui

Unselfish is a shadcn/ui theme built around a vivid green primary color (#19f01c) with vivid red accents (#f01c19). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid green primary (#19f01c) on a neutral background (#020802).

Color palette

TokenLightDark
Background
#ffffffwhite
#020802black
Foreground
#050f05black
#fcfdfcwhite
Card
#ffffffwhite
#020802black
Card foreground
#050f05black
#fcfdfcwhite
Popover
#ffffffwhite
#020802black
Popover foreground
#050f05black
#fcfdfcwhite
Primary
#19f01clime
#19f01clime
Primary foreground
#043a05darkgreen
#043a05darkgreen
Secondary
#1c19f0blue
#1c19f0blue
Secondary foreground
#d9d9fdlavender
#d9d9fdlavender
Muted
#d7d7e0gainsboro
#1f1f28black
Muted foreground
#4c4c67darkslategray
#9998b3darkgray
Accent
#f01c19red
#f01c19red
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#983206saddlebrown
#f65f1echocolate
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#19f01clime
#19f01clime

Contrast

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

Light mode
Text on background19.49:1AAA
Text on card19.49:1AAA
Primary button8.40:1AAA
Secondary button6.24:1AA
Muted text5.77:1AA
Accent4.28:1AA Large
Destructive7.52:1AAA
Dark mode
Text on background19.82:1AAA
Text on card19.82:1AAA
Primary button8.40:1AAA
Secondary button6.24:1AA
Muted text5.82:1AA
Accent4.28:1AA Large
Destructive6.54:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.155 0.028 144.547);
  --muted: oklch(0.881 0.013 286.905);
  --muted-foreground: oklch(0.427 0.044 285.139);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.155 0.028 144.547);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.155 0.028 144.547);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.83 0.276 142.666);
  --primary-foreground: oklch(0.302 0.097 142.916);
  --secondary: oklch(0.449 0.288 266.889);
  --secondary-foreground: oklch(0.896 0.049 286.131);
  --accent: oklch(0.609 0.238 28.648);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.463 0.144 38.94);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.83 0.276 142.666);
  --chart-1: oklch(0.83 0.276 142.666);
  --chart-2: oklch(0.449 0.288 266.889);
  --chart-3: oklch(0.609 0.238 28.648);
  --chart-4: oklch(0.466 0.278 269.103);
  --chart-5: oklch(0.839 0.28 142.637);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.122 0.024 144.44);
  --foreground: oklch(0.993 0.001 146.047);
  --muted: oklch(0.244 0.018 285.784);
  --muted-foreground: oklch(0.69 0.039 286.095);
  --popover: oklch(0.122 0.024 144.44);
  --popover-foreground: oklch(0.993 0.001 146.047);
  --card: oklch(0.122 0.024 144.44);
  --card-foreground: oklch(0.993 0.001 146.047);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.83 0.276 142.666);
  --primary-foreground: oklch(0.302 0.097 142.916);
  --secondary: oklch(0.449 0.288 266.889);
  --secondary-foreground: oklch(0.896 0.049 286.131);
  --accent: oklch(0.609 0.238 28.648);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.673 0.198 40.038);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.83 0.276 142.666);
  --chart-1: oklch(0.83 0.276 142.666);
  --chart-2: oklch(0.449 0.288 266.889);
  --chart-3: oklch(0.609 0.238 28.648);
  --chart-4: oklch(0.466 0.278 269.103);
  --chart-5: oklch(0.839 0.28 142.637);
}