Absorption line studies of reflection from horizontally inhomogeneous layers