JSFiddle - React, Tailwind, and code Playground
by CreativeDreams
HTML
<section>
<input class="button" value="Submit Ticket" type="submit">
<button class="button">
Submit Ticket
</button>
</section>
SCSS
section {
display: flex;
justify-content: space-between;
width: 400px;
padding: 50px;
}
.button {
display: flex;
align-items: center;
position: relative;
height: 45px;
padding: 0 20px;
color: #fff;
font-size: 15px;
border: none;
appearance: none;
background: #1B62F6;
border-radius: 4px;
transition: transform 0.2s ease, background 0.2s ease;
&:before {
position: absolute;
z-index: -1;
content: '';
top: 0;
left: 0;
right: 0;
bottom: 0;
display: block;
border-radius: inherit;
opacity: 0;
box-shadow: 0px 8px 30px 0px #5635E9;
transition: opacity 0.2s ease;
}
&:hover {
background: #5635E9;
transform: translate3d(0, -3px, 0);
&:before {
opacity: 0.5;
}
}
}