Game Freak doesn't do things with the metagame entirely in mind. While they did state that Fairies were meant to balance out the OP Dragons (who I still think weren't that OP), they probably didn't think about the metagame beyond that. If they really were prioritizing the metagame, they wouldn't have given stuff like Blaziken or Garchomp mega evolutions or would've given Black Kyurem Ice Fang/Punch. Game Freak likes to troll.
While for most of the games this is true, I actually kind of disagree that GF didn't really factor the metagame with the new type, or anything with X/Y for that matter.
Dragon, as a type, is imbalanced. It excels both offensively, thanks to only one type resisting it, and defensively, being weak to itself and ice, both of which can be negated by the Dragon type Pokemon themselves. The problem wasn't noticeable until recently, however, because before Gen 4, the Dragon type was severely lacking in diversity of Pokemon and those that had the type were intended to be godly to begin with (Dragonite, Salamence, etc.). Heck, most Dragons before Gen 4 could barely utilize their STAB, as not only were Dragon-type moves lacking in diversity, but the moves all did special damage when most dragons were geared to be physical attackers. The only reason people starting running the DD+Outrage set was due to the changes in regards to what makes a move physical or special, which happened in Gen 4.
However, especially in Gen 5, dragons became a lot less of a pain to obtain and there was a bit more diversity in the types of Dragon Pokemon. It broke the main game as Dragon-type moves have few options to counter against, and it somewhat broke the competitive game for the same reason, any a lot of players were forced to pigeon-hole their teams just to address them, and the counters to most of the top Dragon-threats are negligible at best. The Fairy type was introduced to put in end to this, and it did just that.
The other part about the Fairy type, one which is the reason I disagree that Game Freak didn't factor in competitive play in their decision to add the new type, is their weaknesses. Both Poison and Steel are some of the worst offensive types in the game, and competitively, while steel was favored for defensive roles, steel-type moves were not favored. Poison had it even worse, despite having great defensive properties, there was almost no reason to use both a Poison-type Pokemon (due to the risks of Earthquake) or their moves, since they have poor coverage. In general, players prior to this gen would stick to using only a handful of Pokemon types, and I seriously doubt GF didn't pay attention to the picks of world tournaments and didn't notice how stale the whole thing is. The Fairy type did justice to these types by promoting their use, and it actually added some diversity to the game. I seriously never saw as many Crobat users until this gen came about.
I will say that I partially agree with you in regards to Mega Evolution, though. I feel like they stuck it on popular/competitively favored Pokemon as a marketing reason, just so that audiences don't feel underwhelmed by seeing it given to Pokemon they never cared about prior to their mega-evos.