Complex for shadcn/ui

Complex is a shadcn/ui theme built around a near-white primary color (#fcfcfd) with near-white accents (#fdfcfd). The light mode uses a neutral background (#fcfbfe). Dark mode keeps the near-white primary (#fcfcfd) on a violet-tinted background (#09070e).

Color palette

TokenLightDark
Background
#fcfbfewhite
#09070eblack
Foreground
#0a0415black
#f9f8fcghostwhite
Card
#f9f6fdghostwhite
#0b0911black
Card foreground
#080311black
#fcfcfdwhite
Popover
#f9f6fdghostwhite
#0b0911black
Popover foreground
#080311black
#fcfcfdwhite
Primary
#fcfcfdwhite
#fcfcfdwhite
Primary foreground
#5c4c7bdarkslateblue
#5c4c7bdarkslateblue
Secondary
#fcfcfdwhite
#fcfcfdwhite
Secondary foreground
#4c537bdarkslateblue
#4c537bdarkslateblue
Muted
#dbdde6gainsboro
#191b24black
Muted foreground
#4e5165dimgray
#9a9eb1darkgray
Accent
#fdfcfdwhite
#fdfcfdwhite
Accent foreground
#744c7bdimgray
#744c7bdimgray
Destructive
#690702maroon
#fa160ared
Destructive foreground
#fda5a0lightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#fcfcfdwhite
#fcfcfdwhite

Contrast

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

Light mode
Text on background19.53:1AAA
Text on card19.08:1AAA
Primary button7.37:1AAA
Secondary button7.23:1AAA
Muted text5.74:1AA
Accent6.69:1AA
Destructive6.77:1AA
Dark mode
Text on background18.95:1AAA
Text on card19.32:1AAA
Primary button7.37:1AAA
Secondary button7.23:1AAA
Muted text6.46:1AA
Accent6.69:1AA
Destructive4.05:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.989 0.005 302.138);
  --foreground: oklch(0.133 0.039 299.479);
  --muted: oklch(0.898 0.013 278.108);
  --muted-foreground: oklch(0.44 0.033 277.126);
  --popover: oklch(0.978 0.01 302.061);
  --popover-foreground: oklch(0.123 0.035 301.256);
  --card: oklch(0.978 0.01 302.061);
  --card-foreground: oklch(0.123 0.035 301.256);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.991 0.002 302.187);
  --primary-foreground: oklch(0.453 0.078 299.37);
  --secondary: oklch(0.991 0.001 278.297);
  --secondary-foreground: oklch(0.453 0.067 275.731);
  --accent: oklch(0.992 0.002 321.069);
  --accent-foreground: oklch(0.479 0.089 321.398);
  --destructive: oklch(0.332 0.13 29.987);
  --destructive-foreground: oklch(0.807 0.106 22.959);
  --ring: oklch(0.991 0.002 302.187);
  --chart-1: oklch(0.991 0.002 302.187);
  --chart-2: oklch(0.991 0.001 278.297);
  --chart-3: oklch(0.992 0.002 321.069);
  --chart-4: oklch(1.017 0.003 98.356);
  --chart-5: oklch(0.991 0.002 302.183);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.135 0.016 301.707);
  --foreground: oklch(0.982 0.005 302.14);
  --muted: oklch(0.224 0.018 276.984);
  --muted-foreground: oklch(0.702 0.029 277.686);
  --popover: oklch(0.146 0.019 300.4);
  --popover-foreground: oklch(0.991 0.002 302.177);
  --card: oklch(0.146 0.019 300.4);
  --card-foreground: oklch(0.991 0.002 302.177);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.991 0.002 302.187);
  --primary-foreground: oklch(0.453 0.078 299.37);
  --secondary: oklch(0.991 0.001 278.297);
  --secondary-foreground: oklch(0.453 0.067 275.731);
  --accent: oklch(0.992 0.002 321.069);
  --accent-foreground: oklch(0.479 0.089 321.398);
  --destructive: oklch(0.624 0.249 29.504);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.991 0.002 302.187);
  --chart-1: oklch(0.991 0.002 302.187);
  --chart-2: oklch(0.991 0.001 278.297);
  --chart-3: oklch(0.992 0.002 321.069);
  --chart-4: oklch(1.017 0.003 98.356);
  --chart-5: oklch(0.991 0.002 302.183);
}