#include <bits/stdc++.h>
bool check(long long A, long long B, long long C, long long D) {
  int clock = 1;
  while (1) {
    ++clock;
    if (A < B) {
      return false;
    }
    if (A > C) A -= (A - C) / B * B;
    if (A <= C) A += D;
    if (A < B) {
      return false;
    }
    A -= B;
    if (A <= C) A += D;
    if (clock > 1e6) return 1;
  }
}
int main() {
  long long A, B, C, D;
  scanf("%lld", &A);
  while (~scanf("%lld%lld%lld%lld", &A, &B, &C, &D)) {
    printf("%s\n", check(A, B, C, D) ? "Yes" : "No");
  }
  return 0;
}
