Windshield for shadcn/ui

Windshield is a shadcn/ui theme built around a vivid deep green primary color (#373c06) with vivid deep green accents (#1c3c06). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid deep green primary (#373c06) on a green-tinted background (#0b0c04).

Color palette

TokenLightDark
Background
#ffffffwhite
#0b0c04black
Foreground
#000000black
#fafaf9snow
Card
#fcfcfcsnow
#0e1005black
Card foreground
#000000black
#fdfdfcwhite
Popover
#fcfcfcsnow
#0e1005black
Popover foreground
#000000black
#fdfdfcwhite
Primary
#373c06darkgreen
#373c06darkgreen
Primary foreground
#d5e826greenyellow
#d5e826greenyellow
Secondary
#3c2706black
#3c2706black
Secondary foreground
#e89b26goldenrod
#e89b26goldenrod
Muted
#f3f0eclinen
#13100cblack
Muted foreground
#4a443adarkslategray
#c5beb5silver
Accent
#1c3c06darkgreen
#1c3c06darkgreen
Accent foreground
#74e826lawngreen
#74e826lawngreen
Destructive
#7d130dmaroon
#ec4f46tomato
Destructive foreground
#f9c6c3pink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#373c06darkgreen
#373c06darkgreen

Contrast

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

Light mode
Text on background21.00:1AAA
Text on card20.54:1AAA
Primary button8.51:1AAA
Secondary button6.18:1AA
Muted text8.50:1AAA
Accent7.84:1AAA
Destructive7.07:1AAA
Dark mode
Text on background18.85:1AAA
Text on card18.88:1AAA
Primary button8.51:1AAA
Secondary button6.18:1AA
Muted text10.30:1AAA
Accent7.84:1AAA
Destructive3.65:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.957 0.006 78.291);
  --muted-foreground: oklch(0.39 0.018 78.072);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.34 0.072 115.449);
  --primary-foreground: oklch(0.887 0.195 115.842);
  --secondary: oklch(0.291 0.055 72.891);
  --secondary-foreground: oklch(0.748 0.151 70.862);
  --accent: oklch(0.319 0.088 135.977);
  --accent-foreground: oklch(0.831 0.239 136.677);
  --destructive: oklch(0.381 0.141 28.942);
  --destructive-foreground: oklch(0.87 0.059 21.847);
  --ring: oklch(0.34 0.072 115.449);
  --chart-1: oklch(0.34 0.072 115.449);
  --chart-2: oklch(0.291 0.055 72.891);
  --chart-3: oklch(0.319 0.088 135.977);
  --chart-4: oklch(0.331 0.065 71.995);
  --chart-5: oklch(0.343 0.074 115.543);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.148 0.019 112.523);
  --foreground: oklch(0.986 0.001 111.042);
  --muted: oklch(0.175 0.01 77.991);
  --muted-foreground: oklch(0.805 0.015 78.243);
  --popover: oklch(0.166 0.022 113.075);
  --popover-foreground: oklch(0.993 0.001 111.028);
  --card: oklch(0.166 0.022 113.075);
  --card-foreground: oklch(0.993 0.001 111.028);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.34 0.072 115.449);
  --primary-foreground: oklch(0.887 0.195 115.842);
  --secondary: oklch(0.291 0.055 72.891);
  --secondary-foreground: oklch(0.748 0.151 70.862);
  --accent: oklch(0.319 0.088 135.977);
  --accent-foreground: oklch(0.831 0.239 136.677);
  --destructive: oklch(0.642 0.195 27.05);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.34 0.072 115.449);
  --chart-1: oklch(0.34 0.072 115.449);
  --chart-2: oklch(0.291 0.055 72.891);
  --chart-3: oklch(0.319 0.088 135.977);
  --chart-4: oklch(0.331 0.065 71.995);
  --chart-5: oklch(0.343 0.074 115.543);
}