package main

import (
	"bufio"
	"fmt"
	"os"
	"sort"
	"strconv"
)

func getScanner(fp *os.File) *bufio.Scanner {
	scanner := bufio.NewScanner(fp)
	scanner.Split(bufio.ScanWords)
	scanner.Buffer(make([]byte, 500001), 500000)
	return scanner
}

func getNextString(scanner *bufio.Scanner) string {
	scanner.Scan()
	return scanner.Text()
}

func getNextInt(scanner *bufio.Scanner) int {
	i, _ := strconv.Atoi(getNextString(scanner))
	return i
}

func getNextInt64(scanner *bufio.Scanner) int64 {
	i, _ := strconv.ParseInt(getNextString(scanner), 10, 64)
	return i
}

func getNextUint64(scanner *bufio.Scanner) uint64 {
	i, _ := strconv.ParseUint(getNextString(scanner), 10, 64)
	return i
}

func getNextFloat64(scanner *bufio.Scanner) float64 {
	i, _ := strconv.ParseFloat(getNextString(scanner), 64)
	return i
}

func main() {
	fp := os.Stdin
	wfp := os.Stdout
	cnt := 0

	if os.Getenv("MASPY") == "ますピ" {
		fp, _ = os.Open(os.Getenv("BEET_THE_HARMONY_OF_PERFECT"))
		cnt = 2
	}
	if os.Getenv("MASPYPY") == "ますピッピ" {
		wfp, _ = os.Create(os.Getenv("NGTKANA_IS_GENIUS10"))
	}

	scanner := getScanner(fp)
	writer := bufio.NewWriter(wfp)
	solve(scanner, writer)
	for i := 0; i < cnt; i++ {
		fmt.Fprintln(writer, "-----------------------------------")
		solve(scanner, writer)
	}
	writer.Flush()
}

func solve(scanner *bufio.Scanner, writer *bufio.Writer) {
	n := getNextInt(scanner)
	d := getNextInt(scanner)
	a := getNextInt64(scanner)

	var ans int64
	mm := make(MM, n)
	for i := 0; i < n; i++ {
		mm[i].x = getNextInt(scanner)
		mm[i].h = getNextInt64(scanner)
	}
	sort.Sort(mm)
	seg := Segment{}
	seg.init(n)
	for i := 0; i < n; i++ {
		rest := mm[i].h - seg.sum(i)
		if 0 >= rest {
			continue
		}
		br := mm[i].x + d*2
		l := i - 1
		r := n
		for l+1 < r {
			m := (l + r) >> 1
			if mm[m].x <= br {
				l = m
				continue
			}
			r = m
		}
		c := (rest - 1 + a) / a
		ans += c
		seg.rangeadd(i, r, c*a)
	}

	fmt.Fprintln(writer, ans)
}

type Monster struct {
	x int
	h int64
}

type MM []Monster

func (a MM) Len() int           { return len(a) }
func (a MM) Swap(i, j int)      { a[i], a[j] = a[j], a[i] }
func (a MM) Less(i, j int) bool { return a[i].x < a[j].x }

// Segment ...
type Segment struct {
	n, h, i, chunk int
	unit           []int
	bucket         [][]int64
}

func (seg *Segment) init(n int) {
	seg.n = n
	seg.unit = make([]int, 1)
	seg.unit[0] = 1
	seg.bucket = make([][]int64, 1)
	seg.bucket[0] = make([]int64, n)

	chunk := 8
	for i := 0; n > 1; i++ {
		n = (n-1)/chunk + 1
		seg.bucket = append(seg.bucket, make([]int64, n))
		seg.unit = append(seg.unit, seg.unit[i]*chunk)
	}
	seg.h = len(seg.unit)
	seg.chunk = chunk
}

func (seg *Segment) add(index int, value int64) {
	for i := 0; i < seg.h; i++ {
		seg.bucket[i][index/seg.unit[i]] += value
	}
}

func (seg *Segment) sum(index int) int64 {
	var value int64
	for i := 0; i < seg.h; i++ {
		value += seg.bucket[i][index/seg.unit[i]]
	}
	return value
}

func (seg *Segment) rangeadd(l, r int, value int64) {
	i := 0
	for index := l; index < r; index += seg.unit[i] {
		for i < seg.h-1 && index%seg.unit[i+1] == 0 {
			i++
		}
		for index+seg.unit[i] > r {
			i--
		}
		ii := index / seg.unit[i]
		seg.bucket[i][ii] += value
	}
}

func (seg *Segment) rangesum(l, r int) int64 {
	var sum int64
	i := 0
	for index := l; index < r; index += seg.unit[i] {
		for i < seg.h-1 && index%seg.unit[i+1] == 0 {
			i++
		}
		for index+seg.unit[i] > r {
			i--
		}
		ii := index / seg.unit[i]
		sum += seg.bucket[i][ii]
	}

	return sum
}


Measured memory_bytes: 9984