Ratings for wires vary a lot, look online for wire tables that give some numbers. One table that I often see come up in searches is this one:
https://www.powerstream.com/Wire_Size.htm
For #12 wire this table shows 41 amps in chassis and 9.3 amps in power transmission. These continuous current values represent a range based on different operating conditions and design assumptions. I regard the 41 amp value as a maximum continuous value for most use cases (and de-rate from there). Since heating increases as the square of the current things go bad rather quickly as current is increased.
The length of a wire doesn't really change the current handling capacity. Adding length adds both power loss through I squared R (R is proportional to length) and at the same time increases the cooling surface area. So it basically cancels out. For this reason most wire tables don't discuss or show wire length as a factor in current capacity.
A major factor in how much current the wire can handle is what temperature it will operate at. The ability of the insulation to withstand high temperature is important here. Unfortunately some of the highest temperature insulations (like silicone) are very soft and easy to damage so tight tie wraps or metal edges can penetrate the insulation and cause shorts. This is also a problem with PVC insulation when it gets hot and becomes soft.
When wires are bundled together the heat from multiple conductors generates higher temperatures, so multiple wires in a bundle call for reduced current.
If there is good airflow the heat will be carried away faster and somewhat higher current can be carried. This is often true in RC applications, and in some ebikes, for example the wires to the motor probably get good airflow. The battery side wiring may be covered and not get good airflow however.
If you like your wiring to operate without getting hot then choose a little heavier wire. You will notice the wire get warm when charging if you have a high current charger. I was using #14 wire for charging at 12 amps. This table shows 5.9 to 32 amps for #14, but at 12 amps continuous it gets fairly warm in still air. The wire is also called on to provide cooling for the connector, so near the connector it was even warmer.
On that same bike I use two #12's in parallel for battery to motor current, giving it a max capacity of about 80 amps. The controller is set for 80 amps max, and those levels of current don't last long, so the wiring does not get warm that I've noticed. In this case it was easier to work with a pair of #12's than a heavier wire as we were paralleling four 8AH Lipos.
The heating of the wire wastes a small amount of energy. It is not a lot, but using heavier wire does increase efficiency slightly. Length matters here, hence the lower values of current recommended in the table for power transmission to avoid wasting too much power. Make the wires long enough, but no longer. Keeping length at a minimum plus and minus paired also reduces inductance which is important between the controller and the battery as additional inductance increases the voltage spikes on the FETs. On the motor side inductance and cable length is much less of a concern.
Stranding of the wire is important for flexibility and long life in the face of vibration. Finer stranding maximizes flexibility. The stranding in house wire is not really sufficient for ebikes. Automotive or marine grade wire is a better choice.