Forebear for shadcn/ui

Forebear is a shadcn/ui theme built around a vivid deep teal primary color (#021717) with vivid deep red accents (#170202). The light mode uses a neutral background (#f8fcfc). Dark mode keeps the vivid deep teal primary (#021717) on a teal-tinted background (#051010).

Color palette

TokenLightDark
Background
#f8fcfcmintcream
#051010black
Foreground
#010404black
#fcfdfdwhite
Card
#f8fcfcmintcream
#051010black
Card foreground
#010404black
#fcfdfdwhite
Popover
#f8fcfcmintcream
#051010black
Popover foreground
#010404black
#fcfdfdwhite
Primary
#021717black
#021717black
Primary foreground
#12d3d3darkturquoise
#12d3d3darkturquoise
Secondary
#170202black
#170202black
Secondary foreground
#f15b5btomato
#f15b5btomato
Muted
#f2e3e3mistyrose
#1c0d0dblack
Muted foreground
#645e5edimgray
#a19b9bdarkgray
Accent
#170202black
#170202black
Accent foreground
#f15b5btomato
#f15b5btomato
Destructive
#9e2510firebrick
#e83617orangered
Destructive foreground
#fce7e3mistyrose
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#021717black
#021717black

Contrast

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

Light mode
Text on background19.93:1AAA
Text on card19.93:1AAA
Primary button9.88:1AAA
Secondary button6.09:1AA
Muted text5.10:1AA
Accent6.09:1AA
Destructive6.49:1AA
Dark mode
Text on background18.97:1AAA
Text on card18.97:1AAA
Primary button9.88:1AAA
Secondary button6.09:1AA
Muted text6.90:1AA
Accent6.09:1AA
Destructive4.21:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.988 0.005 197.077);
  --foreground: oklch(0.099 0.01 195.637);
  --muted: oklch(0.928 0.017 17.463);
  --muted-foreground: oklch(0.487 0.007 17.413);
  --popover: oklch(0.988 0.005 197.077);
  --popover-foreground: oklch(0.099 0.01 195.637);
  --card: oklch(0.988 0.005 197.077);
  --card-foreground: oklch(0.099 0.01 195.637);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.189 0.029 194.973);
  --primary-foreground: oklch(0.786 0.132 194.797);
  --secondary: oklch(0.139 0.045 25.201);
  --secondary-foreground: oklch(0.667 0.185 23.567);
  --accent: oklch(0.139 0.045 25.201);
  --accent-foreground: oklch(0.667 0.185 23.567);
  --destructive: oklch(0.46 0.16 32.241);
  --destructive-foreground: oklch(0.944 0.024 29.574);
  --ring: oklch(0.189 0.029 194.973);
  --chart-1: oklch(0.189 0.029 194.973);
  --chart-2: oklch(0.139 0.045 25.201);
  --chart-3: oklch(0.139 0.045 25.201);
  --chart-4: oklch(0.176 0.06 25.984);
  --chart-5: oklch(0.19 0.03 194.932);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.16 0.018 195.549);
  --foreground: oklch(0.994 0.002 197.13);
  --muted: oklch(0.18 0.027 20.043);
  --muted-foreground: oklch(0.695 0.007 17.32);
  --popover: oklch(0.16 0.018 195.549);
  --popover-foreground: oklch(0.994 0.002 197.13);
  --card: oklch(0.16 0.018 195.549);
  --card-foreground: oklch(0.994 0.002 197.13);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.189 0.029 194.973);
  --primary-foreground: oklch(0.786 0.132 194.797);
  --secondary: oklch(0.139 0.045 25.201);
  --secondary-foreground: oklch(0.667 0.185 23.567);
  --accent: oklch(0.139 0.045 25.201);
  --accent-foreground: oklch(0.667 0.185 23.567);
  --destructive: oklch(0.609 0.217 32.116);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.189 0.029 194.973);
  --chart-1: oklch(0.189 0.029 194.973);
  --chart-2: oklch(0.139 0.045 25.201);
  --chart-3: oklch(0.139 0.045 25.201);
  --chart-4: oklch(0.176 0.06 25.984);
  --chart-5: oklch(0.19 0.03 194.932);
}