Order resultset by configured value and then list all the rest

This isn’t possible with WP_Query. To achieve your goal multiple queries are necessary, one for each country, with the results fetched separately then combined in PHP manually.

You also can’t use meta_query to sort, meta_query is for filtering/searching post meta, which is very expensive and gets slower as your meta table gets larger. Post meta is optimised for get_post_meta, fetching values when you already know the post ID/key. It was never intended for searching/filtering for posts by value, that’s why taxonomies were added.

If you want to change the sorting to use meta, refer to the sorting official docs, which show that you can sort by meta_value or meta_value_num for a single key ( meta_value_key ), defined using meta_key_value and orderby, with a limited number of options for how to sort:

‘meta_value‘ – Note that a ‘meta_key=keyname‘ must also be present in the query. Note also that the sorting will be alphabetical which is fine for strings (i.e. words), but can be unexpected for numbers (e.g. 1, 3, 34, 4, 56, 6, etc, rather than 1, 3, 4, 6, 34, 56 as you might naturally expect). Use ‘meta_value_num‘ instead for numeric values. You may also specify ‘meta_type‘ if you want to cast the meta value as a specific type. Possible values are ‘NUMERIC’, ‘BINARY’, ‘CHAR’, ‘DATE’, ‘DATETIME’, ‘DECIMAL’, ‘SIGNED’, ‘TIME’, ‘UNSIGNED’, same as in ‘$meta_query‘. When using ‘meta_type’ you can also use ‘meta_value_*’ accordingly. For example, when using DATETIME as ‘meta_type’ you can use ‘meta_value_datetime’ to define order structure.

Listing the values and a priority or order they go in is not possible. It’s possible to do this with a list of post IDs and it will return the posts in the order specified, but in all those cases the order is already known before the query is executed.

Achieving what you desire with the main query will not be possible without executing multiple WP_Query beforehand, then extracting the results in PHP and compiling an array of post IDs and passing them to pre_get_posts. This will be unreliable and very slow.

The only feasible route I can foresee, is an integration via a plugin with software such as Elastic Search or Algolia.