Mastercard (MA -1.28%) is back. After a couple of years of underperformance thanks to the pandemic, the company is beating the market again this year. Share prices of the second-largest payments network (behind Visa) are down only 2.8% so far in 2022, compared to a 14.2% decline for the S&P 500 index.

For Mastercard, overall expansion in economic activity can keep business chugging higher -- even if issues abound with actual economic health. Amidst worries of inflation, rising interest rates, and general lingering effects from the pandemic, Mastercard is back in growth mode and could help stabilize a portfolio in these troubling times.

Here are three reasons the stock is a buy now.

1. Revenue is soaring

Mastercard's second-quarter 2022 revenue increased 21% year over year to $5.5 billion, or up 27% year over year when excluding foreign currency exchange rates. Currency exchange headwinds, in particular, have been problematic for many companies this earnings season, which is in part being spurred on by the U.S. Federal Reserve's interest rate hikes this year. The Fed wants to get inflation under control by cooling off some areas of the economy, but a side effect has been a record-setting run in the value of the dollar versus most other currencies.  

But Mastercard shook off those issues as important operating metrics like cross-border travel continued to recover. Cross-border transaction volumes were up 58% year over year. But besides a general recovery in travel activity, Mastercard has plenty of growth opportunities. For example, buy-now pay-later (BNPL) options are increasingly popular among consumers as an alternative to credit cards. Apple has announced its entry into this realm, and Apple's service makes use of Mastercard's "Installments" service to facilitate the tech giant's BNPL offering.  

Elsewhere in the business, Mastercard said its "other revenues" -- consisting of various ancillary services like marketing, technology, security, and data services -- grew 18% year over year in Q2. In 2021, Mastercard said these other revenue streams made up one-third of its total.

2. Profitability is rising even faster than revenue

A giant company like Mastercard isn't going to be the fastest-growing investment out there. However, what a big company may lack in all-out expansion, it can more than make up for with a highly profitable operation. Mastercard certainly delivers on this front.

Operating expenses grew only 13% year over year, which equated to an even faster rate of profit growth than revenue. Adjusting for comparability (specifically, backing out the effects of changes in equity investment during a particularly volatile Q2 for the market), net income increased 29% from a year ago. Adjusted net income of $2.5 billion represented an enviable profit margin of 45% last quarter, up from 43% last year.

Despite these incredibly high margins, Mastercard only pays a dividend that's currently yielding 0.6% a year. However, the company does repurchase lots of stock to return excess cash to shareholders. In Q2 alone, Mastercard spent $2.4 billion on share buybacks, helping boost its adjusted earnings per share growth to 31% compared to the second quarter last year.

3. There's plenty more room for further recovery

Management said on the earnings call that cross-border transaction volumes were 118% of the level they were at in 2019 before the pandemic. That's good news, considering that travel-related charges are a prime way Mastercard makes money. Further rebound in global travel (both vacations and business trips) will further boost Mastercard's results going forward.  

Asia in particular is one region that is still being heavily affected by pandemic lockdowns and border restrictions. Apparently, Mastercard's cross-border transaction volumes in Asia were only 60% of the volume they were in 2019. Other regions are likewise only just getting started in their recovery from lockdowns in 2020 and 2021. This represents another area that could help Mastercard keep growing fast in the years ahead.

Given this ongoing recovery and Mastercard's general growth as economic activity chugs higher, this stock looks reasonably priced at 38 times trailing-12-month free cash flow and 33 times current year expected earnings. This has been a market-beating stock for many years, and after a hiatus during the start of the pandemic, it's back in expansion mode. For investors looking for a way to offset the negative effects of inflation and other imperfect economic conditions, Mastercard is a top stock to consider.