It's a fine example of the potentially counter-intuitive 'Law of Comparative Advantage' [1]
[1] https://en.wikipedia.org/wiki/Comparative_advantage