The decline of the DCEU films at the box office started with Shazam!, and only escalated from there. BoP came out a month before lockdowns, and its low OW numbers were a shock to pretty much everyone.
All in all, I think the DCEU’s decline was a result of it not having any real sense of direction. There was no big event for people to get hyped about, and the movies themselves didn’t look exciting enough for the average moviegoer to rush to see them. It doesn’t help that they kept playing coy about the fact that Henry Cavill was fired because Toby Emmerich didn’t like the guy, and didn’t have any real concrete plan on how they were going to replace him.