#include <bits/stdc++.h>
using namespace std;
const int N = 505, P = 1000000007;
using ll = long long;
int a[N], c[N], r[N], aa[N], ans[N], mx, p[N], tmp[N], t[N], f, b;
ll n;
void mul(int f[], int g[], int ans[]) {
  for (int i = 0; i < mx * 2; i++) r[i] = 0;
  for (int i = 0; i < mx; i++)
    for (int j = 0; j < mx; j++) r[i + j] = (r[i + j] + 1ll * f[i] * g[j]) % P;
  for (int i = mx * 2 - 2; i >= mx; --i)
    for (int j = mx - 1; j >= 0; --j)
      r[i + j - mx] = (r[i + j - mx] + P - r[i] * 1ll * c[j] % P) % P;
  for (int i = 0; i < mx; i++) ans[i] = r[i];
}
int main() {
  ios::sync_with_stdio(false);
  cin >> f >> b >> n;
  for (int i = 1; i <= f; i++) cin >> a[i];
  for (int i = 1, x; i <= b; i++) cin >> x, mx = max(mx, x), ++t[x];
  for (int i = 0; i < mx; i++) c[i] = P - t[mx - i];
  c[mx] = 1;
  for (int i = 1; i <= f; i++) {
    for (int j = 0; j < mx; j++) ans[j] = tmp[j] = 0;
    if (mx > 1)
      tmp[1] = 1;
    else
      tmp[0] = P - c[0];
    for (ans[0] = 1; a[i] > 0; a[i] >>= 1, mul(tmp, tmp, tmp))
      if (a[i] & 1) mul(ans, tmp, ans);
    for (int j = 0; j < mx; j++) aa[j] = (aa[j] + ans[j]) % P;
  }
  for (int i = 0; i < mx; i++) ans[i] = 0;
  for (ans[0] = p[0] = 1; n > 0; n >>= 1, mul(aa, aa, aa))
    if (n & 1) mul(ans, aa, ans);
  for (int i = 0; i < mx; i++)
    for (int j = 0; j <= i; j++) p[i] = (t[j] * 1ll * p[i - j] + p[i]) % P;
  ll out = 0;
  for (int i = 0; i < mx; i++) out = (out + ans[i] * 1ll * p[i]) % P;
  cout << out << endl;
  return 0;
}
