CSS elemento com sub elemento automático

Olá todos !

Sou novo por aqui, tenho uma dúvida quando criar elemento com sub elemento usando CSS.

Segui o código HTML:

widget { position: absolute; left: 100px; top: 100px; width: 200px; height: 200px; border-radius: 5px; border: 1px solid rgb(197,40,0); background: rgb(235,235,235); } widget_title { position: absolute; top: 0px; left: 0px; width: 100%; height: 30px; background-image: linear-gradient(to bottom, #ffaf46, #e78404); } -----------------------------------------------------

PERGUNTA:
Como criar um elemento( widget) com um sub elemento ( widget_title ) usando apenas isso:

Espero que seja entendido.

Grato !

Opa erro, vou fazer outro tópico.

Sou novato aqui, tem como editar ?