CSS3 Transition Ease in and out Box Shadow
This could work:
#how-to-content-wrap-first:hover{
box-shadow : inset 0 1px 1px rgba(0,0,0,.075);
-webkit-transition : box-shadow ease-in-out .15s;
transition : box-shadow ease-in-out .15s;
}
You need to use transitions on .class
and not .class:hover
div {
height: 200px;
width: 200px;
box-shadow: 0;
transition: box-shadow 1s;
border: 1px solid #eee;
}
div:hover {
box-shadow: 0 0 3px #515151;
;
}
<div></div>
Here is a resource-efficient solution
#how-to-content-wrap-first::after{
/* Pre-render the bigger shadow, but hide it */
box-shadow: 3px 3px 5px -1px #80aaaa;
opacity: 0;
transition: opacity 0.3s ease-in-out;
}
#how-to-content-wrap-first:hover::after {
/* Transition to showing the bigger shadow on hover */
opacity: 1;
}