Healthy for shadcn/ui

Healthy is a shadcn/ui theme built around a muted deep green primary color (#283f27) with muted deep green accents (#273f32). The light mode uses a neutral background (#f7fdf7). Dark mode keeps the muted deep green primary (#283f27) on a neutral background (#020802).

Color palette

TokenLightDark
Background
#f7fdf7mintcream
#020802black
Foreground
#041103black
#f8fcf8mintcream
Card
#f4fbf3whitesmoke
#030c03black
Card foreground
#030d03black
#fcfdfcwhite
Popover
#f4fbf3whitesmoke
#030c03black
Popover foreground
#030d03black
#fcfdfcwhite
Primary
#283f27darkslategray
#283f27darkslategray
Primary foreground
#c1d8c0silver
#c1d8c0silver
Secondary
#343f27darkslategray
#343f27darkslategray
Secondary foreground
#cdd8c0lightgrey
#cdd8c0lightgrey
Muted
#f2f6efwhitesmoke
#0d1009black
Muted foreground
#4a4a4adarkslategray
#b5b5b5silver
Accent
#273f32darkslategray
#273f32darkslategray
Accent foreground
#c0d8cblightgrey
#c0d8cblightgrey
Destructive
#cb3b06firebrick
#f24607orangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#283f27darkslategray
#283f27darkslategray

Contrast

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

Light mode
Text on background18.69:1AAA
Text on card18.79:1AAA
Primary button7.55:1AAA
Secondary button7.50:1AAA
Muted text8.10:1AAA
Accent7.53:1AAA
Destructive5.05:1AA
Dark mode
Text on background19.50:1AAA
Text on card19.43:1AAA
Primary button7.55:1AAA
Secondary button7.50:1AAA
Muted text9.32:1AAA
Accent7.53:1AAA
Destructive3.70:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.987 0.009 144.561);
  --foreground: oklch(0.159 0.037 142.651);
  --muted: oklch(0.968 0.01 127.244);
  --muted-foreground: oklch(0.409 0 190.305);
  --popover: oklch(0.981 0.013 144.532);
  --popover-foreground: oklch(0.142 0.032 142.632);
  --card: oklch(0.981 0.013 144.532);
  --card-foreground: oklch(0.142 0.032 142.632);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.341 0.051 143.592);
  --primary-foreground: oklch(0.859 0.042 144.299);
  --secondary: oklch(0.351 0.043 128.759);
  --secondary-foreground: oklch(0.868 0.035 127.619);
  --accent: oklch(0.344 0.038 160.211);
  --accent-foreground: oklch(0.861 0.032 162.482);
  --destructive: oklch(0.561 0.188 36.247);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.341 0.051 143.592);
  --chart-1: oklch(0.341 0.051 143.592);
  --chart-2: oklch(0.351 0.043 128.759);
  --chart-3: oklch(0.344 0.038 160.211);
  --chart-4: oklch(0.385 0.048 128.806);
  --chart-5: oklch(0.345 0.057 143.478);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.123 0.025 142.815);
  --foreground: oklch(0.987 0.006 144.58);
  --muted: oklch(0.168 0.016 128.274);
  --muted-foreground: oklch(0.773 0 180);
  --popover: oklch(0.141 0.029 142.818);
  --popover-foreground: oklch(0.993 0.003 144.599);
  --card: oklch(0.141 0.029 142.818);
  --card-foreground: oklch(0.993 0.003 144.599);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.341 0.051 143.592);
  --primary-foreground: oklch(0.859 0.042 144.299);
  --secondary: oklch(0.351 0.043 128.759);
  --secondary-foreground: oklch(0.868 0.035 127.619);
  --accent: oklch(0.344 0.038 160.211);
  --accent-foreground: oklch(0.861 0.032 162.482);
  --destructive: oklch(0.64 0.217 35.967);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.341 0.051 143.592);
  --chart-1: oklch(0.341 0.051 143.592);
  --chart-2: oklch(0.351 0.043 128.759);
  --chart-3: oklch(0.344 0.038 160.211);
  --chart-4: oklch(0.385 0.048 128.806);
  --chart-5: oklch(0.345 0.057 143.478);
}