Optimal rates for estimation of two-dimensional totally positive distributions