Structure of the hexameric HerA ATPase reveals a mechanism of translocation-coupled DNA-end processing in archaea