Medium is a shadcn/ui theme built around a neutral gray primary color (#777977) with neutral gray accents (#797779). The light mode uses a neutral background (#f8fcf8). Dark mode keeps the neutral gray primary (#777977) on a green-tinted background (#051005).
| Token | Light | Dark |
|---|---|---|
| Background | #f8fcf8mintcream | #051005black |
| Foreground | #040c03black | #fcfdfcwhite |
| Card | #f4fbf4whitesmoke | #061406black |
| Card foreground | #020802black | #ffffffwhite |
| Popover | #f8fcf8mintcream | #051005black |
| Popover foreground | #040c03black | #fcfdfcwhite |
| Primary | #777977gray | #777977gray |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #797779gray | #797779gray |
| Secondary foreground | #ffffffwhite | #ffffffwhite |
| Muted | #ebdaeclavender | #241325black |
| Muted foreground | #564356darkslategray | #bca9bcsilver |
| Accent | #797779gray | #797779gray |
| Accent foreground | #ffffffwhite | #ffffffwhite |
| Destructive | #830d07maroon | #f4392fcrimson |
| Destructive foreground | #fcc3c0pink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #777977gray | #777977gray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.15:1 | AAA |
| Text on card | 19.20:1 | AAA |
| Primary button | 4.39:1 | AA Large |
| Secondary button | 4.45:1 | AA Large |
| Muted text | 6.76:1 | AA |
| Accent | 4.45:1 | AA Large |
| Destructive | 6.77:1 | AA |
| Text on background | 19.04:1 | AAA |
| Text on card | 18.93:1 | AAA |
| Primary button | 4.39:1 | AA Large |
| Secondary button | 4.45:1 | AA Large |
| Muted text | 7.96:1 | AAA |
| Accent | 4.45:1 | AA Large |
| Destructive | 3.84:1 | AA Large |
Paste this into your globals.css to use Medium in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.987 0.008 144.568);
--foreground: oklch(0.14 0.028 142.911);
--muted: oklch(0.908 0.03 324.83);
--muted-foreground: oklch(0.409 0.041 325.229);
--popover: oklch(0.987 0.008 144.568);
--popover-foreground: oklch(0.14 0.028 142.911);
--card: oklch(0.981 0.012 144.542);
--card-foreground: oklch(0.122 0.024 142.908);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.574 0.005 144.567);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.571 0.005 324.669);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.571 0.005 324.669);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.389 0.151 29.4);
--destructive-foreground: oklch(0.867 0.065 21.977);
--ring: oklch(0.574 0.005 144.567);
--chart-1: oklch(0.574 0.005 144.567);
--chart-2: oklch(0.571 0.005 324.669);
--chart-3: oklch(0.571 0.005 324.669);
--chart-4: oklch(0.597 0.005 324.67);
--chart-5: oklch(0.578 0.018 144.414);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.157 0.031 142.987);
--foreground: oklch(0.993 0.001 144.612);
--muted: oklch(0.219 0.042 325.735);
--muted-foreground: oklch(0.756 0.035 324.911);
--popover: oklch(0.157 0.031 142.987);
--popover-foreground: oklch(0.993 0.001 144.612);
--card: oklch(0.172 0.035 142.998);
--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.574 0.005 144.567);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.571 0.005 324.669);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.571 0.005 324.669);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.633 0.224 28.506);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.574 0.005 144.567);
--chart-1: oklch(0.574 0.005 144.567);
--chart-2: oklch(0.571 0.005 324.669);
--chart-3: oklch(0.571 0.005 324.669);
--chart-4: oklch(0.597 0.005 324.67);
--chart-5: oklch(0.578 0.018 144.414);
}