Teenager convicted of terror plot sentenced to life in prison over Mad Hatter case