Yeah..I can't think of any foolproof solution, but you'd think that if they are going to allow two 3rd place teams, then two of the group winners should play them. I mean..Mexico wins Brazil's group, but Brazil gets a third place team in the QFs and Mexico gets a second place team. I would have the group winner with the worst record play against a 2nd place team and let the other two first place teams play against the 2 third place teams. The last quarter final will then be between two 2nd place teams..
Think that seems more fair