There are only 5 countries in the World that won 5 or more medals at the World Cup. And their order in top 5 is very easy to agree on:
Brazil are first, because they won it 5 times. Germany are clear second, close to first. They played more WC finals than Brazil (8 vs 7) and won more medals than Brazil (12 vs 9), but won one gold medal less.
Italy are third. As many gold medals as the Germans, but less finals (6 vs 8) and less medals (7 vs 12).
Argentina are 4th. Three gold medals, 6 finals.
France are 5th. Two gold medals, as many as Uruguay, but many more finals (4 vs 2) and medals (6 vs 2).