[Moto G7 Power Questions & Answers] eworm92:
I tried installing Lineage 18.1, the appropriate Gapps and Magisk. Booted directly into TWRP (without flashing it) and did everything as per usual, followed the instructions, so no rebooting in-between etc.

Now all my phone can do is bootloader. Notably, the usual "broken android guy" picture is gone and so are the labels of the volume up/down buttons (though they do function and it displays "restart bootloader" or "recovery mode" or "factory" etc on top of the screen). Trying to boot, even with "fastboot continue", just brings me back to the bootloader, same with attempting to use recovery (shows error message and brings me back).

The serial number has changed from what it used to be and while fastboot does detect the device (with the aforementioned new ID), it can't do anything. All attempts to boot or flash are met with errors, usually accompanied with:

FAILED (remote: '')

and usually with "permission denied". Bootloader claims "oem_locked". Trying to "oem get_unlock_data"

Attempting to flash recovery to boot shows "invalid partition name boot" (changing it to "boot_a" or "boot_b" doesn't help). Can't just boot the recovery image from the computer either - once again, "permission denied" and FAILED (remote: '').

The oem unlock command returns "feature disabled".

The getvar current-slot command returns "current-slot: "

Trying to set active slot to either A or B returns "Command is not allowed".

Trying to flash stock image is no use, as no commands (outside of getvar max-sparse-size) work at all.

Motorola's Rescue Assistant couldn't detect my device (or rather, it could - said my device is '' and wasn't able to do anything with it). I've reinstalled the Motorola drivers and it was no help, although I admittedly can't find it in the device manager - should it be under "Ports" or is "Android Device -> Motorola ADB Interface" all that's supposed to show?

Bootloader screen:

AP Fastboot Flash Mode (Secure)
BL: MBM-2.1-ocean_retail-cfdb645cf1d-210201
Baseband:
Product/variant: ocean radio6 64GB PVT1
Serial Number: d890e31
CPU: SDM632
eMMC: 64GB MICRON S0J9N8 RV=08 PV=10 FV=0000000000000004
DRAM: 4GB MICRON LP3 DIE=3Gb M5=FF M6=01 M&=00 M8=5F
Console [NULL]: null
Console [default]: ttyMSM0,115200,n8
(I can switch between the two with "Switch console" via the volume buttons)
Tools Mode Config: DISABLED/ENABLED
(can switch with "Switch Tools mode" via volume buttons)
Battery OK
oem_locked
Transfer Mode: USB Connected

I'm running out of ideas. I've had trouble before, but at least then I could use the bootloader to attempt some fixing. Worst case scenario used to be losing all data and having to reflash the stock. This is so much worse - I can't even do anything! Does anyone have any ideas??

EDIT: getvar all results just in case:

(bootloader) version: 0.5
(bootloader) version-bootloader: MBM-2.1-ocean_retail-cfdb645cf1d-210201
(bootloader) product: ocean
(bootloader) board: ocean
(bootloader) secure: yes
(bootloader) hwrev: PVT1
(bootloader) radio: 6
(bootloader) storage-type: emmc
(bootloader) emmc: 64GB MICRON S0J9N8 RV=08 PV=10 FV=0000000000000004
(bootloader) ram: 4GB MICRON LP3 DIE=8Gb M5=FF M6=01 M7=00 M8=5F
(bootloader) cpu: SDM632
(bootloader) serialno: d890e31
(bootloader) cid: 0xDEAD
(bootloader) channelid: 0x00
(bootloader) uid: 0000000000000000000000000000
(bootloader) securestate: oem_locked
(bootloader) factory-modes: disabled
(bootloader) iswarrantyvoid: n/a
(bootloader) max-download-size: 536870912
(bootloader) reason: Failed to initialize partition table
(bootloader) imei:
(bootloader) imei2:
(bootloader) meid:
(bootloader) date:
(bootloader) sku:
(bootloader) carrier_sku:
(bootloader) battid:
(bootloader) iccid:
(bootloader) cust_md5:
(bootloader) max-sparse-size: 268435456
(bootloader) current-time:
(bootloader) ro.build.fingerprint:
(bootloader) poweroffalarm: 0
(bootloader) ro.build.version.full:
(bootloader) ro.build.version.qcom:
(bootloader) version-baseband:
(bootloader) kernel.version:
(bootloader) sbl1.git: sbl1.git
(bootloader) rpm.git: rpm.git
(bootloader) tz.git: tz.git
(bootloader) devcfg.git: devcfg.git
(bootloader) keymaster.git: keymaster.git
(bootloader) cmnlib.git: cmnlib.git
(bootloader) cmnlib64.git: cmnlib64.git
(bootloader) prov.git: prov.git
(bootloader) aboot.git: MBM-2.1-ocean_retail-cfdb645cf1d-210201
(bootloader) frp-state: no protection (err)
(bootloader) ro.carrier:
(bootloader) current-slot:
(bootloader) running-boot-lun: must + g->mlen
(bootloader) running-slot:
(bootloader) slot-suffixes: _a
(bootloader) slot-count: 1
(bootloader) slot-successful:_a: INVALID
(bootloader) slot-successful:_b: INVALID
(bootloader) slot-bootable:_a: INVALID
(bootloader) slot-bootable:_b: INVALID
(bootloader) slot-retry-count:_a: unknown
(bootloader) slot-retry-count:_b: unknown
(bootloader) pcb-part-no:
all: listed above