Tag names moved to constants. Element scoping determination algorithms implemented. Testing required.