Frontend Responsive Design Standards
Build responsive, mobile-first layouts using fluid containers, flexible units, media queries, and touch-friendly design that works across all screen sizes. Use this skill when creating or modifying UI layouts, responsive grids, breakpoint styles, mobile navigation, or any interface that needs to adapt to different screen sizes. Apply when working with responsive CSS, media queries, viewport settings, flexbox/grid layouts, mobile-first styling, breakpoint definitions (mobile, tablet, desktop), touch target sizing, relative units (rem, em, %), image optimization for different screens, or testing layouts across multiple devices. Use for any task involving multi-device support, responsive design patterns, or adaptive layouts.
What this skill does
# Frontend Responsive Design Standards
**Rule:** Mobile-first development with consistent breakpoints, fluid layouts, relative units, and touch-friendly targets.
## When to use this skill
- When creating or modifying layouts that need to work on mobile, tablet, and desktop
- When implementing mobile-first design patterns starting with mobile layout
- When writing media queries or breakpoint-specific styles
- When using flexible units (rem, em, %) instead of fixed pixels for scalability
- When implementing fluid layouts with percentage-based widths or flexbox/grid
- When ensuring touch targets meet minimum size requirements (44x44px) for mobile
- When optimizing images and assets for different screen sizes and mobile networks
- When testing UI across multiple device sizes and breakpoints
- When maintaining readable typography across all screen sizes
- When prioritizing content display on smaller screens through layout decisions
- When using responsive design utilities in CSS frameworks (Tailwind, Bootstrap responsive classes)
This Skill provides Codex with specific guidance on how to adhere to coding standards as they relate to how it should handle frontend responsive.
## Mobile-First Development - Mandatory
**Always start with mobile layout, then enhance for larger screens.**
Bad (desktop-first):
```css
.container {
width: 1200px;
display: grid;
grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 768px) {
.container {
width: 100%;
grid-template-columns: 1fr;
}
}
```
Good (mobile-first):
```css
.container {
width: 100%;
display: grid;
grid-template-columns: 1fr;
}
@media (min-width: 768px) {
.container {
grid-template-columns: repeat(2, 1fr);
}
}
@media (min-width: 1024px) {
.container {
max-width: 1200px;
grid-template-columns: repeat(4, 1fr);
}
}
```
**Why mobile-first:**
- Forces content prioritization
- Better performance on mobile (no overriding)
- Progressive enhancement over graceful degradation
## Standard Breakpoints
**Identify and use project breakpoints consistently:**
Common breakpoint systems:
Tailwind:
```
sm: 640px (small tablets)
md: 768px (tablets)
lg: 1024px (laptops)
xl: 1280px (desktops)
2xl: 1536px (large desktops)
```
Bootstrap:
```
sm: 576px
md: 768px
lg: 992px
xl: 1200px
xxl: 1400px
```
**Check existing codebase for breakpoint definitions before creating new ones.**
Usage (Tailwind):
```jsx
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4">
```
Usage (CSS):
```css
@media (min-width: 768px) { }
@media (min-width: 1024px) { }
```
**Never use arbitrary breakpoints like 850px or 1150px unless explicitly required.**
## Fluid Layouts
**Use flexible containers that adapt to screen size:**
Bad (fixed widths):
```css
.container { width: 1200px; }
.sidebar { width: 300px; }
.content { width: 900px; }
```
Good (fluid):
```css
.container {
width: 100%;
max-width: 1200px;
padding: 0 1rem;
}
.layout {
display: grid;
grid-template-columns: 1fr;
}
@media (min-width: 1024px) {
.layout {
grid-template-columns: 300px 1fr;
}
}
```
**Patterns for fluid layouts:**
- Flexbox: `flex: 1`, `flex-grow`, `flex-shrink`
- Grid: `1fr`, `minmax()`, `auto-fit`, `auto-fill`
- Percentage widths: `width: 100%`, `max-width: 1200px`
- Container queries (modern): `@container (min-width: 400px)`
## Relative Units Over Fixed Pixels
**Use rem/em for scalability and accessibility:**
Bad:
```css
font-size: 16px;
padding: 20px;
margin: 10px;
border-radius: 8px;
```
Good:
```css
font-size: 1rem; /* 16px base */
padding: 1.25rem; /* 20px */
margin: 0.625rem; /* 10px */
border-radius: 0.5rem; /* 8px */
```
**When to use each unit:**
- `rem`: Font sizes, spacing, layout dimensions (scales with root font size)
- `em`: Component-relative sizing (scales with parent font size)
- `%`: Widths, heights relative to parent
- `px`: Borders (1px), shadows, very small values
- `vw/vh`: Full viewport dimensions, hero sections
- `ch`: Text-based widths (e.g., `max-width: 65ch` for readable line length)
**Framework utilities handle this automatically:**
```jsx
<div className="text-base p-5 m-2.5 rounded-lg">
```
## Touch-Friendly Design
**Minimum touch target size: 44x44px (iOS) / 48x48px (Android)**
Bad:
```css
.icon-button {
width: 24px;
height: 24px;
}
```
Good:
```css
.icon-button {
width: 24px;
height: 24px;
padding: 12px; /* Total: 48x48px */
/* Or use min-width/min-height */
min-width: 44px;
min-height: 44px;
}
```
**Touch target checklist:**
- [ ] Buttons minimum 44x44px
- [ ] Links in text have adequate spacing
- [ ] Form inputs have sufficient height (min 44px)
- [ ] Icon buttons have padding for larger hit area
- [ ] Spacing between interactive elements (min 8px)
## Readable Typography
**Maintain readable font sizes without zoom:**
Bad:
```css
body { font-size: 12px; }
.small-text { font-size: 10px; }
```
Good:
```css
body { font-size: 1rem; } /* 16px minimum */
.small-text { font-size: 0.875rem; } /* 14px minimum */
```
**Typography guidelines:**
- Body text: 16px (1rem) minimum
- Small text: 14px (0.875rem) minimum
- Line height: 1.5 for body, 1.2 for headings
- Line length: 45-75 characters (use `max-width: 65ch`)
- Contrast: WCAG AA minimum (4.5:1 for normal text)
Responsive typography:
```css
h1 {
font-size: 2rem;
}
@media (min-width: 768px) {
h1 {
font-size: 2.5rem;
}
}
@media (min-width: 1024px) {
h1 {
font-size: 3rem;
}
}
```
Or with clamp (fluid):
```css
h1 {
font-size: clamp(2rem, 5vw, 3rem);
}
```
## Content Priority on Mobile
**Show most important content first, hide or collapse secondary content:**
Bad:
```jsx
<div>
<Sidebar /> {/* Full sidebar on mobile */}
<MainContent />
</div>
```
Good:
```jsx
<div className="flex flex-col lg:flex-row">
<MainContent className="order-1" />
<Sidebar className="order-2 hidden lg:block" />
</div>
```
**Strategies:**
- Hide non-essential elements on mobile
- Use hamburger menus for navigation
- Collapse accordions/tabs for secondary content
- Stack layouts vertically on mobile
- Use `order` property to reorder content
## Image Optimization
**Serve appropriate images for device size:**
Bad:
```html
<img src="hero-4000x3000.jpg" alt="Hero">
```
Good:
```html
<img
src="hero-800x600.jpg"
srcset="
hero-400x300.jpg 400w,
hero-800x600.jpg 800w,
hero-1600x1200.jpg 1600w
"
sizes="(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 800px"
alt="Hero"
>
```
Or with modern formats:
```html
<picture>
<source srcset="hero.avif" type="image/avif">
<source srcset="hero.webp" type="image/webp">
<img src="hero.jpg" alt="Hero">
</picture>
```
**Framework-specific:**
```jsx
// Next.js
<Image
src="/hero.jpg"
width={800}
height={600}
sizes="(max-width: 768px) 100vw, 50vw"
alt="Hero"
/>
```
## Testing Across Devices
**Verify layouts at key breakpoints before completing work:**
Test checklist:
- [ ] Mobile (375px - iPhone SE)
- [ ] Mobile large (414px - iPhone Pro Max)
- [ ] Tablet (768px - iPad)
- [ ] Laptop (1024px)
- [ ] Desktop (1440px)
**Testing methods:**
1. Browser DevTools responsive mode
2. Real device testing (iOS/Android)
3. Browser extensions (Responsive Viewer)
4. Automated visual regression tests
**Common issues to check:**
- Horizontal scrolling on mobile
- Text overflow or truncation
- Overlapping elements
- Unreadable font sizes
- Touch targets too small
- Images not loading or distorted
## Common Responsive Patterns
**Navigation:**
```jsx
// Mobile: Hamburger menu
// Desktop: Horizontal nav
<nav className="lg:flex lg:items-center">
<button className="lg:hidden">Menu</button>
<ul className="hidden lg:flex lg:gap-4">
<li>Home</li>
<li>About</li>
</ul>
</nav>
```
**Grid layouts:**
```css
.grid {
display: grid;
grid-template-columns: 1fr;
gap: 1rem;
}
@media (min-width: 640px) {
.grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
.grid { gridRelated in Design
contribute
IncludedLocal-only OSS contribution command center. Auto-refreshes the user's in-flight PR and issue state on invoke so conversations start with full context — no need to brief Claude on what's in flight. Helps the user find issues to contribute to on GitHub, builds per-repo dossiers of what each upstream expects (CLA, DCO, branch convention, AI policy, draft-first, review bots, issue templates), runs deterministic gates before any external action so AI-assisted contributions don't reach maintainers as slop. State is markdown-only: candidate files at ~/.contribute-system/candidates/, repo dossiers at ~/.contribute-system/research/, append-only event log at ~/.contribute-system/log.jsonl. No database, no cloud calls. Use when the user asks about their PRs / issues / contributions, wants to find new work to take on, claim an issue, build/refresh a repo's dossier, or draft a Design Issue or PR. Trigger with "/contribute", "what's my PR status", "find a contribution", "claim issue X", "draft a Design Issue for Y", "refresh dossier for Z".
architectural-analysis
IncludedUser-triggered deep architectural analysis of a codebase or scoped subtree across eight modes — information architecture, data flow, integration points, UI surfaces, interaction patterns, data model, control flow, and failure modes. This skill should be used when the user asks to "diagram this codebase," "map the architecture," "show the data flow," "give me an ERD," "trace control flow," "find the integration points," "verify the layout pattern," "audit the UX architecture," or any similar request whose primary deliverable is mermaid diagrams plus cited reports under docs/architecture/. Dispatches haiku/sonnet sub-agents in parallel for per-mode exploration, then verifies every citation mechanically before any node lands in a diagram. Not for one-off prose explanations of code (use code-explanation) or for high-level system design from scratch (use system-design).
mcp
IncludedModel Context Protocol (MCP) server development and tool management. Languages: Python, TypeScript. Capabilities: build MCP servers, integrate external APIs, discover/execute MCP tools, manage multi-server configs, design agent-centric tools. Actions: create, build, integrate, discover, execute, configure MCP servers/tools. Keywords: MCP, Model Context Protocol, MCP server, MCP tool, stdio transport, SSE transport, tool discovery, resource provider, prompt template, external API integration, Gemini CLI MCP, Claude MCP, agent tools, tool execution, server config. Use when: building MCP servers, integrating external APIs as MCP tools, discovering available MCP tools, executing MCP capabilities, configuring multi-server setups, designing tools for AI agents.
react-native-skia
IncludedDesign, build, debug, and optimise high-polish animated graphics in React Native or Expo using @shopify/react-native-skia, Reanimated, and Gesture Handler. Use when the user wants canvas-driven UI, shaders, paths, rich text, image filters, sprite fields, Skottie, video frames, snapshots, web CanvasKit setup, or performance tuning for custom motion-heavy elements such as loaders, hero art, cards, charts, progress indicators, particle systems, or gesture-driven surfaces. Also use when the user asks for fluid, glow, glass, blob, parallax, 60fps/120fps, or GPU-friendly animated effects in React Native, even if they do not explicitly say "Skia". Do not use for ordinary form/layout work with standard views.
plaid
IncludedProduct Led AI Development — guides founders from idea to launched product. Six capabilities: Idea (discover a product idea), Validate (pressure-test the idea against fatal flaws, problem reality, competition, and 2-week MVP feasibility), Plan (vision intake + document generation), Design (translate image references into a design.md spec), Launch (go-to-market strategy), and Build (roadmap execution). Use when someone says "PLAID", "plaid idea", "help me find an idea", "product idea", "idea from my business", "idea from my expertise", "plaid validate", "validate my idea", "pressure-test", "is this idea good", "find fatal flaws", "validate the problem", "plan a product", "define my vision", "generate a PRD", "product strategy", "plaid design", "design from image", "translate image to design", "create design.md", "extract design tokens", "plaid launch", "go-to-market", "launch plan", "GTM strategy", "launch playbook", "plaid build", "build the app", "start building", or "execute the roadmap".
nextjs-framer-motion-animations
IncludedAdds production-safe Motion for React or Framer Motion animations to Next.js apps, including reveal, hover and tap micro-interactions, whileInView, stagger, AnimatePresence, layout and layoutId transitions, reorder, scroll-linked UI, and lightweight route-content transitions. Use when the user asks to add, refactor, or debug Motion or Framer Motion in App Router or Pages Router codebases, especially around server/client boundaries, reduced motion, LazyMotion, bundle size, hydration, or route transitions. Avoid for GSAP-style timelines, WebGL or 3D scenes, heavy scroll storytelling, or CSS-only effects unless Motion is explicitly requested.