Technically correct but irrelevant. Childbirth itself takes a couple weeks. A proportional pay gap from that would be well under one percent, and it could be offset by the fact that women live five years longer.
> A proportional pay gap from that would be well under one percent
If only pay gap were proportional... I'm afraid that employers penalize time off work disproportionally, probably exponentially; part-time work doesn't have half the salary of full-time work, and when employees take a few weeks off, they don't forgo only those weeks' salary, but also slow down their future learning, progress and promotions. Whether that's fair or not is debatable (I'd say it makes sense from employers' point of view, but they're probably unnecessarily harsh with it for game-theoretical reasons), but it probably affects all employees taking time off equally, not just women.
This is a hypothetical scenario where parenting roles are equal, meaning lots of men are taking off months, and lots of women are taking off months plus a couple weeks. People take off a couple weeks all the time; it's called vacation. I can't see any meaningful pay difference making sense.