
body:has(.popup.on) { overflow: hidden; }

header {position: fixed; inset: 0; z-index: 9; width: 100%; height: 45px; background-color: #fff;}
header .inner { display: flex; align-items: center; justify-content: space-between; width: 100%; height: 100%; padding-inline: 9px;}
header .btn_back { display: block; width: 32px; aspect-ratio: 1; background: url(/img/icon_back.svg) no-repeat center / contain;}
header .logo { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 121px;}
header .logo img {width: 100%;}

footer {position: fixed; bottom: 0; z-index: 9; width: 100%; height: 67px; background-color: #fff; border-top: 1px solid #EDEDED;}
footer .inner { width: 100%; max-width: 430px; margin-inline: auto; height: 100%; padding: 11px 0 12px;}
footer .inner .menu_list { display: flex; align-items: center; justify-content: space-between; height: 100%;}
footer .inner .menu_list li { width: calc(100% / 3); text-align: center;}
footer .inner .menu_list i { display: block; margin-bottom: -2px; width: 30px; aspect-ratio: 1; margin-inline: auto; }
footer .inner .menu_list img { width: 100%;}
footer .inner .menu_list span { color: #603813; font-family: "Pretendard", sans-serif; font-size: 12px; font-weight: 400; line-height: 140%; letter-spacing: -0.12px; }

/* 팝업 */
.popup {position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; z-index: 100;}
.popup .close-btn { z-index: 2; position: absolute; top: 28px; right: 30px; display: block; width: 24px; aspect-ratio: 1; background: url(/img/close_x.svg) no-repeat center / contain;}
.popup > .bg { position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: rgba(0, 0, 0, 0.2); z-index: 110; transition: .3s ease-out; opacity: 0; pointer-events: none; }
.popup > .inner { position: fixed; overflow: hidden; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 90%; min-width: 300px; max-width: 500px; height: auto; max-height: 90dvh; opacity: 0; pointer-events: none; background-color: #fff; transition: .3s ease-in-out; z-index: 150; border-radius: 15px; background: #FFF; }
.popup.on > .bg ,
.popup.on > .inner {opacity: 1; pointer-events: auto;}

.wrap {display: flex; flex-direction: column; background: #F9F4E9; height: calc(100dvh - 67px); overflow-y: auto;}
.wrap .btn { display: flex; justify-content: center; align-items: center; width: calc(100% - 40px); max-width: 375px; height: 56px; border-radius: 12px; font-family: "VITRO CORE TTF", sans-serif;}
.wrap .btn * { font-family: "VITRO CORE TTF", sans-serif; }
.wrap .btn.red { color: #fff; background: #D81A22; box-shadow: 0 6px 0 0 #821E10; margin-bottom: 6px; }
.wrap .btn.light { border: 1px solid #000; background: #F9F4E9; box-shadow: 0 6px 0 0 #3B2314; color: #603813; margin-bottom: 6px; }
.wrap .btn.link em {display: inline-block; margin-left: 5px; width: 20px; aspect-ratio: 1; background: url(/img/icon_new_window.svg) no-repeat center / contain;}


.wrap.main { }
.wrap.main .kv { width: 100%; max-width: 460px; margin-inline: auto;}
.wrap.main .kv img {width: 100%;}

.wrap.main .sec_steps {position: relative; width: calc(100% - 40px); max-width: 460px; margin-inline: auto; margin-top: 108px;}
.wrap.main .sec_steps .top_box { position: absolute; top: -20px; left: 50%; transform: translate(-50%, -100%); width: calc(100% - 20px); max-width: 354px; padding: 19px 0 15px; text-align: center; border-radius: 12px; background: #603813; box-shadow: 0 3px 0 0 rgba(220, 181, 134, 0.30); }
.wrap.main .sec_steps .top_box .txt { color: #FFF2DF; font-size: 20px; font-weight: 700; line-height: 130%; }
.wrap.main .sec_steps .top_box .date { margin-top: 8px; color: #FFE9AD; font-family: "VITRO CORE TTF", sans-serif; font-size: 17px; font-weight: 900; line-height: 160%; }

.wrap.main .steps_wrap { border-radius: 12px; background: #FFF; margin-bottom: 16px;}
.wrap.main .step_list {position: relative; display: flex; flex-wrap: wrap; padding: 8px 5px;}
.wrap.main .step_list::after { content: ''; display: block; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: calc(100% - 74px); height: 1px; background-color: rgba(246, 146, 39, 0.30);}
.wrap.main .step_list::before { content: ''; display: block; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) rotate(90deg); width: calc(100% - 80px); height: 1px; background-color: rgba(246, 146, 39, 0.30);}
.wrap.main .step_list li { display: flex; justify-content: center; align-items: center; flex-direction: column; row-gap: 10px; width: calc(100% / 2); aspect-ratio: 1; text-align: center;}
.wrap.main .step_list li > span { color: #F69227; font-family: "VITRO CORE TTF", sans-serif; font-size: 14px; font-weight: 900; line-height: 140%; }
.wrap.main .step_list li .img_box {width: 100%; max-width: 80px; aspect-ratio: 1; }
.wrap.main .step_list li .img_box img {width: 100%; height: 100%; object-fit: contain;}
.wrap.main .step_list li > p { color: #000; font-size: 16px; font-weight: 500; line-height: 130%; letter-spacing: -0.02em; }
.wrap.main .steps_wrap .txt_box {text-align: center; border-top: 1px solid #F69227; padding: 18px 0;}
.wrap.main .steps_wrap .txt_box p { position: relative; width: fit-content; margin-inline: auto; color: #603813; font-family: "VITRO CORE TTF", sans-serif; font-size: 24px; font-weight: 900; line-height: 130%; }
.wrap.main .steps_wrap .txt_box p::after { content: ''; position: absolute; top: -6px; right: -13px; display: block; width: 17px; aspect-ratio: 17 / 16; background: url(/img/txt_extra.png) no-repeat center / contain; }

.wrap.main .sec_steps .btn_wrap .btn { width: 100%; margin-inline: auto;}
.wrap.main .sec_steps .btn_wrap .btn.red {font-size: 22px;}
.wrap.main .sec_steps .btn_wrap .btn.link {font-size: 18px;}
.wrap.main .sec_steps .btn_wrap .btn + .btn {margin-top: 16px;}


.wrap.main .sec_gift {padding-top: 23px; padding-bottom: 43px; width: calc(100% - 40px); max-width: 460px; margin-inline: auto; }
.wrap.main .sec_gift .ti_area {padding: 23px 0; text-align: center;}
.wrap.main .sec_gift .ti_area span { position: relative; color: #3B2314; font-family: "VITRO CORE TTF", sans-serif; font-size: 22px; font-weight: 900; line-height: normal; }
.wrap.main .sec_gift .ti_area span::before { content: ''; display: block; position: absolute; top: 50%; left: -123%; transform: translateY(-50%); width: 94px; height: 3px; background: #A87C4F; box-shadow: 2.4px 2.4px 0 0 rgba(96, 56, 19, 0.30);}
.wrap.main .sec_gift .ti_area span::after { content: ''; display: block; position: absolute; top: 50%; right: -123%; transform: translateY(-50%); width: 94px; height: 3px; background: #A87C4F; box-shadow: 2.4px 2.4px 0 0 rgba(96, 56, 19, 0.30);}


.wrap.main .gift_list {text-align: center;}
.wrap.main .gift_list li { width: 100%; padding: 22px 27px 30px; border-radius: 12px; background: #FFF; box-shadow: 0 3px 0 0 rgba(220, 181, 134, 0.30); }
.wrap.main .gift_list li + li {margin-top: 17px;}

.wrap.main .gift_list li > span { display: inline-block; padding: 6px 10px; color: #3B2314; font-family: "VITRO CORE TTF", sans-serif; font-size: 18px; font-weight: 900; border-radius: 100px; border: 1px solid #000; }
.wrap.main .gift_list li .name { margin-top: 12px; color: #000; font-size: 20px; font-weight: 700; line-height: 140%; }
.wrap.main .gift_list li .img_box { position: relative; margin-top: 12px;}
.wrap.main .gift_list li .img_box img { width: 100%; border-radius: 6px;}
.wrap.main .gift_list li > .cap { margin-top: 19px; color: #000; font-size: 15px; font-weight: 400; line-height: 130%; }


.wrap.main .gift_list li .img_box::after { content: ''; display: block; position: absolute; left: 0; bottom: -7px; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.25));} 

.wrap.main .gift_list li.first .img_box::after { width: 140px; height: 109px; left: -16px; bottom: -19px; background: url(/img/gift_extra_01.png) no-repeat center / contain;} 
.wrap.main .gift_list li.second .img_box::after  { width: 113px; height: 71px; left: 7px; background: url(/img/gift_extra_02.png) no-repeat center / contain;}
.wrap.main .gift_list li.third .img_box::after { width: 113px; height: 71px; left: 7px;  background: url(/img/gift_extra_03.png) no-repeat center / contain;}
.wrap.main .terms ~ .warning_cap { padding-bottom: 30px; background-color: #fff;}



.wrap .store_count_area {text-align: center; padding: 24px 0; background: #F5B335;}
.wrap .store_count_area .flex_box { display: flex; justify-content: center; align-items: center; column-gap: 8px; padding-top: 11px;}
.wrap .store_count_area .flex_box > p { color: #38230F; font-size: 16px; font-weight: 500; line-height: 130%; }
.wrap .store_count_area .flex_box > p span { color: #38230F; font-weight: 500; line-height: 130%; }
.wrap .store_count_area .flex_box > em { font-style: normal;}
.wrap .store_count_area > .ti { color: #4E2C0C; font-family: "VITRO CORE TTF", sans-serif; font-size: 24px; font-weight: 900; line-height: 140%; }
.wrap .store_count_area > .ti span { color: #FFF; font-family: "VITRO CORE TTF", sans-serif; font-weight: 900; line-height: 140%; }
.wrap .store_count_area .cap { padding-top: 6px; color: #38230F; font-size: 14px; font-weight: 300; line-height: 130%; }

.terms { width: 100%; margin-inline: auto; padding: 46px 27px; background-color: #fff;}
.terms * {font-family: "Noto Sans KR", sans-serif;}
.terms ul { width: 100%; max-width: 460px; margin-inline: auto; }
.terms ul + ul {margin-top: 40px;}
.terms ul li + li {margin-top: 0.3em;}
.terms ul li { word-break: keep-all; text-indent: -0.5em; padding-left: 0.5em; color: #603813; font-size: 14px; font-style: normal; font-weight: 400; line-height: 140%; letter-spacing: -0.03em; }
.terms ul li.head { margin-bottom: 10px; font-size: 17px; line-height: 1.1; font-weight: 500; letter-spacing: -0.025em; }

.wrap .warning_cap p { text-align: center; color: #603813; font-size: 14px; font-weight: 400; line-height: 140%; } 


.play {padding-top: 25px;}
.play .sec_game { position: relative; width: 100%; max-width: 460px; min-height: 500px; background: url(/img/game_bg.jpg) repeat top center / 450px; margin-inline: auto; overflow: hidden; z-index: 8; }
.play .sec_game .top_area {position: absolute; top: 40px; left: 0; width: 100%; padding-inline: 22px;}
.play .sec_game .top_area .mini_banner {width: 226px;}
.play .sec_game .top_area p { margin-top: 8px; color: #FFE9AD; font-family: "VITRO CORE TTF", sans-serif; font-size: 16px; font-weight: 900; line-height: 140%; }
.play .sec_game .top_area p span { color: #FFE9AD; font-family: "VITRO CORE TTF", sans-serif; font-size: 18px; font-weight: 900; line-height: 140%; }
.play .sec_game .game_wrap { position: absolute; top: 50%; left: 50%; width: 768px; height: 100%; transform: translate(-50%, -50%); bottom: 40px; z-index: 1; background: url(/img/game_ground.png) no-repeat -7px / 810px; }
.play .sec_game .game_wrap > img { width: 100%; }

.play .sec_game .board_wrap { position: absolute; width: 100%; height: 100%;}
.play .sec_game .board_wrap * {box-sizing: content-box;}
.play .sec_game .board { scale: 1.06; position: relative; width: 700px; aspect-ratio: 1; transform: translate(24px , -21px) rotateX(53deg) rotateZ(-45deg); transform-style: preserve-3d; z-index: 5; }
.play .sec_game .tile { opacity: 0 !important; visibility: hidden !important; position: absolute; width: 43px; aspect-ratio: 1; background-color: #576064; border: 2px solid #fff; background-repeat: no-repeat; background-size: 100%; display: flex; align-items: center; justify-content: center; flex-direction: column; transform-style: preserve-3d; transform: translateZ(1px); }
.play .sec_game .character { position: absolute; width: 68px; aspect-ratio: 68 / 87; background: url(/img/game_main_char.png) no-repeat 100% / 100%; transform: translateX(calc(-50% - 6px)) translateY(calc(-50% - 9px)) translateZ(80px) rotateZ(45deg) rotateX(-45deg); transition: all 0.5s ease; z-index: 100; transform-style: preserve-3d; }




/* 주사위 관련 */
.dice_wrap {position: fixed; top: 0; left: 0; width: 0; height: 0; overflow: hidden; z-index: 10;}
.dice_wrap .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.70);}
.dice_wrap > p {color: #FFF; font-size: 20px; font-weight: 700; letter-spacing: -0.05rem;}
.dice_wrap .dice-container {position: relative; display: none; justify-content: center; gap: 24px; position: fixed; top: 42%; left: 50%; transform: translate(-50%,-50%); width: calc(100% - 32px); max-width: 335px; height: auto;}

.dice_wrap.on .bg {opacity: 1; pointer-events: all;}
.dice_wrap.on .dice-container {display: flex;}

.dice { width: 67px; height: 67px; position: relative; overflow: hidden; border-radius: 18px; box-shadow: 0 4px 8px rgba(0,0,0,0.3); }

.dice-sprite { width: 67px; height: 402px; /* 6개 면 * 67px */ background-image: url(/img/dice_paper.png); background-repeat: repeat-y; background-size: 67px 402px; transition: transform 0.1s ease-out; position: absolute; top: 0; left: 0; }

.dice-sprite.rolling { animation: scroll-down var(--animation-duration) forwards ease-out; }

.bouncing { animation: bounce 0.3s ease-out; }

@keyframes scroll-down {
    0% {
        background-position: 0 0px;
    }
    100% {
        background-position: 0 var(--final-position);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}


.play .sec_bottom { flex: 1; position: relative; z-index: 9; background: #F5B335;}

.play .sec_bottom .btn_wrap { padding-top: 45px;}
.play .sec_bottom .btn.roll_dice { position: absolute; top: -25px; left: 50%; transform: translateX(-50%); font-size: 22px; font-weight: 900; }
.play .sec_bottom .btn.roll_dice > em { display: inline-block; margin-right: 8px; width: 33px; height: 31px; background: url(/img/em_btn_dice.png) no-repeat center / contain; }
.play .sec_bottom .btn.roll_dice > p { margin-left: 6px; color: #FFF; font-family: "Pretendard", sans-serif; font-size: 20px; font-weight: 400; }
.play .sec_bottom .btn.roll_dice > p span { color: #FFF; font-family: "Pretendard", sans-serif; font-weight: 700; }
.play .sec_bottom .btn { margin-inline: auto;}
.play .sec_bottom .btn.link { font-family: "VITRO CORE TTF", sans-serif; font-size: 18px; font-weight: 900; letter-spacing: -0.01em; }

.play .sec_bottom .store_count_area {padding: 30px 0 45px;}








