/* Shared purchase-field system for catalogue, product, cart, offers, and account tools. */
:root {
    --graham-purchase-blue: #075da8;
    --graham-purchase-ink: #17324a;
    --graham-purchase-muted: #526d80;
    --graham-purchase-border: #9fb7c7;
    --graham-purchase-height: 42px;
    --graham-purchase-height-compact: 38px;
    --graham-purchase-radius: 6px;
}

/* Keep all three product-card actions equally clear on hover and keyboard focus. */
body.graham-catalog-view .graham-catalog-main .graham-add-list-menu:hover > summary.graham-save-link,
body.graham-catalog-view .graham-catalog-main .graham-add-list-menu > summary.graham-save-link:focus-visible,
body.graham-catalog-view .graham-catalog-main .graham-add-list-menu[open] > summary.graham-save-link {
    background: #f0f5f8 !important;
    color: #1269a7 !important;
}

.graham-quantity-input,
body.single-product .graham-uom-purchase-row .quantity .qty,
body.graham-cart-page table.shop_table.cart td.product-quantity input.qty,
.graham-customer-offer-buy input[type="number"],
#graham-quote-page .graham-quote-quantity input[type="number"] {
    appearance: auto;
    -webkit-appearance: auto;
    background: #fff;
    border: 1px solid var(--graham-purchase-border);
    border-radius: var(--graham-purchase-radius);
    box-shadow: none;
    box-sizing: border-box;
    color: var(--graham-purchase-ink);
    font-size: 16px;
    font-variant-numeric: tabular-nums;
    font-weight: 750;
    height: var(--graham-purchase-height);
    line-height: 1;
    margin: 0;
    min-height: var(--graham-purchase-height);
    padding: 6px 8px;
    text-align: center;
}

.graham-quantity-input:focus,
body.single-product .graham-uom-purchase-row .quantity .qty:focus,
body.graham-cart-page table.shop_table.cart td.product-quantity input.qty:focus,
.graham-customer-offer-buy input[type="number"]:focus,
#graham-quote-page .graham-quote-quantity input[type="number"]:focus {
    border-color: var(--graham-purchase-blue);
    box-shadow: 0 0 0 3px rgba(7, 93, 168, 0.13);
    outline: 0;
}

.graham-quantity-input::-webkit-inner-spin-button,
.graham-quantity-input::-webkit-outer-spin-button,
body.single-product .graham-uom-purchase-row .quantity .qty::-webkit-inner-spin-button,
body.single-product .graham-uom-purchase-row .quantity .qty::-webkit-outer-spin-button,
body.graham-cart-page table.shop_table.cart td.product-quantity input.qty::-webkit-inner-spin-button,
body.graham-cart-page table.shop_table.cart td.product-quantity input.qty::-webkit-outer-spin-button,
.graham-customer-offer-buy input[type="number"]::-webkit-inner-spin-button,
.graham-customer-offer-buy input[type="number"]::-webkit-outer-spin-button,
#graham-quote-page .graham-quote-quantity input[type="number"]::-webkit-inner-spin-button,
#graham-quote-page .graham-quote-quantity input[type="number"]::-webkit-outer-spin-button {
    min-height: 32px;
    min-width: 18px;
    opacity: 1;
}

.graham-saved-lists-page .graham-quantity-input,
.graham-location-items-page .graham-quantity-input,
.graham-par-dialog .graham-quantity-input,
.graham-add-list-panel .graham-quantity-input {
    height: var(--graham-purchase-height-compact);
    min-height: var(--graham-purchase-height-compact);
}

.graham-saved-lists-page :is(.graham-saved-product-quantity, .graham-stock-order-quantity, .graham-par-dialog__quantity) > span,
.graham-location-item-quantity > span,
.graham-customer-offer-buy label > span,
#graham-quote-page .graham-quote-row label > span {
    color: var(--graham-purchase-muted);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1.2;
    text-transform: none;
}

body.single-product .graham-uom-purchase-row .graham-product-uom-picker select,
body.single-product .graham-uom-purchase-row .graham-product-uom-single,
body.single-product .graham-uom-purchase-row .quantity .qty,
body.single-product .graham-uom-purchase-row .single_add_to_cart_button {
    height: var(--graham-purchase-height) !important;
    min-height: var(--graham-purchase-height) !important;
}

body.graham-cart-page table.shop_table.cart td.product-quantity input.qty,
.graham-customer-offer-buy input[type="number"] {
    height: var(--graham-purchase-height) !important;
    min-height: var(--graham-purchase-height) !important;
}

.graham-location-item-remove,
#graham-quote-page .graham-quote-remove {
    align-items: center;
    background: transparent;
    border: 0;
    border-radius: 4px;
    color: #6b7e8b;
    cursor: pointer;
    display: inline-flex;
    height: 32px;
    justify-content: center;
    margin: 0;
    padding: 0;
    width: 32px;
}

.graham-location-item-remove:hover,
.graham-location-item-remove:focus-visible,
#graham-quote-page .graham-quote-remove:hover,
#graham-quote-page .graham-quote-remove:focus-visible {
    background: #fff1f1;
    color: #a12727;
    outline: 0;
}

.graham-location-item-remove .dashicons,
#graham-quote-page .graham-quote-remove .dashicons {
    font-size: 17px;
    height: 17px;
    line-height: 17px;
    width: 17px;
}

@media (min-width: 821px) {
    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart {
        align-items: stretch;
        grid-template-columns: 88px minmax(68px, 1fr) 30px !important;
        height: var(--graham-purchase-height) !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart.has-uom {
        grid-template-columns: 60px 88px minmax(62px, 1fr) 30px !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart[data-cart-quantity="0"] {
        grid-template-columns: 88px minmax(68px, 1fr) !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart.has-uom[data-cart-quantity="0"] {
        grid-template-columns: 60px 88px minmax(62px, 1fr) !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity-field {
        align-items: stretch;
        border: 1px solid var(--graham-purchase-border);
        border-radius: var(--graham-purchase-radius);
        box-sizing: border-box;
        display: grid;
        grid-template-columns: 28px minmax(0, 1fr);
        height: var(--graham-purchase-height);
        margin: 0;
        min-width: 0;
        overflow: hidden;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__uom-label,
    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__uom {
        box-sizing: border-box;
        height: var(--graham-purchase-height) !important;
        min-height: var(--graham-purchase-height) !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity-field > span {
        align-items: center;
        background: #f4f8fa;
        color: var(--graham-purchase-muted);
        display: flex;
        font-size: 0.62rem;
        font-weight: 800;
        justify-content: center;
        line-height: 1;
        overflow: hidden;
        white-space: nowrap;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity {
        appearance: auto !important;
        -webkit-appearance: auto !important;
        border: 0 !important;
        border-left: 1px solid #d3e0e8 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        height: 40px !important;
        min-height: 40px !important;
        padding: 3px 2px !important;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity:focus {
        background: #f5fbff;
        outline: 2px solid var(--graham-purchase-blue);
        outline-offset: -2px;
    }

    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity::-webkit-inner-spin-button,
    .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity::-webkit-outer-spin-button {
        appearance: auto !important;
        margin: 0;
        min-height: 28px;
        opacity: 1;
    }

    .graham-catalog-grid-view .graham-catalog-main :is(.graham-card-cart__submit, .graham-card-cart__remove) {
        box-sizing: border-box;
        height: var(--graham-purchase-height) !important;
        min-height: var(--graham-purchase-height) !important;
    }
}

/* 0.13.608 final cascade: this block is intentionally last so the saved-list
 * picker wins over older breakpoint rules in this stylesheet. */
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
    contain: none !important;
    content-visibility: visible !important;
    grid-auto-rows: auto !important;
    overflow: visible !important;
    position: relative !important;
    z-index: 1001 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop {
    align-items: stretch !important;
    align-self: start !important;
    bottom: auto !important;
    display: flex !important;
    flex-wrap: wrap !important;
    grid-column: 1 / -1 !important;
    grid-row: 9 !important;
    height: auto !important;
    justify-self: stretch !important;
    left: auto !important;
    min-height: 0 !important;
    padding: 6px 0 0 !important;
    position: relative !important;
    right: auto !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-menu[open] {
    flex: 1 0 100% !important;
    height: auto !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel {
    box-sizing: border-box !important;
    display: block !important;
    height: auto !important;
    left: auto !important;
    margin: 6px 0 0 !important;
    max-height: none !important;
    max-width: 100% !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow: visible !important;
    padding: 10px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
    align-items: end !important;
    display: grid !important;
    grid-auto-rows: auto !important;
    height: auto !important;
    min-height: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice,
    .graham-add-list-quantity
) {
    min-width: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice select,
    .graham-add-list-quantity input,
    .graham-add-list-form > .button
) {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory,
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    align-self: start !important;
    bottom: auto !important;
    left: auto !important;
    margin-top: 6px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    z-index: 4 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory {
    grid-column: 1 !important;
    grid-row: 10 !important;
    justify-self: start !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    grid-column: 2 !important;
    grid-row: 10 !important;
    justify-self: end !important;
}

@media (max-width: 420px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form > .button {
        grid-column: auto !important;
    }
}

/* 0.13.638: final normal-card layout guard.  This must remain after the
 * legacy compact-card rules so normal cards keep the edit-mode content flow:
 * image, alternate images, title, and item code in separate rows. */
@media (min-width: 560px) {
    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .wc-block-components-product-image {
        grid-area: 1 / 1 / 2 / -1 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-loop-alt-thumbnails {
        grid-area: 2 / 1 / 3 / -1 !important;
        min-width: 0 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > :is(.wc-block-components-product-title, .wp-block-post-title) {
        grid-area: 3 / 1 / 4 / -1 !important;
        min-width: 0 !important;
        position: relative !important;
        visibility: visible !important;
        z-index: 2 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-card-identity {
        grid-area: 4 / 1 / 5 / -1 !important;
        min-width: 0 !important;
        position: relative !important;
        z-index: 2 !important;
    }
}

/* 0.13.638: final normal-card layout guard.  The legacy compact-card rules
 * above can win later in the cascade and put the product title beside the
 * image.  Normal cards use the same vertical content flow as edit mode; edit
 * controls remain separate and are not changed here. */
@media (min-width: 560px) {
    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .wc-block-components-product-image {
        grid-area: 1 / 1 / 2 / -1 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-loop-alt-thumbnails {
        grid-area: 2 / 1 / 3 / -1 !important;
        min-width: 0 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > :is(.wc-block-components-product-title, .wp-block-post-title) {
        grid-area: 3 / 1 / 4 / -1 !important;
        min-width: 0 !important;
        position: relative !important;
        visibility: visible !important;
        z-index: 2 !important;
    }

    html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-card-identity {
        grid-area: 4 / 1 / 5 / -1 !important;
        min-width: 0 !important;
        position: relative !important;
        z-index: 2 !important;
    }
}

/* 0.13.637: final card-flow guard.  Normal and edit catalogue cards share the
   same rows: image first, title second, identity third. */
html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .wc-block-components-product-image,
html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-loop-alt-thumbnails {
    grid-column: 1 / -1 !important;
    grid-row: 1 !important;
}

html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > :is(
    .wc-block-components-product-title,
    .wp-block-post-title
) {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    min-width: 0 !important;
    position: relative !important;
    visibility: visible !important;
    z-index: 2 !important;
}

html body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-shell.graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-card-identity {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    min-width: 0 !important;
    position: relative !important;
    z-index: 2 !important;
}

/* 0.13.608: final saved-list flow override. Match the inventory panel's
 * in-card behavior, but reserve a real grid row for the list form and a
 * separate row for Inventory/Quote so neither action can cover the other. */
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
    contain: none !important;
    content-visibility: visible !important;
    grid-auto-rows: auto !important;
    overflow: visible !important;
    position: relative !important;
    z-index: 1001 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop {
    align-items: stretch !important;
    align-self: start !important;
    bottom: auto !important;
    display: flex !important;
    flex-wrap: wrap !important;
    grid-column: 1 / -1 !important;
    grid-row: 9 !important;
    height: auto !important;
    justify-self: stretch !important;
    left: auto !important;
    min-height: 0 !important;
    padding: 6px 0 0 !important;
    position: relative !important;
    right: auto !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-menu[open] {
    flex: 1 0 100% !important;
    height: auto !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel {
    box-sizing: border-box !important;
    display: block !important;
    height: auto !important;
    left: auto !important;
    margin: 6px 0 0 !important;
    max-height: none !important;
    max-width: 100% !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow: visible !important;
    padding: 10px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
    align-items: end !important;
    display: grid !important;
    grid-auto-rows: auto !important;
    height: auto !important;
    min-height: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice,
    .graham-add-list-quantity
) {
    min-width: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice select,
    .graham-add-list-quantity input,
    .graham-add-list-form > .button
) {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory,
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    align-self: start !important;
    bottom: auto !important;
    left: auto !important;
    margin-top: 6px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    z-index: 4 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory {
    grid-column: 1 !important;
    grid-row: 10 !important;
    justify-self: start !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    grid-column: 2 !important;
    grid-row: 10 !important;
    justify-self: end !important;
}

@media (max-width: 420px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form > .button {
        grid-column: auto !important;
    }
}

/* 0.13.607: make the saved-list picker follow the same in-card flow as the
 * staff inventory panel. The compact card footer is absolutely positioned
 * while closed, so move it into a second normal grid row when the picker is
 * open. Also let the form grow to its labels instead of retaining the old
 * 24px action-row height, which caused the fields and Create a new list link
 * to overlap. */
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
    contain: none !important;
    content-visibility: visible !important;
    overflow: visible !important;
    z-index: 1001 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop {
    align-self: stretch !important;
    bottom: auto !important;
    display: flex !important;
    grid-column: 1 / -1 !important;
    grid-row: 9 !important;
    height: auto !important;
    justify-self: stretch !important;
    left: auto !important;
    min-height: 0 !important;
    padding: 6px 0 0 !important;
    position: relative !important;
    right: auto !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-menu[open] {
    flex: 1 0 100% !important;
    height: auto !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel {
    box-sizing: border-box !important;
    display: block !important;
    left: auto !important;
    margin: 6px 0 0 !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
    padding: 10px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
    align-items: end !important;
    display: grid !important;
    height: auto !important;
    min-height: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice,
    .graham-add-list-quantity
) {
    min-width: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice select,
    .graham-add-list-quantity input,
    .graham-add-list-form > .button
) {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) :is(
    .graham-staff-inventory,
    > .graham-quote-add
) {
    align-self: start !important;
    bottom: auto !important;
    left: auto !important;
    margin-top: 6px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    z-index: 4 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory {
    grid-column: 1 !important;
    grid-row: 10 !important;
    justify-self: start !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    grid-column: 2 !important;
    grid-row: 10 !important;
    justify-self: end !important;
}

@media (max-width: 420px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form > .button {
        grid-column: auto !important;
    }
}

/* 0.13.410: catalogue cards show only their default UOM in the compact row. */
.graham-catalog-main .graham-card-uom__static,
.graham-catalog-main .graham-card-cart__uom-static {
    align-items: center;
    background: #f4f8fa;
    border: 1px solid var(--graham-purchase-border);
    border-radius: var(--graham-purchase-radius);
    box-sizing: border-box;
    color: var(--graham-purchase-ink);
    display: flex;
    font-size: 0.7rem;
    font-weight: 800;
    height: var(--graham-purchase-height-compact);
    justify-content: center;
    line-height: 1;
    min-height: var(--graham-purchase-height-compact);
    min-width: 0;
    padding: 0 6px;
    white-space: nowrap;
}

.graham-catalog-main .graham-card-uom__source {
    display: block;
    margin: 0;
    min-width: 0;
}

@media (min-width: 560px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product-template,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main ul.products {
        grid-template-columns: repeat(auto-fill, minmax(275px, 290px)) !important;
        justify-content: start !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main ul.products li.product {
        max-width: 290px;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__uom-static {
        height: 32px;
        min-height: 32px;
    }
}

@media (max-width: 559px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom {
        min-width: 179px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom[data-cart-quantity="0"] {
        min-width: 150px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__uom-static {
        height: 38px;
        min-height: 38px;
    }
}

/* 0.13.412: let the full sort label and both card columns fit on unfolded phones. */
@media (min-width: 560px) and (max-width: 820px) {
    html body.graham-catalog-view .graham-catalog-toolbar-actions,
    html body.graham-catalog-view .graham-catalog-toolbar-ordering,
    html body.graham-catalog-view .graham-catalog-toolbar-ordering .woocommerce-ordering,
    html body.graham-catalog-view .graham-catalog-tools .graham-catalog-toolbar-ordering select:not([multiple]) {
        max-width: none !important;
        min-width: 0 !important;
        width: 100% !important;
    }
}

/* 0.13.412: use the full unfolded-phone width before fixed desktop tiles take over. */
@media (min-width: 560px) and (max-width: 820px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product-template,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main ul.products {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main ul.products li.product {
        max-width: none;
    }
}

@media (max-width: 700px) {
    body.graham-cart-page table.shop_table.cart td.product-quantity input.qty {
        height: var(--graham-purchase-height-compact) !important;
        min-height: var(--graham-purchase-height-compact) !important;
    }

    .graham-location-item-actions {
        align-self: end;
    }
}

/* 0.13.408: keep tiled cards' price and compact purchase controls on one baseline. */
@media (min-width: 560px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product {
        column-gap: 8px !important;
        grid-template-rows: 148px 38px 2.4em 24px 24px 36px 0 30px 0 !important;
        min-height: 376px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
        grid-template-rows: 148px 38px 2.4em 24px 24px 36px 0 30px auto !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product > :is(
        .wc-block-components-product-image,
        .graham-loop-alt-thumbnails,
        .wc-block-components-product-title,
        .wp-block-post-title,
        .graham-card-identity
    ) {
        grid-column: 1 / -1 !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-loop-status-row > :is(
        .stock,
        mark[class*="graham-availability"],
        .graham-availability-with-help
    ) {
        align-self: center !important;
        grid-column: 1 !important;
        grid-row: 5 !important;
        justify-self: start !important;
        margin: 0 !important;
        max-width: 100%;
        text-align: left !important;
        width: auto !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-loop-status-row .graham-availability-with-help {
        justify-content: flex-start;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price {
        align-self: end;
        display: flex;
        grid-column: 1 !important;
        grid-row: 6 !important;
        height: 36px !important;
        justify-content: flex-start;
        margin: 0 !important;
        min-width: 0;
        overflow: visible;
        padding: 0 2px 0 0;
        text-align: left !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price .wc-block-components-product-price {
        align-items: flex-end;
        display: flex;
        height: 36px !important;
        justify-content: flex-start;
        margin: 0 !important;
        min-width: 0;
        overflow: visible;
        text-align: left !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price .woocommerce-Price-amount {
        color: #17324a;
        display: block;
        font-size: 1.18rem !important;
        font-variant-numeric: tabular-nums;
        font-weight: 800;
        line-height: 32px;
        white-space: nowrap;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price.graham-card-price--long .woocommerce-Price-amount {
        font-size: 1rem !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price .graham-price-review {
        color: #657987;
        display: block;
        font-size: 0.72rem !important;
        font-weight: 600;
        line-height: 1.15 !important;
        max-width: 96px;
        padding-bottom: 5px;
        white-space: normal;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wp-block-woocommerce-product-price .graham-large-order-price-note {
        display: none !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main :is(
        .wp-block-woocommerce-product-button,
        .graham-select-uom,
        .graham-card-uom,
        .graham-price-gated-order
    ) {
        align-self: end;
        box-sizing: border-box;
        grid-column: 2 !important;
        grid-row: 5 / 7 !important;
        height: 32px !important;
        min-width: 0;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-price-gated-block .graham-login-to-view-price--compact {
        align-items: flex-end;
        color: #536d7e;
        font-size: 0.68rem;
        font-weight: 700;
        line-height: 1.15;
        max-width: none;
        padding-bottom: 5px;
        white-space: nowrap;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product:has(.graham-price-gated-order) {
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-price-gated-order {
        display: flex;
        justify-content: flex-end;
        justify-self: end;
        max-width: 144px;
        padding-right: 4px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-price-gated-order .graham-login-to-order {
        font-size: 0.72rem !important;
        height: 32px !important;
        line-height: 1 !important;
        margin: 0 !important;
        min-height: 32px !important;
        padding: 0 10px !important;
        white-space: nowrap;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart {
        gap: 4px;
        grid-template-columns: 52px 88px 24px !important;
        height: 32px !important;
        justify-content: end;
        min-width: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart[data-cart-quantity="0"] {
        grid-template-columns: 52px 88px !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart.has-uom {
        gap: 3px;
        grid-template-columns: 56px 52px 66px 22px !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart.has-uom[data-cart-quantity="0"] {
        grid-template-columns: 56px 52px 66px !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity-field,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__uom-label,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__uom,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main :is(.graham-card-cart__submit, .graham-card-cart__remove) {
        box-sizing: border-box;
        height: 32px !important;
        min-height: 32px !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity-field {
        display: block;
        position: relative;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity-field > span {
        font-size: 0.56rem;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__uom {
        font-size: 0.68rem;
        padding: 0 12px 0 5px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity {
        border-left: 0 !important;
        font-size: 0.72rem;
        padding: 1px !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity::-webkit-inner-spin-button,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__quantity::-webkit-outer-spin-button {
        min-height: 22px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__submit {
        gap: 3px;
        font-size: 0.66rem;
        padding: 0 7px;
        white-space: nowrap;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart__submit .dashicons {
        font-size: 13px;
        height: 13px;
        width: 13px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .graham-card-cart.has-uom:not([data-cart-quantity="0"]) .graham-card-cart__submit .dashicons {
        display: none;
    }
}

/* 0.13.636: keep normal catalogue titles out of the image row.  The compact
   grid above intentionally gives price and cart controls their own columns,
   but the shared content selector previously left the title on row 1 where
   the full-width product image could cover it. */
@media (min-width: 560px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product > .wc-block-components-product-image,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-loop-alt-thumbnails {
        grid-column: 1 / -1 !important;
        grid-row: 1 !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product > :is(
        .wc-block-components-product-title,
        .wp-block-post-title
    ) {
        grid-column: 1 / -1 !important;
        grid-row: 2 !important;
        min-width: 0 !important;
        position: relative;
        z-index: 2;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product > .graham-card-identity {
        grid-column: 1 / -1 !important;
        grid-row: 3 !important;
        min-width: 0 !important;
        position: relative;
        z-index: 2;
    }
}

@media (max-width: 820px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wp-block-woocommerce-product-button[data-graham-quantity-ready="1"] > :is(
        .wc-block-components-product-button__button,
        .added_to_cart,
        span[hidden]
    ),
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-uom[data-graham-quantity-ready="1"] > :is(
        label,
        .graham-card-uom__add
    ) {
        display: none !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-uom[data-graham-quantity-ready="1"] {
        display: block !important;
        min-width: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart {
        align-items: stretch;
        display: grid !important;
        gap: 3px;
        grid-template-columns: minmax(44px, 52px) minmax(74px, 96px) 26px;
        height: 38px;
        justify-content: start;
        margin: 0 0 0 auto;
        max-width: 184px;
        min-width: 0;
        position: relative;
        width: 100%;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart[data-cart-quantity="0"] {
        grid-template-columns: minmax(44px, 52px) minmax(74px, 96px);
        max-width: 151px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom {
        grid-template-columns: minmax(48px, 58px) minmax(38px, 48px) minmax(58px, 80px) 26px;
        max-width: 221px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom[data-cart-quantity="0"] {
        grid-template-columns: minmax(48px, 58px) minmax(38px, 48px) minmax(58px, 80px);
        max-width: 192px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main :is(
        .graham-card-cart__quantity-field,
        .graham-card-cart__uom-label,
        .graham-card-cart__uom,
        .graham-card-cart__quantity,
        .graham-card-cart__submit,
        .graham-card-cart__remove
    ) {
        box-sizing: border-box;
        height: 38px !important;
        min-height: 38px !important;
        min-width: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main :is(
        .graham-card-cart__quantity-field,
        .graham-card-cart__uom-label
    ) {
        display: block;
        margin: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__uom {
        border: 1px solid var(--graham-purchase-border);
        border-radius: var(--graham-purchase-radius);
        font-size: 0.72rem;
        padding: 0 16px 0 6px;
        width: 100%;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__quantity {
        appearance: auto !important;
        -webkit-appearance: auto !important;
        border: 1px solid var(--graham-purchase-border) !important;
        border-radius: var(--graham-purchase-radius) !important;
        font-size: 0.74rem;
        padding: 1px !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__submit,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__remove {
        align-items: center;
        border: 0;
        cursor: pointer;
        display: inline-flex;
        justify-content: center;
        margin: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__submit {
        background: var(--graham-mobile-green, #14843e);
        border-radius: var(--graham-purchase-radius);
        color: #fff;
        font-size: 0.68rem;
        font-weight: 700;
        gap: 3px;
        padding: 0 6px;
        white-space: nowrap;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__submit .dashicons {
        font-size: 13px;
        height: 13px;
        width: 13px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__remove {
        background: transparent;
        color: #687d8c;
        padding: 0;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart__remove[hidden] {
        display: none !important;
    }
}

/* 0.13.406: align the compact purchase controls with the card footer divider. */
@media (max-width: 559px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart {
        margin-right: clamp(3px, calc(5vw - 12px), 15px);
    }
}

@media (min-width: 560px) and (max-width: 640px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product,
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main .wc-block-product:has(.graham-price-gated-order) {
        grid-template-columns: minmax(84px, 0.72fr) minmax(0, 1.28fr) !important;
    }
}

@media (min-width: 560px) and (max-width: 820px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main :is(
        .wp-block-woocommerce-product-button,
        .graham-select-uom,
        .graham-card-uom
    ) {
        height: 32px !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart {
        gap: 4px;
        grid-template-columns: 52px 88px 24px !important;
        height: 32px !important;
        margin-right: 4px;
        max-width: 168px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart[data-cart-quantity="0"] {
        grid-template-columns: 52px 88px !important;
        max-width: 144px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom {
        gap: 3px;
        grid-template-columns: 56px 52px 66px 22px !important;
        max-width: 205px;
        min-width: 205px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .graham-card-cart.has-uom[data-cart-quantity="0"] {
        grid-template-columns: 56px 52px 66px !important;
        max-width: 180px;
        min-width: 180px;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main :is(
        .graham-card-cart__quantity-field,
        .graham-card-cart__uom-label,
        .graham-card-cart__uom,
        .graham-card-cart__quantity,
        .graham-card-cart__submit,
        .graham-card-cart__remove
    ) {
        height: 32px !important;
        min-height: 32px !important;
    }
}

@media (min-width: 821px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-grid-view .graham-catalog-main :is(
        .wp-block-woocommerce-product-button,
        .graham-select-uom,
        .graham-card-uom
    ) {
        padding-right: 4px;
    }
}

/* 0.13.411: the phone sort choice uses the available row instead of truncating. */
@media (max-width: 559px) {
    html body.graham-catalog-view .graham-catalog-toolbar-actions,
    html body.graham-catalog-view .graham-catalog-toolbar-ordering,
    html body.graham-catalog-view .graham-catalog-toolbar-ordering .woocommerce-ordering,
    html body.graham-catalog-view .graham-catalog-tools .graham-catalog-toolbar-ordering select:not([multiple]) {
        max-width: none !important;
        min-width: 0 !important;
        width: 100% !important;
    }
}

/* 0.13.606: keep the desktop product-card list picker in the card flow.
 * The compact card footer is positioned at the bottom of the card while
 * closed. When List opens, moving that action row into the final grid row
 * lets the card grow for the picker instead of shifting the controls left
 * or clipping the panel outside the card. */
@media (min-width: 821px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
        overflow: visible !important;
        position: relative !important;
        z-index: 8 !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop {
        align-items: center !important;
        bottom: auto !important;
        display: flex !important;
        grid-column: 1 / -1 !important;
        grid-row: 9 !important;
        height: auto !important;
        justify-self: stretch !important;
        left: auto !important;
        padding: 6px 0 0 !important;
        position: relative !important;
        right: auto !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-menu[open] {
        flex: 1 0 100% !important;
        height: auto !important;
        min-width: 0 !important;
        width: 100% !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel {
        box-shadow: 0 8px 24px rgba(15, 45, 68, 0.14) !important;
        display: block !important;
        left: auto !important;
        margin-top: 7px !important;
        max-width: 100% !important;
        min-width: 0 !important;
        position: static !important;
        right: auto !important;
        top: auto !important;
        width: 100% !important;
    }
}

/* 0.13.608 end-of-file override: keep the open list picker and its footer
 * actions in separate, growing card rows at every catalogue breakpoint. */
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) {
    contain: none !important;
    content-visibility: visible !important;
    grid-auto-rows: auto !important;
    overflow: visible !important;
    position: relative !important;
    z-index: 1001 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop {
    align-items: stretch !important;
    align-self: start !important;
    bottom: auto !important;
    display: flex !important;
    flex-wrap: wrap !important;
    grid-column: 1 / -1 !important;
    grid-row: 9 !important;
    height: auto !important;
    justify-self: stretch !important;
    left: auto !important;
    min-height: 0 !important;
    padding: 6px 0 0 !important;
    position: relative !important;
    right: auto !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-menu[open] {
    flex: 1 0 100% !important;
    height: auto !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel {
    box-sizing: border-box !important;
    display: block !important;
    height: auto !important;
    left: auto !important;
    margin: 6px 0 0 !important;
    max-height: none !important;
    max-width: 100% !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow: visible !important;
    padding: 10px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
    align-items: end !important;
    display: grid !important;
    grid-auto-rows: auto !important;
    height: auto !important;
    min-height: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice,
    .graham-add-list-quantity
) {
    min-width: 0 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel :is(
    .graham-add-list-choice select,
    .graham-add-list-quantity input,
    .graham-add-list-form > .button
) {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory,
body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    align-self: start !important;
    bottom: auto !important;
    left: auto !important;
    margin-top: 6px !important;
    position: static !important;
    right: auto !important;
    top: auto !important;
    z-index: 4 !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-staff-inventory {
    grid-column: 1 !important;
    grid-row: 10 !important;
    justify-self: start !important;
}

body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) > .graham-quote-add {
    grid-column: 2 !important;
    grid-row: 10 !important;
    justify-self: end !important;
}

@media (max-width: 420px) {
    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.graham-catalog-view:not(.graham-shop-landing) .graham-catalog-main .wc-block-product:has(.graham-add-list-menu[open]) .graham-product-save-actions-loop .graham-add-list-panel .graham-add-list-form > .button {
        grid-column: auto !important;
    }
}
