Structural basis and distal effects of Gag substrate coevolution in drug resistance to HIV-1 protease