She was completely at a loss.

Literal

She [topic-は] at-a-loss ended-up-becoming [regrettable-てしまった].

途方に暮れる is an idiom meaning 'to be at a loss / not know what to do' — literally 'to be benighted on the path,' as if lost at dusk with no direction. ~てしまった adds the nuance of an unintended or regrettable outcome — she didn't want to be at a loss, but that's where she ended up. The combination conveys helplessness.