Optical properties of low-energy pions in nuclei