Exile followed inner descent
In a letter which Rabbi Ashlag wrote to his students whilst he was away in London, he bemoans the fact that some previous students had fallen away from the group. In looking at the question as to why this had happened, he shows how outer change actually follows a prior inner change.
This we learn from the story of the exile in Egypt. It was an inner change in the spiritual consciousness of the children of Israel that enabled their outer reality to change from being guests in a welcoming host country, to one of slavery and servitude.