﻿@charset "utf-8";

.open_cover{position: fixed;left: 0;top: 0;width: 100%;height: 100%;z-index: 9999;transition: all ease-in-out .8s;-ms-transition: all ease-in-out .8s;-moz-transition: all ease-in-out .8s;-webkit-transition: all ease-in-out .8s;-o-transition: all ease-in-out .8s;opacity: 1;display: none;background: #9c1d1a;}
/* .open_cover::before{content: '';position: absolute;left: 0;top: 0;width: 100%;height: 100%;display: block;background: rgba(0, 0, 0, .2);z-index: 2;} */
.open_cover video{position: absolute;left: 0;top: 0;width: 100%;top: 0;display: block;z-index: 11;object-fit: cover;height: 100%;}
.open_cover.hide{top: -150%;opacity: 0;pointer-events: none;}
.open_cover.show{display:block}
.open_cover .close{z-index: 100;}
.open_cover .bb{position:absolute;left:50%;bottom:22px;text-align:center;transform:translateX(-50%);color:#fff;cursor: pointer;z-index: 10;padding: 40px 0 0;}
.open_cover .loading{width: 100px;height: 100px;position: absolute;left: 50%;top: 50%;transform: translate(-50%, -50%);z-index: 10;}
.open_cover .loading path{stroke: rgb(255,198,125);}

.envelope_mask {
    width: 100%;
    height: 100%;
    background-color: #000;
    opacity: 0.86;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(1.1);
    opacity: 0;
    z-index: -1;
    visibility: hidden;
    transition: all 0.5s ease-out 0s;
}

.envelope_wrap {
    width: 760px;
    height: 657px;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 90000;
}

.envelop_body {
    width: 761px;
    height: 415px;
    background: url(../images/letter_body.png) no-repeat center;
    position: absolute;
    left: 0;
    bottom: 0;
    z-index: 8000;
}

.envelop_top {
    width: 761px;
    height: 250px;
    background: url(../images/letter_front.png) no-repeat center;
    position: absolute;
    top: 244px;
    left: 0;
    transition: transform 0.4s 0.4s, z-index 0.2s 0.4s;
    transform-origin: 50% 0%;
    z-index: 8910;
}

.envelop_top:before {
    content: '';
    width: 320px;
    height: 101px;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background: url(../images/letter_logo.png) no-repeat center;
}

.envelop_article {
    width: 705px;
    height: 240px;
    /* height: 591px; */
    background: url(../images/letter.jpg) no-repeat top center;
    border-radius: 25px;
    margin: 0 auto;
    position: absolute;
    bottom: 170px;
    left: 28px;
    z-index: 7900;
    transition: height 0.5s 0.4s;
    overflow: hidden;
}

.envelop_article h3 {
    text-align: center;
    padding: 54px 0 22px;
    ;
}

.envelop_txt {
    text-align: center;
}

.envelop_black {
    width: 761px;
    height: 415px;
    background-color: #8e242f;
    position: absolute;
    left: 0;
    bottom: 0;
}


/* 爱心弹出 */

.hearts {
    position: absolute;
    bottom: 130px;
    left: 10%;
    right: 0;
}

.heart {
    position: absolute;
    bottom: 0;
    right: 50%;
}

.heart:before,
.heart:after {
    position: absolute;
    content: "";
    left: 50px;
    top: 0;
    width: 50px;
    height: 80px;
    background: #D00000;
    border-radius: 50px 50px 0 0;
    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);
    -webkit-transform-origin: 0 100%;
    transform-origin: 0 100%;
}

.heart:after {
    left: 0;
    -webkit-transform: rotate(45deg);
    transform: rotate(45deg);
    -webkit-transform-origin: 100% 100%;
    transform-origin: 100% 100%;
}

.close .heart {
    opacity: 0;
    -webkit-animation: none;
    animation: none;
}

.envelope_wrap.active .envelop_top {
    transition: transform 0.4s, z-index 0.2s;
    transform: rotateX(180deg);
    /* transition-delay: .9s; */
    z-index: 0;
    /* animation: letterOpen .4s forwards; */
}


/* .envelope_wrap:hover .envelop_top::after {
    width: 761px;
    height: 5px;
    background: #782027;
    content: '';
    position: absolute;
    top: -7px;
    left: 0;
} */

.envelope_wrap.active .envelop_top:before {
    opacity: 0;
}

.envelope_wrap.active .envelop_article {
    height: 492px;
}

.envelope_wrap.active .hearts {
    z-index: 7910;
}

.envelope_wrap.active .a1 {
    left: 20%;
    -webkit-transform: scale(0.6);
    transform: scale(0.6);
    opacity: 1;
    -webkit-animation: slideUp 4s linear 1, sideSway 2s ease-in-out 4 alternate;
    -moz-animation: slideUp 4s linear 1, sideSway 2s ease-in-out 4 alternate;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: .7s;
    animation-delay: .7s;
}

.envelope_wrap.active .a2 {
    left: 55%;
    -webkit-transform: scale(1);
    transform: scale(1);
    opacity: 1;
    -webkit-animation: slideUp 5s linear 1, sideSway 4s ease-in-out 2 alternate;
    -moz-animation: slideUp 5s linear 1, sideSway 4s ease-in-out 2 alternate;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: .7s;
    animation-delay: .7s;
}

.envelope_wrap.active .a3 {
    left: 10%;
    -webkit-transform: scale(0.8);
    transform: scale(0.8);
    opacity: 1;
    -webkit-animation: slideUp 7s linear 1, sideSway 2s ease-in-out 6 alternate;
    -moz-animation: slideUp 7s linear 1, sideSway 2s ease-in-out 6 alternate;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: .7s;
    animation-delay: .7s;
}

.envelope_wrap.active .a4 {
    left: 70%;
    -webkit-transform: scale(.7);
    transform: scale(.7);
    opacity: 1;
    -webkit-animation: slideUp 6s linear 1, sideSway 4s ease-in-out 2 alternate;
    -moz-animation: slideUp 6s linear 1, sideSway 4s ease-in-out 2 alternate;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: .7s;
    animation-delay: .7s;
}

.envelope_wrap.active .a5 {
    left: 0%;
    -webkit-transform: scale(0.9);
    transform: scale(0.9);
    opacity: 1;
    -webkit-animation: slideUp 4.5s linear 1, sideSway 2s ease-in-out 4 alternate;
    -moz-animation: slideUp 4.5s linear 1, sideSway 2s ease-in-out 4 alternate;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: .7s;
    animation-delay: .7s;
}

@-webkit-keyframes slideUp {
    0% {
        top: 0;
    }
    100% {
        top: -200vh;
    }
}

@keyframes slideUp {
    0% {
        top: 0;
    }
    100% {
        top: -200vh;
    }
}

@-webkit-keyframes sideSway {
    0% {
        margin-left: 0px;
    }
    100% {
        margin-left: 50px;
    }
}

@keyframes sideSway {
    0% {
        margin-left: 0px;
    }
    100% {
        margin-left: 50px;
    }
}


/* 烟花 */

#confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 7910;
    /* transform: translate(-50%, -50%); */
}

.confetti {
    position: absolute;
    width: 10px;
    height: 20px;
}


/* @keyframes letterOpen {
    0% {
        transform: rotateX(0);
    }
    100% {
        transform: rotateX(180deg);
    } 


}*/

.bibbon {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    overflow: hidden;
    font-size: 0;
    z-index: 80000;
    opacity: 0;
}

.bibbon .d2 {
    /* width: 7.23rem;
    height: 5.47rem;
    position: absolute;
    right: -0.1rem;
    bottom: .9rem;
    background: url(../images/d2.png) no-repeat left center; */
    width: 0;
    overflow: hidden;
    transition: width 3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 547px;
    position: absolute;
    /* right: -0.1rem; */
    right: 0;
    bottom: 90px;
    background: url(../images/d2.png) no-repeat left center;
}

.d1 {
    width: 100%;
    overflow: hidden;
    transition: width 4.1s cubic-bezier(0.4, 0, 0.2, 1);
    height: 607px;
    position: relative;
    overflow: hidden;
    /*background: url(../images/d1.png) no-repeat left center;*/
    background-size: auto 100%;
}


/* .d1 img {
    position: absolute;
    left: 0;
    width: 100%;
    height: 100%;
} */


/* .bibbon.active .d1 {
    width: 100%;
}

.bibbon.active .d1 {
    -webkit-animation: widthChange 7s linear infinite;
    -moz-animation: widthChange 7s linear infinite;
    -webkit-animation-fill-mode: forwards;
    animation-fill-mode: forwards;
    -webkit-animation-delay: 2s;
    animation-delay: 2s;
} */

@keyframes widthChange {
    0% {
        width: 0;
    }
    50% {
        width: 100%;
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

.envelope_wrap {
    opacity: 0;
    transform: translate(-50%, 100%);
    transition: all 2s ease-in-out;
}

.envelope_wrap.start {
    opacity: 1;
    transform: translate(-50%, -50%);
}

.bibbon {
    transition: all 2s ease-in-out;
    transform: translateY(100%);
}

.bibbon.start {
    transform: none;
    opacity: 1;
}

body.start {
    overflow: hidden;
}

.close {
    position: absolute;
    right: 37px;
    top: 37px;
}

.envelope_mask.start {
    opacity: 0.85;
    z-index: 80000;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

@media screen and (max-width: 1300px) {
    .envelope_wrap {
        transform: translate(-50%, 100%) scale(.8);
    }
    .envelope_wrap.start {
        transform: translate(-50%, -50%) scale(.8);
    }
}

@media screen and (max-width: 1200px) {
    .envelope_wrap {
        transform: translate(-50%, 100%) scale(.5);
    }
    .envelope_wrap.start {
        transform: translate(-50%, -50%) scale(.5);
    }
}

@media screen and (max-width: 480px) {
    .envelope_wrap {
        transform: translate(-50%, 100%) scale(.4);
    }
    .envelope_wrap.start {
        transform: translate(-50%, -50%) scale(.4);
    }
}