SELECT 
  pfv.feature_id, 
  pfv.product_id, 
  pfv.variant_id, 
  gp.group_id 
FROM 
  cscart_product_features_values AS pfv 
  INNER JOIN cscart_product_variation_group_products AS gp ON pfv.product_id = gp.product_id 
  INNER JOIN cscart_product_variation_group_features AS gpf ON gpf.group_id = gp.group_id 
  AND gpf.feature_id = pfv.feature_id 
WHERE 
  pfv.lang_code = 'vi' 
  AND gp.group_id IN (
    12247, 12575, 15656, 15352, 12572, 13692, 
    15353, 13693, 12574, 13691, 13836, 
    15354, 16668
  )

Query time 0.00222

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "gp",
          "access_type": "range",
          "possible_keys": ["PRIMARY", "idx_group_id"],
          "key": "idx_group_id",
          "key_length": "3",
          "used_key_parts": ["group_id"],
          "rows": 54,
          "filtered": 100,
          "index_condition": "gp.group_id in (12247,12575,15656,15352,12572,13692,15353,13693,12574,13691,13836,15354,16668)"
        }
      },
      {
        "table": {
          "table_name": "gpf",
          "access_type": "ref",
          "possible_keys": ["PRIMARY", "idx_group_id"],
          "key": "idx_group_id",
          "key_length": "3",
          "used_key_parts": ["group_id"],
          "ref": ["dev_db.gp.group_id"],
          "rows": 1,
          "filtered": 100
        }
      },
      {
        "table": {
          "table_name": "pfv",
          "access_type": "ref",
          "possible_keys": [
            "PRIMARY",
            "fl",
            "lang_code",
            "product_id",
            "fpl",
            "idx_product_feature_variant_id"
          ],
          "key": "idx_product_feature_variant_id",
          "key_length": "12",
          "used_key_parts": ["product_id", "feature_id", "lang_code"],
          "ref": ["dev_db.gp.product_id", "dev_db.gpf.feature_id", "const"],
          "rows": 1,
          "filtered": 100,
          "attached_condition": "pfv.lang_code = 'vi'",
          "using_index": true
        }
      }
    ]
  }
}

Result

feature_id product_id variant_id group_id
19725 15226 68602 12247
19725 6357 68603 12247
20077 16888 70183 12572
20077 16881 70182 12572
20077 16880 70181 12572
20077 16879 70180 12572
20077 16878 70179 12572
20077 16877 70178 12572
20077 16876 70177 12572
20077 16875 70176 12572
20077 5300 70176 12572
20083 17264 70239 12574
20083 17263 70238 12574
20083 17262 70237 12574
20083 17261 70236 12574
20083 17260 70235 12574
20083 17259 70234 12574
20083 17258 70233 12574
20083 5296 70240 12574
20084 17273 70249 12575
20084 17272 70248 12575
20084 17271 70247 12575
20084 17270 70246 12575
20084 17269 70245 12575
20084 17268 70244 12575
20084 17267 70243 12575
20084 17266 70242 12575
20084 17265 70241 12575
20084 5294 70250 12575
21322 22130 74589 13691
21322 22129 74588 13691
21322 1981 74590 13691
21323 22132 74592 13692
21323 22131 74591 13692
21323 1980 74593 13692
21324 22134 74595 13693
21324 22133 74594 13693
21324 1979 74596 13693
21490 22765 75211 13836
21490 1716 75210 13836
23233 31815 80579 15352
23233 31633 80578 15352
23234 31636 80580 15353
23234 31816 80581 15353
23235 31637 80582 15354
23235 31817 80583 15354
23521 34555 81643 15656
23521 34648 81644 15656
24443 43834 85250 16668
24443 43824 85249 16668
24443 43835 85251 16668
24443 43836 85252 16668
24443 43837 85253 16668
24443 43838 85254 16668