#include <bits/stdc++.h>
using namespace std;
inline char gc() {
  static char now[1 << 16], *S, *T;
  if (T == S) {
    T = (S = now) + fread(now, 1, 1 << 16, stdin);
    if (T == S) return EOF;
  }
  return *S++;
}
inline long long read() {
  long long x = 0, f = 1;
  char ch = gc();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = gc();
  }
  while (ch <= '9' && ch >= '0') x = x * 10 + ch - '0', ch = gc();
  return x * f;
}
long long dp[2][1100000], l, block, ans;
int n, m, a[1100000], b[1100000], nn, k;
int main() {
  n = read();
  l = read();
  k = read();
  int pre = 0, now = 1;
  dp[pre][0] = 1;
  block = l / n;
  for (int i = 1; i <= n; ++i) b[i] = a[i] = read();
  sort(b + 1, b + n + 1);
  nn = unique(b + 1, b + n + 1) - b - 1;
  for (int i = 1; i <= n; ++i) a[i] = lower_bound(b + 1, b + nn + 1, a[i]) - b;
  for (int i = 1; i <= block + 1 && i <= k; ++i) {
    for (int j = 0; j <= nn; ++j) dp[now][j] = 0;
    for (int j = 1; j <= nn; ++j) (dp[pre][j] += dp[pre][j - 1]) %= 1000000007;
    for (int j = 1; j <= n; ++j) (dp[now][a[j]] += dp[pre][a[j]]) %= 1000000007;
    for (int j = 1; j <= nn; ++j)
      (ans += (block - i + 1) % 1000000007 * (dp[now][j] % 1000000007) %
              1000000007) %= 1000000007;
    for (int j = 1; j <= l - block * n; ++j)
      (ans += dp[pre][a[j]]) %= 1000000007;
    pre ^= 1;
    now ^= 1;
  }
  printf("%lld\n", ans);
  return 0;
}
