Resilient communities for safe cities