SELECT 
  v.product_id, 
  v.feature_id, 
  v.value, 
  v.value_int, 
  v.variant_id, 
  f.feature_type, 
  fd.description, 
  fd.prefix, 
  f.parent_id, 
  f.position, 
  gf.position as gposition, 
  vd.variant, 
  fd.suffix 
FROM 
  q_product_features as f 
  LEFT JOIN q_product_features_values as v ON v.feature_id = f.feature_id 
  LEFT JOIN q_product_features_descriptions as fd ON fd.feature_id = v.feature_id 
  AND fd.lang_code = 'en' 
  LEFT JOIN q_product_feature_variants fv ON fv.variant_id = v.variant_id 
  LEFT JOIN q_product_feature_variant_descriptions as vd ON vd.variant_id = fv.variant_id 
  AND vd.lang_code = 'en' 
  LEFT JOIN q_product_features as gf ON gf.feature_id = f.parent_id 
  AND gf.feature_type = 'G' 
WHERE 
  f.status IN ('A') 
  AND v.product_id in (
    45397, 40679, 40680, 40681, 40682, 40683, 
    40684, 40685, 40686, 40687, 40688, 
    40689, 40690, 40691, 40692, 40693, 
    40694, 40695, 40696, 40697, 40698, 
    40699, 40700, 40702, 40703, 40704, 
    40705, 40706
  ) 
  AND f.display_on_catalog = 'Y' 
  AND f.feature_id in (2) 
  AND (
    f.categories_path = '' 
    OR FIND_IN_SET(207, f.categories_path) 
    OR FIND_IN_SET(469, f.categories_path) 
    OR FIND_IN_SET(615, f.categories_path)
  ) 
  AND IF(
    f.parent_id, 
    (
      SELECT 
        status 
      FROM 
        q_product_features as df 
      WHERE 
        df.feature_id = f.parent_id
    ), 
    'A'
  ) IN ('A') 
  AND (
    v.variant_id != 0 
    OR (
      f.feature_type != 'C' 
      AND v.value != ''
    ) 
    OR (f.feature_type = 'C') 
    OR v.value_int != ''
  ) 
  AND v.lang_code = 'en' 
ORDER BY 
  fd.description, 
  fv.position

Query time 0.00193

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "244.21"
    },
    "ordering_operation": {
      "using_temporary_table": true,
      "using_filesort": true,
      "nested_loop": [
        {
          "table": {
            "table_name": "f",
            "access_type": "const",
            "possible_keys": [
              "PRIMARY",
              "status"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id"
            ],
            "key_length": "3",
            "ref": [
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 1,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "0.00",
              "eval_cost": "0.20",
              "prefix_cost": "0.00",
              "data_read_per_join": "432"
            },
            "used_columns": [
              "feature_id",
              "feature_type",
              "categories_path",
              "parent_id",
              "display_on_catalog",
              "status",
              "position"
            ]
          }
        },
        {
          "table": {
            "table_name": "v",
            "access_type": "range",
            "possible_keys": [
              "PRIMARY",
              "fl",
              "variant_id",
              "lang_code",
              "product_id",
              "fpl"
            ],
            "key": "fpl",
            "used_key_parts": [
              "feature_id",
              "product_id",
              "lang_code"
            ],
            "key_length": "12",
            "rows_examined_per_scan": 51,
            "rows_produced_per_join": 51,
            "filtered": "100.00",
            "index_condition": "((`portal`.`v`.`feature_id` = 2) and (`portal`.`v`.`product_id` in (45397,40679,40680,40681,40682,40683,40684,40685,40686,40687,40688,40689,40690,40691,40692,40693,40694,40695,40696,40697,40698,40699,40700,40702,40703,40704,40705,40706)) and (`portal`.`v`.`lang_code` = 'en'))",
            "cost_info": {
              "read_cost": "89.21",
              "eval_cost": "10.20",
              "prefix_cost": "99.41",
              "data_read_per_join": "39K"
            },
            "used_columns": [
              "feature_id",
              "product_id",
              "variant_id",
              "value",
              "value_int",
              "lang_code"
            ],
            "attached_condition": "((if('1',(/* select#2 */ select 'A' from `portal`.`q_product_features` `df` where 1),'A') = 'A') and ((`portal`.`v`.`variant_id` <> 0) or (<cache>(('E' <> 'C')) and (`portal`.`v`.`value` <> '')) or <cache>(('E' = 'C')) or (`portal`.`v`.`value_int` <> '')))",
            "attached_subqueries": [
              {
                "dependent": true,
                "cacheable": false,
                "query_block": {
                  "select_id": 2,
                  "cost_info": {
                    "query_cost": "1.00"
                  },
                  "table": {
                    "table_name": "df",
                    "access_type": "const",
                    "possible_keys": [
                      "PRIMARY"
                    ],
                    "key": "PRIMARY",
                    "used_key_parts": [
                      "feature_id"
                    ],
                    "key_length": "3",
                    "ref": [
                      "const"
                    ],
                    "rows_examined_per_scan": 1,
                    "rows_produced_per_join": 1,
                    "filtered": "100.00",
                    "cost_info": {
                      "read_cost": "0.00",
                      "eval_cost": "0.20",
                      "prefix_cost": "0.00",
                      "data_read_per_join": "432"
                    },
                    "used_columns": [
                      "feature_id",
                      "status"
                    ]
                  }
                }
              }
            ]
          }
        },
        {
          "table": {
            "table_name": "fd",
            "access_type": "const",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id",
              "lang_code"
            ],
            "key_length": "9",
            "ref": [
              "const",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 51,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "1.00",
              "eval_cost": "10.20",
              "prefix_cost": "110.61",
              "data_read_per_join": "78K"
            },
            "used_columns": [
              "feature_id",
              "description",
              "prefix",
              "suffix",
              "lang_code"
            ]
          }
        },
        {
          "table": {
            "table_name": "fv",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "variant_id"
            ],
            "key_length": "3",
            "ref": [
              "portal.v.variant_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 51,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "51.00",
              "eval_cost": "10.20",
              "prefix_cost": "171.81",
              "data_read_per_join": "58K"
            },
            "used_columns": [
              "variant_id",
              "position"
            ]
          }
        },
        {
          "table": {
            "table_name": "vd",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "variant_id",
              "lang_code"
            ],
            "key_length": "9",
            "ref": [
              "portal.fv.variant_id",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 51,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "51.00",
              "eval_cost": "10.20",
              "prefix_cost": "233.01",
              "data_read_per_join": "154K"
            },
            "used_columns": [
              "variant_id",
              "variant",
              "lang_code"
            ]
          }
        },
        {
          "table": {
            "table_name": "gf",
            "access_type": "const",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id"
            ],
            "key_length": "3",
            "ref": [
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 51,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "1.00",
              "eval_cost": "10.20",
              "prefix_cost": "244.21",
              "data_read_per_join": "21K"
            },
            "used_columns": [
              "feature_id",
              "feature_type",
              "position"
            ],
            "attached_condition": "<if>(is_not_null_compl(gf), (`portal`.`gf`.`feature_type` = 'G'), true)"
          }
        }
      ]
    }
  }
}

Result

product_id feature_id value value_int variant_id feature_type description prefix parent_id position gposition variant suffix
40694 2 7617 E Brand 1 0 1 Intex
40703 2 7617 E Brand 1 0 1 Intex
40686 2 7617 E Brand 1 0 1 Intex
40695 2 7617 E Brand 1 0 1 Intex
40679 2 7617 E Brand 1 0 1 Intex
40704 2 7617 E Brand 1 0 1 Intex
40687 2 7617 E Brand 1 0 1 Intex
40696 2 7617 E Brand 1 0 1 Intex
40680 2 7617 E Brand 1 0 1 Intex
40705 2 7617 E Brand 1 0 1 Intex
40688 2 7617 E Brand 1 0 1 Intex
40697 2 7617 E Brand 1 0 1 Intex
40681 2 7617 E Brand 1 0 1 Intex
40706 2 7617 E Brand 1 0 1 Intex
40689 2 7617 E Brand 1 0 1 Intex
40698 2 7617 E Brand 1 0 1 Intex
40682 2 7617 E Brand 1 0 1 Intex
45397 2 7617 E Brand 1 0 1 Intex
40690 2 7617 E Brand 1 0 1 Intex
40699 2 7617 E Brand 1 0 1 Intex
40683 2 7617 E Brand 1 0 1 Intex
40691 2 7617 E Brand 1 0 1 Intex
40692 2 7617 E Brand 1 0 1 Intex
40700 2 7617 E Brand 1 0 1 Intex
40684 2 7617 E Brand 1 0 1 Intex
40693 2 7617 E Brand 1 0 1 Intex
40702 2 7617 E Brand 1 0 1 Intex
40685 2 7617 E Brand 1 0 1 Intex