We've been at "war" for decades burning military dollars on a "cause" that very few Americans believe in, care about, or even understand. You can only wave the flags and shout about patriotism for so long before people stop giving a shit. It obviously becomes very hard for an organization to attract talent when said talent doesn't care about or believe in what the organization is doing.
The military got the best and brightest during WWII because the US was fighting Nazis (oh, sorry, "alt-right European Nationalists") and a foreign enemy who had attacked us on our own soil. For Vietnam, they had to draft because few believed in the cause and what they got where those too powerless to escape the draft (cough, cough, bone spurs). And for... whatever the fuck it is we've been doing in the Middle East since 9/11, the military doesn't even have a draft to potentially snare some better people.
When you have an all-volunteer military in an endless war for no clear purpose, the end result is many people who have nothing better going for them. Should we really be surprised the military is a clusterfuck? If you were competent, why would you want to squander your talents helping the US kill random brown people for no good reason?