All settings are stored in database in serialized form. Default config value should be serialized too. But when submitting the form with complex settings are data are in different form - also arrays. I think I found several problems in your implementation (and fix some of them), but the code is not easy to read and understand.
1/ add method serialize/deserialize to class admin_setting - with deafult implemenation just returning data as text
2/ always store defaults in serialized form (only strings - the same as in database)
2/ make get_setting() to return deserialized form (arrays, strings, etc)
3/ decide if write_setting() should accept only deserialized, serialized, or both forms
4/ fix all uses of write_setting() accorning to 3/
The resulting code should be easier to read, most bugs should be fixed during the conversion, it would be easier to add new complex types.