Using CSS, how can I style the following:
- Mercury
- Mercury (0.4 AU from the Sun) is the closest planet to th
this works to display them as table, with border, it should be responsive with 3em the width of the first column. The word-wrap just breaks any words wider than the column
dl { display:block;
border:2px solid black;
margin: 1em;}
dt { display:inline-block;
width:3em;
word-wrap:break-word;}
dd { margin-left:0;
display:inline;
vertical-align:top;
line-height:1.3;}
dd:after { content:'';display:block; }
Comparison of with
:
Table
DL list Milk
Black hot drink
Coffee2
Black hot drink
Warm milk
White hot drink