body{ background-color: aliceblue; } .italy{ position: relative; width: 18ex; height: 12ex; border: 1px solid black; } .italy :first-child{ position: absolute; left: 0; top: 0; width: 6ex; height: 12ex; background: #008000; } .italy div+div+div{ position: relative; left: 12ex; top: 0; width: 6ex; height: 12ex; background: #ff0000; }