/* Cart/Checkout presentation only. One clean rule set for Classic Cart + Classic Checkout.
   Do not style gateway internals/iframes. */
.commerce-flow{padding-bottom:var(--fanyi-section-space);}
.commerce-flow .entry-title{font-size:clamp(2rem,3.6vw,3.25rem);line-height:1.1;letter-spacing:var(--fanyi-tracking);margin:1rem 0 1.75rem;}
.commerce-flow .woocommerce{min-width:0;}
.commerce-flow :is(.woocommerce-info,.woocommerce-message,.woocommerce-error){margin:0 0 1.25rem;padding:1rem 1.25rem;border:1px solid var(--fanyi-border);border-left:3px solid var(--fanyi-green);border-radius:12px;background:var(--fanyi-bg-soft);color:var(--fanyi-text);overflow-wrap:anywhere;}
.commerce-flow .woocommerce-error{border-left-color:var(--fanyi-text);}
.commerce-flow .woocommerce-error li+li{margin-top:.5rem;}
.commerce-flow .woocommerce-notices-wrapper:empty{display:none;}
.commerce-flow :is(.wc-backward,.checkout-button,button[name=update_cart],button[name=apply_coupon],.woocommerce-form-coupon button,.woocommerce-form-login button){display:inline-flex;align-items:center;justify-content:center;min-height:46px;padding:.75rem 1.1rem;border:1px solid var(--fanyi-border);border-radius:10px;font:650 .9375rem/1.3 var(--fanyi-font);text-decoration:none;text-align:center;background:#fff;color:var(--fanyi-text);cursor:pointer;}
.commerce-flow .woocommerce :is(.checkout-button,.wc-backward){background:var(--fanyi-green);border-color:var(--fanyi-green);color:#fff;}
.commerce-flow .woocommerce :is(.checkout-button,.wc-backward):hover{background:var(--fanyi-green-hover);}
.commerce-flow button:disabled{opacity:.5;cursor:default;}

/* ---------- Classic Cart ---------- */
body.woocommerce-cart .commerce-flow table.shop_table{width:100%;border-collapse:separate;border-spacing:0;border:1px solid var(--fanyi-border);border-radius:14px;background:#fff;font-size:.9375rem;overflow:hidden;}
body.woocommerce-cart .commerce-flow .shop_table :is(th,td){padding:1rem;text-align:left;vertical-align:middle;border-bottom:1px solid var(--fanyi-border);}
body.woocommerce-cart .commerce-flow .shop_table tr:last-child>td{border-bottom:0;}
body.woocommerce-cart .commerce-flow .shop_table thead th{font-size:.8125rem;background:var(--fanyi-bg-soft);font-weight:650;}
body.woocommerce-cart .commerce-flow .product-thumbnail img{width:72px;height:72px;object-fit:cover;border-radius:10px;}
body.woocommerce-cart .commerce-flow .product-name{line-height:1.45;overflow-wrap:normal;word-break:normal;}
body.woocommerce-cart .commerce-flow .product-name a{font-weight:700;text-decoration:none;}
body.woocommerce-cart .commerce-flow .variation{margin:.375rem 0 0;font-size:.8125rem;color:var(--fanyi-muted);}
body.woocommerce-cart .commerce-flow .variation :is(dt,dd){margin:0 .375rem .25rem 0;}
body.woocommerce-cart .commerce-flow .product-remove{width:3.5rem;text-align:center;}
body.woocommerce-cart .commerce-flow .product-remove a.remove{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;min-width:30px;min-height:30px;margin:auto;border:1px solid var(--fanyi-border);border-radius:999px;background:#fff;font-size:.95rem;line-height:1;text-decoration:none;color:var(--fanyi-muted);}
body.woocommerce-cart .commerce-flow .product-remove a.remove:hover{border-color:var(--fanyi-text);color:var(--fanyi-text);}
body.woocommerce-cart .commerce-flow .quantity .qty{width:5rem;min-height:44px;padding:.55rem;border:1px solid var(--fanyi-border);border-radius:10px;font:inherit;text-align:center;background:#fff;color:var(--fanyi-text);}
body.woocommerce-cart .commerce-flow td.actions{padding:1rem!important;}
body.woocommerce-cart .commerce-flow .actions .coupon{display:inline-flex!important;align-items:center;gap:.65rem;float:none!important;margin:0!important;}
body.woocommerce-cart .commerce-flow .actions .coupon label{display:none;}
body.woocommerce-cart .commerce-flow .actions .coupon input{width:18rem;max-width:100%;min-height:44px;padding:.65rem .85rem;border:1px solid var(--fanyi-border);border-radius:10px;font:inherit;}
body.woocommerce-cart .commerce-flow .actions button[name=apply_coupon]{white-space:nowrap;}
body.woocommerce-cart .commerce-flow .actions button[name=update_cart]{float:right!important;white-space:nowrap;}
body.woocommerce-cart .commerce-flow .cart-collaterals{min-width:0;}
body.woocommerce-cart .commerce-flow .cart_totals{width:100%;float:none;padding:1.5rem;background:#fff;border:1px solid var(--fanyi-border);border-radius:14px;box-shadow:0 14px 36px rgba(14,24,38,.05);}
body.woocommerce-cart .commerce-flow .cart_totals h2{font-size:clamp(1.35rem,2vw,1.7rem);line-height:1.2;margin:0 0 1rem;padding:0 0 1rem;border-bottom:1px solid var(--fanyi-border);}
body.woocommerce-cart .commerce-flow .cart_totals table{border:0;background:transparent;margin:0;}
body.woocommerce-cart .commerce-flow .cart_totals :is(th,td){padding:.85rem 0;border-bottom:1px solid var(--fanyi-border);vertical-align:top;}
body.woocommerce-cart .commerce-flow .cart_totals th{width:38%;font-weight:650;}
body.woocommerce-cart .commerce-flow .cart_totals td{width:62%;text-align:right;line-height:1.5;overflow-wrap:normal;word-break:normal;}
body.woocommerce-cart .commerce-flow .cart_totals .order-total :is(th,td){font-size:1.05rem;border-bottom:0;}
body.woocommerce-cart .commerce-flow #shipping_method{list-style:none;margin:0;padding:0;}
body.woocommerce-cart .commerce-flow #shipping_method li{margin:.4rem 0;}
body.woocommerce-cart .commerce-flow .woocommerce-shipping-destination{margin-top:.65rem;font-size:.8125rem;color:var(--fanyi-muted);}
body.woocommerce-cart .commerce-flow .shipping-calculator-button{display:inline-flex;margin-top:.35rem;font-weight:650;}
body.woocommerce-cart .commerce-flow .wc-proceed-to-checkout{padding-top:1rem;}
body.woocommerce-cart .commerce-flow .checkout-button{width:100%;min-height:52px;border-radius:11px;font-size:1rem;}

/* empty cart */
body.woocommerce-cart .commerce-flow .woocommerce-message{max-width:52rem;margin:0 auto .9rem;padding:.9rem 1.05rem;background:#f8faf9;border:1px solid var(--fanyi-border);border-left:3px solid var(--fanyi-green);}
body.woocommerce-cart .commerce-flow .wc-empty-cart-message{max-width:52rem;margin:0 auto;}
body.woocommerce-cart .commerce-flow .wc-empty-cart-message .cart-empty,
body.woocommerce-cart .commerce-flow p.cart-empty.woocommerce-info{margin:0;padding:2rem 1.25rem;border:1px solid var(--fanyi-border);border-left:1px solid var(--fanyi-border);border-radius:14px;background:#fff;text-align:center;font-size:1.1rem;font-weight:700;box-shadow:0 12px 28px rgba(14,24,38,.04);}
body.woocommerce-cart .commerce-flow .return-to-shop{display:flex;justify-content:center;margin:1rem auto 0;}
body.woocommerce-cart .commerce-flow .return-to-shop .button{min-width:11rem;border-radius:999px;}

/* ---------- Classic Checkout ---------- */
.commerce-flow form.checkout{min-width:0;}
.commerce-flow form.checkout > :is(#customer_details,#order_review_heading,#order_review){float:none!important;clear:none!important;width:auto!important;max-width:none!important;margin-left:0!important;margin-right:0!important;}
.commerce-flow form.checkout > #customer_details{min-width:0;}
.commerce-flow form.checkout > #order_review_heading,.commerce-flow form.checkout > #order_review{min-width:0;width:100%!important;}
.commerce-flow #customer_details{min-width:0;}
.commerce-flow #customer_details :is(.col-1,.col-2){float:none;width:100%;}
.commerce-flow #customer_details :is(.woocommerce-billing-fields,.woocommerce-shipping-fields,.woocommerce-additional-fields){margin-bottom:1.5rem;}
.commerce-flow #customer_details .form-row{padding:0;margin:0 0 1rem;min-width:0;}
.commerce-flow #customer_details label{display:block;font-size:.875rem;font-weight:650;margin-bottom:.5rem;}
.commerce-flow #customer_details .required{color:var(--fanyi-green-hover);text-decoration:none;}
.commerce-flow #customer_details :is(.input-text,select,textarea,.select2-selection){width:100%;min-width:0;min-height:48px;border:1px solid var(--fanyi-border);border-radius:10px;padding:.75rem 1rem;background:#fff;color:var(--fanyi-text);font:inherit;}
.commerce-flow #customer_details textarea{min-height:120px;resize:vertical;}
.commerce-flow #customer_details .select2-container{max-width:100%;}
.commerce-flow #customer_details .select2-selection__rendered{padding:0;}
.commerce-flow #customer_details .select2-selection__arrow{height:100%;}
.commerce-flow #order_review{min-width:0;padding:1.25rem;border:1px solid var(--fanyi-border);border-radius:14px;background:var(--fanyi-bg-soft);}
.commerce-flow :is(#order_review_heading,#customer_details h3){font-size:clamp(1.375rem,2vw,1.75rem);line-height:1.2;margin:0 0 1.25rem;}
.commerce-flow .woocommerce-checkout-review-order-table{margin-bottom:1.25rem;}
.commerce-flow #payment{border-top:1px solid var(--fanyi-border);padding-top:1.25rem;}
.commerce-flow button#place_order{min-height:54px;max-width:100%;padding:.875rem 1.25rem;border:1px solid var(--fanyi-green);border-radius:10px;background:var(--fanyi-green);color:#fff;font:650 1rem/1.35 var(--fanyi-font);}
.commerce-flow :is(.coupon input,.qty,#customer_details input,#customer_details select,#customer_details textarea,button#place_order):focus-visible{outline:3px solid var(--fanyi-green-hover);outline-offset:3px;}

body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle{margin:0 0 1.25rem;}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .woocommerce-info{display:flex;align-items:center;gap:.6rem;flex-wrap:wrap;padding:.9rem 1rem;border:1px solid var(--fanyi-border);border-left:3px solid var(--fanyi-green);border-radius:12px;background:#f8faf9;}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .woocommerce-info::before{display:none!important;content:none!important;}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .showcoupon{font-weight:650;text-decoration:none;}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.75rem 1rem;align-items:end;margin:0 0 1.5rem;padding:1rem;border:1px solid var(--fanyi-border);border-radius:12px;background:#fff;}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon>p:first-child{grid-column:1/-1;margin:0;}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon .form-row{float:none!important;width:auto!important;padding:0;margin:0;}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon input{width:100%;min-height:46px;padding:.65rem .85rem;border:1px solid var(--fanyi-border);border-radius:10px;}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon .clear{display:none;}

@media(min-width:64rem){
  body.woocommerce-cart .commerce-flow .woocommerce{display:grid;grid-template-columns:minmax(0,1.75fr) minmax(22rem,.85fr);gap:2rem;align-items:start;width:100%;}
  body.woocommerce-cart .commerce-flow .woocommerce::after{display:none;}
  body.woocommerce-cart .commerce-flow .woocommerce > :not(.woocommerce-cart-form):not(.cart-collaterals){grid-column:1/-1;width:100%;min-width:0;}
  body.woocommerce-cart .commerce-flow .woocommerce > .woocommerce-cart-form{grid-column:1;width:100%!important;float:none!important;margin:0!important;}
  body.woocommerce-cart .commerce-flow .woocommerce > .cart-collaterals{grid-column:2;width:100%!important;float:none!important;margin:0!important;position:sticky;top:1.5rem;}
  .commerce-flow form.checkout{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(22rem,1fr);column-gap:2.5rem;row-gap:0;align-items:start;width:100%;}
  .commerce-flow form.checkout>#customer_details{grid-column:1;grid-row:1/span 2;}
  .commerce-flow form.checkout>#order_review_heading{grid-column:2;grid-row:1;}
  .commerce-flow form.checkout>#order_review{grid-column:2;grid-row:2;}
  .commerce-flow form.checkout>:not(#customer_details):not(#order_review_heading):not(#order_review){grid-column:1/-1;}
  body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle,
  body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon{max-width:calc(100% - 24.5rem);}
}

@media(max-width:63.999rem){
  .commerce-flow form.checkout{display:block;width:100%;}
  .commerce-flow form.checkout>:is(#customer_details,#order_review_heading,#order_review){width:100%!important;max-width:100%!important;float:none!important;clear:both!important;}
  .commerce-flow #order_review_heading{margin-top:2rem;}
  body.woocommerce-cart .commerce-flow .woocommerce-cart-form,
  body.woocommerce-cart .commerce-flow .cart-collaterals{width:100%!important;float:none!important;}
  body.woocommerce-cart .commerce-flow .cart-collaterals{margin-top:1.25rem;}
}

@media(max-width:47.999rem){
  .commerce-flow .entry-title{font-size:1.75rem;margin:.35rem 0 1rem;}
  body.woocommerce-cart .commerce-flow table.shop_table.cart{display:block;border:0;background:transparent;overflow:visible;}
  body.woocommerce-cart .commerce-flow .cart thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);}
  body.woocommerce-cart .commerce-flow .cart tbody{display:block;width:100%;}
  body.woocommerce-cart .commerce-flow .cart tr.cart_item{display:grid!important;grid-template-columns:72px repeat(3,minmax(0,1fr));grid-template-rows:auto auto;column-gap:.75rem;row-gap:.8rem;padding:1rem;margin:0 0 .85rem;border:1px solid var(--fanyi-border);border-radius:14px;background:#fff;position:relative;}
  body.woocommerce-cart .commerce-flow .cart .cart_item td{border:0!important;padding:0!important;min-width:0;}
  body.woocommerce-cart .commerce-flow .cart .product-thumbnail{display:block!important;grid-column:1;grid-row:1;width:72px!important;}
  body.woocommerce-cart .commerce-flow .cart .product-thumbnail img{width:72px!important;height:72px!important;border-radius:10px;}
  body.woocommerce-cart .commerce-flow .cart .product-name{display:block!important;grid-column:2/5;grid-row:1;padding-right:2.65rem!important;align-self:center;font-size:.96rem;line-height:1.4;}
  body.woocommerce-cart .commerce-flow .cart .product-remove{position:absolute!important;top:.7rem;right:.7rem;width:auto!important;z-index:2;}
  body.woocommerce-cart .commerce-flow .cart .product-remove a.remove{width:28px;height:28px;min-width:28px;min-height:28px;border:0;background:#f2f4f6;}
  body.woocommerce-cart .commerce-flow .cart :is(.product-price,.product-quantity,.product-subtotal){display:flex!important;flex-direction:column;gap:.25rem;padding-top:.7rem!important;border-top:1px solid var(--fanyi-border)!important;font-size:.92rem;}
  body.woocommerce-cart .commerce-flow .cart .product-price{grid-column:1;grid-row:2;align-items:flex-start;}
  body.woocommerce-cart .commerce-flow .cart .product-quantity{grid-column:2/4;grid-row:2;align-items:center;}
  body.woocommerce-cart .commerce-flow .cart .product-subtotal{grid-column:4;grid-row:2;align-items:flex-end;text-align:right;}
  body.woocommerce-cart .commerce-flow .cart td[data-title]::before{content:attr(data-title)!important;font-size:.7rem;font-weight:700;color:var(--fanyi-muted);text-transform:uppercase;letter-spacing:.02em;}
  body.woocommerce-cart .commerce-flow .cart td.product-name[data-title]::before{content:none!important;}
  body.woocommerce-cart .commerce-flow .quantity .qty{width:64px;min-height:38px;height:38px;padding:.3rem .45rem;}
  body.woocommerce-cart .commerce-flow .cart tr:last-child{display:block!important;width:100%!important;}
  body.woocommerce-cart .commerce-flow .cart td.actions{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:.65rem!important;width:100%!important;min-width:0!important;padding:.85rem 0 0!important;border:0!important;text-align:left!important;float:none!important;}
  body.woocommerce-cart .commerce-flow .actions .coupon{display:contents!important;float:none!important;width:auto!important;margin:0!important;}
  body.woocommerce-cart .commerce-flow .actions .coupon label{display:none!important;}
  body.woocommerce-cart .commerce-flow .actions .coupon input{grid-column:1!important;grid-row:1!important;width:100%!important;min-width:0!important;max-width:none!important;min-height:42px!important;height:42px!important;margin:0!important;float:none!important;}
  body.woocommerce-cart .commerce-flow .actions button[name=apply_coupon]{grid-column:2!important;grid-row:1!important;width:auto!important;min-width:7.5rem!important;min-height:42px!important;height:42px!important;margin:0!important;padding:.55rem .8rem!important;white-space:nowrap!important;float:none!important;}
  body.woocommerce-cart .commerce-flow .actions button[name=update_cart]{grid-column:1 / -1!important;grid-row:2!important;justify-self:end!important;display:inline-flex!important;width:auto!important;min-width:8.5rem!important;min-height:40px!important;margin:0!important;padding:.5rem .8rem!important;float:none!important;white-space:nowrap!important;}
  body.woocommerce-cart .commerce-flow .cart-collaterals{margin-top:.85rem!important;}
  body.woocommerce-cart .commerce-flow .cart_totals{padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:transparent!important;}
  body.woocommerce-cart .commerce-flow .cart_totals h2{font-size:1.2rem;margin:0;padding:.1rem 0 .7rem;border-bottom:1px solid var(--fanyi-border);background:transparent!important;}
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table{border:0;border-radius:0;margin:0;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table :is(th,td){padding:.8rem 0!important;border-bottom:1px solid var(--fanyi-border)!important;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table th{width:34%!important;font-size:.88rem;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table td{width:66%!important;padding-left:.75rem!important;font-size:.91rem;text-align:right!important;line-height:1.45;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table tr.order-total :is(th,td){border-bottom:0!important;}
  body.woocommerce-cart .commerce-flow .wc-proceed-to-checkout{padding-top:.85rem;}
  body.woocommerce-cart .commerce-flow .checkout-button{min-height:50px;border-radius:11px;}
  body.woocommerce-cart .commerce-flow .woocommerce-message{font-size:.9rem;}
  body.woocommerce-cart .commerce-flow .return-to-shop .button{width:100%;max-width:20rem;}
  body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon{grid-template-columns:1fr;}
  body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon button{width:100%;}
  .commerce-flow #customer_details :is(.form-row-first,.form-row-last){width:100%;float:none;}
  .commerce-flow #order_review{padding:1rem;}
  .commerce-flow button#place_order{width:100%;}
}

@media(max-width:23rem){
  body.woocommerce-cart .commerce-flow .cart tr.cart_item{grid-template-columns:64px repeat(3,minmax(0,1fr));column-gap:.55rem;padding:.8rem;}
  body.woocommerce-cart .commerce-flow .cart .product-thumbnail{width:64px!important;}
  body.woocommerce-cart .commerce-flow .cart .product-thumbnail img{width:64px!important;height:64px!important;}
  body.woocommerce-cart .commerce-flow .cart td.actions{grid-template-columns:1fr!important;}
  body.woocommerce-cart .commerce-flow .actions .coupon input,
  body.woocommerce-cart .commerce-flow .actions button[name=apply_coupon],
  body.woocommerce-cart .commerce-flow .actions button[name=update_cart]{grid-column:1!important;width:100%!important;justify-self:stretch!important;}
  body.woocommerce-cart .commerce-flow .actions button[name=apply_coupon]{grid-row:2!important;}
  body.woocommerce-cart .commerce-flow .actions button[name=update_cart]{grid-row:3!important;}
}

/* Actual Checkout uses WooCommerce Blocks, not the classic checkout form.
   Preserve the native fields, floating labels, gateway subtree and DOM sequence. */
.commerce-flow .wc-block-checkout{font-family:var(--fanyi-font);color:var(--fanyi-text);}
.commerce-flow .wc-block-components-sidebar-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:2rem;margin:0;align-items:start;}
.commerce-flow .wc-block-components-sidebar-layout .wc-block-components-main,
.commerce-flow .wc-block-components-sidebar-layout .wc-block-components-sidebar{width:100%;min-width:0;padding:0;margin:0;}
.commerce-flow .wc-block-components-checkout-step{margin-bottom:1.75rem;}
.commerce-flow .wc-block-components-checkout-step__title{font-size:1.375rem;font-weight:700;letter-spacing:var(--fanyi-tracking);}
.commerce-flow .wc-block-components-checkout-step__description{color:var(--fanyi-muted);font-size:.875rem;}
.commerce-flow .wc-block-components-checkout-step__content{padding:0;}
.commerce-flow :is(.wc-block-checkout__contact-fields,.wc-block-checkout__shipping-fields,.wc-block-checkout__billing-fields) :is(input:not([type=checkbox]):not([type=radio]),select){min-height:54px;background:var(--fanyi-bg);border-color:var(--fanyi-border);border-radius:var(--fanyi-radius-sm);color:var(--fanyi-text);font-size:1rem;}
.commerce-flow :is(.wc-block-checkout__contact-fields,.wc-block-checkout__shipping-fields,.wc-block-checkout__billing-fields) :is(input,select):focus{outline:2px solid var(--fanyi-green-hover);outline-offset:2px;box-shadow:none;}
.commerce-flow :is(.wc-block-checkout__contact-fields,.wc-block-checkout__shipping-fields,.wc-block-checkout__billing-fields) .wc-block-components-text-input label{color:var(--fanyi-muted);}
.commerce-flow .wc-block-components-address-form__address_2-toggle{min-height:44px;color:var(--fanyi-green-hover);}
.commerce-flow .wc-block-components-checkout-order-summary__content{border-color:var(--fanyi-border);border-radius:var(--fanyi-radius-lg);background:var(--fanyi-bg-soft);}
.commerce-flow .wc-block-components-checkout-order-summary__title{border-color:var(--fanyi-border);background:var(--fanyi-bg-soft);}
.commerce-flow .wc-block-components-order-summary-item__image img{object-fit:contain;border-radius:var(--fanyi-radius-sm);}
.commerce-flow .wc-block-components-product-name{font-weight:650;line-height:1.4;}
.commerce-flow .wc-block-components-product-metadata{color:var(--fanyi-muted);font-size:.8125rem;}
.commerce-flow .wc-block-components-totals-wrapper{border-color:var(--fanyi-border);}
.commerce-flow .wc-block-components-totals-footer-item{font-size:1.125rem;}
.commerce-flow .wc-block-components-checkout-place-order-button{min-height:54px;border:1px solid var(--fanyi-green);border-radius:var(--fanyi-radius-sm);background:var(--fanyi-green);color:white;font:650 1rem/1.35 var(--fanyi-font);padding:.875rem 1.25rem;}
.commerce-flow .wc-block-components-checkout-place-order-button:hover{background:var(--fanyi-green-hover);}
.commerce-flow .wc-block-checkout .wc-block-components-button.wc-block-components-checkout-place-order-button{min-height:54px;}
.commerce-flow .wc-block-components-checkout-return-to-cart-button{min-height:48px;color:var(--fanyi-muted);}
@media(min-width:64rem){.commerce-flow .wc-block-components-sidebar-layout{grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:3rem;}}
@media(max-width:47.999rem){
 .commerce-flow .wc-block-components-address-form .wc-block-components-text-input{width:100%;margin-left:0;margin-right:0;}
 .commerce-flow .wc-block-components-checkout-place-order-button{width:100%;}
 .commerce-flow .wc-block-checkout__actions_row{flex-wrap:wrap;gap:1rem;}
 .commerce-flow .wc-block-components-checkout-order-summary__content{display:block;}
}


/* 1.0.45: Simplify Cart actions. Coupons live on Checkout; mobile quantity changes auto-update. */
body.woocommerce-cart .commerce-flow .actions .coupon{display:none!important;}

@media(max-width:47.999rem){
  /* Reserve a clean top-right slot for remove without allowing it to collide with the title. */
  body.woocommerce-cart .commerce-flow .cart tr.cart_item{grid-template-columns:72px repeat(3,minmax(0,1fr));padding:1rem;column-gap:.75rem;row-gap:.72rem;}
  body.woocommerce-cart .commerce-flow .cart .product-name{
    grid-column:2/5!important;
    padding-right:2.6rem!important;
    text-align:left!important;
    align-self:start!important;
    font-size:.94rem!important;
    line-height:1.35!important;
  }
  body.woocommerce-cart .commerce-flow .cart .product-remove{
    position:absolute!important;
    top:.65rem!important;
    right:.65rem!important;
    width:30px!important;
    height:30px!important;
    z-index:3!important;
  }
  body.woocommerce-cart .commerce-flow .cart .product-remove a.remove{
    width:30px!important;height:30px!important;min-width:30px!important;min-height:30px!important;
    border:1px solid var(--fanyi-border)!important;background:#fff!important;color:var(--fanyi-muted)!important;
  }
  /* JS adds this class only when auto-update is active; otherwise Woo's Update cart stays as fallback. */
  body.fanyi-mobile-cart-auto-update.woocommerce-cart .commerce-flow .cart td.actions{display:none!important;}
  body.woocommerce-cart .commerce-flow .cart td.actions{
    width:100%!important;padding:.55rem 0 0!important;border:0!important;background:transparent!important;
  }
  body.woocommerce-cart .commerce-flow .actions button[name=update_cart]{
    float:none!important;display:inline-flex!important;width:auto!important;min-width:8.5rem!important;
    min-height:40px!important;margin-left:auto!important;padding:.5rem .85rem!important;
  }

  /* Compact summary: remove Woo/Astra paragraph margins that inflate Shipping. */
  body.woocommerce-cart .commerce-flow .cart-collaterals{margin-top:.6rem!important;}
  body.woocommerce-cart .commerce-flow .cart_totals h2{margin:0!important;padding:0 0 .65rem!important;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table :is(th,td){padding:.58rem 0!important;line-height:1.3!important;}
  body.woocommerce-cart .commerce-flow .cart_totals .shop_table tr.shipping :is(th,td){padding-top:.6rem!important;padding-bottom:.6rem!important;}
  body.woocommerce-cart .commerce-flow .cart_totals p,
  body.woocommerce-cart .commerce-flow .cart_totals .woocommerce-shipping-destination{margin:.2rem 0 0!important;}
  body.woocommerce-cart .commerce-flow .cart_totals #shipping_method li{margin:0!important;}
  body.woocommerce-cart .commerce-flow .cart_totals .shipping-calculator-button{margin:.22rem 0 0!important;line-height:1.25!important;}
  body.woocommerce-cart .commerce-flow .wc-proceed-to-checkout{padding-top:.65rem!important;}
}

@media(max-width:23.5rem){
  body.woocommerce-cart .commerce-flow .cart tr.cart_item{grid-template-columns:64px repeat(3,minmax(0,1fr));column-gap:.55rem;padding:.8rem;}
  body.woocommerce-cart .commerce-flow .cart .product-name{font-size:.9rem!important;padding-right:2.35rem!important;}
}

/* 1.0.46: Final mobile Cart totals reset. Woo/Astra responsive table rules can
   turn cart totals cells into block elements; restore a true full-width 2-column summary. */
@media(max-width:47.999rem){
  body.woocommerce-cart .commerce-flow .cart_totals{
    width:100%!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals h2{
    margin:0!important;
    padding:0 0 .7rem!important;
    font-size:1.2rem!important;
    line-height:1.2!important;
    border-bottom:1px solid var(--fanyi-border)!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table,
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table_responsive{
    display:table!important;
    width:100%!important;
    min-width:100%!important;
    table-layout:fixed!important;
    margin:0!important;
    border:0!important;
    border-collapse:collapse!important;
    background:transparent!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tbody{
    display:table-row-group!important;
    width:auto!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr{
    display:table-row!important;
    width:auto!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr th,
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr td{
    display:table-cell!important;
    box-sizing:border-box!important;
    padding:.72rem 0!important;
    border:0!important;
    border-bottom:1px solid var(--fanyi-border)!important;
    vertical-align:top!important;
    line-height:1.35!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr th{
    width:34%!important;
    padding-right:.75rem!important;
    text-align:left!important;
    font-size:.9rem!important;
    font-weight:700!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr td{
    width:66%!important;
    padding-left:.75rem!important;
    text-align:right!important;
    font-size:.9rem!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr.shipping td{
    white-space:normal!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr.shipping td > *{
    margin-top:0!important;
    margin-bottom:.18rem!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals .woocommerce-shipping-destination{
    max-width:none!important;
    margin:.05rem 0 .2rem!important;
    line-height:1.35!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals .shipping-calculator-button{
    display:inline-flex!important;
    margin:.12rem 0 0!important;
    line-height:1.25!important;
  }
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr.order-total th,
  body.woocommerce-cart .commerce-flow .cart_totals table.shop_table tr.order-total td{
    padding-top:.82rem!important;
    padding-bottom:.55rem!important;
    border-bottom:0!important;
    font-size:.98rem!important;
    font-weight:700!important;
  }
  body.woocommerce-cart .commerce-flow .wc-proceed-to-checkout{
    margin:0!important;
    padding:.55rem 0 0!important;
  }
  body.woocommerce-cart .commerce-flow .checkout-button{
    width:100%!important;
    min-height:52px!important;
    margin:0!important;
  }
}

/* 1.0.47: Clean Classic Checkout entry notices. Account login lives in the site account flow. */
body.woocommerce-checkout .commerce-flow .woocommerce-form-login-toggle{display:none!important;}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle{
  margin:0 0 1.15rem!important;
  max-width:none!important;
}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .woocommerce-info{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:.75rem!important;
  min-height:58px!important;
  margin:0!important;
  padding:.7rem .75rem .7rem 1rem!important;
  border:1px solid var(--fanyi-border)!important;
  border-left:1px solid var(--fanyi-border)!important;
  border-radius:14px!important;
  background:#fff!important;
  color:var(--fanyi-muted)!important;
  box-shadow:0 6px 20px rgba(16,24,40,.045)!important;
  font-size:.94rem!important;
  line-height:1.35!important;
}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .woocommerce-info::before{
  display:none!important;
  content:none!important;
}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .showcoupon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 auto!important;
  min-height:38px!important;
  margin-left:auto!important;
  padding:.48rem .8rem!important;
  border:1px solid #ff6b21!important;
  border-radius:999px!important;
  background:#fff8f4!important;
  color:#d94f08!important;
  font-weight:700!important;
  text-decoration:none!important;
  white-space:nowrap!important;
}
body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .showcoupon:hover{
  background:#fff1e9!important;
  color:#ba3e00!important;
}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon{
  grid-template-columns:minmax(0,1fr) auto!important;
  gap:.7rem!important;
  max-width:none!important;
  margin:-.35rem 0 1.35rem!important;
  padding:.85rem!important;
  border:1px solid var(--fanyi-border)!important;
  border-radius:0 0 14px 14px!important;
  background:#fff!important;
  box-shadow:0 8px 18px rgba(16,24,40,.035)!important;
}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon>p:first-child{
  grid-column:1/-1!important;
  margin:0!important;
  color:var(--fanyi-muted)!important;
  font-size:.88rem!important;
}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon input{
  min-height:44px!important;
  border-radius:10px!important;
}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon button{
  min-height:44px!important;
  border-color:#ff6b21!important;
  background:#ff6b21!important;
  color:#fff!important;
}
body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon button:hover{
  background:#e95c18!important;
  border-color:#e95c18!important;
}
@media(max-width:47.999rem){
  body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .woocommerce-info{
    min-height:54px!important;
    padding:.65rem .7rem .65rem .85rem!important;
    font-size:.9rem!important;
  }
  body.woocommerce-checkout .commerce-flow .woocommerce-form-coupon-toggle .showcoupon{
    min-height:36px!important;
    padding:.42rem .7rem!important;
    font-size:.86rem!important;
  }
  body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon{
    grid-template-columns:1fr!important;
  }
  body.woocommerce-checkout .commerce-flow .checkout_coupon.woocommerce-form-coupon button{
    width:100%!important;
  }
}

