• Binary revolution
    -

    VIP
    5
  • Forex  -

  • TOKYO GAP


  • Master Trend

    300 1000 . .
  • 6000$





!!!

 

CSS3

: 13.01.2014
: 
: bulatlab.ru

, !

 

, , , CSS. ( ) target nth-of-type -  input (radio).

 

, html- :

 

<!DOCTYPE html>
<html>
<head> 
</head> 
<body>
 <section class="container">
    <div>
        <input id="ac-1" name="accordion-1" type="radio" checked />
        <label for="ac-1"> 1</label>
        <article>
            <ul >
               <li><a href=""> 1.1</a></li>
               <li><a href=""> 1.2</a></li>
               <li><a href=""> 1.3</a></li>
               <li><a href=""> 1.4</a></li>
               <li><a href=""> 1.5</a></li>
            </ul>
        </article>
    </div>
    
    <div>
        <input id="ac-2" name="accordion-1" type="radio" />
        <label for="ac-2"> 2</label>
        <article>
            <ul >
               <li><a href=""> 2.1</a></li>
               <li><a href=""> 2.2</a></li>
               <li><a href=""> 2.3</a></li>
               <li><a href=""> 2.4</a></li>
               <li><a href=""> 2.5</a></li>
            </ul>
        </article>
    </div>
    
    <div>
        <input id="ac-3" name="accordion-1" type="radio" />
        <label for="ac-3"> 3</label>
        <article>
            <ul >
               <li><a href=""> 3.1</a></li>
               <li><a href=""> 3.2</a></li>
               <li><a href=""> 3.3</a></li>
               <li><a href=""> 3.4</a></li>
               <li><a href=""> 3.5</a></li>
            </ul>
        </article>
    </div>
    
    <div>
        <input id="ac-4" name="accordion-1" type="radio" />
        <label for="ac-4"> 4</label>
        <article>
            <ul >
               <li><a href=""> 4.1</a></li>
               <li><a href=""> 4.2</a></li>
               <li><a href=""> 4.3</a></li>
               <li><a href=""> 4.4</a></li>
               <li><a href=""> 4.5</a></li>
            </ul>
        </article>
    </div>
</section>
</body>
</html>

 

, div, input label ( ), ( ).

 

, head:

 

style>
.container{ width: 250px; margin: 10px auto 30px auto;}
.container input{ display: none;}
.container ul {list-style-type:none;}
.container a{ text-decoration: none;color:#777;}
.container a:hover{ text-decoration: underline;color:#444;}

.container  label{
    font-family: 'Arial Narrow', Arial, sans-serif;
    padding: 5px 20px;
    position: relative;
    z-index: 20;
    display: block;
    height: 30px;
    cursor: pointer;
    color: #777;
    text-shadow: 1px 1px 1px rgba(255,255,255,0.8);
    line-height: 33px;
    font-size: 19px;
    background: -moz-linear-gradient(top, #ffffff 1%, #eaeaea 100%);
    background: -webkit-gradient(linear, left top, left bottom, color-stop(1%,#ffffff), color-stop(100%,#eaeaea));
    background: -webkit-linear-gradient(top, #ffffff 1%,#eaeaea 100%);
    background: -o-linear-gradient(top, #ffffff 1%,#eaeaea 100%);
    background: -ms-linear-gradient(top, #ffffff 1%,#eaeaea 100%);
    background: linear-gradient(top, #ffffff 1%,#eaeaea 100%);
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#eaeaea',GradientType=0 );
    box-shadow: 
        0px 0px 0px 1px rgba(155,155,155,0.3), 
        1px 0px 0px 0px rgba(255,255,255,0.9) inset, 
        0px 2px 2px rgba(0,0,0,0.1);
}


.container label:hover{
    box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.5) inset;
    -moz-box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.5) inset;
    -webkit-box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.5) inset;   
 
}


.container article{
    background: rgba(255, 255, 255, 0.5);
    margin-top: -1px;
    overflow: hidden;
    height: 0px;
    position: relative;
    z-index: 10;
    -webkit-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -moz-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -o-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -ms-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
}

.container input:checked ~ article {
     -webkit-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -moz-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -o-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    -ms-transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    transition: height 0.3s ease-in-out, box-shadow 0.6s linear;
    box-shadow: 0px 0px 0px 1px rgba(155,155,155,0.3);
    height: 150px;
}
</style>

.

  

  

 

 

 
: 348
: 0
: (0)