When this happens are you by chance going into a left turn corner and it feels like she is drifting to the right, even though she is bent to the left? Overbent, perhaps? If there was no fence there, would she drift outward toward the right? LIke a magnet is pulling her?
Sounds like her mind is going somewhere outside of the arena at that point. Next time she does it observe her ears and eyes and try to notice when her mind starts going that way, if it is well before the shoulder falling out happens.
If you can catch that happening, do something that will get her attention on you, like a change of gait or move her off the wall or stop or anything to interupt that thought in her. Then start again toward the corner. that's one way to shake things up.
You can push her shoulder back in with leg and outside rein, you can counterbend, or just to mess with her mind, do a volte ( a tiny circle in the corner there, going in the opposite dirctione she wants to go. So , she is falling shoulder out to the right, chances are you might be overbending to the inside (left) trying to go through that corner, she drops her shoulder, you just take her into a tight circle to the LEFT. This will disengage her from that drift to the right. Set it up and try again.