Search⌘ K

Pulsating Call-to-Action Button

Explore how to create an animated call-to-action button using CSS. Learn to apply padding, colors, and rounded corners, then define keyframes to produce a gentle pulsating scale animation. This lesson helps you enhance UI elements with smooth, infinite animations using only CSS, improving your design and coding skills.

Problem description

Given an HTML page containing a <button class="cta-button">Click Me</button> element, write CSS to:

  • Style the button with padding, background color, text color, no border, and rounded corners.

  • Define a @keyframes ...