As someone who went altogether too far down the 40k setting rabbit hole for too many years, I'm happy to give my read on this--not in an attempt to serve some sort of Devil's Advocate role or anything, but largely to provide some... underlying extratextual context, I suppose?
See, the thing about the setting of 40k is that it's a failed state. That it leans into "the most totalitarian state imaginable" as "the good guys (by comparison to everyone else on offer)" isn't so much, on a more critical level, an endorsement of totalitarianism so much as it is a lament for the setting's loss and failure on a level of humanitarian and scientific advancement. The standard boilerplate intro to every Imperium-based work in the 40k setting includes the following touchstone phrase:
If anything, I see that as the guiding principle of the universe: the Imperium is a failed state, crumbling under its own weight, constrained by its own massive inertia. It is a worst case survival scenario.
SO, how does 30k and the Horus Heresy tie into that? 30k ties into the failure of the future as the grand arc of tragedy bending back around, specifically reverse-engineered to fulfill the prophetic tragedy of the 40k setting. It presents these genetically modified and brainwashed soldiers as a flawed attempt at perfect creatures which is doomed from the start: these are emotionally immature yet hypermasculinized figures, whose temper tantrums spell the deaths of billions. 30k is an attempt at an exploration of why the Emperor's Grand Crusade failed, and how it brought about the 40k universe.
That said, from metatextual perspective, I can't speak for the guiding ideologies of the authors writing these books. They might be seduced by the face-level allure of raw power and hypothetical necessity of the existence of such a totalitarian regime. It's a dangerous line to flirt with.
If you're going to engage with the material here (which is for the most part, indeed almost exclusively, by no means heady or intellectual stuff) it's worth bearing in mind that Black Library ultimately fills the role of hyping up the physical product line of Games Workshop. The ultimate end goal of their work, above and beyond being profitable themselves, is to sell readers specific miniatures, then also prompt in them an investment in the setting that will lead them to buy even more miniatures.
Which is all to say: I think the better works in the setting are the ones that are varying degrees of satire and subversion, or the ones which explore the less militant elements of the setting, not the ones that are a naked glorification of militant prowess--however, that said, it is a setting that literally sells itself on "bolter porn," which is to say hypermasculine military prowess and gratuitous uber-violence.