.product-promotion-wrap{
    max-width: 100%;
    display: flex;
    /* overflow-x: scroll; */
    padding-top: 10px;
    margin: 10px 0;
}
.product-promotion-wrap-style2{
    gap: 12px;
}
.product-promotion-item{
    width: 33.33%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-self: center;
    padding: 0 12px 26px 12px;
    /* gap: 5px; */
    cursor: pointer;
    position: relative;
    /* overflow: hidden; */
    background-color: #ffffff;
}
.product-promotion-item-style2{
    padding:26px 12px;
}

/* .recommend-style1-wrap::after, .recommend-style2-wrap::after {
    background-color: #633FF5;
    opacity: 0.1;
} */
.recommend-style2-wrap::after {
    border-radius: 12px;
}
.product-promotion-item:nth-child(even) p,.product-promotion-item:nth-child(even) div{
    position: relative;
    z-index: 10;
}
.product-promotion-item-style2{
    border-radius: 12px;
    /* overflow: hidden; */
}
.product-promotion-item .product-promotion-item-image {
    width: 64px;
    height: 64px;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}
.product-promotion-item .product-promotion-item-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-promotion-item:not(.product-promotion-item-style3) {
  &[data-check="true"] {
    .product-promotion-item-image {
      img {
        /* filter: invert(48%) sepia(79%) saturate(2476%) hue-rotate(240deg) brightness(68%) contrast(119%); */
      }
    }
  }
}

.product-promotion-item * {
    margin: 0;
}
.product-promotion-item:nth-last-child(1) {
    border-radius: 0 12px 12px 0;
}
.product-promotion-item:nth-of-type(1) {
    border-radius: 12px 0 0 12px;
}
.product-promotion-item-style2:nth-last-child(1) {
    border-radius: 12px;
}
.product-promotion-item-style2:nth-of-type(1) {
    border-radius: 12px;
}
.product-promotion-item::before,.product-promotion-item::after{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    content: "";
}
.product-promotion-item:nth-last-child(1)::before {
    border-radius: 0 12px 12px 0;
    border: 1px solid #888888;
}
.product-promotion-item:nth-of-type(1)::before {
    border-radius: 12px 0 0 12px;
    border: 1px solid #888888;
}
.product-promotion-item::before {
    border: 1px solid #888888;
    z-index: 10;
    border-radius: 12px;
}
.product-promotion-item-style1 {
    justify-content: flex-end;
}
.product-promotion-item-style1[data-check="true"]::after,
.product-promotion-item-style2[data-check="true"]::after {
    background-color: var(--cover-color);
    opacity: var(--cover-color-opacity);
}
.product-promotion-item-style2[data-check="true"]::after {
    border-radius: 12px;
}
.product-promotion-item-style1:first-child[data-check="true"]::after {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}
.product-promotion-item-style1:last-child[data-check="true"]::after {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}
.product-promotion-item-style1::before {
    border-radius: 0;
    border-left: none;
    border-right: none;
}
.product-promotion-item-style1::before{
    border-radius: 0;
}
.product-promotion-item-style2:nth-last-child(1)::before {
    border-radius: 12px;
}
.product-promotion-item-style2:nth-of-type(1)::before {
    border-radius: 12px;
}

.product-promotion-item[data-check="true"]::before{
    border: 1px solid var(--cover-color);
    z-index: 10;
    /* background-color: var(--theme-color); */
}
.product-promotion-item-style1[data-check="true"] {
    &:not(:first-child,:last-child)::before {
        border-left: none;
        border-right: none;
    }
    &:first-child::after {
        border-top-left-radius: 12px;
        border-bottom-left-radius: 12px;
    }
    &:last-child::after {
        border-top-right-radius: 12px;
        border-bottom-right-radius: 12px;
    }
}
.product-promotion-item-style1[data-check="true"] p{
    color: var(--theme-color) !important;
}
.product-promotion-item-style2[data-check="true"]::before{
    border-radius: 12px;
}
.product-promotion-item .product-promotion-item-title{
    color: #000;
    /* font-weight: 500; */
    /* font-size: 24px; */
  }
  
.product-promotion-item-style1, .product-promotion-item-style2 {
  .product-promotion-item-title{
    font-weight: 500;
    font-size: 24px;
  }
}

.product-promotion-item .product-promotion-item-save{
    color: #000;
    font-size: 16px;
}

.product-promotion-item .product-promotion-item-price{
    color: #000;
    font-size: 16px;
}
.product-promotion-item .product-promotion-item-price .product-promotion-item-old{
    text-decoration: line-through;
}

.product-promotion-item .product-promotion-item-price-bottom{
    color: #000;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
}
.product-promotion-item .product-promotion-item-price-bottom .product-promotion-item-price-each{
    font-size: 14px;
    margin-left: 8px;
}

/* style3 */
.product-promotion-wrap-style3{
    gap: 12px;
    flex-direction: column;
}
.product-promotion-item-style3{
    border-radius: 12px !important;
    overflow: hidden;
    /* width: 428px; */
    width: 100%;
    height: max-content;
    background-color: #ffffff;
    border: 1px solid #888888;
    padding: 12px 12px 14px;
    align-items: unset;
    gap: 12px;
}
.product-promotion-item-style3 .product-promotion-item-content{
    display: flex;
    width: 100%;
    gap: 12px;
}
.product-promotion-item-style3::before{
    display: none;
}
.product-promotion-item .product-promotion-item-image-left {
    width: 26%;
    height: auto;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}
.product-promotion-item .product-promotion-item-image-left::after {
    display: block;
    width: 100%;
    padding-bottom: 100%;
    content: "";
}
.product-promotion-item-style3 .product-promotion-item-title{
    color: #000;
    font-weight: 500;
}
.product-promotion-item-style3 .product-promotion-item-des{
    color: #666267;
}
.product-promotion-item-style3 .product-promotion-item-save{
    color: #000;
    font-size: 14px;
    font-weight: 500;
    padding: 4px 6px;
    background-color: #F6DB85;
    border-radius: 8px;
    text-align: center;
    position: absolute !important;
    top: 0;
    right: 0;
}
.product-promotion-item-style3 .product-promotion-item-price{
    color: #000;
    font-weight: 500;
}
.product-promotion-item-style3 .product-promotion-item-price .product-promotion-item-old{
    text-decoration: line-through;
    color: #6b6b6b;
}
.product-promotion-item-style3 .product-promotion-item-image-right{
    width: 26%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
}
.product-promotion-item-style3 .product-promotion-item-image-right svg:first-child {
    stroke: var(--theme-color);
}
.product-promotion-item-style3 .product-promotion-item-image-right svg:last-child {
    fill: var(--theme-color);
}
.product-promotion-item-style3 .product-promotion-item-image-center{
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.product-promotion-item-sku-content{
    width: 100%;
    overflow: hidden;
}
.product-promotion-item-style3[data-check="true"] .product-promotion-item-image-right svg[check="false"] {
    display: none;
}
.product-promotion-item-style3[data-check="false"] .product-promotion-item-image-right svg[check="true"] {
    display: none;
}
.product-promotion-item-style3[data-check="false"] .product-promotion-item-sku-content {
    display: none;
}
.product-promotion-item-style3[data-check="true"] .product-promotion-item-sku-content {
    display: block;
}

.product-promotion-item-style3 .product-promotion-item-sku-content-bottom{
    color: #08716D;
}

.product-promotion-item-style3-wrap h3 {
    color: #000;
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 20px;
    text-align: center;
}

/* style4 */
.product-promotion-wrap-style4{
    gap: 12px;
    flex-direction: column;
}
.product-promotion-item-style4{
    border-radius: 12px !important;
    width: 100%;
    height: max-content;
    background-color: #ffffff;
    border: 1px solid #888888;
    padding: 13px 20px;
    align-items: unset;
    /* overflow: hidden; */
}
.product-promotion-item-style4 .product-promotion-item-content{
    display: flex;
    width: 100%;
    align-items: center;
    gap: 12px;
}
.product-promotion-item-style4::before{
    display: none;
}
.product-promotion-item-style4 .product-promotion-item-image-left {
    flex: 1;
    display: flex;
    align-items: center;
}
.product-promotion-item-style4 .product-promotion-item-image-left .product-promotion-item-image {
    width: 53px;
    height: 53px;
    margin-right: 20px;
    flex-shrink: 0;
}
.product-promotion-item-style4 .product-promotion-item-image-left::after {
    display: none;
}
.product-promotion-item-style4 .product-promotion-item-title{
    color: #000;
    font-weight: 500;
    font-size: 16px;
    display: flex;
    gap: 12px;
    align-items: center;
}
.product-promotion-item-style4 .product-promotion-item-des{
    color: #171717;
    font-weight: 500;
    font-size: 14px;
}
.product-promotion-item-style4 .product-promotion-item-des2 {
    margin-top: 4px;
    font-size: 17px;
}
.product-promotion-item-style4 .product-promotion-item-des2 .bold {
    font-size: 18px;
    font-weight: bold;
    color: var(--theme-color);
}
.product-promotion-item-style4 .product-promotion-item-save{
    color: #fff;
    font-size: 12px;
    font-weight: 300;
    padding: 2px 8px;
    background-color: var(--theme-color);
    border-radius: 12px;
    text-align: center; 
    width: max-content;
    height: max-content;
}
.product-promotion-item-price-style1 span{
    color: #bdbdbd;
}
.product-promotion-item-style4 .product-promotion-item-price{
    color: #000;
    font-size: 20px;
    font-weight: 500;
    display: flex;
    flex-direction: column;
}
.product-promotion-item-style4 .product-promotion-item-price .product-promotion-item-old{
    text-decoration: line-through;
    color: #6b6b6b;
    font-size: 16px;
    font-weight: 300;
}
.product-promotion-item-style4 .product-promotion-item-image-right{
    width: fit-content;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
}
.product-promotion-item-sku-content{
    width: 100%;
    overflow: hidden;
}
.product-promotion-item-style4[data-check="false"] .product-promotion-item-sku-content {
    display: none;
}
.product-promotion-item-style4[data-check="true"] .product-promotion-item-sku-content {
    display: block;
}
.product-promotion-item-checked{
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 1px solid var(--theme-color);
    padding: 2px;
}
.product-promotion-item-checked .product-promotion-item-checked-item{
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: transparent;
}

.product-promotion-item-style4[data-check="false"] .product-promotion-item-checked .product-promotion-item-checked-item {
    background-color: transparent;
}
.product-promotion-item-style4[data-check="true"] .product-promotion-item-checked .product-promotion-item-checked-item {
    background-color: var(--theme-color);
}
.product-promotion-item-style4[data-check="false"] .product-promotion-item-image-right {
    opacity: 1;
}
.product-promotion-item-style4[data-check="true"] .product-promotion-item-image-right {
    /* opacity: 0; */
}

.product-promotion-item-style4 .product-promotion-item-gift-info {
    height: 54px;
    background-color: var(--theme-color);
    padding: 3px 6px;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 14px;
    color: rgb(var(--color-light-text));
    font-size: 14px;
    font-weight: 500;
    font-size: 0;
    width: calc(100% + 40px);
    margin-left: -20px;
    margin-bottom: -13px;
    border-radius: 0 0 10px 10px;
}

.product-promotion-item-style4 .product-promotion-item-gift-info img {
    height: 100%;
    width: auto;
}

.product-promotion-item-style4 .product-promotion-item-gift-info p {
    font-size: 18px;
    font-weight: normal;
}

.product-promotion-item-style4 .product-promotion-item-gift-info p .bold {
    font-weight: bold;
}

.promotion-number{
    font-size: 16px;
    font-weight: 500;
    color: var(--theme-color);
    margin-right: 12px;
}

.product-promotion-style1-recommend{
    color: transparent;
    font-size: 14px;
    font-weight: 400;
}
.recommend-style1{
    color: var(--style-1-recommend-tag-text-color);
}

.product-promotion-style2-recommend{
    display: none;
}

.recommend-style2{
    display: block ;
    color: var(--style-2-recommend-tag-text-color);
    background-color: var(--style-2-recommend-tag-bg-color);
    padding: 0 4px;
    border-radius: 4px;
    position: absolute !important;
    top: 0;
    left: auto;
    right: auto;
    transform: translateY(-50%);
    z-index: 10;
}
.product-promotion-style4-recommend{
    display: none;
}
.recommend-style4{
    display: block;
    background-color: var(--style-4-recommend-tag-bg-color);
    color: var(--style-4-recommend-tag-text-color);
    padding: 2px 4px;
    width: max-content;
    border-radius: 0 4px 4px 4px;
    position: absolute !important;
    top: 0;
    right: 10px;
    transform: translateY(-50%);
}
.recommend-style4::after{
    content: "";
    /* width: 6px;
    height: 10px;
    background-color: #534688; */
    margin-left: -6px;
    position: absolute;
    left: 0;
    top: 0;
    border-left: 3px solid transparent;
    border-top: 5px solid transparent;
    border-bottom: 5px solid var(--style-4-recommend-tag-back-bg-color);
    border-right: 3px solid var(--style-4-recommend-tag-back-bg-color);
}

@media screen and (max-width: 768px) {
    .product-promotion-style1-recommend,
    .product-promotion-style2-recommend,
    .product-promotion-style4-recommend {
        font-size: 10px;
    }

    .product-promotion-item-style1,
    .product-promotion-item-style2 {
        .product-promotion-item-title {
            font-size: 12px;
        }

        .product-promotion-item-save {
            font-size: 10px;
        }

        .product-promotion-item-price {
            font-size: 10px;
        }
        .product-promotion-item-price-bottom {
            font-size: 14px;

            .product-promotion-item-price-each {
                font-size: 12px;
            }
        }
    }

    .product-promotion-item-style3-wrap h3 {
        font-size: 13px;
        font-weight: 700;
        line-height: 1.2;
        margin-bottom: 18px;
    }

    .product-promotion-item-style3 {
        .product-promotion-item-content {
            .product-promotion-item-image {
                min-height: 80px;
                width: 80px;
            }

            .product-promotion-item-title {
                font-size: 14px;
            }

            .product-promotion-item-des {
                font-size: 11px;
            }

            .product-promotion-item-price {
                font-size: 13px;
            }

            .product-promotion-item-save {
                font-size: 12px;
                font-weight: 600;
            }

            .product-promotion-item-image-right {
                svg {
                    width: 32px;
                    height: 32px;
                }
            }
        }
    }

    .product-promotion-item-style4 {
        padding: 15px;
        border-radius: 8px;

        .product-promotion-item-image-left .product-promotion-item-image {
            width: 40px;
            height: 40px;
            margin-right: 10px;
        }

        .product-promotion-item-title {
            font-size: 14px;
        }

        .product-promotion-item-save {
            font-size: 10px;
        }

        .product-promotion-item-des {
            font-size: 12px;
        }

        .product-promotion-item-price {
            font-size: 16px;
        }

        .product-promotion-item-price .product-promotion-item-old {
            font-size: 12px;
        }

        .product-promotion-item-des2 {
            font-size: 12px;
        }

        .product-promotion-item-des2 .bold {
            font-size: 13px;
        }

        .product-promotion-item-gift-info {
            width: calc(100% + 30px);
            margin-left: -15px;
            margin-bottom: -15px;
            height: 36px;
        }

        .product-promotion-item-gift-info p {
            font-size: 12px;
        }

        .product-promotion-item-gift-info p .bold {
            font-size: 13px;
        }
    }

    .new-sku-list[data-show='true'] {
        .promotion-number {
            padding-top: 0 !important;
        }

        &.new-sku-list-style1{
            .product-promotion-item-title {
                font-size: 16px;
            }

            .product-promotion-item-price {
                font-size: 16px;
            }

            .product-promotion-item-old {
                font-size: 12px;
            }
        }

        .product-promotion-item-style4 & {
            .product-promotion-item-title {
                font-size: 16px;
            }

            .product-promotion-item-price {
                font-size: 16px;
            }

            .product-promotion-item-old {
                font-size: 12px;
            }
        }
    }
}
/* ============================================================================
   液态玻璃风（Apple Liquid Glass）—— 仅在后台开启「液态玻璃风」时生效
   全部规则挂在 .pp-liquid-glass 下，关掉开关即完全回到原样，不影响其它品类站。
   数值来自 block 的三个滑杆（圆角/模糊/不透明度），挂在根元素的 inline style 上。
   ============================================================================ */

/* ---- 档位卡片：磨砂玻璃 ---- */
.pp-liquid-glass .product-promotion-item-style4 {
  position: relative;
  border-radius: var(--pp-glass-radius, 24px) !important;
  border: 1px solid rgba(255, 255, 255, 0.6) !important;
  background-color: transparent;
  background-image: linear-gradient(
    160deg,
    rgba(255, 255, 255, calc(var(--pp-glass-opacity, 0.55) + 0.25)),
    rgba(255, 255, 255, var(--pp-glass-opacity, 0.55))
  );
  -webkit-backdrop-filter: blur(var(--pp-glass-blur, 20px)) saturate(180%);
  backdrop-filter: blur(var(--pp-glass-blur, 20px)) saturate(180%);
  /* 玻璃的立体感来自「外部柔和投影 + 内部顶光」，不是单纯的半透明 */
  box-shadow:
    0 8px 24px rgba(31, 38, 135, 0.08),
    inset 0 1px 1px rgba(255, 255, 255, 0.9);
  transition: box-shadow 0.35s ease, transform 0.35s ease;
}

/* ---- 选中态：虹彩描边 ----
   普通 border 画不出渐变。做法是用伪元素铺一层渐变，再用 mask 把中间挖空，
   只留下 padding-box 到 border-box 之间那一圈 —— 这是渐变边框的标准解法。 */
.pp-liquid-glass .product-promotion-item-style4[data-check="true"] {
  box-shadow:
    0 12px 36px rgba(99, 63, 245, 0.18),
    inset 0 1px 1px rgba(255, 255, 255, 0.95);
}

.pp-liquid-glass .product-promotion-item-style4[data-check="true"]::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 2px;
  background: linear-gradient(
    135deg,
    #a8d8ff 0%,
    #c9b6ff 25%,
    #ffc2e8 50%,
    #b6e3ff 75%,
    #d4c2ff 100%
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 1;
}

/* ---- MOST POPULAR 徽章：同款虹彩 ---- */
.pp-liquid-glass .recommend-style4 {
  border-radius: 999px !important;
  background: linear-gradient(135deg, #a8d8ff, #c9b6ff 45%, #ffc2e8) !important;
  color: #2b2b45 !important;
  font-weight: 600;
  letter-spacing: 0.04em;
  box-shadow: 0 4px 14px rgba(150, 130, 255, 0.35);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

/* ---- 单选圆点 ---- */
.pp-liquid-glass .product-promotion-item-checked {
  border-radius: 50%;
  border: 1.5px solid rgba(0, 0, 0, 0.25);
  background: rgba(255, 255, 255, 0.5);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}

.pp-liquid-glass
  .product-promotion-item-style4[data-check="true"]
  .product-promotion-item-checked {
  border-color: #3b6fe0;
  box-shadow: 0 0 0 3px rgba(59, 111, 224, 0.15);
}

/* ---- 「20% OFF」徽章：设计稿里是浅色玻璃药丸，不是实心主题色 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-save {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75) !important;
  color: #2b2b45 !important;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 1px 3px rgba(0, 0, 0, 0.06);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

/* ---- 内嵌的 #1 / #2 规格子卡：比外层更浅一层的玻璃，形成层次 ---- */
.pp-liquid-glass .new-sku-list[data-show="true"] > [data-sku-index] {
  border-radius: calc(var(--pp-glass-radius, 24px) - 6px);
  padding: 12px;
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8);
}

.pp-liquid-glass .promotion-number {
  color: #3b6fe0;
  font-weight: 700;
}

/* ---- 降级：不支持 backdrop-filter 的浏览器给不透明底，否则文字会糊在背景上 ---- */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .pp-liquid-glass .product-promotion-item-style4 {
    background-image: none;
    background-color: rgba(255, 255, 255, 0.92);
  }
}

/* xN 角标要凸出到缩略图外面，卡片不能裁掉它 */
.pp-liquid-glass .product-promotion-item-style4 {
  overflow: visible;
}

/* ::after 是原样式给缎带做的左侧小三角，行内药丸不需要 */
.pp-liquid-glass .recommend-style4::after {
  display: none;
}

/* ---- 液态玻璃：SKU 从平铺改成下拉外观 ----------------------------------
   为什么不换成真 <select>：product-sku-component.js 跟这套平铺 DOM 绑得很深 ——
   靠 .new-sku-item 绑 click、靠 [data-value="X"] 查节点、靠 disabled 属性标记
   不可选组合、还有 setSkuDisabled() 做规格联动。换成 select 等于重写加购路径上的
   整个选择器。这里只改「外观」：结构和 JS 全部原样，把选项面板默认收起，
   用组件自带的 .sku-title + .new-sku-name（现有 JS 已在实时填当前选中值）当触发器。
   点开还是原来那些节点、点击还是原来的 handler，风险接近零。 */

.pp-liquid-glass .sku-option-style1,
.pp-liquid-glass [class*="new-sku-option-"] {
  position: relative;
  margin-bottom: 8px !important;
}

/* 触发器：显示「规格名: 当前值 ▾」 */
.pp-liquid-glass .sku-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 30px 8px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 1px 3px rgba(0, 0, 0, 0.06);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-size: 13px;
  cursor: pointer;
  user-select: none;
  position: relative;
  transition: box-shadow 0.2s ease;
}

.pp-liquid-glass .sku-title:hover {
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 下拉箭头 */
.pp-liquid-glass .sku-title::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid rgba(0, 0, 0, 0.5);
  border-bottom: 1.5px solid rgba(0, 0, 0, 0.5);
  transform: translateY(-70%) rotate(45deg);
  transition: transform 0.2s ease;
}

.pp-liquid-glass .sku-title[aria-expanded="true"]::after {
  transform: translateY(-30%) rotate(-135deg);
}

.pp-liquid-glass .new-sku-name {
  font-weight: 500;
  color: #111;
}

/* 选项面板：默认收起，点触发器才展开 */
.pp-liquid-glass .new-sku-wrap {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 30;
  min-width: 100%;
  width: max-content;
  max-width: 280px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 30px rgba(31, 38, 135, 0.16);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
}

.pp-liquid-glass .new-sku-wrap[data-open="true"] {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* ---- 液态玻璃：颜色/尺码/长度 横排一行 --------------------------------
   参考图里 #1 后面是 [Dark Gray ▾] [S ▾] [Full Length ▾] 并排，很省纵向空间。
   原本每个规格是 margin-bottom:16px 的块级元素，一个一行。 */
.pp-liquid-glass [id^="new-sku-"] {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.pp-liquid-glass [class*="new-sku-option-"] {
  margin-bottom: 0 !important;
  flex: 0 1 auto;
  /* 面板是 position:absolute，参照系是「最近的定位祖先」。这里不写 relative，
     它会一路找到 .product-promotion-item-style4（那个是 relative），
     于是面板挂到整张卡片的坐标系上，展开时看起来就是错位。 */
  position: relative;
}

/* 触发器不要被挤变形 */
.pp-liquid-glass .sku-title {
  white-space: nowrap;
  max-width: 100%;
}

.pp-liquid-glass .new-sku-name {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 90px;
  display: inline-block;
  vertical-align: bottom;
}

/* #1 / #2 那一行整体也横排：编号 + 三个下拉在同一行 */
.pp-liquid-glass [data-sku-index] {
  align-items: center !important;
  gap: 10px;
  flex-wrap: wrap;
}

.pp-liquid-glass .promotion-number {
  padding-top: 0 !important;
  flex-shrink: 0;
}

/* 横排后每个下拉都是绝对定位面板，靠 z-index 保证点开的那个盖在别人上面 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] {
  z-index: 40;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass [id^="new-sku-"] {
    gap: 6px;
  }
  .pp-liquid-glass .sku-title {
    padding: 7px 26px 7px 10px;
    font-size: 12px;
  }
  .pp-liquid-glass .new-sku-name {
    max-width: 64px;
  }
}

/* ---- 液态玻璃：下拉面板改成竖排列表（不再平铺） ------------------------
   之前面板里是 flex-wrap 平铺，等于把原来的平铺搬进了小盒子，没解决占地问题。
   下拉就该是一列选项，一行一个。 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 2px;
  padding: 6px;
  max-height: 260px;
  overflow-y: auto;
}

/* 每个选项占一整行，像原生下拉的 option */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > * {
  width: 100%;
  margin: 0 !important;
  border-radius: 8px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.pp-liquid-glass .new-sku-wrap[data-open="true"] > *:hover {
  background: rgba(0, 0, 0, 0.05);
}

/* 当前选中项 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > [check="true"] {
  background: rgba(59, 111, 224, 0.1);
  font-weight: 500;
}

/* 不可选组合：保持原有的置灰语义，别让它看起来可点 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > [disabled="true"] {
  opacity: 0.35;
  cursor: not-allowed;
}

.pp-liquid-glass .new-sku-wrap[data-open="true"] > [disabled="true"]:hover {
  background: transparent;
}

/* 颜色项：色块 + 名字并排，而不是只有一个色块 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] .new-sku-color-item,
.pp-liquid-glass .new-sku-wrap[data-open="true"] [class*="new-sku-color"] {
  justify-content: flex-start;
}

/* ---- 档位显示顺序：2 / 3 / 1 --------------------------------------------
   用 CSS order 而不是改元字段数组：
   1) 元字段是数据，改它会影响所有用同一份数据的地方；
   2) order 只改「视觉顺序」，DOM 顺序不动 —— JS 的 promotionIndex（档位序号）
      和价格计算全靠 DOM 顺序，动了会连带出错。
   按件数排：2 件在最前，3 件次之，1 件垫底（1 件是兜底选项，不该抢视线）。 */
.product-promotion-wrap[data-tier-order="mid_high_low"] {
  display: flex;
  flex-direction: column;
}

.product-promotion-wrap[data-tier-order="mid_high_low"] .J-promotion-item {
  order: 5; /* 其余件数排在后面，保持相对顺序 */
}

.product-promotion-wrap[data-tier-order="mid_high_low"] .J-promotion-item[data-qty-order="2"] {
  order: 1;
}

.product-promotion-wrap[data-tier-order="mid_high_low"] .J-promotion-item[data-qty-order="3"] {
  order: 2;
}

.product-promotion-wrap[data-tier-order="mid_high_low"] .J-promotion-item[data-qty-order="1"] {
  order: 9; /* 单件垫底 */
}

/* ============================================================================
   按设计稿 1:1 调整（液态玻璃风）
   ============================================================================ */

/* ---- 徽章：行内玻璃药丸，竖直居中贴在价格左边 ---- */
.pp-liquid-glass .pp-badge-inline {
  display: none; /* 没有 recommend 的档位不占位 */
}

.pp-liquid-glass .pp-badge-inline.recommend-style4 {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: center;
  flex-shrink: 0;
  margin-right: 18px;
  position: static;       /* 覆盖上一版的缎带绝对定位 */
  top: auto;
  right: auto;
  padding: 7px 16px !important;
  border-radius: 999px !important;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: #5b5bd6 !important;
  background: rgba(255, 255, 255, 0.75) !important;
  border: 1px solid rgba(150, 150, 255, 0.35);
  box-shadow:
    0 2px 10px rgba(120, 120, 255, 0.18),
    inset 0 1px 1px rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

/* 徽章前面的图标（设计稿里是星星/钻石） */
.pp-liquid-glass .pp-badge-inline.recommend-style4::before {
  content: "◆";
  font-size: 11px;
  color: #6c6cf0;
}

/* 缎带态遗留的折角，行内药丸不需要 */
.pp-liquid-glass .pp-badge-inline.recommend-style4::after {
  display: none;
}

/* ---- 内容行：让 image-left 吃掉中间空隙，把徽章和价格推到右边 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-content {
  align-items: center;
  padding: 16px 18px;
}

.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-left {
  flex: 1 1 auto;
  min-width: 0;
}

/* ---- 价格：右对齐，现价大、原价划线在下 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-right {
  align-items: flex-end;
  flex-shrink: 0;
}

.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-price {
  align-items: flex-end;
  gap: 2px;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* ---- 「15% OFF」药丸：浅蓝玻璃 + 蓝字 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-save {
  color: #5b5bd6 !important;
  background: rgba(160, 190, 255, 0.22) !important;
  border-color: rgba(150, 170, 255, 0.4);
}

/* ---- 标题 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-title {
  font-size: 20px;
  font-weight: 600;
}

/* ---- #1 / #2 行：分隔线 + 下拉右对齐 ---- */
.pp-liquid-glass .new-sku-list[data-show="true"] {
  gap: 0 !important;
  padding: 0 14px 10px;
}

.pp-liquid-glass [data-sku-index] {
  padding: 10px 0;
  border-top: 1px solid rgba(0, 0, 0, 0.07);
}

/* 规格下拉整体推到右边（设计稿里 Color/Size 是右对齐的） */
.pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  /* basis 必须是 0 不能是 auto：父级 [data-sku-index] 开了 flex-wrap，
     basis:auto 会拿「内容宽度」(价格+两个下拉≈300px)去算换行，
     窄屏一超就把整块甩到下一行，变成 #1和缩略图一行、价格一行、下拉一行。
     basis:0 让它先占住剩余空间，再由自己内部换行。 */
  flex: 1 1 0;
  min-width: 0;
}

.pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
  margin-left: auto;
  justify-content: flex-end;
}

/* 子行价格：小一号，不跟主价抢 */
.pp-liquid-glass [data-sku-index] .product-promotion-item-price {
  font-size: 15px;
  font-weight: 600;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  margin: 0;
}

/* ---- 触发器：Color: White ▾ ——「标签: 值」都在药丸里 ---- */
.pp-liquid-glass .sku-title {
  border-radius: 999px;
  padding: 9px 32px 9px 14px;
  font-weight: 600;
  color: #111;
}

.pp-liquid-glass .new-sku-name {
  font-weight: 400;
  color: #444;
}

@media screen and (max-width: 768px) {
  /* 设计稿是 ~1450px 宽屏、一行到底。375px 上放不下
     radio + 图 + 标题 + 折扣药丸 + 徽章 + 价格 这六件，必须取舍：
     价格留在第一行右侧（它是决策信息），徽章降到第二行整行居中。 */
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-content {
    flex-wrap: wrap;
    row-gap: 10px;
    padding: 14px;
  }
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-right {
    order: 3;
    margin-left: auto;
  }
  .pp-liquid-glass .pp-badge-inline.recommend-style4 {
    order: 4;
    flex-basis: 100%;
    margin-right: 0;
    justify-content: center;
    padding: 5px 10px !important;
    font-size: 10px;
  }
  /* 标题和折扣药丸允许折行，但各自不许被拦腰断开 */
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-title {
    flex-wrap: wrap;
    gap: 8px;
    row-gap: 4px;
    font-size: 16px;
    white-space: nowrap;
  }
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-title-wrapper {
    min-width: 0;
  }
  /* xN 角标是 right:-8px，图片右边距太小会压到标题上 */
  .pp-liquid-glass
    .product-promotion-item-style4
    .product-promotion-item-image-left
    .product-promotion-item-image {
    margin-right: 14px;
  }
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-price {
    font-size: 17px;
    white-space: nowrap;
  }
  .pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
    gap: 6px;
    justify-content: flex-start;
  }
  .pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
    margin-left: 0;
    justify-content: flex-start;
  }
}

/* ---- 档位缩略图 + xN 角标 ---- */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-left .product-promotion-item-image {
  position: relative;
  border-radius: 12px;
  overflow: visible;
  flex-shrink: 0;
}

.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-left .product-promotion-item-image img {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* xN：蓝色圆形角标，贴在缩略图右上角（设计稿里的 x2 / x3） */
.pp-liquid-glass .pp-qty-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  min-width: 26px;
  height: 26px;
  padding: 0 6px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #6f8dff, #7a5cf0);
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 8px rgba(110, 110, 240, 0.4);
}

/* ---- #1 / #2 行的小缩略图 ---- */
.pp-liquid-glass .pp-sku-thumb {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 1px 4px rgba(0, 0, 0, 0.05);
}

.pp-liquid-glass .pp-sku-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-qty-badge {
    min-width: 22px;
    height: 22px;
    font-size: 10px;
    top: -6px;
    right: -6px;
  }
  .pp-liquid-glass .pp-sku-thumb {
    width: 40px;
    height: 40px;
  }
}


/* ================= 下拉：虹边玻璃 + 色轮触发器 =================
   虹边用和卡片同一套手法（渐变铺底 + mask-composite 挖空中心，只留描边）。
   不用 border-image：它和 border-radius 不兼容，圆角会被切成直角。 */

.pp-liquid-glass .sku-title,
.pp-liquid-glass .new-sku-wrap {
  isolation: isolate;
}

.pp-liquid-glass .sku-title::before,
.pp-liquid-glass .new-sku-wrap[data-open="true"]::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: linear-gradient(
    135deg,
    #a8d8ff 0%,
    #c9b6ff 25%,
    #ffc2e8 50%,
    #b6e3ff 75%,
    #d4c2ff 100%
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.55;
  transition: opacity 0.2s ease;
  z-index: 1;
}

/* 展开/悬停时虹边点亮 */
.pp-liquid-glass .sku-title:hover::before,
.pp-liquid-glass .sku-title[aria-expanded="true"]::before {
  opacity: 1;
}

.pp-liquid-glass .new-sku-wrap[data-open="true"]::before {
  opacity: 0.85;
}

/* 面板要能容纳 ::before 的绝对定位 */
.pp-liquid-glass .new-sku-wrap {
  position: absolute;
}

/* ---- 触发器里的色轮：替掉 "White" 文字 ----
   色块由 promotion-sku-dropdown.js 从已选中的 .new-sku-color 里克隆过来 ——
   颜色值在 my_fields.sku_color_map 元字段里，sku-color 组件已经解析并渲染过一次，
   这里没必要再解析一遍（重复解析 = 两套逻辑，元字段一改就会不同步）。 */
.pp-liquid-glass .pp-swatch {
  display: inline-flex;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid rgba(0, 0, 0, 0.18);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.6);
}

.pp-liquid-glass .pp-swatch .sku-color-item {
  width: 100%;
  height: 100%;
  display: flex;
}

.pp-liquid-glass .pp-swatch .sku-color-item-l,
.pp-liquid-glass .pp-swatch .sku-color-item-r {
  width: 50%;
  height: 100%;
}

.pp-liquid-glass .pp-swatch .sku-color-item-l {
  background-color: var(--skuBgL);
}

.pp-liquid-glass .pp-swatch .sku-color-item-r {
  background-color: var(--skuBgR);
}

/* 有色块时就不再重复显示颜色名 */
.pp-liquid-glass .sku-title.pp-has-swatch .new-sku-name {
  display: none;
}

/* ---- 整体收紧：字号、间距都降一档 ---- */
.pp-liquid-glass .sku-title {
  padding: 6px 26px 6px 10px;
  font-size: 12px;
  gap: 5px;
}

.pp-liquid-glass .sku-title::after {
  right: 10px;
}

.pp-liquid-glass [id^="new-sku-"] {
  gap: 6px;
}

.pp-liquid-glass [data-sku-index] {
  gap: 8px;
}

/* ---- 子行整体左对齐（编号 / 缩略图 / 价格 / 下拉 一路靠左）---- */
.pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
  justify-content: flex-start;
}

.pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
  margin-left: 0;
  justify-content: flex-start;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .sku-title {
    padding: 5px 22px 5px 8px;
    font-size: 11px;
  }
  .pp-liquid-glass .pp-swatch {
    width: 14px;
    height: 14px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price {
    font-size: 14px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price .product-promotion-item-old {
    font-size: 12px;
  }
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-price {
    font-size: 16px;
  }
  .pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-price .product-promotion-item-old {
    font-size: 13px;
  }
}


/* ================= 子行：编号/缩略图/价格/颜色/尺码 一行到底 =================
   375px 卡内宽约 319px，五件东西的预算：
   #1(18) + 缩略图(34) + 价格(68) + Color(78) + Size(74) + 4个间隙(24) ≈ 296px。
   余量只有 ~23px，所以下面每个尺寸都是算出来的，别随手加 padding。

   三层容器全部 nowrap + min-width:0：
   [data-sku-index] > .J-product-promotion-sku-wrapper > [id^="new-sku-"]
   任何一层漏了 min-width:0，里面的下拉就压不下去，会把整行顶破。 */

.pp-liquid-glass [data-sku-index],
.pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper,
.pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
  flex-wrap: nowrap;
  min-width: 0;
}

.pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
  flex: 1 1 auto;
}

.pp-liquid-glass [data-sku-index] .product-promotion-item-price {
  flex-shrink: 0;
}

.pp-liquid-glass [data-sku-index] [class*="new-sku-option-"] {
  min-width: 0;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass [data-sku-index] {
    gap: 6px;
    padding: 8px 0;
  }
  .pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
    gap: 6px;
  }
  .pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
    gap: 5px;
  }
  .pp-liquid-glass .promotion-number {
    font-size: 12px;
  }
  .pp-liquid-glass .pp-sku-thumb {
    width: 34px;
    height: 34px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price {
    font-size: 13px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price .product-promotion-item-old {
    font-size: 11px;
  }
  /* 触发器：箭头占 16px，左内边距 7px —— 再小点字就贴边了 */
  .pp-liquid-glass .sku-title {
    padding: 4px 18px 4px 7px;
    font-size: 10px;
    gap: 4px;
    border-radius: 9px;
  }
  .pp-liquid-glass .sku-title::after {
    right: 7px;
    width: 5px;
    height: 5px;
  }
  .pp-liquid-glass .new-sku-name {
    max-width: 42px;
    font-size: 10px;
  }
  .pp-liquid-glass .pp-swatch {
    width: 12px;
    height: 12px;
  }
}


/* ================= 子行再收紧一档 =================
   上一版 Size 药丸被卡片右边缘裁掉了 —— 说明预算还是超了。
   这里每一项都是在抠宽度，不是纯审美调整。 */

/* .promotion-number 自带 margin-right:12px（原主题的），
   和父级的 flex gap 叠加 = #1 和缩略图之间有 18px。gap 一个就够。 */
.pp-liquid-glass .promotion-number {
  margin-right: 0 !important;
}

/* 子行整体再往左：外层左内边距从 14px 降到 8px */
.pp-liquid-glass .new-sku-list[data-show="true"] {
  padding: 0 8px 8px;
}

.pp-liquid-glass [data-sku-index] {
  gap: 5px;
}

.pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
  gap: 5px;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .new-sku-list[data-show="true"] {
    padding: 0 6px 6px;
  }
  .pp-liquid-glass [data-sku-index] {
    gap: 4px;
    padding: 6px 0;
  }
  .pp-liquid-glass [data-sku-index] .J-product-promotion-sku-wrapper {
    gap: 4px;
  }
  .pp-liquid-glass [data-sku-index] [id^="new-sku-"] {
    gap: 4px;
  }
  .pp-liquid-glass .promotion-number {
    font-size: 11px;
  }
  .pp-liquid-glass .pp-sku-thumb {
    width: 30px;
    height: 30px;
    border-radius: 8px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price {
    font-size: 12px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price .product-promotion-item-old {
    font-size: 10px;
  }
}


/* ---- xN 角标被裁：外层容器也得放行 ----
   DOM 是 <div class="product-promotion-item-image product-promotion-item-image-left">
           <div class="product-promotion-item-image"> —— 外层同时带着两个类。
   之前只给内层开了 overflow:visible，但外层 -image-left 有原主题的
   overflow:hidden，角标 top:-8px 凸出去正好被它裁掉。
   整条链路都要放行，只解一环没用。 */
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-image-left,
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-content,
.pp-liquid-glass .product-promotion-item-style4 .product-promotion-item-title-wrapper {
  overflow: visible !important;
}


/* ================= 徽章：回到卡片右上角 =================
   原主题第 513 行有 `.recommend-style4 { position: absolute !important; }`。
   我之前写的 `position: static`（无 !important）压不过它 —— 徽章一直是绝对定位，
   加上我又写了 top:auto/right:auto，它就停在「原本该在的静态位置」但脱离文档流，
   正好压在标题上。要么带 !important 拉回文档流，要么顺着它把位置摆对。
   这里选后者：设计上徽章本来就该在右上角。 */
.pp-liquid-glass .pp-badge-inline.recommend-style4 {
  position: absolute !important;
  top: -11px !important;
  right: 16px !important;
  left: auto !important;
  bottom: auto !important;
  transform: none !important;
  margin-right: 0 !important;
  z-index: 3;
}

/* 徽章往上凸出 11px，卡片之间要腾出空间，否则会压到上一张卡。
   挂 pp-has-badge 而不是 recommend-style4-wrap —— 后者是 JS 的「选中标记」，
   借用它会让「有徽章」等于「被选中」。 */
.pp-liquid-glass .pp-has-badge {
  margin-top: 14px;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-badge-inline.recommend-style4 {
    top: -9px !important;
    right: 12px !important;
  }
  .pp-liquid-glass .pp-has-badge {
    margin-top: 12px;
  }
}

/* ---- 子行价格再降 1/3 ---- */
.pp-liquid-glass [data-sku-index] .product-promotion-item-price {
  font-size: 10px;
}
.pp-liquid-glass [data-sku-index] .product-promotion-item-price .product-promotion-item-old {
  font-size: 9px;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price {
    font-size: 9px;
  }
  .pp-liquid-glass [data-sku-index] .product-promotion-item-price .product-promotion-item-old {
    font-size: 8px;
  }
}


/* ================= 子行价格：字号 =================
   promotion.html 里有段内联 <style>：
     .new-sku-list[data-show='true'] .product-promotion-item-price { font-size: 20px }
   它是 (0,3,0)，和我原来的规则打平，但内联在 HTML 里、加载更晚 → 它赢。
   所以之前所有对子行现价的字号调整全部无效（划线价因为多一层类名侥幸生效了，
   于是现价 20px、划线价 8px，差了一倍多）。
   这里用 (0,4,0) 压过去，而不是甩 !important —— 后者会让下一个人更难覆盖。 */
.pp-liquid-glass .new-sku-list[data-show="true"] [data-sku-index] .product-promotion-item-price {
  font-size: 12px;
  font-weight: 600;
}

.pp-liquid-glass
  .new-sku-list[data-show="true"]
  [data-sku-index]
  .product-promotion-item-price
  .product-promotion-item-old {
  font-size: 10px;
}


/* ================= 徽章与价格的间距 =================
   展开的卡片里标题行贴着卡片顶边，徽章(top:-11px, 高约 22px)的下半截正好落在
   价格上，两者挤在一起。收起的卡因为内容垂直居中、上下有余量，看不出来。

   两件事一起做，缺一不可：
   - 徽章再往上提 → 减少它伸进卡片里的部分
   - 有徽章的卡，标题行加顶部内边距 → 价格自己也往下让
   只提徽章的话价格仍然贴着顶边，只加内边距的话徽章还是压在价格上方。 */

.pp-liquid-glass .pp-badge-inline.recommend-style4 {
  top: -15px !important;
}

.pp-liquid-glass .pp-has-badge {
  margin-top: 20px;
}

.pp-liquid-glass .pp-has-badge .product-promotion-item-content {
  padding-top: 22px;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-badge-inline.recommend-style4 {
    top: -13px !important;
  }
  .pp-liquid-glass .pp-has-badge {
    margin-top: 17px;
  }
  .pp-liquid-glass .pp-has-badge .product-promotion-item-content {
    padding-top: 19px;
  }
}


/* ================= 下拉面板：绝不影响行布局 =================
   现象：展开后 Color 触发器整个跳到行顶，#1/价格/Size 掉到面板的垂直中间 ——
   这是「面板还在文档流里把行撑高、其余元素 align-items:center 居中到中间」的典型表现。

   CSS 上 .pp-liquid-glass .new-sku-wrap 已经是 position:absolute（(0,2,0)，
   压得过组件内联那条 (0,1,0) 的 position:relative），线上文件也逐字节核对过。
   静态查不出为什么没生效，所以这里用 !important 兜底 ——
   不是因为想清楚了，是因为「面板影响布局」这件事本身不可接受，
   宁可用一条粗暴但确定的规则挡住。 */
.pp-liquid-glass .new-sku-wrap {
  position: absolute !important;
}

/* 选项容器只包触发器，高度不许被面板带跑 */
.pp-liquid-glass [data-sku-index] [class*="new-sku-option-"] {
  align-self: center;
  height: auto;
}

/* ================= 选项：色块回正圆 + 选中态虹边 =================
   原主题的 .new-sku-color::before 是 width/height:100% + border-radius:50%
   的「描边圈」。平铺时 .new-sku-color 是个小方块，圈就是正圆；
   但下拉面板里我把每个选项拉成了整行（width:100%），100% 宽的 50% 圆角
   = 一个横向大椭圆，而且描边是 var(--theme-color)（你的站上是黑）。
   两个问题一起解：圈不再画在整行上，改画在色块自己身上，并换成虹边。 */

/* 整行上的那个椭圆圈：直接废掉 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > .new-sku-color::before,
.pp-liquid-glass .new-sku-wrap[data-open="true"] > .new-sku-color:hover::before,
.pp-liquid-glass .new-sku-wrap[data-open="true"] > .new-sku-color[check="true"]::before {
  display: none !important;
}

/* 原主题在选中项右上角点了个红点（[check=true]::after），下拉里不需要 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > .new-sku-color[check="true"]::after {
  display: none !important;
}

/* 色块本体：固定正圆，不跟着行宽走 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] sku-color {
  flex: 0 0 auto;
}

.pp-liquid-glass .new-sku-wrap[data-open="true"] .sku-color-item {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.15);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.5);
  overflow: hidden;
}

/* 选中态：统一蓝色系描边 + 浅蓝底。
   颜色项和尺码项走同一条规则，不再各自一套。

   color 必须显式写死：组件里
     .new-sku-block[check='true'] { background-color: var(--theme-color); color: #fff }
   只盖掉背景不动 color 的话，白字会落在浅色底上 —— 选中项直接看不见。 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] > [check="true"] {
  position: relative;
  background: rgba(59, 111, 224, 0.1) !important;
  border: 1.5px solid #3b6fe0 !important;
  color: #111827 !important;
  font-weight: 600;
}


/* ---- 下拉面板被折叠容器裁掉 ----
   .product-promotion-item-sku-content 有 overflow:hidden（第 284 / 407 行两条）。
   面板是 position:absolute 且要溢出到容器外，正好被它切掉。

   放行是安全的：这里的「折叠」是 [data-check] 切 display:none/block，
   不是 max-height 动画 —— overflow:hidden 对折叠没有任何作用，
   它只是原样式给 style1/2/3 圆角裁图用的，style4 用不到。 */
.pp-liquid-glass .product-promotion-item-sku-content {
  overflow: visible !important;
}

.pp-liquid-glass .new-sku-list {
  overflow: visible;
}

/* 面板自身仍然可以滚（选项多时），这是它自己的滚动条，不影响外溢 */
.pp-liquid-glass .new-sku-wrap[data-open="true"] {
  max-height: 240px;
}


/* ---- 展开中的那一行抬到最上层 ----
   组件里 .new-sku-item { position: relative } —— 每个选项都是定位元素，
   相邻行的选项会和面板抢绘制顺序。只调面板自己的 z-index 不稳，
   把整行抬起来才是确定的做法（面板溢出到行外，跟着行一起抬）。 */
.pp-liquid-glass [data-sku-index]:has(.new-sku-wrap[data-open="true"]) {
  position: relative;
  z-index: 60;
}

.pp-liquid-glass .new-sku-wrap[data-open="true"] {
  z-index: 61;
}

/* 展开中的卡片也要盖过下面的卡片（面板会溢出到卡外） */
.pp-liquid-glass .product-promotion-item-style4:has(.new-sku-wrap[data-open="true"]) {
  z-index: 20;
}

/* ================= 倒计时 ================= */
.pp-liquid-glass .pp-countdown {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 auto 14px;
  width: max-content;
  max-width: 100%;
  padding: 8px 18px;
  border-radius: 999px;
  position: relative;
  isolation: isolate;
  background: rgba(255, 255, 255, 0.6);
  -webkit-backdrop-filter: blur(10px) saturate(160%);
  backdrop-filter: blur(10px) saturate(160%);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 10px rgba(31, 38, 135, 0.08);
  font-size: 13px;
  letter-spacing: 0.04em;
}

/* 虹边：和卡片/触发器/按钮同一套 mask 手法 */
.pp-liquid-glass .pp-countdown::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: linear-gradient(
    135deg,
    #a8d8ff 0%,
    #c9b6ff 25%,
    #ffc2e8 50%,
    #b6e3ff 75%,
    #d4c2ff 100%
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 1;
}

.pp-liquid-glass .pp-countdown-label {
  font-weight: 600;
  color: #2b2b45;
}

.pp-liquid-glass .pp-countdown-time {
  font-weight: 700;
  color: #5b5bd6;
  /* 等宽数字：不加的话秒数每跳一下整条都在抖 */
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  min-width: 44px;
  text-align: left;
}

.pp-liquid-glass .pp-countdown[data-expired="true"] .pp-countdown-time {
  color: #9aa0b4;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-countdown {
    font-size: 11px;
    padding: 6px 14px;
    gap: 6px;
    margin-bottom: 10px;
  }
  .pp-liquid-glass .pp-countdown-time {
    min-width: 38px;
  }
}

/* ---- 倒计时嵌进徽章槽位：外层药丸已经由 .recommend-style4 提供，
       这里把独立形态那套（自己的药丸底、虹边、内边距）全部收掉，
       否则会变成「药丸里套药丸」。 ---- */
.pp-liquid-glass .pp-countdown--inline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  width: auto;
  max-width: none;
  border-radius: 0;
  background: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  box-shadow: none;
  font-size: inherit;
  letter-spacing: inherit;
  isolation: auto;
}

.pp-liquid-glass .pp-countdown--inline::before {
  display: none;
}

/* 倒计时药丸比 "Most Popular" 长，右侧留白收窄一点免得顶出卡片 */
.pp-liquid-glass .pp-badge-countdown {
  right: 10px !important;
}

.pp-liquid-glass .pp-badge-countdown .pp-countdown-label {
  color: inherit;
  font-weight: 600;
}

.pp-liquid-glass .pp-badge-countdown .pp-countdown-time {
  color: #5b5bd6;
  font-weight: 700;
  min-width: 40px;
}

/* 徽章的 ::before 是个 ◆，倒计时换成时钟更贴题 */
.pp-liquid-glass .pp-badge-inline.pp-badge-countdown::before {
  content: "⏱";
  font-size: 12px;
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-badge-countdown {
    right: 8px !important;
  }
  .pp-liquid-glass .pp-badge-countdown .pp-countdown-time {
    min-width: 34px;
  }
}

/* ================= 档位上方的文字线 =================
   「──── The offer ends tonight! ────」*/
.pp-liquid-glass .pp-offer-heading {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 16px;
}

.pp-liquid-glass .pp-offer-heading::before,
.pp-liquid-glass .pp-offer-heading::after {
  content: "";
  flex: 1;
  height: 1.5px;
  border-radius: 2px;
  min-width: 20px;
}

/* 两侧的线各自从透明渐入，靠近文字的一端最实 —— 直接铺满色会显得很硬 */
.pp-liquid-glass .pp-offer-heading::before {
  background: linear-gradient(to right, rgba(168, 216, 255, 0), #a8d8ff, #c9b6ff);
}

.pp-liquid-glass .pp-offer-heading::after {
  background: linear-gradient(to left, rgba(212, 194, 255, 0), #d4c2ff, #ffc2e8);
}

.pp-liquid-glass .pp-offer-heading-text {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  /* 渐变文字：比虹边那套深一档。
     虹边用的浅色(#a8d8ff 等)是画在描边上的，铺到文字上会糊得看不清。 */
  background: linear-gradient(120deg, #5a9dff 0%, #7c5cf0 40%, #d95fb0 75%, #7c5cf0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

/* 关掉渐变时用后台取色器的纯色 */
.pp-liquid-glass .pp-offer-heading--solid .pp-offer-heading-text {
  background: none;
  color: var(--pp-heading-color, #2b2b45);
  -webkit-text-fill-color: var(--pp-heading-color, #2b2b45);
}

@media screen and (max-width: 768px) {
  .pp-liquid-glass .pp-offer-heading {
    gap: 10px;
    margin-bottom: 12px;
  }
  .pp-liquid-glass .pp-offer-heading-text {
    font-size: 14px;
    white-space: normal;
    text-align: center;
  }
}
