<style>img {
margin-top:10px;
margin-left:10px;
transition: width 1s , height 1s ;
-moz-transition: width 1s, height 1s;
-webkit-transition: width 1s, height 1s;
-o-transition: width 1s, height 1s;
width: 140px;
height: 90px;
box-shadow: 0px 0px 10px black;
border-radius: 5px;
animation:myfirst 0.5s infinite;
-moz-animation:myfirst 0.5s infinite;
-webkit-animation:myfirst 0.5s infinite;
}
img:hover {
box-shadow: 0px 0px 10px black;
width: 400px ;
height: 240px ;
box-shadow: 0px 0px 10px black;
border-radius: 5px;
}
</style>