#include <bits/stdc++.h>
using namespace std;
const int IINF = 1e9;
const long long LINF = 1e18;
const long long mod = 1e9 + 7;
int main() {
  int H, W;
  cin >> H >> W;
  vector<vector<tuple<int, int, int, int>>> v(
      H, vector<tuple<int, int, int, int>>(W, make_tuple(0, 0, 0, 0)));
  vector<string> s(H);
  for (int i = 0; i < (int)(H); i++) {
    cin >> s[i];
  }
  for (int i = 0; i < (int)(H); i++) {
    int left = -1;
    for (int j = 0; j < (int)(W); j++) {
      if (s[i][j] == '#') {
        left = j;
      } else {
        v[i][j] = make_tuple(left, 0, 0, 0);
      }
    }
    int right = W;
    for (int j = W - 1; 0 <= j; j--) {
      if (s[i][j] == '#') {
        right = j;
      } else {
        int l = get<0>(v[i][j]);
        v[i][j] = make_tuple(l, right, 0, 0);
      }
    }
  }
  for (int j = 0; j < (int)(W); j++) {
    int up = -1;
    for (int i = 0; i < (int)(H); i++) {
      if (s[i][j] == '#') {
        up = i;
      } else {
        int l = get<0>(v[i][j]);
        int r = get<1>(v[i][j]);
        v[i][j] = make_tuple(l, r, up, 0);
      }
    }
    int down = H;
    for (int i = H - 1; 0 <= i; i--) {
      if (s[i][j] == '#') {
        down = i;
      } else {
        int l = get<0>(v[i][j]);
        int r = get<1>(v[i][j]);
        int u = get<2>(v[i][j]);
        v[i][j] = make_tuple(l, r, u, down);
      }
    }
  }
  int res = -1;
  for (int i = 0; i < (int)(H); i++) {
    for (int j = 0; j < (int)(W); j++) {
      int l = get<0>(v[i][j]);
      int r = get<1>(v[i][j]);
      int u = get<2>(v[i][j]);
      int d = get<3>(v[i][j]);
      if (l < r && u < d) {
        res = max(res, (r - l) + (d - u) - 3);
      }
    }
  }
  cout << res << endl;
  return 0;
}
