JSFiddle - React, Tailwind, and code Playground
by Akram kamal
HTML
<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>(Better) Round Out Tabs</title>
<link rel='stylesheet' href='css/style.css'>
<style>
</style>
</head>
<body>
<ul class="tabrow">
<input type="radio" name="tabs" id="t1"><label for="t1">Lorem</label>
<input type="radio" name="tabs" id="t2"><label for="t2">Ipsum</label>
<input type="radio" name="tabs" id="t3" checked="true"><label for="t3">Sit amet</label>
<input type="radio" name="tabs" id="t4"><label for="t4">Consectetur adipisicing</label>
</ul>
</body>
</html>
CSS
/*
CSS-Tricks Example
by Chris Coyier
http://css-tricks.com
*/
* { margin: 0; padding: 0; }
body { font: 14px Georgia, serif; }
h1 {
width: 660px;
margin: 0 auto;
padding: 20px 0;
color: #222;
}
.group:before,
.group:after {
content: "";
display: table;
}
.group:after {
clear: both;
}
.group {
zoom: 1;
}
.tabrow {
text-align: center;
margin: 200px 0 20px;
padding: 0;
line-height: 24px;
height: 26px;
overflow: hidden;
font-size: 12px;
font-family: verdana;
position: relative;
}
.tabrow label {
border: 1px solid #AAA;
background: #D1D1D1;
background: -o-linear-gradient(top, #ECECEC 50%, #D1D1D1 100%);
background: -ms-linear-gradient(top, #ECECEC 50%, #D1D1D1 100%);
background: -moz-linear-gradient(top, #ECECEC 50%, #D1D1D1 100%);
background: -webkit-linear-gradient(top, #ECECEC 50%, #D1D1D1 100%);
background: linear-gradient(top, #ECECEC 50%, #D1D1D1 100%);
display: inline-block;
position: relative;
z-index: 0;
border-top-left-radius: 6px;
border-top-right-radius: 6px;
box-shadow: 0 3px 3px rgba(0, 0, 0, 0.4), inset 0 1px 0 #FFF;
text-shadow: 0 1px #FFF;
margin: 0 -5px;
padding: 0 20px;
}
.tabrow label {
color: #555;
text-decoration: none;
}
.tabrow input:checked+label {
background: #FFF;
color: #333;
z-index: 2;
border-bottom-color: #FFF;
}
.tabrow:before {
position: absolute;
content: " ";
width: 100%;
bottom: 0;
left: 0;
border-bottom: 1px solid #AAA;
z-index: 1;
}
.tabrow label:before,
.tabrow label:after {
border: 1px solid #AAA;
position: absolute;
bottom: -1px;
width: 5px;
height: 5px;
content: " ";
}
.tabrow label:before {
left: -6px;
border-bottom-right-radius: 6px;
border-width: 0 1px 1px 0;
box-shadow: 2px 2px 0 #D1D1D1;
}
.tabrow label:after {
right: -6px;
border-bottom-left-radius: 6px;
...