Compose a piece of music based on the provided motif and adhering to the outlined musical structure.
X:1
L:1/8
M:12/8
K:D
['g2 g gfe', 'A2 G FED F2 A A2'  
X:1
L:1/8
M:12/8
K:D
|: e | f2 f fed g2 g gfe | fgf fed e2 c A2 e | fff f2 d g2 g gfe | f2 f efe d3 d2 :: B | 
 A2 G FED F2 A A2 c | d2 d cBA B2 E E2 F | A2 G FED F2 A A2 d | c2 B ABc d3 d2 :|  