Thanks for your good work. My brother has a brother-in-law, a kid I knew in passing, who is in a federal institution for similar reasons. He relies a lot on the reading material he gets from my brother and his wife. He's locked up a few thousand miles from his family. It's a long but finite sentence. He settled in after a few years, and seems to be doing pretty well. There's reason to think he may come out in better shape than he went in. 

My father-in-law was one of the first people civilly committed for child sex abuse in his state. He'd been at it for decades, and was starting to slide into dementia. They couldn't get a criminal conviction, because of the statutes of limitations on his known offense, but he was a very real and active danger to children, with no potential for rehabilitation. He spent several years in psychiatric prison, and two years in a secure clinical facility, where he died. 

These are just anecdotes, not endorsements of the often over-punative system.