# Hugging Face DESIGN.md

> Public preview. The complete DESIGN.md source (all 123 design tokens, spacing, components and frontmatter) requires DesignMD Pro: https://www.designmdpro.app/pricing

The friendly, utilitarian design system behind the Hugging Face hub. Dense white directory pages pair Source Sans Pro with IBM Plex Mono metadata, rounded-8px hairline cards, and black pill CTAs — punctuated by a near-black hero panel, per-Space generated gradients, a soft "PRO" rainbow wash, and a literal hugging emoji as the brand mark.

- Website: https://huggingface.co
- Primary color: Blue `#3080FF`
- Fonts: Source Sans Pro, IBM Plex Mono, Charter
- Version: 1.0.0
- Details: https://www.designmdpro.app/websites/hugging-face

## Palette preview

- `primary`: `#3080ff`
- `surface`: `#ffffff`
- `tertiary`: `#fe6e00`
- `on-primary`: `#ffffff`
- `on-surface`: `#000000`
- `on-tertiary`: `#ffffff`
- `inverse-surface`: `#0b0f19`
- `surface-container`: `#f9fafb`

## Typography preview

- `body-lg`: Source Sans Pro
- `code-md`: IBM Plex Mono
- `serif-body`: Charter

---

## Overview

Hugging Face is the open hub of machine learning, and its design system is a **friendly utilitarian directory** — the visual equivalent of a well-run public library. Pages are white, dense, and information-first: Source Sans Pro text in literal black, IBM Plex Mono for stats and code, 8px-radius cards separated by the faintest `#F3F4F6` hairlines, and a single black pill as the universal primary action ("Sign Up", "Get Team").

What makes it unmistakably Hugging Face is the warmth layered onto the utility: the 🤗 emoji is the logo and section decoration, filter chips come in a dozen task colors, every Space card gets its **own generated gradient** cover (violet, teal, blue, pink — no two alike), the PRO tier glows with a soft 10%-alpha rainbow wash, and the homepage hero is a giant near-black (`#0B0F19`) billboard panel with 26px rounded corners. It is enterprise infrastructure wearing a smile.

## Colors

- **Primary — HF Blue (#3080FF):** links, "Most popular" pills, hover states, focused rings, and blue task accents. White text on solid fills.
- **Tertiary — Signal Orange (#FE6E00):** task-category icons, "new" badges, and warm accents across filter chips.
- **Brand accents:** **HF Yellow (#FFD236)** powers the emoji-gold PRO touches and gradient stops; **Inference Indigo (#625FFF)** marks inference/provider branding. Task chips cycle a wider Tailwind palette — pink `#F6339A`, teal `#00BAA7`, purple `#8D54FF`, green `#00BB7F`, red `#FB2C36`.
- **Surfaces:** white pages; `#F9FAFB`–`#F3F4F6` card washes and chip fills; pricing cards sit at `white/40` translucency over a `45.4deg` rainbow wash (`#F70059`→`#52FF00`→`#1400FF`→`#FF0000`→`#FFE600`, all ≈10% alpha) — the signature "gradient-rainbow" backdrop.
- **Ink:** pure `#000000` primary text (an unusually hard black), `#4A5565`/`#6A7282` secondary, `#99A1AF` placeholders, hairlines at `#E5E7EB` and `#F3F4F6`.
- **Inverse:** `#0B0F19` near-black for the hero billboard, dark preview mockups, and GitHub-adjacent code surfaces, with white text.
- **Space covers:** every Space card generates its own duotone gradient (observed violet→blue, emerald→teal, magenta→rose, slate→indigo) — treat `brand.indigo` as the flat fallback; white overlay text throughout.

## Typography

- **Source Sans Pro** carries the entire interface — from the 48px hero down to 12px metadata — in weights 400–700. Remarkably, page titles like "Models" set at just 18px/400 beside a huge stat count ("3,255,845"), trusting the data to do the talking.
- **Display (`display-hero` 48px/700, `display-lg` 48px/700 −0.025em):** white on the `#0B0F19` panel vs gray-900 on pricing ("Leveling up AI collaboration and compute."); scales to 60px at 2xl breakpoints.
- **Headlines (`headline-lg` 30px/700, `headline-md` 24px/600, `headline-sm` 20px/600):** section and card-group titles ("Spaces", "Community Blog & Articles").
- **Titles (`title-md` 16px/600):** model/dataset names — `moonshotai/Kimi-K2.5` rendered semibold in black, keeping the `org/name` slug readable.
- **Body (`body-md` 16px, `body-sm` 14px):** nav, descriptions, filter chips, plan features.
- **IBM Plex Mono (`code-md` 14px, `code-sm` 12px):** stats, prices, "PRO" tags, kbd hints (⌘K), and code — the engineering accent against the humanist sans.
- **Charter (`serif-body` 17px/1.65):** longform prose on the blog — a quiet serif reserved for reading.

## Layout

A 65px sticky header (logo + emoji, center search pill, icon-led nav, black "Sign Up") sits over a 1280px-centered page. The homepage opens with the dark billboard hero — hugging emoji, 48px headline, white outline pill CTA, and a live dark-mode preview of the Models directory — then flows into "Trending on 🤗 this week" card grids. Directory pages (Models/Datasets) split into a 224px filter sidebar (task chips, parameter sliders, library pickers) plus a list of 62px overview cards. Pricing uses a 3-column translucent-card layout over the rainbow wash; Spaces uses a 4-column cover grid under a 50px pill search bar ("Ask anything you want to do with AI"). Rhythm is a tight 4px base: 2px micro-gaps, 6–8px chip padding, 12px card spacing, 16px gutters, 24–32px section breaks.

## Elevation & Depth

**Nearly flat — hairlines over shadows.** Cards separate via 1px `#F3F4F6`–`#E5E7EB` borders; the default card shadow is a whisper (`0 1px 2px` black 5%). Inputs invert the depth: an inner `0 2px 4px` 5% inset shadow makes fields feel debossed. The only real lift belongs to search-style surfaces (`0 5px 5px`/`0 2px 2px`/`0 0 1px` at 3%) and Space covers (`0 1px 3px` 10%). Focus rings are HF-blue tinted; hover states lift cards into a faint `gray-50→white` gradient.

## Shapes

**Friendly rounding at every level, pills for actions.** The working radius is **8px** — cards, tabs, chips, dropdowns. Inputs stay at 8px in the header but inflate to a **50px full pill** on Spaces. Primary CTAs, badges, and kbd chips go `9999px` (the black "Sign Up" is a true capsule). Space covers round at 16px, the hero billboard at ~26px, and buttons inside plan cards at 12–14px. Nothing is sharp-cornered; even directory density stays soft.

## Motion & Micro-interaction

**150ms utility, with alive status indicators.** All chrome transitions run 150ms `cubic-bezier(0.4, 0, 0.2, 1)`; card hovers and transforms stretch to 300ms. "Running on ZERO" status chips pulse (2s `cubic-bezier(0.4,0,0.6,1)`), notifications ping (1s), and ambient marquee/orbit decorations run 6–13s loops. Hover micro-details abound: underline-offset animates, Space covers darken toward the corner, and the hero preview mockup is a live product capture, not a static render.

## Voice & Content Strategy

- **Tone:** warm, plainspoken, community-first — "The AI community building the future.", "The platform where the machine learning community collaborates on models, datasets, and applications." No hype adjectives; the numbers carry the credibility.
- **Capitalization:** sentence case; repo names keep `org/name` lowercase slugs; plan names in title case ("PRO Account", "Team", "Enterprise").
- **Terminology:** "models", "datasets", "Spaces" (never "apps" in product UI — though the subtitle allows "The AI App Directory"), "Inference Providers", "runs"/"downloads"/likes as the stats triplet.
- **Button labels:** short verbs — "Sign Up", "Get Team (via credit card)", "Talk to sales", "New Space", "Get PRO", "Explore AI Apps", "Browse 2M+ models".
- **Numbers:** compact counts ("96.2k", "1.42k", "2,555,000"), mono-set prices ("$9/month"), "Updated 2 days ago" relative timestamps.
- **Emoji as texture:** 🤗 is a first-class brand glyph — in the logo, headings ("Trending on 🤗 this week"), and user-generated titles; UI also sprinkles 🔥⚡✨🧩 freely.

## Components

### Buttons

`button-primary` is the black 36px capsule — white 14px label, generous x-padding ("Sign Up", "Get Team", "Talk to sales"). `button-outline` is the white bordered pill second ("New Space", "Learn more"). `button-hero` inverts to a white-on-dark outline capsule inside the billboard ("Explore AI Apps"). `button-pro` is the rainbow-washed pill — ink text over the mint→pink→yellow PRO gradient with a sparkle icon ("Get PRO"). `tab-active` is a tiny black 8px rounded toggle ("Main") for tab bars.

### Cards & chips

`card-model` is the directory row: white (fading to `gray-50` on hover), 1px `#F3F4F6` border, 8px radius, avatar + semibold repo name + icon-stat metadata row. `card-space` is a 16px-radius cover tile with a per-app duotone gradient, white title/description, and status pills ("Running on ✱ ZERO", "♥ 223"). `card-plan` is a translucent `white/40` pricing panel over the rainbow wash with mono price figures. `chip-filter` (gray-100, 28px, 8px radius, colored leading icon) fills sidebars; `badge-pill` (white, gray-200 border, 30px) labels sections like "🔥 Spaces of the week".

### Inputs & navigation

`input-search` is a 36px white field with `#E5E7EB` border, inset shadow, and a ⌘K kbd chip. `input-hero` is Spaces' 50px full-pill ask bar with a real drop shadow. `nav-header` is the 65px sticky bar — emoji logo + wordmark, icon+label links (Models/Datasets/Spaces/Buckets/Docs/Pricing), "Log In" ghost + black "Sign Up". `meta-mono` renders IBM Plex Mono stats in gray.

### Surfaces

`surface-hero` is the `#0B0F19` billboard (26px radius, white display type, embedded product mockup) — the homepage's anchor. Dark preview panels reuse it at smaller radii.

## Do's and Don'ts

- Do keep the interface black-and-white by default; let task colors, Space gradients, and the rainbow wash supply all the chroma.
- Do use the black pill for every primary action and 8px rounding for all data containers; reserve `9999px` for CTAs, badges, and kbd chips.
- Do set repo names semibold in `org/name` slug form and stats in IBM Plex Mono — never spell out "thousand" when "k" fits.
- Do treat 🤗 as a brand glyph — it can headline sections, but don't substitute generic emoji for it.
- Don't introduce drop shadows on directory cards; hairline borders plus the 5% whisper shadow is the entire elevation system.
- Don't use HF blue for fills beyond links, focus rings, and small pills — the rainbow gradient is the only multi-color surface.
- Do keep the PRO rainbow wash at ~10% alpha behind white content; saturated gradients belong to Space covers only.
- Don't round hero/billboard panels less than ~24px — the billboard's softness is the contrast to the dense grids below it.
- Do honor `prefers-reduced-motion` — the pulse/ping status loops and marquee drifts are decorative, not critical.
- Do keep sentence case and plain verbs; the brand voice is friendly documentation, not marketing copy.
