Why do we say "Mazel Tov" when something good happens to a person? Doesn't that mean "good luck?" Are we saying that what happened, happened because of luck?
"Mazal" stems from the root "nazal," meaning "to flow." The basic meaning of the word, then, is not "luck" but rather "something that causes a flow." (It is therefore applied to the heavenly bodies, which in classical Jewish thought are the conduits designed by G-d to exert certain influences on earthly affairs. This then became conflated with the pagan idea that these bodies are independent powers that cause good or bad "luck" - hence the semantic drift.)
R' Shneur Zalman of Liadi, in one of his Chassidic discourses (Likkutei Torah, Haazinu 71d), develops the idea that "mazal," as applied to Jews, refers to the soul's higher spiritual root (compare Talmud, Megillah 3a and Sanhedrin 94a). Through this "mazal" the bearer of the corresponding soul receives the Divine energy that powers his or her physical life, and through it also comes the spiritual awakening that one sometimes feels.
In short, then, when we congratulate someone with "mazal tov," we are acknowledging that he or she has received a heightened level of G-dly bounty, channeled through their "mazal." Possibly, too, we are also thereby implying that we hope that this state of affairs will continue, and that their "mazal" will from now on be more attuned to G-d and will thus be a continued source of blessings.
The full phrase is "siman tov umazal tov yehe lanu ulchol yisrael."
May this good thing be a good, auspicious sign for us and all of Israel. So congratulations to you, good luck to everyone.