Credit for shadcn/ui

Credit is a shadcn/ui theme built around a deep violet primary color (#1e0c50) with deep green accents (#3e500c). The light mode uses a neutral background (#f9f7fd). Dark mode keeps the deep violet primary (#1e0c50) on a neutral background (#040307).

Color palette

TokenLightDark
Background
#f9f7fdghostwhite
#040307black
Foreground
#020104black
#fcfcfdwhite
Card
#f9f7fdghostwhite
#040307black
Card foreground
#020104black
#fcfcfdwhite
Popover
#f9f7fdghostwhite
#040307black
Popover foreground
#020104black
#fcfcfdwhite
Primary
#1e0c50midnightblue
#1e0c50midnightblue
Primary foreground
#b49df0lightsteelblue
#b49df0lightsteelblue
Secondary
#3e500cdarkolivegreen
#3e500cdarkolivegreen
Secondary foreground
#b9e345greenyellow
#b9e345greenyellow
Muted
#e0e6d1gainsboro
#292e19darkslategray
Muted foreground
#585954dimgray
#aaaba6darkgray
Accent
#3e500cdarkolivegreen
#3e500cdarkolivegreen
Accent foreground
#b9e345greenyellow
#b9e345greenyellow
Destructive
#b63711firebrick
#ec6136tomato
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#1e0c50midnightblue
#1e0c50midnightblue

Contrast

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

Light mode
Text on background19.56:1AAA
Text on card19.56:1AAA
Primary button7.37:1AAA
Secondary button6.01:1AA
Muted text5.50:1AA
Accent6.01:1AA
Destructive5.91:1AA
Dark mode
Text on background20.03:1AAA
Text on card20.03:1AAA
Primary button7.37:1AAA
Secondary button6.01:1AA
Muted text6.06:1AA
Accent6.01:1AA
Destructive6.33:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.979 0.008 298.426);
  --foreground: oklch(0.08 0.015 298.444);
  --muted: oklch(0.914 0.028 119.107);
  --muted-foreground: oklch(0.462 0.008 118.885);
  --popover: oklch(0.979 0.008 298.426);
  --popover-foreground: oklch(0.08 0.015 298.444);
  --card: oklch(0.979 0.008 298.426);
  --card-foreground: oklch(0.08 0.015 298.444);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.236 0.114 286.085);
  --primary-foreground: oklch(0.748 0.119 295.635);
  --secondary: oklch(0.401 0.092 124.038);
  --secondary-foreground: oklch(0.858 0.185 123.384);
  --accent: oklch(0.401 0.092 124.038);
  --accent-foreground: oklch(0.858 0.185 123.384);
  --destructive: oklch(0.522 0.169 35.855);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.236 0.114 286.085);
  --chart-1: oklch(0.236 0.114 286.085);
  --chart-2: oklch(0.401 0.092 124.038);
  --chart-3: oklch(0.401 0.092 124.038);
  --chart-4: oklch(0.446 0.104 124.202);
  --chart-5: oklch(0.236 0.117 285.317);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.105 0.014 298.483);
  --foreground: oklch(0.991 0.002 298.534);
  --muted: oklch(0.29 0.036 120.852);
  --muted-foreground: oklch(0.738 0.008 118.744);
  --popover: oklch(0.105 0.014 298.483);
  --popover-foreground: oklch(0.991 0.002 298.534);
  --card: oklch(0.105 0.014 298.483);
  --card-foreground: oklch(0.991 0.002 298.534);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.236 0.114 286.085);
  --primary-foreground: oklch(0.748 0.119 295.635);
  --secondary: oklch(0.401 0.092 124.038);
  --secondary-foreground: oklch(0.858 0.185 123.384);
  --accent: oklch(0.401 0.092 124.038);
  --accent-foreground: oklch(0.858 0.185 123.384);
  --destructive: oklch(0.663 0.182 37.176);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.236 0.114 286.085);
  --chart-1: oklch(0.236 0.114 286.085);
  --chart-2: oklch(0.401 0.092 124.038);
  --chart-3: oklch(0.401 0.092 124.038);
  --chart-4: oklch(0.446 0.104 124.202);
  --chart-5: oklch(0.236 0.117 285.317);
}