Last year, Southwest Airlines (NYSE:LUV) was the best-performing major airline stock in the U.S. Unfortunately, the popular low-cost carrier has faced a variety of challenges in 2018, putting pressure on its profit outlook. This has caused Southwest Airlines stock to fall nearly 20% year to date.

Even with a lower 2018 profit outlook at Southwest, the stock has become significantly cheaper due to its poor performance this year. Furthermore, the company is well positioned to post solid profit growth over the next few years. As a result, Southwest Airlines stock looks like a bargain based on its Monday closing price of $52.83.

Mixed first-quarter results

In January, Southwest Airlines projected that it would achieve a solid 1% to 2% increase in revenue per available seat mile (RASM) for the first quarter. This put the carrier on track to record strong earnings growth, primarily due to the reduction of the corporate tax rate.

However, Southwest cut its unit revenue forecast in March, estimating that RASM would be flat year over year in the first quarter. It pointed to weaker-than-expected revenue results during off-peak periods in the first half of March. The company did reduce its Q1 unit cost forecast at the same time, but investors still dumped Southwest Airlines stock after this update.

Last Thursday, Southwest Airlines reported that RASM came in exactly flat year over year last quarter. Meanwhile, adjusted nonfuel unit costs ticked down 0.3% year over year, more or less offsetting a modest increase in fuel costs. (While oil prices have risen significantly over the past year, Southwest suffered from steep hedging losses in 2017.)

A Southwest Airlines plane preparing to land during the day

Unit revenue fell short of Southwest's initial guidance last quarter. Image source: Southwest Airlines.

The net result was that Southwest's adjusted operating income edged up to $584 million from $574 million a year earlier. Including the benefit of tax reform and a lower share count, adjusted EPS surged nearly 30% to $0.75.

Second-quarter guidance is disappointing

The near-term outlook for Southwest darkened last month after passenger Jennifer Riordan died in an accident on April 17, 2018, related to an engine malfunction. This was the first time an accident claimed the life of a Southwest Airlines passenger in the airline's 47-year history.

While media coverage of the incident has been fairly positive -- focusing on the heroism of the crew and passengers -- the accident will still hurt Southwest Airlines' near-term financial performance. For example, the company halted all advertising immediately after the accident. It is returning to its normal advertising level slowly. This has exacerbated the short-term impact of the accident on bookings. Additionally, Southwest has accelerated its engine inspection plans, driving up costs this quarter.

Due to these factors, management expects RASM to fall 1% to 3% year over year this quarter. Most of the decline relates to the impact of the accident on bookings, although the timing of Easter is another headwind. Rising fuel costs and a 1% to 2% increase in nonfuel unit costs will also put pressure on profitability.

That said, Southwest reported a stellar operating margin of 21.1% in Q2 2017. Its operating margin is on track to drop by 4 to 5 percentage points from that level, but that should still allow the company to post a modest year-over-year EPS increase this quarter.

Conditions will improve

The recent dip in bookings at Southwest Airlines isn't likely to last long, if prior experience is a guide. The carrier will also see bigger benefits from its new reservation system in the second half of 2018, which should contribute to better unit revenue results.

Moreover, Southwest currently faces a shortage of Boeing (NYSE:BA) 737 jets in its fleet, after retiring its oldest 737s last September. This has forced it to operate suboptimal schedules for the past two quarters, dampening unit revenue. As Southwest adds more Boeing 737s to its fleet, the impact of suboptimal scheduling on unit revenue should recede in Q3 and disappear by Q4.

On the cost side, Southwest Airlines currently expects flat nonfuel unit costs and a 2% to 3% improvement in fuel efficiency in 2018. Cost trends should remain favorable beyond 2018, due to continued fleet modernization efforts. In fact, Southwest recently ordered another 40 Boeing 737 MAX 8 planes, in order to take advantage of attractive opportunities to replace its oldest 737-700s.

A Boeing 737 MAX 8 painted in the Southwest Airlines livery

Southwest Airlines has ordered another 40 737 MAX 8s from Boeing. Image source: Southwest Airlines.

By the end of 2021, Southwest Airlines will have received more than 100 additional 737 MAX 8s from Boeing, driving substantial savings along with moderate capacity growth. Southwest will also have captured the full $500 million estimated benefit of its new reservation system by 2021 (up from $200 million in 2018).

In short, even if operating profit dips slightly in 2018, Southwest Airlines is in great shape to get operating profit growing again thereafter. Its strong free cash flow will also allow it to return lots of cash to shareholders. With Southwest Airlines stock trading for less than 12 times earnings, this could be a great time for long-term investors to jump in.

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