No actually Turkish adopted the word "merhaba" from arabic The word in arabic is "marhaba" But because we say "to you" in arabic "bek" = marhaban bek" We delete the last part "bek" And remain the "n" So it turn to "marhaban" But the word it self is "marhaba" It came from the arabic root "rahaba"="r.h.b"
Adding to the answer here- generally when you wish a good something to someone in Turkish, it's plural. For example: İyi şanslar (good luck), İyi bayramlar (happy holiday - for religious or national holidays in the American usage of the word), İyi geceler (good night), iyi yolculuklar (happy travels/bon voyage), mutlu yıllar (Happy New Year, or a phrase to use on a birthday), etc. :-)
I dont think evening and night are synonyms in Enlish, and they are certainly not in Turkish. There are no strict definitions but evening is typically after sunset, but before it is too late. For me after 7pm is evening, and after 10-11pm is nigt. I also dont think you would say good evening to a person who is going to bed, or good night to a person who you see in the evening. So even if people might not agree when evening and night are, I guess everyone would agree when to say good evenin or good night.