SAN FRANCISCO — Of all the blue state legal challenges to President Donald Trump, none have delivered as big a blow as two court rulings striking down his tariffs on imports from dozens of countries.