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 (
    13472, 16467, 12307, 13465, 15679, 14649, 
    13049, 16497, 15497, 15835, 12146, 
    13682, 14078, 13467, 13844, 13919, 
    12645, 13924, 13672
  )

Query time 0.01119

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": 46,
          "filtered": 100,
          "index_condition": "gp.group_id in (13472,16467,12307,13465,15679,14649,13049,16497,15497,15835,12146,13682,14078,13467,13844,13919,12645,13924,13672)"
        }
      },
      {
        "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
19615 14804 68212 12146
19615 6604 68211 12146
19793 15483 68827 12307
19793 15482 68826 12307
19793 6070 68828 12307
20170 17915 70581 12645
20170 17914 70580 12645
20170 4865 70582 12645
20616 19306 72095 13049
20616 3499 72094 13049
21073 21116 73575 13465
21073 2442 73574 13465
21075 21118 73579 13467
21075 2440 73578 13467
21080 21123 73589 13472
21080 2435 73588 13472
21303 22094 74534 13672
21303 22093 74535 13672
21303 2003 74533 13672
21313 22114 74564 13682
21313 22113 74565 13682
21313 1993 74563 13682
21501 1689 75242 13844
21501 22797 75243 13844
21587 23021 75502 13919
21587 1550 75501 13919
21592 23026 75512 13924
21592 1542 75511 13924
21757 1266 76075 14078
21757 23502 76076 14078
22383 335 78476 14649
22383 25887 78472 14649
22383 25888 78473 14649
22383 25889 78474 14649
22383 25890 78475 14649
23362 32712 81045 15497
23362 32772 81046 15497
23549 35217 81717 15679
23549 35319 81718 15679
23712 36291 82320 15835
23712 36633 82321 15835
24211 41310 84353 16467
24211 41286 84352 16467
24239 41549 84460 16497
24239 41499 84459 16497
24239 41550 84461 16497