But Q wasn't in the military so it WAS just a costume, at least that's the way I took the line.
Folks from the present (relatively speaking) are usually, if not always, going to see themselves as superior to their predecessors and lots of things about them. Folks today would look back at the kind of clothes Aristocrats wore back in the past (including the makeup they wore, including men) and see them as ridiculous costumes as well.
It's not Picard being deliberately insulting, it's just how a guy 300+ years from now would think of our own attire including what our soldiers wore.
Also in the context of the episode, Q was wearing that uniform to remind humanity of a part of its past where armies invaded other countries for territory and personal power with no regard for the lives lost in the wake. Picard's characterization of a 'costume' was meant to disown unjust wars and invasions from his cultural past, not to show any disrespect for those who defend their own country.
I rewatched Encounter at Farpoint today, and the exchange between Q (in his Marine Corps uniform) and Picard goes like this:
Q: But you can't deny that you're still a dangerous, savage child race.
PICARD: Most certainly I deny it. I agree we still were when humans wore costumes like that, four hundred years ago.
Sorry, but this is first-season Picard being a douche. He exhibits the same elitist attitude in "The Neutral Zone".
Fortunately, his attitude improved in later seasons, along with everything else in TNG.