#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
template <class T>
void read(T &val) {
  T x = 0;
  T bz = 1;
  char c;
  for (c = getchar(); (c < '0' || c > '9') && c != '-'; c = getchar())
    ;
  if (c == '-') {
    bz = -1;
    c = getchar();
  }
  for (; c >= '0' && c <= '9'; c = getchar()) x = x * 10 + c - 48;
  val = x * bz;
}
const int maxn = 1e6 + 11;
const int mod = 1e9 + 7;
int t;
long long x, a[maxn], n, m, b[maxn];
bool mpp[maxn];
bool vis[maxn];
int p[maxn];
int main() {
  read(n);
  read(m);
  long long x, y, k;
  read(x);
  read(k);
  read(y);
  for (int i = 1; i <= n; i++) read(a[i]), p[a[i]] = i;
  for (int i = 1; i <= m; i++) read(b[i]), mpp[b[i]] = true;
  for (int i = 1; i <= n; i++) {
    if (!mpp[a[i]]) vis[i] = true;
  }
  int pos1 = 1;
  for (int i = 1; i <= n; i++) {
    if (vis[i]) continue;
    if (a[i] != b[pos1]) {
      puts("-1");
      return 0;
    }
    pos1++;
  }
  long long ans = 0;
  int xx = 1;
  while (xx <= n) {
    if (vis[xx] == false) {
      xx++;
      continue;
    }
    long long cnt = 0, mx = 0;
    int l = xx - 1;
    while (vis[xx]) {
      cnt++;
      xx++;
      mx = max(mx, a[xx - 1]);
    }
    if (cnt >= k) {
      if (a[l] > mx || a[xx] > mx) {
        ans += cnt / k * min(x, k * y);
      } else {
        cnt -= k;
        ans += x;
        ans += cnt / k * min(x, k * y);
      }
      ans += cnt % k * y;
    } else {
      if (a[l] < mx && mx > a[xx]) {
        puts("-1");
        return 0;
      }
      ans += cnt * y;
    }
  }
  printf("%lld\n", ans);
  return 0;
}
