Early for shadcn/ui

Early is a shadcn/ui theme built around a deep indigo primary color (#1d1744) with deep violet accents (#331744). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep indigo primary (#1d1744) on a neutral background (#030307).

Color palette

TokenLightDark
Background
#ffffffwhite
#030307black
Foreground
#030208black
#ffffffwhite
Card
#ffffffwhite
#030307black
Card foreground
#030208black
#ffffffwhite
Popover
#ffffffwhite
#030307black
Popover foreground
#030208black
#ffffffwhite
Primary
#1d1744midnightblue
#1d1744midnightblue
Primary foreground
#b2abe2lightsteelblue
#b2abe2lightsteelblue
Secondary
#172944darkslategray
#172944darkslategray
Secondary foreground
#abc0e2lightsteelblue
#abc0e2lightsteelblue
Muted
#dadbddgainsboro
#222325black
Muted foreground
#46494edarkslategray
#b1b4b9silver
Accent
#331744midnightblue
#331744midnightblue
Accent foreground
#cdabe2plum
#cdabe2plum
Destructive
#640202maroon
#fa1414red
Destructive foreground
#fd9b9blightsalmon
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#1d1744midnightblue
#1d1744midnightblue

Contrast

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

Light mode
Text on background20.66:1AAA
Text on card20.66:1AAA
Primary button7.78:1AAA
Secondary button7.92:1AAA
Muted text6.51:1AA
Accent7.78:1AAA
Destructive6.66:1AA
Dark mode
Text on background20.60:1AAA
Text on card20.60:1AAA
Primary button7.78:1AAA
Secondary button7.92:1AAA
Muted text7.54:1AAA
Accent7.78:1AAA
Destructive4.05:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.096 0.022 289.261);
  --muted: oklch(0.891 0.003 259.938);
  --muted-foreground: oklch(0.405 0.008 259.946);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.096 0.022 289.261);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.096 0.022 289.261);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.243 0.081 283.811);
  --primary-foreground: oklch(0.767 0.078 289.767);
  --secondary: oklch(0.28 0.056 259.52);
  --secondary-foreground: oklch(0.805 0.053 259.885);
  --accent: oklch(0.27 0.085 310.402);
  --accent-foreground: oklch(0.791 0.085 312.256);
  --destructive: oklch(0.318 0.128 28.845);
  --destructive-foreground: oklch(0.79 0.118 20.032);
  --ring: oklch(0.243 0.081 283.811);
  --chart-1: oklch(0.243 0.081 283.811);
  --chart-2: oklch(0.28 0.056 259.52);
  --chart-3: oklch(0.27 0.085 310.402);
  --chart-4: oklch(0.308 0.064 259.509);
  --chart-5: oklch(0.24 0.086 283.089);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.1 0.017 289.944);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.257 0.005 259.946);
  --muted-foreground: oklch(0.77 0.007 259.943);
  --popover: oklch(0.1 0.017 289.944);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.1 0.017 289.944);
  --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.243 0.081 283.811);
  --primary-foreground: oklch(0.767 0.078 289.767);
  --secondary: oklch(0.28 0.056 259.52);
  --secondary-foreground: oklch(0.805 0.053 259.885);
  --accent: oklch(0.27 0.085 310.402);
  --accent-foreground: oklch(0.791 0.085 312.256);
  --destructive: oklch(0.624 0.249 28.654);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.243 0.081 283.811);
  --chart-1: oklch(0.243 0.081 283.811);
  --chart-2: oklch(0.28 0.056 259.52);
  --chart-3: oklch(0.27 0.085 310.402);
  --chart-4: oklch(0.308 0.064 259.509);
  --chart-5: oklch(0.24 0.086 283.089);
}