土壇場

Etymology
Originally, a platform made of dirt used to perform executions (decapitations) in the Edo period​

Noun

 * 1)  the last minute; the eleventh hour