#include <bits/stdc++.h>
using namespace std;
const int N = 105;
int n, t;
int ans = 1e6, pos = 0;
int s[N], d[N];
int main() {
  cin >> n >> t;
  for (int i = 0; i < n; i++) {
    cin >> s[i] >> d[i];
    if (s[i] >= t) {
      if (s[i] < ans) {
        pos = i;
        ans = min(ans, s[i]);
      }
    } else {
      if (ans > s[i] + d[i] * (int)ceil((float)(t - s[i]) / (float)d[i])) {
        ans = s[i] + d[i] * (int)ceil((float)(t - s[i]) / (float)d[i]);
        pos = i;
      }
    }
  }
  cout << pos + 1;
}
