A 25-year-old medical student is preparing for an exam while consuming large amounts of coffee. He learns that pepsin, a stomach enzyme, functions at a very acidic pH (~2), while alkaline phosphatase operates in a basic pH (~9). Which of the following best explains the effect of pH on enzyme activity?