Dynamic Balance of the Head in a Flexible Legged Robot for Efficient Biped Locomotion