UN climate talks near end as countries divided on emissions, funding