Loading…
Loading…
Design beautiful buttons with visual controls — export CSS, React JSX, or Tailwind classes.
.btn {
background-color: #7655a1;
color: #ffffff;
font-size: 16px;
font-weight: 600;
padding: 12px 24px;
border: none;
border-radius: 8px;
box-shadow: 0px 4px 14px 0px #7655a14d;
transition: all 200ms ease;
cursor: pointer;
display: inline-flex;
align-items: center;
justify-content: center;
}
.btn:hover {
background-color: #62428c;
color: #ffffff;
box-shadow: 0px 6px 20px 0px #7655a166;
transform: scale(1.02) translateY(-1px);
}
.btn:active {
transform: scale(0.98) translateY(0px);
}
.btn:focus-visible {
outline: 2px solid #7655a1;
outline-offset: 2px;
}
Common questions about the CSS Button Generator.
Start with padding, font-size, border-radius, and background-color. Add hover and active states for interactivity. This tool generates complete button styles with customizable size, shape, color, shadow, and animation — ready to copy into your CSS.
Good buttons have sufficient size (min 44×44px touch target), clear visual hierarchy (primary/secondary/ghost variants), obvious hover/active feedback, and accessible contrast (4.5:1 text-to-background). Use consistent border-radius and spacing across your UI.
Primary: solid background with white text. Secondary: lighter background or outline. Ghost: transparent with text color only. Use CSS custom properties for the color system so all variants stay consistent. This tool generates all three variants from a single base color.
Use <button> for actions (submit, toggle, open modal) and <a> for navigation (links to pages/URLs). This matters for accessibility — screen readers announce them differently, and keyboard behavior differs (Enter vs Enter+Space). Style both consistently but use the correct semantic element.
A review pass that strips the tells of generated UI — indigo gradients, emoji icons, three equal cards — and puts a point of view back in. The skill and a grep for the tells are below, ready to copy.
SkillsTurns a screen brief into a state inventory before anything is generated, then drives generation one state at a time and reports coverage. Lives inside the unhappy-paths guide.
WorkflowsA fixed order for checking interfaces a model built: foundations, then polish, then accessibility, then a headless screenshot pass.
PromptsTurns a vague 'this looks off' into a ranked table of concrete edits with the reason for each.