Again, risk to benefit analysis. Children need interaction with children their age in order to learn to be successful in the future. Silly examples notwithstanding, once the parent has chosen to raise the child, it is part of their responsibility to teach the child such analysis. Most parents in the US use a set of rules given them by their parents that already considered such things, or didn't but is used to make those determinations. This is where most people learn religion.
Once the decision to raise a child is made, creating the best environment for success is the most moral action. The highest percentage of success is from a two-parent environment, the child learns important social lessons from each parent.
Creating children randomly and on accident is not the most moral of activities as it places an entire lifetime at risk solely for a moment's pleasure.
Again, to answer the original question (repeating myself here), it is not always "harmful" to participate in casual sex, however it is always possibly very harmful and such a risk forced upon an innocent is wrong.