﻿.works-box{
    width: 100%;
    position: relative;
    display: block;
    min-height: 100vh;
    padding-top: 117px;
}
.works-all-box{
    width: 1840px;
    max-width: 100%;
    font-size: 0;
    display: block;
    margin: 0 auto;
    position: relative;
    box-sizing: border-box;
    padding-bottom: 60px;
}

.works-class-box{
    box-sizing: border-box;
    padding: 80px 0;
    position: relative;
    text-align: center;
}
.works-class-all-box{
    display: inline-block;
    box-sizing: border-box;
    padding: 15px 60px;
    position: relative;
}
.works-class{
    font-size: 16px;
    color: #666;
    letter-spacing: 0.2em;
    line-height: 30px;
    font-family: 'Noto Sans TC';
    box-sizing: border-box;
    padding-left: 0.2em;
    display: inline-block;
    vertical-align: middle;
    position: relative;
    margin: 0 15px;
    transition: all .3s linear;
}
.works-class::after{
    content: '';
    width: 0%;
    height: 2px;
    background-color: #000;
    position: absolute;
    bottom: -1px;
    right: 0;
    transition: all .3s ease;
}
.works-class-border-box{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.works-class-border-box span{
    width: 1px;
    height: 100%;
    background-color: #000;
    display: block;
    position: absolute;
}
.works-class-border-box span:nth-child(1){
    left: 0;
    top: 0;
}
.works-class-border-box span:nth-child(2){
    right: 0;
    top: 0;
}
.works-class-border-box span::after{
    content: '';
    width: 10px;
    height: 1px;
    position: absolute;
    background-color: #000;
}
.works-class-border-box span:nth-child(1)::after{
    left: 0;
    top: 0;
}
.works-class-border-box span:nth-child(2)::after{
    right: 0;
    bottom: 0;
}


.works-info{
    width: 560px;
    max-width: 100%;
    display: inline-block;
    vertical-align: top;
    position: relative;
    margin-right: 80px;
    padding-bottom: 60px;
}
.works-info:nth-child(3n){
    margin-right: 0;
}
.works-info:nth-child(n + 4){
    margin-top: 60px;
}
.works-info-img{
    width: 100%;
    height: 380px;
    display: block;
    overflow: hidden;
}
.works-info-text-box{
    width: 510px;
    max-width: 100%;
    display: block;
    position: absolute;
    bottom: 0;
    left: 0;
    background-color: #fff;
    box-sizing: border-box;
    padding: 15px;
    padding-bottom: 24px;
    transition: all .3s linear;
}
.works-info-class{
    font-size: 14px;
    letter-spacing: 0.1em;
    color: #666;
}
.works-info-text{
    font-size: 18px;
    letter-spacing: 0.1em;
    color: #000;
    margin-top: 5px;
    font-family: 'Noto Sans TC';
}
.works-info-arrow{
    width: 60px;
    height: 1px;
    background-color: #000;
    display: block;
    position: relative;
    margin-top: 25px;
}
.works-info-arrow span{
    border-bottom: 4px solid #000;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    position: absolute;
    right: 0;
    bottom: 0;
}


.works-page_number-box .page{
    margin: 60px 0;
}
.works-page_number-box .page>a{
    font-size: 22px;
    color: #888;
    font-family: "roboto";
    display: inline-block;
}
.works-page_number-box .page>a:hover,
.works-page_number-box .page>a.select{
    color: #000;
    font-weight: 600;
}
.works-page_number-box .page>a.prev,
.works-page_number-box .page>a.next{
    width: 30px;
    height: 30px;
    padding: 0;
    display: inline-flex;
    display: -webkit-inline-flex;
    align-items: center;
    -webkit-align-items: center;
    justify-content: center;
    -webkit-justify-content: center;
    flex-direction: column;
}
.works-page_number-box .page>a.prev span,
.works-page_number-box .page>a.next span{
    width: 100%;
    height: 1px;
    background-color: #000;
    display: block;
    position: relative;
    top: 5px;
}
.works-page_number-box .page>a.prev span::after{
    content: '';
    border-bottom: 4px solid #000;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    position: absolute;
    left: -1px;
    bottom: 0;
}
.works-page_number-box .page>a.next span::after{
    content: '';
    border-bottom: 4px solid #000;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    position: absolute;
    right: -1px;
    bottom: 0;
}



.works-class:hover,
.works-class.active{
    color: #000;
}
.works-class:hover::after,
.works-class.active::after{
    width: 100%;
    right: inherit;
    left: 0;
}




@media only screen and (max-width: 1840px){
    .works-all-box{
        width: 95%;
    }
    .works-info{
        width: calc((100% - 160px) / 3);
    }
    .works-info-img{
        height: calc((380 / 560) * ((95vw - 160px) / 3));
    }
    .works-info-text-box{
        width: 80%;
    }
}
@media only screen and (max-width: 1280px){
    .works-info{
        width: calc((100% - 80px) / 3);
        margin-right: 40px;
    }
    .works-info-img{
        height: calc((380 / 560) * ((95vw - 80px) / 3));
    }
    .works-info:nth-child(n + 4) {
        margin-top: 30px;
    }
}
@media only screen and (max-width: 1000px){
    .works-info:nth-child(n) {
        width: calc((100% - 40px) / 2);
        margin-right: 40px;
    }
    .works-info-img{
        height: calc((380 / 560) * ((95vw - 40px) / 2));
    }
    .works-info:nth-child(2n) {
        margin-right: 0;
    }
    .works-info:nth-child(n + 3) {
        margin-top: 30px;
    }
	.rwd-works-class{
        width: 100%;
        height: 46px;
        border: 1px solid #888;
        font-size: 16px;
        letter-spacing: 1px;
        text-align: center;
        display: block;
        line-height: 46px;
        position: relative;
        box-sizing: border-box;
        font-family: 'Noto Sans TC';
        color: #666;
    }
    .rwd-works-class:after {
        content: '';
        width: 0px;
        height: 0px;
        margin: 0 auto;
        border-right: 8px solid transparent;
        border-top: 10px solid #666;
        border-left: 8px solid transparent;
        display: block;
        position: absolute;
        bottom: calc(50% - 5px);
        right: 5%;
        box-sizing: border-box;
    }
    .works-class-all-box{
        width: 100%;
        display: none;
        box-sizing: border-box;
        border: 1px solid #d1d1d1;
        border-top: 0;
        box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
        box-sizing: border-box;
        position: absolute;
        background-color: #fff;
        z-index: 9;
        padding: 10px 0;
    }
    .works-class {
        width: 100%;
        margin-right: 0;
        position: relative;
        line-height: 46px;
        letter-spacing: 0.06em;
        padding-left: 0;
        margin: 0;
    }
    .works-class.active{
        background-color: #e1e1e1;
    }
    .works-class::after{
        display: none;
    }
    .works-class-border-box{
        display: none;
    }
    .works-class-box{
        padding: 40px 0;
    }
}
@media only screen and (max-width: 750px){
    .works-info:nth-child(n) {
        width: calc((100% - 20px) / 2);
        margin-right: 20px;
        padding-bottom: 0;
    }
    .works-info-img{
        height: calc((380 / 560) * ((95vw - 20px) / 2));
    }
    .works-info:nth-child(2n) {
        margin-right: 0;
    }
    .works-info:nth-child(n + 3) {
        margin-top: 20px;
    }
    .works-info-text-box{
        width: 100%;
        display: block;
        position: static;
        padding: 10px 0;
    }
}
@media only screen and (max-width: 550px){
    .works-box{
        padding-top: 100px;
    }
    .works-info:nth-child(n) {
        width: 100%;
        margin-right: 0;
        padding-bottom: 0;
        margin-top: 10px;
    }
    .works-info-img{
        height: calc((380 / 560) * 95vw);
    }
    .works-info-text-box{
        padding: 5px 0;
    }
    .works-info-class{
        font-size: 12px;
    }
    .works-info-text{
        font-size: 16px;
        margin-top: 0;
    }
    .works-info-arrow{
        margin-top: 10px;
    }
    .works-class-box{
        padding: 20px 0;
    }
}



.works-info:hover .works-info-img span{
    transform: scale(1.1);
}


/*animation*/
/*<-------------動畫------------->*/
@media only screen and (min-width: 1001px){
    .works-info:hover .works-info-text-box{
        box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    }
    .works-class-box.anima .works-class-border-box span:nth-child(1){
        animation: line2 .5s linear 0s 1 both;
        transform-origin: 50% 100%;
    }
    .works-class-box.anima .works-class-border-box span:nth-child(1)::after{
        animation: line .5s ease .4s 1 both;
        transform-origin: 0% 50%;
    }
    .works-class-box.anima .works-class-border-box span:nth-child(2){
        animation: line2 .5s linear 0s 1 both;
        transform-origin: 50% 0%;
    }
    .works-class-box.anima .works-class-border-box span:nth-child(2)::after{
        animation: line .5s ease .4s 1 both;
        transform-origin: 100% 50%;
    }
	.works-class-box.anima .works-class{
        animation: fade 1s ease .5s 1 both;
    }
    .works-info,
    .works-info-text-box{
        opacity: 0;
    }
    .works-info.anima{
        animation: fadeInUp 1s ease 0s 1 both;
    }
    .works-info.anima .works-info-text-box{
        animation: fadeInLeft 1s ease .3s 1 both;
    }
    .works-page_number-box.anima{
        animation: fadeInUp 1s ease 0s 1 both;
    }
}
