Retina for shadcn/ui

Retina is a shadcn/ui theme built around a deep green primary color (#31421f) with deep pink accents (#421f31). The light mode uses a neutral background (#fcfefb). Dark mode keeps the deep green primary (#31421f) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#fcfefbwhite
#000000black
Foreground
#030401black
#ffffffwhite
Card
#fcfefbwhite
#000000black
Card foreground
#030401black
#ffffffwhite
Popover
#fcfefbwhite
#000000black
Popover foreground
#030401black
#ffffffwhite
Primary
#31421fdarkslategray
#31421fdarkslategray
Primary foreground
#caddb6lightgrey
#caddb6lightgrey
Secondary
#1f3142darkslategray
#1f3142darkslategray
Secondary foreground
#b6caddlightsteelblue
#b6caddlightsteelblue
Muted
#dde6eelavender
#111a22black
Muted foreground
#3e4246darkslategray
#b9bdc1silver
Accent
#421f31darkslategray
#421f31darkslategray
Accent foreground
#ddb6cathistle
#ddb6cathistle
Destructive
#c42a12firebrick
#ec4f36tomato
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#31421fdarkslategray
#31421fdarkslategray

Contrast

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

Light mode
Text on background20.23:1AAA
Text on card20.23:1AAA
Primary button7.49:1AAA
Secondary button7.91:1AAA
Muted text8.01:1AAA
Accent7.90:1AAA
Destructive5.69:1AA
Dark mode
Text on background21.00:1AAA
Text on card21.00:1AAA
Primary button7.49:1AAA
Secondary button7.91:1AAA
Muted text9.31:1AAA
Accent7.90:1AAA
Destructive3.65:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.994 0.003 127.825);
  --foreground: oklch(0.103 0.021 126.396);
  --muted: oklch(0.92 0.014 246.142);
  --muted-foreground: oklch(0.378 0.009 246.225);
  --popover: oklch(0.994 0.003 127.825);
  --popover-foreground: oklch(0.103 0.021 126.396);
  --card: oklch(0.994 0.003 127.825);
  --card-foreground: oklch(0.103 0.021 126.396);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.356 0.061 130.195);
  --primary-foreground: oklch(0.874 0.057 128.579);
  --secondary: oklch(0.306 0.04 247.621);
  --secondary-foreground: oklch(0.83 0.035 246.445);
  --accent: oklch(0.294 0.061 349.245);
  --accent-foreground: oklch(0.816 0.053 345.873);
  --destructive: oklch(0.535 0.193 31.553);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.356 0.061 130.195);
  --chart-1: oklch(0.356 0.061 130.195);
  --chart-2: oklch(0.306 0.04 247.621);
  --chart-3: oklch(0.294 0.061 349.245);
  --chart-4: oklch(0.335 0.045 247.687);
  --chart-5: oklch(0.36 0.066 130.39);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.212 0.02 247.085);
  --muted-foreground: oklch(0.796 0.007 246.07);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0 0 0);
  --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.356 0.061 130.195);
  --primary-foreground: oklch(0.874 0.057 128.579);
  --secondary: oklch(0.306 0.04 247.621);
  --secondary-foreground: oklch(0.83 0.035 246.445);
  --accent: oklch(0.294 0.061 349.245);
  --accent-foreground: oklch(0.816 0.053 345.873);
  --destructive: oklch(0.642 0.198 31.511);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.356 0.061 130.195);
  --chart-1: oklch(0.356 0.061 130.195);
  --chart-2: oklch(0.306 0.04 247.621);
  --chart-3: oklch(0.294 0.061 349.245);
  --chart-4: oklch(0.335 0.045 247.687);
  --chart-5: oklch(0.36 0.066 130.39);
}