mobile-first-design

Designs responsive interfaces starting from mobile screens with progressive enhancement for larger devices. Use when building responsive websites, optimizing for mobile users, or implementing adaptive layouts.

⭐9stars🔀0forks📁View on GitHub🕐Updated Jan 1, 2026⬇️1downloads

When & Why to Use This Skill

This Claude skill provides a comprehensive framework for Mobile-First Design, enabling the creation of responsive and high-performance web interfaces. It streamlines the development process by offering standardized CSS breakpoints, touch-friendly UI patterns, and progressive enhancement techniques. By prioritizing mobile screens and optimizing for performance, it ensures a seamless user experience across all devices while improving SEO rankings and accessibility.

Use Cases

  • Building a responsive website from scratch using a mobile-first CSS architecture to ensure fast loading on mobile networks.
  • Optimizing existing web layouts for better mobile usability by implementing touch-friendly targets and adequate spacing.
  • Implementing progressive enhancement strategies to ensure core content is accessible on all browsers before adding complex styles or scripts.
  • Defining and implementing consistent media query breakpoints for seamless transitions between mobile, tablet, and desktop views.
  • Ensuring web performance targets are met by following specific JS bundle and page weight requirements for mobile users.
namemobile-first-design
descriptionDesigns responsive interfaces starting from mobile screens with progressive enhancement for larger devices. Use when building responsive websites, optimizing for mobile users, or implementing adaptive layouts.

Mobile-First Design

Design interfaces starting with mobile as the foundation, then enhance for larger screens.

Breakpoints

Name Width Devices
Mobile 320-480px iPhone SE, small Android
Tablet 481-768px iPad mini
Desktop 769-1024px iPad Pro, laptops
Large 1025px+ Desktop monitors

Mobile-First CSS

/* Base styles (mobile) */
.container {
  padding: 1rem;
}

.nav {
  display: none; /* Hidden on mobile */
}

.nav-toggle {
  display: block; /* Hamburger visible */
}

/* Tablet and up */
@media (min-width: 768px) {
  .container {
    padding: 2rem;
    max-width: 720px;
    margin: 0 auto;
  }

  .nav {
    display: flex;
  }

  .nav-toggle {
    display: none;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .container {
    max-width: 960px;
  }
}

Touch-Friendly Design

/* Minimum touch target: 48x48px */
.button {
  min-height: 48px;
  min-width: 48px;
  padding: 12px 24px;
}

/* Adequate spacing */
.list-item {
  padding: 16px;
  margin-bottom: 8px;
}

Performance Requirements

Metric Target
First Contentful Paint <3s on 3G
JS bundle <100KB gzipped
Total page weight <500KB

Progressive Enhancement

<!-- Layer 1: Semantic HTML (works without CSS/JS) -->
<nav>
  <a href="/home">Home</a>
  <a href="/about">About</a>
</nav>

<!-- Layer 2: CSS enhances appearance -->
<!-- Layer 3: JS adds interactivity -->

Best Practices

  • Start design at 320px width
  • Use relative units (rem, %, vw)
  • Test on real devices
  • Optimize images for mobile
  • Minimize JavaScript for initial load
  • Ensure readable text without zooming