#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string arr[n];
  int sum = 0;
  for (int i = 0; i < n; i++) cin >> arr[i];
  for (int i = 0; i < n; i++)
    for (int j = 0; j < n; j++)
      if (arr[i].at(j) == '.') sum++;
  for (int i = 1; i < n - 1; i++)
    for (int j = 1; j < n - 1; j++)
      if (arr[i].at(j) == '.') {
        if (arr[i].at(j + 1) == '.')
          if (arr[i].at(j - 1) == '.')
            if (arr[i + 1].at(j) == '.')
              if (arr[i - 1].at(j) == '.') {
                arr[i].at(j) = '#';
                arr[i + 1].at(j) = '#';
                arr[i - 1].at(j) = '#';
                arr[i].at(j + 1) = '#';
                arr[i].at(j - 1) = '#';
                sum -= 5;
              }
      }
  if (sum == 0)
    cout << "YES";
  else
    cout << "NO";
}
