Diagnosis for shadcn/ui

Diagnosis is a shadcn/ui theme built around a vivid green primary color (#87f401) with vivid pink accents (#f40187). The light mode uses a neutral background (#fafdf7). Dark mode keeps the vivid green primary (#87f401) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#fafdf7mintcream
#000000black
Foreground
#0d1306black
#fcfdfcwhite
Card
#f8fbf3whitesmoke
#030303black
Card foreground
#0b0f05black
#ffffffwhite
Popover
#fafdf7mintcream
#000000black
Popover foreground
#0d1306black
#fcfdfcwhite
Primary
#87f401chartreuse
#87f401chartreuse
Primary foreground
#162900black
#162900black
Secondary
#0187f4dodgerblue
#0187f4dodgerblue
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#e3e9eelavender
#11181cblack
Muted foreground
#40484fdarkslategray
#b0b8bfsilver
Accent
#f40187deeppink
#f40187deeppink
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#af3a04firebrick
#fa5d14orangered
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#87f401chartreuse
#87f401chartreuse

Contrast

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

Light mode
Text on background18.34:1AAA
Text on card18.55:1AAA
Primary button11.03:1AAA
Secondary button3.65:1AA Large
Muted text7.56:1AAA
Accent4.05:1AA Large
Destructive6.13:1AA
Dark mode
Text on background20.59:1AAA
Text on card20.67:1AAA
Primary button11.03:1AAA
Secondary button3.65:1AA Large
Muted text8.94:1AAA
Accent4.05:1AA Large
Destructive6.64:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.99 0.008 126.526);
  --foreground: oklch(0.177 0.027 128.064);
  --muted: oklch(0.93 0.009 242.327);
  --muted-foreground: oklch(0.397 0.015 242.697);
  --popover: oklch(0.99 0.008 126.526);
  --popover-foreground: oklch(0.177 0.027 128.064);
  --card: oklch(0.984 0.011 126.577);
  --card-foreground: oklch(0.161 0.024 127.057);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.866 0.249 134.281);
  --primary-foreground: oklch(0.254 0.069 130.701);
  --secondary: oklch(0.621 0.189 252.697);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.627 0.255 358.416);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.512 0.162 39.175);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.866 0.249 134.281);
  --chart-1: oklch(0.866 0.249 134.281);
  --chart-2: oklch(0.621 0.189 252.697);
  --chart-3: oklch(0.627 0.255 358.416);
  --chart-4: oklch(0.645 0.193 252.255);
  --chart-5: oklch(0.875 0.254 134.482);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.993 0.001 126.443);
  --muted: oklch(0.203 0.014 243.12);
  --muted-foreground: oklch(0.779 0.013 242.409);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.993 0.001 126.443);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.866 0.249 134.281);
  --primary-foreground: oklch(0.254 0.069 130.701);
  --secondary: oklch(0.621 0.189 252.697);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.627 0.255 358.416);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.678 0.205 40.124);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.866 0.249 134.281);
  --chart-1: oklch(0.866 0.249 134.281);
  --chart-2: oklch(0.621 0.189 252.697);
  --chart-3: oklch(0.627 0.255 358.416);
  --chart-4: oklch(0.645 0.193 252.255);
  --chart-5: oklch(0.875 0.254 134.482);
}