This year has been rough for many retirement savers, but smart investors know that market downturns are an opportunity to find quality companies at bargain prices before they go back up.

Owning companies that grow over many years can lead to a significant change in an investor's financial situation. And buying those companies at a discount to their worth can lead to something special.

When stocks dip into a bear market, many are going to trade well below their intrinsic value. Let's look at two you can buy right now that are trading at deep discounts.

1. The market is too shortsighted on Amazon

With Amazon's (AMZN -0.63%) revenue up nearly 80% over the last three years, management has been ramping up investment to expand its fulfillment capacity, inventory, and technology infrastructure.

Amazon is a great business that has delivered massive returns to investors, but worries about consumer spending and lower growth have sent the stock down 46% this year. 

We've seen this story play out before. Amazon has doubled its network capacity over the last two years, which usually is a forward indicator of the opportunities for the company. It went through a similar spending spree on its fulfillment network about 10 years ago, which caused a similar slump in its share price before it started heading higher again. 

While Amazon's high-growth days might be over because of its large size, it still only commands a small share of total e-commerce spending worldwide.

It's not easy to visualize the size of the global e-commerce market, which is expected to reach $58 trillion by 2028, according to SkyQuest Technology Consulting. That is quite large next to Amazon's paltry $500 billion in annual revenue, so investors can have confidence that it can grow for many years.

This market downturn is as good a time as any to buy the stock. The shares are the cheapest they have looked in years, with a price-to-sales ratio of 1.8. This valuation could be considered fair for the sum value of Amazon's retail, advertising, subscription, and third-party fulfillment services. So investors are getting the cloud services business, Amazon Web Services (AWS) -- which is the fastest-growing and most profitable segment at the company -- for a big discount. 

Any way you slice it, market participants seem to be focusing more on Amazon's operating losses and slowing growth in retail, which is undervaluing the company's fast-growing, high-margin revenue streams.

2. Lithia Motors is a monster growth stock in the making

Lithia Motors (LAD -0.62%) is one of the largest sellers of vehicles in the U.S. The company has a good track record of acquiring smaller dealerships to expand its vehicle inventory, but most importantly in a profitable manner. This has led to solid growth in revenue and earnings, sending the stock up 88% over the last five years.  

Management focuses on acquiring new-car franchises that range from midsize markets to large metropolitan areas. The goal with every deal is to earn 15% on the acquisition. The company's recent record of growth suggests it is overachieving on that goal.

However, Lithia is also willing to sell stores that don't make the cut. Last year, it acquired 77 stores and divested nine. The company spent a total of $2.3 billion to buy these stores and expects these additions to contribute nearly $7 billion in annual revenue. 

Lithia sees a huge opportunity to consolidate more of the auto retailing industry, a market worth $2 trillion, it says. The company has guided that earnings per share should reach $55 by 2025 on $50 billion in revenue. 

Investors can buy the stock at a mere four times 2025 earnings guidance. At this valuation, it could be argued that Lithia stock is a better investment than buying more dealerships, and management seems to agree -- the company has bought back over 7% of all its outstanding shares this year.

A shrinking pie raises the per-share value of the company, which can compound the value of shareholders' investments enormously over time.

The market's focus on negative headlines about the economy is causing some real gems to get overlooked. Lithia stock is very cheap and could soar once the dust settles.