How a series of security lapses led to near-fatal Trump shooting