ויקרא יא,ב: זֹאת הַחַיָה אֲשֶׁר תֹאכְלוּ
HaShem’s original intent was to dwell in the midst of the Jewish people without the medium of a Sanctuary or any other form of intermediary. Were it not for the sin of the Golden Calf this would have come to pass and holy nation of the Jews would have been everlasting. After this grand plan was thwarted HaShem refused to allow His Presence to dwell among the Jews until Moshe prevailed upon Him through prayers to dwell in the Sanctuary. Chaza”l teach us that the laws listed in this Parsha and the following ones serve to refine and purify the collective soul and character of the Jews, thereby preparing them to receive the Divine Presence. The laws of Kashrus and of Niddah and of purity were all meant to sanctify the Jews, thereby bringing them to a level to be close to HaShem. This is the thrust of the Sforno’s commentary.
The Sforno proceeds to explain the difference between the expressions טמא (unclean) and שֶׁקֶׁץ (detestable). He submits that only that which can convey defilement through contact or carrying is referred to as טמא, while that which is prohibited but does not physically defile is referred to as שקץ.
In addition, Sforno continues to explain that the Jew has specific dietary laws (kosher) that are meant to maintain his spirituality and his connection to chaim (eternal life/HaShem). The Jew must separate himself from anything that could diminish his spirituality. This is not only limited to food items but to anything which is classified as spiritually contaminating.
