I'm sorry to hear you got divorced.

Literal

Divorced [quotative-と] hearing unfortunately think.

離婚された uses the honorific/respectful passive された for the other person's action. 残念に思います (I regret to hear) is a polite expression of sympathy — 残念 (regrettable) + に思う (to feel).