R3 Digital Design System
A comprehensive design system built on HSL colors and Tailwind CSS v4 with semantic token extensions. This interface matches exactly with our design tokens and serves as the single source of truth for designers and developers.
🎨 Design System Architecture
HSL Color System
Semantic tokens like bg-surface-primary and text-content-secondary
Tailwind Foundation
Standard utilities like p-4, gap-6, and rounded-lg
Dual Approach
Choose semantic py-spacing-section OR Tailwind py-24
Figma ↔ Code Token Mapping
Use these exact token names in Figma to ensure seamless design-to-code handoffs. Each section below shows the complete mapping from Figma tokens to CSS classes.
Surface/Primarybg-surface-primary#171717Color System
Semantic color mappings between Figma and CSS following our design token specifications. Each color serves specific purposes and automatically adapts to light/dark contexts where appropriate.
Color System Architecture
HSL Color Format
Better browser compatibility
Simplified from previous OKLCH system
Contextual Colors
Content/Stroke colors adapt to context
Light/dark theme support built-in
Surface Colors
Background colors for different surfaces and components
Primary
Main dark backgrounds
bg-surface-primarySurface/Primary#171717bg-neutral-900Secondary
Secondary surfaces
bg-surface-secondarySurface/Secondary#262626bg-neutral-800Tertiary
Light grey surfaces
bg-surface-tertiarySurface/Tertiary#E5E5E5bg-neutral-200Light
White surfaces
bg-surface-lightSurface/Light#FFFFFFbg-whiteContent Colors
Text and content colors
Primary
Main text color
text-content-primaryContent/PrimaryContextualtext-neutral-900 (contextual)Secondary
Red emphasis text
text-content-secondaryContent/Secondary#DC2626text-red-500Inverse
Opposite of primary
text-content-inverseContent/InverseContextualtext-white (contextual)Muted
Muted grey text
text-content-mutedContent/Muted#737373text-neutral-500Interactive Colors
Colors for CTAs and interactive elements
Primary
Primary buttons/links
bg-interactive-primaryInteractive/Primary#DC2626bg-red-500Secondary
Secondary buttons
bg-interactive-secondaryInteractive/Secondary#262626bg-neutral-800Stroke Colors
Border and divider colors
Primary
Main borders
border-stroke-primaryStroke/PrimaryContextualborder-neutral-200 (contextual)Secondary
Red accent borders
border-stroke-secondaryStroke/Secondary#DC2626border-red-500Typography System
Typography mappings between Figma and code following the exact specifications from our design tokens. Use these exact names in Figma to ensure consistency and seamless design-to-code handoffs.
Typography Guidelines
Default Body Text
14px with 26px line-height
300 weight (light) for all body text
Responsive Scaling
Single breakpoint at 768px
All typography classes auto-scale
Weight System
Weight is implicit in the style purpose
No separate weight variants needed
Display/Titles
title-9xlHero XXLtext-8xl md:text-9xl font-boldtitle-8xlHero XLtext-7xl md:text-8xl font-boldtitle-5xlTitle Largetext-4xl md:text-5xl font-boldtitle-4xlTitle Mediumtext-3xl md:text-4xl font-boldtitle-3xlTitle Smalltext-2xl md:text-3xl font-boldtitle-2xlTitle Tinytext-xl md:text-2xl font-boldBody Content
text-introIntrotext-2xl md:text-3xl font-lighttext-body-xlBody XLtext-lg md:text-xl font-normaltext-quoteQuotetext-xl md:text-2xl font-mediumtext-quote-featuredQuote Featuredtext-2xl md:text-3xl font-mediumUI Elements
text-navigationNavigationtext-base font-boldtext-navigation-smallNavigation Smalltext-xs font-boldtext-buttonButton Texttext-sm font-boldtext-fieldField Texttext-sm font-normaltext-breadcrumbBreadcrumbtext-xs font-normalStandard Text
text-lgParagraph Largetext-lg font-normaltext-baseParagraphtext-sm font-normaltext-smParagraph Smalltext-xs font-normalContainer System
Container system with responsive gutters following our design tokens. Content containers use larger gutters (24px/64px) while navigation uses smaller gutters (16px/32px).
Container Guidelines
Mobile Gutters
24px content / 16px navigation
Desktop Gutters
64px content / 32px navigation
Breakpoint
768px (mobile to desktop)
Outer Container
Main layout container for full-width sections
container-outerContainer/Outer1500px
24px mobile, 64px desktop
Page sections, hero areas, full-width content
Inner Container
Content container for readable text width
container-innerContainer/Inner1180px
24px mobile, 64px desktop
Article content, forms, main content areas
Text Width
Optimal reading width for text content. Note: w-text is defined in CSS, or use max-w-[784px] with Tailwind
w-text or max-w-[784px]Text Width784px
Inherits from parent
Long-form content, articles, body text
Fluid Container
Full-width container with responsive gutters
container-fluidContainer/Fluid100%
24px mobile, 64px desktop
Full-width sections that need gutters
Navigation Container
Special container for navigation with smaller gutters
container-navContainer/Navigation1500px
16px mobile, 32px desktop
Navigation bars, headers
Outer Container (No Padding)
Outer container without any padding
container-outer-no-padContainer/Outer/NoPad1500px
None
Edge-to-edge content within outer bounds
Inner Container (No Padding)
Inner container without any padding
container-inner-no-padContainer/Inner/NoPad1180px
None
Edge-to-edge content within inner bounds, used inside container-outer
Gallery Scroll Container
Scrollable container that starts at content line but extends to viewport edge for overflow scrolling
gallery-scroll-containerContainer/Gallery/ScrollExtends to viewport edge
Left: aligns with 1180px content; Right: extends past container gutters
Horizontal scrolling galleries, carousels that need left content alignment with right overflow
Common Usage Patterns
<div className="container-outer">Use for full-width sections like heroes, footers, and major page divisions
<div className="container-inner max-w-text">Combine containers for optimal reading width within inner constraints
<nav className="container-nav">Special navigation container with specific gutter requirements
Spacing System
Spacing tokens that work with both semantic classes and standard Tailwind utilities. Choose the approach that best fits your workflow - semantic for design consistency or Tailwind for flexibility.
Semantic + Tailwind Approach
Semantic Classes (Recommended)
py-spacing-sectionUse semantic tokens for design system consistency
Tailwind Utilities (Alternative)
py-24Use standard Tailwind classes for flexibility
Section
Between major sections
spacing-sectionSection96px24 (py-24, gap-24)Between major sections
Component
Between components
spacing-componentComponent48px12 (gap-12, py-12)Between components
Card
Internal card padding
spacing-cardCard32px8 (p-8, gap-8)Internal card padding
Element
Between related elements
spacing-elementElement24px6 (gap-6, py-6)Between related elements
Compact
Compact layouts
spacing-compactCompact16px4 (gap-4, p-4)Compact layouts
Tight
Minimal spacing
spacing-tightTight8px2 (gap-2, py-2)Minimal spacing
How to Apply Spacing
Apply spacing using semantic tokens OR Tailwind equivalents:
Margin Top
mt-spacing-sectionApply spacing as top margin
Margin Bottom
mb-spacing-componentApply spacing as bottom margin
Padding Top
pt-spacing-cardApply spacing as top padding
Padding Bottom
pb-spacing-elementApply spacing as bottom padding
Gap
gap-spacing-compactApply spacing as flexbox/grid gap
Common Spacing Patterns
Semantic Approach
py-spacing-sectionMajor page sections (96px)
gap-spacing-elementRelated elements (24px)
p-spacing-cardCard interiors (32px)
Tailwind Approach
py-24Major page sections (96px)
gap-6Related elements (24px)
p-8Card interiors (32px)
Border Radius System
Consistent border radius values for different component types. Each radius serves specific UI patterns and maintains visual hierarchy across the design system.
Button/Input
Standard radius for interactive elements
rounded-buttonButton/Input6pxrounded-mdButtons and inputs
Card
Standard radius for content containers
rounded-cardCard8pxrounded-lgCards and panels
Modal
Larger radius for overlay elements
rounded-modalModal12pxrounded-xlModals and overlays
Border Radius Guidelines
Apply consistent border radius across components to maintain visual harmony:
Interactive Elements
rounded-button (6px)Buttons, form inputs, interactive controls
Content Containers
rounded-card (8px)Cards, content panels, grouped information
Overlay Elements
rounded-modal (12px)Modals, popovers, dropdown menus
Component Examples
Common UI components built with our design system tokens. These components automatically inherit semantic styling and maintain consistency across the application.
Primary Button
Main call-to-action buttons with semantic styling
Button/Primary<Button variant="default" size="default"> Get In Touch <ArrowRight className="h-4 w-4" /> </Button>
Secondary Button
Secondary actions with outline styling
Button/Secondary<Button variant="outline" size="default"> Download <Download className="h-4 w-4" /> </Button>
Ghost Button
Subtle actions with minimal styling
Button/Ghost<Button variant="ghost" size="default"> <Settings className="h-4 w-4" /> Settings </Button>
Card content with semantic typography and spacing.
Card Component
Standard content cards with proper spacing
Card/Standard<Card>
<CardHeader>
<CardTitle>Card Title</CardTitle>
</CardHeader>
<CardContent>
<p>Card content with semantic typography and spacing.</p>
</CardContent>
</Card>Badge Components
Status indicators and labels
Badge/Default<Badge variant="default">Default</Badge> <Badge variant="secondary">Secondary</Badge> <Badge variant="outline">Outline</Badge>
Design-to-Code Workflow
For Designers
- • Use tokens from this page as Figma variable names
- • Reference component variants shown here
- • Specify exact CSS classes in handoff specs
- • Maintain consistency with semantic naming
For Developers
- • Use semantic classes instead of arbitrary values
- • Reference this page for token availability
- • Extend components using design system patterns
- • Maintain token consistency in new components
Quick Reference
Colors
bg-surface-*text-content-*border-stroke-*Typography
title-*xltext-navigationfont-featuredLayout
container-outercontainer-innerw-textSpacing
spacing-sectionspacing-componentspacing-element