import std.stdio, std.conv, std.string, std.array, std.range, std.algorithm, std.container;
import std.math, std.random, std.bigint, std.datetime, std.format;
void main(string[] args){ if(args.length > 1) if(args[1] == "-debug") DEBUG = 1; solve(); }
void log()(){ writeln(""); } void log(T, A ...)(T t, lazy A a){ if(DEBUG) write(t, " "), log(a); } bool DEBUG = 0; 
string read(){ static string[] ss; while(!ss.length) ss = readln.chomp.split; string res = ss[0]; ss.popFront; return res; }
// ----- ----- ----- ----- ----- ----- ----- ----- ----- ----- ----- ----- //

void solve(){
	
	int h = read.to!int;
	int w = read.to!int;
	
	char[][] as;
	foreach(i; 0 .. h){
		as ~= readln.chomp.to!(char[]);
	}
	
	
	int[][] ys = new int[][](h, w);
	foreach(i; 0 .. h) foreach(j; 0 .. w){
		if(as[i][j] == '.') ys[i][j] += 1;
	}
	int[][] xs = new int[][](h, w);
	
	foreach(i; 0 .. h) foreach(j; 0 .. w){
		if(as[i][j] == '#') xs[i][j] = 0;
		else if(j == 0) xs[i][j] = 1;
		else xs[i][j] = xs[i][j - 1] + 1;
		ys[i][j] += xs[i][j] - 1;
	}
	log("xs:", xs);
	log("ys:", ys);
	
	foreach(i; 0 .. h) foreach_reverse(j; 0 .. w){
		if(as[i][j] == '#') xs[i][j] = 0;
		else if(j == w - 1) xs[i][j] = 1;
		else xs[i][j] = xs[i][j + 1] + 1;
		ys[i][j] += xs[i][j] - 1;
	}
	log("xs:", xs);
	log("ys:", ys);
	
	foreach(i; 0 .. h) foreach(j; 0 .. w){
		if(as[i][j] == '#') xs[i][j] = 0;
		else if(i == 0) xs[i][j] = 1;
		else xs[i][j] = xs[i - 1][j] + 1;
		ys[i][j] += xs[i][j] - 1;
	}
	log("xs:", xs);
	log("ys:", ys);
	
	foreach_reverse(i; 0 .. h) foreach(j; 0 .. w){
		if(as[i][j] == '#') xs[i][j] = 0;
		else if(i == h - 1) xs[i][j] = 1;
		else xs[i][j] = xs[i + 1][j] + 1;
		ys[i][j] += xs[i][j] - 1;
	}
	log("xs:", xs);
	log("ys:", ys);
	
	long ans = -1;
	foreach(i; 0 .. h) foreach(j; 0 .. w){
		ans = max(ans, ys[i][j]);
	}
	
	ans.writeln;
}
