Shallow quake in Indonesia kills 3, damages hundreds of homes; two-week emergency declared in affected areas