Earlier this week, Rite Aid (RAD 5.56%) became the latest company to report earnings that were in line with or better than expectations, but fell flat on guidance and led to a market sell-off. The third-place pharmacy chain has lagged the margin strength of its competitors, CVS Caremark and Walgreen, and cut costs to save the bottom line. As many an investor will tell you, though, the cost-cutting lever only pulls so many times -- at some point the fundamentals must improve. Luckily for Rite Aid investors, things are improving. And with the stock remaining significantly cheaper than its rivals', now may be the time to get in on the action.

Earnings sigh
Shares fell more than 10% on Monday as Rite Aid reported top-line sales of $6.36 billion. The number represented a nearly 2% gain over the prior year's numbers and slightly more than the Street's expected $6.32 billion.

Pharmacy same-store sales led the charge with a 3.5% gain over fiscal 2013's number, while the front of the store remained unappealing with a 0.2% drop.

The bottom line dropped $0.03 per share year over year to $0.04 per share, though much of this was due to financial engineering (capital raising and preferred conversion), and the Street knew it was coming.

Even though the company is focusing on efficiency at the operating level, costs rose substantially and limited profitability.

Looking ahead is what did the company in during Monday's trading. Analysts had hoped for a full-year gain of $0.24 per share, but management guided for a maximum of $0.23 per share and put the figure as low as $0.17 per share.

The road ahead
Putting estimates and short-term forecasts aside, Rite Aid has significant potential. For one thing, the industry is looking increasingly attractive in the back of the store as patented drugs are approaching the end of their exclusivity -- opening the door to more generic drugs and significantly higher margins for the pharmacies.

Though this is debated, Rite Aid is investing in its stores (while cutting costs) with fresh looks and new product partnerships and should compete more formidably with CVS and Walgreen. The front of the store is a very low-margin game for these companies, and Rite Aid has been the industry's caboose for some time. Looking in the rearview, that isn't too exciting, but it leaves room for significant improvement going forward. As the stores are renovated and things stabilize, Rite Aid has the potential to generate amazing additional cash flow from just a tiny improvement in its margins.

Then there is the subject of valuation. Rite Aid has for some time traded at a steep discount to its peers. While some of that value has evaporated with capital appreciation, Rite Aid is still attractively priced on an EV/EBITDA basis. Walgreen trades at nearly 12 times trailing EV/EBITDA, while CVS is at 9.44 times and Rite Aid at less than 8.5 times. Looking out a couple of years, Rite Aid may boost its EBITDA more than the market predicts via margin enhancement.

While not the industry darling, Rite Aid continues to offer a value price on a growth business.