RAIL investigators were today preparing a probe into the cause of a massive derailment and fire on an Ayrshire mainline.

One theory to be investigated is that a rail bridge which collapsed during the freight train crash could have been weakened by work linked to a line upgrade.

A huge clear-up operation on the Kilmarnock line was beginning today after tonnes of fuel was spilled.

The train which was carrying diesel and kerosene burst into flames when it derailed as it a crossed a bridge at Peacock Bank Farm, Stewar-ton, near Kilmarnock.

It split in two around 6.15am yesterday when rear tankers crashed into one another igniting diesel on board.

Flames were seen for miles around and there were fears of further explosions after the tankers also struck a pylon sending power cables crashing down on to the train.

The driver, 45-year-old Anthony Stewart, from Chapelhall, in Lanarkshire, who raised the alarm, had a miraculous escape.

Network Rail, which is responsible for upkeep of the line, said an inspection was carried out almost year ago, and that the bridge was safe.

However, locals fear work carried out on the site recently may have weakened it.

Bosses said the bridge was to be rebuilt as part of a £30million upgrade to the Kilmarnock to Glasgow line.

Work was to start there on February 7, with work starting this weekend on a bridge north of the village.

One local said: "The A735 at Stewarton was to be closed for two weeks to allow the bridge to be demolished but people have been working there for weeks. Land has been cleared and there have been workmen on site.

"There is a real fear among locals it may have weakened the surrounding structure in some way and had it been a few hours later there could have been a steady stream of motorists using that route."

East Ayrshire Council bosses issued a road closure for the A735, the main road between Stewarton and Kilmarnock, for three weeks following yesterday morning's incident.

The bridge was due to be widened soon so that the rail route could be upgraded from single to double track to provide a half hourly service to Glasgow.

Today a Network Rail spokesman said that all aspects of the railway operation will be looked at during the investigation.

He added: "It is too early to come to any conclusion about the cause of this derailment, but certainly nothing will be discounted. The bridge was rigorously inspected last February and we have no reason to believe that it was anything but structurally sound before this incident.

"The bridge is only one of five or six different factors we will be looking into and is not an immediate consideration."

Environmental protection agency SEPA have had teams working on the site overnight monitoring water supplies.

Colin Bayes, SEPA's director of Environmental Protection and Improvement, said: "Once the immediate site has been declared safe for access SEPA officers will able to give further assistance.

"It appears the main affected water course is the Garrier Burn, oil containment booms have placed down the course of the stream. It may take time before the full extent of any environmental impact is known."

Six wagons from the 10 wagon train operated by D B Schenker and travelling from Mossend in Lanarkshire to Riccarton in Ayrshire overturned. Firefighters from Strathclyde Fire and Rescue extinguished the blaze shortly after midday.