#include <bits/stdc++.h>
using namespace std;
const int MAXN = 200010;
pair<int, int> gas[MAXN];
vector<int> stations[4];
int dp[4][MAXN];
int calculate(int tip, int start, int s) {
  int ona_posle =
      lower_bound(stations[tip].begin(), stations[tip].end(), start) -
      stations[tip].begin();
  int do_kraja = dp[tip][ona_posle];
  int do_mene = stations[tip][ona_posle] - start - s;
  if (do_mene < 0) do_mene = 0;
  return do_mene + do_kraja;
}
void fail() { puts("-1 -1"); }
int main() {
  int e, s, n, m;
  scanf("%d %d %d %d", &e, &s, &n, &m);
  for (int i = 1; i <= n; i++) {
    scanf("%d %d", &gas[i].first, &gas[i].second);
    if (gas[i].second <= e) {
      for (int t = 1; t <= gas[i].first; t++) {
        stations[t].push_back(gas[i].second);
      }
    }
  }
  for (int t = 1; t <= 3; t++) {
    stations[t].push_back(e);
    sort(stations[t].begin(), stations[t].end());
    stations[t].resize(unique(stations[t].begin(), stations[t].end()) -
                       stations[t].begin());
    dp[t][(int)stations[t].size() - 1] = 0;
    for (int i = (int)stations[t].size() - 2; i >= 0; i--) {
      int to_next = stations[t][i + 1] - stations[t][i] - s;
      if (to_next < 0) to_next = 0;
      dp[t][i] = dp[t][i + 1] + to_next;
    }
  }
  vector<int> starts(m);
  for (int i = 0; i < m; i++) {
    scanf("%d", &starts[i]);
    int need_worst = calculate(3, starts[i], s);
    int need_semi = calculate(2, starts[i], s);
    int need_best = calculate(1, starts[i], s);
    if (need_best > 0) {
      fail();
    } else {
      printf("%d %d\n", need_semi, need_worst - need_semi);
    }
  }
  return 0;
}
