/* MoodTag WooCommerce pages (0.10.7, work item 60): cart, checkout, my account, order received, in the product page
   layer's look. Look only: no template, payment or script changes, so WooCommerce, the add-on plugin (EPO) lines, the
   Live Preview data, Stripe, PayPal and the tracking events run exactly as before. Stripe's and PayPal's own fields
   are iframes and keep their look; only what is around them is styled. Scope: body.mtd-woo (set by woo.php).
   Additional CSS styles some of these with !important (shipping options, the Stripe list item): those rules are kept
   where they do layout; !important here only where a colour/border/radius has to win over one. Greens only. */

body.mtd-woo #wrapper {
  --sand: #f4f1ea; --sand-2: #e8e3d8; --cream: #fbf9f4; --ink: #1a202c; --ink-2: #2d3748; --muted: #5f6a64;
  --terra: #2fa66a; --terra-ink: #1f7a4c; --olive: #13612e; --olive-soft: #dff3e7; --rust: #b42318;
  --serif: "Fraunces", Georgia, serif; --sans: "Jakarta", system-ui, sans-serif; --r: 24px;
  background: var(--sand); color: var(--ink-2); font-family: var(--sans);
}
body.mtd-woo #wrapper #inner-wrap, body.mtd-woo #wrapper .content-area, body.mtd-woo #wrapper .site-main { background: transparent; }

/* ---------- the page card and headings ---------- */
body.mtd-woo #wrapper .content-container.site-container { max-width: 1200px; }
body.mtd-woo #wrapper .entry.content-bg { background: #fff; border: 1px solid var(--sand-2); border-radius: 28px; box-shadow: none; }
body.mtd-woo #wrapper .entry-title { font: 800 clamp(32px, 4vw, 48px)/1.05 var(--serif); letter-spacing: -.01em; text-transform: none; color: var(--ink); }
body.mtd-woo #wrapper .entry-content :is(h2, h3):not(.woocommerce-loop-product__title):not(.mt-checkout-guarantees__title) { font: 800 clamp(21px, 2.2vw, 26px)/1.2 var(--serif); letter-spacing: -.005em; text-transform: none; color: var(--ink); }
body.mtd-woo #wrapper .entry-content a:not(.button):not(.remove):not(.woocommerce-LoopProduct-link):not(.woocommerce-loop-product__link) { color: var(--terra-ink); }

/* ---------- form fields ---------- */
body.mtd-woo #wrapper .entry-content :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], textarea, select) {
  min-height: 48px; padding: 10px 14px; border: 1.5px solid var(--sand-2); border-radius: 14px; background: #fff; color: var(--ink);
  font: 500 16px/1.4 var(--sans); box-shadow: none; transition: border-color .15s ease, box-shadow .15s ease;
}
body.mtd-woo #wrapper .entry-content textarea { min-height: 96px; }
body.mtd-woo #wrapper .entry-content :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], textarea, select):focus {
  border-color: var(--terra); box-shadow: 0 0 0 3px rgba(47, 166, 106, .2); outline: none;
}
body.mtd-woo #wrapper .entry-content .select2-container .select2-selection--single { height: 48px; border: 1.5px solid var(--sand-2); border-radius: 14px; background: #fff; }
body.mtd-woo #wrapper .entry-content .select2-container .select2-selection--single .select2-selection__rendered { line-height: 45px; padding-left: 14px; color: var(--ink); font: 500 16px/45px var(--sans); }
body.mtd-woo #wrapper .entry-content .select2-container .select2-selection--single .select2-selection__arrow { height: 45px; right: 8px; }
body.mtd-woo #wrapper .entry-content .select2-container--focus .select2-selection--single, body.mtd-woo #wrapper .entry-content .select2-container--open .select2-selection--single { border-color: var(--terra); box-shadow: 0 0 0 3px rgba(47, 166, 106, .2); }
body.mtd-woo #wrapper .entry-content .form-row label, body.mtd-woo #wrapper .entry-content .woocommerce-form-row label { font: 700 14px/1.4 var(--sans); color: var(--ink); }
body.mtd-woo #wrapper .entry-content .form-row .required { color: var(--rust); }
body.mtd-woo #wrapper .entry-content input[type="checkbox"], body.mtd-woo #wrapper .entry-content input[type="radio"] { accent-color: var(--terra-ink); }

/* ---------- buttons: the layer's pills ---------- */
body.mtd-woo #wrapper .entry-content :is(.button, button.button, input.button) {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 10px 22px;
  border: 0; border-radius: 999px; background: #fff; box-shadow: inset 0 0 0 1.5px var(--terra-ink); color: var(--terra-ink);
  font: 700 15px/1.2 var(--sans); letter-spacing: 0; text-transform: none; transition: background-color .15s ease, color .15s ease;
}
body.mtd-woo #wrapper .entry-content :is(.button, button.button):hover { background: var(--olive-soft); color: var(--olive); }
body.mtd-woo #wrapper .entry-content :is(.button, button.button):disabled, body.mtd-woo #wrapper .entry-content .button.disabled { opacity: .45; }
body.mtd-woo #wrapper .entry-content :is(.button.alt, button.button.alt, #place_order, .checkout-button) {
  min-height: 54px; background: var(--terra-ink); box-shadow: none; color: #fff; font-size: 16px;
}
body.mtd-woo #wrapper .entry-content :is(.button.alt, #place_order, .checkout-button):hover { background: var(--olive); color: #fff; }
body.mtd-woo #wrapper .entry-content :is(.button, button):focus-visible { outline: 3px solid rgba(47, 166, 106, .45); outline-offset: 3px; }

/* ---------- cart ---------- */
body.mtd-woo #wrapper .woocommerce-cart-form .shop_table { border: 0; border-collapse: collapse; }
body.mtd-woo #wrapper .woocommerce-cart-form .shop_table th { font: 800 11px/1.3 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--terra-ink); border: 0; }
body.mtd-woo #wrapper .woocommerce-cart-form .shop_table td { border-top: 1px solid var(--sand-2); padding-top: 16px; padding-bottom: 16px; }
body.mtd-woo #wrapper .woocommerce-cart-form .product-name a { color: var(--ink); font-weight: 700; text-decoration: none; }
body.mtd-woo #wrapper .woocommerce-cart-form .product-name a:hover { text-decoration: underline; }
body.mtd-woo #wrapper .woocommerce-cart-form .product-name :is(dl.variation, .tc-epo-metadata, .tm-cart-edit-options) { font-size: 13.5px; color: var(--muted); }
body.mtd-woo #wrapper .woocommerce-cart-form .product-thumbnail img { width: 64px; border-radius: 14px; }
body.mtd-woo #wrapper .woocommerce-cart-form a.remove { width: 30px; height: 30px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--sand); color: var(--rust) !important; font-weight: 700; }
body.mtd-woo #wrapper .woocommerce-cart-form a.remove:hover { background: #fdf1f0; }
body.mtd-woo #wrapper .woocommerce-cart-form .quantity .qty { width: 76px; text-align: center; }
body.mtd-woo #wrapper .woocommerce-cart-form .actions .coupon { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
body.mtd-woo #wrapper .woocommerce-cart-form .actions .coupon .input-text { width: 200px; }
body.mtd-woo #wrapper .cart_totals { padding: clamp(18px, 2.4vw, 26px); border: 1px solid var(--sand-2); border-radius: 22px; background: var(--cream); }
body.mtd-woo #wrapper .cart_totals .shop_table { border: 0; }
body.mtd-woo #wrapper .cart_totals .shop_table :is(th, td) { border-top: 1px solid var(--sand-2); background: transparent; }
body.mtd-woo #wrapper .cart_totals .order-total :is(th, td) { font-size: 18px; color: var(--ink); }
body.mtd-woo #wrapper .cart_totals .wc-proceed-to-checkout .checkout-button { width: 100%; }
/* cross-sells: the product page related-card look */
body.mtd-woo #wrapper .cross-sells ul.products > li.product { border-radius: 22px; background: #fff; border: 1px solid var(--sand-2); overflow: hidden; }
body.mtd-woo #wrapper .cross-sells li.product .woocommerce-loop-product__title { font: 800 17px/1.25 var(--serif) !important; letter-spacing: 0 !important; text-transform: none !important; color: var(--ink) !important; }
body.mtd-woo #wrapper .cross-sells li.product .woocommerce-loop-product__title a { color: inherit; text-decoration: none; }
body.mtd-woo #wrapper .cross-sells li.product .price { color: var(--terra-ink); font-weight: 700; }
body.mtd-woo #wrapper .cross-sells li.product .button { width: auto; max-width: 100%; background: var(--terra-ink) !important; box-shadow: none; color: #fff !important; font-size: 14px !important; letter-spacing: 0 !important; text-transform: none !important; padding: 10px 18px !important; }
body.mtd-woo #wrapper .cross-sells li.product .button:hover { background: var(--olive) !important; }
/* phones: WooCommerce stacks each cart row with its labels; each item becomes a card */
@media (max-width: 768px) {
  body.mtd-woo #wrapper .woocommerce-cart-form .shop_table_responsive tr.cart_item { display: block; margin: 0 0 14px; padding: 8px 14px; border: 1px solid var(--sand-2); border-radius: 20px; background: var(--cream); }
  body.mtd-woo #wrapper .woocommerce-cart-form .shop_table_responsive tr.cart_item td { border-top: 1px solid var(--sand-2); background: transparent; }
  body.mtd-woo #wrapper .woocommerce-cart-form .shop_table_responsive tr.cart_item td:first-child { border-top: 0; }
  body.mtd-woo #wrapper .woocommerce-cart-form .actions .coupon .input-text { width: 100%; }
  body.mtd-woo #wrapper .woocommerce-cart-form .actions .coupon .button, body.mtd-woo #wrapper .woocommerce-cart-form .actions > .button { width: 100%; }
}

/* ---------- checkout ---------- */
/* "— OR —" under the express buttons (Stripe's own paragraph): a thin line with "or" on it; the words stay in the page */
body.mtd-woo #wrapper #wc-stripe-express-checkout-button-separator { position: relative; margin: 20px 0 8px !important; font-size: 0 !important; line-height: 0; text-align: center; background: linear-gradient(var(--sand-2), var(--sand-2)) center / 100% 1px no-repeat; min-height: 20px; }
body.mtd-woo #wrapper #wc-stripe-express-checkout-button-separator::before { content: "or"; display: inline-block; padding: 0 14px; background: #fff; color: var(--muted); font: 700 13px/20px var(--sans); text-transform: uppercase; letter-spacing: .1em; }
body.mtd-woo #wrapper .woocommerce-checkout #order_review, body.mtd-woo #wrapper form.checkout #order_review { padding: clamp(18px, 2.4vw, 26px); border: 1px solid var(--sand-2); border-radius: 22px; background: var(--cream); }
body.mtd-woo #wrapper .woocommerce-checkout-review-order-table { border: 0; }
body.mtd-woo #wrapper .woocommerce-checkout-review-order-table :is(th, td) { border-top: 1px solid var(--sand-2); background: transparent; }
body.mtd-woo #wrapper .woocommerce-checkout-review-order-table .product-name :is(dl.variation, .tc-epo-metadata) { font-size: 13.5px; color: var(--muted); }
body.mtd-woo #wrapper .woocommerce-checkout-review-order-table .order-total :is(th, td) { font-size: 18px; color: var(--ink); }
body.mtd-woo #wrapper #payment { background: transparent; border-radius: 0; }
body.mtd-woo #wrapper #payment ul.payment_methods { padding: 0; border: 0; }
body.mtd-woo #wrapper #payment ul.payment_methods li.wc_payment_method { margin: 0 0 10px; padding: 14px 16px !important; border: 1px solid var(--sand-2) !important; border-radius: 18px !important; background: #fff !important; }
body.mtd-woo #wrapper #payment ul.payment_methods li.wc_payment_method > label { font: 700 15px/1.4 var(--sans); color: var(--ink); }
body.mtd-woo #wrapper #payment div.payment_box { margin: 10px 0 0; padding: 0; background: transparent !important; }
body.mtd-woo #wrapper #payment div.payment_box::before { display: none; }
body.mtd-woo #wrapper #payment .place-order { padding: 8px 0 0; }
body.mtd-woo #wrapper #payment #place_order { width: 100%; }
body.mtd-woo #wrapper .mt-checkout-guarantees { border-radius: 20px; }

/* ---------- my account ---------- */
body.mtd-woo #wrapper form:is(.woocommerce-form-login, .woocommerce-form-register, .woocommerce-ResetPassword, .lost_reset_password) { padding: clamp(18px, 2.4vw, 28px); border: 1px solid var(--sand-2); border-radius: 22px; background: var(--cream); }
body.mtd-woo #wrapper .woocommerce-MyAccount-navigation ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
body.mtd-woo #wrapper .woocommerce-MyAccount-navigation li a { display: block; padding: 10px 16px; border-radius: 999px; color: var(--ink-2); font-weight: 700; text-decoration: none; }
body.mtd-woo #wrapper .woocommerce-MyAccount-navigation li a:hover { background: var(--sand); }
body.mtd-woo #wrapper .woocommerce-MyAccount-navigation li.is-active a { background: var(--olive-soft); color: var(--olive); }
body.mtd-woo #wrapper .woocommerce-MyAccount-content .shop_table, body.mtd-woo #wrapper .woocommerce-table--order-details { border: 1px solid var(--sand-2); border-radius: 18px; border-collapse: separate; overflow: hidden; }
body.mtd-woo #wrapper .woocommerce-MyAccount-content .shop_table :is(th, td), body.mtd-woo #wrapper .woocommerce-table--order-details :is(th, td) { border-top: 1px solid var(--sand-2); background: transparent; }
body.mtd-woo #wrapper .woocommerce-Addresses .woocommerce-Address, body.mtd-woo #wrapper .woocommerce-customer-details address { padding: 18px 20px; border: 1px solid var(--sand-2); border-radius: 18px; background: var(--cream); }

/* ---------- order received ---------- */
body.mtd-woo #wrapper .woocommerce-thankyou-order-received { font: 800 clamp(22px, 2.6vw, 30px)/1.2 var(--serif); color: var(--ink); }
body.mtd-woo #wrapper ul.woocommerce-order-overview { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 24px; padding: 0; list-style: none; }
body.mtd-woo #wrapper ul.woocommerce-order-overview li { margin: 0; padding: 12px 16px; border: 1px solid var(--sand-2) !important; border-radius: 16px; background: var(--cream); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
body.mtd-woo #wrapper ul.woocommerce-order-overview li strong { display: block; margin-top: 4px; font: 700 16px/1.3 var(--sans); text-transform: none; letter-spacing: 0; color: var(--ink); }

/* empty cart: the line under the notice (woo.php) */
body.mtd-woo #wrapper .mtd-empty-cart { margin: -6px 0 22px; font: 500 16px/1.6 var(--sans); color: var(--ink-2); }
body.mtd-woo #wrapper .mtd-empty-cart a { color: var(--terra-ink); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
body.mtd-woo #wrapper .return-to-shop .button { background: var(--terra-ink); box-shadow: none; color: #fff; }
body.mtd-woo #wrapper .return-to-shop .button:hover { background: var(--olive); color: #fff; }

/* coupon errors: WooCommerce shows them inline under the coupon field (e.g. an expired code), not as a notice */
body.mtd-woo #wrapper .coupon-error-notice { display: flex; align-items: center; gap: 8px; flex-basis: 100%; margin: 4px 0 0; color: var(--rust); font: 700 14px/1.4 var(--sans); }
body.mtd-woo #wrapper .coupon-error-notice::before { content: "!"; flex: none; width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; background: var(--rust); color: #fff; font: 800 13px/1 var(--sans); }
body.mtd-woo #wrapper .coupon:has(.coupon-error-notice) .input-text { border-color: var(--rust); }

/* checkout "Your order" on phones: the product column had ~90px and broke words ("Stainle ss"); the shipping options sat
   beside a "Shipment" label. Slimmer padding, words break only between words, the price column as narrow as its
   content, and the shipping row stacked under its label. */
@media (max-width: 600px) {
  body.mtd-woo #wrapper form.checkout #order_review { padding: 14px 12px; }
  body.mtd-woo #wrapper .woocommerce-checkout-review-order-table :is(th, td) { padding: 10px 8px; word-break: normal; overflow-wrap: break-word; hyphens: manual; }
  body.mtd-woo #wrapper .woocommerce-checkout-review-order-table td.product-total, body.mtd-woo #wrapper .woocommerce-checkout-review-order-table th.product-total { width: 1%; white-space: nowrap; text-align: right; }
  body.mtd-woo #wrapper .woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals > :is(th, td) { display: block; width: auto; border-top: 0; padding-top: 4px; }
  body.mtd-woo #wrapper .woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals > th { border-top: 1px solid var(--sand-2); padding-top: 12px; }
}

/* SAGE's crop review (27 Oct). The page H1 here is a Kadence heading block in the page content, not .entry-title:
   same Fraunces title as the other pages. */
body.mtd-woo #wrapper .entry-content h1.wp-block-kadence-advancedheading { font: 800 clamp(32px, 4vw, 48px)/1.05 var(--serif); letter-spacing: -.01em; text-transform: none; color: var(--ink); }
/* Cart: Kadence's "Cart Summary" heading straight under the "Cart" H1 becomes a small kicker */
body.mtd-woo #wrapper .entry-content .kadence-woo-cart-form-wrap .cart-summary h2 { font: 800 12px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--terra-ink); margin: 0 0 12px; }
/* Checkout: "Have a discount code?" is the green link only, no empty bar behind it */
body.mtd-woo #wrapper .woocommerce-form-coupon-toggle .woocommerce-info { background: none !important; border: 0 !important; box-shadow: none !important; border-radius: 0 !important; min-height: 0; padding: 0 !important; }
body.mtd-woo #wrapper .woocommerce-form-coupon-toggle .showcoupon { font: 700 15px/1.4 var(--sans); text-decoration: underline; text-underline-offset: 3px; }
/* Checkout: the notes field has its own label and the "Add an order note" toggle, so the empty
   "Additional information" heading is hidden */
body.mtd-woo #wrapper .woocommerce-additional-fields:has(.mt-order-notes-toggle) > h3 { display: none; }

/* My account title band (SAGE's account check, 27 Oct): Kadence's page title hero on a pale blue-grey; the page sand
   instead, like the other pages. */
body.mtd-woo #wrapper .entry-hero .entry-hero-container-inner, body.mtd-woo #wrapper .entry-hero .hero-section-overlay { background: transparent; }
body.mtd-woo #wrapper .entry-hero.page-hero-section .entry-header { min-height: 0; padding: 48px 0 8px; }
