/* M6 side cart drawer */
.m6sc { --m6-accent: #111; --m6-line: #e5e5e5; --m6-muted: #707070; position: fixed; inset: 0; z-index: 100000; pointer-events: none; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; font-size: 14px; line-height: 1.45; color: #1a1a1a; }
.m6sc *, .m6sc *::before, .m6sc *::after { box-sizing: border-box; }
.m6sc-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.45); opacity: 0; transition: opacity .25s; }
.m6sc-panel { position: absolute; top: 0; right: 0; bottom: 0; width: 420px; max-width: 92vw; background: #fff; transform: translateX(100%); transition: transform .3s cubic-bezier(.2,.8,.2,1); display: flex; flex-direction: column; outline: none; box-shadow: -10px 0 30px rgba(0,0,0,.12); }
.m6sc.is-open { pointer-events: auto; }
.m6sc.is-open .m6sc-overlay { opacity: 1; }
.m6sc.is-open .m6sc-panel { transform: none; }
html.m6sc-lock, html.m6sc-lock body { overflow: hidden; }

.m6sc-content { display: flex; flex-direction: column; height: 100%; min-height: 0; transition: opacity .15s; }
.m6sc-content.is-busy { opacity: .55; pointer-events: none; }
.m6sc-loading { margin: 40px auto; width: 26px; height: 26px; border: 2px solid #ddd; border-top-color: #111; border-radius: 50%; animation: m6spin .7s linear infinite; }
@keyframes m6spin { to { transform: rotate(360deg); } }

.m6sc-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--m6-line); }
.m6sc-head h3 { margin: 0; font-size: 18px; font-weight: 600; text-transform: none; letter-spacing: 0; color: #1a1a1a; }
.m6sc-count { color: var(--m6-muted); font-weight: 400; }
.m6sc-x { background: none; border: 0; padding: 4px; cursor: pointer; color: #1a1a1a; line-height: 0; min-height: 0; }

.m6sc-goal { padding: 14px 20px; background: #fafafa; border-bottom: 1px solid var(--m6-line); }
.m6sc-goal p { margin: 0 0 8px; font-size: 13px; text-align: center; }
.m6sc-goal .amount { color: inherit; }
.m6sc-bar { height: 6px; background: #e6e6e6; border-radius: 3px; overflow: hidden; }
.m6sc-bar span { display: block; height: 100%; background: var(--m6-accent); border-radius: 3px; transition: width .4s; }
.m6sc-goal.is-done .m6sc-bar span { background: #1f8f4e; }

.m6sc-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 4px 20px 16px; }
.m6sc-items, .m6sc-recs ul { list-style: none; margin: 0; padding: 0; }
.m6sc-item { display: flex; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--m6-line); margin: 0; }
.m6sc-thumb { flex: 0 0 76px; width: 76px; height: 76px; border: 1px solid var(--m6-line); border-radius: 6px; overflow: hidden; display: block; background: #fff; }
.m6sc-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; margin: 0; }
.m6sc-info { flex: 1 1 auto; min-width: 0; }
.m6sc-name { display: block; color: #1a1a1a; font-weight: 500; text-decoration: none; line-height: 1.35; }
.m6sc-name:hover { text-decoration: underline; color: #1a1a1a; }
.m6sc-meta, .m6sc-meta dl { font-size: 12px; color: var(--m6-muted); margin: 3px 0 0; }
.m6sc-meta dt, .m6sc-meta dd, .m6sc-meta p { display: inline; margin: 0; padding: 0; float: none; font-weight: 400; }
.m6sc-meta dd::after { content: "\A"; white-space: pre; }
.m6sc-row { display: flex; align-items: center; gap: 14px; margin-top: 8px; }
.m6sc-qty { display: inline-flex; align-items: center; border: 1px solid var(--m6-line); border-radius: 6px; height: 32px; }
.m6sc-qty button { width: 30px; height: 30px; border: 0; background: none; cursor: pointer; font-size: 16px; color: #1a1a1a; padding: 0; min-height: 0; }
.m6sc-qty button:disabled { opacity: .3; cursor: default; }
.m6sc-qty span { min-width: 24px; text-align: center; font-size: 13px; }
.m6sc-qty-fixed { font-size: 12px; color: var(--m6-muted); }
.m6sc-remove { background: none; border: 0; padding: 0; color: var(--m6-muted); text-decoration: underline; font-size: 12px; cursor: pointer; min-height: 0; text-transform: none; }
.m6sc-price { font-weight: 500; white-space: nowrap; }
.m6sc-price .amount { color: inherit; }

.m6sc-recs { margin-top: 18px; }
.m6sc-recs-title { font-weight: 600; margin: 0 0 6px; }
.m6sc-recs li { display: flex; gap: 12px; align-items: center; padding: 10px 0; margin: 0; }
.m6sc-recs .m6sc-thumb { flex-basis: 56px; width: 56px; height: 56px; }
.m6sc-rec-price { display: block; font-size: 13px; color: var(--m6-muted); margin-top: 2px; }
.m6sc-rec-price .amount { color: #1a1a1a; }
.m6sc-add { flex: 0 0 auto; border: 1px solid #1a1a1a; background: #fff; color: #1a1a1a; border-radius: 6px; padding: 6px 14px; font-size: 13px; font-weight: 600; cursor: pointer; text-decoration: none; text-transform: none; min-height: 0; line-height: 1.4; }
.m6sc-add:hover { background: #1a1a1a; color: #fff; }

.m6sc-empty { text-align: center; padding: 50px 0; }
.m6sc-empty p { color: var(--m6-muted); margin-bottom: 18px; }

.m6sc-foot { border-top: 1px solid var(--m6-line); padding: 16px 20px calc(16px + env(safe-area-inset-bottom)); background: #fff; }
.m6sc-sub { display: flex; justify-content: space-between; font-size: 15px; margin-bottom: 4px; }
.m6sc-sub .amount { color: inherit; }
.m6sc-disc { font-size: 13px; color: #1f8f4e; }
.m6sc-note { margin: 4px 0 12px; font-size: 12px; color: var(--m6-muted); }
.m6sc-btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; height: 52px; border-radius: 6px; background: var(--m6-accent); color: #fff !important; font-size: 16px; font-weight: 600; text-decoration: none !important; text-transform: none; letter-spacing: .01em; }
.m6sc-btn .amount { color: #fff; }
.m6sc-btn:hover { opacity: .9; color: #fff; }
.m6sc-empty .m6sc-btn { display: inline-flex; width: auto; padding: 0 28px; }
.m6sc-viewcart { display: block; text-align: center; margin-top: 10px; font-size: 13px; color: var(--m6-muted); text-decoration: underline; }

/* Hide WoodMart's hover mini cart, mobile side cart and added-to-cart popup while the drawer is active. */
body .wd-header-cart .wd-dropdown-cart, body .cart-widget-side, body .wd-close-side.wd-close-side-opened ~ .cart-widget-side,
body .popup-added_to_cart, body .wd-popup-added { display: none !important; }

/* ---------- Styled cart page ---------- */
.m6cart { --m6-accent: #111; --m6-line: #e5e5e5; --m6-muted: #707070; max-width: 1120px; margin: 10px auto 40px; font-size: 14px; color: #1a1a1a; }
.m6cart *, .m6cart *::before, .m6cart *::after { box-sizing: border-box; }
.m6cart.is-busy { opacity: .55; pointer-events: none; }
.m6cart > .m6sc-head, .m6cart .m6sc-head { border: 0; padding: 0 0 16px; grid-column: 1 / -1; }
.m6cart .m6sc-head h3 { font-size: 26px; }
.m6cart { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 0 40px; align-items: start; }
.m6cart .m6sc-goal { grid-column: 1 / -1; border: 1px solid var(--m6-line); border-radius: 8px; margin-bottom: 18px; }
.m6cart .m6sc-body { padding: 0; overflow: visible; border-top: 1px solid var(--m6-line); }
.m6cart .m6sc-thumb { flex-basis: 100px; width: 100px; height: 100px; }
.m6cart .m6sc-item { padding: 20px 0; }
.m6cart .m6sc-name { font-size: 15px; }
.m6cart .m6sc-recs ul { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.m6cart .m6sc-recs li { flex-direction: column; align-items: flex-start; border: 1px solid var(--m6-line); border-radius: 8px; padding: 12px; }
.m6cart .m6sc-recs .m6sc-thumb { width: 100%; height: auto; aspect-ratio: 1 / 1; flex: none; }
.m6cart .m6sc-recs .m6sc-add { margin-top: auto; }
.m6cart .m6sc-foot { position: sticky; top: 30px; border: 1px solid var(--m6-line); border-radius: 8px; background: #fafafa; padding: 22px; }
.m6cart .m6sc-sub { font-size: 17px; }
.m6cart .m6sc-empty { grid-column: 1 / -1; }
.m6cart-trust { list-style: none; margin: 18px 0 0; padding: 14px 0 0; border-top: 1px solid var(--m6-line); display: grid; gap: 10px; }
.m6cart-trust li { display: flex; align-items: center; gap: 10px; font-size: 13px; margin: 0; }
.m6cart-trust .m6-ico { flex: 0 0 auto; color: var(--m6-accent); }
@media (max-width: 900px) {
	.m6cart { grid-template-columns: 1fr; padding: 0 4px; }
	.m6cart .m6sc-foot { position: static; margin-top: 20px; }
	.m6cart .m6sc-recs ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.m6cart .m6sc-thumb { flex-basis: 80px; width: 80px; height: 80px; }
}
/* Hide WooCommerce cart block leftovers + WoodMart cart steps on the styled cart page */
body.m6cart-page .wp-block-woocommerce-cart, body.m6cart-page .wd-checkout-steps { display: none !important; }
