Imagine a retailer that began by specializing in just one product, then grew into a mammoth that redefined the American shopping experience.

Among its innovations: No matter where you lived, it shipped your order directly to you, whether you were looking for cast-iron cookware, a mandolin, the newest technological marvel, or the latest in petticoats.

Amazon, right? Actually, it was Sears — a century ago.

The brainchild of a pocket-watch salesman, Sears navigated retailing through the end of the stagecoach era, the rise (and fall) of downtown department stores and the malling of suburban America. Recently it has been battling to stay relevant with the advance of online retailers — like Amazon.

For many, the story of Sears is a reflection of the carnage occurring throughout much of retail right now. In recent days, the stocks of J.C. Penney, Macy’s and Dillard’s all tumbled after they reported another round of quarterly sales declines. Some analysts expect Sears to report a third consecutive double-digit decline in same-store sales in the second quarter.

But what may ultimately lead to the collapse of the once-great retailer is a dose of Wall Street financial engineering.

Under the direction of the hedge-fund moneyman Edward S. Lampert, Sears has borrowed to the hilt. Many of its most valuable assets have been sold off. Its stores have been starved for cash and attention. An early shift in the organizational structure designed to create competition among store departments — a strategy used by some hedge funds to allocate company resources — instead led to infighting.

It was all done in search of a profit that, for Mr. Lampert and his investors, has not materialized.

“I don’t think it was inevitable that Sears would find itself in the position it is in today,” said Arthur Martinez, who orchestrated a turnaround of Sears as its chief executive in the late 1990s. “The Sears brand has become largely irrelevant,” he said, “and it breaks my heart to say that.”

Today, Sears Holdings, the publicly traded entity that is the result of the 2005 merger of Sears and Kmart, coordinated by Mr. Lampert, is on analysts’ short list of most-likely-to-go-bankrupt retailers.

Over the past decade at Sears, more than $ 26 billion of market value has disappeared. Revenue has been halved, as has its work force, with 175,000 people losing their jobs.

This year, Sears has sued two vendors to force them to continue supplying goods even as many others reduce shipments to the retailer, concerned they could wind up empty-handed if Sears files for bankruptcy protection. One suit was settled; the other is in progress.

Mr. Lampert declined to be interviewed. Responding to questions through emails, the company said it continued to work on its transformation in a difficult retail environment and that it had no plans to file for bankruptcy.

The company also disputed the idea that Mr. Lampert had focused on financial engineering, noting that many retailers rely heavily on integration of financial and operational structures. The company also said Mr. Lampert began responding to the e-commerce shift more than a decade ago, well before many retailers did. Just last month, shortly after announcing additional store closings (so far this year, 155 Sears and Kmarts around the country have been shuttered) Sears announced a deal to sell its Kenmore appliances through Amazon.

Mr. Lampert said on the company blog this summer that Sears was continuing a strategic transformation that would return it to profitability. “While there is still work to do,” Mr. Lampert wrote, “we are determined to do what is necessary to remain a competitive retailer in a challenging environment.”

A Household Name

At the turn of the 20th century, as Americans established roots across the nation, they turned to Sears. Through its robust mail-order business — some catalogs were more than 500 pages — Sears shipped groceries, rifles, corsets, cream separators, davenports, stoves and entire prefab houses to some of the most remote regions of the country.

For decades, as Americans shifted the ways they shopped, Sears deftly evolved. In fact, it was often at the forefront of changing demands as it moved from catalogs featuring pages of saddles and bridles, to showrooms full of glistening home appliances, to auto-repair shops outside the mall.

As Americans moved from rural communities to larger cities, many no longer needed to shop by thumbing through the catalog; they preferred to visit dazzling department stores. Sears began opening hundreds of stand-alone retail stores, some with soda fountains, dentist’s offices and pet shops alongside tombstones and farm tractors.

The set of “The Donna Reed Show” in the 1960s featured a Kenmore stove, dishwasher and washer and dryer, all must-have appliances in American homes. And as TV culture grew in the ’60s, Sears ramped up its advertising campaigns and signed licensing agreements with celebrities like the baseball player Ted Williams, the golfer Arnold Palmer and the model Cheryl Tiegs.

In the 1980s, as Americans’ fondness for credit grew, Sears introduced its wildly popular Discover card, which was the first to offer cash rewards to customers based on the volume of their purchases. Within four years, 20 million people had the card. Within a decade, credit operations accounted for a big chunk of Sears’s revenues.

When malls became the meeting place of American youth, Sears moved with them. Its stores anchored shopping centers all over the country.

By the 1990s, however, Sears’s dominance of the retail landscape had ended. It was surpassed by the discount shopping retailers Walmart and Kmart, the so-called big-box stores. By 2001, Walmart’s revenues were about five times that of Sears.

The new players were nimble, able to change inventory and prices quickly. Sears’s overhead costs were higher, and catalog prices were usually set months in advance in order to meet printing and mailing schedules.

But big-box stores were only one threat. Online shopping would soon emerge as an even more powerful force, one that Sears, with its hundreds of brick-and-mortar stores needing constant face-lifts and upkeep, was also ill prepared to compete with.

That’s when the hedge-fund titan came knocking.

Slowing Sales and Leaky Roofs

In late 2004, newspapers were still running articles about the coming $ 11 billion takeover of Sears by the discount giant Kmart when Arthur Martinez’s phone rang. Mr. Martinez had been the chief executive and president of Sears in the late 1990s.

On the line, he said, was Edward Lampert.

A financial wizard who started his career on the vaunted risk arbitrage desk at Goldman Sachs, Mr. Lampert had just arranged the megadeal that created the nation’s third-largest retailer. Among the new members of its board were Steven Mnuchin, Mr. Lampert’s former roommate at Yale and the current Treasury secretary.

“He asked me if he had just done the stupidest thing in the world by buying Sears,” Mr. Martinez recalled.

Over a 90-minute meeting in Greenwich, Conn., where they both had offices, Mr. Martinez advised Mr. Lampert to focus on high-value businesses like appliance sales, Sears’s crown jewel. He also noted that Sears was a capital-intensive business, requiring steady investments not only in the stores, but also in training and retaining employees.

“He appears to have roundly ignored everything I told him to do,” Mr. Martinez said.

Sears disputed Mr. Martinez’s recollections, saying it was Mr. Martinez who requested the meeting, and denied that Mr. Lampert had made the comment about buying Sears. The company also said Mr. Lampert had not ignored Mr. Martinez’s advice.

At Sears, Mr. Lampert typically led from afar. As the largest shareholder through his hedge fund and, since 2013, the company’s chief executive, Mr. Lampert has overseen the company’s operations via videoconference from his home in Miami. He sets foot inside Sears headquarters in Hoffman Estates, Ill., roughly once a year for the annual meeting, according to interviews with several former executives.

In the early days of the merger, when times were better, Sears used its cash to buy back shares, a move businesses often use to try to drive share prices higher. From 2005 to 2012, the company spent $ 6 billion buying back its own shares at prices as high as $ 174 a share.

Today, Sears Holdings stock trades at $ 9.30 a share, a decline of 95 percent from its highs.

Besides the share buybacks, one of the earliest moves by Mr. Lampert was to decentralize the managements of Sears and Kmart, effectively creating more than three dozen silos of business lines such as men’s wear, shoes and home furnishings, each with its own management team and board of directors.

It is similar to a strategy sometimes used at hedge funds, where different teams compete with one another for scarce company resources. At Sears, though, the design led to infighting between divisions for everything from space in the weekly advertising circulars to floor shelving.

One former executive described how the clashes played out in Sears showrooms, whether in the jewelry or the tools departments. Managers would tell their sales staff not to help customers in adjacent sections, even if someone asked for help. Mr. Lampert would praise policies like these, said the executive, who asked not to be named because he still works in retail.

The company said the descriptions by former employees presented an “incomplete perspective” and that the company had adopted different organizational models. It noted that it had recently consolidated its management structure to speed up decision making.

Mr. Lampert’s grand vision for Sears, many former executives said, was to position it to compete with Amazon. Instead of spending on store upkeep, he plowed investment, new talent and marketing into Sears’s website and a customer loyalty program called Shop Your Way. The program allows customers to earn points, for purchases not only at Sears but at partnering businesses including Burger King, Under Armour and Uber, that can be redeemed for Sears merchandise.

Sears, Mr. Lampert argued, had a big edge: Its hundreds of stores nationwide could act as distribution centers. People could order things online and have them delivered locally.

The problem, former executives and employees said, was that the bulk of Sears’s revenue still came from its stores. And they were rapidly losing traffic.

“Victoria’s Secret has a $ 1 billion online business selling $ 25 bras and such because customers are totally comfortable going to victoriassecret.com, because they felt connected to the brand and the store experience,” said Gary Schettino, a former vice president of merchandising at Sears Holdings. “Victoria’s Secret understood the overlap of the store and the online customer in a way that Sears never did.”

Kmart and Sears stores around the country became dilapidated, their personnel demoralized. Employees at some Kmarts didn’t receive raises for several years. Some salespeople who worked solely on commission said that they had been slashed to nearly nothing about three years ago.

Customers walking into a Sears store in Kokomo, Ind., were greeted by stained carpets, broken mannequins and cracked display tables, recalled Amanda Marquand Householder, an assistant manager there before she left in 2014. The Kokomo store closed this spring.

The problems extended to Kmart stores as well. Kristin Hamm, an assistant manager at a branch in Lancaster, Pa., from 2011 to 2014, said managers knew exactly where to put the buckets they kept handy — all 10 of them — to catch water from the leaky roof when it rained.

Ms. Hamm also said inventory was hit and miss. On Black Friday one year, Kmart heavily promoted a particular television to drive traffic into its store. She said the Lancaster Kmart was given only one to sell.

The store did receive plenty of items, however, from the body-conscious clothing line by the hip-hop star Nicki Minaj. “It didn’t sell well,” Ms. Hamm said. “I mean, our store was located in the middle of one of the largest Mennonite populations in the country.”

Kmart ended its partnership with Ms. Minaj late last year. The Kmart store in Lancaster, which opened in 1970, closed in March.

In a statement, Sears said that the execution of Mr. Lampert’s strategy has had its challenges, but that the company was making progress “in a very difficult retail environment where many retailers, including Victoria’s Secret, have also been challenged.”

Regarding pay and commissions, Sears said that rather than increase compensation in some outlets, it chose to keep people employed, and stores open, as long as possible. As for upkeep, Sears noted that at the end of last year it had 1,400 operating stores and that it spent a “significant amount” on store appearance and “never wants a store’s appearance to disappoint its customers.”

The company also noted that other retailers have gone under even after investing in store renovation. Regarding inventory control, Sears said that given the scale of its business, there would be “situations where the company doesn’t always get this right.”

The fallout from Sears’s mistakes have hit its work force hard.

“Sears was the greatest job ever. A1. No doubt,” said Edd Oliver, who, for the past decade worked as a salesman at a Sears in Columbus, Ga. “People were raising families and sending children to college off of this company.”

A member of the Sears “million-dollar club” for three consecutive years in which he sold more than $ 1 million of appliances, Mr. Oliver said his job started to take a downward turn around 2014. That was when commissions, which had once been as high as 6 percent for some items, were cut to around 1.3 percent, he recalled.

Paid solely on commission, Mr. Oliver’s take-home pay, which topped out at around $ 60,000 in 2014, fell sharply in 2015 and then fell some more in 2016. The store also cut back on local advertising, Mr. Oliver said, hurting foot traffic.

In April, Mr. Oliver lost his job when his store closed.

“I still today would tell anyone to go to Sears and buy the appliances and get the warranty. It is the best,” Mr. Oliver said. “But after working there all of those years and then losing my job, it hurts. I’ve taken a big emotional hit from this.”

‘A Long, Slow Bleed’

In recent years, Sears has been kept afloat largely by selling off its most valuable assets. At the same time, Mr. Lampert has taken steps to protect his investment in the company.

Since 2012, Sears has been raising cash through a series of spinoffs or sales of entities including Sears Hometown and Outlet, a national retailer that focused on appliances and lawn and garden equipment, as well as Lands’ End and Sears Canada. More recently, the company sold its Craftsman brand of tools to Stanley Black & Decker, for $ 900 million.

In many of the spinoffs, Mr. Lampert, through his hedge funds and other entities, invested significantly. Those stakes appear to be under water.

But one move that could yet prove profitable for Mr. Lampert and others was the 2015 sale of more than 266 Sears and Kmart properties for $ 3 billion to a publicly traded real-estate investment pool called Seritage Growth Properties.

The sale drew intense scrutiny on the pricing of the properties as well as a shareholder lawsuit, which argued that there had not been an independent, fair valuation of the properties and that there were myriad conflicts of interest. Mr. Lampert was the chief executive and largest shareholder of Sears, as well as the chairman of the board of trustees for Seritage. The lawsuit was settled this year for $ 40 million.

Cutting companies into two pieces — a real estate side and an operations side — is a move hedge funds and private-equity investors have been performing for years. This can sometimes strain the operations side as it uses its cash to make rental payments.

For Sears Holdings, the Seritage deal meant it now had to pay rent on properties it once owned. Sears Holdings paid an additional $ 200 million in rent and other expenses to Seritage in 2016.

In its statement, the company said rent payments would decline as Sears Holdings reduces the size of its stores, as more customers shop online. This year, it expects rent payments to total $ 160 million.

But as Sears Holdings exits those leases, higher-paying tenants are coming in, which benefits Seritage shareholders, including Mr. Lampert’s hedge funds. “In properties where Sears has given up the lease,” said Wes Golladay, an analyst at RBC Capital Markets, “Seritage has moved in restaurants, small grocers, gym chains, a pretty broad-based group of new lessees who are paying more than $ 18 a square foot, from the $ 4 that Sears was paying.”

In recent years, Mr. Lampert has played the role of Sears Holdings’s primary banker, collecting fees while providing loans to the operations side of the company. As a result, Mr. Lampert’s hedge fund and other entities hold a significant portion of Sears Holdings’s debt, in effect making him one of the company’s biggest lenders. The bulk of that debt is secured by property or inventory.

The debt ensures that even if Sears Holdings goes into bankruptcy, Mr. Lampert has a prominent seat at the table — and a voice in its future course — since debt-holders come before shareholders in working out a corporate restructuring through the courts.

Some observers say it is difficult for them to imagine a scenario in which Sears doesn’t go into bankruptcy. “There has been a long, steady sale of assets to the point where the cupboard is pretty bare,” said Ken Perkins, the president of Retail Metrics, which provides independent research to institutional investors. “It has been a long, slow bleed to keep the company afloat.”

“It is a shame,” Mr. Perkins added, “because this was such an iconic retailer.”