The Scottish Government is trying to help the whole of the UK with its efforts to prevent a so-called hard Brexit, Holyrood's Constitution Secretary has said.

Derek Mackay was speaking after the Tories accused the SNP Government of using the UK vote to leave the European Union to push ahead with its plans for "independence at any cost".

A draft Bill that could pave the way for a second independence referendum has been published for consultation by the Scottish Government.

READ MORE: Scotland's Finance Secretary calls for 'real investment' amid 'turbulent times'

Mr Mackay said that legislation "is about the mechanics of the referendum should we conclude that independence is the best or only way to protect Scotland's interests".

In the EU referendum, 62% of Scots voters backed remaining in the bloc, but a majority across the UK opted to leave - prompting First Minister Nicola Sturgeon to warn that a second independence vote is "highly likely".

However Ms Sturgeon has said she will consider all options, with the First Minister wanting to protect Scotland's place in the single market as part of Brexit negotiations.

READ MORE: Scotland's Finance Secretary calls for 'real investment' amid 'turbulent times'

In addition, she wants the Scottish Government to gain responsibility for immigration and the ability to strike its own international deals.

Mr Mackay told MSPs at Holyrood: "Our starting point remains protecting Scotland's national interests, as set out by the First Minister.

"We're considering all possible options to ensure Scotland's continuing relationship with and place in Europe.

"Scotland delivered a strong, unequivocal vote to remain, and our focus is on ensuring Scotland's interests are protected, particularly as it appears the UK Government now favours a hard Brexit."

But Conservative MSP Oliver Mundell pointed out the draft Bill had been put forward before the SNP's "National Survey" on Scotland's future, which aims to canvass the views of two million people, has been completed.

READ MORE: Scotland's Finance Secretary calls for 'real investment' amid 'turbulent times'

The Tory, who is the son of Scottish Secretary David Mundell, said that by "pushing ahead with the Bill, as the Government plans to do as its number one priority... exposes the SNP's true colours and true intentions - independence at any cost".

He asked the Constitution Secretary why the SNP "are so keen to ignore the two million No voters who made their intentions crystal clear" in the 2014 independence referendum.

Mr Mundell also said the SNP are "keen to airbrush out of history" the one million Scots who voted to leave the EU in June.

READ MORE: Scotland's Finance Secretary calls for 'real investment' amid 'turbulent times'

But Mr Mackay said: "Every part of this nation, every local authority area, voted to remain within Europe, and that is what should be respected by the UK Government.

"Now the ball is in the court of the UK Government to respect Scotland and respect how the people voted, and if they do that then maybe we can find a solution that works for every part of the UK.

"Here's a Scottish Government that's not just standing up for Scotland, but actually trying to help the whole of the UK."