Major for shadcn/ui

Major is a shadcn/ui theme built around a near-white primary color (#ffffff) with neutral gray accents (#ccc7c7). The light mode uses a neutral background (#fdfcfc). Dark mode keeps the near-white primary (#ffffff) on a red-tinted background (#100505).

Color palette

TokenLightDark
Background
#fdfcfcsnow
#100505black
Foreground
#080202black
#fdfcfcsnow
Card
#fdfcfcsnow
#100505black
Card foreground
#080202black
#fdfcfcsnow
Popover
#fdfcfcsnow
#100505black
Popover foreground
#080202black
#fdfcfcsnow
Primary
#ffffffwhite
#ffffffwhite
Primary foreground
#333333darkslategray
#333333darkslategray
Secondary
#dbdbdbgainsboro
#322f2fdarkslategray
Secondary foreground
#424242darkslategray
#cbc8c8silver
Muted
#dfd3d3lightgrey
#2c2020black
Muted foreground
#6c5151dimgray
#ae9393rosybrown
Accent
#ccc7c7silver
#493c3cdarkslategray
Accent foreground
#332e2edarkslategray
#dfd8d8gainsboro
Destructive
#8a210adarkred
#ef451forangered
Destructive foreground
#fbd3cbbisque
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#ffffffwhite
#ffffffwhite

Contrast

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

Light mode
Text on background20.05:1AAA
Text on card20.05:1AAA
Primary button12.63:1AAA
Secondary button7.27:1AAA
Muted text4.89:1AA
Accent7.98:1AAA
Destructive6.61:1AA
Dark mode
Text on background19.63:1AAA
Text on card19.63:1AAA
Primary button12.63:1AAA
Secondary button7.98:1AAA
Muted text5.52:1AA
Accent7.52:1AAA
Destructive3.77:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.991 0.002 17.192);
  --foreground: oklch(0.103 0.019 20.998);
  --muted: oklch(0.876 0.014 17.416);
  --muted-foreground: oklch(0.463 0.036 18.52);
  --popover: oklch(0.991 0.002 17.192);
  --popover-foreground: oklch(0.103 0.019 20.998);
  --card: oklch(0.991 0.002 17.192);
  --card-foreground: oklch(0.103 0.019 20.998);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(1 0 180);
  --primary-foreground: oklch(0.321 0 180);
  --secondary: oklch(0.892 0 180);
  --secondary-foreground: oklch(0.38 0 180);
  --accent: oklch(0.833 0.006 17.277);
  --accent-foreground: oklch(0.306 0.007 17.542);
  --destructive: oklch(0.42 0.144 33.463);
  --destructive-foreground: oklch(0.9 0.047 32.767);
  --ring: oklch(1 0 180);
  --chart-1: oklch(1 0 180);
  --chart-2: oklch(0.892 0 180);
  --chart-3: oklch(0.833 0.006 17.277);
  --chart-4: oklch(0.916 0 180);
  --chart-5: oklch(1 0 180);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.133 0.022 20.498);
  --foreground: oklch(0.992 0.001 17.174);
  --muted: oklch(0.259 0.019 18.457);
  --muted-foreground: oklch(0.689 0.032 17.949);
  --popover: oklch(0.133 0.022 20.498);
  --popover-foreground: oklch(0.992 0.001 17.174);
  --card: oklch(0.133 0.022 20.498);
  --card-foreground: oklch(0.992 0.001 17.174);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(1 0 180);
  --primary-foreground: oklch(0.321 0 180);
  --secondary: oklch(0.308 0.004 17.383);
  --secondary-foreground: oklch(0.835 0.004 17.229);
  --accent: oklch(0.369 0.019 18.03);
  --accent-foreground: oklch(0.887 0.008 17.304);
  --destructive: oklch(0.635 0.212 33.67);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(1 0 180);
  --chart-1: oklch(1 0 180);
  --chart-2: oklch(0.308 0.004 17.383);
  --chart-3: oklch(0.369 0.019 18.03);
  --chart-4: oklch(0.338 0.005 17.391);
  --chart-5: oklch(1 0 180);
}