Gap Inc. shares tumbled in extended trading Thursday after the company said CEO Art Peck will be stepping down immediately, and be replaced by the founders' son temporarily.

Gap, which has been struggling to revive its sales, also slashed its forecast for the year, citing a "challenging quarter." Its shares sank more than 7% in after-hours trading on the news.

Robert Fisher, currently the company's non-executive chairman, will serve as CEO on an interim basis. He previously served as interim CEO in 2007.

Peck has served as CEO since 2015 and worked at Gap for almost 15 years. In February, Peck announced plans to split the retailer into two publicly traded companies in 2020 — one company would house its faster-growing Old Navy brand, while the second would be led by Peck and oversee Gap, Banana Republic and its other brands such as Athleta.

CFO Teri List-Stoll said the quarter was hurt by "macro impacts" and slower foot traffic, which "further pressured results that have been hampered by product and operating challenges across key brands."

The clothing retailer said third-quarter company-wide same-store sales fell 4%, compared with flat growth a year ago. It said sales at the Gap brand were down 7% during the latest quarter, they dropped 3% at Banana Republic and declined 4% at Old Navy.

Gap warned third-quarter net income to range between 50 cents and 52 cents a share. On an adjusted basis, it expects to earn 34 cents to 36 cents a share.

For the year, the company now expects to earn between $1.70 and $1.75 a share, down from a prior range of $2.05 to $2.15 a share.

It's set to deliver a complete earnings report for its fiscal third quarter on Nov. 21.

The poor performance is the latest in a string of bad news for the retailer. While its stock initially surged on the spinoff plans earlier this year, shares are down more than 30% since January, bringing its market value to $6.8 billion.

Under Peck, Gap has closed hundreds of stores. But his efforts haven't been enough to bring back the strong performance the company enjoyed in the 1990s under Mickey Drexler.

Gap also named Bobby Martin, chair of its compensation and management development committee, as its lead independent director.