/* R9 side mini-cart — same summary system as the cart totals (UX 2026-10-02). Loaded non-blocking on every front-end page.
   Item: [image] [title / stepper + line price] with a compact remove icon at the top end. Footer: total row, instalment strip, buttons. */
body .cart-widget-side .woocommerce-mini-cart-item{position:relative;display:grid!important;grid-template-columns:72px minmax(0,1fr);column-gap:12px;align-items:start;padding:14px 16px!important;border-bottom:1px solid var(--r9-line-2,#eceef1)}
body .cart-widget-side .woocommerce-mini-cart-item>.cart-item-image{grid-column:1;grid-row:1}
body .cart-widget-side .woocommerce-mini-cart-item>.cart-info{grid-column:2;grid-row:1;display:grid!important;grid-template-columns:auto minmax(0,1fr);grid-template-areas:"t t" "q p";column-gap:12px;row-gap:10px;align-items:center;min-width:0;text-align:start;padding:0!important;margin:0!important}
body .cart-widget-side .cart-info>.wd-entities-title{grid-area:t;margin:0!important;padding-inline-end:40px;font-size:14px;line-height:1.5}
body .cart-widget-side .cart-info>.wd-product-detail{display:none!important}

/* remove: compact icon, 44px target, top end of the row */
body .cart-widget-side .woocommerce-mini-cart-item>a.remove{position:absolute!important;top:8px!important;inset-inline-end:8px!important;inset-inline-start:auto!important;z-index:3;display:block!important;width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;margin:0!important;padding:0!important;border:0!important;border-radius:10px!important;background:transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234a4f57' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h16M10 11v6M14 11v6M6 7l1 12a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2l1-12M9 7V4h6v3'/%3E%3C/svg%3E") center/20px 20px no-repeat!important;font-size:0!important;color:transparent!important;box-shadow:none!important;transition:background-color .15s}
body .cart-widget-side .woocommerce-mini-cart-item>a.remove::before,body .cart-widget-side .woocommerce-mini-cart-item>a.remove::after{display:none!important;content:none!important}
body .cart-widget-side .woocommerce-mini-cart-item>a.remove:hover{background-color:var(--r9-red-50,#fdecef)!important;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a00d25' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h16M10 11v6M14 11v6M6 7l1 12a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2l1-12M9 7V4h6v3'/%3E%3C/svg%3E")!important}
body .cart-widget-side .woocommerce-mini-cart-item>a.remove:focus-visible{outline:none;box-shadow:var(--r9-focus,0 0 0 3px #fff,0 0 0 5px #16181d)!important}

/* stepper: clear border, bold glyphs, 44px targets; grouped on one line with the line price */
body .cart-widget-side .cart-info>div.quantity{grid-area:q;position:relative;z-index:2;display:inline-flex!important;align-items:stretch;justify-content:flex-start;width:auto!important;margin:0!important;border:1.5px solid #7b818b!important;border-radius:10px!important;overflow:hidden;background:#fff}
body .cart-widget-side .cart-info>div.quantity .minus,body .cart-widget-side .cart-info>div.quantity .plus{width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;background-color:#fff!important;background-size:18px 18px!important;background-position:center!important;background-repeat:no-repeat!important;font-size:0!important;color:transparent!important;cursor:pointer;transition:background-color .12s}
body .cart-widget-side .cart-info>div.quantity .plus{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316181d' stroke-width='2.8' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E")!important}
body .cart-widget-side .cart-info>div.quantity .minus{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316181d' stroke-width='2.8' stroke-linecap='round'%3E%3Cpath d='M5 12h14'/%3E%3C/svg%3E")!important}
body .cart-widget-side .cart-info>div.quantity .minus:hover,body .cart-widget-side .cart-info>div.quantity .plus:hover{background-color:var(--r9-bg,#f3f4f6)!important}
body .cart-widget-side .cart-info>div.quantity .minus:active,body .cart-widget-side .cart-info>div.quantity .plus:active{background-color:var(--r9-line,#e3e5e8)!important}
body .cart-widget-side .cart-info>div.quantity :is(.minus,.plus):focus-visible{outline:none;box-shadow:inset 0 0 0 2px var(--r9-ink,#16181d)!important}
body .cart-widget-side .cart-info>div.quantity input.qty{width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;margin:0!important;padding:0!important;border:0!important;border-inline:1px solid var(--r9-line,#e3e5e8)!important;border-radius:0!important;background:#fff!important;font-size:16px!important;font-weight:700!important;color:var(--r9-ink,#16181d)!important;text-align:center;-moz-appearance:textfield}
body .cart-widget-side .cart-info>div.quantity input.qty::-webkit-inner-spin-button,body .cart-widget-side .cart-info>div.quantity input.qty::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
body .cart-widget-side .cart-info>span.quantity{grid-area:p;justify-self:end;display:flex!important;flex-direction:column;align-items:flex-end;gap:1px;margin:0!important;text-align:end;white-space:nowrap;font-weight:400;color:var(--r9-ink,#16181d)}
body .cart-widget-side .cart-info>span.quantity .r9mc-line__t,body .cart-widget-side .cart-info>span.quantity .r9mc-line__t .amount{font-size:16px!important;font-weight:800!important;color:var(--r9-ink,#16181d)!important}
body .cart-widget-side .cart-info>span.quantity .r9mc-line__u,body .cart-widget-side .cart-info>span.quantity .r9mc-line__u .amount{font-size:12px!important;font-weight:400!important;color:var(--r9-muted,#646973)!important}

/* header */
body .cart-widget-side .wd-heading{align-items:center;padding-top:6px;padding-bottom:6px}
body .cart-widget-side .wd-heading .close-side-widget>a{min-height:44px;display:inline-flex;align-items:center;gap:6px}

/* «أكمل طلبك» upsell */
body .cart-widget-side .r9g-nudge{padding:12px!important;border-radius:12px}
body .cart-widget-side .r9g-nudge__h{font-size:14px;line-height:1.5;margin-bottom:10px}
body .cart-widget-side .r9g-nudge__h span{display:block;font-size:12.5px;font-weight:600;margin-top:1px}
body .cart-widget-side .r9g-nudge li{gap:10px;margin-bottom:10px}
body .cart-widget-side .r9g-nudge li:last-child{margin-bottom:0}
body .cart-widget-side .r9g-nudge .r9g-nudge__add{flex:none;min-width:64px!important;min-height:44px!important;padding:0 14px!important;font-size:14px!important;display:inline-flex!important;align-items:center;justify-content:center}

/* footer: free-shipping bar, total row, instalment strip, buttons */

body .cart-widget-side .wd-free-progress-bar:has(.progress-bar[style*="100%"]) .progress-msg{color:var(--r9-green,#1e7e34);font-weight:600}
body .cart-widget-side .woocommerce-mini-cart__total:has(.r9mc-r){display:grid!important;grid-template-columns:minmax(0,1fr) auto;align-items:baseline;column-gap:0;row-gap:0;padding:10px 16px 8px!important;margin:0!important;border:0!important;font-size:14px;line-height:1.5}
body .cart-widget-side .r9mc-r{display:contents}
body .cart-widget-side .r9mc-l{grid-column:1;text-align:start;padding:3px 0;font-size:14px;font-weight:500;color:var(--r9-text,#4a4f57)}
body .cart-widget-side .r9mc-n{grid-column:1/-1;display:block;margin:-2px 0 2px;font-size:12px;font-weight:400;line-height:1.45;text-align:start;color:var(--r9-muted,#646973)}
body .cart-widget-side .r9mc-n i{font-style:normal}
body .cart-widget-side .r9mc-n .amount{font-size:12px!important;font-weight:600!important;color:var(--r9-muted,#646973)!important}
body .cart-widget-side .r9mc-v{grid-column:2;text-align:end;white-space:nowrap;padding:3px 0 3px;padding-inline-start:16px;font-size:15px;font-weight:700;color:var(--r9-ink,#16181d);font-variant-numeric:tabular-nums}
body .cart-widget-side .r9mc-v .amount,body .cart-widget-side .r9mc-v bdi{color:inherit!important;font-weight:inherit!important;font-size:inherit!important}
body .cart-widget-side .r9mc-r--ship.r9mc-free .r9mc-v{color:var(--r9-green,#1e7e34)}
body .cart-widget-side .r9mc-r--total .r9mc-l,body .cart-widget-side .r9mc-r--total .r9mc-v{padding-top:10px;margin-top:6px;border-top:1px solid var(--r9-silver,#c9cdd2)}
body .cart-widget-side .r9mc-r--total:first-child .r9mc-l,body .cart-widget-side .r9mc-r--total:first-child .r9mc-v{padding-top:3px;margin-top:0;border-top:0}
body .cart-widget-side .r9mc-r--total .r9mc-l{font-size:16px;font-weight:700;color:var(--r9-ink,#16181d)}
body .cart-widget-side .r9mc-r--total .r9mc-v{font-size:20px;font-weight:800;align-self:start}
body .cart-widget-side .r9mc-r--save .r9mc-l,body .cart-widget-side .r9mc-r--save .r9mc-v{color:var(--r9-green,#1e7e34);font-weight:600}
body .cart-widget-side .r9mc-r--save .r9mc-v{font-weight:700}
body .cart-widget-side .r9g-bnpl--mini{display:flex!important;flex-wrap:nowrap!important;align-items:center;justify-content:space-between;gap:10px!important;margin:0 16px 12px!important;padding:9px 12px!important;border:1px solid var(--r9-line,#e3e5e8)!important;border-radius:10px;background:#fafbfc!important;text-align:start!important}
body .cart-widget-side .r9g-bnpl--mini p{flex:1 1 auto;min-width:0;margin:0;text-align:start!important;font-size:13px!important;line-height:1.5}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos{flex:none;margin:0!important;gap:12px!important}
body .cart-widget-side .r9g-bnpl--mini p{text-wrap:balance}
body .cart-widget-side .r9g-bnpl--mini p strong{white-space:nowrap}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img{border:0!important;padding:0!important;background:none!important;height:18px!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img:last-child{height:13px!important}
body .cart-widget-side .woocommerce-mini-cart__buttons{margin:0!important;grid-template-columns:1.7fr 1fr!important}
body .cart-widget-side .woocommerce-mini-cart__buttons .button:focus-visible{outline:none;box-shadow:var(--r9-focus,0 0 0 3px #fff,0 0 0 5px #16181d)!important}
/* the drawer scrolls as one piece (no squeezed item list on short phones); the footer sits at the bottom when there is room,
   and the two buttons stay pinned in the thumb zone while scrolling */
body .cart-widget-side>.widget_shopping_cart{flex:1 0 auto!important;height:auto!important;min-height:0;display:flex!important;flex-direction:column}
body .cart-widget-side .widget_shopping_cart_content{display:flex!important;flex-direction:column;flex:1 0 auto!important;height:auto!important;min-height:0}
body .cart-widget-side .shopping-cart-widget-body{flex:none!important;overflow:visible!important;max-height:none!important;height:auto!important}
body .cart-widget-side .shopping-cart-widget-footer:not(.wd-cart-empty){flex:1 0 auto!important;display:flex!important;flex-direction:column;margin-top:0!important;padding-bottom:0!important;box-shadow:none!important}
body .cart-widget-side .woocommerce-mini-cart__buttons{position:sticky!important;bottom:0;z-index:3;background:#fff;padding:12px 16px max(12px,env(safe-area-inset-bottom))!important;box-shadow:0 -1px 0 var(--r9-line,#e3e5e8)}
body .cart-widget-side .r9g-nudge li>div{position:relative}
body .cart-widget-side .r9g-nudge__name::after{content:"";position:absolute;inset:-4px 0}
body .cart-widget-side .shopping-cart-widget-footer.wd-cart-empty{box-shadow:none!important;border:0!important;padding:0!important}
body .cart-widget-side .wd-empty-mini-cart .btn,body .cart-widget-side .wd-empty-mini-cart .wc-backward{min-height:48px!important;display:inline-flex!important;align-items:center;justify-content:center;padding:0 24px!important;border-radius:var(--r9-r-btn,10px)!important;font-size:15px!important}
body .cart-widget-side .wd-empty-mini-cart .woocommerce-mini-cart__empty-message{font-size:16px;font-weight:700;color:var(--r9-ink,#16181d)}
/* progress toward free shipping: solid, calm; green once reached */
body .cart-widget-side .wd-free-progress-bar .progress-area .progress-bar[style*="100%"]{background-color:var(--r9-green,#1e7e34)!important}
body .cart-widget-side .wd-free-progress-bar .progress-area{padding:0!important;box-sizing:border-box!important;height:6px!important;border-radius:3px!important;background:var(--r9-line,#e3e5e8)!important;overflow:hidden}
body .cart-widget-side .wd-free-progress-bar .progress-bar{height:100%!important;margin:0!important;background-image:none!important;background-color:var(--r9-text,#4a4f57)!important;border-radius:3px!important;animation:none!important}
body .cart-widget-side .r9g-nudge__price,body .cart-widget-side .r9g-nudge__price .amount{color:var(--r9-ink,#16181d)!important}
@media (prefers-reduced-motion:reduce){body .cart-widget-side *{transition:none!important}}
body .cart-widget-side>.wd-heading{position:sticky;top:0;z-index:4;background:#fff}

body .cart-widget-side .wd-free-progress-bar .progress-msg{margin:0 0 8px!important;line-height:1.5}
body .cart-widget-side .wd-free-progress-bar .progress-msg .amount{color:var(--r9-ink,#16181d)!important;font-weight:700}
/* drawer: compact rows; the instalment line is a quiet row, not a card */
body .cart-widget-side .r9mc-l,body .cart-widget-side .r9mc-v{padding-top:2px;padding-bottom:2px}
body .cart-widget-side .r9g-bnpl--mini{border:0!important;background:none!important;padding:2px 0 0!important;margin:0 16px 10px!important}
body .cart-widget-side .r9g-bnpl--mini p{font-size:12.5px!important;color:var(--r9-text,#4a4f57)}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img{height:15px!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img:last-child{height:11px!important}
/* checkout button carries the amount */
body .cart-widget-side .woocommerce-mini-cart__buttons .r9mc-co{display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:1px;line-height:1.25!important;white-space:nowrap;padding-block:6px!important}
body .cart-widget-side .r9mc-co .r9mc-co__amt,body .cart-widget-side .r9mc-co .r9mc-co__amt .amount{display:block;color:#fff!important;font-weight:600!important;font-size:12.5px!important}
body .cart-widget-side .woocommerce-mini-cart__buttons .btn-cart{white-space:nowrap}
/* empty drawer */
body .cart-widget-side .wd-empty-mini-cart::before{color:#9aa0a6!important}
body .cart-widget-side .wd-empty-mini-cart .btn,body .cart-widget-side .wd-empty-mini-cart .wc-backward{width:100%;box-sizing:border-box}
body .cart-widget-side .wd-empty-mini-cart{padding-inline:16px!important}
body .cart-widget-side .r9mc-empty{padding:4px 16px 20px;text-align:start}
body .cart-widget-side .r9mc-empty__h{margin:0 0 10px;font-size:14px;font-weight:700;color:var(--r9-ink,#16181d)}
body .cart-widget-side .r9mc-empty ul{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
body .cart-widget-side .r9mc-empty a{display:flex;align-items:center;justify-content:center;min-height:44px;padding:0 8px;border:1px solid var(--r9-line,#e3e5e8);border-radius:10px;background:#fff;font-size:14px;font-weight:600;color:var(--r9-ink,#16181d)!important;text-align:center;text-decoration:none}
body .cart-widget-side .r9mc-empty a:hover{border-color:var(--r9-ink,#16181d)}
body .cart-widget-side .r9mc-empty a:focus-visible{outline:none;box-shadow:var(--r9-focus,0 0 0 3px #fff,0 0 0 5px #16181d)}
body .cart-widget-side .r9mc-empty li{margin:0!important;padding:0!important}

/* drawer v3: instalment line stacked like the cart strip; readable small print; calmer secondary button; no duplicate free-shipping banner */
body .cart-widget-side .r9g-bnpl--mini{flex-wrap:wrap!important;gap:4px 12px!important}
body .cart-widget-side .r9g-bnpl--mini p{flex:1 1 100%}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos{margin-inline-end:auto!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img{height:16px!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img:last-child{height:12px!important}
body .cart-widget-side .r9mc-n,body .cart-widget-side .r9mc-n .amount{font-size:12.5px!important}
body .cart-widget-side .r9g-bnpl--mini p{font-size:13px!important}
body .cart-widget-side .woocommerce-mini-cart__buttons .btn-cart{border-color:var(--r9-silver,#c9cdd2)!important;border-width:1.5px!important}
body .cart-widget-side .woocommerce-mini-cart__buttons .btn-cart:hover{border-color:var(--r9-ink,#16181d)!important}
body .cart-widget-side .shopping-cart-widget-footer .wd-free-progress-bar:has(.progress-bar[style*="100%"]){display:none!important}
body .cart-widget-side .r9mc-empty{text-align:center}
body .cart-widget-side .r9mc-empty__h{text-align:center}
@media (min-width:1025px){body .cart-widget-side .r9mc-n,body .cart-widget-side .r9mc-n .amount{font-size:13px!important}}

/* final: one instalment strip token everywhere (same as /cart/), readable logos, a soft edge on the docked bar */
body .cart-widget-side .r9g-bnpl--mini{border:1px solid var(--r9-line,#e3e5e8)!important;background:#fafbfc!important;padding:8px 12px!important;border-radius:10px!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img{height:18px!important}
body .cart-widget-side .r9g-bnpl--mini .r9g-bnpl__logos img:last-child{height:13px!important}
body .cart-widget-side .woocommerce-mini-cart__buttons{box-shadow:0 -1px 0 var(--r9-line,#e3e5e8),0 -6px 12px rgba(22,24,29,.05)!important}
