﻿/*--------------header-style1-----------------*/
.header-style1{
    position: absolute;
    z-index: 999;
    display: block;
    width: 100%;
    top: 0;
    background-color: #FFF;
    box-shadow: 0 0 8px 0 #555;
}
.header-style1 .header-box{
    width: 1200px;
    max-width: 100%;
    display: block;
    margin: 0 auto;
    font-size: 0;
    padding: 10px 0;
}
.header-style1 .header-logo{
    width: 540px;
    max-width: 100%;
    display: inline-block;
    position: relative;
    vertical-align: middle;
}
.header-style1 .header-menu-box{
    width: calc(100% - 540px);
    display: inline-block;
    vertical-align: middle;
    font-size: 0;
    text-align: center;
}
.header-style1 .header-menu> li{
    display: inline-block;
    vertical-align: middle;
    position: relative;
}
.header-logo-line1{
    width: 20%;
    height: 4px;
    background-color: #d0011b;
    display: block;
    position: absolute;
    left: 0;
    bottom: calc(50% - 18px);
}

.header-logo-line2{
    width: 55%;
    height: 4px;
    background-color: #d0011b;
    display: block;
    position: absolute;
    right: 0;
    top: calc(50% - 40.5px);
}


.header-link-box{
    display: block;
    position: absolute;
    right: 0;
    top: 0;
}

.header-menu li{
    padding-left: 30px;
}
.header-menu li:first-child{
    padding-left: 0;
}
.header-menu-title{
    font-size: 16px;
    position: relative;
    color: #555555;
    transition: all .3s linear;
}
.header-menu-title:after{
    content: '';
    width: 0;
    height: 1px;
    background-color: #d0011b;
    position: absolute;
    bottom: 0;
    left: 0;
    transition: all .3s linear;
}
div.header-menu-title{
    cursor: pointer;
}
.header-products .header-menu-title:before{
    content: '';
    position: absolute;
    top: calc(50% - 2.5px);
    right: -15px;
    background-color: transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #555;
    border-left: 5px solid transparent;
    transition: all .3s ease;
}
.header-products .header-menu-title.active .header-products-box{
    display: block;
}
.header-products-box{
    box-sizing: border-box;
    display: none;
    position: absolute;
    top: 23px;
    background-color: #eee;
    box-shadow: 0 0 5px #555;
}
.header-products-text,
.header-products-text2{
    width: 135px;
    display: block;
    box-sizing: border-box;
    font-size: 16px;
    padding: 5px 10px;
    position: relative;
    padding-right: 20px;
    text-align: left;
}
.header-products-text:after,
.header-products-text2:after{
    content: '';
    position: absolute;
    top: 15px;
    right: 10px;
    background-color: transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #555;
    border-left: 5px solid transparent;
    transition: all .3s ease;
}
.header-products-standard{
    position: relative;
    display: block;
    cursor: pointer;
}
.header-products-list,
.header-products-last{
    display: none;
    cursor: pointer;
}
.header-products-list .header-products-text{
    font-size: 14px;
}
.header-products-last .header-products-text2{
    font-size: 12px;
}
.header-products-list .header-products-text:after{
    top: 15px;
    right: 10px;
    border-right: 4px solid transparent;
    border-top: 4px solid #555;
    border-left: 4px solid transparent;
}
.header-products-last .header-products-text:after{
    display: none;
}
.header-products-text:hover{
    color: #d0011b;
}
.header-products-text:hover:after{
    border-top-color: #d0011b;
}
.header-products-standard.active .header-products-list,
.header-products-list.active .header-products-last{
    display: block;
}
.header-products-standard.active>.header-products-text{
    background-color: #d0011b;
    color: #fff;
}
.header-products-list.active>.header-products-text{
    background-color: #9c0014;
    color: #fff;
}
.header-products-standard.active>.header-products-text:after,
.header-products-list.active>.header-products-text:after{
    border-top-color: #fff;
}
.header-products-title{
    display: none;
}
.header-products-text2.active{
    color: #d0011b;
}
.header-products-text2.active:after{
    border-top: 5px solid #d0011b;
}

.rwd-menu-list-back{
    display: none;
}
/*------------------------------------------------*/
.header-products-list-box{
    position:absolute;
    left: 100%;
    top: 0;
    display: none;
    max-height: 60vh;
    overflow-y: auto;
    overflow-x: hidden;
}
.header-products-list-box{

    box-shadow: 0 0 5px #555;
}
.header-products-list{

    background-color: #eee;
}

.mask{
    width: 100%;
    height: 100vh;
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    background-color: rgba(0, 0, 0, 0.7);
}

.mask.active{
    display: block;
}

.rwd-menu{
    width: 30px;
    max-width: 100%;
    position: absolute;
    right: 20px;
    z-index: 99999;
    display: none;
    top: calc(50% - 3px);
}
.rwd-menu span{
    width: 100%;
    display: block;
    margin: 0 auto;
    height: 2px;
    background-color: #ee1b2d;
    position: relative;
}
.rwd-menu-bth-line>span,
.rwd-menu-bth-line2>span{
    background-color: #fff;
}



/*漢堡樣式1*/
.rwd-menu-style1> span:nth-child(even){
    margin: 4px auto;
    transition: all .4s linear;
}
.rwd-menu-style1> span:nth-child(1){
    transform: scale(1);
    transform-origin: left;
    transition: all .4s linear;
}
.rwd-menu-style1> span:nth-child(3){
    transform: scale(1);
    transform-origin: right;
    transition: all .4s linear;
}
.rwd-menu-style1> span:nth-child(4){
    top: -19px;
    transform:  scale(0,1) rotate(-45deg);
}
.rwd-menu-style1> span:nth-child(4){
    display: none;
}
.rwd-menu-style1 .rwd-menu-bth-line{
    transform: rotate(-45deg);
}
.rwd-menu-style1 .rwd-menu-bth-line2{
    transform: rotate(45deg);
}
.rwd-menu-style1 .rwd-menu-bth-line,
.rwd-menu-style1 .rwd-menu-bth-line2{
    position: absolute;
    top: 6px;
    left:0;
    width: 100%;
}
.rwd-menu-style1 .rwd-menu-bth-line span,
.rwd-menu-style1 .rwd-menu-bth-line2 span{
    transform:  scale(0,1);
    transition: all .5s ease;
    position: relative;
}
.rwd-menu-style1.active .rwd-menu-bth-line span,
.rwd-menu-style1.active .rwd-menu-bth-line2 span{
    transform:  scale(1,1) ;
    transition-delay: .1s;
}
.rwd-menu-style1.active> span:nth-child(1),
.rwd-menu-style1.active> span:nth-child(2),
.rwd-menu-style1.active> span:nth-child(3){
    transform: scale(0,1);
}
.rwd-menu-style1.active> span:nth-child(odd){
    transform: scale(0);
    transition: all .4s linear;
    transition-delay: 0s;
}

/*漢堡樣式2*/

.rwd-menu-style2> span:nth-child(4){
    display: none;
}
.rwd-menu-style2> span:nth-child(2){
    display: block;
    margin: 4px auto;
}
.rwd-menu-style2{
    width: 25px;
}
.rwd-menu-style2> span{
    transition: all 0.3s ease-in-out;
}
.rwd-menu-style2 .rwd-menu-bth-line,
.rwd-menu-style2 .rwd-menu-bth-line2{
    display: none;
}
.rwd-menu-style2.active{
    animation: smallbig 0.6s forwards;
}
.rwd-menu-style2.active> span:nth-child(1){
    -webkit-transform: translateY(7px) rotate(45deg);
    -ms-transform: translateY(7px) rotate(45deg);
    -o-transform: translateY(7px) rotate(45deg);
    transform: translateY(7px) rotate(45deg);
}
.rwd-menu-style2.active> span:nth-child(2){
    opacity: 0;
}
.rwd-menu-style2.active> span:nth-child(3){
    -webkit-transform: translateY(-5px) rotate(-45deg);
    -ms-transform: translateY(-5px) rotate(-45deg);
    -o-transform: translateY(-5px) rotate(-45deg);
    transform: translateY(-5px) rotate(-45deg);
}

.rwd-menu-style2.active> span:nth-child(1), 
.rwd-menu-style2.active> span:nth-child(2), 
.rwd-menu-style2.active> span:nth-child(3) {
    -webkit-transition-delay: 0.2s;
    -o-transition-delay: 0.2s;
    transition-delay: 0.2s;
}
.header-menu-title:hover,
.header-about.active .header-menu-title,
.header-news.active .header-menu-title,
.header-service.active .header-menu-title,
.header-products.active .header-menu-title,
.header-contact.active .header-menu-title,
.header-system.active .header-menu-title{
    color: #d0011b;
}
.header-menu-title:hover:after,
.header-about.active .header-menu-title:after,
.header-news.active .header-menu-title:after,
.header-service.active .header-menu-title:after,
.header-products.active .header-menu-title:after,
.header-contact.active .header-menu-title:after,
.header-system.active .header-menu-title:after{
    width: 100%;
}
.header-products .header-menu-title:hover:before,
.header-products.active .header-menu-title:before{
    border-top: 5px solid #d0011b;
}

@keyframes smallbig{
  0%, 100%{
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    -o-transform: scale(1);
    transform: scale(1);
  }

  50%{
    -webkit-transform: scale(0);
    -ms-transform: scale(0);
    -o-transform: scale(0);
    transform: scale(0);
  }
}


/*------------------------------------------*/
@media only screen and (max-width: 1550px){
    .header-logo-line1{
        width: 13%;
    }
    .header-logo-line2{
        width: 73%;
    }
}
@media only screen and (max-width: 1200px){
    .header-style1 .header-box{
        width: 95%;
        margin: 0 auto;
    
    }
    .header-style2 .header-menu ul{
        width: 100%;
    }

    .header-menu-title{
        font-size: 14px;
    }
}

@media only screen and (max-width: 1100px){
    .header-style1 .header-logo{
        width: 400px;
    }
    .header-style1 .header-menu-box{
        width: calc(100% - 400px);
    }
    .header-logo-line1{
        bottom: calc(50% - 14px);
        height: 3px;
    }
    .header-logo-line2{
        top: calc(50% - 31px);
        height: 3px;
    }
}
@media only screen and (max-width: 1000px){
    .header-style1{
        position: fixed;
    }
    .header-style6 .header-logo{
        position: relative;
        width: 100%!important;
        text-align: left;
        background-color: #FFF;
    }
    .rwd-menu{
        display: block;
    }
    .header-style1 .rwd-menu{
        display: block;
    }

    .rwd-header-menu-sytle1 .header-menu{
        width: 100%;
        height: 100vh;
        position: fixed;
        top: 0px;
        right: 0px;
        z-index: 3;
        display:         flex;
        display: -webkit-flex;
        align-items: center;
        -webkit-align-items: center;
        justify-content: center;
        -webkit-justify-content: center;
        flex-direction:column;
        background-color: #d0011b;
        transition: none;
        box-shadow: 0 0 5px 0 #000;
    }
   
    .rwd-header-menu-sytle1.header2 .header-menu{
        width: 100%;
    }
    
    .rwd-header-menu-sytle1 .header-menu> li{
        margin: 0;
        padding-left: 0;
        margin-bottom: 20px;
    }
    .rwd-header-menu-sytle1 .header-menu> li:last-child{
        margin-bottom: 0;
     }
     .header-menu-title{
        color: #fff;
     }
      .rwd-header-menu-sytle2 .header-menu-box.active .header-menu{
        top: 0;
    }
    .rwd-header-menu-sytle2 .header-menu{
        width: 100%;
        height: 100vh;
        position: fixed;
        top: calc(-100% - 100px);
        left: 0;
        z-index: 3;
        display:         flex;
        display: -webkit-flex;
        align-items: center;
        -webkit-align-items: center;
        justify-content: center;
        -webkit-justify-content: center;
        flex-direction:column;
        background-color: #f5f5f5;
        transition: all .5s ease;
    }
    .header-style6.header2{
        border-bottom: 0;
    }
    .header-style6 .header-logo{
        border-bottom: 1px solid #d1d1d1;
    }

    .header-menu-title:hover,
    .header-about.active .header-menu-title,
    .header-news.active .header-menu-title,
    .header-service.active .header-menu-title,
    .header-products.active .header-menu-title,
    .header-contact.active .header-menu-title,
    .header-system.active .header-menu-title{
        color: #fff;
        font-weight: bold;
        letter-spacing: 3px;
    }
    .header-products-title{
        display: block;
    }
    .header-products .header-products-title:before{
        display: none;
    }
    div.header-menu-title{
        display: none;
    }
    .header-products-box{
        display: none;
        opacity: 0;
        pointer-events: none;
    }
}

@media only screen and (max-width: 700px){
    .header-style1 .header-logo{
        width: 300px;
    }
    .header-logo-line1{
        width: 3%;
        bottom: calc(50% - 11px);
        height: 3px;
    }
    .header-logo-line2{
        width: 56%;
        top: calc(50% - 23px);
        height: 2px;
    }
}
@media only screen and (max-width: 400px){
    .header-style1 .header-logo{
        width: 220px;
    }
    .header-logo-line1{
        width: 3%;
        bottom: calc(50% - 8px);
        height: 2px;
    }
    .header-logo-line2{
        width: 56%;
        top: calc(50% - 17px);
        height: 2px;
    }
}