#include <bits/stdc++.h>
#define exrep(i, a, b) for(long long i = a; i <= b; i++)
#define rep(i,n)for(long long i=0;i<(long long)(n);i++)
#define all(a) a.begin(), a.end()
#define rall(a) a.rbegin(), a.rend()
using namespace std;
typedef unsigned long long ull;
typedef long long ll;
typedef long double ld;
typedef vector<ll> vl;
typedef vector<vector<ll>> vvl;
typedef pair<ll, ll> P;
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; }
 
const ll MOD=1e9+7;
const ll INF=1e18;
const int MAX=510000;
const double pi=acos(-1);
int dx[4]={1,0,-1,0};
int dy[4]={0,1,0,-1};
ll modpow(ll a, ll n){
  if(n==0)return 1;
  if(n%2==0){
    ll t=modpow(a,n/2);
    return t*t%MOD;
  }
  return a*modpow(a,n-1)%MOD;
}
ll modinv(ll a){
  return modpow(a,MOD-2);
}
long long fac[MAX], finv[MAX], inv[MAX];

// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

// 二項係数計算
long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}
struct UnionFind {
    vector<int> par; // 親ノード
    vector<int> rank; // ランク

    UnionFind(int n = 1) {
        init(n);
    }

    void init(int n = 1) {
        par.resize(n); rank.resize(n);
        for (int i = 0; i < n; ++i) par[i] = i, rank[i] = 0;
    }

    int root(int x) {
        if (par[x] == x) {
            return x;
        }
        else {
            int r = root(par[x]);
            return par[x] = r;
        }
    }

    bool issame(int x, int y) {
        return root(x) == root(y);
    }

    bool merge(int x, int y) {
        x = root(x); y = root(y);
        if (x == y) return false;
        if (rank[x] < rank[y]) swap(x, y);
        if (rank[x] == rank[y]) ++rank[x];
        par[y] = x;
        return true;
    }
};
int h,w;
vector<string>vec;
int numu[3000][3000];
int numd[3000][3000];
int numl[3000][3000];
int numr[3000][3000];
int dfsu(int y,int x){
  int ny=y-1,nx=x;
  int py=y+1,px=x;
  int res=0;
  if(0<=py && py<h && 0<=px && px<w && numu[py][px]!=-1)return numu[y][x]=numu[py][px]-1;
  if(0<=ny && ny<h && 0<=nx && nx<w && vec[ny][nx]=='.'){
    res+=dfsu(ny,nx)+1;
  }
  return numu[y][x]=res;
}
int dfsd(int y,int x){
  int ny=y+1,nx=x;
  int py=y-1,px=x;
  int res=0;
  if(0<=py && py<h && 0<=px && px<w && numd[py][px]!=-1)return numd[y][x]=numd[py][px]-1;
  if(0<=ny && ny<h && 0<=nx && nx<w && vec[ny][nx]=='.')res+=dfsd(ny,nx)+1;
  return numd[y][x]=res;
}
int dfsl(int y,int x){
  int ny=y,nx=x-1;
  int py=y,px=x+1;
  int res=0;
  if(0<=py && py<h && 0<=px && px<w && numl[py][px]!=-1)return numl[y][x]=numl[py][px]-1;
  if(0<=ny && ny<h && 0<=nx && nx<w && vec[ny][nx]=='.')res+=dfsl(ny,nx)+1;
  return numl[y][x]=res;
}
int dfsr(int y,int x){
  int ny=y,nx=x+1;
  int py=y,px=x-1;
  int res=0;
  if(0<=py && py<h && 0<=px && px<w && numr[py][px]!=-1)return numr[y][x]=numr[py][px]-1;
  if(0<=ny && ny<h && 0<=nx && nx<w && vec[ny][nx]=='.')res+=dfsr(ny,nx)+1;
  return numr[y][x]=res;
}
    
int main(){
  cin.tie(0);
  ios::sync_with_stdio(false); 
  COMinit();
  
  cin >> h >> w;
  vec.resize(h);
  rep(i,h) cin >> vec[i];
  rep(i,h){
    rep(j,w){
      numu[i][j]=-1;
      numd[i][j]=-1;
      numl[i][j]=-1;
      numr[i][j]=-1;
    }
  }
  int m=0;
  rep(i,h){
    rep(j,w){
      if(vec[i][j]=='.')chmax(m,dfsu(i,j)+dfsd(i,j)+dfsl(i,j)+dfsr(i,j)+1);
    }
  }
  cout << m << endl;
  
}


Measured memory_bytes: 116224