Mel & Robyn Gibson: Oops, We Didn't Think of That!

9/28/2010 9:00 AM PDT

Mel & Robyn Gibson: Oops, We Didn't Think of That!

Mel Gibson and wife Robyn never thought in a million years that one of them would have a child during their marriage with another partner ... and that's why baby Lucia created a big problem.

Sources tell TMZ ... Mel and Robyn created the Icon Trust to provide financial security for their kids.  But when the trust was drafted, it defined "issue" (a fancy name for children) as kids born from Mel or Robyn, not Mel and Robyn.

So then Mel goes and gets Oksana Grigorieva pregnant and baby Lucia is born.  Lucia is automatically a beneficiary under the trust ... something that was never contemplated or intended.  We're told Mel, Robyn and their 7 kids all love Lucia and want to provide for her, but including Lucia in the trust would create major tax issues.

So ... fast forward to the mediation between Mel and Oksana -- the very first term in the agreement states, "Oksana consents to amendment of Icon Trust to exclude Lucia."  Oksana agreed, partly because under the mediation agreement, upon Mel's death, Lucia will receive "no less than $4.3 million ... in addition to the ... $2 million life insurance policy."

But ... if Oksana can successfully disavow the mediation deal, it could throw a major monkey wrench into the Icon Trust.

Stay tuned ...