CSSTransitions

Transitions create smooth animations between style changes. Instead of instantly switching from one style to another, a transition gradually changes it over a specified time. This makes interactions look polished and modern. You can animate properties like color, background, or position. For example, a button can smoothly change its background color when hovered over, making the website feel more professional and user-friendly.

button { transition: background 0.3s; }
button:hover { background: teal; }