#include<bits/stdc++.h>
using namespace std;
#define li(i,j,k) for(int i=j ; i<=k ; i++)
#define si(i,j,k) for(int i=j ; i>=k ; i--)
int r,c,k;
char ground[201][201];
int ans=0;
int main(){
scanf("%d%d%d",&r,&c,&k);
li(i,1,r){
scanf("%s",&ground[i]);
}
li(i,1,r){
li(j,0,c-k){
bool ok=true;
li(kk,j,j+k-1){
if(ground[i][kk]=='#'){
ok=false;
break;
}
}
if(ok)ans++;
}
}
li(i,1,r-k+1){
li(j,0,c-1){
bool ok=true;
li(kk,i,i+k-1){
if(ground[kk][j]=='#'){
ok=false;
break;
}
}
if(ok)ans++;
}
}
printf("%d\n",ans);
return 0;
}