You have to think in USD value of the pair rather than futures levels.
The USD value is the futures level multiplied by the point value of the future
To calculate your P&L, you simply deduct the sale value of the 'pair' from the purchase value of the 'pair'.
Example:
If you bought ESM8 at 2,800 / sold NQM8 at 7,200 and exited this trade at levels of 2,801 and 7,199 respectively, your profit would be calculated as follows:
Sale value of the pair: (2,801 * 50) - (7,199 * 20) = (140,050)-(143,980) = -3,930
Purchase value of the pair: (2,800 * 50) - (7,200 * 20) = (140,000)-(144,000) = -4,000
P&L = (-3,930) - (-4000) = 70
I hope this helps.