/* ==========================================================================
   Commerce UI 1.5.0 — Cart · Checkout · Notices · Mobile footer join
   Loaded after theme.css + improvements.css. All colours except the CTA
   orange come from the theme tokens, so the Customizer still controls them.
   ========================================================================== */
:root {
  --cta: #F85506;            /* exact "Place Order" orange */
  --cta-hover: #DD4A02;
  --cta-ring: rgba(248, 85, 6, .28);
  --cx-card: var(--surface, #fff);
  --cx-line: var(--border, #e6e7df);
  --cx-soft: color-mix(in srgb, var(--primary) 6%, var(--surface, #fff));
  --cx-radius: 16px;
  --cx-shadow: 0 1px 2px rgba(20, 35, 28, .04), 0 10px 28px -18px rgba(20, 35, 28, .28);
}

/* ---------- 1. Orange call-to-action buttons -------------------------- */
body .woocommerce .wc-proceed-to-checkout a.checkout-button,
body .woocommerce a.checkout-button.button.alt,
body .woocommerce #place_order,
body .woocommerce button#place_order.button.alt {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 54px; margin: 0; padding: 14px 22px;
  background: var(--cta); color: #fff; border: 0; border-radius: 12px;
  font-size: 17px; font-weight: 700; letter-spacing: .01em; line-height: 1.2; text-align: center;
  box-shadow: 0 12px 24px -12px var(--cta-ring), 0 2px 0 rgba(255, 255, 255, .18) inset;
  transition: background-color .15s, transform .1s, box-shadow .15s;
  filter: none; opacity: 1;
}
body .woocommerce .wc-proceed-to-checkout a.checkout-button:hover,
body .woocommerce a.checkout-button.button.alt:hover,
body .woocommerce #place_order:hover,
body .woocommerce button#place_order.button.alt:hover { background: var(--cta-hover); color: #fff; filter: none; box-shadow: 0 14px 26px -12px var(--cta-ring); }
body .woocommerce .wc-proceed-to-checkout a.checkout-button:active,
body .woocommerce #place_order:active { transform: scale(.985); }
body .woocommerce .wc-proceed-to-checkout a.checkout-button:focus-visible,
body .woocommerce #place_order:focus-visible { outline: 3px solid var(--cta-ring); outline-offset: 2px; }
body .woocommerce #place_order:disabled,
body .woocommerce button#place_order.button.alt:disabled { background: var(--cta); opacity: .55; cursor: not-allowed; }
.woocommerce .wc-proceed-to-checkout a.checkout-button::after {
  content: ""; width: 18px; height: 18px; flex: none; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* mini-cart drawer "Proceed to Checkout" */
body .drawer a.button.checkout-link, body a.button.checkout-link {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 54px; padding: 14px 22px;
  background: var(--cta); color: #fff; border: 0; border-radius: 12px; font-size: 17px; font-weight: 700; line-height: 1.2;
  box-shadow: 0 12px 24px -12px var(--cta-ring), 0 2px 0 rgba(255,255,255,.18) inset; filter: none;
  transition: background-color .15s, transform .1s;
}
body .drawer a.button.checkout-link:hover, body a.button.checkout-link:hover { background: var(--cta-hover); color: #fff; filter: none; }
body .drawer a.button.checkout-link:active { transform: scale(.985); }
body a.button.checkout-link .icon { width: 20px; height: 20px; }

/* ---------- 2. Notices (added to cart / info / error) ----------------- */
.woocommerce-notices-wrapper { margin: 0; }
body .woocommerce-message.woocommerce-message,
body .woocommerce-info.woocommerce-info,
body .woocommerce-error.woocommerce-error {
  position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px;
  margin: 0 0 18px; padding: 14px 16px 14px 62px; min-height: 64px;
  list-style: none; font-size: 15px; line-height: 1.5; color: var(--text);
  background: linear-gradient(0deg, var(--cx-soft), var(--cx-soft)), var(--cx-card);
  border: 1px solid color-mix(in srgb, var(--primary) 20%, var(--cx-line));
  border-left: 1px solid color-mix(in srgb, var(--primary) 20%, var(--cx-line));
  border-radius: var(--cx-radius); box-shadow: var(--cx-shadow); outline: 0;
}
body .woocommerce-message::before,
body .woocommerce-info::before,
body .woocommerce-error::before {
  content: ""; position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; margin: 0; font: 0/0 a; border-radius: 50%;
  background: var(--primary);
  -webkit-mask: var(--cx-ico) center/32px 32px no-repeat; mask: var(--cx-ico) center/32px 32px no-repeat;
}
body .woocommerce-message.woocommerce-message { --cx-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M12 2a10 10 0 100 20 10 10 0 000-20zm4.7 7.3a1 1 0 010 1.4l-5.4 5.4a1 1 0 01-1.4 0l-2.6-2.6a1 1 0 111.4-1.4l1.9 1.9 4.7-4.7a1 1 0 011.4 0z'/%3E%3C/svg%3E"); }
body .woocommerce-info.woocommerce-info { --cx-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M12 2a10 10 0 100 20 10 10 0 000-20zm-1 5h2v2h-2zm0 4h2v6h-2z'/%3E%3C/svg%3E"); }
body .woocommerce-error.woocommerce-error { --cx-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M12 2a10 10 0 100 20 10 10 0 000-20zm-1 5h2v6h-2zm0 8h2v2h-2z'/%3E%3C/svg%3E"); }
body .woocommerce-error.woocommerce-error { background: #fff6f5; border-color: #f3c6c2; display: block; }
body .woocommerce-error::before { background: #d33d3d; top: 22px; transform: none; }
body .woocommerce-error.woocommerce-error li { margin: 0; padding: 2px 0; }
body .woocommerce-error.woocommerce-error a { color: var(--primary); font-weight: 600; }
body .woocommerce-message.woocommerce-message > a.button,
body .woocommerce-info.woocommerce-info > a.button {
  order: 2; margin: 0 0 0 auto; float: none; flex: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 22px; border-radius: 999px;
  background: var(--primary); color: var(--button-text, #fff); border: 0;
  font-size: 14.5px; font-weight: 700; line-height: 1; white-space: nowrap;
  box-shadow: 0 8px 18px -10px color-mix(in srgb, var(--primary) 80%, #000);
  transition: filter .15s, transform .1s;
}
body .woocommerce-message.woocommerce-message > a.button:hover,
body .woocommerce-info.woocommerce-info > a.button:hover { background: var(--primary); filter: brightness(1.12); color: var(--button-text, #fff); }
body .woocommerce-message.woocommerce-message > a.button:active { transform: scale(.97); }
@media (max-width: 600px) {
  body .woocommerce-message.woocommerce-message, body .woocommerce-info.woocommerce-info { padding: 14px 14px 14px 58px; }
  body .woocommerce-message::before, body .woocommerce-info::before { top: 20px; transform: none; left: 14px; }
  body .woocommerce-message.woocommerce-message > a.button, body .woocommerce-info.woocommerce-info > a.button { width: 100%; margin: 2px 0 0; min-height: 46px; }
  /* text first, button below it */
  body .woocommerce-message.woocommerce-message, body .woocommerce-info.woocommerce-info { align-items: flex-start; }
}
@keyframes cx-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
body .woocommerce-message.woocommerce-message, body .woocommerce-error.woocommerce-error, body .woocommerce-info.woocommerce-info { animation: cx-in .28s ease-out both; }
@media (prefers-reduced-motion: reduce) { body .woocommerce-message.woocommerce-message, body .woocommerce-error.woocommerce-error, body .woocommerce-info.woocommerce-info { animation: none; } }

/* ---------- 3. Cart ---------------------------------------------------- */
.woocommerce-cart .woocommerce-cart-form,
.woocommerce-cart .cart-collaterals .cart_totals {
  background: var(--cx-card); border: 1px solid var(--cx-line);
  border-radius: calc(var(--cx-radius) + 2px); box-shadow: var(--cx-shadow); padding: 22px;
}
.woocommerce-cart .cart_totals h2 { font-size: 19px; font-weight: 700; margin: 0 0 6px; }
.woocommerce-cart table.cart { border: 0; margin: 0; border-collapse: collapse; width: 100%; }
.woocommerce-cart table.cart th.product-thumbnail, .woocommerce-cart table.cart td.product-thumbnail { width: 100px; }
.woocommerce-cart table.cart th.product-remove, .woocommerce-cart table.cart td.product-remove { width: 44px; padding-left: 0; padding-right: 0; text-align: center; }
.woocommerce-cart table.cart th.product-name { text-align: left; } .woocommerce-cart table.cart th.product-quantity { text-align: center; } .woocommerce-cart table.cart td.product-quantity { text-align: center; } .woocommerce-cart table.cart td.product-price, .woocommerce-cart table.cart td.product-subtotal, .woocommerce-cart table.cart th.product-price, .woocommerce-cart table.cart th.product-subtotal { white-space: nowrap; }
.woocommerce-cart table.cart thead th {
  padding: 0 10px 12px; border: 0; border-bottom: 1px solid var(--cx-line);
  font-size: 12px; font-weight: 700; letter-spacing: .08em; color: var(--muted); text-transform: uppercase;
}
.woocommerce-cart table.cart td { padding: 18px 10px; border-top: 1px solid var(--cx-line); }
.woocommerce-cart table.cart tbody tr:first-child td { border-top: 0; }
.woocommerce-cart table.cart img { width: 84px; height: 84px; object-fit: cover; border-radius: 14px; border: 1px solid var(--cx-line); background: #f4f3ec; }
.woocommerce-cart table.cart td.product-name a { font-size: 16px; font-weight: 600; line-height: 1.4; color: var(--text); }
.woocommerce-cart table.cart td.product-name a:hover { color: var(--primary); }
.woocommerce-cart table.cart td.product-name dl.variation { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.woocommerce-cart table.cart td.product-price { color: var(--muted); }
.woocommerce-cart table.cart td.product-subtotal { font-weight: 700; font-size: 17px; color: var(--cta); white-space: nowrap; }
.woocommerce-cart table.cart td.product-subtotal .amount { font-family: var(--font-price); }
.woocommerce-cart table.cart del { color: var(--muted); font-weight: 400; font-size: 14px; }
.woocommerce-cart table.cart ins { text-decoration: none; }
.woocommerce-cart table.cart .product-remove a.remove {
  display: grid; place-items: center; width: 34px; height: 34px; margin: 0; padding: 0;
  border-radius: 50%; background: #f5f3ee; color: var(--muted) !important; font-size: 19px; line-height: 1;
  transition: background-color .15s, color .15s;
}
.woocommerce-cart table.cart .product-remove a.remove:hover { background: #fde9e7; color: #d33d3d !important; }
.woocommerce-cart .quantity.has-stepper { height: 40px; background: #fff; }
.woocommerce-cart .quantity.has-stepper > .qty-btn { width: 36px; }
.woocommerce-cart .quantity.has-stepper > input.qty.qty { width: 34px; font-size: 15px; }

/* coupon + update row */
@media (min-width: 769px) {
  .woocommerce-cart table.cart td.actions { display: table-cell; padding: 18px 0 0; border-top: 1px solid var(--cx-line); }
  .woocommerce-cart table.cart td.actions::after { content: ""; display: block; clear: both; }
  .woocommerce-cart table.cart td.actions .coupon { float: left; display: flex; gap: 8px; width: min(440px, 100%); }
  .woocommerce-cart table.cart td.actions button[name=update_cart] { float: right; }
  .woocommerce-cart table.cart td.product-name { width: 38%; min-width: 180px; }
}
.woocommerce-cart table.cart td.actions { padding-top: 18px; }
.woocommerce-cart .actions .coupon input.input-text {
  min-height: 46px; border: 1.5px solid var(--cx-line); border-radius: 12px; background: #fff; padding: 0 14px;
}
.woocommerce-cart .actions .coupon input.input-text:focus { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 15%, transparent); }
.woocommerce-cart .actions .coupon button.button {
  min-height: 46px; border-radius: 12px; background: var(--primary); color: var(--button-text, #fff); border: 0; font-weight: 600; padding: 0 20px;
}
.woocommerce-cart .actions button[name=update_cart] {
  min-height: 46px; border-radius: 12px; background: transparent; color: var(--primary);
  border: 1.5px solid color-mix(in srgb, var(--primary) 45%, transparent); font-weight: 600;
}
.woocommerce-cart .actions button[name=update_cart],
.woocommerce-cart .actions input[name=update_cart],
.woocommerce-cart-form button[name=update_cart] { display: none !important; }   /* 1.6.11: quantity auto-saves — the button stays in the DOM (WooCommerce needs it) but is never shown */
.woocommerce-cart table.cart td.actions { background: none !important; }
.woocommerce-cart table.cart td.actions .coupon { display: flex; gap: 8px; width: 100%; float: none; }
.woocommerce-cart table.cart td.actions .coupon input.input-text { flex: 1 1 auto; min-width: 0; width: auto; }
.woocommerce-cart table.cart td.actions .coupon button.button { flex: none; white-space: nowrap; }

/* totals */
.woocommerce-cart .cart_totals table.shop_table { border: 0; margin: 0 0 4px; width: 100%; }
.woocommerce-cart .cart_totals th, .woocommerce-cart .cart_totals td { padding: 13px 0; border-top: 1px solid var(--cx-line); font-size: 15px; background: none; }
.woocommerce-cart .cart_totals th { font-weight: 500; color: var(--muted); text-align: left; }
.woocommerce-cart .cart_totals td { text-align: right; font-weight: 600; }
.woocommerce-cart .cart_totals .order-total th { color: var(--text); font-weight: 700; font-size: 16px; }
.woocommerce-cart .cart_totals .order-total td { font-size: 22px; font-weight: 800; color: var(--cta); font-family: var(--font-price); }
.woocommerce-cart .cart_totals .order-total small { display: block; font-size: 12px; font-weight: 400; color: var(--muted); }
.woocommerce-cart .wc-proceed-to-checkout { padding: 14px 0 0; margin: 0; }
.ship-progress { border: 1px dashed color-mix(in srgb, var(--primary) 35%, transparent); background: var(--cx-soft); border-radius: 14px; }
.ship-progress .bar { background: #fff; }

/* cart — mobile cards */
@media (max-width: 768px) {
  .woocommerce-cart .woocommerce-cart-form, .woocommerce-cart .cart-collaterals .cart_totals { padding: 14px; border-radius: 18px; }
  .woocommerce-cart table.cart thead { display: none; }
  .woocommerce-cart table.cart.shop_table_responsive tr.woocommerce-cart-form__cart-item {
    position: relative; display: grid; grid-template-columns: 88px 1fr; grid-template-rows: auto auto auto;
    gap: 6px 14px; padding: 14px 0; border: 0; border-top: 1px solid var(--cx-line); margin: 0;
  }
  .woocommerce-cart table.cart.shop_table_responsive tr.woocommerce-cart-form__cart-item:first-child { border-top: 0; padding-top: 2px; }
  .woocommerce-cart table.cart tr.woocommerce-cart-form__cart-item td { padding: 0 !important; border: 0 !important; text-align: left !important; }
  .woocommerce-cart table.cart td.product-thumbnail { grid-column: 1; grid-row: 1 / 4; }
  .woocommerce-cart table.cart td.product-thumbnail img { width: 88px; height: 88px; }
  .woocommerce-cart table.cart td.product-name { grid-column: 2; grid-row: 1; padding-right: 38px !important; font-size: 15px; }
  .woocommerce-cart table.cart td.product-name a { font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .woocommerce-cart table.cart tr.woocommerce-cart-form__cart-item td.product-price { display: none; }
  .woocommerce-cart table.cart td.product-quantity { grid-column: 2; grid-row: 3; align-self: end; justify-self: start; }
  .woocommerce-cart table.cart td.product-subtotal { grid-column: 2; grid-row: 2; font-size: 18px; align-self: center; }
  .woocommerce-cart table.cart tr.woocommerce-cart-form__cart-item td.product-remove { position: absolute; top: 8px; right: 0; width: auto; }
  .woocommerce-cart table.cart tr.woocommerce-cart-form__cart-item:first-child td.product-remove { top: -2px; }
  .woocommerce-cart table.cart tr.woocommerce-cart-form__cart-item td.product-remove a.remove { width: 30px; height: 30px; font-size: 17px; }
  .woocommerce-cart table.cart td.product-quantity::before, .woocommerce-cart table.cart td.product-subtotal::before { display: none !important; }
  .woocommerce-cart table.cart tr:has(td.actions) { display: block; border-top: 1px solid var(--cx-line); }
  /* sticky checkout bar above the bottom nav */
  .woocommerce-cart .wc-proceed-to-checkout {
    position: sticky; bottom: calc(var(--cx-nav, 0px) + 12px); z-index: 20;
    margin: 12px -4px 0; padding: 10px; background: color-mix(in srgb, var(--cx-card) 94%, transparent);
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
    border: 1px solid var(--cx-line); border-radius: 18px; box-shadow: 0 -8px 26px -14px rgba(20, 35, 28, .35);
  }
}
.has-mobile-nav { --cx-nav: calc(78px + env(safe-area-inset-bottom)); } /* JS replaces this with the nav's real height */
@media (min-width: 761px) { .has-mobile-nav { --cx-nav: 0px; } }

/* ---------- 4. Checkout → see checkout-ui.css ---------- */

/* ---------- 5. Footer ↔ mobile bottom nav: no light strip -------------- */
/* The nav's reserved space used to be padding on the <footer>, so a band of the footer's own
   background colour showed *underneath* the copyright bar — it read as an empty block after the
   last line of the site. The space now sits inside the copyright bar itself: the bar keeps
   colouring the page all the way down, the nav floats over it, and the copyright row is the last
   thing a visitor can read. (1.6.3) */
.has-mobile-nav { padding-bottom: 0 !important; }
@media (max-width: 760px) {
  .has-mobile-nav .site-footer { margin-bottom: 0; padding-bottom: 0; }
  .has-mobile-nav .site-footer .footer-copyright { padding-bottom: calc(var(--cx-nav, 78px) + 12px); }
  /* product pages: also clear the floating "Choose & buy" bar */
  .has-mobile-nav.single-product .site-footer .footer-copyright { padding-bottom: calc(var(--cx-nav, 78px) + 86px); }
}
@media (min-width: 761px) { .has-mobile-nav .site-footer, .has-mobile-nav .site-footer .footer-copyright { padding-bottom: 0; } }

/* Footer headings (1.6.3) ----------------------------------------------------------------------
   The Customizer prints a global `html h2 { color: … }` (the dark content-heading colour), which
   beat plain inheritance inside the dark footer: widget titles like "Archives" rendered dark-green
   on the navy footer and were unreadable. Footer headings now follow the footer's own text colour
   (still Customizer-driven through --footer-text / style-light), and widget titles are sized like
   the footer's own headings instead of the 32px content scale. */
.site-footer h1, .site-footer h2, .site-footer h3, .site-footer h4,
.site-footer .wp-block-heading { color: var(--footer-text); }
.site-footer .footer-widget .wp-block-heading { font-size: 20px; line-height: 1.35; margin: 0 0 12px; }
@media (max-width: 760px) { .site-footer .footer-widget .wp-block-heading { font-size: 18px; } }
