Is there a way to reverse the order of specific div's children elements using just CSS?
For instance:
I need
<div id="parent">
<a>A</a>
<a>B</a>
<a>C</a>
<a>D</a>
<div id="sub-child">
<a>X</a>
<a>Y</a>
<a>Z</a>
</div>
</div>
to appear like this:
D
C
B
A
X
Y
Z
I attempted:
#parent {
display:flex;
flex-direction: column-reverse;
}
However, all contents within parent were reversed (Not achieving the desired outcome)