Backup from main line through condensate drain
We recently had a new heat and air unit installed. Now we've got a main line backup that has flooded through the condensate drain pipe back into the unit.
I've attached a couple of pictures showing the drain pipe. The first picture shows the pipe coming out of the unit. From there it proceeds level, with a couple of turns, until the second picture, which shows it connecting with the drain pipe from the washer and dryer, I think.
I don't know anything about plumbing codes and was wondering what folks thought about this setup. It seems to me crazy to leave open the opportunity for water to flow straight back into the heat & air unit like that.