I don't want to be the one to break this to you, but companies care very much about making money. It's true.
Buying card packs with virtual coins isn't gambling, though. Not any more than how we would buy packs of cards in real life anyway. Or like those small toy/sticker machines that were next to gumball machines. Or even the freakin gumball machine, lol.
Sometimes you get the item you wanted, sometimes you don't. It's a gamble in the sense that you don't know what exactly you're going to get, but you'll always get
something, so you never actually "lose".