Skip to content
css-tokens logo

CSS Design Tokens Skill

css-tokens

Provides foundational CSS design tokens (custom properties) for typography, spacing, colors, borders, z-index, and transitions. Use when setting up a base token system for a web project.

SKILL.md

Full skill instructions

CSS Design Tokens Skill

Purpose

This skill provides a comprehensive set of CSS design tokens (custom properties) to establish a consistent design foundation for web projects. Use this skill when the user requests a base token system or design tokens for their CSS.

When to Use This Skill

Use this skill when the user asks for:

  • "Add design tokens to my project"
  • "Set up CSS tokens"
  • "Create a tokens file"
  • "Add base CSS variables"
  • Similar requests for foundational CSS custom properties

When NOT to Use This Skill

  • User already has an existing design token system (suggest modifications instead)
  • User specifically requests a framework-specific token system (e.g., Tailwind config, CSS-in-JS tokens)
  • User only needs a subset of tokens (offer to extract specific categories)

What This Skill Provides

A complete tokens.css file with a comprehensive design token system:

  • Typography: Font families, weights, and a modular size scale (xs to 4xl)
  • Spacing: Consistent size scale from 4px to 96px, named by pixel value
  • Colors: Using oklch() color space for perceptually uniform colors with light/​dark mode variants for surfaces, text, brand, interactive elements, and semantic states
  • Borders: Radius values derived from the size scale (sm to full)
  • Z-index: Named layers for stacking context (dropdown, modal, toast, etc.)
  • Transitions: Standard timing values (fast, base, slow)

Users can reference individual tokens using CSS custom property syntax: var(--token-name)

Token Content

The complete token definitions are located in references/​tokens.css within this skill directory. This file contains all the CSS custom property declarations organized by category.

How to Use This Skill

1. Detect CSS Directory

Search the project for common CSS directory names:

  • css/
  • styles/
  • assets/​css/
  • stylesheets/
  • src/​css/
  • src/​styles/

Check directories at multiple levels (root, src/, public/, assets/).

2. Confirm Location with User

If a CSS directory is found:

Present the discovered location and ask for confirmation:

I found a CSS directory at [path]. Should I add the design tokens to this directory in a file named `tokens.css`?

If you'd like a different location or filename, please specify both.

If no CSS directory is found:

Ask the user directly:

I couldn't find an existing CSS directory in your project. Please specify:
1. The directory path where you'd like the tokens file (I can create it if needed)
2. The filename (e.g., `tokens.css`, `design-tokens.css`)

3. Write the Tokens File

Once confirmed, write the complete tokens file to the specified location. Use the exact content from references/​tokens.css in this skill directory.

4. Inform User About Import

After successfully writing the file, inform the user:

✓ Design tokens written to [full-path]

To use these tokens in your project, import this file in your main CSS file or HTML:

In CSS:

@import url('path/​to/​tokens.css');

In HTML:

<link rel="stylesheet" href="path/​to/​tokens.css" />

The tokens are now available as CSS custom properties throughout your project (e.g., var(--color-primary), var(--size-16)).

Customization

These tokens provide a solid foundation but are meant to be customized for your project:

  • Adjust color values to match your brand
  • Modify the spacing scale to fit your design system
  • Add project-specific tokens as needed
  • Extend categories with additional tokens (animations, shadows, etc.)

This is a scaffolding skill - it sets up the initial structure but doesn't handle ongoing modifications.

Important Notes

  • Do NOT make assumptions about directory structure or filename if the user hasn't specified
  • Always confirm the location before writing
  • Create directories if needed and confirmed by user
  • The tokens file includes both light and dark mode color schemes using prefers-color-scheme
  • The oklch() color space provides perceptually uniform colors for better accessibility and consistency

More Design skills

brandkit logo
Design

brandkit

Premium brand-kit image generation for high-end identity systems, logo concepts, and visual-world presentations.

92.7K 345.8K
View

Premium website design-to-code skill that generates visual references first, then builds faithful frontend implementations.

92.7K 341.7K
View

Premium frontend image direction for landing pages and marketing sites, generating one distinct horizontal image per section.

92.7K 337.8K
View

Premium mobile app screen concepts and flows with clean hierarchy, strong imagery, and distinctive art direction.

92.7K 331.8K
View

Emil Kowalski's philosophy on UI polish, component design, and the invisible details that make software feel good.

43.5K 323.4K
View

Frontend design and iteration for production-grade interfaces, from concept to ship.

76.8K 313.3K
View

Reverse-engineer design tokens from public websites into starter token files for your project.

232 129.9K
View
Animate logo
Design

Animate

Builds an animation from scratch by making the decisions in the order that determines whether it feels right.

43.5K 117.9K
View

Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.

179.7K 114.2K
View

Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.

179.7K 100.1K
View

Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with colors/fonts that you can apply to any artifact that has been creating, or can generate a new theme on-the-fly.

179.7K 89.5K
View

Design AI tools

Maze Guru logo
Images

Maze Guru

Chat-to-edit AI studio for product photos, portraits, branding, and video.

Freemium
View
R
Design

RoomGPT

Generate your dream room in seconds.

Paid
View

Redesign your interior in seconds using AI

Paid
View
Reroom logo
Design

Reroom

Transform rooms with AI-generated designs.

Freemium
View
Jife logo
Design

Jife

Transform Your Space with AI-Powered Japanese Interior Designs by Jife

Paid
View
Visily logo
Design

Visily

AI-powered wireframes for non-designers.

Free
View

Revolutionize Property Viewing with AI-Generated Floor Plans and Virtual Tours

Paid
View
Archsynth logo
Design

Archsynth

Transform sketches into stunning architectural renders with AI.

Paid
View