Hybrid atomistic-coarse-grained treatment of thin-film lubrication. I.