Considerate for shadcn/ui

Considerate is a shadcn/ui theme built around a deep purple primary color (#4e2e56) with deep teal accents (#2e564e). The light mode uses a neutral background (#fbf7fc). Dark mode keeps the deep purple primary (#4e2e56) on a neutral background (#030203).

Color palette

TokenLightDark
Background
#fbf7fcghostwhite
#030203black
Foreground
#0a040cblack
#f9f5faghostwhite
Card
#faf4fbghostwhite
#060307black
Card foreground
#070208black
#fbf8fcghostwhite
Popover
#fbf7fcghostwhite
#030203black
Popover foreground
#0a040cblack
#f9f5faghostwhite
Primary
#4e2e56darkslategray
#4e2e56darkslategray
Primary foreground
#e2d1e6gainsboro
#e2d1e6gainsboro
Secondary
#564e2edarkolivegreen
#564e2edarkolivegreen
Secondary foreground
#e6e2d1gainsboro
#e6e2d1gainsboro
Muted
#dfded7gainsboro
#282620darkslategray
Muted foreground
#504d3fdarkolivegreen
#c0bdafsilver
Accent
#2e564edarkslategray
#2e564edarkslategray
Accent foreground
#d1e6e2gainsboro
#d1e6e2gainsboro
Destructive
#752500maroon
#eb4a00orangered
Destructive foreground
#ffc4a8navajowhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#4e2e56darkslategray
#4e2e56darkslategray

Contrast

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

Light mode
Text on background19.19:1AAA
Text on card18.92:1AAA
Primary button7.80:1AAA
Secondary button6.37:1AA
Muted text6.28:1AA
Accent6.28:1AA
Destructive6.76:1AA
Dark mode
Text on background19.22:1AAA
Text on card19.44:1AAA
Primary button7.80:1AAA
Secondary button6.37:1AA
Muted text8.02:1AAA
Accent6.28:1AA
Destructive3.81:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.982 0.008 319.447);
  --foreground: oklch(0.123 0.025 320.939);
  --muted: oklch(0.899 0.009 95.146);
  --muted-foreground: oklch(0.418 0.022 95.568);
  --popover: oklch(0.982 0.008 319.447);
  --popover-foreground: oklch(0.123 0.025 320.939);
  --card: oklch(0.973 0.012 319.448);
  --card-foreground: oklch(0.107 0.022 321.149);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.359 0.077 319.408);
  --primary-foreground: oklch(0.88 0.034 319.455);
  --secondary: oklch(0.424 0.049 95.779);
  --secondary-foreground: oklch(0.911 0.023 95.318);
  --accent: oklch(0.422 0.047 179.53);
  --accent-foreground: oklch(0.908 0.023 182.466);
  --destructive: oklch(0.384 0.12 40.271);
  --destructive-foreground: oklch(0.866 0.078 46.027);
  --ring: oklch(0.359 0.077 319.408);
  --chart-1: oklch(0.359 0.077 319.408);
  --chart-2: oklch(0.424 0.049 95.779);
  --chart-3: oklch(0.422 0.047 179.53);
  --chart-4: oklch(0.457 0.054 95.775);
  --chart-5: oklch(0.358 0.084 319.38);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.087 0.012 320.593);
  --foreground: oklch(0.974 0.009 319.447);
  --muted: oklch(0.268 0.012 95.481);
  --muted-foreground: oklch(0.796 0.019 95.304);
  --popover: oklch(0.087 0.012 320.593);
  --popover-foreground: oklch(0.974 0.009 319.447);
  --card: oklch(0.11 0.015 320.593);
  --card-foreground: oklch(0.983 0.006 319.446);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.359 0.077 319.408);
  --primary-foreground: oklch(0.88 0.034 319.455);
  --secondary: oklch(0.424 0.049 95.779);
  --secondary-foreground: oklch(0.911 0.023 95.318);
  --accent: oklch(0.422 0.047 179.53);
  --accent-foreground: oklch(0.908 0.023 182.466);
  --destructive: oklch(0.631 0.207 37.987);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.359 0.077 319.408);
  --chart-1: oklch(0.359 0.077 319.408);
  --chart-2: oklch(0.424 0.049 95.779);
  --chart-3: oklch(0.422 0.047 179.53);
  --chart-4: oklch(0.457 0.054 95.775);
  --chart-5: oklch(0.358 0.084 319.38);
}