A thief steals a number of rare plants from a nursery. On the way​ out, the thief meets three security​ guards, one after another. To each security​ guard, the thief is forced to give one-half of the plants that he still​ had, plus 2 more.​ Finally, the thief leaves the nursery with 6 plants. How many plants were originally​ stolen?