// Arup Guha
// 7/22/2022
// Solution to 2021 USACO December Silver Problem: Closest Cow

import java.util.*;
import java.io.*;

public class closest {

	public static void main(String[] args) throws Exception {
	
		BufferedReader stdin = new BufferedReader(new InputStreamReader(System.in));
		
		// Read in data, use disjoint set to id all sets of connected fields.
		StringTokenizer tok = new StringTokenizer(stdin.readLine());
		int numG = Integer.parseInt(tok.nextToken());
		int numN = Integer.parseInt(tok.nextToken());
		int numJ = Integer.parseInt(tok.nextToken());
			
		// Read in grass, will store later in lists.
		int[][] grass = new int[numG][2];
		for (int i=0; i<numG; i++) {
			tok = new StringTokenizer(stdin.readLine());
			grass[i][0] = 2*Integer.parseInt(tok.nextToken());
			grass[i][1] = Integer.parseInt(tok.nextToken());
		}
			
		// Read in Nhoj
		int[] nhoj = new int[numN];
		for (int i=0; i<numN; i++)
			nhoj[i] = 2*Integer.parseInt(stdin.readLine());
		Arrays.sort(nhoj);
			
		// Mapping each x value of Nhoj to its index.
		TreeMap<Integer,Integer> nMap = new TreeMap<Integer,Integer>();
		nMap.put(-1, 0);
		for (int i=0; i<numN; i++)
			nMap.put(nhoj[i], i+1);
			
		// Create a list for every "gap" between farmer Nhoj's cows.
		ArrayList<patch>[] lists = new ArrayList[numN+1];
		for (int i=0; i<=numN; i++) lists[i] = new ArrayList<patch>();
			
		// Now, place each grass patch in the appropriate list.
		for (int i=0; i<numG; i++) {
			int myKey = nMap.lowerKey(grass[i][0]);
			int idx = nMap.get(myKey);
			lists[idx].add(new patch(grass[i][0], grass[i][1]));
		}
			
		// Store the options of what we can get for one cow here.
		ArrayList<Long> options = new ArrayList<Long>();
			
		// Go through each list.
		for (int i=0; i<lists.length; i++) {
			
			// No need to consider.
			if (lists[i].size() == 0) continue;
				
			// We need the list sorted to sweep.
			Collections.sort(lists[i]);
				
			// one cow suffices
			if (i == 0 || i == lists.length-1) {
				options.add(total(lists[i]));
				continue;
			}
			
			// Here is what we earn with placing 2 cows in this interval.
			long both = total(lists[i]);
			
			// One cow and the difference between the two.
			long one = sweep(nhoj[i-1], lists[i], nhoj[i]);
			long diff = both-one;
			
			// Each of these are what we earn with one cow.
			options.add(one);
			options.add(diff);
		}
		
		// Sort from biggest to smallest.
		Collections.sort(options);
		Collections.reverse(options);
		
		// Ta da!
		long total = 0;
		for (int i=0; i<numJ && i<options.size(); i++)
			total += options.get(i);
		System.out.println(total);
	}
	
	// Just returns the sum of tastiness.
	public static long total(ArrayList<patch> a) {
		long res = 0;
		for (patch p: a)
			res += p.value;
		return res;
	}
	
	// Runs sweep of one cow.
	public static long sweep(int low, ArrayList<patch> a, int high) {
		
		// This is the largest window size of treats we can grab.
		int window = (high-low)/2-1;
		int i=0, j=0;
		long sum = 0, best = 0;
		
		// Sweep through the data.
		while (i<a.size() && j<a.size()) {
			
			// Advance my j pointer as far as I can go without the window exceeding maximal length.
			int curX = a.get(i).x;
			while (j<a.size() && a.get(j).x <= curX+window) {
				sum += a.get(j).value;
				best = Math.max(best, sum);
				j++;
			}
			
			// Move the front pointer up.
			sum -= a.get(i).value;
			i++;
		}
		
		// This is the best we did with one cow.
		return best;		
	}
	
}

class patch implements Comparable<patch> {
	
	public int x;
	public long value; 
	
	public patch(int myx, int myv) {
		x = myx;
		value = myv;
	}
	
	public int compareTo(patch other) {
		return this.x - other.x;
	}
}
	