improved tabs implementation