A Chipotle restaurant in Miami. (Joe Raedle/Getty Images)

Legions of customers have been steering clear of Chipotle after a series of food contamination scares made them wary of their burrito ritual. So many of them have stayed away, in fact, that chain saw a 29.7 percent plunge last quarter in sales at restaurants open more than 13 months — the sort of nosedive that is practically unheard of in the restaurant business.

Chipotle has been playing offense for months to try to win customers back, but in the past two weeks, those efforts have gone into a new phase: The chain added a new item to its famously tight menu, launched a summerlong rewards program and released a cutesy animated video that takes shots at its competitors.

All the tactics are an effort by the chain to ensure that this incident is a regrettable footnote — rather than a defining turning point — in its extraordinary growth story. But as Chipotle takes these steps to reclaim its street cred, there are early signals that it could encounter some fresh challenges facing the wider fast-casual dining business. Market research firm NPD Group found that visits to fast-casual restaurants declined in the most recent quarter for the first time since it began tracking them in 2004. NPD analyst Warren Solochek said that dip is part of a broader slowdown in demand across the entire restaurant industry.

Meanwhile, Nation’s Restaurant News, an industry trade publication, found that fast-casual restaurant stocks were down 9 percent in the second quarter, on average.

“The investment community is highly skeptical at the moment,” said Jonathan Maze, a senior editor at Nation’s Restaurant News.

In other words, Chipotle is not only up against problems of its own making, but must deal with a Wall Street that is cautious about fast-casual players and a Main Street that may be less receptive to its overtures.

[What we get wrong when we talk about the fast-food wars]

Chipotle’s latest blitz to win back customers is wide-ranging. For one, it moved last week to add chorizo to its menu, a sausage that is made of pork and chicken and is seasoned with paprika, toasted cumin and chipotle peppers. The meat debuted in locations in five markets and is set to land on menus around the country later this year.

Chipotle has deliberately kept a tightly curated menu that it says allows it to maintain efficiency in the kitchen and keep lines moving quickly in its restaurant. But it opted to give the chorizo a try after it saw favorable response with loyal customers in a test last year in Kansas City.

On July 1, it launched “Chiptopia,” a three-month-long loyalty program in which customers can buy four entrees in a month and get the fifth free.  (That’s for the entry-level, “Mild” level of the program; customers who buy enough to achieve “Medium” or “Hot” status are eligible for additional free meals.) The program is structured to reward not how many dollars you spend at Chipotle, but how many times you visit. Chiptopia is likely aimed at getting diners to again feast on Chipotle burritos out of habit, almost on autopilot.

Most recently, the company unleashed on the Internet a short animated film that, in between scenes of doe-eyed kids falling in love and growing up to build a food business, takes some shots at quick-service restaurants that serve sprawling menus and use artificial ingredients.

Chipotle has released such animated films in years past, and the company told The Wall Street Journal that it started work on this one before the food contamination problems. But it is aimed at establishing Chipotle in the minds of consumers as a place for freshness — an especially critical message in the wake of the food safety issues.

The film shows a girl and a boy duking it out with rival lemonade and orange juice stands, which they nurture through adulthood to become booming commercial restaurants. But, they lose their way because they rely on contraptions such as a “sparkle taste booster” and a “microwave auto heater” to make their food, and they offer crazy menu items such as bacon lemon balls and orange sliders. (It’s hard not to see that last bit as a dig at McDonald’s, which has said that an unwieldy, overly-complex menu contributed to its struggles in recent years.)

The video has already been viewed over 3.6 million times on YouTube.

[Why Chipotle is thinking about opening a burger chain]

It’s too soon to know how much any of these latest efforts will move the needle. When the company reports earnings on July 21, we should get a broader picture of its progress. The quarter ended before the launch of Chiptopia and just days after the arrival of chorizo, though, so we won’t see the impact of those moves on sales or traffic.

Earlier this year, the company undertook a systematic evaluation of safety procedures around each of its ingredients and brought on Jim Marsden to serve in a newly created role of executive director of food safety.

Chipotle’s plans to re-attract customers may bump up against external headwinds. NPD’s Solochek says restaurant chains are courting a customer that, in recent months, has had less appetite for dining out.

“What we’ve seen is consumers are becoming a little more conservative, meaning their willingness and ability to spend in places that have a higher average check is diminishing,” said Solochek, president of NPD’s foodservice research practice.

Fast-casual restaurants, are among the group that has a higher average check; quick-service restaurants such as McDonald’s or Burger King would not.

Plus, with so many fast-casual restaurants opening new locations at a breakneck pace, it can be increasingly hard for any single chain to grab a big share of diners’ dollars.

Wall Street, too, seems to be changing its posture on investing in restaurants. Splashy initial public offerings from Shake Shack and Habit Restaurants haven’t maintained their momentum. Shake Shack’s stock is down 21 percent since its February 2015 IPO, while Habit Restaurants’ is down 55 percent since its November 2014 stock market debut.

“Investors were just throwing money at these companies, and it’s now really very much a ‘show-me story’ when it comes to fast-casual chains,” Maze said.

Meanwhile, it likely doesn’t help Chipotle that the company has had to deal with the unwelcome distraction of news that its chief creative and development officer, Mark Crumpacker, was arrested this week on charges of drug possession. Crumpacker earlier had been placed on administrative leave from Chipotle when allegations surfaced of his connection to an alleged drug ring.

Still, there are some encouraging signs for the burrito chain. Chipotle increased its share of restaurant foot traffic between the first quarter and second quarter, according to an analysis by xAd, a location-based marketing company. At least one research analyst found that early customer response to the chorizo has been favorable. And with a track record of revenue and comparable sales growth that has often been the envy of the restaurant industry, it has shown that it knows as well as anyone how to ring up big sales in a fast-casual format.