Scotland's rural affairs secretary has said 90.4% of EU farm payments were made before the midnight deadline.

Fergus Ewing said it meant 16,521 farmers had now received their Common Agricultural Policy payments.

The government has been facing pressure to deal with "failures" in the subsidies payment system.

It emerged on Friday that any fine may be waived and an extension to the deadline no longer required if a 90% target was met.

Mr Ewing said: "As of close of business last night, and subject to final confirmation, we have made BPS, Greener and Young Farmer payments to 16,521 farmers and crofters, valued at £343m. This represents around 90.4% of expected total payments for those schemes.

"We are awaiting a final determination from the European Commission regarding an extension to the payment deadline to 15 October, if necessary, on the grounds of the acutely challenging delivery and implementation issues we face in Scotland.

"Our payments made to date, along with the national loan scheme mean that the majority of farmers and crofters have received their money."

Image caption Fergus Ewing told the rural economy committee that 90% of payments were projected to be made by Friday

He added: "Over the coming weeks we will be working hard to ensure that we complete the remaining payments due to farmers and crofters as quickly as possible."

The government has accelerated payments in recent weeks amid political pressure from opposition parties, and First Minister Nicola Sturgeon has apologised to farmers for "failures" with the system.

An extension was granted in 2016, after problems arose with a new £178m IT system for delivering the payments.

Audit Scotland has estimated that fines for missing the deadlines could run to £60m, and have warned there are still "significant costs and risks for the Scottish government" over the IT problems.

The latest deadline pressure has sparked a political row at Holyrood, with Scottish Conservative leader Ruth Davidson accusing Mr Ewing and Ms Sturgeon of "not being straight" with MSPs and farmers.

The first minister said "rapid daily progress" was being made in getting payments through, and insisted she and her ministers had been clear with parliament. Mr Ewing described criticism as "fanciful".