
:root {
    --gallery-peek-height: 80px;
    --card_wrap-margin-top: 20px;

    --card-scale-default: 0.8;
    --card-scale-semi-small: 0.75;
    --card-scale-small: 0.6;

    --card-scale-message-default: 1;
    --card-scale-message-small: 0.85;

    --small-card-top: 30%;

    /* --fiexdMenu-head-height: 80px; */
}

.Boucheron-2025 { overscroll-behavior: contain; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; }
.Boucheron-2025 .btn { position: absolute; left: 50%; bottom: 5.5%; transform: translateX(-50%);  width: 100%; border-radius: 130px; text-align: center; visibility: visible; opacity: 1; transition: opacity 1s;}
.Boucheron-2025 .btn > a {position: relative; z-index: 10; display: block; padding: 30px 0; font-size: 29px; letter-spacing: -0.05em; line-height: normal; color: #fff; font-weight: 500;}

.Boucheron-2025 > .wrap {width: 100%; background: url(/images/pc_bg_v2.jpg) no-repeat center / cover;}
.Boucheron-2025 > .wrap > .inner {position: relative; width: 100%; max-width: 540px; margin: 0 auto; height: 100dvh; padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }

/* .Boucheron-2025 .inner > .bg {width: 100%; height: 100%;}
.Boucheron-2025 .inner > .bg > img {width: 100%; height: 100%; min-height: 100dvh; object-fit: cover;} */


/* 메인 페이지 */
.main .inner > .logo {opacity: 1; position: absolute; top: 5%; left: 50%; transform: translateX(-50%); width: 100%; max-width: 250px; transition: opacity .3s;}
.main .inner > .logo.off {opacity: 0;}
.main .inner > .logo > img {width: 100%;}
.main .inner > .title {opacity: 1; position: absolute; top: 32%; left: 50%; transform: translateX(-50%); width: 100%; transition: opacity 1s;}
.main .inner > .title.off {opacity: 0;}
.main .inner > .title p { font-size: 35px; color: #fff; letter-spacing: -0.05em; line-height: 1.7; text-align: center; text-transform: uppercase; }
.main .inner > .title p + p {margin-top: 33px;}

.main .inner > .btn.start { width: calc(100% - 85px); background-color: #6598d8; overflow: hidden; }
.main .inner > .btn.start.glow { animation: neonGlow 1.5s ease-in-out infinite; }
.main .inner > .btn.start.off { opacity: 0; visibility: hidden;}

.main .inner > .btn.start #effect { position: absolute; width: 100%; height: 100%;}
.main .inner > .btn.start #effect > img {width: 100%; height: 100%;}


@keyframes neonGlow {
    0%, 100% {
        box-shadow:
        0 0 20px rgba(100, 142, 205, 0.3),
        0 0 40px rgba(100, 142, 205, 0.2),
        0 0 50px rgba(100, 142, 205, 0.15),
        0 0 60px rgba(100, 142, 205, 0.00);
    }
    50% {
        box-shadow:
        0 0 20px rgba(100, 142, 205, 0.6),
        0 0 40px rgba(100, 142, 205, 0.5),
        0 0 60px rgba(100, 142, 205, 0.3),
        0 0 80px rgba(100, 142, 205, 0.25),
        0 0 100px rgba(100, 142, 205, 0.18);
    }
}


@media screen and (min-width: 1920px) {
    .main .inner > .title p {font-size: 40px;}
    

}
@media screen and (min-width: 768px) {
    .Boucheron-2025 > .wrap {background: url(/images/pc_bg_v3.jpg) no-repeat center / cover;}
    .main .inner > .logo {max-width: 280px;}
    .main .inner > .title {width: 140%;}
}
@media screen and (max-width: 768px) {
    .main .inner > .title {width: 100%;}
    .main .inner > .title p {font-size: 22px;}
    .main .inner > .title p + p {margin-top: 20px;}

}

@media screen and (max-width: 450px) {
    .main .inner > .logo {max-width: 190px;}
    .main .inner > .title {top: 30%;}
    .main .inner > .title p {font-size: 20px;}
    .main .inner > .title p + p {margin-top: 20px;}
    
    .Boucheron-2025 .btn > a {padding: 24px 0; font-size: 22px;}
}

@media screen and (max-width: 500px) and (max-height: 800px) {
    .main .inner > .logo {max-width: 170px;}
    .main .inner > .title p {font-size: 18px;}
    
    .Boucheron-2025 .btn > a {padding: 20px 0; font-size: 20px;}
    
}
@media screen and (max-width: 375px) {
    .main .inner > .logo {max-width: 150px;}
    .main .inner > .title p {font-size: 18px;}

}

/* 메인 페이지 인트로 */
.inner_popup.intro.loading {}
.inner_popup.intro.loading > .bg {background: rgba(255, 255, 255, 1);}
.inner_popup.intro > .bg {pointer-events: none; background: rgba(255, 255, 255, 0.35); transition: background 0.6s, opacity 0.6s;}
.inner_popup.intro > .inner {pointer-events: none; width: 100%; max-width: 900px; height: 900px; padding: 0; border-radius: 0; background-color: transparent; transition: opacity 0.6s;}
.inner_popup.intro .txt_box { height: 100%; display: flex; flex-direction: column; justify-content: center; text-align: center; background: url(/images/open_intro_blur.png) no-repeat center / 800px; transition: opacity 1s;}
.inner_popup.intro .txt_box > p { display: none; padding: 0px; color: #29476c; font-family: 'Pretendard', sans-serif; font-weight: 500; font-size: 32px; line-height: 1.5; white-space: pre-line;}

.inner_popup.intro .txt_box > p.fade-in { opacity: 1; }
.inner_popup.intro .txt_box > p.fade-out { opacity: 0; }

@media screen and (min-width: 1024px) {
    .inner_popup.intro > .inner {max-width: 1100px;}
    .inner_popup.intro .txt_box {background-size: 1100px;}
}

@media screen and (max-width: 450px) {
    .inner_popup.intro .txt_box > p {font-size: 26px;}
}
@media screen and (max-width: 400px) {
    .inner_popup.intro .txt_box > p {font-size: 23px;}
}
@media screen and (max-width: 370px) {
    .inner_popup.intro .txt_box > p {font-size: 21px;}

}

/* 카드 만들기 팝업 */
.popup { position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; z-index: 10; pointer-events: none;}
.popup > .bg { overscroll-behavior: contain; opacity: 0; pointer-events: none; transition: opacity .3s; position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: rgba(0, 0, 0, 0.8); }
.popup > .inner { overscroll-behavior: contain; padding-top: 30px; position: relative; opacity: 0; visibility: hidden; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100%; height: 100%; transition: opacity .3s;}

.popup.on > .bg { opacity: 1; pointer-events: all;}
.popup.on > .inner { opacity: 1; visibility: visible; pointer-events: all;}

.popup .top_btns {display: flex; justify-content: space-between; align-items: center; padding: 0 50px;}
.popup .backBtn {display: block; width: 55px; height: 55px;}
.popup .backBtn > img {width: 100%; height: 100%;}
.popup .nextBtn {font-size: 22px; color: #b0c8ee; letter-spacing: -0.05em;}

.popup .step_title {text-align: center; padding-top: 25px; font-size: 18px; color: #fff; letter-spacing: -0.05em; text-transform: uppercase;}

.popup .card_wrap { touch-action: none; position: relative; width: 100%; height: 110vw; max-height: 769px; max-width: 540px; margin: 0 auto; margin-top: 30px; transition: all .3s; filter: drop-shadow(0px 0px 10px rgba(0, 0, 0, 0.5)); }
.popup .card_wrap .card { overscroll-behavior: none; scale: var(--card-scale-default); top: auto; transform-origin: center top; position: absolute; width: 100%; height: auto; padding: 18.7% 6.7% 24%; border-radius: 20px; border: 1px solid #787878; overflow: hidden; transition: scale .3s , top 0.3s; }
.popup .card_wrap .card:has(.deco_sticker_area em.move) {overflow: visible;}
.popup .card_wrap .card_frame {opacity: 0; visibility: hidden;  transition: opacity 0.5s ease, visibility 0.5s ease;}
.popup .card_wrap .card_frame.active { opacity: 1; visibility: visible; }

.popup .card_wrap:has(.card.small) {margin-top: 0px;}


.popup .card .card_frame {position: absolute; top: 50%; left: 50%; width: 100%; height: 100%; z-index: 1; transform: translate(-50%, -50%); background-size: cover; background-repeat: no-repeat; background-position: top center; border-radius: 20px;}
.popup .card .card_frame[data-frame= "4"] {background-image: url(/images/pattern_4_v2.jpg);}
.popup .card .card_frame[data-frame= "5"] {background-image: url(/images/pattern_5_v2.jpg);}

.popup .btn_ratio_wrap { position: absolute; bottom: 70px; left: 50%; transform: translateX(-50%); width: 140px; height: 56px; background: rgba(255, 255, 255, 0.5); border-radius: 35px; padding: 5px; box-sizing: border-box; cursor: pointer; border: 1px solid #fff; transition: top 0.3s; }
.popup .btn_ratio_wrap.active { bottom: 30px;}
.popup .btn_ratio_wrap .toggle_slider { position: absolute; top: 50%; left: 5px; transform: translateY(-50%); width: 55%; height: 46px; background: white; border-radius: 30px; transition: all 0.3s ease; box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); }
.popup .btn_ratio_wrap.active .toggle_slider { left: calc(45% - 5px); }
.popup .btn_ratio_wrap .ratio_labels { position: relative; display: flex; height: 100%; z-index: 1; }
.popup .btn_ratio_wrap .btn_ratio { flex: 1; display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 400; transition: all 0.3s ease; background: none; border: none; cursor: pointer; font-family: "Pretendard" , sans-serif; color: #fff; letter-spacing: -0.02em; }
.popup .btn_ratio_wrap:not(.active) .btn_ratio[data-ratio="4:5"] { color: #648dcd; padding-left: 6px; }

.popup .btn_ratio_wrap.active .btn_ratio[data-ratio="9:16"] { color: #648dcd; padding-right: 6px; }




.popup .card_wrap .card .img_frame { position: relative; aspect-ratio: 1 / 1.5666; /* background-color: #fff; background-image: url(/images/polygon_bg.png); background-repeat: no-repeat; background-size: cover; */ clip-path: polygon(23% 0%, 77% 0%, 100% 13%, 100% 87%, 77% 100%, 23% 100%, 0% 87%, 0% 13%); z-index: 3; }
.popup .card_wrap .img_frame > .bg {}
.popup .card_wrap .img_frame .upload_img {width: 100%; height: 100%;}
.popup .card_wrap .img_frame .upload_img > img {width: 100%; height: 100%; object-fit: cover;}

.popup .card_wrap .img_frame > .add_btn {display: none; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100%; max-width: 80px;}
.popup .card_wrap .img_frame > .add_btn > img {width: 100%;}



/* 4:5 프레임 */
.popup .card.small .card_frame[data-frame= "4"] {background-image: url(/images/small_pattern_4.jpg);}
.popup .card.small .card_frame[data-frame= "5"] {background-image: url(/images/small_pattern_5.jpg);}

.popup .card_wrap .card.small { padding: 12% 15.3% 16%; top: 50%; transform: translateY(-50%);}
.popup .card_wrap .card.small .img_frame { aspect-ratio: 1 / 1.42; }

.popup .card.small .deco_text_area {margin-top: 4%; height: 11vw; max-height: 60px;}
.popup .card.small .deco_text_area .txt_img {top: 51%;}



.popup .deco_text_area { opacity: 0; visibility: hidden; pointer-events: none; cursor: pointer; display: flex; justify-content: center; align-items: center; position: absolute; left: 50%; transform: translateX(-50%); width: fit-content; max-width: 400px; height: 15vw; min-height: 40px; max-height: 64px; margin-top: 4.3%; border: 1px solid #fff; background: url(/images/deco_text_bg.png) no-repeat center / cover; border-radius: 10px; z-index: 4; transition: opacity 0.3s; }
.popup .deco_text_area #decoText { padding: 0 70px; text-align: center; background-color: transparent; font-family: 'Sackers Gothic Std', sans-serif; font-size: clamp(17px, 4.5vw , 22px); color: #fff; font-weight: 300; text-transform: uppercase; white-space: nowrap; }
.popup .deco_text_area .reset_btn { display: flex; justify-content: center; align-items: center; position: absolute; aspect-ratio: 1; width: 53px; top: 0%; left: 100%; transform: translate(-50%, -50%); background-color: #72aee0; border-radius: 50%; filter: drop-shadow(5px 5px 7px rgba(100,100,100, 0.2)); z-index: 10; cursor: pointer; opacity: 1; transition: opacity 0.3s; }
.popup .deco_text_area .reset_btn.hidden { opacity: 0; pointer-events: none; }
.popup .deco_text_area .reset_btn > img {width: 100%; max-width: 30px;}
.popup .deco_text_area .txt_img { display: none; position: absolute; left: 50%; top: 51%; transform: translate(-50% , -50%); width: 105%; max-width: 300px;}
.popup .deco_text_area .txt_img > img {width: 100%;}

.popup .card.small .deco_text_area .txt_img { width: 100%; max-width: 290px;}
.popup .card.small .deco_text_area #decoText { font-size: clamp(17px, 4vw , 22px);}


@media screen and (min-width: 500px) {
    .popup .card.small .deco_text_area .txt_img {top: 42%;}

}
@media screen and (max-width: 450px) {
    .popup .deco_text_area {max-width: 300px;}
}

@media screen and (min-width: 768px) {
    :root {--small-card-top: 50%;}
}

@media screen and (min-width: 500px) and (max-width: 767px) {
    :root {--small-card-top: 35%;}
}

/* 커스텀 셀렉트 박스 스타일 */
.custom_select_wrapper { position: fixed; z-index: 9999; display: none; transform-origin: bottom left; filter: drop-shadow(0px 0px 6px rgba(0, 0, 0, 0.25)); }
.custom_select_wrapper .custom_select_option:first-of-type { border-radius: 10px 10px 0 0; }
.custom_select_wrapper .custom_select_option:last-of-type { border-radius: 0 0 10px 10px; }
.custom_select_wrapper.active { display: block; }
.custom_select_wrapper .reset_btn { display: flex; justify-content: center; align-items: center; position: absolute; aspect-ratio: 1; width: 53px; top: 0%; left: 100%; transform: translate(-50%, -50%); background-color: #72aee0; border-radius: 50%; z-index: 10; cursor: pointer; }
.custom_select_wrapper .reset_btn > img { width: 100%; max-width: 30px; }

.custom_select_option { display: flex; justify-content: center; align-items: center; width: 100%; height: 15vw; min-height: 40px; max-height: 64px; border: none; background-color: #fff; cursor: pointer; transition: all 0.3s; margin-top: -1px; }
.custom_select_option.selected { background-color: #e8eef3; }
.custom_select_option:hover { background-color: #e8eef3; }
.custom_select_option p { padding: 0 70px; text-align: center; background-color: transparent; font-family: 'Sackers Gothic Std', sans-serif; font-size: clamp(17px, 4.5vw , 21px); color: #648dcd; font-weight: 400; letter-spacing: -0.05em; text-transform: uppercase; white-space: nowrap; }
.custom_select_wrapper.small .custom_select_option p {font-size: clamp(17px, 4vw , 21px); }




.popup .deco_text_area.on { opacity: 1; visibility: visible; pointer-events : all; }
.popup .deco_text_area.on.capture {background: transparent; border: none; width: 100%;}
.popup .deco_text_area.on.capture .txt_img {display: block;}
.popup .deco_text_area.on.capture #decoText {display: none;}
.popup .deco_text_area.on.capture .reset_btn {display: none;}


.popup .deco_sticker_area {position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100%; height: 100%; z-index: 4; pointer-events: none;}
.popup .deco_sticker_area.on {pointer-events: all;}
.popup .deco_sticker_area > em {cursor: grab; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center; width: 40%; min-width: 50px; max-width: 500px; aspect-ratio: 1;}
.popup .deco_sticker_area > em .stic_img {width: 100%; height: 100%; max-width: 100%; pointer-events: none; object-fit: contain;}
.popup .deco_sticker_area > em > button { opacity: 0; visibility: hidden; position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center; filter: drop-shadow(5px 5px 7px rgba(100,100,100, 0.2));}
.popup .deco_sticker_area > em > button > img {width: 36%;}
.popup .deco_sticker_area > em > button.del_btn {top: 0; left: 100%; width: 50px; aspect-ratio: 1; border-radius: 50%; background-color: #07223a;}
.popup .deco_sticker_area > em > button.size_btn {top: 100%; left: 100%; width: 50px; aspect-ratio: 1; border-radius: 50%; background-color: #97d3f7;}
.popup .deco_sticker_area > em > button.size_btn.left {top: 100%; left: 0%; width: 50px; aspect-ratio: 1; border-radius: 50%; background-color: #97d3f7;}
.popup .deco_sticker_area > em > button.size_btn.left > img {transform: rotate(90deg);}


.popup .deco_sticker_area > em.move {outline: 2px solid #fff;}
.popup .deco_sticker_area > em.move > button {opacity: 1; visibility: visible; pointer-events: all;}
.popup .deco_sticker_area > em.move > button {opacity: 1; visibility: visible; pointer-events: all;}

.popup .slide_btn { position: absolute; top: 50%; transform: translateY(-50%); width: 100%; max-width: 20px; transition: none;}
.popup .slide_btn > img {width: 100%; filter: invert(1); -webkit-filter: invert(1);}
.popup .slide_btn.prev {left: 13px;}
.popup .slide_btn.next {right: 13px;}



/* 데코 텍스트 선택 / 팝업의 내부 팝업 */
.inner_popup { position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; z-index: 30; }
.inner_popup > .bg { opacity: 0; pointer-events: none; transition: opacity .3s; position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: rgba(0, 0, 0, 0.8); transition: opacity .5s;}
.inner_popup > .inner { position: relative; opacity: 0; visibility: hidden; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: calc(100% - 60px); max-width: 400px; height: auto; padding: 25px 15px; transition: opacity .5s; overflow-y: auto; background-color: #fff; border-radius: 20px;}

.inner_popup.on > .bg { opacity: 1; pointer-events: all;}
.inner_popup.on > .inner { opacity: 1; visibility: visible; pointer-events: all;}

.inner_popup.phrase .inner > .header {text-align: center; margin-bottom: 15px;}
.inner_popup.phrase .inner > .header > h1 {color: #000; font-weight: 500; font-size: 15px; line-height: 1.8;}

.inner_popup.phrase .phrase-list {padding: 0 30px; margin-bottom: 25px; background-color: #eff1f8; border-radius: 1em;}
.inner_popup.phrase .phrase-item { display: flex; align-items: center; justify-content: space-between; padding: 35px 0; cursor: pointer; transition: background 0.2s; }
.inner_popup.phrase .phrase-item + .phrase-item { border-top: 1px solid #e9e6e6; }
.inner_popup.phrase .phrase-text { padding-left: 20px; font-size: 17px; font-weight: 500; letter-spacing: -0.04em; color: #648dcd; text-transform: uppercase; }
.inner_popup.phrase .radio-button { width: 28px; height: 28px; border: 3px solid #648dcd; border-radius: 50%; position: relative; flex-shrink: 0; transition: all 0.3s ease; }
.inner_popup.phrase .phrase-item:hover .radio-button { border-color: #5a8bc4; transform: scale(1.05); }
.inner_popup.phrase .radio-button.checked { border-color: #648dcd; }
.inner_popup.phrase .radio-button.checked::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 16px; height: 16px; background: #648dcd; border-radius: 50%; animation: scaleIn 0.2s ease; }

.inner_popup.phrase .btn_complete {width: 100%; padding: 15px 0; border-radius: 50px; background-color: #eff1f8; font-weight: 500; font-size: 20px; letter-spacing: -0.04em;}


/* 프레임 설명 팝업 */
.inner_popup.select_frame {position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; opacity: 0; pointer-events: none; transition: opacity 0; z-index: 10;}
.inner_popup.select_frame .bg {position: fixed; top: 0; left: 0; width: 100%; height: 100dvh; background: rgba(0, 0, 0, 0.50);  opacity: 0; pointer-events: none; transition: opacity .3s;}
.inner_popup.select_frame .inner { display: none; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: calc(90% - 20px); max-width: 380px; height: auto; padding: 0; padding-bottom: 30px; border-radius: 25px; background: #e0e0e0; filter: drop-shadow(0px 0px 10px rgba(0, 0, 0, 0.5)); }
.inner_popup.select_frame .inner .top { position: relative; display: flex; align-items: center; justify-content: center; height: 55px;}
.inner_popup.select_frame .inner .top .btn_close { position: absolute; top: 60%; right: 25px; transform: translateY(-50%); width: 18px; height: 18px; background: url(/images/btn_close2.png) no-repeat center center / 100% auto; }
.inner_popup.select_frame .inner > .txt { margin-bottom: 35px; color: #29476C; text-align: center; font-size: 21px; font-weight: 500; line-height: 1.4; letter-spacing: -1.5px; }
.inner_popup.select_frame .inner > .btn_close { display: block; width: calc(100% - 30px); max-width: 270px; padding: 14px 0; margin: 0 auto; border-radius: 50px; background: #648DCD; text-align: center; color: #FDFDFD; font-size: 18px; font-weight: 300; letter-spacing: -1.125px;}

.inner_popup.select_frame.on,
.inner_popup.select_frame.on .bg { opacity: 1; pointer-events: all;}
.inner_popup.select_frame.on .inner {display: block;}

.inner_popup.select_frame.on {transition: opacity 1s;}

@keyframes scaleIn {
    from {
        transform: translate(-50%, -50%) scale(0);
    }
    to {
        transform: translate(-50%, -50%) scale(1);
    }
}

@media screen and (max-width: 767px) {
    .inner_popup.phrase .phrase-list {padding: 0 23px; margin-bottom: 20px;}
    .inner_popup.phrase .phrase-item {padding: 35px 0;}
    .inner_popup.phrase .inner > .header > h1 {font-size: 13px;}
    .inner_popup.phrase .phrase-text {font-size: 15px; padding-left: 25px;}
    .inner_popup.phrase .btn_complete {font-size: 18px;}

}
@media screen and (max-width: 400px) {
    .inner_popup > .inner {padding: 20px 10px;}
    .inner_popup.phrase .phrase-text {padding-left: 15px;}
    .inner_popup.phrase .inner > .header > h1 {font-size: 13px;}
    .inner_popup.phrase .phrase-list {padding: 0 17px;}
    .inner_popup.phrase .phrase-item {padding: 27px 0;}
    .inner_popup.phrase .phrase-text {font-size: 15px;}
    .inner_popup.phrase .radio-button {width: 24px; height: 24px;}
    .inner_popup.phrase .btn_complete {padding: 12px 0; font-size: 17px;}

    .inner_popup.select_frame .inner > .txt {font-size: 20px;}
}




/* 하단 갤러리 이미지, 스티커 탭 */
.fixed_menu {display: none; position: fixed; top: 70%; left: 50%; transform: translateX(-50%); z-index: 20; width: 100%; height: 100%; background-color: #ecf5fe;}
.fixed_menu.on {display: block;}
.fixed_menu > .inner {}
.fixed_menu .head_wrap { overscroll-behavior: none; width: 100%; padding: 10px 0; background-color: #d0e6f9;}
.fixed_menu .head_wrap .top_list { display: flex; align-items: center; justify-content: center; gap: 15px; min-height: 51px; transition: all 0.3s;}
.fixed_menu .head_wrap .top_list:has(li.onSub) {gap: 12px;}
.fixed_menu .head_wrap .top_list > li {display: flex; align-items: center; justify-content: center; width: 50px; height: 50px; background-color: #8eafdb; border-radius: 15px; transition: all 0.3s;}
.fixed_menu .head_wrap .top_list > li.on {background-color: #4c79bd;}
.fixed_menu .head_wrap .top_list > li.onSub { pointer-events: none; background-image: none; width: fit-content; height: fit-content; padding: 5px; background-color: #fff; }

.fixed_menu .head_wrap .sub_list { pointer-events: none; display: flex; align-items: center; gap: 0px; border-radius: 15px; transition: gap 0.3s ease; }
.fixed_menu .head_wrap .sub_list > li { width: 50px; height: 50px; background-color: #dde6f4; border-radius: 15px; flex-shrink: 0; opacity: 0; transform: translateX(-20px); transition: opacity 0.3s ease, transform 0.3s ease; }
.fixed_menu .head_wrap .sub_list > li.on { border: 1px solid #8cb0d8; background-color: #b0c5e6;}

/* 스티커버튼 스타일 */
.fixed_menu .head_wrap .top_list > li.sticker { overflow: hidden; position: relative; }
.fixed_menu .head_wrap .sub_list > * { overflow: hidden; }
.fixed_menu .head_wrap .top_list > li.onSub .sub_list { pointer-events: all; grid-template-columns: 1fr; gap: 15px; }
.fixed_menu .head_wrap .top_list > li.onSub .sub_list > li { opacity: 1; transform: translateX(0); }
.fixed_menu .head_wrap .sub_list::before { content: ''; display: none; }

/* 스티커탭 순차 애니메이션 */
.fixed_menu .head_wrap .top_list > li.onSub .sub_list > li:nth-child(1) { transition-delay: 0.05s; }
.fixed_menu .head_wrap .top_list > li.onSub .sub_list > li:nth-child(2) { transition-delay: 0.1s; }
.fixed_menu .head_wrap .top_list > li.onSub .sub_list > li:nth-child(3) { transition-delay: 0.15s; }
.fixed_menu .head_wrap .top_list > li.onSub .sub_list > li:nth-child(4) { transition-delay: 0.2s; }


.fixed_menu .top_list li,
.fixed_menu .top_list .sub_list li {background-size: 30px;}
.fixed_menu .top_list .camera {background: url(/images/icon_camera.png) no-repeat center / 30px;}
.fixed_menu .top_list .camera.on {background-image: url(/images/icon_camera_on.png);}
.fixed_menu .top_list .sticker {background: url(/images/icon_sticker_v2.png) no-repeat center / 30px;}
.fixed_menu .top_list > .sticker.onSub .sub_list > .sticker { pointer-events: none; background-image: url(/images/icon_sticker_on_v2.png); background-color: #4c79bd;}
.fixed_menu .sub_list .product {background: url(/images/icon_product.png) no-repeat center;}
.fixed_menu .sub_list .cat {background: url(/images/icon_cat.png) no-repeat center;}
.fixed_menu .sub_list .snow {background: url(/images/icon_snow.png) no-repeat center;}
.fixed_menu .top_list .sub_list .product {background-size: 23px;}


.fixed_menu .body_wrap {padding: 20px 0; overflow-x: auto; height: 29vh;}
.fixed_menu .item_list { display: grid; grid-template-columns: 1fr 1fr 1fr; row-gap: 20px; column-gap: 25px; width: calc(100% - 30px); max-width: 430px; margin: 0 auto; }
.fixed_menu .item_list > li { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; width: 100%; border-radius: 20%; overflow: hidden; background-color: #fff;}
.fixed_menu .item_list > li.selected {outline: 2px solid #fff;}
/*.fixed_menu .item_list:not(.photo) > li {padding: 15px;}*/
/* .fixed_menu .item_list.stic_vladimir > li {padding: 15%;} */
.fixed_menu .item_list.stic_season > li > img {width: 75%; height: 75%;}
.fixed_menu .item_list > li > img {width: 65%; height: 65%; object-fit: contain;}
.fixed_menu .item_list.photo > li > img {width: 100%; height: 100%; object-fit: contain;}
.fixed_menu .item_list.photo > li > img {object-fit: cover; object-position: top;}

.fixed_menu .item_list .add_photo {background: url(/images/icon_add_photo.png) no-repeat center / 35%; background-color: #fff;}

/* .fixed_menu.gallery {display: block; visibility: hidden; opacity: 0; top: auto; bottom: -100%; height: 300px; transition: bottom 0.4s ease;}
.fixed_menu.gallery.on {visibility: visible; opacity: 1; bottom: 0%; } */

.fixed_menu.gallery { display: block; visibility: hidden; opacity: 0; position: fixed; top: auto; left: 50%; bottom: -100%; transform: translateX(-50%); height: 100%; width: 100%; background-color: #ecf5fe; z-index: 20; overscroll-behavior: contain;}

.fixed_menu.gallery.on { visibility: visible; opacity: 1; bottom: -78%; transition: opacity 0.3s;}

.fixed_menu.gallery.full { bottom: 0; padding-bottom: env(safe-area-inset-bottom);}
.fixed_menu.gallery.on.full .body_wrap { height: auto;
    user-select: none; /* 텍스트 선택 방지 */
    -webkit-user-drag: none; /* 이미지 드래그 방지 (Safari용) */
    touch-action: none;
    overscroll-behavior: contain;
}
.fixed_menu.gallery.on.full > .inner {height: 100%;}
.fixed_menu.gallery .empty_space {display: none;}
.fixed_menu.gallery.on.full .empty_space {display: block; width: 100%; height: 100%;}


/* 갤러리 or 스티커 바로가기 메뉴 */
.fixed_menu.direction { top: auto; bottom: 0%; height: auto; margin-bottom: 30px; background-color: transparent;}
.fixed_menu.direction > .inner {display: flex; justify-content: center; gap: 30px;}
.fixed_menu.direction .btn_to {aspect-ratio: 1; width: 130px; height: 130px; border-radius: 20px;  border: 6px solid transparent;}
.fixed_menu.direction .btn_to.on {box-shadow: 0px 0px 0px 1.5px #fff;}
.fixed_menu.direction .btn_to > img {background-color: #fff; width: 100%; height: 100%; object-fit: contain; padding: 25%; border-radius: 1em;}


@media screen and (min-width: 767px) {
    .fixed_menu.gallery {border-radius: 15px 15px 0 0; overflow: hidden;}

    .fixed_menu .item_list {width: 90%; max-width: none; grid-template-columns: repeat(auto-fit, 100px); justify-content: center;}
    .fixed_menu .item_list > li {max-width: 100px;}
    /* .fixed_menu .item_list:not(.photo) > li {padding: 10px;} */
}

@media screen and (max-width: 767px) {
    :root {
        --gallery-peek-height: 56px;

    }

    .fixed_menu.direction > .inner {gap: 20px;}
    .fixed_menu.direction .btn_to {width: 110px; height: 110px;}
    .fixed_menu.gallery .body_wrap {height: 16vh;}
    .fixed_menu .item_list {width: 75%; row-gap: 10px; column-gap: 15px;}

    .fixed_menu .head_wrap {padding: 4px 0;}
    .fixed_menu .head_wrap .top_list {min-height: 48px;}
    .fixed_menu .head_wrap .top_list:has(li.onSub) { gap: 8px;}
    .fixed_menu .head_wrap .top_list > li.onSub {padding: 3px;}
    .fixed_menu .head_wrap .top_list > li.onSub .sub_list{gap: 10px;}
    .fixed_menu .head_wrap .top_list > li {width: 40px; height: 40px; border-radius: 10px;}
    .fixed_menu .head_wrap .sub_list > li {width: 40px; height: 40px; border-radius: 10px;}
    .fixed_menu .top_list .camera {background-size: 23px;}
    .fixed_menu .top_list .sub_list .product {background-size: 17px;}
    .fixed_menu .top_list li,
    .fixed_menu .top_list .sub_list li {background-size: 25px;}
    .fixed_menu .body_wrap {padding: 12px 0;}
}

@media screen and (max-width: 450px) {

    .fixed_menu.direction {margin-bottom: 10px;}
    .fixed_menu.direction > .inner {gap: 15px;}
    .fixed_menu.direction .btn_to {width: 80px; height: 80px;}
}

@media screen and (max-width: 380px) {
    :root {
        --card_wrap-margin-top: 20px;
    }

    .fixed_menu.gallery .body_wrap {height: 14vh;}

    .fixed_menu.direction {margin-bottom: 5px;}
    .fixed_menu.direction > .inner {gap: 15px;}
    .fixed_menu.direction .btn_to {width: 75px; height: 75px;}
}
@media screen and (max-width: 380px) and (min-height: 850px) {
    .fixed_menu.gallery .body_wrap {height: 16vh;}
}



/* 메세지 작성 페이지 index_message */
.message .mid {max-width: 540px; margin: 0 auto; height: 73vh;}

.message .mid .font_menu {display: block; transition: all 0.6s; opacity: 0; visibility: hidden;}
.message .mid .font_menu.on {opacity: 1; visibility: visible;}
.message .mid .font_menu > ul {display: flex; align-items: center; justify-content: space-between; padding: 0 20px; gap: 5px;}
.message .mid .font_menu > ul li {padding: 5px 0px; width: 100%; max-width: 80px; background-color: rgba(253, 253, 253, 0.3); border-radius: 20px; cursor: pointer;}
.message .mid .font_menu > ul li.on {outline: 1px solid #fff;}
.message .mid .font_menu > ul li > p {text-align: center; font-size: 15px; color: #fff;}
.message .mid .font_menu > ul li > p.GmarketSans {font-family: 'GmarketSans', sans-serif; font-weight:300; }
.message .mid .font_menu > ul li > p.AritaDotumKR {font-family: 'AritaDotumKR',sans-serif; font-weight:500;}
.message .mid .font_menu > ul li > p.Continuous {font-family: 'Continuous',sans-serif;  font-weight:300;}
.message .mid .font_menu > ul li > p.Continuous > span {font-family: 'AritaDotumKR',sans-serif; font-weight:500;  line-height: 1; vertical-align: text-top;}
.message .mid .font_menu > ul li > p.THEFACESHOP {font-family: 'THEFACESHOP',sans-serif; font-weight:300; scale: 1.2; pointer-events: none;}
.message .mid .font_menu > ul li > p.SDMiSaeng {font-family: 'SDMiSaeng',sans-serif; font-weight:300; scale: 1.5; pointer-events: none;}


.message .mid .card_area { scale: var(--card-scale-message-default); position: relative; width: 100%; height: fit-content; margin-top: 2vh; perspective: 1000px; transition: all 0.3s;}
.message .mid .card_area .card_inner { position: relative; width: calc(100% - 100px); height: fit-content; margin: 0 auto; transition: transform 0.8s; transform-style: preserve-3d; }
.message .mid .card_area .card_front { width: 100%; height: fit-content; filter: drop-shadow(0px 0px 10px rgba(0, 0, 0, 0.5)); border-radius: 15px; overflow: hidden;}
.message .mid .card_area .card_front > img {width: 100%; height: auto;}

.message .mid .card_area .card_back { position: absolute; left: 0; top: 0; transform: rotateY(180deg); backface-visibility: hidden; width: 100%; height: 100%; border-radius: 15px; overflow: hidden;}
.message .mid .card_area .card_back .frame { position: relative; width: 100%; height: 100%; padding: 5.5% 4.5% 0; background-image: url(/images/pattern_4_v2_back.jpg); background-repeat: no-repeat; background-size: 100% 100%; }
.message .mid .card_area .card_back .logo {position: absolute; bottom: 7%; left: 50%; transform: translateX(-50%); width: 100%; max-width: 120px;}
.message .mid .card_area .card_back .logo > img {width: 100%;}
.message .mid .card_area.flipped .card_inner { transform: rotateY(180deg); }

.message .mid:has(.card_area.small) {padding-top: 0%;}
.message .mid .card_area.small {margin-top: 5%; --card-scale-message-default: 1; --card-scale-message-small: 1; }


.message .mid .card_back .text_area { background-color: #fff; border-radius: 10px 50px 10px 50px; height: 80%; margin: 0 auto; padding: 17% 5%; word-break: break-all; }
#userText {width: 100%; height: 100%; overflow: hidden; color: #2681b7; letter-spacing: -0.05em; font-size: 19px; pointer-events: none; resize: none; line-height: 2.4;}
#userText.GmarketSans { font-family: 'GmarketSans', sans-serif; font-weight: 300; font-size: 20px; line-height: 2.3; letter-spacing: -0.008em;}
#userText.AritaDotumKR { font-family: 'AritaDotumKR', sans-serif; font-weight: 500; font-size: 24px; line-height: 1.9; letter-spacing: -0.008em;}
#userText.Continuous { font-family: 'Continuous', sans-serif; font-weight: 300; font-size: 23px; line-height: 2.1; letter-spacing: normal;}
#userText.THEFACESHOP { font-family: 'THEFACESHOP', sans-serif; font-weight: 300; font-size: 26px; line-height: 1.8; letter-spacing: -0.02em;}
#userText.SDMiSaeng { font-family: 'SDMiSaeng', sans-serif; font-weight: 300; font-size: 31px; line-height: 1.5; letter-spacing: -0.02em;}

.message .mid .btn_flip { opacity: 0; visibility: hidden; pointer-events: none; display: flex; justify-content: center; align-items: center; position: absolute; aspect-ratio: 1; width: 53px; bottom: 0%; left: calc(100% - 50px); transform: translate(-50%, 50%); background-color: #72aee0; border-radius: 50%; filter: drop-shadow(5px 5px 7px rgba(100, 100, 100, 0.2)); transition: opacity 0.5s; cursor: pointer; }
.message .mid .btn_flip.on { opacity: 1; visibility: visible; pointer-events: all; }
.message .mid:has(.font_menu:not(.on)) .btn_flip.on {left: calc(100% - 50px);}
.message .mid .btn_flip > img {width: 100%; max-width: 30px;}



.message .bottom_btns {position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: calc(100% - 40px); max-width: 400px; margin-bottom: 30px;}
.message .bottom_btns button {font-family: 'Sackers Gothic Std', 'Pretendard' ,sans-serif; font-weight: 400;}
.message .bottom_btns a {font-family: 'Sackers Gothic Std', 'Pretendard' ,sans-serif; font-weight: 400;}
.message .bottom_btns.front { display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.message .bottom_btns.front .btn_download_front {width: 70px; height: 70px; aspect-ratio: 1;}
.message .bottom_btns.front .btn_download_front > img {width: 100%;}
.message .bottom_btns.front .btn_to_write {display: block; width: 100%; padding: 25px 0px; text-align: center; color: #648dcd; background-color: #fff; border-radius: 50px; font-size: 20px; line-height: normal;}

.message .bottom_btns.back {display: none;}
.message .bottom_btns.back .btn_done {display: block; width: 100%; max-width: 200px; margin: 0 auto; padding: 16px 0px; text-align: center; color: #648dcd; background-color: #fff; border-radius: 50px; font-size: 24px;}

.message .bottom_btns.share { opacity: 0; visibility: hidden; pointer-events: none; display: flex; justify-content: space-between; align-items: center; gap: 15px; transition: all 0.3s;}
.message .bottom_btns.share.on {opacity: 1; visibility: visible; pointer-events: all;}
.message .bottom_btns.share > button {display: block; width: 100%; padding: 18px 0;  border-radius: 50px; font-size: 22px; text-align: center;}
.message .bottom_btns.share .btn_save {color: #648dcd; background-color: #fff;}
.message .bottom_btns.share .btn_share {color: #fff; background-color: #648dcd; }





@media screen and (max-width: 767px) {

    #userText { font-size: 14px; line-height: 2.4;}
    #userText.GmarketSans {  font-size: 16px; line-height: 2.3;}
    #userText.AritaDotumKR { font-size: 18px; line-height: 1.9; }
    #userText.Continuous { font-size: 18px; line-height: 1.9; }
    #userText.THEFACESHOP {  font-size: 21px; line-height: 1.6; }
    #userText.SDMiSaeng { font-size: 25px; line-height: 1.3; }



    .message .bottom_btns.front {padding: 0 30px; gap: 10px;}
    .message .bottom_btns.front .btn_download_front {width: 60px; height: 60px;}
    .message .bottom_btns.front .btn_to_write { padding: 23px 0; font-size: 17px;}

    .message .bottom_btns.back .btn_done {padding: 14px 0; font-size: 19px;}

    .message .bottom_btns.share > button {padding: 14px 0; font-size: 19px;}


}

@media screen and (max-width: 450px) {
    .message .mid .card_area.small {margin-top: 10% !important;}
    .message .mid:has(.card_area.small) {padding-top: 5%;}
    .message .mid {padding-top: 0;}

    /* #userText {font-size: 12px;} */

    .message .mid .font_menu > ul li > p {font-size: 13px;}

    .message .bottom_btns {margin-bottom: 10px;}
    .message .bottom_btns.front {padding: 0 20px;}
    .message .bottom_btns.front .btn_download_front {width: 50px; height: 50px;}
    .message .bottom_btns.front .btn_to_write { padding: 15px 0; font-size: 15px;}
    .message .bottom_btns.back .btn_done {padding: 10px 0; font-size: 15px;}

    .message .bottom_btns.share > button {padding: 12px 0; font-size: 17px;}

}

@media screen and (max-width: 420px) {
    /* .message .mid .card_area {margin-top: -50px;} */
    .message .mid .card_back .text_area {padding: 17% 4%;}
    #userText {font-size: 12px;}
    #userText.GmarketSans {  font-size: 13px; line-height: 2.3;}
    #userText.AritaDotumKR { font-size: 15px; line-height: 1.9;}
    #userText.Continuous { font-size: 15px; line-height: 1.9;}
    #userText.THEFACESHOP { font-size: 18px; line-height: 1.6;}
    #userText.SDMiSaeng { font-size: 22px; line-height: 1.3;}


}

@media screen and (max-width: 370px) {
    /* #userText {font-size: 11px;} */
    #userText {font-size: 10px;}
    #userText.GmarketSans {  font-size: 12px; line-height: 2.3;}
    #userText.AritaDotumKR { font-size: 15px; line-height: 2;}
    #userText.Continuous { font-size: 13px; line-height: 1.8; letter-spacing: normal;}
    #userText.THEFACESHOP { font-size: 15px; line-height: 1.6;}
    #userText.SDMiSaeng { font-size: 18px; line-height: 1.3;}

}


/* 공유하기 */
.inner_popup.send {position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; opacity: 0; pointer-events: none; transition: opacity .3s; z-index: 10;}
.inner_popup.send .bg {position: fixed; top: 0; left: 0; width: 100%; height: 100dvh; background: rgba(0, 0, 0, 0.50);  opacity: 0; pointer-events: none; transition: opacity .3s;}
.inner_popup.send .inner { display: none; position: fixed; top: 70%; left: 50%; transform: translate(-50%, -50%); width: calc(90% - 50px); max-width: 400px; height: auto; padding: 0; padding-bottom: 15px; border-radius: 25px; background: #e0e0e0; filter: drop-shadow(0px 0px 10px rgba(0, 0, 0, 0.5)); }
.inner_popup.send .inner .top { position: relative; display: flex; align-items: center; justify-content: center; height: 68px;}
.inner_popup.send .inner .top strong {color: #648dcd; font-size: 20px; font-weight: 500;}
.inner_popup.send .inner .top .btn_close { position: absolute; top: 50%; right: 35px; transform: translateY(-50%); width: 34px; height: 34px; background: url(/images/btn_close1.png) no-repeat center center / 18px auto; }
.inner_popup.send .inner .sendSns {display: flex; align-items: center; justify-content: center; margin: 35px auto 45px; gap: 24px;}
.inner_popup.send .inner .sendSns button {width: 72px; height: 72px; background-repeat: no-repeat; background-position: center center; background-size: 100% 100%;}
.inner_popup.send .inner .sendSns button.facebook {background-image: url(/images/logo_facebook.png) ;}
.inner_popup.send .inner .sendSns button.btn_url {background-image: url(/images/icon_url.png) ;}
.inner_popup.send .inner .sendSns button.kakao {background-image: url(/images/logo_kakao.png) ;}
.inner_popup.send .inner .sendSns button.shareBtn {background-image: url(/images/logo_shareBtn.png) ;}
.inner_popup.send .inner .clip {display: flex; align-items: center; width: calc(100% - 60px); max-width: 326px; height: 46px; padding: 6px 0; margin: auto; border: 1px solid #bacdeb; border-radius: 12px; background: #f2f2f2;}
.inner_popup.send .inner .clip input { font-family: 'NotoSansCJK', sans-serif; flex-grow: 1; width: 100%; height: 100%; padding: 0 10px; font-size: 12px; font-weight: 300; color: #4d4d4d;}
.inner_popup.send .inner .clip .clipBtn {width: 78px; height: 100%; margin-right: 8px; background-color: #648dcd; border-radius: 30px; font-family: 'NotoSansCJK', sans-serif; font-size:13px ; color: #fff;}
.inner_popup.send .inner .caption { display: block; margin-top: 6px; color: #9A9A9A; text-align: center; font-size: 14px; line-height: 180%; font-family: "pretendard" , sans-serif;}

.inner_popup.send.on,
.inner_popup.send.on .bg { opacity: 1; pointer-events: all;}
.inner_popup.send.on .inner {display: block;}

.tostPop {position: fixed; bottom: 50px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; justify-content: center; min-height: 50px; padding: 10px 35px; color: #FFF; text-align: center; font-family: 'Pretendard' , sans-serif; font-size: 16px; font-weight: 400; border-radius: 12px; word-break: keep-all; background: rgba(0, 0, 0, 0.46); opacity: 0; pointer-events: none; transition: .3s; z-index: 50;}
.tostPop.on { opacity: 1; bottom: 100px;}



@media screen and (max-width: 768px) {
    .inner_popup.send .inner {}
    .inner_popup.send .inner .top {height: 52px;}
    .inner_popup.send .inner .top strong {font-size: 18px;}
    .inner_popup.send .inner .top .btn_close {right: 15px;}
    .inner_popup.send .inner .sendSns { margin: 15px auto 25px; gap: 26px;}
    .inner_popup.send .inner .sendSns button {width: 60px; height: 60px;}
    .inner_popup.send .inner .clip {width: calc(100% - 48px); height: 42px;}
    .inner_popup.send .inner .clip .clipBtn {width: 60px;}
    .inner_popup.send .inner .caption {font-size: 12px;}

    .inner_popup.send .inner .sendSns a {width: 50px; height: 50px;}
    .inner_popup.send .inner .sendSns a img {width: 50px; height: 50px;}

}



/* 전체 스케일 관리 반응형 ----------------------------------------------------------- */


/* ========================================
   1. 데스크톱 (768px 이상)
======================================== */

/* 데스크톱 - 높이 부족 (800px ~ 1170px) */
@media screen and (min-width: 768px) and (min-height: 801px) and (max-height: 1181px) {
    .popup .card_wrap {max-height: 580px;}
    .popup .card_wrap:has(.card.small) {margin-top: -15px !important;}


    :root {
        --card-scale-default: 0.6;
        --card-scale-semi-small: 0.55;
        --card-scale-small: 0.45;
        --card-scale-message-default: 0.7;
        --card-scale-message-small: 0.6;
    }

    .message .mid .card_area {margin-top: -7vh;}

    .fixed_menu.direction > .inner {gap: 20px;}
    .fixed_menu.direction .btn_to {width: 110px; height: 110px;}
    .fixed_menu .body_wrap {height: 15vh;}

    .fixed_menu .item_list {row-gap: 15px; column-gap: 15px; grid-template-columns: repeat(auto-fit, 80px);}
    .fixed_menu .item_list > li {max-width: 80px;}
}

/* 데스크톱 - 높이 매우 부족 (800px 이하) */
@media screen and (min-width: 768px) and (max-height: 800px) {
    .popup .step_title {padding-top: 0;}
    .popup .card_wrap {max-height: 485px;}
    .popup .card_wrap:has(.card.small) {margin-top: -0px !important;}


    :root {
        --card-scale-default: 0.5;
        --card-scale-semi-small: 0.45;
        --card-scale-small: 0.4;
        --card-scale-message-default: 0.6;
        --card-scale-message-small: 0.5;
    }

    .message .mid .card_area.small {
        margin-top: -5%;
        --card-scale-message-default: 0.7;
        --card-scale-message-small: 0.7;
    }

    .message .mid .card_area {margin-top: -25%;}
    .message .bottom_btns {margin-bottom: 15px;}
    .message .bottom_btns.front .btn_download_front {width: 60px; height: 60px;}
    .message .bottom_btns.front .btn_to_write {padding: 20px 0 ; font-size: 18px;}
    .message .bottom_btns.back .btn_done {padding: 14px 0; font-size: 22px;}
    .message .bottom_btns.share > button {padding: 15px 0; font-size: 20px;}
    .fixed_menu .body_wrap {height: 13vh;}

    .fixed_menu.direction {margin-bottom: 20px;}
    .fixed_menu.direction > .inner {gap: 15px;}
    .fixed_menu.direction .btn_to {width: 100px; height: 100px;}

    .fixed_menu .item_list {row-gap: 10px; column-gap: 15px; grid-template-columns: repeat(auto-fit, 80px);}
    .fixed_menu .item_list > li {max-width: 80px;}
}


/* ========================================
   2. 모바일/태블릿 (767px 이하)
======================================== */

/* 모바일/태블릿 공통 스타일 */
@media screen and (max-width: 767px) {
    .popup .step_title {font-size: 15px; padding-top: 20px;}
    .popup > .inner {padding-top: 20px;}
    .popup .top_btns {padding: 0 25px;}
    .popup .slide_btn.next {right: 9px; max-width: 15px;}
    .popup .slide_btn.prev {left: 9px; max-width: 15px;}

    :root {
        --card-scale-message-default: 0.9;
        --card-scale-message-small: 0.85;
    }
}

/* 모바일 - 작은 화면 (380px 이하) */
@media screen and (max-width: 380px) {
    .popup > .inner {padding-top: 20px;}
    .popup .top_btns {padding: 0 20px;}
    .popup .backBtn {width: 50px; height: 50px;}
    .popup .nextBtn {font-size: 18px;}
    .popup .step_title {padding-top: 14px; font-size: 13px;}
    .popup .card_wrap {margin-top: 20px; height: 125vw;}
}


/* ========================================
   3. 모바일 높이별 설정 (767px 이하)
======================================== */

/* 모바일 - 높이 매우 충분 (800px 이상) */
@media screen and (max-width: 767px) and (min-height: 800px) {
    :root {
        --card-scale-default: 0.8;
        --card-scale-semi-small: 0.77;
        --card-scale-small: 0.67;
    }

    .popup > .inner {padding-top: 20px;}
    .popup .card_wrap {margin-top: 30px; height: 143vw;}
    .popup .card_wrap:has(.card.small) {margin-top: -0px !important;}

}

/* 모바일 - 높이 충분 (750px ~ 799px) */
@media screen and (max-width: 767px) and (min-height: 750px) and (max-height: 799px) {
    :root {
        --card-scale-default: 0.71;
        --card-scale-semi-small: 0.66;
        --card-scale-small: 0.6;
        --card-scale-message-default: 0.85;
        --card-scale-message-small: 0.75;
    }

    .popup > .inner {padding-top: 20px;}
    .popup .card_wrap {margin-top: 25px; height: 143vw;}
    .popup .card_wrap:has(.card.small) {margin-top: -0px !important;}


    .message .mid .card_area {margin-top: -1vh;}
}

/* 모바일 - 높이 보통 (700px ~ 749px) */
@media screen and (max-width: 767px) and (min-height: 700px) and (max-height: 749px) {
    :root {
        --card-scale-default: 0.63;
        --card-scale-semi-small: 0.57;
        --card-scale-small: 0.5;
        --card-scale-message-default: 0.85;
        --card-scale-message-small: 0.75;
    }


    .popup > .inner {padding-top: 20px;}
    .popup .card_wrap {margin-top: 30px;}
    .popup .card_wrap:has(.card.small) {margin-top: 5px !important;}


    .message .mid .card_area {margin-top: -1vh;}
}

/* 모바일 - 높이 부족 (650px ~ 699px) */
@media screen and (max-width: 767px) and (min-height: 650px) and (max-height: 699px) {
    :root {
        --card-scale-default: 0.63;
        --card-scale-semi-small: 0.6;
        --card-scale-small: 0.5;
        --card-scale-message-default: 0.85;
        --card-scale-message-small: 0.75;
    }

    .popup > .inner {padding-top: 20px;}
    .popup .card_wrap {margin-top: 20px; height: 110vw;}

    .message .mid .card_area {margin-top: -3vh;}
}

/* 모바일 - 높이 매우 부족 (600px ~ 649px) */
@media screen and (max-width: 767px) and (min-height: 600px) and (max-height: 649px) {
    :root {
        --card-scale-default: 0.56;
        --card-scale-semi-small: 0.53;
        --card-scale-small: 0.47;
        --card-scale-message-default: 0.85;
        --card-scale-message-small: 0.75;
    }

    .popup > .inner {padding-top: 20px;}
    .popup .card_wrap {margin-top: 20px; height: 110vw;}
    .message .mid .card_area {margin-top: -3vh;}
}

/* 모바일 - 높이 극도로 부족 (599px 이하) */
@media screen and (max-width: 767px) and (max-height: 599px) {
    :root {
        --card-scale-default: 0.53;
        --card-scale-semi-small: 0.5;
        --card-scale-small: 0.45;
        --card-scale-message-default: 0.85;
        --card-scale-message-small: 0.75;
    }

    .popup > .inner {padding-top: 15px;}
    .popup .card_wrap {margin-top: 20px; height: 110vw;}
    .message .mid .card_area {margin-top: -3vh;}
}


/* ========================================
   4. Aspect Ratio 기반 스크롤 처리
======================================== */

/* 정사각형에 가까운 화면 (태블릿 등) */
@media (min-aspect-ratio: 3/4) and (max-aspect-ratio: 4/3) {
    .popup.on:not(.openCardPop) > .inner {
        overflow-y: auto;
        padding-bottom: 13dvh;
    }

    .message .mid .card_area.small {
        margin-top: -5%;
        --card-scale-message-default: 0.8;
        --card-scale-message-small: 0.8;
    }
}

/* 와이드 화면이지만 높이가 부족한 경우 (노트북, 울트라와이드 등) */
@media (min-aspect-ratio: 17/10) and (max-height: 700px) {
    .popup.on:not(.openCardPop) > .inner {
        overflow-y: auto;
        padding-bottom: 13dvh;
    }
}

@media (min-width: 1600px) and (max-height: 900px) {
    .popup.on:not(.openCardPop) > .inner {
        overflow-y: auto;
        padding-bottom: 17dvh;
    }
}

/* 전체 스케일 관리 반응형 end ----------------------------------------------------------- */






/* 카드 열어보기 페이지 */
.openCardPop .mid { position: relative; height: auto; width: 100%; max-width: 500px; margin: 0 auto; padding-top: 100px; }
.openCardPop .touch_balloon { display: none; position: absolute; top: 0%; left: 50%; transform: translateX(-50%); width: 140px; height: 64px; background: url(/images/touch_balloon.png) no-repeat 100% / 100%; text-align: center; animation: floatingBalloon 2s ease-in-out 3; }
.openCardPop .touch_balloon > span {font-size: 20px; color: #648dcd; line-height: 2.5;}


@keyframes floatingBalloon {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(15px);
    }
}

.openCardPop > .inner { display: flex; justify-content: center; align-items: center; padding-top: 0; padding-bottom: 10dvh;}
.openCardPop .mid .card_area {position: relative; width: 100%; height: fit-content; perspective: 1000px; transition: all 0.4s;}
.openCardPop .mid .card_area .card_inner { position: relative; width: calc(100% - 70px); height: fit-content; margin: 0 auto; transition: transform 0.8s; transform-style: preserve-3d; cursor: pointer;}
.openCardPop .mid .shadow_wrap {filter: drop-shadow(0px 0px 30px rgba(255, 255, 255, 0.7)); scale: 0.9; transition: all 0.3s;}
.openCardPop .mid .card_area .card_front { width: 100%; height: fit-content; border-radius: 10px; overflow: hidden;}
.openCardPop .mid .card_area .card_front > img {width: 100%; height: auto;}

.openCardPop .mid .card_area .card_back { position: absolute; left: 0; top: 0; transform: rotateY(180deg); backface-visibility: hidden; width: 100%; height: fit-content; border-radius: 10px; overflow: hidden;}
.openCardPop .mid .card_area .card_back > img {width: 100%; height: auto;}

.openCardPop .mid .card_area.flipped .card_inner { transform: rotateY(180deg); }

.openCardPop .bottom_btns {position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); margin: 0 auto; padding-top: 40px; width: calc(100% - 40px); max-width: 400px; margin-bottom: 30px;}
.openCardPop .bottom_btns button {font-family: 'Sackers Gothic Std', 'Pretendard' ,sans-serif; font-weight: 400;}
.openCardPop .bottom_btns a {font-family: 'Sackers Gothic Std', 'Pretendard' ,sans-serif; font-weight: 400;}

.openCardPop .bottom_btns.open { opacity: 0; visibility: hidden; pointer-events: none; display: flex; justify-content: space-between; align-items: center; gap: 15px; transition: all 0.3s;}
.openCardPop .bottom_btns.open.on { opacity: 1; visibility: visible; pointer-events: all; }
.openCardPop .bottom_btns.open .btn_download_all {width: 70px; height: 70px; aspect-ratio: 1;}
.openCardPop .bottom_btns.open .btn_download_all > img {width: 100%;}
.openCardPop .bottom_btns.open .btn_reply {display: block; width: 100%; padding: 16px 0px; text-align: center; color: #fff; background-color: #648dcd; border-radius: 50px; font-size: 24px;}


.inner_popup.open_intro {}
.inner_popup.open_intro.loading {}
.inner_popup.open_intro.loading > .bg {background: rgba(255, 255, 255, 1);}
.inner_popup.open_intro > .bg {background: rgba(255, 255, 255, 0.35); transition: background 0.6s, opacity 0.6s;}
.inner_popup.open_intro > .inner {width: 100%; max-width: 900px; height: 900px; padding: 0; border-radius: 0; background-color: transparent; transition: opacity 0.6s;}
.inner_popup.open_intro .txt_box { height: 100%; display: flex; flex-direction: column; justify-content: center; text-align: center; background: url(/images/open_intro_blur.png) no-repeat center / 800px; transition: opacity 1s;}
.inner_popup.open_intro .txt_box > p { opacity: 0; padding: 0 20px; margin-bottom: 40px; color: #29476c; font-family: 'Pretendard', sans-serif; font-weight: 500; font-size: 32px; line-height: 1.5; transition: opacity 0.8s ease-in-out;}
.inner_popup.open_intro .txt_box .btn_open { opacity: 0; display: block; width: 100%; max-width: 210px; margin: 0 auto; padding: 14px 0px; text-align: center; color: #fff; background-color: #648dcd; border-radius: 50px; font-size: 20px; font-family: 'Pretendard', sans-serif; font-weight: 400; transition: opacity 0.8s ease-in-out;}

body:has(.open_intro.on) .openCardPop.on > .bg {background: transparent;}

.inner_popup.open_intro .txt_box > p.fade-in { opacity: 1; }
.inner_popup.open_intro .txt_box > p.fade-out { opacity: 0; }

@media screen and (max-height: 1000px) {

    .openCardPop .mid {max-width: 400px;}
}

@media screen and (min-width: 1024px) and (max-height: 800px) {
    .openCardPop .mid {padding-top: 70px}
    .openCardPop .touch_balloon {width: 100px; height: 44px;}
    .openCardPop .touch_balloon > span {font-size: 14px; line-height: 36px;}

    .openCardPop .mid {max-width: 350px;}
    .openCardPop .mid .card_area .card_inner {width: calc(100% - 80px);}
}
@media screen and (min-width: 1024px) {
    .inner_popup.open_intro > .inner {max-width: 1100px;}
    .inner_popup.open_intro .txt_box {background-size: 1100px;}
}

@media screen and (min-width: 500px) and (max-height: 800px) {
    .openCardPop.on > .inner {overflow-y: auto;}

}




@media screen and (max-width: 430px) {
    .inner_popup.open_intro .txt_box > p {font-size: 26px;}

}

@media screen and (max-width: 430px) {
    .openCardPop .mid {padding-top: 70px}
    .openCardPop .touch_balloon {width: 100px; height: 44px;}
    .openCardPop .touch_balloon > span {font-size: 14px; line-height: 36px;}
    .openCardPop .mid .card_area .card_inner {width: calc(100% - 90px);}

    .openCardPop .bottom_btns {width: calc(100% - 60px); padding-top: 2vh; margin-bottom: 2dvh;}
    .openCardPop .bottom_btns.open .btn_download_all {width: 50px; height: 50px;}
    .openCardPop .bottom_btns.open .btn_reply {padding: 10px 0; font-size: 19px;}


}

@media screen and (max-width: 429px) {
    .inner_popup.open_intro .txt_box > p {font-size: 22px;}
    .inner_popup.open_intro .txt_box .btn_open {width: 190px; padding: 12px 0; font-size: 18px;}
    .openCardPop .mid .card_area .card_inner {width: calc(100% - 120px);}
}

@media screen and (max-width: 400px) {
    .inner_popup.open_intro .txt_box > p {font-size: 20px;}
    .inner_popup.open_intro .txt_box .btn_open {width: 180px; padding: 11px 0; font-size: 17px;}
    .openCardPop .mid .card_area .card_inner {width: calc(100% - 115px);}
}

@media screen and (max-width: 380px) {
    .openCardPop .mid .card_area .card_inner {width: calc(100% - 120px);}
}





