Domains are an asset and very easy to justify paying for if you have the money. It's not like they just burned half a million dollars. If the company folds they can sell the name.
Also the name is vague enough to encompass any pivots. It's a great name, probably one of the best domains you could have for an app in the happiness business.
It was expensive, sure, but they have the money. And corporate accounting probably sees it as an appreciating asset anyway.
If you have $41 million I can think of few better purchases than a really great, memorable, meaningful, happiness-associated domain name.
Also it has netted them tons of free advertising. Think all the "The iPad will fail!!!!!!!" blog posts hurt Apple's bottom line? No one _really_ listens to naysayers. Pessimists are just an alternative form of advertising.