Puny is a shadcn/ui theme built around a muted deep green primary color (#1f2e22) with muted deep purple accents (#2e1f2b). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted deep green primary (#1f2e22) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #000000black |
| Foreground | #020803black | #ffffffwhite |
| Card | #fcfcfcsnow | #030303black |
| Card foreground | #010402black | #ffffffwhite |
| Popover | #fcfcfcsnow | #030303black |
| Popover foreground | #010402black | #ffffffwhite |
| Primary | #1f2e22darkslategray | #1f2e22darkslategray |
| Primary foreground | #b3cbb8silver | #b3cbb8silver |
| Secondary | #2e1f2bdarkslategray | #2e1f2bdarkslategray |
| Secondary foreground | #cbb3c7silver | #cbb3c7silver |
| Muted | #f1eef0whitesmoke | #110e10black |
| Muted foreground | #534150darkslategray | #beacbbsilver |
| Accent | #2e1f2bdarkslategray | #2e1f2bdarkslategray |
| Accent foreground | #cbb3c7silver | #cbb3c7silver |
| Destructive | #b01f11firebrick | #df2716crimson |
| Destructive foreground | #fef6f6snow | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #1f2e22darkslategray | #1f2e22darkslategray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.21:1 | AAA |
| Text on card | 20.15:1 | AAA |
| Primary button | 8.29:1 | AAA |
| Secondary button | 8.04:1 | AAA |
| Muted text | 8.16:1 | AAA |
| Accent | 8.04:1 | AAA |
| Destructive | 6.45:1 | AA |
| Text on background | 21.00:1 | AAA |
| Text on card | 20.67:1 | AAA |
| Primary button | 8.29:1 | AAA |
| Secondary button | 8.04:1 | AAA |
| Muted text | 8.96:1 | AAA |
| Accent | 8.04:1 | AAA |
| Destructive | 4.74:1 | AA |
Paste this into your globals.css to use Puny in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.122 0.02 150.495);
--muted: oklch(0.953 0.004 331.462);
--muted-foreground: oklch(0.4 0.034 332.547);
--popover: oklch(0.992 0 161.565);
--popover-foreground: oklch(0.097 0.016 150.495);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0.097 0.016 150.495);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.282 0.029 149.799);
--primary-foreground: oklch(0.82 0.038 150.725);
--secondary: oklch(0.262 0.03 332.963);
--secondary-foreground: oklch(0.794 0.039 332.08);
--accent: oklch(0.262 0.03 332.963);
--accent-foreground: oklch(0.794 0.039 332.08);
--destructive: oklch(0.49 0.182 30.036);
--destructive-foreground: oklch(0.98 0.008 23.664);
--ring: oklch(0.282 0.029 149.799);
--chart-1: oklch(0.282 0.029 149.799);
--chart-2: oklch(0.262 0.03 332.963);
--chart-3: oklch(0.262 0.03 332.963);
--chart-4: oklch(0.292 0.036 333.033);
--chart-5: oklch(0.284 0.034 149.547);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(1 0 180);
--muted: oklch(0.168 0.006 331.884);
--muted-foreground: oklch(0.764 0.029 331.927);
--popover: oklch(0.092 0 180);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.092 0 180);
--card-foreground: oklch(1 0 180);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.282 0.029 149.799);
--primary-foreground: oklch(0.82 0.038 150.725);
--secondary: oklch(0.262 0.03 332.963);
--secondary-foreground: oklch(0.794 0.039 332.08);
--accent: oklch(0.262 0.03 332.963);
--accent-foreground: oklch(0.794 0.039 332.08);
--destructive: oklch(0.582 0.219 30.069);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.282 0.029 149.799);
--chart-1: oklch(0.282 0.029 149.799);
--chart-2: oklch(0.262 0.03 332.963);
--chart-3: oklch(0.262 0.03 332.963);
--chart-4: oklch(0.292 0.036 333.033);
--chart-5: oklch(0.284 0.034 149.547);
}