The latest in a string of militant attacks on Kenya's coast has dealt a fresh blow to the economy, but the threat this time goes beyond the tourist trade to an ambitious $25.5 billion port and transport scheme next to the historic town of Lamu.
Lamu residents, often working in tourism like others along Kenya's palm-fringed coastline, have seen visitors flee with each assault, growing used to empty alleyways that once bustled with visitors and idle dhows awaiting clients on the waterfront. But, till now, most attacks targeted Mombasa, 240 km (150 miles) south. This week gunmen hit closer to Lamu, striking twice in 24 hours around Mpeketoni town just 30 km (20 miles) from the 14th century Arab trading post. About 65 people died.
"Our future hinges on getting our port," said Munawar Abdalla, 36, a local mason crafting ornate chairs styled with ebony and camel bone. "But if there's no peace here how can the Lamu port work out. I'm very worried."
Lamu is at the heart of a grand scheme that aims to connect new oil fields of Uganda and Kenya, and possibly the wells of South Sudan, by pipeline to the Indian Ocean. It also aims to link land-locked Ethiopia, an emerging economic power, to a brand new container port along a planned north Kenyan highway.
Critics have always said raising $25.5 billion for a 32-berth port, new roads and other infrastructure by 2030 was optimistic at the best of times. But attacks on Lamu's doorstep make the tough task of raising financing an even harder sell.
It may force plans to be stripped back, reducing it to a pipeline and oil terminal to deal with crude flows from Uganda and Kenya that may reach 500,000 barrels per day in a few years.
"This is a big important political economic project but if you don't achieve the safety of whatever staff you have working on this project, it will be hard to attract foreign investors," said Mark Bohlund, an Africa economist at IHS Global Insight.
The project is dubbed LAPSSET, which stands for Lamu Port-South Sudan-Ethiopia Transport. It was dreamed up before Kenya or Uganda found commercial oil and is a bid to keep Kenya as east Africa's main trade gateway, easing pressure on its congested Mombasa port. But it has struggled to secure backers.
Driving Up Costs
A Chinese firm was awarded a $484 million contract to build three berths early last year, but there has been no sign of work starting. Meanwhile, a rival $10 billion port project in southern neighbor Tanzania powers ahead with Chinese backing.
Fresh worries around Lamu, which is 110 km (70 miles) from war-torn Somalia to the north, will drive up insurance premiums and could make any work pricier if fewer firms compete.
"It absolutely raises the cost of the project," said Clare Allenson, Africa expert at Eurasia Group consultancy. "You will have to invest heavily in private security and other precautions and insurance for all elements of the project will go up."
The government insists it is tackling the security problem.
Although Kenya has blamed a string of assaults in recent months in Mombasa and the capital Nairobi on Somalia's al Shabaab militant group, President Uhuru Kenyatta said his political rivals were the ones behind the Mpeketoni attacks.
That drew heated denials from opponents and raised eyebrows among experts after al Shabaab claimed responsibility, even if they acknowledge the Mpeketoni attacks on a poor area showed different tactics to al Shabaab's raid on Nairobi's upscale shopping mall last year in which 67 people died.
The government insists Kenya is still a safe place to invest, while those behind the port project remain upbeat.
"I don’t want us to overplay this," LAPSSET Chief Executive Silvester Kasuku told Reuters from Nairobi offices, adding the latest attack would not hurt the project "in any meaningful way because any issue over insecurity is not just unique to Kenya."
Yet, there is still little activity at the port site, a short boat ride from Lamu through the mangroves.
A gleaming four-storey building stands above the mangrove bushes, home to Kenya Ports Administration, but the bay which it overlooks shows no sign of dredging or other work for the container berths. Some workers on site are nervous.
"We are now worried about security because of these attacks," said one worker this week, near the remote concrete port authority building sheathed in a mirror glass and stone exterior. "We don't have any police here."
Some analysts say the planned berths may never be built, limiting the project to a pipeline and oil terminal without the grander trimmings of highways, railways and container ships.
"The pipeline and oil component still has promise but the broader scheme ... is at risk," Allenson said. "There is a pretty big difference between risk appetite for oil projects versus broader shipping (plans)."
Energy firms, long used to extracting oil from tough places, are unlikely to be fazed. Britain's Tullow Oil is determined to pipe oil it has discovered in Kenya's northeastern Turkana region and Uganda to the coast.
That means crossing north Kenya, a region close to Somalia where attacks between rival groups over land and other disputes are common. A cheaper pipeline above ground could be target.
Tullow, which works with Africa Oil in Kenya, has said it plans to bury the piping, citing both environmental and security reasons. It has also said the pipeline route and other details have yet to be confirmed as studies are still going on.
Exports from Kenya and Uganda, where France's Total and China's CNOOC also operate, could start in about three years, possibly trucking oil out initially.
Kenya and Uganda have begun work on plans for the pipeline that could cost $2.5 billion to $5 billion. South Sudan, which now exports oil via a pipeline through Sudan, could join in.
Yet, with plans still in the works, some fret that tensions in Lamu will increase. Mahmoud Abdulkadir, a 62-year-old Muslim preacher, worries radical Islamist ideas that have won over youths further south on Kenya's coast may be spreading north.
He points to Swahili graffiti near Lamu's 19th century fort that reads "Boko Haram ndio njia", or "Boko Haram is the way", a reference to the Islamist insurrection in Nigeria on the other side of Africa.
One senior security official said al Shabaab and radical Islamist groups had been playing on the disputes and rivalries between ethnic groups over land ownership and other issues, which might explain why Mpeketoni was hit. "Al Shabaab has been exploiting local grievances," he said.