I went through this personally as a kid. My best friend got accepted by the popular kids and realized I didn't dress trendy enough, listen to the right music, etc. and dumped me completely and later bullied me. Fortunately, I had other friends to get me through it, but it was very difficult. I thought my friend was really nice, too. She came from a Mormon family that was very family-oriented and kind, so there was no sign this was coming. It was immediate and dramatic.
What I would do is let your daughter know that a lot of people in the world are very insecure about themselves. With all that he has going on, that's no doubt the case. People in this position tend to not make wise choices. Let her know you're so proud of who she is as a person and how strong she is to be herself. Remind her of the great friends she does have and that the situation is just a bad reflection on him and his poor choices right now.
So sorry she's going through this! You're a great mom for trying to help her through it.