mobile-responsive
Skill2 starsChanged 6 months agoMITView on GitHub
This skill should be used whenever the agent creates, edits, reviews, or debugs any web UI such as pages, components, layouts, sections, forms, navs, cards, tables, or modals. It guarantees the output is mobile-friendly and responsive across the full range of devices (small phones at 320px through large desktops), prevents horizontal overflow, and makes the result look intentional and beautiful rather than merely "not broken". It also enforces visual consistency: new UI must match the spacing, type, breakpoints, and component patterns already in the project, and remain coherent with components added later. Trigger on phrases like "make this responsive", "mobile friendly", "works on phones", "fix the layout on mobile", "it's overflowing", "looks broken on small screens", or any request to build/style web UI where no responsive behavior was specified. Use it proactively whenever generating new web markup.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- ominou5/funnel-architect-plugintheir own version, first seen Feb 26, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- ominou5/funnel-architect-plugin★ 86same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 8 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 24
Every piece of web UI this skill touches must (1) work flawlessly from 320px to large desktop, (2) never overflow horizontally, (3) look …
- Distinctive: line 34
Before writing or changing any UI, read what already exists so new work blends in instead of clashing.
- Very specific: line 52
If tailwind.config, a theme file, or a design-tokens file exists, read it.
- Distinctive: line 57
Write base styles for the smallest screen with no breakpoint prefix and
- Distinctive: line 61
Use the conventions from Step 0 for every spacing, size, and breakpoint value.
- Very specific: line 76
After building, mentally (or with scripts/check-overflow.js) confirm zero horizontal scroll at every width in the device matrix below.
- Very specific: line 90
Protect whitespace: Add responsive horizontal padding (px-4 md:px-8) so content never kisses the edge.
- Very specific: line 96
Order matters: Use order-* / flex-col-reverse so the most important thing (usually the headline or primary CTA) comes first on mobile.
- Very specific: line 120
Mobile-first, min-width only: Avoid max-width queries except for genuine desktop-only behavior.
- Distinctive: line 122
Match the existing system: Never add a new CSS framework or a parallel spacing/type scale.
- Very specific: line 124
Relative units: Prefer rem / % / fr / vw / minmax / clamp over fixed px.
- Distinctive: line 126
No overflow, ever: Treat horizontal scroll as a bug to be fixed at the source.
- Distinctive: line 127
Beautiful by default: If a quick fix is ugly, do the slightly larger fix that looks intentional.
- Distinctive: line 129
Stay in scope: Don't restyle components the user didn't ask about, but do make sure your new component is consistent with them.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Mobile Responsive
Every piece of web UI this skill touches must (1) work flawlessly from 320px to large desktop, (2) never overflow horizontally, (3) look deliberately designed, and (4) stay visually consistent with the rest of the project, both past and future.
Work mobile-first: the base, unprefixed styles target the smallest screen, then you add complexity upward. Never start from desktop and shrink down.
Step 0: Learn the project's conventions first (do not skip)
Before writing or changing any UI, read what already exists so new work blends in instead of clashing. Beautiful and consistent beats clever and isolated.
- Find sibling components in the same directory/feature. Read two or three of them.
- Extract the conventions they already follow:
- Styling system (Tailwind, CSS Modules, styled-components, plain CSS, Bootstrap, etc.). Match it, and never introduce a second one.
- Spacing scale actually in use (e.g. only
4 / 8 / 16 / 24 / 32, or Tailwind'sgap-2 gap-4 gap-6). Reuse the same steps. - Type scale (the specific sizes/weights used for headings vs body).
- Breakpoints already chosen (
sm md lg, or custom values). Use the same set, and don't invent new breakpoints. - Color/spacing design tokens or theme variables. Use the tokens, never hard-coded hex/px that duplicates a token.
- Container/max-width and horizontal-padding pattern used by surrounding sections.
- Component structure conventions (how props/variants/slots are named).
- Match them. A new card should feel like it shipped in the same release as
the old cards. If the project has no convention yet, establish a clean one
(see
references/design-consistency.md) and apply it consistently so future components have a pattern to follow.
If tailwind.config, a theme file, or a design-tokens file exists, read it.
That is the source of truth for spacing, breakpoints, and colors.
Step 1: Build and fix, mobile-first
- Write base styles for the smallest screen with no breakpoint prefix and no media query.
- Layer larger-screen behavior on top using min-width breakpoints only
(Tailwind
sm: md: lg:are min-width; in CSS use@media (min-width: ...)). - Use the conventions from Step 0 for every spacing, size, and breakpoint value.
Step 2: Guarantee no overflow (hard requirement)
Horizontal scroll on mobile is a defect, never acceptable. Prevent it at the source. Most common causes, with fixes:
- Fixed widths become
w-full max-w-[Npx](Tailwind) orwidth:100%; max-width:Npx. - Flex children that won't shrink get
min-w-0(andtruncateon text that should ellipsis). - Wide media: all
img/video/iframe/svggetmax-w-full h-auto. - Long unbroken strings/URLs get
break-words/overflow-wrap: anywhere. - Fixed-width tables: wrap in
overflow-x-autoso the table scrolls, not the page. - Negative margins /
100vw:100vwincludes the scrollbar and overflows, so preferw-full. - Absolute/translated elements poking past the edge: clip with
overflow-hiddenon a sized parent.
After building, mentally (or with scripts/check-overflow.js) confirm zero
horizontal scroll at every width in the device matrix below. Full deep-dive in
references/overflow-prevention.md.
Step 3: Make it beautiful, not just functional
Responsive doesn't mean squished. Aim for layouts that look composed at every size.
- Reflow, don't just shrink. Multi-column grids collapse to fewer columns or
a single stack on mobile (
grid-cols-1 sm:grid-cols-2 lg:grid-cols-3), rather than keeping cramped columns. - Fluid type. Headings scale with
clamp()or responsive utilities so they don't dwarf small screens (text-2xl md:text-4xl). - Protect whitespace. Add responsive horizontal padding (
px-4 md:px-8) so content never kisses the edge; scale gaps down on mobile (gap-4 md:gap-8). - Touch targets of about 44px or larger on interactive elements (
min-h-11, real padding). - Honor reading width. Cap body text line length (
max-w-prose/ ~65ch). - Hide vs. transform. Collapse desktop navs into a toggle below
md; don't just let them wrap into a mess. - Order matters. Use
order-*/flex-col-reverseso the most important thing (usually the headline or primary CTA) comes first on mobile.
Step 4: Verify across the full device range
A layout isn't "mobile responsive" because it survives one phone width. Walk it across the matrix:
| Width | Represents |
| 320px | Smallest phones, the stress test |
| 375px | Standard phone |
| 414px | Large phone |
| 768px | Tablet portrait |
| 1024px | Tablet landscape / small laptop |
| 1280px | Desktop |
| 1440px+ | Large desktop |
At each one: no horizontal scroll, no clipped/overlapping content, readable type, tappable controls, intact alignment with neighboring sections. Then state in one or two sentences what you changed and why. Do not touch unrelated code.
Rules
- Mobile-first, min-width only. Avoid
max-widthqueries except for genuine desktop-only behavior. - Match the existing system. Never add a new CSS framework or a parallel spacing/type scale. Reuse tokens and conventions (Step 0).
- Relative units. Prefer
rem / % / fr / vw / minmax / clampover fixedpx; never set fixed pixel heights on containers with variable content. - No overflow, ever. Treat horizontal scroll as a bug to be fixed at the source.
- Beautiful by default. If a quick fix is ugly, do the slightly larger fix that looks intentional.
- Stay in scope. Don't restyle components the user didn't ask about, but do make sure your new component is consistent with them.
Reference files (read on demand)
references/breakpoints.md: breakpoint values, device matrix, container queries, fluid type.references/overflow-prevention.md: every overflow cause, fix, and debugging technique.references/design-consistency.md: extracting and matching a project's design language; building a token system when none exists.references/frameworks.md: stack-specific syntax (Tailwind, plain CSS, CSS Modules, styled-components, Bootstrap, Flutter web).
Quick example
Before (fixed width, desktop-only, will overflow on phones):
<div className="flex w-[960px] gap-8 p-10">
<img src="/hero.png" width="600" />
<div>
<h1 className="text-5xl">Welcome</h1>
<p>Some long description...</p>
</div>
</div>After (fluid, stacks on mobile, no overflow, scales nicely, reuses the project's spacing steps):
<div className="flex flex-col md:flex-row w-full max-w-[960px] gap-4 md:gap-8 px-4 py-6 md:p-10">
<img src="/hero.png" className="w-full md:max-w-[600px] h-auto rounded-lg" />
<div className="min-w-0">
<h1 className="text-3xl md:text-5xl">Welcome</h1>
<p className="max-w-prose break-words">Some long description...</p>
</div>
</div>Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

