"B = value of the Roth IRA at the time the 2024 contribution was made plus that contribution"
No, B = value of the Roth IRA at the time the 2024 contribution was made plus both $7,000 contributions. See CFR 1.408-11 for the definition of the Adjusted Opening Balance:
https://www.law.cornell.edu/cfr/text/26/1.408-11#b
C= $7,000
A = $26,000
B = $15,000 + $7,000 + $7,000 = $29,000
NIA = $7,000 * ($26,000 - $29,000) / $29,000 = negative $724.14 (which is a loss)
To accomplish the recharacterization of the $7,000 contribution made for 2024, the amount transferred to the traditional IRA would need to be $6,275.86.