Well, what happens is that jQuery binds the click event handler and then your script continues executing. The bit inside of the event handler will only be executed when somebody clicks on one of the given elements. If you want to set the "nation" variable based on what someone selects, the solution is simple, just move the assignment into the event handler.
e.g. something along these lines
nation = ""// your code...
//maybe call some function that does something with nation