Best is a shadcn/ui theme built around a near-black primary color (#191a1a) with near-black accents (#1a1a19). The light mode uses a neutral background (#f8fafc). Dark mode keeps the near-black primary (#191a1a) on a blue-tinted background (#060b0e).
| Token | Light | Dark |
|---|---|---|
| Background | #f8fafcghostwhite | #060b0eblack |
| Foreground | #010304black | #f8fafcghostwhite |
| Card | #f4f8fawhitesmoke | #080d12black |
| Card foreground | #000000black | #fcfdfdwhite |
| Popover | #f8fafcghostwhite | #060b0eblack |
| Popover foreground | #010304black | #f8fafcghostwhite |
| Primary | #191a1ablack | #191a1ablack |
| Primary foreground | #b1b3b4darkgray | #b1b3b4darkgray |
| Secondary | #1a191ablack | #1a191ablack |
| Secondary foreground | #b4b1b3darkgray | #b4b1b3darkgray |
| Muted | #ded8dcgainsboro | #272124black |
| Muted foreground | #61565cdimgray | #a99ea4darkgray |
| Accent | #1a1a19black | #1a1a19black |
| Accent foreground | #b3b4b1darkgray | #b3b4b1darkgray |
| Destructive | #9d1607darkred | #f52f19orangered |
| Destructive foreground | #fddcd8mistyrose | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #191a1ablack | #191a1ablack |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.76:1 | AAA |
| Text on card | 19.62:1 | AAA |
| Primary button | 8.31:1 | AAA |
| Secondary button | 8.25:1 | AAA |
| Muted text | 5.01:1 | AA |
| Accent | 8.36:1 | AAA |
| Destructive | 6.45:1 | AA |
| Text on background | 18.92:1 | AAA |
| Text on card | 19.12:1 | AAA |
| Primary button | 8.31:1 | AAA |
| Secondary button | 8.25:1 | AAA |
| Muted text | 6.11:1 | AA |
| Accent | 8.36:1 | AAA |
| Destructive | 3.94:1 | AA Large |
Paste this into your globals.css to use Best in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.984 0.003 242.24);
--foreground: oklch(0.089 0.013 232.206);
--muted: oklch(0.889 0.008 342.825);
--muted-foreground: oklch(0.467 0.017 343.495);
--popover: oklch(0.984 0.003 242.24);
--popover-foreground: oklch(0.089 0.013 232.206);
--card: oklch(0.976 0.005 242.263);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.215 0.001 242.27);
--primary-foreground: oklch(0.765 0.003 242.241);
--secondary: oklch(0.215 0.002 342.836);
--secondary-foreground: oklch(0.763 0.004 342.752);
--accent: oklch(0.217 0.002 126.552);
--accent-foreground: oklch(0.768 0.005 126.505);
--destructive: oklch(0.446 0.17 30.529);
--destructive-foreground: oklch(0.92 0.038 25.38);
--ring: oklch(0.215 0.001 242.27);
--chart-1: oklch(0.215 0.001 242.27);
--chart-2: oklch(0.215 0.002 342.836);
--chart-3: oklch(0.217 0.002 126.552);
--chart-4: oklch(0.247 0.002 342.855);
--chart-5: oklch(0.215 0.003 242.386);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.144 0.011 240.135);
--foreground: oklch(0.984 0.003 242.236);
--muted: oklch(0.255 0.01 343.585);
--muted-foreground: oklch(0.709 0.015 343.142);
--popover: oklch(0.144 0.011 240.135);
--popover-foreground: oklch(0.984 0.003 242.236);
--card: oklch(0.156 0.013 242.567);
--card-foreground: oklch(0.992 0.002 242.215);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.215 0.001 242.27);
--primary-foreground: oklch(0.765 0.003 242.241);
--secondary: oklch(0.215 0.002 342.836);
--secondary-foreground: oklch(0.763 0.004 342.752);
--accent: oklch(0.217 0.002 126.552);
--accent-foreground: oklch(0.768 0.005 126.505);
--destructive: oklch(0.627 0.234 30.519);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.215 0.001 242.27);
--chart-1: oklch(0.215 0.001 242.27);
--chart-2: oklch(0.215 0.002 342.836);
--chart-3: oklch(0.217 0.002 126.552);
--chart-4: oklch(0.247 0.002 342.855);
--chart-5: oklch(0.215 0.003 242.386);
}