@charset "UTF-8";

/* CSSアニメーション */
.story__frame {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
}
/* 最初の要素だけは常に表示状態にしておく */
.story__frame:first-of-type {
  opacity: 1;
  transform: translateY(0);
}
.story__frame.active {
    opacity: 1;
    transform: translateY(0);
}
.fade-in-color {
    filter: grayscale(100%);
    transition: filter 0.6s ease-in-out;
}
.fade-in-color.active {
    filter: grayscale(0%);
}

/* =========================================
story
============================================*/
.container{
    display: block;
}
.story__episode {
    width: 80%;
    background-color: var(--primary-black);
    margin-left: auto;
    color: var(--primary-white);
    padding: 30px 4.2% 30px;
    text-align: right;
    font-size: 1.2rem;
    font-family: 'Montserrat';
}
.section--story .section__topic{
    width: 80%;
    background-color: var(--primary-black);
    margin-left: auto;
}
.story__frame{
    display: flex;
    align-items: flex-end;
}
.story__frame:nth-of-type(2),
.story__frame:nth-of-type(4){
    flex-direction: row-reverse;
}
.story__frame img{
    height: 519px; 
    width: auto;
}
.right,.left{
    color: var(--primary-white);
    font-family: "Noto Serif JP";
    font-size: 1.6rem;
    line-height: 28px;
}
.left{
    z-index: 1;
    margin-right: -100px;
}
.right{
    z-index: 1;
    margin-left: -100px;
}
.story__container{
    padding:22px 0 52px;
    display: flex;
    flex-direction: column;
    gap:100px;
    background-image: url(../images/storybgsp.jpg); 
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}
.story__frame:nth-of-type(1),
.story__frame:nth-of-type(3){
    margin-left: 16px;
}
.story__frame:nth-of-type(2),
.story__frame:nth-of-type(4){
    margin-right: 16px;
}
.story__frame img:last-child{
    display: none;
}
.story__down{
    padding: 72px 0;
}

.story__message{
    margin-right: 4.2%;
    padding: 285px 0 327px ;
    border-radius: 0px 360px 360px 0px;
    background: var(--primary-white);
    background-image: url(../images/handbg.png);
    background-repeat: no-repeat;
    background-position: center 90%;
    background-size: contain;
}
.story__messageframe{
    padding: 0 16px;
    display: flex;
    flex-direction: column;
    gap: 22px;
}
.story__title{
    font-family: "Homemade Apple";
    font-size: 2.4rem;
    line-height: 44px;
}
.story__text p{
    font-size: 1.9rem;
    line-height: 38px
}
.story__text p:nth-of-type(2),
.story__text p:nth-of-type(3),
.story__text p:nth-of-type(4){
    margin-top: 22px;
}

@media screen and (min-width:450px){
.story__episode {
        text-align: center;
    }
}

/* story PC */
@media screen and (min-width:769px){
    
    /* cssアニメーション ホバーPC版*/ 
    .img-hover-effect{
        filter: grayscale(100%); 
        transition: filter 0.5s ease;
    }
    .img-hover-effect:hover {
        filter: grayscale(0%); 
    }
    .story__up{
        max-width: 1160px;
        margin: 0 auto;
    }
    .left {
        max-width: 640px;
        z-index: 0;
        margin-right:0 ;
        font-size: 1.6rem;
        line-height: 32px;
    }    
    .story__frame{
        justify-content: space-between;
    }
    .right{
        max-width: 640px;
        z-index: 0;
        margin-left: 0;
        font-size: 1.6rem;
        line-height: 32px;
    }
    .story__frame img:last-child{
        display: inline-block;
    }
    .story__frame img:nth-of-type(1){
        display: none;
    }
    .story__message{
        display: flex;
        padding: 195px 10.6% 134px 12.9%;
        justify-content: center;
        align-items: center;
    }
    .story__frame:nth-of-type(1),
    .story__frame:nth-of-type(3){
        margin-left: 90px;
    }
    .story__frame:nth-of-type(2),
    .story__frame:nth-of-type(4){
        margin-right: 90px;
    }
    .story__container{
        background-image: url(../images/story-bgpc.jpg);
    }
    .section__topic p{
        text-align: center;
    } 
}