<div class="container">
  <button class="button" type="button">
  マウスホバーしても<br>transitionが効かない
</button>
</div>
.container {
  width: 100%;
  height: 300px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.button {
  background-image: linear-gradient(to left, #7f7fd5, #86a8e7, #91eae4);
  border: none;
  cursor: pointer;
  appearance: none;
  position: relative;
  color: #fff;
  font-size: 24px;
  padding: 16px 24px;
  border-radius: 30px;
  font-weight: bold;
  transition: 0.5s;
}

.button:hover {
  background-image: linear-gradient(to right, #4169e1, #87ceeb);
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.