Lionel Messi recovered from an earlier penalty miss to lead the fightback, scoring one goal and setting up another when his team needed him most.