Get your own website Result Size: 625 x 565
x
 
<!DOCTYPE html>
<html>
<head>
<style> 
#parentDIV {
  background-color:#FFFFFF;
  height:300px;
  position: relative;
  border: solid black 1px;
}
#myDIV {
  position: absolute;
  background-color:lightblue;
  inset: 10px 30px;
  animation: mymove 5s infinite;
}
@keyframes mymove {
  50% {inset: 40px 80px;}
}
</style>
</head>
<body>
<h1>Animation of inset</h1>
<p>Gradually change the inset from 10px 30px to 40px 80px, and back to 10px 30px:<p>
<div id="parentDIV">
  <div id="myDIV">
    This is my DIV element.
  </div>
</div>
</body>