Limit on Charitable Deductions

I am wanting to confirm that TurboTax is handling this correctly for the Charitable Deduction limit as a % of AGI.

 

Say AGI is $100,000.

The Charitable Contribution Limit should be 60% of this for cash contributions = $60,000

We've done an appreciated stock contribution earlier this year for $2,000. This would be limited to 30% of AGI = $30,000.

We also did $1,000 of non-cash contributions. This would be limited to 50% of AGI = $50,000.

 

I'd like to make the maximum cash contribution to a Donor Advised Fund. It seems to me that I should be able to contribute $57,000 ($60,000 - $2,000 - $1000).

 

But, the system (and the IRS worksheet from online) calculation somehow results in a deduction of $42,000 and a carryover of $18,000.

 

I put the worksheet form and related calculations into Excel and using Goal Seek to maximize the cash contribution with no carryover returns $47,000 (50% of AGI less the stock and non-cash, I guess).

 

Am I misunderstanding?  How is it coming up with the $42,000 limit?