To say it's been a bad past two years for Under Armour (UA 0.92%) (UAA 1.03%) stock would be an understatement.

After topping at an all-time, split-adjusted high of $52.92 in late September 2015, Under Armour shares have since suffered a 63.2% decline. Worse yet, this sell-off has erased effectively all the outperformance against the S&P 500 that Under Armour shares had accrued over the past five years.

UAA Chart

UAA data by YCharts

However, one investor's trash can be another's treasure in the stock market. Under Armour remains a strong bet for continued growth over the long term.

Former Houston Astros star Lance Berkman hits a home run wearing Under Armour cleats.

Image source: Under Armour 

What went wrong at Under Armour

The drag on UA stock is the perception that it's a busted growth story, a company whose long history of prodigious growth was matched or exceeded by the equally prodigious valuation of its stock. The company's streak of growing sales at 20% or greater ended abruptly in the most recent holiday quarter, when sales managed to grow only 12%. The company blamed a weak overall quarter for U.S. retail sales, foreign currency headwinds, and inventory issues stemming from bankruptcies at larger franchises such as Sports Authority.

The news of slower sales growth alone prompted Under Armour shares to tank more than 20% in a single session. Worse still, Under Armour also reduced its stated sales and profit targets; it hoped to achieve sales of $7.5 billion and net income of $800 million in 2018. However, while many investors have fled as the company transitions into its next phase of growth, Under Armour stock looks like an interesting contrarian play for long-term investors today.

Why its stock is a buy today

Like most great growth stocks, Under Armour shares have never been cheap. However, Under Armour shares today are the cheapest they've been since 2013 and toward the lower end of their valuation range in Under Armour's time as a public company.

UAA PE Ratio (TTM) Chart

UAA PE Ratio (TTM) data by YCharts

With Under Armour shares now less than twice as expensive as the market averages, the stock seems to be approaching the point of being a great company at a fair price for investors willing to hold its shares for the long term.

Right now, the market is mostly focusing on what's recently gone wrong at Under Armour, rather than on the many positives that should continue to drive the company forward for years to come. Though other factors contributed, the primary catalyst behind Under Armour's sell-off was its reduced 2017 guidance. True, sharply reducing its revenue growth guidance suggests the company is careening toward maturity, but does the evidence support this conclusion?

The company generates 83% of its sales from the U.S., compared twith48% for Nike. Even as it leans more heavily on direct-to-consumer sales amid the ongoing upheaval in the retail market, this presents a tremendous growth opportunity for Under Armour. Moreover, the company continues to push into digital health initiatives that should increase in popularity in the years to come, especially as wearable tech improves.

Though it guided for 12% sales growth this year, analysts project Under Armour revenue growth to accelerate to 15% next year. Over the long term, the sell-side community projects Under Armour will grow its earnings per share by 17% annually over the next five years. The company continues to innovate, sign big-name endorsements, and establish its brand in the eyes of consumers. So even though its valuation remains rich after its recent sell-off, Under Armour still strikes me as a solid long-term bet to match sportswear powers Adidas and Nike atop this massive global market.