Excel interprets the #N/A as an error even if it is entered as text. So, =L1="#N/A" will produce a #N/A result not a TRUE result. For Conditional Formatting to work it has to result in a TRUE result. Use this instead for your Conditional Formatting to deal with the #N/A.
=IFNA(L1,TRUE)
Here is a screenshot showing the formula adjusted for E2 looking at L2.