#include <algorithm>
#include <iostream>
#include <fstream>
#include <sstream>
#include <bitset>
#include <vector>
#include <deque>
#include <queue>
#include <stack>
#include <list>
#include <map>
#include <set>
#include <cmath>
#include <limits>
#include <numeric>
#include <iomanip>
#include <cstdlib>
#include <iterator>
#include <functional>
#include <unordered_map>
#include <unordered_set>

using namespace std;

typedef unsigned                    ui;
typedef int                         si;
typedef long                        sl;
typedef long long                   ll;
typedef unsigned long long          ull;

// ----------------

template <typename A, typename B>
string to_string(pair<A, B> p);

template <typename A, typename B, typename C>
string to_string(tuple<A, B, C> p);

template <typename A, typename B, typename C, typename D>
string to_string(tuple<A, B, C, D> p);

string to_string(const string& s) {
  return '"' + s + '"';
}

string to_string(const char* s) {
  return to_string((string) s);
}

string to_string(bool b) {
  return (b ? "true" : "false");
}

string to_string(vector<bool> v) {
  bool first = true;
  string res = "{";
  for (int i = 0; i < static_cast<int>(v.size()); i++) {
    if (!first) {
      res += ", ";
    }
    first = false;
    res += to_string(v[i]);
  }
  res += "}";
  return res;
}

template <size_t N>
string to_string(bitset<N> v) {
  string res = "";
  for (size_t i = 0; i < N; i++) {
    res += static_cast<char>('0' + v[i]);
  }
  return res;
}

template <typename A>
string to_string(A v) {
  bool first = true;
  string res = "{";
  for (const auto &x : v) {
    if (!first) {
      res += ", ";
    }
    first = false;
    res += to_string(x);
  }
  res += "}";
  return res;
}

template <typename A, typename B>
string to_string(pair<A, B> p) {
  return "(" + to_string(p.first) + ", " + to_string(p.second) + ")";
}

template <typename A, typename B, typename C>
string to_string(tuple<A, B, C> p) {
  return "(" + to_string(get<0>(p)) + ", " + to_string(get<1>(p)) + ", " + to_string(get<2>(p)) + ")";
}

template <typename A, typename B, typename C, typename D>
string to_string(tuple<A, B, C, D> p) {
  return "(" + to_string(get<0>(p)) + ", " + to_string(get<1>(p)) + ", " + to_string(get<2>(p)) + ", " + to_string(get<3>(p)) + ")";
}

void debug_out() { cerr << endl; }

template <typename Head, typename... Tail>
void debug_out(Head H, Tail... T) {
  cerr << " " << to_string(H);
  debug_out(T...);
}

#ifdef LOCAL
#define debug(...) cerr << "[" << #__VA_ARGS__ << "]:", debug_out(__VA_ARGS__)
#else
#define debug(...) 42
#endif

// ----------------

class Item {
public:
    ll X;
    ll H;
};

class SegmentTree {
public:
    void Init(vector<ll>& a) {
        Values.swap(a);
        Tree.assign(Values.size() * 4, 0);

        Build(1, 0, Values.size() - 1);
    }

    void Init(ll n) {
        vector<ll> a(n, 0);
        Init(a);
    }

    void Build(ll v, ll l, ll r) {
        if (l > r) {
            return;
        }

        if (l == r) {
            Tree[v] = Values[l];
            return;
        }

        const ll m = l + (r - l) / 2;
        Build(v * 2, l, m);
        Build(v * 2 + 1, m + 1, r);
        Tree[v] = Tree[v * 2] + Tree[v * 2 + 1];
    }

    ll Get(ll l, ll r) {
        return Get(1, 0, Values.size() - 1, l, r);
    }

    ll Get(ll v, ll tl, ll tr, ll l, ll r) {
        debug(v, tl, tr, l, r, "get");

        if (l > r) {
            return 0;
        }

        if (tl == l && tr == r) {
            return Tree[v];
        }

        const ll m = (tl + tr) / 2;
        const ll left =  Get(v * 2, tl, m, l, min(r, m));
        const ll right = Get(v * 2 + 1, m + 1, tr, max(l, m + 1), r);
        return left + right;
    }

    ll Get(ll i) {
        return Get(1, 0, Values.size() - 1, i);
    }

    ll Get(ll v, ll tl, ll tr, ll i) {
        if (tl == tr) {
            return Tree[v];
        }

        const ll m = (tl + tr) / 2;
        ll answer = Tree[v];
        if (i <= m) {
            answer += Get(v * 2, tl, m, i);
        } else {
            answer += Get(v * 2 + 1, m + 1, tr, i);
        }
        return answer;
    }

    void Add(ll l, ll r, ll x) {
        Add(1, 0, Values.size() - 1, l, r, x);
    }

    void Add(ll v, ll tl, ll tr, ll l, ll r, ll x) {
        if (l > r) {
            return;
        }

        if (tl == l && tr == r) {
            Tree[v] += x;
            return;
        }

        const ll m = (tl + tr) / 2;
        Add(v * 2, tl, m, l, min(r, m), x);
        Add(v * 2 + 1, m + 1, tr, max(l, m + 1), r, x);
    }

public:
    vector<ll> Tree;
    vector<ll> Values;
};

class SqrtDecomposition {
public:
    void Init(ll n) {
        N = n;
        Factor = ceil(sqrt(N));

        ll size = N / Factor;
        if (size * Factor != N) {
            size += 1;
        }

        debug(N, Factor, size);

        Values.assign(N, 0);
        Deltas.assign(size, 0);
    }

    ll GetBlockStart(ll i) const {
        return i * Factor;
    }

    ll GetBlockEnd(ll i) const {
        return GetBlockStart(i + 1) - 1;
    }

    ll GetBlockIndex(ll i) const {
        return i / Factor;
    }

    void Add(ll l, ll r, ll v) {
        ll l_block = l / Factor;
        ll r_block = r / Factor;

        for (ll i = l_block + 1; i < r_block; ++i) {
            Deltas[i] += v;
        }

        ll to_left = GetBlockEnd(l_block);
        to_left = min(to_left, r);
        for (ll i = l; i <= to_left; ++i) {
            Values[i] += v;
        }

        ll from_right = GetBlockStart(r_block);
        from_right = max(l, from_right);
        if (l_block != r_block) {
            for (ll i = from_right; i <= r; ++i) {
                Values[i] += v;
            }
        }

        debug(l, r, l_block, r_block, to_left, from_right);
    }

    ll Get(ll i) const {
        return Values[i] + Deltas[GetBlockIndex(i)];
    }

public:
    ll Factor = 0;
    ll N = 0;
    vector<ll> Values;
    vector<ll> Deltas;
};

int main(int argc, char *argv[])
{
    std::ios_base::sync_with_stdio(false);

    ll n, d, A;
    cin >> n >> d >> A;

    vector<Item> a(n);
    for (int i = 0; i < n; ++i) {
        cin >> a[i].X >> a[i].H;
    }

    sort(a.begin(), a.end(), [](const Item& l, const Item& r) {
        return l.X < r.X;
    });

    const auto get_last = [&](ll l, ll x) {
        ll r = n - 1;

        ll answer = -1;
        while (l <= r) {
            const ll m = l + (r - l) / 2;
            if (a[m].X <= x) {
                answer = m;
                l = m + 1;
            } else {
                r = m - 1;
            }
        }

        return answer;
    };

    ll answer = 0;

    // SqrtDecomposition s;
    // s.Init(n);

    SegmentTree s;
    s.Init(n);

    for (int i = 0; i < n; ++i) {
        ll damage = s.Get(i);
        ll diff = a[i].H - damage;

        debug(i, damage, diff);
        if (diff <= 0) {
            continue;
        }

        ll bombs = max((ll) ceil(static_cast<double>(diff) / A), 1LL);
        ll cur = bombs * A;
        ll last = get_last(i, a[i].X + d * 2);

        debug(i, cur, last, s.Get(i, i));
        if (last >= 0) {
            s.Add(i, last, cur);
        }

        answer += bombs;

        debug(s.Values, s.Tree);
    }
    cout << answer << endl;

    return 0;
}


Measured memory_bytes: 11264