Loading...
Loading...
Modern CSS techniques that replace breakpoint ladders, wrapper elements and scripts. Use whenever you write, edit or review styles in any form, including plain CSS, Tailwind classes, StyleX, CSS-in-JS and inline styles, and whenever you build or restyle a page or component, even if the user never mentions CSS.
npx skill4agent add vojtaholik/good-css good-cssinlineblockmbs-pe-inset-bs-mt-pr-top-oklch()nonecolor-mix(in oklch, …)clamp():hover@media (hover: hover) and (pointer: fine):focus-visibleoutlineoutline: none:active@media (prefers-reduced-motion: no-preference)allease-inoverflow: cliphidden| Read | Before you write |
|---|---|
| a reset or base stylesheet, a set of color tokens, dark mode, a type or spacing scale |
| a page container or wrapper, a grid of cards, cards whose parts line up, a sidebar, a component placed in slots of different widths, overlapping layers, centered content that can overflow |
| spacing between sections, elements stacked one above another, one item pushed to the far end of a row or column, nested rounded corners |
| text or images that come from a user or a CMS, such as names, titles, excerpts, thumbnails, avatars and embeds, an icon next to a label, a label that looks off-center, numbers in a column |
| the focus, hover and press states of a button, link, input or card, a small tap target, a clickable card, form validation, a textarea, a parent styled by what it contains, page scroll locked behind a modal |
| easing and duration tokens, one state change that drives several values, a shadow that changes on hover, a transition between pages, the indicator under an active tab |
| a dialog, popover, dropdown menu or accordion |
| a carousel, a row that may overflow, a modal body, chat list or drawer that scrolls between a header and a footer, in-page links under a sticky header, an app shell on desktop or on a phone |
text-box*text-rendering: optimizeLegibilitydisplay: contentsreferences/foundations.mdSupport:animatereview-animationsimprove-animationsfind-animation-opportunitiesmobile-native