Spin-Orbit Coupling in Ions in Crystals