:root {
    --header-height: 69px;
    /* 改為與 body padding-top 一致 */
    --text-color: #455a64;
    --desc-color: #263238;
    --primary-color: #039BE5;
    --light-blue: #00C4FF;
}

/* 釘選「且」在中間投影片時才會被加上的鎖 */
body.is-pinned {
    overflow: hidden;
    overscroll-behavior: none;
}

/* 將手勢交給 Swiper 的垂直滑動 */
.feature-lv2-swiper {
    touch-action: pan-y;
    -webkit-overflow-scrolling: touch;
}

/* 釘選容器避免 overscroll 連鎖到外層 */
.markets-scroll-section {
    overscroll-behavior: contain;
}

/* tablet */
.show_tb {
    display: none !important;
    content-visibility: hidden;
}

/* 在 1199px 以下時顯示 */
@media (max-width: 1199px) {
    .show_tb {
        display: block !important;
        content-visibility: visible;
    }
}

/* 在 767px 以下時隱藏 */
@media (max-width: 767px) {
    .show_tb {
        display: none !important;
        content-visibility: hidden;
    }
}

@media (max-width:1199px) {
    :root {
        --header-height: 59px;
        /* 手機版也調整為一致 */
    }
}

/* default的補釘 */
@media screen and (min-width: 768px) {
    .show_767 {

        content-visibility: hidden;
    }
}

@media screen and (max-width: 767px) {
    .show_767 {
        content-visibility: visible;
    }

    .hidden_m {
        content-visibility: hidden;
    }

}

.text-gray {
    color: var(--text-color);
}

.markets-title {
    /* font-size: 50px;
    line-height: 75px;
    font-weight: bold; */
    font-size: 36px;
    line-height: 54px;
    /* color: #455A64; */
}

.markets-brief {
    margin-top: 36px;
    line-height: 34px;
    color: var(--desc-color);
}

.bold {
    font-weight: bold;
}

.app_block {
    padding: 100px 0 0;
}

.app_block_2 {
    background-color: #002243;
}


.feature-lv1-img-block {
    margin-top: 70px;
}

.feature-lv1-img {
    height: 450px;
}


.img video,
.img img {
    width: 100%;
    height: 100%;
    object-position: center;
    display: block;
}

/* 圖片放大時的遮罩 */
.img-fit {
    overflow: hidden;
}

.img-fit video,
.img-fit img {
    object-fit: cover;
    object-position: center;
}


.markets-scroll-section-tb,
.markets-scroll-section {
    /* padding: 40px 0; */

    /* position: relative; */
    display: flex;
    flex-direction: column;
    /* background: linear-gradient(270deg, #18E4FF 0%, #0493EA 100%); */
    transition: 0s !important;
    height: calc(100vh - var(--header-height) + 1px);
    height: calc(100dvh - var(--header-height) + 1px);

}

.markets-scroll-section-tb .inner-bg,
.markets-scroll-section .inner-bg {
    height: calc(100vh - var(--header-height) + 1px);
    height: calc(100dvh - var(--header-height) + 1px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: 0s !important;
    position: relative;

}

.markets-scroll-section-tb .inner-bg,
.markets-scroll-section .inner-content {
    /* height: calc(100vh - var(--header-height)); */
    height: 100%;
    padding: 70px 0;
    max-width: 1440px;
    width: 100%;
    margin-inline: auto;
}

.feature-lv2-swiper {
    height: 100%;
}

.feature-lv2-content {
    display: flex;
    /* 跟DT討論哪個比較好 */
    gap: 120px;
    /* 跟DT討論哪個比較好 */
    gap: clamp(20px, 8.3vw, 120px);
    max-height: calc(100vh - var(--header-height) - 140px);

}

.lv2-slide-wrapper {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;


}

.feature-lv2-swiper .swiper-slide:nth-child(even) .feature-lv2-content {
    flex-direction: row-reverse;
}

.feature-slide-title {
    font-size: 36px;
    line-height: 54px;
    color: white;
}

.feature-slide-brief {
    font-size: 20px;
    line-height: 34px;
    color: white;
    margin-top: 36px;
}

.relate-link-title {
    font-size: 24px;
    line-height: 36px;
    color: white;
    margin-top: 36px;

}

.feature-lv2-swiper {
    --swiper-navigation-color: transparent;
}

.swiper_arrow_block .swiper-button-next svg,
.swiper_arrow_block .swiper-button-prev svg {
    opacity: 0;
}


.feature-lv2-swiper .text-block,
.markets-scroll-section-tb .text-block {
    padding-left: 140px;
    /* 跟DT討論哪個比較好 */
    padding-left: 20px;
    margin-left: clamp(0px, (100% - 1200px) / 2, 120px);
    max-width: 712px;
}

.feature-card-list .feature-lv2-content:nth-child(even) .text-block,
.feature-lv2-swiper .swiper-slide:nth-child(even) .text-block {
    padding-right: 140px;
    /* 跟DT討論哪個比較好 */
    padding-left: 0;
    padding-right: 20px;
    margin-left: 0;
    margin-right: clamp(0px, (100% - 1200px) / 2, 120px);
    ;
}

.common-ul {
    --text-color: #263228;
    --bullet-color: #0057a6;
    margin-top: 4px;
}

.common-ul.white-type {
    --text-color: white;
    --bullet-color: white;
}


.common-ul>li {
    position: relative;
    font-size: 20px;
    line-height: 34px;
    padding-left: 40px;
    color: var(--text-color);
}

.common-ul>li::before {
    background-color: var(--bullet-color);
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 7px;
    display: inline-block;
    position: absolute;
    top: 12px;
    left: 10px;
}

.common-ul .relate-li-link {
    color: var(--text-color);
    position: relative;
    display: flex;
    align-items: center;
}

.relate-li-link::after {
    content: "";
    display: block;
    margin: auto;
    margin-left: 14px;
    background-image: url('../../images/umc-arrow-icon.svg');
    background-size: contain;
    background-repeat: no-repeat;
    width: 10px;
    height: 17px;
    transition: all 0.3s cubic-bezier(0, 0, 0.58, 1);
}

/* 20251204 待通知是否要加上去 */
.relate-li-link[href=""], 
.relate-li-link[href="#"], 
.relate-li-link:not([href]){
    cursor: auto;
}

.relate-li-link[href=""]:after, 
.relate-li-link[href="#"]:after, 
.relate-li-link:not([href]):after {
    display: none;
}

.relate-li:hover .relate-li-link::after {
    margin-left: 26px;
}


.feature-lv2-swiper .feature-lv2-img-block {
    max-width: 608px;
}

.feature-lv2-img {
    width: 100%;
    aspect-ratio: 608 / 536;
}

.feature-lv2-content .text-block,
.feature-lv2-content .img-block {
    flex: 1;
}

.feature-lv2-content .img {
    aspect-ratio: 608 / 536;
    max-width: 608px;
}

.finisher-canvas {
    width: 100% !important;
    height: 100% !important;
}

/* .feature-lv2-swiper .swiper-slide:nth-child(even) .feature-lv2-content{
    margin-left: auto;
    margin-right: 70px;
} */
/* 釘選區避免滾動連鎖到 body */
.markets-scroll-section {
    overscroll-behavior: contain;
    /* 阻止 overscroll 向外冒泡 */
}

/* 讓 Swiper 只接管垂直手勢、避免與瀏覽器手勢衝突 */
.feature-lv2-swiper {
    touch-action: pan-y;
    /* 垂直滑動交給 Swiper，保留可滾動語意 */
    -webkit-overflow-scrolling: touch;
    /* iOS 慣性滾動更順 */
}

.pin-space--tablet {
    pointer-events: none!important;
}

.pin-space--tablet>* {
    pointer-events: none!important;
}

.pe-none {
    pointer-events: none!important;
}

@media (min-width:1200px) and (max-width:1439px) {
    .feature-lv1-img-block {
        padding-inline: 140px;
        margin-inline: 0;
        max-width: none;
    }
}




@media (max-height: 746px) and (min-width: 768px) {


    .feature-slide-title {
        font-size: 20px;
        line-height: 30px;
    }

    .feature-slide-brief {
        font-size: 16px;
        line-height: 24px;
        margin-top: 12px;
    }

    .relate-link-title {
        font-size: 18px;
        line-height: 28px;
        margin-top: 12px;
    }


    .common-ul>li {
        font-size: 16px;
        line-height: 24px;
        padding-left: 30px;
    }

    .common-ul>li::before {

        width: 8px;
        height: 8px;
        border-radius: 7px;

        top: 8px;
        left: 14px;
    }

    .relate-li-link::after {

        margin-left: 8px;

        width: 8px;
        height: 14px;

    }

    .relate-li:hover .relate-li-link::after {
        margin-left: 22px;
    }

    .feature-lv2-img {
        height: 100%;
        width: auto;
    }

    .feature-lv2-img-block {
        display: flex;
        justify-content: flex-start;
    }

    .feature-lv2-swiper .swiper-slide:nth-child(even) .feature-lv2-img-block {
        justify-content: flex-end;
    }


}

@media (max-width:1199px) {
    .pin-space--desktop {
        pointer-events: none!important;
    }

    .pin-space--desktop>* {
        pointer-events: none!important;
    }

    .pin-space--tablet {
        pointer-events: auto!important;
    }

    .pin-space--tablet>* {
        pointer-events: auto!important;
    }



    .feature-lv1-img-block {
        margin-top: 50px;
    }



    .markets-title {
        font-size: 36px;
        line-height: 54px;
        font-weight: normal;
    }

    .app_block {
        padding: 40px 0 0;
    }

    .markets-brief {
        margin-top: 36px;
    }


    .feature-lv1-img-block {
        padding: 0 40px;
        margin-inline: auto;

    }

    .feature-lv1-img {
        max-width: 900px;
        margin-inline: auto;
    }

}

@media (max-width:767px) {

    .pin-space--tablet {
        pointer-events: none!important;
    }

    .pin-space--tablet>* {
        pointer-events: none!important;
    }


    .markets-brief {
        font-size: 18px;
        line-height: 28px;
    }

    .app-block-text-wrapper {
        max-width: 500px;
        margin-inline: auto;
    }

    .feature-lv1-img-block {
        margin-top: 40px;
        padding: 0 20px;

    }

    .feature-lv1-img {
        max-width: 500px;
        height: 400px;
    }

    .markets-section-m {
        position: relative;
    }

    .markets-section-m .inner-m {
        padding: 80px 0 60px;
    }

    .markets-section-m .container {
        max-width: 540px;
        min-width: 0;
    }

    .m-feature-card .content {
        margin-top: 40px;
    }

    .feature-slide-title {
        font-size: 30px;
        line-height: 45px;
    }

    .feature-slide-brief {
        font-size: 18px;
        line-height: 28px;
    }

    .relate-link-title {
        font-size: 20px;
        line-height: 34px;
        margin-top: 36px;
    }



    .common-ul>li {
        font-size: 18px;
        line-height: 28px;
        padding-left: 30px;
    }

    .common-ul>li::before {
        width: 8px;
        height: 8px;
        top: 10px;
        left: 11px;
    }


    .relate-li-link::after {
        margin-left: 8px;
        width: 8px;
        height: 14px;
    }

    .relate-li:hover .relate-li-link::after {
        margin-left: 22px;
    }

    .m-feature-card+.m-feature-card {
        margin-top: 100px;
    }

    .m-feature-card .img {
        max-width: 500px;
        aspect-ratio: 500 / 440;
    }

    .markets-section-m canvas[id^="finisher-canvas-"] {
        width: 100% !important;
        height: 100% !important;
    }

    .relative_app_block .container {
        max-width: 500px;
        min-width: 0;
    }
}

.show_touch {
    display: none;
    content-visibility: hidden;
}

/* query是否為觸控裝置 */
@media (pointer:coarse) {
    .hidden_touch {
        display: none;
        content-visibility: hidden;
    }

    .show_touch {
        display: block;
        content-visibility: visible;
    }
}

.feature-card-list {
    height: 100%;
}

/* 在檔案末尾添加或修改以下部分 */

/* 觸控/平板版本的 feature-card-list */
.markets-scroll-section-tb .feature-card-list {
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    /* 垂直置中 */
    justify-content: center;
}

/* 讓觸控版本的每個 slide 絕對定位，可以重疊 */
.markets-scroll-section-tb .feature-lv2-content {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    transform: translateY(-50%);
    /* 垂直置中 */
    display: flex;
    /* gap: 20px; */
    gap: clamp(20px, 8.3vw, 120px);
    /* padding: 0 40px; */
    /* 移除原本的 max-height */
    max-height: calc(100vh - var(--header-height) - 80px);
    overflow: clip;
    will-change: transform;
}

/* 確保 lv2-slide-wrapper 可以容納絕對定位的元素 */
.markets-scroll-section-tb .lv2-slide-wrapper {
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: calc(100vh - var(--header-height));
}

/* 偶數項反向排列 */
.markets-scroll-section-tb .feature-card-list .feature-lv2-content:nth-child(even) {
    flex-direction: row-reverse;
}

/* 調整圖片區塊在觸控版本的尺寸 */
.markets-scroll-section-tb .feature-lv2-img-block {
    max-width: 500px;
    flex: 1;
}

.markets-scroll-section-tb .feature-lv2-img {
    width: 100%;
    aspect-ratio: 608 / 536;
}

/* 調整文字區塊的 padding */
/* .markets-scroll-section-tb .text-block {
    flex: 1;
    padding-left: clamp(20px, 4vw, 80px);
  }
  
  .markets-scroll-section-tb .feature-card-list .feature-lv2-content:nth-child(even) .text-block {
    padding-right: clamp(20px, 4vw, 80px);
    padding-left: 0;
  } */

  