Nut is a shadcn/ui theme built around a muted light blue primary color (#e5e7f1) with muted light blue accents (#e2e3e9). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted light blue primary (#e5e7f1) on a blue-tinted background (#03050c).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #03050cblack |
| Foreground | #040611black | #f5f6fawhitesmoke |
| Card | #ffffffwhite | #03050cblack |
| Card foreground | #040611black | #f5f6fawhitesmoke |
| Popover | #ffffffwhite | #03050cblack |
| Popover foreground | #040611black | #f5f6fawhitesmoke |
| Primary | #e5e7f1lavender | #e5e7f1lavender |
| Primary foreground | #3a4369darkslategray | #3a4369darkslategray |
| Secondary | #e2e3e9gainsboro | #202227black |
| Secondary foreground | #414658darkslategray | #b6b9c3silver |
| Muted | #ecedf4lavender | #0b0d13black |
| Muted foreground | #5e616edimgray | #9194a1lightslategray |
| Accent | #e2e3e9gainsboro | #202227black |
| Accent foreground | #414658darkslategray | #b6b9c3silver |
| Destructive | #ad330bfirebrick | #f36c3ftomato |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #e5e7f1lavender | #e5e7f1lavender |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.20:1 | AAA |
| Text on card | 20.20:1 | AAA |
| Primary button | 7.78:1 | AAA |
| Secondary button | 7.32:1 | AAA |
| Muted text | 5.27:1 | AA |
| Accent | 7.32:1 | AAA |
| Destructive | 6.45:1 | AA |
| Text on background | 18.84:1 | AAA |
| Text on card | 18.84:1 | AAA |
| Primary button | 7.78:1 | AAA |
| Secondary button | 8.14:1 | AAA |
| Muted text | 6.43:1 | AA |
| Accent | 8.14:1 | AAA |
| Destructive | 7.02:1 | AAA |
Paste this into your globals.css to use Nut in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.127 0.025 267.795);
--muted: oklch(0.947 0.009 274.917);
--muted-foreground: oklch(0.495 0.021 274.469);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.127 0.025 267.795);
--card: oklch(1 0 180);
--card-foreground: oklch(0.127 0.025 267.795);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.929 0.013 274.86);
--primary-foreground: oklch(0.394 0.065 272.4);
--secondary: oklch(0.917 0.008 274.921);
--secondary-foreground: oklch(0.396 0.032 273.906);
--accent: oklch(0.917 0.008 274.921);
--accent-foreground: oklch(0.396 0.032 273.906);
--destructive: oklch(0.501 0.164 36.292);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.929 0.013 274.86);
--chart-1: oklch(0.929 0.013 274.86);
--chart-2: oklch(0.917 0.008 274.921);
--chart-3: oklch(0.917 0.008 274.921);
--chart-4: oklch(0.942 0.006 274.958);
--chart-5: oklch(0.928 0.014 274.841);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.117 0.019 268.179);
--foreground: oklch(0.973 0.005 274.972);
--muted: oklch(0.16 0.014 273.751);
--muted-foreground: oklch(0.668 0.02 274.658);
--popover: oklch(0.117 0.019 268.179);
--popover-foreground: oklch(0.973 0.005 274.972);
--card: oklch(0.117 0.019 268.179);
--card-foreground: oklch(0.973 0.005 274.972);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.929 0.013 274.86);
--primary-foreground: oklch(0.394 0.065 272.4);
--secondary: oklch(0.251 0.011 274.456);
--secondary-foreground: oklch(0.786 0.015 274.791);
--accent: oklch(0.251 0.011 274.456);
--accent-foreground: oklch(0.786 0.015 274.791);
--destructive: oklch(0.689 0.176 38.516);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.929 0.013 274.86);
--chart-1: oklch(0.929 0.013 274.86);
--chart-2: oklch(0.251 0.011 274.456);
--chart-3: oklch(0.251 0.011 274.456);
--chart-4: oklch(0.281 0.013 274.421);
--chart-5: oklch(0.928 0.014 274.841);
}