Mikhail S. Gorbachev has succeeded in reshaping the Communist Party in his own centrist image to brace for a challenge from workers and radicals who are quitting the party to organize an opposition. The 28th congress of the Communist Party, billed in advance as a bastion of hard-liners, closed Friday after dumping most of the Old Guard. The delegates also accepted much of Gorbachev's plan to transfer decision-making from the party to the government _ which he also heads. But the government faces increasing discontent, especially among workers, as well as ethnic unrest that is shredding the country at the edges. The struggle intensified Wednesday, when coal miners across the country staged a one-day protest strike and urged workers to leave the party. The miners also are organizing an independent trade union to press demands that the government resign and that all Communist Party assets be nationalized and distributed to rival political groups. Disgruntled workers might flock to the banner of Boris N. Yeltsin, who sent a shock through the Kremlin Thursday by walking out of the Communist congress, quitting the party. He said his first loyalty was to his new job, president of Russia, by far the largest of the 15 Soviet republics. Other leading reformers followed Yeltsin out of the party, including the new mayors of Moscow and Leningrad, the biggest Soviet cities. Despite the split in the party, the first since 1921, Gorbachev was jovial Friday as he closed the two-week Communist congress, which many had predicted would be dominated by hard-liners. Instead, Gorbachev scored a sweeping victory, removing his leading hard-line critic, Yegor K. Ligachev, from the Politburo. He also won approval of a restructuring of top party bodies to transfer power to the government. The danger for Gorbachev is that central authorities could lose touch with the people. The people, in turn, are using Gorbachev's democratic reforms to win control of legislatures throughout the country and challenge central government and party bodies. The atmosphere was tense in Moscow before the national party congress because it followed harsh criticism of Gorbachev's performance by traditionalists at a congress of party members in the Russian republic. Ligachev led the attack, urging Gorbachev to relinquish the top party job if he retained the national presidency. Ligachev complained that the party Politburo, the body that traditionally has ruled the Soviet Union, had been excluded from discussions of economic reform. Gorbachev had instead steered the program through the newly created Presidential Council. The mood was so foreboding that Yeltsin and other reformers recommended postponing the national congress. But the workers and reformers took the offensive. Nine minutes into the first session, miner Vladimir I. Bludov demanded that Gorbachev and other leaders resign. Gorbachev brushed aside the suggestion, noting that the congress was due to elect the general secretary, the Politburo and the Central Committee. He also told delegates that senior party leaders opposed his proposal to expand the Politburo from 12 to 30 members and to create a new deputy party leader's post to direct day-day-affairs. The congress was the stormiest since 1921, when the party faced armed uprisings from angry workers and sailors, and the most momentous since 1956, when Nikita S. Khrushchev denounced the late dictator Josef V. Stalin. The warmest applause was for Ligachev's warning that anti-Communist forces were gaining strength. But his tone was milder than at the Russian Communist Party congress, and he did not repeat his call for Gorbachev to relinquish the party leadership. Other hard-liners tempered their rhetoric and, together with moderates, drew together under Gorbachev. Many said that although they objected to one man heading the party and the government simultaneously, he was the only person capable of holding the party together. Gorbachev engineered his election as chairman of the committee drafting new party rules. Working behind the scenes, he revived his plans to restructure the party leadership. The congress voted to expand the Central Committee from 249 to 412 members, most of them centrists like Gorbachev. The delegates also approved a Gorbachev plan that drastically cut the Politburo's power, doubling its size and including the party heads of the 15 republics _ a move designed to ease ethnic tension. Moreover, he eliminated the Old Guard. Of the 24 Politburo members, only Gorbachev and his newly elected deputy Vladimir Ivashko remain from the former group. Only Gorbachev has been a member of the body more than eight months.