SELECT 
  COUNT(DISTINCT sb.booking_id) 
FROM 
  cscart_ec_seat_bookings sb 
  INNER JOIN cscart_ec_seats s ON sb.seat_id = s.seat_id 
WHERE 
  s.layout_id = 5 
  AND sb.status = 'confirmed'

Query time 0.00071

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "15.74"
    },
    "nested_loop": [
      {
        "table": {
          "table_name": "s",
          "access_type": "ref",
          "possible_keys": [
            "PRIMARY",
            "idx_layout_category"
          ],
          "key": "idx_layout_category",
          "used_key_parts": [
            "layout_id"
          ],
          "key_length": "4",
          "ref": [
            "const"
          ],
          "rows_examined_per_scan": 10,
          "rows_produced_per_join": 10,
          "filtered": "100.00",
          "using_index": true,
          "cost_info": {
            "read_cost": "1.01",
            "eval_cost": "2.00",
            "prefix_cost": "3.01",
            "data_read_per_join": "2K"
          },
          "used_columns": [
            "seat_id",
            "layout_id"
          ]
        }
      },
      {
        "table": {
          "table_name": "sb",
          "access_type": "ref",
          "possible_keys": [
            "idx_seat_event"
          ],
          "key": "idx_seat_event",
          "used_key_parts": [
            "seat_id"
          ],
          "key_length": "4",
          "ref": [
            "pankajecarter_setup3.s.seat_id"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 3,
          "filtered": "33.33",
          "cost_info": {
            "read_cost": "10.61",
            "eval_cost": "0.71",
            "prefix_cost": "15.74",
            "data_read_per_join": "1K"
          },
          "used_columns": [
            "booking_id",
            "seat_id",
            "status"
          ],
          "attached_condition": "(`pankajecarter_setup3`.`sb`.`status` = 'confirmed')"
        }
      }
    ]
  }
}

Result

COUNT(DISTINCT sb.booking_id)
9