Organize CSS using BEM, SMACSS, and CSS-in-JS patterns. Use when building scalable, maintainable styling systems with proper naming conventions.
Build maintainable CSS systems using methodologies like BEM (Block Element Modifier), SMACSS, and CSS-in-JS patterns with proper organization and conventions.
Minimal working example:
/* Block - standalone component */
.button {
display: inline-block;
padding: 10px 20px;
border: none;
border-radius: 4px;
cursor: pointer;
font-size: 16px;
transition: all 0.3s ease;
}
/* Element - component part */
.button__icon {
margin-right: 8px;
vertical-align: middle;
}
/* Modifier - variant */
.button--primary {
background-color: #007bff;
color: white;
}
.button--primary:hover {
background-color: #0056b3;
// ... (see reference guides for full implementation)
Detailed implementations in the references/ directory:
| Guide | Contents | |---|---| | BEM (Block Element Modifier) Pattern | BEM (Block Element Modifier) Pattern | | SMACSS (Scalable and Modular Architecture for CSS) | SMACSS (Scalable and Modular Architecture for CSS) | | CSS-in-JS with Styled Components | CSS-in-JS with Styled Components | | CSS Variables (Custom Properties) | CSS Variables (Custom Properties) | | Utility-First CSS (Tailwind Pattern) | Utility-First CSS (Tailwind Pattern) |
Copy a source-pinned command for your client. You run it yourself.
Destination: .claude/skills/css-architecture · pinned to the source commit
git clone https://github.com/aj-geddes/useful-ai-prompts.git
cd useful-ai-prompts
git checkout 3f5182cfd739fc113f4af5244a1cf342ad7f7911
mkdir -p ".claude/skills/css-architecture"
cp -r "skills/css-architecture" ".claude/skills/css-architecture"Review the source before running. This copies files into your project; it is not a one-click install and does not verify runtime safety.
Scanner static-checks@0.1.0 · commit 3f5182cfd739. Static checks cannot prove runtime safety – review the source and the exact diff before installing. How checks work.
No static rules matched. This is not a safety guarantee.