# Kuori design system

This is everything an agent needs to build Kuori UI that looks like we designed it. Read it before you write any interface code, and stick to the names in here.

Kuori is an email client for web, mobile and Mac. The interface is quiet and dense, type does most of the work, and colour is used sparingly so it means something when it shows up.

## The short version, if you only read one section

1. Use the semantic tokens (`bg/surface`, `text/secondary`), never a raw hex and never a primitive like `gray/900`.
2. Build once and let the theme do the rest. Every token has a value in all seven themes, so nothing should be styled per theme.
3. Text is Inter. Pick one of the named styles below instead of setting size, weight and line height by hand.
4. Spacing and radius come from the scale. If a value isn't on the scale, it's wrong.
5. Icons are Phosphor. Look them up by the Kuori name in the icons table.
6. Inputs are Yöte (`yote-ui`). Don't build a field from scratch.
7. The accent colour is rare. Primary buttons are ink (`fill/primary`), not accent.
8. Text on a primary button is `text/inverse`, because `fill/primary` flips between light and dark themes.
9. Anything people do many times an hour is instant. Motion is only for things that appear occasionally.

## Themes: seven of them, one set of token names

Set the theme with a `data-theme` attribute on the root element. Glass Dark is the default.

| Theme | `data-theme` | Kind |
| --- | --- | --- |
| Glass Dark | `glass-dark` | Dark |
| Glass Light | `glass-light` | Light |
| Dark | `dark` | Dark |
| Light | `light` | Light |
| Dim | `dim` | Dark |
| Paper | `paper` | Light |
| Pink | `pink` | Light |

The two Glass themes are translucent: the canvas and the overlay blur what is behind them (`--glass-blur` is 40px there and 0 everywhere else). Write the blur once with the variable and the solid themes take care of themselves.

Every value lives in `kuori-tokens.css` as a CSS variable. The token `bg/surface` is `var(--bg-surface)`, `status/danger/text` is `var(--status-danger-text)`, and so on: swap the slashes for dashes.

## Backgrounds: six layers, stacked in this order

Think of the app as layers of paper. Each layer has one token, and a layer only ever sits on the one before it.

| Token | CSS variable | Light | Glass Dark | Use it for |
| --- | --- | --- | --- | --- |
| `bg/canvas` | `--bg-canvas` | `#ffffff` | `rgb(16 16 16 / 0.64)` | Layer 1. The window itself: sidebar and title bar. Translucent in the Glass themes, solid everywhere else. |
| `bg/surface` | `--bg-surface` | `#f5f5f5` | `#0b0b0b` | Layer 2. The content panel that sits inset on the canvas. Where reading and work happen. |
| `bg/subtle` | `--bg-subtle` | `rgb(0 0 0 / 0.04)` | `rgb(255 255 255 / 0.06)` | Layer 3. A quiet secondary fill inside any layer: code blocks, input wells, table headers, tracks. Alpha, so it adapts to what it sits on. |
| `bg/raised` | `--bg-raised` | `#eeeeee` | `#171717` | Layer 4. Lifted off the surface: cards, chat bubbles, grouped rows, the selected segment. |
| `bg/overlay` | `--bg-overlay` | `#ffffff` | `rgb(16 16 16 / 0.64)` | Layer 5. Floats above everything: dropdowns, menus, popovers, peek cards, dialogs, the command palette. Same as the canvas in every theme: glass in the Glass themes, solid elsewhere. Pair with the Glass/Overlay effect (blur, top highlight, Shadow/LG). Never bg/raised. |
| `bg/inverse` | `--bg-inverse` | `#1e1e1e` | `#eeeeee` | Layer 6. The opposite polarity: tooltips, toasts, anything that must pop off the theme. |
| `bg/scrim` | `--bg-scrim` | `rgb(0 0 0 / 0.28)` | `rgb(0 0 0 / 0.52)` | Dim behind a modal. Not a layer, a veil. |

In Light, the canvas is pure white and the greys are layered on top of it.

## Text: five levels of emphasis, plus two for text on solid fills

| Token | CSS variable | Light | Glass Dark | Use it for |
| --- | --- | --- | --- | --- |
| `text/primary` | `--text-primary` | `#1e1e1e` | `rgb(255 255 255 / 0.92)` | Titles, unread subjects, body copy. The default. |
| `text/secondary` | `--text-secondary` | `#4d4d4d` | `rgb(255 255 255 / 0.72)` | Read rows, nav items, descriptions. One clear step back. |
| `text/tertiary` | `--text-tertiary` | `#636363` | `rgb(255 255 255 / 0.6)` | Previews, metadata, section labels. Still AA on surface. |
| `text/quaternary` | `--text-quaternary` | `#808080` | `rgb(255 255 255 / 0.44)` | Placeholders, timestamps, hints. 3:1, never for essential copy. |
| `text/disabled` | `--text-disabled` | `#bebebe` | `rgb(255 255 255 / 0.28)` | Disabled labels and icons only. |
| `text/inverse` | `--text-inverse` | `#fbfbfb` | `#121212` | Text on bg/inverse and on fill/primary. |
| `text/on-accent` | `--text-on-accent` | `#ffffff` | `#ffffff` | Text and icons on accent/solid. Status solids have their own on-solid tokens. |

## Borders, states and fills: the parts that make controls feel like controls

| Token | CSS variable | Light | Glass Dark | Use it for |
| --- | --- | --- | --- | --- |
| `border/subtle` | `--border-subtle` | `rgb(0 0 0 / 0.06)` | `rgb(255 255 255 / 0.06)` | Dividers and row separators. |
| `border/default` | `--border-default` | `rgb(0 0 0 / 0.1)` | `rgb(255 255 255 / 0.1)` | Card, input and panel outlines. |
| `border/strong` | `--border-strong` | `rgb(0 0 0 / 0.16)` | `rgb(255 255 255 / 0.16)` | Hovered inputs, emphasis outlines, control borders. |
| `border/focus` | `--border-focus` | `#186ddd` | `#2a81fa` | Focus ring. |
| `state/hover` | `--state-hover` | `rgb(0 0 0 / 0.04)` | `rgb(255 255 255 / 0.04)` | Hover wash on rows, ghost buttons, nav items. |
| `state/pressed` | `--state-pressed` | `rgb(0 0 0 / 0.1)` | `rgb(255 255 255 / 0.12)` | Pressed wash. |
| `state/selected` | `--state-selected` | `rgb(0 0 0 / 0.06)` | `rgb(255 255 255 / 0.08)` | Selected row or nav item. |
| `fill/primary` | `--fill-primary` | `#1e1e1e` | `#eeeeee` | Primary button. Ink, not brand, so the accent stays rare. |
| `fill/primary-hover` | `--fill-primary-hover` | `#353535` | `#cecece` | Primary button, hovered. |
| `fill/secondary` | `--fill-secondary` | `rgb(0 0 0 / 0.06)` | `rgb(255 255 255 / 0.08)` | Secondary button, chips, segmented track. |
| `fill/secondary-hover` | `--fill-secondary-hover` | `rgb(0 0 0 / 0.1)` | `rgb(255 255 255 / 0.12)` | Secondary button, hovered. |
| `fill/control` | `--fill-control` | `rgb(0 0 0 / 0.12)` | `rgb(255 255 255 / 0.16)` | Unchecked checkbox, switch track, kbd key. |
| `fill/search` | `--fill-search` | `rgb(0 0 0 / 0.02)` | `rgb(255 255 255 / 0.04)` | The search field in the sidebar. Quieter than bg/subtle, which input wells use. |
| `fill/disabled` | `--fill-disabled` | `rgb(0 0 0 / 0.04)` | `rgb(255 255 255 / 0.04)` | Disabled control background. |

The state tokens are washes. Lay them over whatever the element already sits on instead of swapping its background.

## Accent and status: colour that means something

| Token | CSS variable | Light | Glass Dark | Use it for |
| --- | --- | --- | --- | --- |
| `accent/solid` | `--accent-solid` | `#186ddd` | `#186ddd` | Brand fill: unread dot, checked control, selection handle. White text passes AA. |
| `accent/solid-hover` | `--accent-solid-hover` | `#1559b5` | `#2a81fa` | Accent fill, hovered. |
| `accent/text` | `--accent-text` | `#1559b5` | `#9ec4fc` | Links and accent-coloured labels. |
| `accent/subtle` | `--accent-subtle` | `rgb(42 129 250 / 0.12)` | `rgb(42 129 250 / 0.16)` | Accent tint: selected-with-meaning, highlighted row, badge. |
| `status/success/text` | `--status-success-text` | `#1a7037` | `#2ff479` | Success text and icons. Use it for the title and body inside a success alert. |
| `status/success/solid` | `--status-success-solid` | `#1d8843` | `#1d8843` | Success solid fill: badges and the alert icon chip. |
| `status/success/on-solid` | `--status-success-on-solid` | `#ffffff` | `#ffffff` | Text and icons on status/success/solid. |
| `status/success/icon` | `--status-success-icon` | `#0e9e4a` | `#20c861` | Success icons on their own, like a state icon in a list. Brighter than the text, since icons only need 3:1. |
| `status/success/subtle` | `--status-success-subtle` | `rgb(32 200 97 / 0.08)` | `rgb(32 200 97 / 0.16)` | Success alert background. Alpha, so it sits on any layer. |
| `status/success/border` | `--status-success-border` | `rgb(32 200 97 / 0.32)` | `rgb(32 200 97 / 0.32)` | Success alert outline. Pair it with status/success/subtle. |
| `status/warning/text` | `--status-warning-text` | `#8c5e1a` | `#fdc987` | Warning text and icons. Use it for the title and body inside a warning alert. |
| `status/warning/solid` | `--status-warning-solid` | `#f5a41e` | `#f5a41e` | Warning solid fill: badges and the alert icon chip. |
| `status/warning/on-solid` | `--status-warning-on-solid` | `#0b0b0b` | `#0b0b0b` | Text and icons on status/warning/solid. |
| `status/warning/icon` | `--status-warning-icon` | `#bc7c0c` | `#f5a41e` | Warning icons on their own, like a state icon in a list. Brighter than the text, since icons only need 3:1. |
| `status/warning/subtle` | `--status-warning-subtle` | `rgb(245 164 30 / 0.08)` | `rgb(245 164 30 / 0.16)` | Warning alert background. Alpha, so it sits on any layer. |
| `status/warning/border` | `--status-warning-border` | `rgb(245 164 30 / 0.32)` | `rgb(245 164 30 / 0.32)` | Warning alert outline. Pair it with status/warning/subtle. |
| `status/danger/text` | `--status-danger-text` | `#ab1e24` | `#fcaca5` | Danger text and icons. Use it for the title and body inside a danger alert. |
| `status/danger/solid` | `--status-danger-solid` | `#cf212c` | `#cf212c` | Danger solid fill: badges, the alert icon chip, a destructive button. |
| `status/danger/on-solid` | `--status-danger-on-solid` | `#ffffff` | `#ffffff` | Text and icons on status/danger/solid. |
| `status/danger/icon` | `--status-danger-icon` | `#fd2937` | `#fb2f39` | Danger icons on their own, like a state icon in a list. Brighter than the text, since icons only need 3:1. |
| `status/danger/subtle` | `--status-danger-subtle` | `rgb(251 47 57 / 0.08)` | `rgb(251 47 57 / 0.16)` | Danger alert background. Alpha, so it sits on any layer. |
| `status/danger/border` | `--status-danger-border` | `rgb(251 47 57 / 0.32)` | `rgb(251 47 57 / 0.32)` | Danger alert outline. Pair it with status/danger/subtle. |
| `status/info/text` | `--status-info-text` | `#1559b5` | `#9ec4fc` | Info text and icons. Use it for the title and body inside an info alert. |
| `status/info/solid` | `--status-info-solid` | `#186ddd` | `#186ddd` | Info solid fill: badges and the alert icon chip. |
| `status/info/on-solid` | `--status-info-on-solid` | `#ffffff` | `#ffffff` | Text and icons on status/info/solid. |
| `status/info/icon` | `--status-info-icon` | `#2781fd` | `#2a81fa` | Info icons on their own, like a state icon in a list. Brighter than the text, since icons only need 3:1. |
| `status/info/subtle` | `--status-info-subtle` | `rgb(42 129 250 / 0.08)` | `rgb(42 129 250 / 0.16)` | Info alert background. Alpha, so it sits on any layer. |
| `status/info/border` | `--status-info-border` | `rgb(42 129 250 / 0.32)` | `rgb(42 129 250 / 0.32)` | Info alert outline. Pair it with status/info/subtle. |
| `icon/star` | `--icon-star` | `#f5a41e` | `#f5a41e` | Filled star on favourited mail. Bright gold in every theme; the unstarred state is the outline star in text/quaternary. |

Never show a status with colour alone. Pair it with an icon or a label.

`icon/star` is the favourite star: bright gold in every theme, filled shape and stroke in the same token so it reads as one solid shape. An unstarred star is the outline icon in `text/quaternary`.

## Tags: ten label colours that all work the same way

Each label colour is a pair: `tag/<colour>/text` for the label and its icon, and `tag/<colour>/bg` for the low opacity fill behind it. The colours are red, orange, amber, yellow, green, cyan, blue, purple, pink and gray. In CSS that is `var(--tag-green-text)` on `var(--tag-green-bg)`. `tag/<colour>/icon` is a brighter step for an icon standing on its own.

A tag pill is 20 tall with radius 6, padding 5 on the left and 6 on the right, and 4 between icon and label. The icon is 12px, Phosphor **Filled**, in `tag/<colour>/icon`. The label is `Label/XS` in `tag/<colour>/text`, on `tag/<colour>/bg`.

| Tag | Colour | Icon |
| --- | --- | --- |
| Work | blue | `briefcase` |
| Updates | purple | `bell-simple` |
| Receipts | amber | `receipt` |
| Newsletters | orange | `newspaper` |
| Travel | green | `airplane-tilt` |
| Personal | pink | `user` |
| Product | cyan | `rocket-launch` |
| Alerts | red | `shield-warning` |

## AI: one gradient, only for what AI does

Anything Kuori's AI does (the AI assist icon, Recap, AI replies) wears one gradient, Dusk: violet to pink to peach at 135 degrees, stepped in OKLCH so it stays clean. Nothing else uses it, so people learn that the gradient means AI.

| Use | Figma | CSS |
| --- | --- | --- |
| Icons, borders, highlights | `AI/Gradient` paint style | `var(--ai-gradient)` |
| Backgrounds behind AI content | `AI/Subtle` paint style (the gradient at 14%) | `var(--ai-gradient-subtle)` |
| A single stop, when a gradient can't be used | `ai/start`, `ai/mid`, `ai/end` | `var(--ai-start)` and so on |

The dark themes use stops 0.06 lighter so the gradient keeps its glow on near-black. Don't put body text on the full gradient, and don't use it for anything the AI didn't do.

## Static: colours that never follow the theme

| Token | CSS variable | Light | Glass Dark | Use it for |
| --- | --- | --- | --- | --- |
| `static/black` | `--static-black` | `#000000` | `#000000` | Hard black. Pure #000000 in every theme, so it never follows the theme. For logo tiles, brand artwork and anything that must stay black. |
| `static/white` | `--static-white` | `#ffffff` | `#ffffff` | Pure #FFFFFF in every theme. For text and icons on photos, brand artwork and the AI gradient, where white is the point. |
| `static/white-80` | `--static-white-80` | `rgb(255 255 255 / 0.8)` | `rgb(255 255 255 / 0.8)` | White at 80% in every theme. On dark photos or brand surfaces: secondary text. |
| `static/white-60` | `--static-white-60` | `rgb(255 255 255 / 0.6)` | `rgb(255 255 255 / 0.6)` | White at 60% in every theme. On dark photos or brand surfaces: tertiary text and icons. |
| `static/white-36` | `--static-white-36` | `rgb(255 255 255 / 0.36)` | `rgb(255 255 255 / 0.36)` | White at 36% in every theme. On dark photos or brand surfaces: placeholder and disabled. |
| `static/white-16` | `--static-white-16` | `rgb(255 255 255 / 0.16)` | `rgb(255 255 255 / 0.16)` | White at 16% in every theme. On dark photos or brand surfaces: borders and dividers. |
| `static/white-8` | `--static-white-8` | `rgb(255 255 255 / 0.08)` | `rgb(255 255 255 / 0.08)` | White at 8% in every theme. On dark photos or brand surfaces: hover and subtle fills. |
| `static/black-80` | `--static-black-80` | `rgb(0 0 0 / 0.8)` | `rgb(0 0 0 / 0.8)` | Black at 80% in every theme. On light photos or scrims over imagery: secondary text. |
| `static/black-60` | `--static-black-60` | `rgb(0 0 0 / 0.6)` | `rgb(0 0 0 / 0.6)` | Black at 60% in every theme. On light photos or scrims over imagery: tertiary text and icons. |
| `static/black-36` | `--static-black-36` | `rgb(0 0 0 / 0.36)` | `rgb(0 0 0 / 0.36)` | Black at 36% in every theme. On light photos or scrims over imagery: placeholder and disabled. |
| `static/black-16` | `--static-black-16` | `rgb(0 0 0 / 0.16)` | `rgb(0 0 0 / 0.16)` | Black at 16% in every theme. On light photos or scrims over imagery: borders and dividers. |
| `static/black-8` | `--static-black-8` | `rgb(0 0 0 / 0.08)` | `rgb(0 0 0 / 0.08)` | Black at 8% in every theme. On light photos or scrims over imagery: hover and subtle fills. |

Static colours are the same in all seven themes. Reach for them when the colour is fixed by what sits underneath, not by the theme: white text on a photo or on the AI gradient, a black logo tile, a scrim over an auth background. The alpha steps follow the same ladder as the text tokens: 80 for secondary text, 60 for tertiary, 36 for placeholders, 16 for borders, 8 for hover. For interface text and surfaces, keep using the `text` and `bg` tokens so the themes still work.

## Glass, shadows and focus: use the named effect, don't rebuild it

| Effect | What it is | Use it for |
| --- | --- | --- |
| `Shadow/SM` | 0 1px 2px `shadow/key` | Chips, the selected segment, small raised controls |
| `Shadow/MD` | SM plus 0 4px 12px `shadow/ambient` | Cards and raised panels |
| `Shadow/LG` | 0 1px 3px `shadow/key` plus 0 8px 24px `shadow/ambient` | Menus and popovers, always with `bg/overlay` and the Glass/Overlay effect |
| `Shadow/XL` | 0 2px 6px `shadow/key` plus 0 16px 40px `shadow/ambient` | Dialogs and the window itself |
| `Glass/Canvas` | Background blur, inner top highlight (`glass/highlight`), Shadow/XL | The window in the Glass themes |
| `Glass/Overlay` | Background blur, inner top highlight, Shadow/LG | Menus, popovers and the command palette |
| `Focus/Ring` | 2px ring in `border/focus` | Keyboard focus on buttons, rows and links |
| `Shadow/Field` | 0 2px 4px in `shadow/field` | Input fields at rest, on hover and when filled, matched to KernUI |
| `Focus/Field` | 3px halo in `accent/subtle` | A focused input, together with a `border/focus` outline |
| `Focus/Field Danger` | 3px halo in `status/danger/subtle` | A focused input that has an error |

Anything floating gets a `glass/stroke` hairline around it.

## Typography: Inter for the app, one serif for brand moments

The sans is Inter and the serif is Libre Baskerville. Sizes are in px, written as size / line height.

| Style | Size | Weight | Tracking | Use it for |
| --- | --- | --- | --- | --- |
| `Display/LG` | 40 / 44 | Semibold 600 | -2.21% | Hero figures, empty states. |
| `Display/SM` | 32 / 36 | Semibold 600 | -2.16% | Stat values, page-level numbers. |
| `Display/Digit` | 30 / 38 | Regular 400 | 0.3px | Digits in the pin input. |
| `Heading/XL` | 24 / 32 | Semibold 600 | -1.95% | Page titles. |
| `Heading/LG` | 20 / 28 | Semibold 600 | -1.67% | Section titles, dialog titles. |
| `Heading/MD` | 17 / 24 | Semibold 600 | -1.28% | Panel titles, thread subjects. |
| `Heading/SM` | 15 / 20 | Semibold 600 | -0.88% | Card titles, group headings. |
| `Heading/XS` | 13 / 18 | Semibold 600 | -0.32% | Dense headings, table headers, unread rows. |
| `Body/XL` | 16 / 26 | Regular 400 | -1.10% | Reader mode, long-form. |
| `Body/LG` | 15 / 24 | Regular 400 | -0.88% | Message bodies, documents. |
| `Body/MD` | 14 / 20 | Regular 400 | -0.62% | Default interface copy. |
| `Body/SM` | 13 / 18 | Regular 400 | -0.32% | Dense rows, previews, secondary copy. |
| `Body/XS` | 12 / 16 | Regular 400 | +0.05% | Captions, timestamps, helper text. |
| `Body/2XS` | 11 / 14 | Regular 400 | +0.48% | Metadata in dense lists, small print. |
| `Body/3XS` | 10 / 14 | Regular 400 | +1.00% | Badge counts and footnotes. Use sparingly, never for anything people need to read closely. |
| `Label/LG` | 14 / 20 | Medium 500 | -0.62% | Buttons, tabs, prominent list titles. |
| `Label/MD` | 13 / 18 | Medium 500 | -0.32% | Nav items, buttons, table cells. |
| `Label/SM` | 12 / 16 | Medium 500 | +0.05% | Tags, badges, section labels. |
| `Label/XS` | 11 / 14 | Medium 500 | +0.48% | Counters, keyboard hints, micro badges. |
| `Label/Overline` | 11 / 14 | Semibold 600 | +6.00% | Section markers. Always uppercase. |
| `Body/Reading` | 14 / 22 | Regular 400 | 0 | Email bodies and any long-form reading. UI text stays on `Body/MD`. |
| `Serif/SM` | 14 / 20 | Regular 400 | -0.35px | Libre Baskerville. Brand moments like the Kuori name next to the logo, never interface copy. |

Body is for reading, Label is for anything you click or scan, Heading is for titles. If a number changes on screen (counts, timers), give it tabular figures.

## Spacing and radius: the only values you should reach for

| Scale | Values in px | CSS variable |
| --- | --- | --- |
| Space | 0, 2, 4, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 64 | `--space-<value>` |
| Radius | 4, 6, 8, 10, 12, 16, 20, full | `--radius-<value>` |

Nested corners are concentric: inner radius is the outer radius minus the padding between them. A card with radius 12 and 4 of padding holds rows with radius 8.

## Icons: Phosphor, looked up by what the icon does

Install `@phosphor-icons/react`. Outline is the default. Filled is the same icon with `weight="fill"`. Icons are 20px in the app and take `text/primary` unless the text beside them is quieter, in which case they match it.

| In Kuori | Phosphor name | React |
| --- | --- | --- |
| Inbox | `tray` | `<TrayIcon />` |
| Starred | `star` | `<StarIcon />` |
| Drafts | `file` | `<FileIcon />` |
| Sent | `paper-plane-tilt` | `<PaperPlaneTiltIcon />` |
| Archive | `archive` | `<ArchiveIcon />` |
| Trash | `trash` | `<TrashIcon />` |
| Labels | `tag` | `<TagIcon />` |
| Folders | `folder` | `<FolderIcon />` |
| Compose | `pencil-simple` | `<PencilSimpleIcon />` |
| Reply | `arrow-bend-up-left` | `<ArrowBendUpLeftIcon />` |
| Reply all | `arrow-bend-double-up-left` | `<ArrowBendDoubleUpLeftIcon />` |
| Forward | `arrow-bend-up-right` | `<ArrowBendUpRightIcon />` |
| Attach | `paperclip` | `<PaperclipIcon />` |
| Snooze | `clock-countdown` | `<ClockCountdownIcon />` |
| Mark as read | `envelope-open` | `<EnvelopeOpenIcon />` |
| Read status filter | `envelope-simple` | `<EnvelopeSimpleIcon />` |
| Tag filter | `tag` | `<TagIcon />` |
| List view | `rows` | `<RowsIcon />` |
| Split view | `square-split-horizontal` | `<SquareSplitHorizontalIcon />` |
| More | `dots-three` | `<DotsThreeIcon />` |
| Refresh | `arrow-clockwise` | `<ArrowClockwiseIcon />` |
| Back | `arrow-left` | `<ArrowLeftIcon />` |
| Search | `magnifying-glass` | `<MagnifyingGlassIcon />` |
| Settings | `gear` | `<GearIcon />` |
| API token | `key` | `<KeyIcon />` |
| AI assist | `sparkle` | `<SparkleIcon />` |
| Pull request | `git-pull-request` | `<GitPullRequestIcon />` |
| Merged | `git-merge` | `<GitMergeIcon />` |
| Opens elsewhere | `arrow-up-right` | `<ArrowUpRightIcon />` |
| Next step inside Kuori | `caret-right` | `<CaretRightIcon />` |
| Permission granted | `check` | `<CheckIcon />` |
| Never allowed | `x` | `<XIcon />` |
| Secure | `lock-simple` | `<LockSimpleIcon />` |

## Inputs: Yöte does the fields, Kuori tokens do the colour

Every field comes from `yote-ui`: `Input`, `Textarea`, `SelectInput`, `InlineSelect`, `DateInput`, `PasswordInput`, `PhoneInput`, `TagsInput`, `PinInput` and `CardInput`. They come in three sizes.

| Size | Field height | Radius | Side padding |
| --- | --- | --- | --- |
| `sm` | 38 | 12 | 14 |
| `md` | 42 | 16 | 18 |
| `lg` | 46 | 20 | 22 |

| Part or state | Token |
| --- | --- |
| Field fill | `bg/canvas` with `Shadow/Field` |
| Outline | `border/subtle` at rest and when filled, `border/strong` with a `state/hover` wash on hover |
| Focused | `border/focus` outline with the `Focus/Field` halo |
| Error | `status/danger/solid` outline with the `Focus/Field Danger` halo, message in `status/danger/text` |
| Value | `text/primary` |
| Label | `Body/SM` in `text/primary` |
| Placeholder | `text/disabled` |
| Helper message | `text/secondary`, 12 / 16 |
| Disabled | `fill/disabled` fill with `text/disabled` |
| Dropdown | `bg/overlay` with `Glass/Overlay`, radius 16 |

Every field has a visible label. A placeholder is a hint, not a label.

## Buttons: three variants, one per job

| Variant | Fill | Hover | Label and icons | Use it for |
| --- | --- | --- | --- | --- |
| Primary | `fill/primary` | `fill/primary-hover` | `text/inverse` | The one main action on a screen |
| Secondary | `bg/surface` | `bg/subtle` | `text/primary` | Alternatives, like Continue with Google |
| Ghost | none | `state/hover` | `text/secondary` | Cancel, Back, quiet actions |

Disabled is `fill/disabled` with `text/disabled`. Two sizes, both with label `Body/SM` and 12 side padding: `md` is 34 tall with radius 10, for toolbars, the reply box and inline actions. `lg` is 38 tall with radius 12 and always pairs with Input `sm` (also 38, radius 12), so every form stack lines up: auth, onboarding and settings. A leading or trailing icon is optional: `arrow-up-right` means the action opens somewhere else, `caret-right` means the next step stays in Kuori.

`fill/primary` flips between themes (near black in light themes, near white in dark ones), so text on it is always `text/inverse`. `text/on-accent` is always white and disappears on a dark theme's primary button.

## Switch

A 28 by 16 track with radius 8 and a 12px knob in `bg/canvas`. On is `fill/primary`, off is `border/strong`. Label the row by its on state ("Comment from Kuori"), never by its off state.

## Layout: the window, the sidebar and one shared top line

- The window insets everything by 16. The sidebar is 280 wide, or a 64 wide rail when collapsed. The content area sits 16 from the sidebar, the top, the right and the bottom.
- The sidebar header, the page title and the header controls all centre on one line, 28px from the top of the window. The sidebar logo sits 16 from the top and 16 from the left.
- Header controls (the `All mail` and `All tags` dropdowns, the view toggle) are 24 tall, radius 8, with a `border/subtle` hairline. A dropdown always shows its current value, never a bare "Filter".
- The content panel is `bg/surface`. In split view, the email list sits straight on the window with no panel behind it, and only the reading pane is `bg/surface`.

## Inbox: rows, reading and empty states

| Part | Spec |
| --- | --- |
| Insets | Rows, group labels, split cards and the Select all row all use 12 inside, so content lines up in both views |
| Row | 36 tall: checkbox, star, unread dot, sender (150 wide), subject and preview (preview fills and truncates), tag, time |
| Unread | `accent/solid` dot, sender and subject in `Heading/XS` `text/primary` |
| Read | No dot, sender and subject in `Body/SM` `text/secondary` |
| Preview | `Body/SM` `text/tertiary`, always truncated to one line |
| Selected | `state/selected` |
| Hover | `state/hover`, instant, and only on devices with a real pointer |
| Groups | Today, Yesterday, Earlier this week, Last week, Earlier in {month}, in `Body/XS` `text/tertiary` |
| Pagination | 50 per page, pinned to the bottom of the panel: "1–50 of 48,979" in `Body/XS` `text/tertiary`, then previous and next. Previous is `text/disabled` on page 1 |
| Peek card | Shown after hovering a row for 450ms: sender, email, time, subject, preview and tag, on `bg/overlay` with `Shadow/LG`. Opens under the row at the subject column |
| Split view list | Cards of three lines (sender and time, subject, preview with tag) with the checkbox on the left |
| Reading pane | One component (`Reading pane`) for both the full view and split view. Toolbar (`Email toolbar`: back to Inbox in the full view only, archive, delete, star, then "1 of N" with previous and next, then reply, forward, more), subject with its tag, sender, body in `Body/Reading` capped at 760 wide, attachments, reply box pinned to the bottom |
| Selection | A 36 tall "Select all" row tops the list (mixed checkbox, "4 of 50 selected", "Select all 48,979"), with even space above and below. The selection bar floats 16 above the bottom in `bg/inverse`. In split view the reading pane says "4 conversations selected" |
| More menu | Opens from "…" in the toolbar. Three groups 8 apart with no dividers: the message (mark as unread, snooze, add tag), the sender (block, report spam, report phishing), tools (filter like this, translate, print, download, show original). Star is never in here |
| Nothing selected | A 44px `bg/canvas` tile with the envelope icon, "No conversation selected" in `Heading/SM`, "Pick an email from the list to read it here." in `Body/SM` `text/tertiary` |
| Scrollbars | Kuori's own bar, never the browser's: a 6px `scrollbar/thumb` pill on a transparent track, `scrollbar/thumb-hover` on hover, no arrows |
| Loading | A skullet skeleton the exact shape of what is coming, in `skeleton/base` with a slow `skeleton/highlight` shimmer. Held back 150ms, so a fast load never flashes one. Never a spinner over the list |

## Motion: fast where people repeat, gentle where they decide

Anything people do many times an hour does not animate. Motion is kept for things that appear occasionally, and it always starts fast.

| Interaction | Motion |
| --- | --- |
| Row hover, checkbox, star fill, selecting an email, pagination | None. Instant |
| J and K, next and previous email, any keyboard action | None. Swap the content instantly |
| Pressing any button or toggle | `scale(0.97)` on `:active`, 120ms ease-out. The star scales to 0.9 on press |
| Dropdown menus | Grow from the trigger corner, `scale(0.97)` plus opacity, 150ms in, 100ms out |
| Peek card | 450ms delay before the first one, then instant on neighbouring rows while one is open. 125ms ease-out from the row |
| Sidebar collapse | 200ms ease-in-out, moving the contents with `transform`, never animating width |
| Skeleton to content | Skullet's smart reveal: instant for a load under 150ms or mid-gesture, a quick crossfade for a refetch, otherwise rows and cards in screen order. Still under `prefers-reduced-motion` |
| List to split view | No layout animation. A crossfade of 120ms at most |

Use `--ease-out: cubic-bezier(0.23, 1, 0.32, 1)` for things appearing and `--ease-in-out: cubic-bezier(0.77, 0, 0.175, 1)` for things moving on screen. Never `ease-in`, never `transition: all`, never start from `scale(0)`. With `prefers-reduced-motion`, drop scale and movement and keep the opacity fades.

## Things that are always wrong

- A hex value, an rgba or a primitive token in component code.
- A style that only exists for one theme.
- A font size, spacing or radius that isn't on the scale.
- The accent colour on a primary button or as decoration.
- A shadow written by hand instead of one of the named effects.
- An icon from another set, or a Phosphor weight other than regular and fill.
- Essential copy in `text/quaternary` or `text/disabled`.
- `text/on-accent` on `fill/primary`.
- A translucent glass surface without its background blur.
- An animation on something people do many times an hour.
- A filter control that doesn't say what it's currently showing.
