Ajax Loader
×

css tabs

HTML
 <div class="nav">
1
 <div class="nav">
2
                <input id="info" type="radio" name="nav" checked>
3
                <label for="info" title="Информация">Информация</label>
4
 
5
                <input id="credit" type="radio" name="nav">
6
                <label for="credit" title="Кредит">Кредит</label>
7
 
8
                <input id="payment" type="radio" name="nav">
9
                <label for="payment" title="Оплата">Оплата</label>
10
 
11
                <input id="more" type="radio" name="nav">
12
                <label for="more" title="Дополнительно">Дополнительно</label>
13
                
14
                <input id="help" type="radio" name="nav">
15
                <label for="help" title="Помощь">Помощь</label>
16
            </div>
17
        <div class="content">
18
            <section id="info-content"><p>Main info</p></section>
19
            <section id="credit-content"><p>Credits</p></section>
20
            <section id="payment-content"><p>Payments</p></section>
21
            <section id="more-content"><p>More dad</p></section>
22
            <section id="help-content"><p>helpeeeee</p></section>
23
        </div>
 
CSS
.nav {
1
.nav {
2
    width: 100%;
3
    padding: 0px;
4
    margin: 0 auto;
5
}
6
section {
7
    display: none;
8
    width: 70%;
9
    margin-top: 0;
10
    background: #ddd;
11
    
12
}
13
.nav input {
14
  display: none;
15
}
16
.nav label {
17
  display: block;
18
  margin: 0 0 -1px;
19
  padding: 15px 25px;
20
  font-weight: 600;
21
  text-align: center;
22
  color: #aaa;
23
}
24
.nav label:hover {
25
    border-left: 4px solid #ddd;
26
    background: #364165;
27
    cursor: pointer;
28
}
29
.nav label:before {
30
  font-family: Helvetica;
31
  font-weight: normal;
32
  margin-right: 10px;
33
}
34
.nav input:checked + label {
35
  color: #555;
36
  border-top: 1px solid #009933;
37
  border-bottom: 1px solid #fff;
38
  background: #fff;
39
}
40
.nav > #info:checked ~ .content > #info-content,
41
.nav > #credit:checked ~ .content > #credit-content,
42
.nav > #payment:checked ~ .content > #payment-content,
43
.nav > #more:checked ~ .content > #more-content,
44
.nav > #help:checked ~ .content > #help-content {
45
    display: inline-block;
46
}
47
 
 

css tabs

CSSDeck G+