/*
分類選單 css start
*/

/* 分類選單開啟時, 背景靜止捲動 */
body.lock {
    overflow: hidden;
}

#navbarSideButton {
    color: #fff;
    outline: none;
    cursor: pointer;
}

.navbar-side {
    display: none;
    grid-template-columns: 20% 80%;
    color: #fff;
    font-size: 1.1em;
    letter-spacing: 2px;
    background-color: #fff;
    height: 100%;
    width: 85%;
    position: fixed;
    top: 40px;
    left: -85%;
    list-style: none;
    z-index: 500;
    -webkit-transform: translateX(0%);
    -ms-transform: translateX(0%);
    transform: translateX(0%);
    -webkit-transition: 300ms ease;
    transition: 300ms ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.navbar-side {
    /* header高: 80px, footer高: 63px */
    height: calc(100dvh - 80px - 63px);
    overflow: hidden;
}

/*全站置頂BANNER*/
.navbar-side-lower {
    top: 80px !important;
}

.navbar-side ul {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-content: center;
    height: calc(100% - 40px);
}

.navbar-side ul.main-category-list {
    height: calc(100dvh - 80px - 63px);
    justify-content: start;
    overflow-y: auto;
}

.navbar-side.no-drawer ul.main-category-list {
    height: calc(100dvh - 80px - 22px);
}

.navbar-side li {
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #E2E8F0;
    cursor: pointer;
}

.navbar-side li.main-category-item {
    min-height: 100px;
}

.navbar-side li h1 {
    margin-bottom: 0;
    font-size: 14px;
}

.navbar-side li.active {
    color: var(--primary);
    font-weight: bold;
    background-color: transparent;
    border-left: 2px solid var(--primary);
}

.navbar-side li.active h1 {
    font-weight: bold;
    color: var(--primary);
}

.navbar-side li + li {
    margin-top: 1px;
}

.navbar-side li > a {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--foreground);
    text-wrap: balance;
    text-align: center;
}

.navbar-side .menu-main {
    padding: 6% 5%;
    height: calc(100dvh - 80px - 63px);
    position: relative;
    overflow-y: auto;
}

.navbar-side.no-drawer .menu-main {
    height: calc(100dvh - 80px - 22px);
}

.navbar-side .menu-main .cat-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-gap: 8px;
}

.navbar-side .menu-main .cat-container h2 {
    margin-top: 4px;
    margin-bottom: 0;
    text-align: center;
    font-weight: bold;
    font-size: 14px;
    letter-spacing: 1px;
    line-height: initial;
}

.colorChange {
    color: #EB0045 !important;
}

/* new-hierarchy */
.active-icon {
    color: var(--primary) !important;
}

.navbar-side .menu-main .link-container {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    grid-gap: 8px;
}

.navbar-side .menu-main .link-container a {
    padding: 8px 0;
    border-bottom: 1px solid var(--primary-foreground);
    font-weight: bold;
    letter-spacing: 1px;
}

/* 側邊選單分享icon */
.navbar-side .side-app-link {
    display: inline-block;
}

.navbar-side .side-app-link ul li {
    float: left;
    margin: 7px;
    width: 32px;
    height: 32px;
}

.navbar-side .side-app-link ul li a {
    padding: 0;
}

.navbar-side .side-app-link ul li i {
    position: relative;
    top: inherit;
    left: inherit;
}

.navbar-side .close {
    color: #777;
    position: absolute;
    top: 5px;
    right: 5px;
}

.side-link {
    padding-left: 2rem;
}

.reveal {
    left: 0%;
    z-index: 998;
    top: 80px;
    width: 100%;
    display: grid;
    height: calc(100% - 102px);
}

.reveal.no-drawer {
    top: 40px;
    height: calc(100% - 63px);
}

.reveal.no-drawer {
    top: 40px;
    height: calc(100% - 102px);
}

.navbar-side .menu-main .cat-container .divider-wrap {
    margin: 16px 0;
    padding: 4px 0;
    grid-column: 1 / span 3;
    border-bottom: 1px solid #F1F5F9;
}

.navbar-side .menu-main .cat-container .divider-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
}


/*
分類選單 css end
*/

/* menu 漢堡選單*/
.fixed-footer .goback i.icon-mb-category {
    mask: url('/Images/icons/footer/icon-menu.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-menu.svg') no-repeat center;
    color: #94A3B8;
    background-color: currentColor;
}

.fixed-footer .goback.category-on i.icon-mb-category {
    color: var(--primary);
}

/* MB: 底部導覽列 */
.fixed-footer {
    width: 100%;
    height: 49px;
    font-weight: bold;
    line-height: initial;
    display: flex;
    align-items: center;
    position: fixed;
    bottom: 0;
    background-color: var(--primary-foreground);
    border-top: 1px solid #ddd;
    box-shadow: var(--shadow);
    overflow: hidden;
    z-index: 999;
}

/* 私密社團: 無底部選單 */
#secretCommunity .fixed-footer {
    display: none;
}

/* PC: 登入/註冊&登出 */
@media (min-width: 991px) {
    .fixed-footer,
    .fixed-navbar {
        display: none;
    }

    .reveal {
        display: none;
    }
}

.fixed-footer ul {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    column-gap: 2px;
}

.fixed-footer ul li {
    flex: 1;
    height: 100%;
    color: #94A3B8;
    display: flex;
    justify-content: center;
}

.fixed-footer ul li span,
.fixed-footer ul li a {
    width: auto;
    height: 100%;
    font-weight: 700;
    font-size: 10px;
    color: #94A3B8;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

.fixed-footer ul li a i,
.fixed-footer ul li span i,
.fixed-navbar ul li a i {
    width: 24px;
    height: 24px;
    display: block;
    position: relative;
    /* 設定任務 tooltip 的三顆按鈕 */
    background-size: cover;
    background-repeat: no-repeat;
}

.fixed-footer .home i.home-icon,
.fixed-navbar .home i.home-icon {
    mask: url('/Images/icons/footer/icon-home.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-home.svg') no-repeat center;
    color: #94A3B8;
    background-color: currentColor;
}

.fixed-footer .goback i.store-icon {
    background-image: url(/Images/icons/footer/icon-tab-sell-default.svg);
}

.fixed-footer .task-menu i.task-icon,
.fixed-navbar .task-menu i.task-icon {
    mask: url('/Images/icons/footer/icon-award.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-award.svg') no-repeat center;
    color: #94A3B8;
    background-color: currentColor;
}

.fixed-footer .task-menu.task-on i.task-icon,
.fixed-navbar .task-menu.task-on i.task-icon {
    color: var(--primary);
}

.fixed-footer .coupon-menu i.coupon-icon,
.fixed-navbar .coupon-menu i.coupon-icon {
    background-image: url(/Images/icons/footer/icon-tab-coupon-default.svg);
}

.fixed-footer .coupon-menu.coupon-on i.coupon-icon,
.fixed-navbar .coupon-menu.coupon-on i.coupon-icon {
    background-image: url(/Images/icons/footer/icon-tab-coupon-select.svg);
}

.fixed-footer .chat i.chat-icon,
.fixed-navbar .chat i.chat-icon {
    mask: url('/Images/icons/footer/icon-chat-bubble.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-chat-bubble.svg') no-repeat center;
    color: #94A3B8;
    background-color: currentColor;
}

.fixed-footer .member i.member-icon,
.fixed-navbar .member i.member-icon {
    mask: url('/Images/icons/footer/icon-clipboard.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-clipboard.svg') no-repeat center;
    color: #94A3B8;
    background-color: currentColor;
}

/* MB: 底部導覽列 */
.fixed-footer .member i.member-icon {
    mask: url('/Images/icons/footer/icon-user.svg') no-repeat center;
    -webkit-mask: url('/Images/icons/footer/icon-user.svg') no-repeat center;
    color: #94A3B8;
    background-color: #94A3B8;
}

.fixed-navbar .member.order-on i.member-icon {
    color: var(--primary)
}

.fixed-footer .member.member-on i.member-icon {
    background-color: var(--primary)
}


/* footer active */
.fixed-footer .home.home-on a,
.fixed-footer .goback.category-on a,
.fixed-footer .chat.chat-on a,
.fixed-footer .member.member-on a,
.fixed-footer .task-menu.task-on a,
.fixed-footer .home.home-on span,
.fixed-footer .chat.chat-on span,
.fixed-footer .member.member-on span {
    color: var(--primary);
}

.fixed-footer .home.home-on i.home-icon,
.fixed-navbar .home.home-on i.home-icon {
    color: var(--primary);
}

.fixed-footer .goback.store-on i.store-icon {
    background-image: url(/Images/icons/footer/icon-tab-sell-select.svg);
}

.fixed-footer .coupon-menu.coupon-on i.coupon-icon {
    background-image: url(/Images/icons/footer/icon-tab-coupon-select.svg);
}

.fixed-footer .chat.chat-on i.chat-icon,
.fixed-navbar .chat.chat-on i.chat-icon {
    color: var(--primary);
}

.fixed-footer .member.member-on i.member-icon,
.fixed-navbar .member.member-on i.member-icon {
    background-image: url(/Images/icons/footer/icon-tab-profile-select.svg);
}

/* 任務新增圖示  */
.fixed-footer .mytask i.signBook-icon,
.fixed-navbar .mytask i.signBook-icon {
    background-image: url(/Images/icons/footer/icons-tab-sign.webp?v=1.0);
}

.fixed-footer .mytask i.couponCenters-icon,
.fixed-navbar .mytask i.couponCenters-icon {
    background-image: url(/Images/icons/footer/icons-tab-coupon.webp?v=1.0);
}

.fixed-footer .mytask i.playground-icon,
.fixed-navbar .mytask i.playground-icon {
    background-image: url(/Images/icons/footer/icon-tab-playground.png);
}

.fixed-footer .mytask i.close-icon,
.fixed-navbar .mytask i.close-icon {
    background-image: url(/Images/icons/footer/icon-tab-close.png);
    top: 50%;
    left: 105%;
    transform: translateY(-50%);
    position: absolute;
    width: 20px;
    height: 20px;
    background-size: 20px 20px;
    -webkit-transition: 300ms ease-out;
    transition: 300ms ease-out;
}

.fixed-footer .mytask {
    padding: 0 15px;
    border-radius: 100px;
    background-color: #fff;
    width: 248px;
    height: 80px;
    position: fixed;
    bottom: 71px;
    left: 50%;
    transform: translateY(5px)translateX(-50%);
    border: 1px solid #F2F2F2;
    box-shadow: 0px 2px 8px -4px rgba(0, 0, 0, 0.25);
    -webkit-transition: 300ms ease-out;
    transition: 300ms ease-out;
}

.fixed-footer .mytask.show {
    transform: translateY(0px) translateX(-50%);
}

.fixed-footer .mytask.show::before {
    transform: translateY(0px) translateX(-50%);
}

.fixed-footer .mytask::before {
    content: "";
    position: absolute;
    left: 50%;
    transform: translateY(5px)translateX(-50%);
    bottom: -9px;
    z-index: 111;
    width: 0;
    height: 0;
    text-align: center;
    display: inline-block;
    border-style: solid;
    border-width: 10px 10px 0 10px;
    border-color: #fff transparent transparent transparent;
    -webkit-transition: 300ms ease-out;
    transition: 300ms ease-out;
}

.fixed-footer .mytask>ul {
    height: 100%;
    padding-left: 0px;
}

.fixed-footer .mytask>ul li {
    justify-content: center;
    display: flex;
    align-items: center;
    font-size: 10px;
    font-weight: 600;
    color: #333;
}

.fixed-footer .mytask>ul li i {
    width: 40px;
    height: 40px;
}

.fixed-footer .chat span.badge {
    width: 16px;
    height: 16px;
    font-size: 12px;
    font-weight: bold;
    font-style: initial;
    color: var(--primary-foreground);
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 2px;
    right: -6px;
    background-color: var(--accent);
    border-radius: 50%;
}

/* Shared Footer */
/* 全站: 保留 MB 底部導覽列高度 */
footer#footerScope {
    padding-bottom: 49px;
}

/* 商品頁: 不顯示底部選單，以購買按鈕取代 */
body#product footer#footerScope {
    padding-bottom: 56px;
}

/* 購物車: 不顯示底部選單，以結帳按鈕取代 */
body#pay01 footer#footerScope {
    padding-bottom: 80px;
}

/* 私密社團: 無底部選單 */
#secretCommunity footer#footerScope,
/* 付款方式: 無底部選單 */
body#pay02 footer#footerScope,
/* 付款成功: 無底部選單 */
body#pay03 footer#footerScope {
    padding-bottom: 0;
}

footer .footer {
    font-size: 14px;
    color: var(--foreground);
    background-color: #F1F5F9;
    border-top: none;
}

footer .footer .footer-body {
    margin: 0 auto;
    padding: 12px 0 16px 0;
    width: 100%;
}

footer .footer .footer-body .footer-logo-wrap {
    margin: 0 auto 16px;
    width: 80px;
    display: block;
}

footer .footer .footer-body img.footer-logo {
    width: 100%;
    display: block;
    object-fit: contain;
    object-position: top;
}

footer .footer .footer-body .accordion-wrap {
    padding: 0 16px;
    width: 100%;
}

footer .footer .footer-body .accordion-header {
    padding: 12px 16px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #D4D4D4;
}

footer .footer .footer-body h3 {
    font-weight: 700;
    font-size: 14px;
    line-height: 24px;
    color: var(--foreground);
}

footer .footer .footer-body ul.accordion-content {
    width: 100%;
    display: block;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

footer .footer .footer-body ul.accordion-content.active {
    max-height: 500px;
    opacity: 1;
    transition: max-height 0.4s, opacity 0.2s;
}

footer .footer .footer-body ul.accordion-content li {
    padding: 8px 12px;
    width: 100%;
    display: block;
}

footer#footerScope .footer .footer-body ul.accordion-content li a,
footer#footerScope .footer .footer-body ul.accordion-content.active li a {
    font-weight: 400;
    font-size: 12px;
    line-height: 20px;
    color: var(--foreground);
}

footer .app-link {
    margin: 16px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

footer .app-link h3 {
    text-align: center;
}

footer .app-link ul {
    /* Follow us icon size */
    --app-link-size: 26px;

    display: flex;
    justify-content: center;
    align-items: center;
}

footer .app-link ul li {
    --app-link-padding: 8px;

    padding: var(--app-link-padding);
    height: calc(var(--app-link-size) + (var(--app-link-padding) * 2));
}

footer .app-link .share-icon {
    width: var(--app-link-size);
    height: var(--app-link-size);
    display: inline-block;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    mask-size: contain;
    mask-position: center;
    background-color: var(--foreground); /* 線條顏色 */
}

footer .app-link .share-icon:hover {
    background-color: var(--primary); /* 線條顏色 */
}

footer .app-link .share-icon.facebook-logo {
    -webkit-mask-image: url(/Images/icons/share/facebook-logo.svg);
    mask-image: url(/Images/icons/share/facebook-logo.svg);
}

footer .app-link .share-icon.instagram-logo {
    -webkit-mask-image: url(/Images/icons/share/instagram-logo.svg);
    mask-image: url(/Images/icons/share/instagram-logo.svg);
}

footer .app-link .share-icon.youtube-logo {
    -webkit-mask-image: url(/Images/icons/share/youtube-logo.svg);
    mask-image: url(/Images/icons/share/youtube-logo.svg);
}

footer .app-link .share-icon.line-logo {
    -webkit-mask-image: url(/Images/icons/share/line-logo.svg);
    mask-image: url(/Images/icons/share/line-logo.svg);
}

footer .app-link .share-icon.blog-logo {
    -webkit-mask-image: url(/Images/icons/share/blog-logo.svg);
    mask-image: url(/Images/icons/share/blog-logo.svg);
}

footer .copy-right-wrap {
    width: 100%;
    background-color: #CBD5E1;
}

footer .copy-right {
    padding: 16px 0;
}

footer .copy-right > p {
    margin: 0;
    font-size: 12px;
    text-align: center;
}

footer .copy-right .gama-link {
    margin: 0 auto;
    width: 36px;
    height: 36px;
    display: block;
}

footer .copy-right .gama-link > img {
    display: block;
    width: 100%;
    height: 100%;
}

@media (min-width: 992px) {
    /* PC: 不需保留底部選單高度 */
    body#product footer#footerScope,
    body#pay01 footer#footerScope,
    body#pay02 footer#footerScope,
    body#pay03 footer#footerScope,
    footer#footerScope {
        padding-bottom: 0;
        position: relative;
    }

    footer .footer .footer-body {
        padding: 40px 0;
        width: 100%;
        max-width: 1200px;
        display: grid;
        grid-template-columns: 148px repeat(4, 1fr);
        column-gap: 80px;
    }

    footer .footer .footer-body .footer-logo-wrap {
        margin: 0;
        width: 100%;
        display: flex;
        justify-content: center;
    }

    footer .footer .footer-body img.footer-logo {
        width: 124px;
    }

    footer .footer .footer-body .accordion-wrap {
        padding: 0;
    }

    footer .footer .footer-body .accordion-header {
        padding: 8px 16px;
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
        border-bottom: none;
    }

    footer .footer .footer-body .accordion-header .collapse-icon {
        display: none;
    }

    footer .footer .footer-body ul.accordion-content {
        max-height: 500px;
        opacity: 1;
    }

    footer .footer .footer-body ul.accordion-content li {
        padding: 8px 16px;
    }

    footer#footerScope .footer .footer-body ul.accordion-content li a,
    footer#footerScope .footer .footer-body ul.accordion-content.active li a {
        font-size: 14px;
        line-height: 24px;
    }

    footer#footerScope .footer .footer-body ul.accordion-content li a:hover,
    footer#footerScope .footer .footer-body ul.accordion-content.active li a:hover {
        color: var(--primary-800);
    }

    footer#footerScope .footer .footer-body ul.accordion-content li a:active,
    footer#footerScope .footer .footer-body ul.accordion-content.active li a:active {
        color: var(--primary);
    }

    footer .app-link {
        margin: 0;
        align-items: flex-start;
        gap: 16px;
    }

    footer .app-link h3 {
        text-align: start;
    }

    footer .app-link ul {
        --app-link-size: 32px;

        margin-top: 0;
        gap: 12px;
    }

    footer .app-link ul li {
        --app-link-padding: 12px;
    }

    footer .copy-right {
        margin: 0 auto;
        width: 100%;
        max-width: 1200px;
        position: relative;
    }

    footer .copy-right > p {
        font-size: 14px;
    }

    footer .copy-right .gama-link {
        margin: 0;
        width: 60px;
        height: 60px;
        display: block;
        position: absolute;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
    }
}