Avaricious Dragon & Day's undoing

What should happen if the opponent has Avaricious Dragon in board and I cast Day’s Undoing?

Who should get the mana when Avaricious Dragon ability (Whenever you draw a card, Destroy 3 gems of the opponent’s color) produces a gem match?

As we are in my turn, I thought that I was going to get the mana, but no, it was for the opponent.

His ability is triggered - his mana..making this combination highly risky