keeping rails s in the foreground