CSS Property:
animation-direction:

Result:
CSS Code:
#myDIV {
  animation-direction:alternate;
}
Click the property values above to see the result
W3Schools.com - Play it