Interedge magnetic coupling in transition-metal terminated graphene nanoribbons