down to the wire

down to the wire (close to the end; to near a deadline, until the last possible moment; running out of time; to have little time remaining) — не ясный до самого конца; решающийся в последний момент; || испытывающий нехватку времени, в цейтноте

Example 1: I'll have to stay late tomorrow to get this finished. I'm down to the wire on the proposal. — ... День сдачи на носу..

Example 2: The negotiations continued down to the wire but they finally ended successfully. (Сonnection)

Example 3: He finished his project on time even though it was right down to the wire. — Ему удалось вовремя сдать проект, хотя сроки очень сильно поджимали.

Example 4: We went right down to the wire but we were able to finish the job on time. — Мы день и ночь сидели над заданием и до последнего момента не было понятно, успеем мы к cроку или нет.

------------------
The “wire” (= a thread that marks where a race ends) goes over the finish line of some horse races, and a picture is taken from this to decide the result of a close race.
---------
The first person to cross the finish line is the winner. When a race is very close it is not clear who the winner is until they “cross the wire.” A contest goes “down to the wire” when it comes right down to the finish line before the winner can be determined. (GoEnglish)

see also
[race against time]
[crunch time]
working flat out
working to beat the band