A two-scale approach to elastohydrodynamic lubrication