University for shadcn/ui

University is a shadcn/ui theme built around a deep blue primary color (#122781) with muted light blue accents (#d1d4e0). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep blue primary (#122781) on a blue-tinted background (#03050c).

Color palette

TokenLightDark
Background
#ffffffwhite
#03050cblack
Foreground
#04050bblack
#f8f9fcghostwhite
Card
#ffffffwhite
#03050cblack
Card foreground
#04050bblack
#f8f9fcghostwhite
Popover
#ffffffwhite
#03050cblack
Popover foreground
#04050bblack
#f8f9fcghostwhite
Primary
#122781midnightblue
#122781midnightblue
Primary foreground
#ced6f8lavender
#ced6f8lavender
Secondary
#d1d4e0lightgrey
#24262ddarkslategray
Secondary foreground
#34384cdarkslategray
#bbbec9silver
Muted
#d4d8e8gainsboro
#171b2bblack
Muted foreground
#5a5d68dimgray
#979aa5darkgray
Accent
#d1d4e0lightgrey
#24262ddarkslategray
Accent foreground
#34384cdarkslategray
#bbbec9silver
Destructive
#760a04maroon
#f83a30tomato
Destructive foreground
#fcb4b0lightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#122781midnightblue
#122781midnightblue

Contrast

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

Light mode
Text on background20.35:1AAA
Text on card20.35:1AAA
Primary button8.93:1AAA
Secondary button7.83:1AAA
Muted text4.60:1AA
Accent7.83:1AAA
Destructive6.76:1AA
Dark mode
Text on background19.35:1AAA
Text on card19.35:1AAA
Primary button8.93:1AAA
Secondary button8.13:1AAA
Muted text6.09:1AA
Accent8.13:1AAA
Destructive3.73:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.118 0.017 270.381);
  --muted: oklch(0.883 0.023 275.819);
  --muted-foreground: oklch(0.479 0.018 275.644);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.118 0.017 270.381);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.118 0.017 270.381);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.328 0.153 266.808);
  --primary-foreground: oklch(0.88 0.048 275.385);
  --secondary: oklch(0.872 0.017 275.912);
  --secondary-foreground: oklch(0.345 0.035 274.603);
  --accent: oklch(0.872 0.017 275.912);
  --accent-foreground: oklch(0.345 0.035 274.603);
  --destructive: oklch(0.361 0.14 29.637);
  --destructive-foreground: oklch(0.837 0.085 22.416);
  --ring: oklch(0.328 0.153 266.808);
  --chart-1: oklch(0.328 0.153 266.808);
  --chart-2: oklch(0.872 0.017 275.912);
  --chart-3: oklch(0.872 0.017 275.912);
  --chart-4: oklch(0.898 0.013 275.972);
  --chart-5: oklch(0.327 0.158 266.438);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.116 0.02 269.12);
  --foreground: oklch(0.982 0.004 276.115);
  --muted: oklch(0.226 0.032 273.872);
  --muted-foreground: oklch(0.687 0.016 275.843);
  --popover: oklch(0.116 0.02 269.12);
  --popover-foreground: oklch(0.982 0.004 276.115);
  --card: oklch(0.116 0.02 269.12);
  --card-foreground: oklch(0.982 0.004 276.115);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.328 0.153 266.808);
  --primary-foreground: oklch(0.88 0.048 275.385);
  --secondary: oklch(0.27 0.014 275.44);
  --secondary-foreground: oklch(0.801 0.016 275.904);
  --accent: oklch(0.27 0.014 275.44);
  --accent-foreground: oklch(0.801 0.016 275.904);
  --destructive: oklch(0.641 0.226 28.467);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.328 0.153 266.808);
  --chart-1: oklch(0.328 0.153 266.808);
  --chart-2: oklch(0.27 0.014 275.44);
  --chart-3: oklch(0.27 0.014 275.44);
  --chart-4: oklch(0.299 0.016 275.405);
  --chart-5: oklch(0.327 0.158 266.438);
}