Virtue is a shadcn/ui theme built around a deep orange primary color (#0e0806) with near-white accents (#e9e8e8). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep orange primary (#0e0806) on a neutral background (#070403).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #070403black |
| Foreground | #0c0604black | #fbf9f9snow |
| Card | #fcfcfcsnow | #0b0605black |
| Card foreground | #080402black | #fdfcfcsnow |
| Popover | #fcfcfcsnow | #0b0605black |
| Popover foreground | #080402black | #fdfcfcsnow |
| Primary | #0e0806black | #0e0806black |
| Primary foreground | #c59281rosybrown | #c59281rosybrown |
| Secondary | #e9e8e8lavender | #161413black |
| Secondary foreground | #514e4ddarkslategray | #b2aba9darkgray |
| Muted | #e6dedbgainsboro | #241c19black |
| Muted foreground | #5c5451dimgray | #aea6a3darkgray |
| Accent | #e9e8e8lavender | #161413black |
| Accent foreground | #514e4ddarkslategray | #b2aba9darkgray |
| Destructive | #90330esaddlebrown | #ec7141tomato |
| Destructive foreground | #fbe0d5antiquewhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #0e0806black | #0e0806black |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.12:1 | AAA |
| Text on card | 19.97:1 | AAA |
| Primary button | 7.37:1 | AAA |
| Secondary button | 6.72:1 | AA |
| Muted text | 5.56:1 | AA |
| Accent | 6.72:1 | AA |
| Destructive | 6.28:1 | AA |
| Text on background | 19.46:1 | AAA |
| Text on card | 19.66:1 | AAA |
| Primary button | 7.37:1 | AAA |
| Secondary button | 8.14:1 | AAA |
| Muted text | 6.99:1 | AA |
| Accent | 8.14:1 | AAA |
| Destructive | 7.02:1 | AAA |
Paste this into your globals.css to use Virtue in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.129 0.014 45.881);
--muted: oklch(0.905 0.009 39.443);
--muted-foreground: oklch(0.453 0.011 39.371);
--popover: oklch(0.992 0 161.565);
--popover-foreground: oklch(0.112 0.012 46.096);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0.112 0.012 46.096);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.143 0.011 42.506);
--primary-foreground: oklch(0.705 0.067 39.219);
--secondary: oklch(0.931 0.001 39.502);
--secondary-foreground: oklch(0.427 0.003 39.457);
--accent: oklch(0.931 0.001 39.502);
--accent-foreground: oklch(0.427 0.003 39.457);
--destructive: oklch(0.451 0.134 39.161);
--destructive-foreground: oklch(0.926 0.033 42.847);
--ring: oklch(0.143 0.011 42.506);
--chart-1: oklch(0.143 0.011 42.506);
--chart-2: oklch(0.931 0.001 39.502);
--chart-3: oklch(0.931 0.001 39.502);
--chart-4: oklch(0.954 0.001 39.504);
--chart-5: oklch(0.143 0.012 42.834);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.113 0.009 44.12);
--foreground: oklch(0.984 0.002 39.496);
--muted: oklch(0.235 0.013 39.27);
--muted-foreground: oklch(0.73 0.01 39.426);
--popover: oklch(0.13 0.01 44.094);
--popover-foreground: oklch(0.992 0.001 39.502);
--card: oklch(0.13 0.01 44.094);
--card-foreground: oklch(0.992 0.001 39.502);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.143 0.011 42.506);
--primary-foreground: oklch(0.705 0.067 39.219);
--secondary: oklch(0.192 0.003 39.408);
--secondary-foreground: oklch(0.746 0.009 39.432);
--accent: oklch(0.192 0.003 39.408);
--accent-foreground: oklch(0.746 0.009 39.432);
--destructive: oklch(0.687 0.165 41.138);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.143 0.011 42.506);
--chart-1: oklch(0.143 0.011 42.506);
--chart-2: oklch(0.192 0.003 39.408);
--chart-3: oklch(0.192 0.003 39.408);
--chart-4: oklch(0.226 0.004 39.397);
--chart-5: oklch(0.143 0.012 42.834);
}