the dying moments/seconds of something - definition and synonyms

phrase
  1. the period of time just before something ends

    He scored in the dying moments of the game.

See also main entry: dying