#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6 + 10, md = 1e9 + 7;
char str[maxn];
map<int, int> cnt;
int main() {
  gets(str);
  int n = strlen(str), res = 0;
  vector<int> dp(n + 2, 0);
  stack<int> st;
  for (int i = 0; i <= n - 1; ++i) {
    if (st.empty() || (str[st.top()] == str[i]))
      st.push(i);
    else if (str[st.top()] == '(' && str[i] == ')') {
      int x = st.top();
      st.pop();
      res = max(res, i - x + 1 + (x - 1 >= 0 ? dp[x - 1] : 0));
      dp[i] = i - x + 1 + (x - 1 >= 0 ? dp[x - 1] : 0);
      cnt[dp[i]]++;
    } else {
      st.push(i);
    }
  }
  if (res)
    cout << res << " " << cnt[res] << endl;
  else
    puts("0 1");
}
