3/4 of these can't be proven or just iffy
1. Name recognition? So many movies that aren't based on a huge brand are still very successful or at least more successful than Shazam. Guardians of the Galaxy wasn't a huge name. True it had the MCU brand but that was back in 2014, where the brand was still big, but it's not like now. Alita grossed a little more than Shazam, Avatar wasn't tied to a major franchise. Helll even Iron Man 1 grossed more than Shazam and that was before Iron Man is who he is now. You don't need to be a big name brand franchise to be successful. Conversly you have something like Detective Pikachu or Man of Steel that are tied to massive franchises get outdone by "smaller" name franchises.
2. Again with the costume. There's no evidence that the costume affected anything. I get y'all don't like the costume, but it's an unproven point and just silly to bring up for why the movie underperformed.
3. Similar to the name brand stuff, star power doesn't mean much anymore in most cases. You have movies that star huge names like Will Smith, The Rock, RDJ, Chris Hemsworth, ScarJo who will lead these huge films and then their next movies flop or seriously underperform. This isn't like the 80s or 90s where movies will necessarily sell just based off the stars in it
4. This is it. This is the answer. The marketing was just not that great.
I think it was 1) the marketing 2) bad release date 3) I don't think the quality of the movie demanded people to run to the theaters.