Image copyright AFP Image caption Donald Trump has said he is confident his administration's appeal will succeed

US President Donald Trump has attacked the judge who blocked his travel ban, saying Americans should blame the courts "if something happens".

Mr Trump also said he had instructed border officials to check people entering America "very carefully".

The ban, affecting people from seven mainly-Muslim countries, was blocked by the federal judge in Seattle on Friday.

Saturday saw a federal appeals court reject the Trump administration's request to reinstate the ban.

This means that Mr Trump's directive will remain suspended and visa holders from Iraq, Syria, Iran, Libya, Somalia, Sudan and Yemen will be allowed to enter the US until the full case has been heard.

The justice department and two US states challenging the ban, Washington and Minnesota, have been asked to present more arguments.

In their latest submission to the appeals court, the two states says that lifting the suspension would "unleash chaos" and adversely affect their economies.

They also lodged a statement by a host of national security experts - including former secretaries of state John Kerry and Madeleine Albright, and former CIA director Leon Panetta - which describes the travel ban as ineffective, dangerous and counterproductive.

Is Trump's immigration order legal?

Who does travel ban affect?

World reacts to Trump order

President Trump has ramped up his criticism of Judge James Robart, who blocked the ban, and the country's judiciary.

In a series of tweets, Mr Trump said: "I have instructed Homeland Security to check people coming into our country VERY CAREFULLY. The courts are making the job very difficult!"

"Just cannot believe a judge would put our country in such peril. If something happens blame him and court system. People pouring in. Bad!"

The president had earlier called Judge Robart's ruling "ridiculous", describing him as a "so-called judge".

US border checks

All persons arriving at a US port of entry are inspected by Customs and Border Protection (CBP) officers

Visitors must have valid US visas or hold "Green Cards" that authorise them to live and work in the US permanently

Travellers under the Visa Waiver Program must apply for authorisation via ESTA (Electronic System for Travel Authorization) before their visit

Image copyright EPA Image caption A CBP officer at Atlanta airport

Visitors must complete declaration forms

Travellers may have their fingerprints and photos taken

CBP officers may also ask to inspect luggage or personal items

CBP uses biometric technologies to verify travellers' identities

Travellers from certain countries can use Automated Passport Control (APC)

US federal judge James Robart's ruling is a temporary restraining order preventing elements of President Trump's executive order being implemented in order to allow the two states time to mount a legal challenge to them.

Washington and Minnesota argue that the ban is unconstitutional and denied people with valid entry documents the right to travel without legal recourse. It also violated freedom of religion rights by appearing to target Muslims, they said.

The ruling suspends: the seven-country travel ban; the temporary refugee admissions ban; the reprioritisation of minority religion (interpreted to mean Christian) refugee claims; and the ban on Syrian refugees. The cap on overall US refugee admissions this year of 50,000 is not covered by the judge's ruling.

In its appeal, the justice department said Judge Robart had overreached by "second guessing" the president on a national security matter.

It also argued that only the president could decide who can enter or stay in the US.

Media playback is unsupported on your device Media caption "The American people are very accustomed to this president speaking his mind" - Vice-President Mike Pence

Democrats and some Republicans have criticised Mr Trump's comments about the country's judiciary.

Democratic Senator Patrick Leahy, a member of the Senate Judiciary Committee, said Mr Trump seemed "intent on precipitating a constitutional crisis".

Meanwhile, Republican Senate leader Mitch McConnell told CNN it was "best to avoid criticising judges individually".

Judge Robart has served on the federal bench since 2004 after nomination by President George W Bush.

Media playback is unsupported on your device Media caption "We are very excited, we are very happy" - Iraqi national flies to the US with his family

Friday's ruling has also seen visa holders from the affected nations scramble to get flights to the US, fearing they have a slim window to enter.

The state department has been reversing visa cancellations and US homeland security employees have been told by their department to comply with the ruling.

The ban caused confusion at US and foreign airports when it came into force.

Polls suggest that US public opinion is sharply divided on the travel ban.