The area where three spectators at a rally were fatally struck by a car was described as "highly dangerous" in official documents.

A fatal accident inquiry into their deaths heard setup plans for the Jim Clark Rally near Coldstream in the Scottish Borders said the area around where the accident happened should be "kept clear".

Photographer Iain Provan, 64, his 63-year-old partner Elizabeth Allan, known as Betty, and Len Stern, 71, died after a car lost control and left the road at the rally in May 2014.

The inquiry at Edinburgh Sheriff Court was shown the setup plans for the Swinton stage, where those killed were standing in a field entrance near a humpbacked bridge.

The plans stipulated: "The area prior to and after this bridge is highly dangerous and should be kept clear.

"Do not allow standing within three metres of the hedge. Definitely no photographers.

"Any incursions should be reported immediately and the stage stopped until rectified."

Witness Brian Bolton, 46, told the inquiry it was "ludicrous" spectators were standing at the site, which he said was a "no go area".

He said he had never seen people standing there before in decades of attending the rally as cars could lose control after crossing the bridge.

Mr Bolton said tape across the field entrance indicated people should keep away from the area.

Advocate depute Andrew Brown QC, for the Crown, asked what he would say to people who were of the view that it was safe to stand behind that tape.

Mr Bolton replied: "How's tape going to stop a car?"

The painter and decorator from Duns said he was standing further along the course, looking down on the accident site, when the crash happened in the afternoon of May 31, 2014.

He said: "I saw the car coming over the bridge and just going sideways."

He described the aftermath of the crash: "I couldn't believe what I'd just seen and it was pandemonium down at the bottom.

"People were coming up and saying it was absolute carnage."

The inquiry also heard from first-time rally spectator Andrew Davies, 50, from the Borders, who was standing in the field entrance when the crash happened and escaped injury by moving out of the way.

He told the court he did not think he should have been allowed to stand at the site.

The inquiry previously heard from spectator Donald Martin, 64, who was injured in the crash and said he thought the tape indicated a safe place to stand behind.

Spectator Garry Wilson, 48, told the inquiry how he fled from the car and then tried to resuscitate one of the casualties as he is a trained first aider.

He said he saw a woman lying on the ground with blood on her face being helped by two people so moved on to help a man lying near her.

He found no pulse but gave CPR for around 25 minutes, joined by paramedics who tried to restart the man's heart with a defibrillator.

Mr Wilson said the driver of the car was in an "awful state".

He told the court: "He was just going 'I'm sorry, I'm sorry'."

The joint fatal accident inquiry is examining the deaths at the 2014 Jim Clark Rally and also that of spectator Joy Robson, 51, at the Snowman Rally near Inverness the previous year.

The inquiry, before Sheriff Kenneth Maciver QC, continues.