/* Commerce presentation only: native WooCommerce totals, fields, gateway
   controls, errors and checkout actions retain their original DOM and behavior. */
.bhq-cart-page .bhq-added-to-cart .wc-forward { display: none; }
.bhq-checkout-page .bhq-added-to-cart .wc-forward { display: none; }
/* Checkout has two steps for every role, including administrators. */
:is(.bhq-checkout-page, .bhq-order-page) .bhq-steps li:not(.is-complete)::before { content: counter(bhq-step); }
/* Existing saved headers/checkout blocks may still contain cart links. The
   server enforces access; these rules remove redundant customer navigation. */
.bhq-customer-journey .bhq-added-to-cart .wc-forward,
.bhq-customer-journey .wc-block-components-checkout-return-to-cart-button,
.bhq-customer-journey .bhq-back-link:not(.bhq-return-to-pricing) { display: none; }
.bhq-main .bhq-steps {
  width: fit-content; max-width: 100%; padding: 0; gap: .75rem;
  border: 0; border-radius: 0; background: transparent;
  font-family: var(--wp--preset--font-family--body);
}
.bhq-main .bhq-steps li {
  padding: .5rem 0; gap: .625rem; background: transparent;
  color: var(--wp--preset--color--muted);
}
.bhq-main .bhq-steps li:not(:last-child)::after {
  content: ''; width: clamp(1rem, 3vw, 3rem); height: 1px; margin-left: .25rem;
  background: var(--wp--preset--color--line);
}
.bhq-main .bhq-steps .is-current { color: var(--wp--preset--color--navy); font-weight: 700; }
.bhq-main .bhq-steps .is-complete { color: var(--wp--preset--color--blue); }
.bhq-main .bhq-steps li::before { flex-shrink: 0; width: 30px; height: 30px; }
.bhq-main .bhq-steps .is-current::before { box-shadow: 0 0 0 4px var(--wp--preset--color--sand); }

/* Independent cards eliminate the large empty cart shell. Woo's is-large
   class remains the source of truth for the two-column breakpoint. */
:is(.bhq-main, .editor-styles-wrapper) .wp-block-woocommerce-cart {
  padding: 0; border: 0; background: transparent; box-shadow: none;
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart {
  min-height: 0; margin-bottom: 0; align-items: flex-start; gap: 1.5rem;
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart__main,
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart__sidebar {
  padding: clamp(1.125rem, 2.5vw, 1.75rem); margin: 0; min-width: 0;
  border: 1px solid var(--wp--preset--color--line);
  border-radius: var(--bhq-card-radius); background: var(--wp--preset--color--white);
  box-shadow: 0 12px 36px #192d4405;
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart.is-large .wc-block-cart__main { width: calc(60% - .75rem); }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart.is-large .wc-block-cart__sidebar { width: calc(40% - .75rem); }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart:not(.is-large) :is(.wc-block-cart__main, .wc-block-cart__sidebar) { width: 100%; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items { margin: 0; border: 0; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items th {
  padding: 0 0 1.125rem; font-family: var(--wp--preset--font-family--body);
  font-size: .6875rem; font-weight: 500; letter-spacing: .12em; color: var(--wp--preset--color--muted);
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items td { border-color: var(--wp--preset--color--line); padding-block: 1.5rem; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items tr:last-child td { border-bottom: 0; padding-bottom: 0; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart.is-large table.wc-block-cart-items .wc-block-cart-item__image { width: 116px; padding-right: 1.25rem; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart-item__image img {
  width: 96px; height: 96px; padding: 1rem; object-fit: contain;
  background: var(--wp--preset--color--surface); border: 1px solid var(--wp--preset--color--line); border-radius: 14px;
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row .wc-block-components-product-name {
  font-family: var(--wp--preset--font-family--heading); font-size: 1.25rem;
  line-height: 1.3; font-weight: 700; color: var(--wp--preset--color--navy); text-decoration: none;
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-components-product-name:hover { text-decoration: underline; text-underline-offset: 3px; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-components-product-metadata { font-size: .8125rem; line-height: 1.6; color: var(--wp--preset--color--muted); }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart-item__prices { font-size: .9375rem; font-weight: 500; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart-item__total .wc-block-components-product-price__value {
  font-family: var(--wp--preset--font-family--heading); font-size: 1.1875rem; font-weight: 700; white-space: nowrap;
}
/* Suppress the old-price presentation, never alter the sale/current price,
   discounts, Store API amounts or order records. */
:is(.bhq-main, .editor-styles-wrapper) :is(.wp-block-woocommerce-cart, .wp-block-woocommerce-checkout) .wc-block-components-product-price del,
:is(.bhq-main, .editor-styles-wrapper) :is(.wp-block-woocommerce-cart, .wp-block-woocommerce-checkout) .wc-block-components-product-price__regular { display: none; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-components-product-price ins { text-decoration: none; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart-item__quantity { margin-top: 1rem; display: flex; align-items: center; gap: .625rem; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-components-quantity-selector { margin: 0; min-height: 36px; height: 36px; border-color: var(--wp--preset--color--line); }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row .wc-block-cart-item__quantity .wc-block-cart-item__remove-link {
  display: inline-flex; align-items: center; justify-content: center; min-width: 36px; min-height: 36px;
  margin: 0; border: 1px solid var(--wp--preset--color--line); border-radius: 8px; color: var(--wp--preset--color--muted);
}
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart-item__remove-link:hover { background: var(--wp--preset--color--sand); color: var(--wp--preset--color--navy); }
.bhq-main .wc-block-cart__submit { margin-top: 1.25rem; margin-bottom: 0; }
.bhq-main .wc-block-cart .wc-block-cart__submit-container {
  position: static; width: 100%; padding: 0; box-shadow: none;
}
.bhq-main .wc-block-cart .wc-block-cart__submit-container::before { display: none; }
.bhq-main .wc-block-cart__payment-options:empty { display: none; }

/* Consistent summary hierarchy with protected horizontal padding on totals. */
:is(.bhq-main, .editor-styles-wrapper) :is(.wp-block-woocommerce-cart-order-summary-block, .wp-block-woocommerce-checkout-order-summary-block) { border-top: 0; }
:is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart__totals-title {
  display: flex; align-items: center; gap: .625rem; padding: 0 0 1.25rem; margin: 0;
  font-family: var(--wp--preset--font-family--heading); font-size: 1.25rem; font-weight: 700;
  text-transform: none; letter-spacing: -.02em; line-height: 1.3; color: var(--wp--preset--color--navy);
}
.bhq-main .wc-block-cart__totals-title::before,
.bhq-main .wc-block-components-checkout-order-summary__title-text::before {
  content: ''; display: inline-block; vertical-align: -.2em; width: 22px; height: 22px; flex-shrink: 0;
  background: var(--bhq-icon-color); mask: url('../icons/receipt.svg') center / contain no-repeat;
}
.bhq-main .wc-block-components-checkout-order-summary__title-text::before { margin-right: .625rem; }
.bhq-main .wc-block-components-totals-coupon { font-size: .875rem; }
.bhq-main .wc-block-components-totals-item:not(.wc-block-components-totals-footer-item) { font-size: .875rem; }
.bhq-main .wc-block-components-totals-footer-item { border-radius: 12px; margin-block: .25rem; }
.bhq-main .wc-block-components-product-badge { background: var(--wp--preset--color--sand); color: var(--wp--preset--color--navy); border: 0; font-size: .6875rem; font-weight: 500; }
.bhq-main .wc-block-components-checkout-order-summary__title { padding: 1.25rem; }
.bhq-main .wc-block-components-checkout-order-summary__title-text { font-size: 1.25rem; }
.bhq-main .wp-block-woocommerce-checkout-order-summary-block { border-color: var(--wp--preset--color--line); overflow: hidden; }
.bhq-main .wc-block-components-order-summary .wc-block-components-order-summary-item { padding-block: .625rem 1.25rem; }
.bhq-main .wc-block-components-order-summary .wc-block-components-order-summary-item__image { width: 64px; }
.bhq-main .wc-block-components-order-summary .wc-block-components-order-summary-item__image img {
  width: 64px; height: 64px; object-fit: contain; padding: .5rem;
  background: var(--wp--preset--color--surface); border-radius: 10px; border: 1px solid var(--wp--preset--color--line);
}
.bhq-main .wc-block-components-order-summary .wc-block-components-product-name {
  font-family: var(--wp--preset--font-family--heading); font-size: 1rem; font-weight: 700; line-height: 1.4;
}
.bhq-main .wc-block-components-order-summary-item__total-price { font-family: var(--wp--preset--font-family--heading); }
.bhq-main .wc-block-components-checkout-step__title { font-family: var(--wp--preset--font-family--heading); font-size: 1.25rem; }
.bhq-main .wc-block-components-checkout-step__heading { display: flex; align-items: center; gap: .625rem; }
.bhq-main :is(.wp-block-woocommerce-checkout-contact-information-block, .wp-block-woocommerce-checkout-billing-address-block, .wp-block-woocommerce-checkout-payment-block) .wc-block-components-checkout-step__heading::before {
  content: ''; width: 22px; height: 22px; flex: 0 0 22px;
  background: var(--bhq-icon-color); mask: url('../icons/account.svg') center / contain no-repeat;
}
.bhq-main .wp-block-woocommerce-checkout-billing-address-block .wc-block-components-checkout-step__heading::before { mask-image: url('../icons/location.svg'); }
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-checkout-step__heading::before { mask-image: url('../icons/card.svg'); }

/* Recognized methods pair their native names with a mark. Provider iframes,
   express buttons and unknown gateway labels retain their native presentation. */
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem;
}
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control-accordion-option { display: contents; }
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control__option {
  display: flex; align-items: center; min-height: 76px; padding: 1rem 1rem 1rem 2.75rem; margin: 0;
  border: 1px solid var(--wp--preset--color--line); border-radius: var(--bhq-field-radius);
  background: var(--wp--preset--color--white);
}
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control__option-checked {
  border-color: var(--bhq-choice-accent); background: var(--bhq-choice-background);
  box-shadow: inset 0 0 0 1px var(--bhq-choice-accent);
}
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control-accordion-content {
  order: 1; grid-column: 1 / -1; padding: 1rem; border-radius: var(--bhq-field-radius);
  background: var(--wp--preset--color--surface); color: var(--wp--preset--color--ink); font-size: .875rem;
}
@media (forced-colors: none) {
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control__option:has(input:is([value="bacs"], [value="paypal"], [value="ppcp-gateway"], [value="ppcp-paypal"])) .wc-block-components-radio-control__label {
  position: static; width: auto; height: auto; padding: 0 3rem 0 0; margin: 0; overflow: visible;
  clip-path: none; white-space: normal; border: 0;
}
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control__option:has(input[value="bacs"])::after {
  content: ''; position: absolute; inset: 50% 1rem auto auto; transform: translateY(-50%);
  display: block; margin: 0; width: 38px; height: 38px;
  background: var(--wp--preset--color--navy); mask: url('../icons/bank.svg') center / contain no-repeat;
}
.bhq-main .wp-block-woocommerce-checkout-payment-block .wc-block-components-radio-control__option:has(input:is([value="paypal"], [value="ppcp-gateway"], [value="ppcp-paypal"]))::after {
  content: ''; position: absolute; inset: 50% 1rem auto auto; transform: translateY(-50%);
  display: block; margin: 0; width: 48px; height: 48px;
  background: url('../icons/paypal.svg') center / contain no-repeat;
}
}

/* Editable help links reflect OMS software support, rather than retail perks. */
.bhq-commerce-help { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; padding-block: 2rem .5rem; }
.bhq-commerce-help > .wp-block-group { position: relative; padding-left: 3.125rem; margin: 0; min-width: 0; }
.bhq-commerce-help > .wp-block-group::before {
  content: ''; position: absolute; left: 0; top: .125rem; width: 32px; height: 32px;
  background: var(--bhq-icon-color); mask: url('../icons/book.svg') center / contain no-repeat;
}
.bhq-commerce-help > .bhq-help-orders::before { mask-image: url('../icons/account.svg'); }
.bhq-commerce-help > .bhq-help-support::before { mask-image: url('../icons/mail.svg'); }
.bhq-commerce-help h3 { font-size: 1rem; margin: 0 0 .375rem; }
.bhq-commerce-help a { color: var(--wp--preset--color--navy); text-decoration: none; }
.bhq-commerce-help a:hover { text-decoration: underline; text-underline-offset: 3px; }
.bhq-commerce-help p { font-size: .8125rem; line-height: 1.6; color: var(--wp--preset--color--muted); margin: 0; }

@media (max-width: 600px) {
  .bhq-main .bhq-steps { gap: .375rem; font-size: .6875rem; flex-wrap: nowrap; }
  .bhq-main .bhq-steps li { gap: .375rem; }
  .bhq-main .bhq-steps li::before { width: 24px; height: 24px; }
  .bhq-main .bhq-steps li:not(:last-child)::after { width: .5rem; margin: 0; }
  .bhq-commerce-help { grid-template-columns: 1fr; gap: 1.5rem; }
}
@container (max-width: 699px) {
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row { grid-template-columns: 72px minmax(0, 1fr); gap: 0 1rem; padding-block: 0 1.5rem; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row:last-child { padding-bottom: 0; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row td { padding: 0; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-item__product { grid-column: 2; min-width: 0; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-item__total { grid-column: 2; grid-row: 2; margin-top: 1rem; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart .wc-block-cart-item__image img { width: 72px; height: 72px; padding: .625rem; }
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row .wc-block-components-product-name { font-size: 1.125rem; }
}
@container (max-width: 899px) {
  :is(.bhq-main, .editor-styles-wrapper) .wc-block-cart.is-large :is(.wc-block-cart__main, .wc-block-cart__sidebar) { width: 100%; }
}
