Good afternoon, dear programmers!
Faced with a small problem, according to TK, you need to make an adaptive menu in a header with a small shadow: 
But when the width of the window changes and the elements of the list begin to jump, a shadow remains in the vacant space, like this: 
I tried to make a shadow not to the ul tag, but to the li, or a tag, but in this case, each button has its own shadow, which also falls on the neighboring button. I will be very pleased with your advice on how to cope with it.
The code on jsbin is http://jsbin.com/zebiqaboki/edit?html,css,output
PS I apologize for such a collective farm explanation))