Inside the frenzied negotiations to salvage a controversial real estate tax break