<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Испытание: итоговая таблица</title>
</head>
<body>
<h1>Итоговая таблица</h1>
<table>
<tr>
<th class="sell-1" class="oll-3">Город</th>
<th class="sell-3">Посещений</th>
<th class="sell-1" class="oll-1">%</th>
</tr>
<tr>
<td class="oll-3">СПб</td>
<td class="oll-2">199</td>
<td class="oll-1">65.12</td>
</tr>
<tr class="sell-2">
<td class="oll-3">Москва</td>
<td class="oll-2">69</td>
<td class="oll-1">21.3</td>
</tr>
<tr>
<td class="oll-3">Киев</td>
<td class="oll-2">5</td>
<td class="oll-1">8</td>
</tr>
<tr class="sell-2">
<td colspan="2" class="oll-3">Посещений за весь период</td>
<td class="oll-1">273</td>
</tr>
</table>
</body>
</html>
body {
width: 350px;
margin: 0;
padding: 0 10px;
font-size: 14px;
font-family: Arial, sans-serif;
}
table{
border-collapse: collapse;
}
th{
border-top: 1px solid black;
border-bottom: 1px solid black;
padding: 5px;
Width: 33%;
color: white;
}
td{
border-top:1px solid lightgray;
padding: 10px;
}
.sell-1{
background-color:darkcyan;
}
.sell-2{
background-color:lightyellow;
}
.sell-3{
background-color:lightblue;
}
.oll-1{
text-align: right;
}
.oll-2{
text-align: center;
}
.oll-3{
text-align: left;
}
juwain
3
В шапке таблицы текст тоже надо выровнять влево, по центру и вправо и задать нужные отступы. Обращайте внимание на вкладки «Различия» и «Наложение».