# UI/UX Design Expert Skill
## Activation Criteria
Activate this skill when the user:
- Requests creation of design systems or component libraries
- Asks for responsive layouts, mobile-first design, or cross-device interfaces
- Needs color schemes, typography pairing, or visual identity systems
- Requires accessibility compliance (WCAG 2.1, ARIA labels)
- Wants CSS/Tailwind implementations for UI components
- Requests Figma-to-code conversions or design token systems
- Needs dark mode implementation or theme switching
- Asks for animation, micro-interactions, or motion design
- Requires specific UI styles: glassmorphism, neumorphism, minimalism, brutalism
- Is building: web apps, dashboards, e-commerce sites, SaaS platforms, admin panels
- Needs CSS Grid, Flexbox, or modern layout mastery
## Core Methodology
### 1. Design System Foundation
#### Step 1: Define Design Tokens
Start with atomic design tokens that form the foundation of all visual decisions.
```css
/* Design Tokens - CSS Custom Properties */
:root {
/* Color Palette - Primary */
--color-primary-50: #eff6ff;
--color-primary-100: #dbeafe;
--color-primary-200: #bfdbfe;
--color-primary-300: #93c5fd;
--color-primary-400: #60a5fa;
--color-primary-500: #3b82f6;
--color-primary-600: #2563eb;
--color-primary-700: #1d4ed8;
--color-primary-800: #1e40af;
--color-primary-900: #1e3a8a;
/* Semantic Colors */
--color-success: #10b981;
--color-warning: #f59e0b;
--color-error: #ef4444;
--color-info: #3b82f6;
/* Neutral Scale */
--color-gray-50: #f9fafb;
--color-gray-100: #f3f4f6;
--color-gray-200: #e5e7eb;
--color-gray-300: #d1d5db;
--color-gray-400: #9ca3af;
--color-gray-500: #6b7280;
--color-gray-600: #4b5563;
--color-gray-700: #374151;
--color-gray-800: #1f2937;
--color-gray-900: #111827;
/* Typography Scale */
--font-family-base: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
--font-family-mono: 'SF Mono', Monaco, 'Cascadia Code', monospace;
/* Font Sizes - Type Scale (Major Third) */
--text-xs: 0.75rem; /* 12px */
--text-sm: 0.875rem; /* 14px */
--text-base: 1rem; /* 16px */
--text-lg: 1.125rem; /* 18px */
--text-xl: 1.25rem; /* 20px */
--text-2xl: 1.5rem; /* 24px */
--text-3xl: 1.875rem; /* 30px */
--text-4xl: 2.25rem; /* 36px */
--text-5xl: 3rem; /* 48px */
/* Spacing Scale (4px base unit) */
--spacing-1: 0.25rem; /* 4px */
--spacing-2: 0.5rem; /* 8px */
--spacing-3: 0.75rem; /* 12px */
--spacing-4: 1rem; /* 16px */
--spacing-5: 1.25rem; /* 20px */
--spacing-6: 1.5rem; /* 24px */
--spacing-8: 2rem; /* 32px */
--spacing-10: 2.5rem; /* 40px */
--spacing-12: 3rem; /* 48px */
--spacing-16: 4rem; /* 64px */
--spacing-20: 5rem; /* 80px */
/* Border Radius */
--radius-sm: 0.25rem;
--radius-md: 0.375rem;
--radius-lg: 0.5rem;
--radius-xl: 0.75rem;
--radius-2xl: 1rem;
--radius-full: 9999px;
/* Shadows */
--shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
--shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
--shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
--shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
/* Transitions */
--transition-fast: 150ms ease-in-out;
--transition-base: 200ms ease-in-out;
--transition-slow: 300ms ease-in-out;
/* Z-Index Scale */
--z-base: 0;
--z-dropdown: 1000;
--z-sticky: 1020;
--z-fixed: 1030;
--z-modal-backdrop: 1040;
--z-modal: 1050;
--z-popover: 1060;
--z-tooltip: 1070;
}
```
#### Tailwind Token Configuration
```javascript
// tailwind.config.js
module.exports = {
theme: {
extend: {
colors: {
primary: {
50: '#eff6ff',
100: '#dbeafe',
200: '#bfdbfe',
300: '#93c5fd',
400: '#60a5fa',
500: '#3b82f6',
600: '#2563eb',
700: '#1d4ed8',
800: '#1e40af',
900: '#1e3a8a',
},
},
fontFamily: {
sans: ['Inter', 'system-ui', 'sans-serif'],
mono: ['Fira Code', 'monospace'],
},
spacing: {
'18': '4.5rem',
'88': '22rem',
'128': '32rem',
},
animation: {
'fade-in': 'fadeIn 0.2s ease-in-out',
'slide-up': 'slideUp 0.3s ease-out',
'slide-down': 'slideDown 0.3s ease-out',
'scale-in': 'scaleIn 0.2s ease-out',
},
keyframes: {
fadeIn: {
'0%': { opacity: '0' },
'100%': { opacity: '1' },
},
slideUp: {
'0%': { transform: 'translateY(10px)', opacity: '0' },
'100%': { transform: 'translateY(0)', opacity: '1' },
},
slideDown: {
'0%': { transform: 'translateY(-10px)', opacity: '0' },
'100%': { transform: 'translateY(0)', opacity: '1' },
},
scaleIn: {
'0%': { transform: 'scale(0.95)', opacity: '0' },
'100%': { transform: 'scale(1)', opacity: '1' },
},
},
},
},
plugins: [
require('@tailwindcss/forms'),
require('@tailwindcss/typography'),
require('@tailwindcss/aspect-ratio'),
],
};
```
### 2. Typography Systems
#### Font Pairing Strategy
**Principle: Contrast without Conflict**
```css
/* Professional Pairing 1: Modern SaaS */
:root {
--font-heading: 'SF Pro Display', -apple-system, sans-serif;
--font-body: 'Inter', system-ui, sans-serif;
--font-mono: 'SF Mono', 'Fira Code', monospace;
}
/* Professional Pairing 2: Editorial */
:root {
--font-heading: 'Merriweather', Georgia, serif;
--font-body: 'Source Sans Pro', system-ui, sans-serif;
--font-mono: 'IBM Plex Mono', monospace;
}
/* Professional Pairing 3: Tech/Developer */
:root {
--font-heading: 'JetBrains Mono', monospace;
--font-body: 'Geist', 'SF Pro', system-ui, sans-serif;
--font-mono: 'Fira Code', monospace;
}
```
#### Typography Scale Implementation
```css
/* Type Scale with Responsive Adjustments */
.heading-1 {
font-size: clamp(2.5rem, 5vw + 1rem, 4rem);
font-weight: 700;
line-height: 1.1;
letter-spacing: -0.02em;
}
.heading-2 {
font-size: clamp(2rem, 4vw + 0.5rem, 3rem);
font-weight: 600;
line-height: 1.2;
letter-spacing: -0.01em;
}
.heading-3 {
font-size: clamp(1.5rem, 2vw + 0.5rem, 2rem);
font-weight: 600;
line-height: 1.3;
}
.body-large {
font-size: 1.125rem;
line-height: 1.7;
}
.body-base {
font-size: 1rem;
line-height: 1.6;
}
.body-small {
font-size: 0.875rem;
line-height: 1.5;
}
.caption {
font-size: 0.75rem;
line-height: 1.4;
color: var(--color-gray-500);
}
```
#### Tailwind Typography Implementation
```html
```
### 3. Color System Design
#### Color Theory Application
**Complementary Scheme for CTAs**
```css
/* High contrast for call-to-actions */
:root {
--color-action-primary: #2563eb; /* Blue */
--color-action-secondary: #10b981; /* Green complement */
}
```
**Analogous Scheme for Navigation**
```css
/* Harmonious navigation colors */
:root {
--color-nav-base: #3b82f6;
--color-nav-hover: #60a5fa;
--color-nav-active: #2563eb;
}
```
**Triadic Scheme for Status**
```css
/* Balanced status indicators */
:root {
--color-success: #10b981; /* Green */
--color-warning: #f59e0b; /* Orange */
--color-error: #ef4444; /* Red */
}
```
#### Dark Mode Implementation
```css
/* Dark mode color mapping */
@media (prefers-color-scheme: dark) {
:root {
--color-bg-primary: #111827;
--color-bg-secondary: #1f2937;
--color-bg-tertiary: #374151;
--color-text-primary: #f9fafb;
--color-text-secondary: #d1d5db;
--color-text-tertiary: #9ca3af;
--color-border: #374151;
}
}
/* Manual dark mode toggle support */
[data-theme="dark"] {
--color-bg-primary: #111827;
--color-bg-secondary: #1f2937;
--color-text-primary: #f9fafb;
/* ... additional mappings */
}
[data-theme="light"] {
--color-bg-primary: #ffffff;
--color-bg-secondary: #f9fafb;
--color-text-primary: #111827;
/* ... additional mappings */
}
```
#### Tailwind Dark Mode Strategy
```javascript
// tailwind.config.js
module.exports = {
darkMode: 'class', // or 'media'
theme: {
extend: {},
},
};
```
```html
Adaptive Heading
Responsive to theme changes
```
### 4. Component Library Design
#### Button Component System
```css
/* Base Button */
.button {
display: inline-flex;
align-items: center;
justify-content: center;
gap: var(--spacing-2);
padding: var(--spacing-3) var(--spacing-6);
font-size: var(--text-sm);
font-weight: 500;
line-height: 1;
border-radius: var(--radius-md);
border: 1px solid transparent;
cursor: pointer;
transition: all var(--transition-base);
}
/* Button Variants */
.button-primary {
background-color: var(--color-primary-600);
color: white;
box-shadow: var(--shadow-sm);
}
.button-primary:hover {
background-color: var(--color-primary-700);
box-shadow: var(--shadow-md);
}
.button-primary:active {
transform: translateY(1px);
}
.button-secondary {
background-color: white;
color: var(--color-gray-700);
border-color: var(--color-gray-300);
}
.button-secondary:hover {
background-color: var(--color-gray-50);
border-color: var(--color-gray-400);
}
.button-ghost {
background-color: transparent;
color: var(--color-gray-700);
}
.button-ghost:hover {
background-color: var(--color-gray-100);
}
/* Button Sizes */
.button-sm {
padding: var(--spacing-2) var(--spacing-4);
font-size: var(--text-xs);
}
.button-lg {
padding: var(--spacing-4) var(--spacing-8);
font-size: var(--text-base);
}
/* Button States */
.button:disabled {
opacity: 0.5;
cursor: not-allowed;
pointer-events: none;
}
.button-loading {
position: relative;
color: transparent;
}
.button-loading::after {
content: '';
position: absolute;
width: 1rem;
height: 1rem;
border: 2px solid currentColor;
border-top-color: transparent;
border-radius: 50%;
animation: spin 0.6s linear infinite;
}
@keyframes spin {
to { transform: rotate(360deg); }
}
```
#### Tailwind Button Component
```html
```
#### Form Component System
```css
/* Input Component */
.input {
width: 100%;
padding: var(--spacing-3) var(--spacing-4);
font-size: var(--text-base);
line-height: 1.5;
color: var(--color-gray-900);
background-color: white;
border: 1px solid var(--color-gray-300);
border-radius: var(--radius-md);
transition: all var(--transition-base);
}
.input:hover {
border-color: var(--color-gray-400);
}
.input:focus {
outline: none;
border-color: var(--color-primary-500);
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}
.input:disabled {
background-color: var(--color-gray-100);
color: var(--color-gray-500);
cursor: not-allowed;
}
/* Error State */
.input-error {
border-color: var(--color-error);
}
.input-error:focus {
border-color: var(--color-error);
box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}
/* Input with Label */
.form-group {
display: flex;
flex-direction: column;
gap: var(--spacing-2);
}
.form-label {
font-size: var(--text-sm);
font-weight: 500;
color: var(--color-gray-700);
}
.form-label-required::after {
content: ' *';
color: var(--color-error);
}
.form-hint {
font-size: var(--text-xs);
color: var(--color-gray-500);
}
.form-error {
font-size: var(--text-xs);
color: var(--color-error);
}
```
#### Tailwind Form Components
```html
```
### 5. Layout Systems
#### CSS Grid Mastery
```css
/* Responsive Grid System */
.grid-container {
display: grid;
gap: var(--spacing-6);
}
/* Two Column Layout */
.grid-two {
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
/* Three Column Layout */
.grid-three {
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
/* Dashboard Grid */
.dashboard-grid {
display: grid;
grid-template-columns: 240px 1fr 300px;
grid-template-rows: auto 1fr auto;
grid-template-areas:
"header header header"
"sidebar main aside"
"footer footer footer";
min-height: 100vh;
gap: var(--spacing-6);
}
.dashboard-header { grid-area: header; }
.dashboard-sidebar { grid-area: sidebar; }
.dashboard-main { grid-area: main; }
.dashboard-aside { grid-area: aside; }
.dashboard-footer { grid-area: footer; }
/* Card Grid */
.card-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
gap: var(--spacing-6);
}
@media (max-width: 768px) {
.dashboard-grid {
grid-template-columns: 1fr;
grid-template-areas:
"header"
"main"
"aside"
"sidebar"
"footer";
}
}
```
#### Tailwind Grid Implementation
```html
```
#### Flexbox Patterns
```css
/* Center Alignment */
.flex-center {
display: flex;
align-items: center;
justify-content: center;
}
/* Space Between */
.flex-space-between {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--spacing-4);
}
/* Vertical Stack */
.flex-stack {
display: flex;
flex-direction: column;
gap: var(--spacing-4);
}
/* Horizontal Scroll */
.flex-scroll {
display: flex;
gap: var(--spacing-4);
overflow-x: auto;
scroll-snap-type: x mandatory;
-webkit-overflow-scrolling: touch;
}
.flex-scroll > * {
scroll-snap-align: start;
flex-shrink: 0;
}
```
### 6. Responsive Design
#### Mobile-First Breakpoints
```css
/* Mobile-First Breakpoint Scale */
/* Base: Mobile First (0px+) */
/* Small: 640px+ */
@media (min-width: 640px) {
.container {
max-width: 640px;
}
}
/* Medium: 768px+ */
@media (min-width: 768px) {
.container {
max-width: 768px;
}
}
/* Large: 1024px+ */
@media (min-width: 1024px) {
.container {
max-width: 1024px;
}
}
/* XLarge: 1280px+ */
@media (min-width: 1280px) {
.container {
max-width: 1280px;
}
}
/* 2XLarge: 1536px+ */
@media (min-width: 1536px) {
.container {
max-width: 1536px;
}
}
```
#### Tailwind Responsive Utilities
```html
Responsive Heading
Content
Desktop Only
Mobile Only
```
### 7. Design Styles
#### Glassmorphism
```css
/* Glassmorphism Effect */
.glass {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
-webkit-backdrop-filter: blur(10px);
border: 1px solid rgba(255, 255, 255, 0.2);
border-radius: var(--radius-xl);
}
.glass-dark {
background: rgba(0, 0, 0, 0.2);
backdrop-filter: blur(10px);
-webkit-backdrop-filter: blur(10px);
border: 1px solid rgba(255, 255, 255, 0.1);
}
/* Tailwind Implementation */
Glassmorphism Card
```
#### Neumorphism
```css
/* Neumorphism (Soft UI) */
.neu-flat {
background: #e0e5ec;
border-radius: var(--radius-xl);
box-shadow:
20px 20px 60px #bebebe,
-20px -20px 60px #ffffff;
}
.neu-pressed {
background: #e0e5ec;
border-radius: var(--radius-xl);
box-shadow:
inset 20px 20px 60px #bebebe,
inset -20px -20px 60px #ffffff;
}
/* Tailwind Implementation */
Neumorphic Element
```
#### Minimalism
```css
/* Minimalist Design */
.minimal {
background: white;
border: none;
box-shadow: none;
padding: var(--spacing-6);
color: var(--color-gray-900);
}
.minimal-text {
font-family: var(--font-body);
font-weight: 400;
line-height: 1.6;
letter-spacing: 0;
}
```
#### Brutalism
```css
/* Brutalist Design */
.brutalist {
background: var(--color-primary-600);
color: white;
border: 4px solid black;
box-shadow: 8px 8px 0 black;
padding: var(--spacing-6);
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.brutalist-button {
background: var(--color-warning);
border: 3px solid black;
box-shadow: 4px 4px 0 black;
transition: none;
}
.brutalist-button:hover {
transform: translate(2px, 2px);
box-shadow: 2px 2px 0 black;
}
.brutalist-button:active {
transform: translate(4px, 4px);
box-shadow: none;
}
/* Tailwind Implementation */
```
### 8. Accessibility (WCAG 2.1)
#### Semantic HTML Structure
```html
Section Title
Article Title
Article content...
```
#### ARIA Labels and Roles
```html
Search for products by name or SKU
.sr-only {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
white-space: nowrap;
border-width: 0;
}
```
#### Keyboard Navigation
```css
/* Focus Visible Indicator */
*:focus-visible {
outline: 2px solid var(--color-primary-600);
outline-offset: 2px;
}
/* Skip Link */
.skip-link {
position: absolute;
top: -40px;
left: 0;
background: var(--color-primary-600);
color: white;
padding: var(--spacing-2) var(--spacing-4);
z-index: 9999;
}
.skip-link:focus {
top: 0;
}
/* Tab Order */
.tab-trigger {
cursor: pointer;
}
.tab-trigger[aria-selected="true"] {
background: var(--color-primary-600);
color: white;
}
```
#### Color Contrast Standards
```css
/* Minimum Contrast Ratios (WCAG 2.1) */
/* AA: 4.5:1 for normal text, 3:1 for large text */
/* AAA: 7:1 for normal text, 4.5:1 for large text */
/* Example - Pass AA */
.text-primary {
color: #2563eb; /* On white: 7.5:1 */
}
.text-secondary {
color: #4b5563; /* On white: 5.74:1 */
}
/* Example - Fail AA */
.text-fail {
color: #9ca3af; /* On white: 2.85:1 - FAIL */
}
```
### 9. Animation Principles
#### Micro-interactions
```css
/* Hover Animation */
.hover-lift {
transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.hover-lift:hover {
transform: translateY(-4px);
box-shadow: var(--shadow-lg);
}
/* Focus Animation */
.focus-ring {
transition: box-shadow var(--transition-base);
}
.focus-ring:focus {
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}
/* Loading Animation */
.spinner {
width: 40px;
height: 40px;
border: 4px solid var(--color-gray-200);
border-top-color: var(--color-primary-600);
border-radius: 50%;
animation: spin 1s linear infinite;
}
@keyframes spin {
to { transform: rotate(360deg); }
}
/* Pulse Animation */
.pulse {
animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
@keyframes pulse {
0%, 100% {
opacity: 1;
}
50% {
opacity: 0.5;
}
}
```
#### Tailwind Animations
```html
Content fades in
Content slides up
Hover to scale
```
### 10. Design Patterns
#### Card Component
```css
.card {
background: white;
border-radius: var(--radius-lg);
box-shadow: var(--shadow-md);
padding: var(--spacing-6);
transition: all var(--transition-base);
}
.card:hover {
box-shadow: var(--shadow-lg);
transform: translateY(-2px);
}
.card-header {
display: flex;
align-items: center;
gap: var(--spacing-4);
margin-bottom: var(--spacing-4);
}
.card-title {
font-size: var(--text-lg);
font-weight: 600;
color: var(--color-gray-900);
}
.card-body {
color: var(--color-gray-600);
line-height: 1.6;
}
.card-footer {
display: flex;
gap: var(--spacing-2);
margin-top: var(--spacing-6);
}
```
#### Modal Component
```css
.modal-backdrop {
position: fixed;
inset: 0;
background: rgba(0, 0, 0, 0.5);
backdrop-filter: blur(4px);
z-index: var(--z-modal-backdrop);
animation: fadeIn 0.2s ease-out;
}
.modal {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background: white;
border-radius: var(--radius-xl);
box-shadow: var(--shadow-xl);
z-index: var(--z-modal);
max-width: 500px;
width: 90%;
max-height: 90vh;
overflow: auto;
animation: scaleIn 0.2s ease-out;
}
.modal-header {
display: flex;
align-items: center;
justify-content: space-between;
padding: var(--spacing-6);
border-bottom: 1px solid var(--color-gray-200);
}
.modal-body {
padding: var(--spacing-6);
}
.modal-footer {
display: flex;
gap: var(--spacing-3);
justify-content: flex-end;
padding: var(--spacing-6);
border-top: 1px solid var(--color-gray-200);
}
```
#### Navigation Component
```css
.navbar {
display: flex;
align-items: center;
justify-content: space-between;
padding: var(--spacing-4) var(--spacing-6);
background: white;
border-bottom: 1px solid var(--color-gray-200);
position: sticky;
top: 0;
z-index: var(--z-sticky);
}
.navbar-brand {
font-size: var(--text-xl);
font-weight: 700;
color: var(--color-primary-600);
}
.navbar-menu {
display: flex;
gap: var(--spacing-6);
}
.navbar-link {
color: var(--color-gray-600);
text-decoration: none;
font-weight: 500;
transition: color var(--transition-fast);
}
.navbar-link:hover,
.navbar-link.active {
color: var(--color-primary-600);
}
```
### 11. Dashboard Design
#### Dashboard Layout Pattern
```css
.dashboard {
display: grid;
grid-template-columns: 260px 1fr;
min-height: 100vh;
}
.dashboard-sidebar {
background: var(--color-gray-900);
color: white;
padding: var(--spacing-6);
}
.dashboard-main {
background: var(--color-gray-50);
padding: var(--spacing-6);
}
.stat-card {
background: white;
padding: var(--spacing-6);
border-radius: var(--radius-lg);
box-shadow: var(--shadow-sm);
}
.stat-value {
font-size: var(--text-3xl);
font-weight: 700;
color: var(--color-gray-900);
}
.stat-label {
font-size: var(--text-sm);
color: var(--color-gray-600);
margin-top: var(--spacing-2);
}
```
#### Tailwind Dashboard
```html
```
### 12. E-commerce Design
#### Product Card Pattern
```css
.product-card {
background: white;
border-radius: var(--radius-lg);
box-shadow: var(--shadow-sm);
overflow: hidden;
transition: all var(--transition-base);
}
.product-card:hover {
box-shadow: var(--shadow-lg);
transform: translateY(-4px);
}
.product-image {
width: 100%;
aspect-ratio: 1;
object-fit: cover;
}
.product-info {
padding: var(--spacing-4);
}
.product-name {
font-size: var(--text-base);
font-weight: 600;
color: var(--color-gray-900);
margin-bottom: var(--spacing-2);
}
.product-price {
font-size: var(--text-lg);
font-weight: 700;
color: var(--color-primary-600);
}
.product-button {
width: 100%;
margin-top: var(--spacing-4);
}
```
### 13. Decision Trees
#### Layout Selection
```
Need to arrange content?
│
├─ Single column? → Flex column
├─ Two columns? → Grid 2 cols
├─ Three+ columns? → Grid auto-fit
├─ Complex dashboard? → Grid with named areas
└─ Horizontal scroll? → Flex with overflow
```
#### Component Style Selection
```
What's the product type?
│
├─ SaaS/B2B → Minimalism, clean borders
├─ E-commerce → Card-based, clear CTAs
├─ Creative portfolio → Glassmorphism, bold colors
├─ Developer tools → Brutalism, monospace
└─ Healthcare → Clean, high contrast, accessible
```
#### Color Scheme Selection
```
What's the brand personality?
│
├─ Trustworthy → Blue primary
├─ Energetic → Orange/Yellow primary
├─ Natural → Green primary
├─ Luxury → Black/Gold or Purple
└─ Playful → Multicolor, gradients
```
### 14. Anti-Patterns to Avoid
1. **Magic Numbers**: Never use arbitrary pixel values. Use spacing scale.
2. **Hard-coded Colors**: Never use hex codes directly. Use design tokens.
3. **Missing Focus States**: Always provide keyboard navigation indicators.
4. **Poor Contrast**: Always test contrast ratios (minimum 4.5:1).
5. **Infinite Scrolling without Pagination**: Provide alternative navigation.
6. **Tiny Touch Targets**: Buttons minimum 44x44px for mobile.
7. **Missing Loading States**: Always provide feedback for async actions.
8. **Inconsistent Spacing**: Use spacing scale consistently.
9. **Overriding Accessibility**: Never remove native accessibility features.
10. **Blocking Mobile**: Always design mobile-first.
### 15. Quality Checklist
Before delivery, verify:
- [ ] All colors use design tokens (no hardcoded hex)
- [ ] Typography follows type scale
- [ ] Spacing uses spacing scale
- [ ] All interactive elements have hover/focus/active states
- [ ] All images have alt text or are decorative
- [ ] Color contrast meets WCAG AA (4.5:1 minimum)
- [ ] Keyboard navigation works for all interactive elements
- [ ] Focus indicators are visible
- [ ] Forms have proper labels and error messages
- [ ] Loading states provided for async actions
- [ ] Responsive design tested on mobile/tablet/desktop
- [ ] Dark mode preserves contrast and readability
- [ ] Animations have `prefers-reduced-motion` support
- [ ] Touch targets minimum 44x44px on mobile
- [ ] Semantic HTML used (headings, landmarks, lists)
- [ ] ARIA labels provided where needed
- [ ] Z-index follows defined scale
- [ ] Border radius consistent within component
- [ ] Shadows follow defined scale
- [ ] Transitions follow timing standards
### 16. Quick Reference
#### Tailwind Common Patterns
```html