We study optical collisions of Na atoms with N(2), CO, C(2)H(2), and CO(2) molecules in a crossed-beam experiment. Excited electronic states of the collision complex are selectively populated during the collision. We measure the relative population of the Na(3p) fine-structure levels after the collision and observe in this way the nonadiabatic transitions occuring in the final phase of the collision process. For the NaCO, NaC(2)H(2), and NaCO(2) systems new ab initio potential surfaces were generated. The theoretical analysis of the nonadiabatic electron dynamics on the excited potential surfaces is made within the classical-path formalism. The results are in good qualitative agreement with the experimental data and provide insight into the nonadiabatic mechanisms prevailing during the evolution in the upper 3p manifold. The differences between the different collisional systems are related to the presence and system-specific locations of conical intersections and avoided crossing seams in the excited potential surfaces.