As we often see God's ways or thoughts are different than ours, wo when we take pride or rejoice in something, God doesn't find Joy in that.

God will take away that which we love more than him.
In the book of Genesis we see Abraham lived his son alot, and God asks him to sacrifice his son.
Samson loved Delilah more than God.
Naomi also lost her everything.

We never know the reason why God does this.
May be to test us.
But know this that worldly treasures and pleasures will not last forever.
People will only come to you for your beauty and money and other needs.
But it's God alone who will be with you for eternity.
So set your eyes upon God and Love nothing more than God.