Your best help is as her friend. Be generous with support, hugs, a glass of wine etc. But leave the custody issue to her and her lawyer.
EDIT: I have been told I have a gift for stating the obvious and fear it may be true here. If so, disregard and just accept my wish of good luck. I am sure your friendship means a lot to this woman right now.