#include <bits/stdc++.h>
using namespace std;
long long n, l, k;
long long ans;
long long f[2][1100000];
long long sum[2][1100000];
int poi;
struct node {
  int pos, num;
} a[1100000];
int cmp(node x, node y) { return x.num < y.num; }
int main() {
  scanf("%I64d%I64d%I64d", &n, &l, &k);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i].num);
    a[i].pos = i;
  }
  sort(a + 1, a + 1 + n, cmp);
  for (int i = 1; i <= n; i++) {
    f[1][i] = 1;
    sum[1][i] = sum[1][i - 1] + f[1][i];
    if (a[i].pos <= l % n) {
      ans += f[1][i] % 1000000007 * ((long long)(l / n + 1) % 1000000007) %
             1000000007;
      ans %= 1000000007;
    } else {
      ans += f[1][i] * (long long)(l / n);
      ans %= 1000000007;
    }
  }
  for (int i = 2; i <= k && i <= l / n; i++) {
    poi = 1;
    for (int j = 1; j <= n; j++) {
      while (a[poi].num <= a[j].num && poi <= n) poi++;
      poi--;
      f[i & 1][j] = sum[(i - 1) & 1][poi];
      sum[i & 1][j] = sum[i & 1][j - 1] + f[i & 1][j];
      sum[i & 1][j] %= 1000000007;
      if (a[j].pos <= l % n) {
        ans += f[i & 1][j] % 1000000007 *
               ((long long)(l / n + 1 - (i - 1)) % 1000000007) % 1000000007;
        ans %= 1000000007;
      } else {
        ans += f[i & 1][j] % 1000000007 *
               ((long long)(l / n - (i - 1)) % 1000000007) % 1000000007;
        ans %= 1000000007;
      }
    }
  }
  poi = 1;
  if (k > l / n) {
    for (int i = 1; i <= n; i++)
      if (a[i].pos <= l % n) {
        while (a[poi].num <= a[i].num && poi <= n) poi++;
        poi--;
        f[(l / n + 1) & 1][i] = sum[(l / n) & 1][poi];
        ans += f[(l / n + 1) & 1][i];
        ans %= 1000000007;
      }
  }
  printf("%I64d\n", ans);
  return 0;
}
