"Aren't they in the Habsberg line?"
Absolutely not. One thing about which the Habsburgs have always been particular is that their marriages must be to other Roman Catholics. The Serbian royal family is Eastern Orthodox ("not that there's anything wrong with that").
Thanks for setting me straight and good to see ya.
Among Karl Ludwig and Amalia's children were Caroline and Wilhelmina. Hesse was a Protestant family, but Caroline married the Catholic King Maximilian I of Bavaria, and so her descendants are Catholics.
Caroline and Maximilian were the parents of Princess Amalia of Bavaria, mother of King Georg I of Saxony, father of Princess Maria Josepha of Saxony, mother of Emperor Karl I of Austria-Hungary, father of Archduke Otto of Austria.
Wilhelmina and her husband Grand Duke Ludwig II of Hesse were the parents of Princess Maria of Hesse (who married Tsar Alexander II), mother of Grand Duke Vladimir of Russia, father of Grand Duchess Helen of Russia, mother of Princess Olga of Greece, mother of Princess Elisabeth of Yugoslavia.
This would of course be easier to explain with a family tree but I don't know how to do that on FR. I can provide more details (on this or any other royal genealogical topic) if you like.