/* StoreWeave v1.3.23 — CommerceKit Wishlist / Purchase actions.
 * 只处理原生购买表单的直接子元素；不打开跨 Hook HTML 容器。
 * 价格卡、数量控件、Rewards 兑换按钮继续由各自模块输出。
 */
body.single-product .summary .swc-tier-pricing-slot[hidden] { display: none !important; }

/* v1.3.31: Single-border quantity shell inside the native Woo quantity. 
 * The native .quantity no longer paints a border; the dedicated shell is its sole visual frame.
 * No JS wraps the default Woo input on first paint. */
body.single-product .summary .swc-quantity-stage--inline{
  display:flex;flex-flow:row wrap;align-items:center;justify-content:flex-start;
  gap:var(--swc-label-gap,6px);width:100%;min-width:0;max-width:100%;
  margin:var(--swc-quantity-top,8px) 0 var(--swc-quantity-bottom,12px);
  padding:0;clear:both;float:none;box-sizing:border-box
}
body.single-product .summary .swc-quantity-stage--inline>.swc-quantity-stage__label{
  display:block;flex:0 0 auto;margin:0;padding:0;color:var(--sw-text,#1f2937);
  font-size:var(--diyyarn-field-heading-size,16px)!important;
  font-weight:var(--diyyarn-field-heading-weight,600)!important;
  line-height:var(--diyyarn-field-heading-line-height,1.35)!important
}
body.single-product .summary .swc-quantity-stage--inline>.swc-quantity-stage__control{
  display:inline-flex;align-items:center;flex-flow:row wrap;justify-content:flex-start;
  flex:0 1 auto;gap:8px;width:auto;min-width:0;
  margin:0;padding:0;overflow:visible
}
body.single-product .summary .swc-quantity-stage--inline .quantity{
  display:inline-flex!important;flex-flow:row nowrap;align-items:stretch;position:relative;
  flex:0 1 var(--swc-qty-width,168px);float:none!important;
  width:var(--swc-qty-width,168px)!important;max-width:100%!important;
  height:var(--swc-qty-height,44px)!important;min-height:0!important;
  margin:0!important;padding:0!important;border:0!important;
  border-radius:0!important;outline:0!important;box-shadow:none!important;
  background:transparent!important;overflow:visible!important;box-sizing:border-box!important
}
body.single-product .summary .swc-quantity-stage--inline .quantity::before,
body.single-product .summary .swc-quantity-stage--inline .quantity::after{
  display:none!important;content:none!important;border:0!important;box-shadow:none!important
}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-shell{
  display:flex!important;flex-flow:row nowrap;align-items:stretch;
  flex:1 1 100%;width:100%;min-width:0;max-width:100%;
  height:100%;min-height:0;margin:0;padding:0;
  background:var(--sw-surface,#fff);border:1px solid var(--sw-border,#d2d8e0);border-radius:var(--swc-qty-radius,9px);
  outline:0;box-shadow:none;overflow:hidden;box-sizing:border-box;
}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-shell::before,
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-shell::after{content:none!important;display:none!important}
body.single-product .summary .swc-quantity-stage--inline .quantity input.qty{
  display:block!important;order:2;flex:1 1 34%;float:none!important;
  min-width:0!important;width:34%!important;max-width:none!important;
  height:100%!important;min-height:0!important;
  margin:0!important;padding:0 2px!important;border:0!important;border-radius:0!important;
  outline:0!important;background:transparent!important;box-shadow:none!important;
  text-align:center!important;font-family:inherit!important;font-size:16px!important;
  font-weight:500!important;line-height:normal!important;appearance:textfield!important;-moz-appearance:textfield!important
}
body.single-product .summary .swc-quantity-stage--inline .quantity input.qty::-webkit-inner-spin-button,
body.single-product .summary .swc-quantity-stage--inline .quantity input.qty::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
/* Themes such as Shoptimizer append their own .quantity-nav after the Woo input.
   Hiding only its .plus / .minus children leaves an empty, bordered nav box on the right.
   Suppress the WHOLE native navigation wrapper, but only when Storefront's shell is present.
   If the Woo template doesn't run Storefront hooks, native controls remain usable until
   quantity-controls.js installs the shell. Scoped to product summary, not cart/mini-cart. */
body.single-product .summary .swc-quantity-stage--inline .quantity:has(> .swc-qty-shell) > :is(
  .quantity-nav, .quantity-navigation, .quantity-buttons, .quantity-arrows
){display:none!important;visibility:hidden!important;flex:0 0 0!important;width:0!important;height:0!important;margin:0!important;padding:0!important;border:0!important;box-shadow:none!important;}
body.single-product .summary .swc-quantity-stage--inline .quantity:has(> .swc-qty-shell) :is(.plus,.minus,.qty-plus,.qty-minus,.quantity-button):not(.swc-qty-button){display:none!important}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button{
  display:flex!important;align-items:center;justify-content:center;order:1;
  flex:1 1 33%;min-width:0!important;width:auto!important;
  height:100%!important;min-height:0!important;
  margin:0!important;padding:var(--swc-qty-padding-y,1px) 0!important;border:0!important;border-radius:0!important;
  background:transparent!important;color:var(--sw-text,#445166)!important;box-shadow:none!important;
  outline:0!important;font-family:inherit;font-size:21px;font-weight:400;
  line-height:1!important;cursor:pointer
}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-plus{order:3}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button::before,
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button::after{content:none!important;display:none!important}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button:hover:not(:disabled){background:var(--sw-surface-alt,#f1f5f8)!important}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button:disabled{opacity:.35;cursor:not-allowed}
body.single-product .summary .swc-quantity-stage--inline .quantity .swc-qty-button:focus-visible,
body.single-product .summary .swc-quantity-stage--inline .quantity input.qty:focus-visible{outline:2px solid var(--sw-focus,#138da0)!important;outline-offset:-3px!important}
/* Mobile Quantity preset: desktop inline dimensions remain unchanged, no JS resize/reparent. */
@media (max-width:767px){
 body.single-product .summary .swc-quantity-stage--inline .quantity{
   width:var(--swc-qty-width-mobile,168px)!important;
   flex-basis:var(--swc-qty-width-mobile,168px);
   height:var(--swc-qty-height-mobile,44px)!important;
 }
}
/* Unified labels: Woo native dropdown + variant grid + tier + quantity, including their descendants. */
body.single-product .summary form.cart .variations :is(th.label,th.label>label,th.label>label>span),
body.single-product .summary form.cart .variations td.label>label,
body.single-product .summary section.sw-tier-box>h3{
  font-size:var(--diyyarn-field-heading-size,16px)!important;
  font-weight:var(--diyyarn-field-heading-weight,600)!important;
  line-height:var(--diyyarn-field-heading-line-height,1.35)!important;
  letter-spacing:0;text-transform:none
}
body.single-product .summary .swc-quantity-stage--standard{display:block}
body.single-product .summary .swc-quantity-stage--standard>.swc-quantity-stage__label{margin-bottom:var(--swc-label-gap,6px)}
body.single-product .summary .swc-quantity-stage--standard>.swc-quantity-stage__control{display:flex;width:100%}
body.single-product .summary .swc-quantity-stage:has(input[name="quantity"][type="hidden"]){display:none!important}
@media(max-width:480px){
 body.single-product .summary .swc-quantity-stage--inline>.swc-quantity-stage__control{gap:7px}
 body.single-product .summary .swc-quantity-stage--inline .quantity input.qty{font-size:15px!important}
}

/* A single eligible container owns Add to Cart and the native CommerceKit wishlist.
   Includes CommerceKit Sticky ATC's real intersector sibling hierarchy. */
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-quantity-stage):not(:has(> .swc-wishlist-native)) {
  display:flex !important; flex-direction:column !important; align-items:stretch !important;
  flex-wrap:nowrap !important; width:100%; min-width:0; max-width:100%;
}
body.single-product .summary .swc-quantity-stage,
body.single-product .summary .swc-ppc {
  flex:none; align-self:stretch; width:100%; min-width:0; max-width:100%; box-sizing:border-box;
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native) {
  display:flex !important; flex-flow:row wrap !important; align-items:stretch !important;
  justify-content:flex-start !important; gap:0 var(--swc-wish-gap,12px) !important;
  width:100%; min-width:0; max-width:100%; box-sizing:border-box;
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native)::before,
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native)::after {
  display:none !important; content:none !important;
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native) > :not(.swc-wishlist-native):not(.single_add_to_cart_button):not(.added_to_cart) {
  flex:0 0 100%; min-width:0; max-width:100%; box-sizing:border-box;
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native) > .single_add_to_cart_button {
  float:none !important; clear:none !important; position:relative; order:10;
  flex:1 1 0 !important; width:auto !important; min-width:0 !important; max-width:none !important;
  margin:0 !important; padding-inline:12px; align-self:stretch; box-sizing:border-box;
  /* Background, color, border, actual height: inherited from Shoptimizer. */
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native) > .swc-wishlist-native {
  order:11;
  flex:0 0 var(--swc-wish-render-size, var(--swc-wish-size,58px)) !important;
  width:var(--swc-wish-render-size, var(--swc-wish-size,58px)) !important;
  height:var(--swc-wish-render-size, var(--swc-wish-size,58px)) !important;
  min-width:var(--swc-wish-render-size, var(--swc-wish-size,58px)) !important;
  max-width:var(--swc-wish-render-size, var(--swc-wish-size,58px)) !important;
  min-height:0 !important; max-height:none;
  align-self:center; box-sizing:border-box;
}
body.single-product .summary :is(form.cart, .woocommerce-variation-add-to-cart, .commercekit-sticky-atc-intersector):has(> .swc-wishlist-native) > .added_to_cart {
  order:12; flex:0 0 100%; min-width:0; box-sizing:border-box;
}
body.single-product .summary .swc-wishlist-native {
  display:flex; position:relative; padding:0 !important; margin:0 !important;
  float:none !important; overflow:visible; box-sizing:border-box;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full {
  display:flex !important; flex:1 1 auto; align-items:stretch;
  position:static !important; width:100% !important; min-width:0; max-width:100%; height:100%;
  margin:0 !important; padding:0 !important; float:none !important; box-sizing:border-box;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a.commercekit-save-wishlist,
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a.commercekit-browse-wishlist {
  display:flex !important; position:relative; flex:1 1 auto; align-items:center; justify-content:center;
  width:100% !important; min-width:0; max-width:100%; height:100% !important; min-height:0 !important;
  padding:0 !important; margin:0 !important;
  border:1px solid var(--swc-wish-border,#aeb6bf) !important;
  border-radius:var(--swc-wish-radius,10px) !important;
  background:#fff !important; color:#222 !important; box-sizing:border-box;
  text-decoration:none !important; font-size:0 !important; line-height:1 !important;
  cursor:pointer; box-shadow:none !important;
  transition:border-color .16s ease,box-shadow .16s ease;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a > span {
  position:absolute !important; width:1px !important; height:1px !important;
  margin:-1px !important; padding:0 !important; border:0 !important;
  overflow:hidden !important; clip:rect(0,0,0,0); white-space:nowrap;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a em {
  display:block !important; position:relative !important;
  flex:0 0 var(--swc-wish-icon-size,26px);
  width:var(--swc-wish-icon-size,26px) !important;
  height:var(--swc-wish-icon-size,26px) !important;
  margin:0 !important; padding:0 !important; color:inherit !important;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a em::before {
  display:block !important; content:"" !important; position:absolute !important;
  inset:0 !important; width:100% !important; height:100% !important;
  background-color:currentColor !important; transform:none !important;
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20.8 4.6a5.5 5.5 0 0 0-7.8 0L12 5.7l-1.1-1.1a5.5 5.5 0 0 0-7.8 7.8L12 21l8.8-8.6a5.5 5.5 0 0 0 0-7.8Z' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E") center / contain no-repeat !important;
  mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20.8 4.6a5.5 5.5 0 0 0-7.8 0L12 5.7l-1.1-1.1a5.5 5.5 0 0 0-7.8 7.8L12 21l8.8-8.6a5.5 5.5 0 0 0 0-7.8Z' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E") center / contain no-repeat !important;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a.commercekit-browse-wishlist {
  color:var(--swc-wish-active,#eb1b69) !important;
}
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a.commercekit-browse-wishlist em::before {
  -webkit-mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21.15 10.55 19.83C5.4 15.16 2 12.08 2 8.3 2 5.22 4.42 2.8 7.5 2.8c1.74 0 3.41.81 4.5 2.09A5.98 5.98 0 0 1 16.5 2.8C19.58 2.8 22 5.22 22 8.3c0 3.78-3.4 6.86-8.55 11.54L12 21.15Z'/%3E%3C/svg%3E") !important;
  mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21.15 10.55 19.83C5.4 15.16 2 12.08 2 8.3 2 5.22 4.42 2.8 7.5 2.8c1.74 0 3.41.81 4.5 2.09A5.98 5.98 0 0 1 16.5 2.8C19.58 2.8 22 5.22 22 8.3c0 3.78-3.4 6.86-8.55 11.54L12 21.15Z'/%3E%3C/svg%3E") !important;
}
/* Only genuine hover devices get the outer glow. Touch devices do not keep :hover sticky.
   Keyboard focus-visible uses inset ring, which cannot be cut by Sticky ATC overflow. */
@media (hover:hover) and (pointer:fine) {
  body.single-product .summary .swc-wishlist-native a:is(.commercekit-save-wishlist,.commercekit-browse-wishlist):hover:not(.processing) {
    border-color:var(--swc-wish-hover,#26b6c6) !important;
    box-shadow:0 0 0 2px color-mix(in srgb,var(--swc-wish-hover,#26b6c6) 35%,transparent),
               0 0 var(--swc-wish-glow,10px) color-mix(in srgb,var(--swc-wish-hover,#26b6c6) 45%,transparent) !important;
  }
  body.single-product .summary .swc-wishlist-native a.commercekit-browse-wishlist:hover:not(.processing) {
    border-color:var(--swc-wish-active-glow,#26b6c6) !important;
    box-shadow:0 0 0 2px color-mix(in srgb,var(--swc-wish-active-glow,#26b6c6) 35%,transparent),
               0 0 var(--swc-wish-glow,10px) color-mix(in srgb,var(--swc-wish-active-glow,#26b6c6) 45%,transparent) !important;
  }
}
body.single-product .summary .swc-wishlist-native a:is(.commercekit-save-wishlist,.commercekit-browse-wishlist):focus-visible:not(.processing) {
  outline:2px solid var(--swc-wish-hover,#26b6c6);
  outline-offset:-4px; box-shadow:inset 0 0 0 2px color-mix(in srgb,var(--swc-wish-hover,#26b6c6) 30%,transparent) !important;
}
body.single-product .summary .swc-wishlist-native a:is(.commercekit-save-wishlist,.commercekit-browse-wishlist).processing {
  box-shadow:none !important; border-color:var(--swc-wish-border,#aeb6bf) !important;
  background:#fff !important;
}
body.single-product .summary .swc-wishlist-native a.processing em { visibility:hidden !important; }
body.single-product .summary .swc-wishlist-native .commercekit-wishlist.full a.processing::after {
  content:"" !important; position:absolute !important; inset:0 !important; margin:auto !important;
  width:22px !important; height:22px !important;
  border:2px solid rgba(30,41,59,.18) !important;
  border-top-color:var(--swc-wish-hover,#26b6c6) !important;
  border-radius:50% !important; box-sizing:border-box !important;
  transform-origin:center !important;
  animation:swc-wishlist-spin .55s linear infinite !important; pointer-events:none;
}
@keyframes swc-wishlist-spin { to { transform:rotate(360deg); } }
/* 禁止 CommerceKit 收藏操作的白色 Product added/removed 弹层。
 * 仅商品详情页生效；不影响 WooCommerce 原生通知或其他页面的 Wishlist。
 * CommerceKit 仍可更新其内联 style，但 !important 确保不会闪现。
 */
body.single-product #commercekit-flash-popup { display: none !important; }
@media (prefers-reduced-motion:reduce) {
  body.single-product .summary .swc-wishlist-native a { transition:none; }
}

/* rc.12: The theme/gallery/intersector and viewport can clip an in-flow
 * box-shadow on phone AND tablet. The interaction halo is rendered in one
 * non-interactive body-level layer, not inside the product summary.
 * This keeps native button alignment and all WooCommerce/CommerceKit nodes.
 * When JS is unavailable, the original scoped :hover shadow above remains.
 */
html.swc-wishlist-glow-portal-ready body.single-product .summary
 .swc-wishlist-native .commercekit-wishlist.full a:is(.commercekit-save-wishlist,.commercekit-browse-wishlist):is(:hover,:focus,:focus-visible):not(.processing){
  box-shadow:none!important;
}
.swc-wishlist-glow-portal{
  position:fixed!important;
  z-index:2147483000!important;
  pointer-events:none!important;
  overflow:visible!important;
  margin:0!important;
  padding:0!important;
  background:transparent!important;
  contain:layout style;
}
.swc-wishlist-glow-portal__paint{
  position:absolute!important;
  display:block!important;
  box-sizing:border-box!important;
  pointer-events:none!important;
  background:transparent!important;
  border:0!important;
  box-shadow:
   0 0 0 2px color-mix(in srgb,var(--swc-wishlist-glow-portal-color,#26b6c6) 35%,transparent),
   0 0 var(--swc-wishlist-glow-portal-blur,10px) color-mix(in srgb,var(--swc-wishlist-glow-portal-color,#26b6c6) 45%,transparent)!important;
}
