What did I just do? Fluid shot out of my handlebar when pushing my caliper in I just bought a new road bike with hydraulic disc brakes, using a Shimano Ultegra R8020 Groupset. The pad was rubbing on the rear rotor and it wouldn't recenter when pumping the brake. The brake lever was also very tight at the time (much more than the front lever).

I took the wheel off and tried to press the piston in but I must have pressed too hard because it went in all of a sudden and fluid squirted out of my break lever (under the hood). The brake lever is now very loose and has about 5% braking power.

I assume I broke some seal or something... Any ideas on WTF I just did?

Info from repair:

The LBS said I pushed out a valve or plug - They said on some MTB systems there is a one-way valve that will deal with this, in case there is too much pressure, but the system I have lacks it. It was a simple fix, they pulled the plug, cleaned it, bled the line and replace the plug.
The LBS said I pushed out a valve or plug - They said on some MB systems there is a 1-way valve that will deal with this in case there is too much pressure but the system I have lacks it. It was a simple fix, they pulled the plug, cleaned it, bled the line and replace the plug/valve. - They charged $40 (in a super expensive area)