On Wednesday morning, Macy's (NYSE:M) reported a third consecutive quarter of comp sales growth. The department-store giant beat its relatively modest sales forecast and posted a big increase in adjusted earnings per share. Macy's also raised its full-year EPS guidance.

In what can only be described as an example of "buy the rumor, sell the news" behavior, Macy's stock plummeted as much as 15% following the earnings report. This is providing investors who missed out on the Macy's rally earlier this year a chance to scoop up shares of the stock at what is still a very cheap price.

Another strong quarter

At first glance, Macy's second-quarter sales performance may not seem very special. Comp sales (including licensed departments) increased 0.5% at Macy's last quarter, while total sales slipped 1.1% to $5.57 billion.

However, a shift in the timing of the retail calendar meant that a major sale moved into the first quarter of 2018, relative to the second quarter last year. This calendar shift boosted Q1 comp sales by about 2.5 percentage points and reduced Q2 comp sales by about 2.4 percentage points. Thus, on an adjusted basis, Macy's comp sales rose nearly 3% in the second quarter.

For the first half of fiscal 2018, comp sales increased 2.3%, including licensed departments. That comfortably surpassed the updated guidance that Macy's management provided three months ago, which called for a 1% to 2% comp sales gain in the first half of the year.

The exterior of the Macy's flagship store in Manhattan

Macy's sales growth cruised past management's projections again last quarter. Image source: Macy's.

Meanwhile, adjusted EPS surged more than 50% year over year, reaching $0.70, driven by strong income from Macy's credit-card program, a 0.8 percentage point gross margin increase, and a lower tax rate. This sailed past the average analyst estimate of $0.51. Under standard accounting rules, EPS came in at $0.53, up from $0.36 a year earlier.

Based on this strong earnings report, as well as adjustments to management's tax rate, interest expense, and credit card income assumptions, Macy's raised its 2018 adjusted EPS forecast by another $0.20. The company now expects to earn between $3.95 and $4.15 per share this year. That has increased by $0.40 from Macy's original EPS forecast of $3.55 to $3.75.

Macy's strategies are working

Macy's sales growth significantly exceeded management's expectations in the first half of fiscal 2018. During the Q2 earnings call on Wednesday morning, CEO Jeff Gennette said the company's sales growth initiatives are gaining traction faster than expected.

Initially, Macy's had expected comp sales growth to accelerate in the second half of fiscal 2018. However, the company now expects comp sales growth (including licensed departments) of 2% to 2.5% for the remainder of the fiscal year, right in line with its first-half increase.

Yet just as management's guidance for the first two quarters of the year was conservative, the same might be true for its second-half forecast. Most notably, the retailer will get a much bigger contribution from the expansion of its Macy's Backstage off-price concept -- arguably its most important sales growth driver -- in the second half of the year.

Macy's opened just 18 Backstage outlets in the first quarter, but it opened another 47 last quarter. It expects to add about 120 Backstage outlets within its full-line stores this year, with the roughly 55 remaining openings set to be completed by the end of this quarter. That could help offset the tougher year-over-year comparison that Macy's will face in the fourth quarter, allowing it to continue beating its forecasts.

The balance sheet is looking solid again

Macy's used some of its excess cash to repurchase $344 million of debt last quarter. As a result, the company ended the period with $5.5 billion of debt, or $4.5 billion net of cash.

Between this debt paydown and the continuing improvement in Macy's underlying earnings, the company's leverage ratio declined again during the second quarter. Adjusted debt now totals 2.6 times adjusted earnings before interest, taxes, depreciation, amortization, and rent -- down from 3.2 times a year ago. This puts Macy's right in the middle of its leverage target range.

Furthermore, Macy's generates the vast majority of its cash flow in the second half of the year. Indeed, between now and the end of fiscal 2018, free cash flow and asset sale proceeds combined will probably exceed $1 billion. This will enable further debt reduction later in the year.

Time to buy Macy's stock?

Even after plunging on Wednesday, Macy's stock is up more than 40% year to date. Nevertheless, it still looks like a bargain.

M Chart

Macy's Stock Performance, data by YCharts.

Macy's stock currently trades for less than nine times the company's projected 2018 EPS. Even excluding asset sale gains of about $0.75 to $0.80 per share, the stock is selling for less than 11 times earnings. (This also ignores the strong possibility that Macy's will continue to raise its EPS forecast, as well as the likelihood that it will continue to sell assets in the coming years.)

Macy's also pays a juicy dividend that yields more than 4%. Based on the company's strong cash flow and improving balance sheet, this payout seems quite safe. Furthermore, with Macy's likely to surpass its leverage target later this year, the company could restart its share buyback program within the next few quarters. This would provide some extra firepower to drive the next rally in Macy's stock.

Adam Levine-Weinberg owns shares of Macy's. The Motley Fool has no position in any of the stocks mentioned. The Motley Fool has a disclosure policy.