#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
const int N = 2e5 + 5;
int n, m, a[N], b[N];
int x, k, y;
long long ans;
bool get(int l, int r) {
  if (l > r) return true;
  int cnt = r - l + 1, mx = 0, tmp = l;
  while (tmp <= r) mx = max(mx, a[tmp]), tmp++;
  bool yes = (l - 1 >= 0 && a[l - 1] > mx);
  yes |= (r + 1 < n && a[r + 1] > mx);
  if (cnt < k && !yes) return false;
  ans += 1ll * (cnt % k) * y;
  cnt -= cnt % k;
  if (y * k >= x)
    ans += 1ll * (cnt / k) * x;
  else if (yes)
    ans += 1ll * cnt * y;
  else
    ans += 1ll * (cnt - k) * y + x;
  return true;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m >> x >> k >> y;
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < m; i++) cin >> b[i];
  int j = 0, lst = 0;
  for (int i = 0; i < m; i++) {
    while (j < n && a[j] != b[i]) j++;
    if (j == n || !get(lst, j - 1)) return cout << -1, 0;
    lst = j + 1;
  }
  if (!get(lst, n - 1)) return cout << -1, 0;
  cout << ans;
  return 0;
}
