/* Added-to-cart popup polish — scoped to #product_cart_popup only */
#product_cart_popup .new_product_popup_addCart {
  --cp-ink: #1a1d21;
  --cp-muted: #6b7280;
  --cp-line: #e6e8eb;
  --cp-soft: #f3f4f6;
  --cp-red: #dc3737;
  --cp-red-hover: #c42f2f;
  --cp-ok: #15803d;
  --cp-radius: 10px;
}

/* Above Tidio chat widget (typically ~999999999) */
#product_cart_popup .new_popup {
  z-index: 2147483000 !important;
}

#product_cart_popup .new_popup_main {
  z-index: 2147483001 !important;
}

body.cart-popup-open #tidio-chat,
body.cart-popup-open #tidio-chat-iframe,
body.cart-popup-open iframe[id^="tidio"] {
  z-index: 1 !important;
  pointer-events: none !important;
}

#product_cart_popup .new_popup_bg {
  background: rgba(17, 20, 24, 0.48) !important;
  backdrop-filter: blur(2px);
}

#product_cart_popup .new_popup_main.change_poput_width1100,
#product_cart_popup .new_popup_main.popup_width680 {
  width: 960px !important;
  max-width: calc(100vw - 48px) !important;
  border-radius: var(--cp-radius) !important;
  overflow: hidden;
  box-shadow: 0 16px 48px rgba(26, 29, 33, 0.18) !important;
  border: 1px solid var(--cp-line);
  background: #fff;
}

#product_cart_popup .new_popup_addCart_tit.new_popup_changeTit01 {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 !important;
  padding: 18px 22px !important;
  border-bottom: 1px solid var(--cp-line) !important;
  background: #fff !important;
  box-sizing: border-box;
  position: relative;
}

#product_cart_popup .new_popup_addCart_tit:after {
  display: none !important;
  content: none !important;
}

#product_cart_popup .new_popup_addCart_tit .addCrat_item_number {
  display: inline-flex !important;
  align-items: center;
  gap: 10px;
  margin: 0 !important;
  font-weight: 600;
  flex: 1 1 auto;
  min-width: 0;
}

#product_cart_popup .new_popup_addCart_tit .addCrat_item_number .icon_dui {
  float: none !important;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e8f7ee;
  color: var(--cp-ok) !important;
  font-size: 16px !important;
  line-height: 28px !important;
  text-align: center;
}

#product_cart_popup .addCrat_item_number .addCrat_item_numberTit {
  font-size: 18px !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  color: var(--cp-ink) !important;
  vertical-align: middle;
}

#product_cart_popup .addCrat_item_numberTit .addCrat_item_count {
  color: var(--cp-muted);
  font-weight: 500;
  margin-left: 4px;
}

#product_cart_popup .new_popup_addCart_tit > .icon_guanbi,
#product_cart_popup .new_popup_addCart_tit .icon.icon_guanbi {
  flex: 0 0 auto !important;
  float: none !important;
  margin-left: auto !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 6px;
  color: var(--cp-muted) !important;
  font-size: 18px !important;
  line-height: 32px !important;
  text-align: center !important;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

#product_cart_popup .new_popup_addCart_tit > .icon_guanbi:hover,
#product_cart_popup .new_popup_addCart_tit .icon.icon_guanbi:hover {
  background: var(--cp-soft);
  color: var(--cp-ink) !important;
}

#product_cart_popup .listmain_box {
  background: #fff;
}

#product_cart_popup .addCrat_item_listMain01 {
  max-height: 360px !important;
  overflow: auto !important;
}

#product_cart_popup .addCrat_item_listMain01 .new_popup_content.addCart_cont,
#product_cart_popup .new_popup_content.addCart_cont {
  padding: 12px 22px 8px !important;
}

#product_cart_popup .addCrat_item_listTa {
  padding-top: 0 !important;
  padding-right: 0 !important;
}

#product_cart_popup .cartpro_item {
  display: grid !important;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "main qty"
    "main del";
  gap: 8px 16px;
  align-items: start;
  margin: 0 0 12px;
  padding: 14px 0 !important;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-sizing: border-box;
}

#product_cart_popup .cartpro_item:last-child {
  margin-bottom: 4px;
}

#product_cart_popup .addCrat_item_listTa .addCrat_item_list_top {
  grid-area: main;
  display: flex !important;
  width: auto !important;
  padding: 0 !important;
  gap: 14px;
  align-items: flex-start;
}

#product_cart_popup .addCrat_left,
#product_cart_popup #video_img {
  flex: 0 0 72px;
  width: 72px !important;
  height: 72px;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0;
  background: transparent;
  overflow: hidden;
  box-sizing: border-box;
}

#product_cart_popup .addCrat_left a,
#product_cart_popup #video_img a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

#product_cart_popup .addCrat_left img,
#product_cart_popup #video_img img {
  width: 100% !important;
  height: 100% !important;
  max-width: 72px;
  max-height: 72px;
  object-fit: contain;
}

#product_cart_popup .addCrat_item_listTa .addCrat_item_list_top .addCrat_right {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0 !important;
}

#product_cart_popup .addCrat_item_list_tit a {
  font-size: 14px !important;
  font-weight: 600 !important;
  line-height: 1.4 !important;
  color: var(--cp-ink) !important;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

#product_cart_popup .addCrat_item_list_top .Qty_num02 {
  margin: 4px 0 0;
  padding: 0 !important;
  font-size: 12px;
  color: var(--cp-muted) !important;
  line-height: 1.4 !important;
}

#product_cart_popup .addCrat_item_listTa .addCrat_item_list_Quantity {
  grid-area: qty;
  display: flex !important;
  flex-direction: column;
  align-items: flex-end;
  width: auto !important;
  padding: 0 !important;
  text-align: right !important;
  position: static !important;
}

#product_cart_popup .addCrat_item_listTa .addCrat_item_list_Quantity > span {
  float: none !important;
  width: auto !important;
}

#product_cart_popup .addCrat_item_listTa .addCart_pro_price {
  margin: 0 0 8px !important;
  float: none !important;
}

#product_cart_popup .popup_cart_price {
  font-size: 15px !important;
  font-weight: 700 !important;
  color: var(--cp-red) !important;
  line-height: 1.2 !important;
}

#product_cart_popup .product_list_text {
  margin: 0 !important;
  float: none !important;
}

/* Qty: minus | input | plus (horizontal) */
#product_cart_popup .addCrat_item_list_Quantity .product_list_text > span {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center;
  height: 36px !important;
  width: 118px !important;
  padding: 0 !important;
  border: 1px solid var(--cp-line);
  border-radius: 6px;
  background: #fff;
  box-sizing: border-box;
  overflow: visible !important;
}

#product_cart_popup .product_list_qty {
  position: relative !important;
  z-index: 1;
  float: none !important;
  width: 48px !important;
  height: 34px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  text-align: center !important;
  font-size: 14px !important;
  font-weight: 600;
  color: var(--cp-ink);
  background: transparent !important;
  box-sizing: border-box;
  line-height: 34px !important;
}

#product_cart_popup .pro_mun {
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  top: 0 !important;
  bottom: 0 !important;
  z-index: 2;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  float: none !important;
  overflow: visible !important;
  max-height: none !important;
  pointer-events: none;
}

#product_cart_popup .pro_mun .cart_qty_add,
#product_cart_popup .pro_mun .cart_qty_reduce,
#product_cart_popup .cart_qty_add,
#product_cart_popup .cart_qty_reduce {
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  -webkit-transform: translateY(-50%) scale(1) !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 28px !important;
  height: 28px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 4px !important;
  background: transparent !important;
  color: var(--cp-ink) !important;
  font-size: 12px !important;
  line-height: 28px !important;
  text-align: center !important;
  cursor: pointer;
  pointer-events: auto;
  float: none !important;
}

#product_cart_popup .pro_mun .cart_qty_reduce,
#product_cart_popup .cart_qty_reduce {
  left: 4px !important;
  right: auto !important;
}

#product_cart_popup .pro_mun .cart_qty_add,
#product_cart_popup .cart_qty_add {
  right: 4px !important;
  left: auto !important;
}

#product_cart_popup .pro_mun .cart_qty_add:hover,
#product_cart_popup .pro_mun .cart_qty_reduce:hover {
  background: var(--cp-soft) !important;
}

#product_cart_popup .addCrat_item_listTa .addCrat_item_list_delete {
  display: none !important;
}

#product_cart_popup .new_popup_addCart_bottom {
  padding: 16px 22px 20px !important;
  background: #fff !important;
  border-top: 1px solid var(--cp-line) !important;
  text-align: right !important;
}

#product_cart_popup .new_popup_addCart_bottom > div.clearfix {
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: 14px;
}

#product_cart_popup .new_popup_addCart_bottom > div.clearfix > span {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

#product_cart_popup .new_popup_addCart_bottomTit02,
#product_cart_popup .cart_total {
  font-size: 18px !important;
  font-weight: 700 !important;
  color: var(--cp-ink) !important;
  line-height: 1.2 !important;
}

#product_cart_popup .new_popup_addCart_bottomLine {
  display: none !important;
}

#product_cart_popup .new_popup_addCart_bottomLink {
  font-size: 13px !important;
  font-weight: 600;
  color: #0070bc !important;
  text-decoration: none;
}

#product_cart_popup .new_popup_addCart_bottomMain {
  margin-top: 0 !important;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn {
  display: flex !important;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn > a,
#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btnG01,
#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn01 {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 160px !important;
  height: 42px !important;
  margin: 0 !important;
  padding: 0 18px !important;
  border-radius: 6px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  text-decoration: none !important;
  box-sizing: border-box;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btnG01 {
  background: #fff !important;
  color: var(--cp-ink) !important;
  border: 1px solid var(--cp-line) !important;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btnG01:hover {
  border-color: #c9ced6 !important;
  background: var(--cp-soft) !important;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn01 {
  background: var(--cp-red) !important;
  color: #fff !important;
  border: 1px solid var(--cp-red) !important;
}

#product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn01:hover {
  background: var(--cp-red-hover) !important;
  border-color: var(--cp-red-hover) !important;
}

#product_cart_popup .new_popup_addCart_bottomMain .mg_left10 {
  margin-left: 0 !important;
}

@media screen and (max-width: 1025px) {
  #product_cart_popup .new_product_popup_addCart {
    align-items: flex-end !important;
  }

  #product_cart_popup .new_popup_main.change_poput_width1100,
  #product_cart_popup .new_popup_main.popup_width680,
  #product_cart_popup .new_popup_main.pupop_video.popup_width680.change_poput_width1100,
  #product_cart_popup .new_product_popup_addCart .new_popup_main.pupop_video.popup_width680 {
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    top: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: min(88vh, 720px) !important;
    margin: 0 !important;
    transform: none !important;
    border-radius: 14px 14px 0 0 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden;
  }

  #product_cart_popup .new_popup_addCart_tit.new_popup_changeTit01 {
    padding: 14px 16px !important;
    flex: 0 0 auto;
  }

  #product_cart_popup .addCrat_item_number .addCrat_item_numberTit {
    font-size: 16px !important;
  }

  #product_cart_popup .listmain_box {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none !important;
    height: auto !important;
    overflow: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  #product_cart_popup .addCrat_item_listMain01 {
    max-height: none !important;
    height: auto !important;
  }

  #product_cart_popup .addCrat_item_listMain01 .new_popup_content.addCart_cont,
  #product_cart_popup .listmain_box .new_popup_content.addCart_cont,
  #product_cart_popup .new_popup_content.addCart_cont {
    padding: 10px 12px 8px !important;
  }

  #product_cart_popup .cartpro_item {
    grid-template-columns: 1fr;
    grid-template-areas:
      "main"
      "qty";
    gap: 10px;
    padding: 12px !important;
    margin-bottom: 10px;
  }

  #product_cart_popup .addCrat_item_listTa .addCrat_item_list_Quantity {
    grid-area: qty;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100% !important;
    text-align: left !important;
    padding: 0 !important;
    position: static !important;
  }

  #product_cart_popup .addCrat_item_listTa .addCart_pro_price {
    margin: 0 !important;
  }

  #product_cart_popup .addCrat_item_listTa .addCrat_item_list_delete {
    display: none !important;
  }

  #product_cart_popup .cartpro_item {
    position: relative;
  }

  #product_cart_popup .addCrat_left,
  #product_cart_popup #video_img {
    flex-basis: 64px;
    width: 64px !important;
    height: 64px;
  }

  #product_cart_popup .addCrat_left img,
  #product_cart_popup #video_img img {
    max-width: 64px;
    max-height: 64px;
  }

  #product_cart_popup .new_popup_addCart_bottom {
    flex: 0 0 auto;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)) !important;
    box-shadow: 0 -6px 20px rgba(26, 29, 33, 0.06);
  }

  #product_cart_popup .new_popup_addCart_bottom > div.clearfix {
    justify-content: space-between;
    margin-bottom: 12px;
  }

  #product_cart_popup .new_popup_addCart_bottom > div.clearfix > span {
    width: 100%;
    justify-content: space-between;
  }

  #product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn {
    flex-direction: column;
    gap: 8px;
  }

  #product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn > a,
  #product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btnG01,
  #product_cart_popup .new_popup_addCart_bottomMain .fm_customer_btn01 {
    width: 100% !important;
    min-width: 0 !important;
    margin-bottom: 0 !important;
  }
}
