What would happen if a ranger were to (willingly or unwillingly) turn a druid into their Ranger Companion?
You can't, because they don't meet the CR requirements.
In order for a beast to be chosen as a Ranger's companion, it must have a challenge rating of 1/4 or lower. While the form that a druid takes might be the form of a beast with a CR of 1/4, the CR of the druid itself will be much higher. Since the druid is not a beast with a CR of 1/4 or less, it can't be made into a Ranger companion.
Note that PCs generally don't have a CR at all, so a PC druid couldn't become a companion even if their CR would theoretically be low enough. In addition, a Ranger couldn't bond with a creature "unwillingly", since the Ranger's Companion ability specifies that any chosen beast must be non-hostile.
You can't, because the Druid is not a Beast in their base form, only when they're using their Wild Shape ability, which lasts for (Druid Level/2) hours. Since the Animal Companion ability requires the animal companion to be a Beast, and the process for making a Beast into an Animal Companion takes 8 hours, they can't take the Druid as a companion as a result - unless the Druid is level 16+, they'll revert to a Humanoid part way through.