1---2name: accessibility-design3description: SKILL — Accessibility Design4---5# SKILL — Accessibility Design67Pixel's accessibility knowledge. Accessibility is not optional — it is a baseline requirement for every design.89---1011## Visual Accessibility1213### Contrast Ratios (WCAG AA)14| Element | Minimum Ratio | Example |15|---------|---------------|---------|16| Normal text (< 18px) | 4.5:1 | Body text, labels, captions |17| Large text (≥ 18px bold or ≥ 24px regular) | 3:1 | Headings, display text |18| UI components & graphical objects | 3:1 | Borders, icons, form controls |19| Focus indicators | 3:1 | Focus rings, outlines |20| Placeholder text | 4.5:1 | Input placeholder (should still be legible) |2122### Color Independence23- **Never use color alone to convey information** — Always pair color with text, icon, or pattern24- Error states: Red border + error icon + error message text25- Status indicators: Color + label text (not just a colored dot)26- Charts: Color + pattern/shape + labels for each data series27- Links: Color + underline (or other non-color indicator)2829### Text Readability30- Minimum 16px for body text31- Sufficient line height (1.5 for body text)32- Maximum line length of 80 characters33- No text embedded in images (unless decorative)34- Avoid thin font weights (100-200) — especially on dark backgrounds3536### Visual Indicators37- Focus rings: 2px solid with 2px offset, high-contrast color38- Selection state: Background change + checkmark/icon (not just color)39- Active/current state: Bold weight or underline + color change40- Disabled state: Reduced opacity (0.5) + cursor change4142---4344## Touch/Click Accessibility4546### Touch Target Sizes47| Platform | Minimum | Recommended |48|----------|---------|-------------|49| iOS | 44pt × 44pt | 48pt × 48pt |50| Android | 48dp × 48dp | 48dp × 48dp |51| Web (desktop) | 24px × 24px | 32px × 32px |52| Web (touch) | 44px × 44px | 48px × 48px |5354### Touch Target Rules551. **Invisible padding counts** — A 24px icon with 12px padding per side = 48px target562. **Adjacent targets need spacing** — Minimum 8px gap between touchable elements573. **Don't rely on precision** — Thumbs are imprecise. Large targets prevent errors.584. **Consistent target sizing** — All items in a list should have the same tap area5960### Keyboard Navigation61- All interactive elements must be keyboard-focusable62- Tab order follows visual reading order (left-to-right, top-to-bottom)63- Enter/Space activates buttons and links64- Arrow keys navigate within components (tabs, menus, radio groups)65- Escape closes modals, dropdowns, popovers66- Skip-to-content link as the first focusable element6768---6970## Screen Reader Design7172### Semantic Structure73- Proper heading hierarchy (H1 → H2 → H3, never skip levels)74- Landmarks: `<header>`, `<nav>`, `<main>`, `<aside>`, `<footer>`75- Lists (`<ul>`, `<ol>`) for groups of related items76- Tables with `<th>` headers for tabular data77- Form labels associated with inputs (`<label for="...">`)7879### ARIA Labels80- Icon-only buttons need `aria-label` (e.g., close button: `aria-label="Close"`)81- Images need `alt` text (decorative images: `alt=""`)82- Dynamic content updates: `aria-live="polite"` for non-urgent, `aria-live="assertive"` for urgent83- Custom components need appropriate ARIA roles and states84- Loading states: `aria-busy="true"` on the loading container8586### Content Design for Screen Readers87- Link text should describe the destination (not "click here")88- Button text should describe the action (not "submit" — use "Create Account")89- Form error messages should reference which field has the error90- Announce dynamic content changes (toast notifications, form validation)91- Table caption to describe what data the table contains9293---9495## Motion & Animation9697### prefers-reduced-motion98- **All animations must respect `prefers-reduced-motion: reduce`**99- When reduced motion is preferred: instant transitions, no parallax, no auto-playing video100- Essential motion (a progress bar filling) can remain but should not loop or bounce101- Decorative motion (hover effects, page transitions, background animations) should stop102103### Animation Guidelines104- Maximum animation duration: 300ms for micro-interactions, 500ms for transitions105- Avoid flashing content (nothing should flash more than 3 times per second)106- No auto-playing carousels or content that moves without user initiation107- Provide pause/stop controls for any continuous animation108- Scroll-triggered animations should have reduced-motion alternatives109110### Motion Principles111- Motion should explain spatial relationships (where did this come from?)112- Motion should provide feedback (did my action work?)113- Motion should guide attention (look here next)114- Motion should NOT be decorative, distracting, or required to understand the UI115116---117118## Cognitive Accessibility119120### Reduce Cognitive Load121- One primary action per screen/section122- Clear, simple language (no jargon unless domain-specific)123- Consistent patterns — same action looks and works the same everywhere124- Predictable navigation — users always know where they are and how to go back125- Error recovery — clear instructions on how to fix mistakes126127### Content Structure128- Headings organize content into scannable sections129- Short paragraphs (3-4 sentences max)130- Bulleted lists for multiple related items131- Visual grouping through spacing and borders132- Clear labels (not clever labels — "Settings" not "The Workshop")133134### Form Accessibility135- Clear labels for every field (never placeholder-only)136- Expected format shown as helper text ("MM/DD/YYYY")137- Error messages explain what's wrong AND how to fix it138- Don't rely on time limits (or provide generous extensions)139- Auto-save or confirm before clearing long forms140141### Information Density142- Progressive disclosure — show summary first, details on demand143- Don't overwhelm — prioritize the most important information144- Provide context — "3 of 10" not just "3"145- Use familiar metaphors and patterns146- Avoid ambiguous icons — pair with labels when uncertain