There aren't many stocks available at compelling discounts right now. That's all thanks to a roaring stock market rally that has pushed indexes to new highs. The S&P 500 is up 22% in the last 12 months, in fact, and many growth stocks have rallied by much more.

Starbucks (SBUX -1.93%) is not one of them. The coffee giant's shares are down 21% since mid-April 2023. That's by far the worst performance among its fast-food peers, including McDonald's and Dutch Bros. There are some good reasons for the stock's weakness, but the issues plaguing the company are short-term in nature.

Let's look at why Starbucks is such a great long-term buy for savvy investors right now.

The issues

Wall Street wasn't thrilled to hear management's cautious short-term outlook as part of its late January earnings report. CEO Laxman Narasimhan and his team described some stubborn headwinds that are pressuring the business in its two biggest markets right now.

In the core U.S. division, consumers are looking to save cash and so they're stepping back from their prior free-spending ways. Starbucks' most loyal customers are still frequenting stores, but its occasional shoppers aren't visiting as much. "We are responding with both product innovation and targeted marketing," Narasimhan told investors.

In China, meanwhile, price-based competition is combining with weaker consumer spending to pressure sales. Global comparable-store sales in Q1 slowed to a 5% uptick compared to the 8% spike investors enjoyed in the prior full year.

Rebound ahead

Starbucks will find its growth path again. New product releases should help, as will targeted promotions aimed at convincing those occasional afternoon visitors to come back. Investors can follow customer traffic trends for signs of success here. Look for a shake-out of the competitive threats in China that will speed up its comps growth, too.

Yet, investors should brace for at least a few more quarters of unusually weak sales trends. Most Wall Street pros are looking for sales to rise 8% this year compared to last year's 12% spike.

You'll benefit from Starbucks' strong finances while you wait for that rebound momentum to build. The chain notched a 1.4 percentage point boost in operating profit margin last quarter (up to 16% of sales), which is even more impressive considering that its wage expenses are rising so quickly.

Starbucks has hiked hourly pay by over 50% in the last four years, which the company says has led to a sharp reduction in turnover. The resulting improvement in the dining experience will take time to translate into faster growth, but shareholders' patience should still pay off.

Take advantage of the discount

Meanwhile, you'll get a big discount for choosing to buy Starbucks stock during this period of elevated Wall Street pessimism. Shares are trading at 2.7 times sales and 23 times earnings today. Both valuations are near three-year lows.

That decaffeinated premium makes sense if you believe Starbucks has lost its competitive edge, but that's not what the recent operating trends show. The chain attracted higher customer traffic and increased average spending last quarter, after all.

It's true that shares could underperform the market again in 2024 if the rebound strategy takes more time to start showing results. Cautious investors might want to ease into a position if they're worried about the chain's ability to get back on track. There's no harm in watching the stock for a while until sales trends at least stabilize.

You'll get the best returns by purchasing Starbucks stock at a big discount, though. The lower valuation for this profitable, growing business isn't likely to last for long.