Functional hydration and conformational gating of proton uptake in cytochrome c oxidase.