Rough for shadcn/ui

Rough is a shadcn/ui theme built around a vivid light green primary color (#d0f6a2) with neutral gray accents (#e1e2df). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid light green primary (#d0f6a2) on a green-tinted background (#080c04).

Color palette

TokenLightDark
Background
#ffffffwhite
#080c04black
Foreground
#0b1202black
#ffffffwhite
Card
#ffffffwhite
#080c04black
Card foreground
#0b1202black
#ffffffwhite
Popover
#ffffffwhite
#080c04black
Popover foreground
#0b1202black
#ffffffwhite
Primary
#d0f6a2palegoldenrod
#d0f6a2palegoldenrod
Primary foreground
#375d09darkolivegreen
#375d09darkolivegreen
Secondary
#e1e2dfgainsboro
#1a1b18black
Secondary foreground
#484c43darkslategray
#b3b6afdarkgray
Muted
#f0f5ebwhitesmoke
#10140ablack
Muted foreground
#4d5346darkslategray
#b3b9acdarkgray
Accent
#e1e2dfgainsboro
#1a1b18black
Accent foreground
#484c43darkslategray
#b3b6afdarkgray
Destructive
#951204darkred
#f9311aorangered
Destructive foreground
#fed2cdpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#d0f6a2palegoldenrod
#d0f6a2palegoldenrod

Contrast

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

Light mode
Text on background19.06:1AAA
Text on card19.06:1AAA
Primary button6.35:1AA
Secondary button6.75:1AA
Muted text7.16:1AAA
Accent6.75:1AA
Destructive6.45:1AA
Dark mode
Text on background19.76:1AAA
Text on card19.76:1AAA
Primary button6.35:1AA
Secondary button8.44:1AAA
Muted text9.26:1AAA
Accent8.44:1AAA
Destructive3.83:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.17 0.037 127.277);
  --muted: oklch(0.963 0.014 126.612);
  --muted-foreground: oklch(0.432 0.021 127.06);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.17 0.037 127.277);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.17 0.037 127.277);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.926 0.115 128.163);
  --primary-foreground: oklch(0.433 0.115 132.163);
  --secondary: oklch(0.911 0.005 126.502);
  --secondary-foreground: oklch(0.409 0.015 126.9);
  --accent: oklch(0.911 0.005 126.502);
  --accent-foreground: oklch(0.409 0.015 126.9);
  --destructive: oklch(0.429 0.165 30.63);
  --destructive-foreground: oklch(0.9 0.05 25.536);
  --ring: oklch(0.926 0.115 128.163);
  --chart-1: oklch(0.926 0.115 128.163);
  --chart-2: oklch(0.911 0.005 126.502);
  --chart-3: oklch(0.911 0.005 126.502);
  --chart-4: oklch(0.934 0.004 126.482);
  --chart-5: oklch(0.929 0.119 128.224);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.145 0.02 125.739);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.184 0.02 127.946);
  --muted-foreground: oklch(0.777 0.018 126.73);
  --popover: oklch(0.145 0.02 125.739);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.145 0.02 125.739);
  --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.926 0.115 128.163);
  --primary-foreground: oklch(0.433 0.115 132.163);
  --secondary: oklch(0.219 0.005 126.734);
  --secondary-foreground: oklch(0.772 0.011 126.618);
  --accent: oklch(0.219 0.005 126.734);
  --accent-foreground: oklch(0.772 0.011 126.618);
  --destructive: oklch(0.635 0.236 30.52);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.926 0.115 128.163);
  --chart-1: oklch(0.926 0.115 128.163);
  --chart-2: oklch(0.219 0.005 126.734);
  --chart-3: oklch(0.219 0.005 126.734);
  --chart-4: oklch(0.253 0.006 126.761);
  --chart-5: oklch(0.929 0.119 128.224);
}