Nonadiabatic ring-polymer instanton rate theory: A generalized dividing-surface approach | Synapse