Skip to main content
This guide provides complete Tailwind CSS configuration for implementing the Paper UI design system across MetaCogna Suite applications.

Overview

Paper UI requires custom Tailwind configuration to support:
  • Semantic color tokens (Ink, Paper, Surface, Accent)
  • Hard shadows (4px 4px 0px 0px)
  • Typography system (Serif, Sans-Serif, Monospace)
  • Border radius constraints (max 2px)
  • Dark mode support
The recommended approach uses CSS custom properties for better dark mode support and easier theme management.

HTML Setup

Tailwind CDN Configuration

For CDN-based setups (current MetaCogna.ai Landing approach):

Standard Tailwind Config File Approach

For projects using standard Tailwind configuration files:

tailwind.config.js

CSS File (e.g., src/index.css or styles.css)

Color System

Paper UI Color Tokens

Additional Accent Variants

Typography

Font Families

Paper UI uses three distinct typefaces:

Font Loading

Include in HTML <head>:

Shadows

Hard Shadows

Paper UI uses hard, non-blurred shadows to create physical depth:
  • shadow-hard: 4px 4px 0px 0px rgb(var(--color-shadow)) - Default card shadow
  • shadow-hard-sm: 2px 2px 0px 0px rgb(var(--color-shadow)) - Small elements
  • shadow-hard-lg: 6px 6px 0px 0px rgb(var(--color-shadow)) - Hover states
  • shadow-hard-hover: 6px 6px 0px 0px rgb(var(--color-shadow)) - Interactive hover

Usage

Border Radius

Paper UI uses minimal border radius (max 2px) for “hard edges”:

Animations

Custom Animations (Optional)

Dark Mode Setup

Toggle Implementation

CSS Background Pattern

Optional dot pattern background:

Migration Guide

From Direct Color Values

Before:
After:

From Standard Shadows

Before:
After:

Adding Dark Mode

  1. Add CSS custom properties for dark mode
  2. Configure darkMode: 'class' in Tailwind config
  3. Use semantic color tokens instead of direct colors
  4. Test all components in both light and dark modes

Current Application Status

MetaCogna RAG

  • Status: Uses CDN Tailwind with inline config
  • Dark Mode: Not implemented
  • Migration: Needs CSS custom properties approach

MetaCogna.ai Landing

  • Status: Uses CDN Tailwind with CSS custom properties ✅
  • Dark Mode: Fully implemented ✅
  • Migration: Already follows recommended approach

Parti Architecture

  • Status: Uses CDN Tailwind with basic config
  • Dark Mode: Unknown
  • Migration: Needs CSS custom properties and dark mode

Best Practices

  1. Always use semantic tokens: bg-paper, text-ink, border-ink
  2. Never use direct colors: Avoid bg-white, text-zinc-900
  3. Test dark mode: Ensure all components work in both themes
  4. Use CSS custom properties: Best approach for theme switching
  5. Consistent shadows: Always use shadow-hard variants
  6. Minimal border radius: Max 2px except for circles