We present a new closure relation that is an extension of the Percus-Yevick approximation. In the proposed closure, we introduce an additional term and a mixing coefficient that can be determined by imposing a condition of thermodynamic self-consistency. Moreover, the mixing coefficient is calculated analytically within a linear approximation. In the case of a monodisperse system of hard spheres, we compare the results of our model to well-established thermodynamic expressions and also to the structural properties of fairly known closure approximations. In the second case, and using an equivalent scheme, the new closure relation is extended to the depletion potential between two large hard spheres immersed in a liquid of small hard spheres. In both cases, the results of our model are in good agreement with numerical simulations performed at intermediate concentrations.