#include <bits/stdc++.h>
using namespace std;
const int MOD = 1e9 + 7;
const int AX = 1e5 + 666;
int mark[AX];
struct Node {
  long long l, r;
  int id;
  bool friend operator<(const Node &a, const Node &b) {
    return ((a.l == b.l && a.r < b.r) || a.l < b.l);
  }
} a[AX];
struct NO {
  long long l, r;
  int id;
} c[AX];
Node b[AX];
int n;
long long x, y;
bool cmp(NO a, NO b) { return a.r > b.r; }
int binary_search(long long x) {
  int l = 0, r = n - 1;
  while (l <= r) {
    int mid = (l + r) >> 1;
    if (a[mid].l > x) {
      r = mid - 1;
    } else {
      l = mid + 1;
    }
  }
  return l;
}
int main() {
  scanf("%d%I64d%I64d", &n, &x, &y);
  for (int i = 0; i < n; i++) {
    scanf("%I64d%I64d", &a[i].l, &a[i].r);
    a[i].id = i;
    c[i].id = i;
    c[i].l = a[i].l;
    c[i].r = a[i].r;
  }
  memset(mark, 0, sizeof(mark));
  sort(a, a + n);
  sort(c, c + n, cmp);
  long long res = 0LL;
  int tot = 1;
  for (int i = 0; i <= n; i++) {
    b[i].l = 1000000007;
    b[i].r = 0;
  }
  for (int i = 0; i < n; i++) {
    int pos = binary_search(c[i].r);
    if (pos < 0 || pos >= n || (1LL * y * (a[pos].l - c[i].r) > x)) {
      continue;
    }
    int id;
    if (!mark[a[pos].id]) {
      mark[c[i].id] = tot;
      mark[a[pos].id] = tot;
      id = tot++;
    } else {
      id = mark[a[pos].id];
      if (b[id].l <= c[i].r) {
        while (pos < n && (1LL * y * (a[pos].l - c[i].r) < x) &&
               b[mark[a[pos].id]].l <= c[i].r)
          pos++;
        if (pos < n && (1LL * y * (a[pos].l - c[i].r) < x) &&
            b[mark[a[pos].id]].l > c[i].r) {
          if (!mark[a[pos].id]) {
            mark[c[i].id] = tot;
            mark[a[pos].id] = tot;
            id = tot++;
          } else {
            id = mark[a[pos].id];
          }
        } else
          continue;
      }
      mark[c[i].id] = id;
    }
    b[id].l = min(b[id].l, c[i].l);
    b[id].r = max(b[id].r, a[pos].r);
  }
  for (int i = 1; i < tot; i++) {
    res = (res + x % MOD + 1LL * y * (b[i].r - b[i].l) % MOD) % MOD;
  }
  for (int i = 0; i < n; i++) {
    if (!mark[a[i].id]) {
      res = (res + x % MOD + 1LL * y * (a[i].r - a[i].l) % MOD) % MOD;
    }
  }
  printf("%I64d\n", res);
  return 0;
}
