Refs cost Miami the lead