Metallic nanostructures as electronic billiards for nonlinear terahertz photonics