Slight for shadcn/ui

Slight is a shadcn/ui theme built around a muted blue primary color (#aab1ca) with muted violet accents (#b3aaca). The light mode uses a neutral background (#fbfcfe). Dark mode keeps the muted blue primary (#aab1ca) on a blue-tinted background (#040710).

Color palette

TokenLightDark
Background
#fbfcfewhite
#040710black
Foreground
#030716black
#fcfcfdwhite
Card
#f7f8fdghostwhite
#060914black
Card foreground
#030612black
#ffffffwhite
Popover
#fbfcfewhite
#040710black
Popover foreground
#030716black
#fcfcfdwhite
Primary
#aab1calightsteelblue
#aab1calightsteelblue
Primary foreground
#1a1d29black
#1a1d29black
Secondary
#aac1calightsteelblue
#aac1calightsteelblue
Secondary foreground
#1a2429black
#1a2429black
Muted
#d5e2e7gainsboro
#18252adarkslategray
Muted foreground
#424d52darkslategray
#adb9bdsilver
Accent
#b3aacasilver
#b3aacasilver
Accent foreground
#1e1a29black
#1e1a29black
Destructive
#881f02darkred
#fc4d1dorangered
Destructive foreground
#feccbepeachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#aab1calightsteelblue
#aab1calightsteelblue

Contrast

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

Light mode
Text on background19.49:1AAA
Text on card19.05:1AAA
Primary button7.88:1AAA
Secondary button8.43:1AAA
Muted text6.55:1AA
Accent7.73:1AAA
Destructive6.52:1AA
Dark mode
Text on background19.62:1AAA
Text on card19.90:1AAA
Primary button7.88:1AAA
Secondary button8.43:1AAA
Muted text7.81:1AAA
Accent7.73:1AAA
Destructive3.38:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.99 0.003 273.826);
  --foreground: oklch(0.135 0.035 265.552);
  --muted: oklch(0.904 0.015 223.312);
  --muted-foreground: oklch(0.413 0.017 223.628);
  --popover: oklch(0.99 0.003 273.826);
  --popover-foreground: oklch(0.135 0.035 265.552);
  --card: oklch(0.98 0.007 273.784);
  --card-foreground: oklch(0.124 0.03 264.553);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.764 0.036 273.272);
  --primary-foreground: oklch(0.232 0.024 272.46);
  --secondary: oklch(0.797 0.028 223.544);
  --secondary-foreground: oklch(0.254 0.017 224.134);
  --accent: oklch(0.757 0.046 298.257);
  --accent-foreground: oklch(0.228 0.03 296.999);
  --destructive: oklch(0.412 0.144 34.569);
  --destructive-foreground: oklch(0.884 0.061 35.972);
  --ring: oklch(0.764 0.036 273.272);
  --chart-1: oklch(0.764 0.036 273.272);
  --chart-2: oklch(0.797 0.028 223.544);
  --chart-3: oklch(0.757 0.046 298.257);
  --chart-4: oklch(0.82 0.025 223.476);
  --chart-5: oklch(0.76 0.041 273.181);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.13 0.022 267.781);
  --foreground: oklch(0.992 0.001 273.853);
  --muted: oklch(0.255 0.02 224.375);
  --muted-foreground: oklch(0.777 0.015 223.332);
  --popover: oklch(0.13 0.022 267.781);
  --popover-foreground: oklch(0.992 0.001 273.853);
  --card: oklch(0.141 0.026 268.834);
  --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.764 0.036 273.272);
  --primary-foreground: oklch(0.232 0.024 272.46);
  --secondary: oklch(0.797 0.028 223.544);
  --secondary-foreground: oklch(0.254 0.017 224.134);
  --accent: oklch(0.757 0.046 298.257);
  --accent-foreground: oklch(0.228 0.03 296.999);
  --destructive: oklch(0.663 0.218 35.07);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.764 0.036 273.272);
  --chart-1: oklch(0.764 0.036 273.272);
  --chart-2: oklch(0.797 0.028 223.544);
  --chart-3: oklch(0.757 0.046 298.257);
  --chart-4: oklch(0.82 0.025 223.476);
  --chart-5: oklch(0.76 0.041 273.181);
}