Try "alter database set restricted_user with rollback immediate" before setting it offline. This will terminiate user connections and rollback their transactions and only allow priviledged users to connect.
Then close the dialog and exit Server Management Studio. Restart it, and the database should be offline.