MOSCOW (AP) — The U.S. and Russian presidents tentatively agreed to meet in a last-ditch effort to stave off a possible Russian invasion of Ukraine, even as sustained shelling continued Monday in a conflict in eastern Ukraine that Western powers fear could provide the spark for a broader war.

If Russia invades, as the U.S. warns Moscow has already decided to do, the meeting will be off. Still the prospect of a face-to-face summit resuscitated hopes that diplomacy could prevent a devastating conflict, which would result in massive casualties and huge economic damage in Europe, which is heavily dependent on Russian energy.

Russia has massed an estimated 150,000 troops on three sides of Ukraine — the biggest such buildup since the Cold War. And Western officials have warned that Russian President Vladimir Putin is now merely looking for a pretext to invade the country, a western-looking democracy that has defied Moscow’s attempts to pull it back into its orbit.

Moscow denies it has any plans to attack, but wants Western guarantees that NATO won’t allow Ukraine and other former Soviet countries to join as members. It has also demanded the alliance halt weapons deployments to Ukraine and roll back its forces from Eastern Europe — demands flatly rejected by the West.

With the prospect of war looming, French President Emmanuel Macron scrambled to broker a meeting between U.S. President Joe Biden and Putin.

Macron’s office said both leaders had “accepted the principle of such a summit,” to be followed by a broader meeting that would include other “relevant stakeholders to discuss security and strategic stability in Europe.”

The language from Moscow and Washington was more cautious, but neither side denied a meeting is under discussion.

U.S. national security adviser Jake Sullivan said the administration has always been ready to talk to avert a war — but was also prepared to respond to any attack.

“So when President Macron asked President Biden yesterday if he was prepared in principle to meet with President Putin, if Russia did not invade, of course President Biden said yes,” he told NBC’s “Today” show on Monday. “But every indication we see on the ground right now in terms of the disposition of Russian forces is that they are, in fact, getting prepared for a major attack on Ukraine.”

Kremlin spokesman Dmitry Peskov told reporters Monday that Putin and Biden could meet if they consider it “feasible,” but emphasized that “it’s premature to talk about specific plans for a summit.”

Macron’s office said that U.S. Secretary of State Antony Blinken and Russian Foreign Minister Sergey Lavrov are set to lay the groundwork for the potential summit when they meet Thursday. The French leader has been trying to play go-between to avert a new war in Europe, and his announcement followed a flurry of calls by Macron to Putin, Biden, British Prime Minister Boris Johnson and Ukrainian President Volodymyr Zelenskyy.

Even as the diplomacy pressed ahead, there were signs it might not head off a broader conflict. In on particularly dire signal, Russia and its ally Belarus announced Sunday that they were extending massive war games on Belarus’ territory, which could offer a staging ground for an attack on the Ukrainian capital, Kyiv, located just 75 kilometers (less than 50 miles) south of the border.

Starting Thursday, shelling also spiked along the tense line of contact that separates Ukrainian forces and Russian-backed rebels in Ukraine’s eastern industrial heartland of Donbas. Over 14,000 people have been killed since conflict erupted there in 2014, shortly after Moscow annexed Ukraine’s Crimean Peninsula.

Ukraine and the separatist rebels have traded blame for massive cease-fire violations with hundreds of explosions recorded daily. The world is watching the fighting warily since Western officials have warned for weeks that Russia would look for a pretext to invade — and that the conflict in Donbas could provide just such an excuse.

On Friday, separatist officials announced the evacuation of civilians and military mobilization in the face of what they described as an imminent Ukrainian offensive on the rebel regions. Ukrainian officials have strongly denied any plans to launch such an attack and described the evacuation order as part of Russian provocations intended to set the stage for an invasion.

While Russia-backed separatists have charged that Ukrainian forces were firing on residential areas, Associated Press journalists reporting from several towns and villages in Ukrainian-held territory along the line of contact have not witnessed any notable escalation from the Ukrainian side and have documented signs of intensified shelling by the separatists that destroyed homes and ripped up roads.

Some residents of the main rebel-held city of Donetsk described sporadic shelling by Ukrainian forces, but they added that it wasn’t on the same scale as earlier in the nearly 8-year-old conflict in the east.

The separatist authorities said Monday that at least four civilians were killed by Ukrainian shelling over the past 24 hours and several others were wounded. Ukraine’s military said two Ukrainian soldiers were killed over the weekend, and another serviceman was wounded Monday.

Ukrainian military spokesman Pavlo Kovalchyuk said the Ukrainian positions were shelled 80 times Sunday and eight times early Monday, noting that the separatists were “cynically firing from residential areas using civilians as shields.” He insisted that Ukrainian forces weren’t returning fire.

Oleksiy Danilov, the head of Ukraine’s National Security and Defense Council, also denied that Ukrainian forces were firing on rebel-held territory, noting that “our military can only retaliate and fire back if their lives are in danger.”

In the village of Novognativka on the government-controlled side, 60-year-old Ekaterina Evseeva, said the shelling was worse than at the height of fighting early in the conflict.

“We are on the edge of nervous breakdowns. And there is nowhere to run,” she said, her voice trembling.

Evseeva said that residents were hunkering down in basements amid the renewed fighting: “Yesterday I saw my neighbor with her 2-month-old as she was running to the basement. It shouldn’t be like this.”

Amid the heightened invasion fears, the Kremlin reacted angrily to a New York Times report that the U.S. administration has sent a letter to the United Nations human rights chief claiming that Moscow has compiled a list of Ukrainians to be killed or sent to detention camps after the invasion. Peskov, the Kremlin spokesman, said the claim was a lie and no such list exists.

Russian officials have shrugged off Western calls to deescalate by pulling back troops, arguing that Moscow is free to deploy troops and conduct drills wherever it likes on its territory — and at the invitation of allies, Belarus.

Throughout the crisis, Ukraine’s leaders have sought to project calm — repeatedly playing down the threat of an invasion.

Ukrainian Defense Minister Oleksii Reznikov said Monday that Russia has amassed 147,000 troops around Ukraine, including 9,000 in Belarus, arguing that the number is clearly insufficient for an offensive on the Ukrainian capital from the north.

“The talk about an attack on Kyiv from the Belarusian side sounds ridiculous,” he said, charging that Russia is using the troops there as a scare tactic.

The European Union’s top diplomat, foreign policy chief Josep Borrell, welcomed the prospect of a Biden-Putin summit but said the 27-nation bloc has finalized its package of sanctions for use if Putin orders an invasion.

“The work is done. We are ready,” said Borrell. He provided no details about who might be targeted.

Ukrainian Foreign Minister Dmytro Kuleba said Monday that the European Union has also agreed to send military officers to the country in an advisory role. It’s likely to take several months to set up.

___

Karmanau reported from Kyiv, Ukraine, and Cook from Brussels. Lori Hinnant in Kyiv; Angela Charlton in Paris; Zeke Miller and Aamer Madhani in Munich, Germany; Geir Moulson in Berlin; and Ellen Knickmeyer, Robert Burns, Matthew Lee and Darlene Superville in Washington contributed to this report.

___

Follow AP’s coverage of the Ukraine crisis at https://apnews.com/hub/russia-ukraine