#include <bits/stdc++.h>
 
using namespace std;
#define ll long long
#define ld long double
 
const ld EPS = 1e-9, PI = acos(-1.);
const ll LINF = 0x3f3f3f3f3f3f3f3f;
const int INF = 0x3f3f3f3f, MOD = 1e9+7;
const int N = 1e5+5;
 
int main(){
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    int t;
    cin >> t;
 
    while(t--) {   
        string s;
        cin >> s;
        int start = s.find('a');
        char ch = 'b';
        int l = start;
        int r = start;
        bool ok = true;

        if(start == -1) {
            cout << "NO" << endl;
            continue;
        }
        
        for(int i = 1; i < s.size(); i++) {
            if(l-1 >= 0) {
                if(s[l-1] == ch) {
                    l = l-1;
                    ch++;
                    continue;
                }
            }

            if(r + 1 < s.size()) {
                if(s[r+1] == ch) {
                    r = r+1;
                    ch++;
                    continue;
                }
            }

            ok = false;
        }

        if(ok) cout << "YES" << endl;
        else cout << "NO" << endl;
    }
}