Max for shadcn/ui

Max is a shadcn/ui theme built around a vivid purple primary color (#a60ca1) with vivid pink accents (#a60c54). The light mode uses a neutral background (#fefbfe). Dark mode keeps the vivid purple primary (#a60ca1) on a purple-tinted background (#0b040b).

Color palette

TokenLightDark
Background
#fefbfewhite
#0b040bblack
Foreground
#150415black
#f9f6f9whitesmoke
Card
#fefbfewhite
#0b040bblack
Card foreground
#150415black
#f9f6f9whitesmoke
Popover
#fefbfewhite
#0b040bblack
Popover foreground
#150415black
#f9f6f9whitesmoke
Primary
#a60ca1darkmagenta
#a60ca1darkmagenta
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#5e0ca6rebeccapurple
#5e0ca6rebeccapurple
Secondary foreground
#f3e7fdlavender
#f3e7fdlavender
Muted
#dac9e8thistle
#271736midnightblue
Muted foreground
#4a4351darkslategray
#b6aebcsilver
Accent
#a60c54brown
#a60c54brown
Accent foreground
#fde7f2lavenderblush
#fde7f2lavenderblush
Destructive
#b84e14sienna
#eb8147coral
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#a60ca1darkmagenta
#a60ca1darkmagenta

Contrast

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

Light mode
Text on background19.27:1AAA
Text on card19.27:1AAA
Primary button6.58:1AA
Secondary button8.46:1AAA
Muted text6.11:1AA
Accent6.37:1AA
Destructive5.10:1AA
Dark mode
Text on background18.87:1AAA
Text on card18.87:1AAA
Primary button6.58:1AA
Secondary button8.46:1AAA
Muted text7.74:1AAA
Accent6.37:1AA
Destructive7.72:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.991 0.005 326.583);
  --foreground: oklch(0.151 0.046 328.77);
  --muted: oklch(0.86 0.045 309.265);
  --muted-foreground: oklch(0.395 0.027 309.12);
  --popover: oklch(0.991 0.005 326.583);
  --popover-foreground: oklch(0.151 0.046 328.77);
  --card: oklch(0.991 0.005 326.583);
  --card-foreground: oklch(0.151 0.046 328.77);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.509 0.226 329.985);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.407 0.209 299.809);
  --secondary-foreground: oklch(0.944 0.032 309.453);
  --accent: oklch(0.473 0.185 1.656);
  --accent-foreground: oklch(0.949 0.027 347.667);
  --destructive: oklch(0.553 0.152 43.818);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.509 0.226 329.985);
  --chart-1: oklch(0.509 0.226 329.985);
  --chart-2: oklch(0.407 0.209 299.809);
  --chart-3: oklch(0.473 0.185 1.656);
  --chart-4: oklch(0.431 0.222 299.644);
  --chart-5: oklch(0.514 0.23 330.027);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.126 0.023 327.8);
  --foreground: oklch(0.976 0.006 326.59);
  --muted: oklch(0.242 0.06 307.122);
  --muted-foreground: oklch(0.761 0.023 309.491);
  --popover: oklch(0.126 0.023 327.8);
  --popover-foreground: oklch(0.976 0.006 326.59);
  --card: oklch(0.126 0.023 327.8);
  --card-foreground: oklch(0.976 0.006 326.59);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.509 0.226 329.985);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.407 0.209 299.809);
  --secondary-foreground: oklch(0.944 0.032 309.453);
  --accent: oklch(0.473 0.185 1.656);
  --accent-foreground: oklch(0.949 0.027 347.667);
  --destructive: oklch(0.709 0.149 47.221);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.509 0.226 329.985);
  --chart-1: oklch(0.509 0.226 329.985);
  --chart-2: oklch(0.407 0.209 299.809);
  --chart-3: oklch(0.473 0.185 1.656);
  --chart-4: oklch(0.431 0.222 299.644);
  --chart-5: oklch(0.514 0.23 330.027);
}