Adaptive phenotype drives resistance to androgen deprivation therapy in prostate cancer