/* R39: retain native cart forms; correct theme padding that collapses the remove icon. */
body .line-item .line-item-remove .line-item-remove-button {
    padding: 0 !important;
    min-width: 32px;
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
body .line-item .line-item-remove .line-item-remove-button .icon {
    flex: 0 0 18px;
    width: 18px !important;
    height: 18px !important;
}
body .line-item .line-item-remove .line-item-remove-button .icon svg {
    width: 100%;
    height: 100%;
    top: 0;
}
body .line-item-remove-button:focus-visible {
    outline: 3px solid #111;
    outline-offset: 3px;
}
/* Keep search, cart and badge inside the viewport below desktop navigation. */
@media (max-width: 991.98px) {
    header.header-main > .container .header-row {
        width: 100%;
        height: 75px !important;
        margin: 0;
        padding: 0 12px;
        flex-wrap: nowrap;
        gap: 8px;
    }
    header.header-main .header-row > .header-actions-col {
        flex: 0 0 44px;
        width: 44px;
        padding: 0;
    }
    header.header-main .header-row > .header-logo-col {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        padding: 0;
        justify-content: center;
    }
    header.header-main .header-logo-main { max-width: 160px; width: 100%; }
    header.header-main .header-logo-main-img { max-width: 100%; object-fit: contain; }
    header.header-main .header-row > .header-search-col {
        flex: 0 0 auto;
        width: auto;
        padding: 0;
    }
    header.header-main .header-search-col > .row {
        flex-wrap: nowrap;
        gap: 4px;
        margin: 0;
    }
    header.header-main .header-search-col > .row > .col-auto { padding: 0; }
    header.header-main .header-search-col .header-actions-btn {
        display: inline-flex;
        width: 44px;
        height: 44px;
        padding: 0;
        align-items: center;
        justify-content: center;
    }
    header.header-main .header-cart-btn-wrapper {
        width: 44px;
        height: 44px;
        align-items: center;
        justify-content: center;
    }
    header.header-main .header-cart-badge {
        top: 0;
        right: 0;
        left: auto;
        transform: none;
        min-width: 18px;
        width: auto;
        height: 18px;
        padding: 0 4px;
        line-height: 18px;
        font-size: 11px;
    }
}
@media (max-width: 767.98px) {
    body .line-item .line-item-remove {
        min-width: 44px;
        min-height: 44px;
    }
    body .line-item .line-item-remove .line-item-remove-button {
        width: 44px !important;
        height: 44px !important;
    }
    /* The theme's 105px quantity field otherwise wraps its plus button. */
    body .offcanvas-cart .line-item-quantity-group {
        width: 126px;
        max-width: 100%;
        flex-wrap: nowrap;
    }
    body .offcanvas-cart .line-item-quantity-group .btn {
        flex: 0 0 36px;
        width: 36px;
        padding: 0;
    }
    body .offcanvas-cart .line-item-quantity-group .form-control {
        min-width: 0;
        width: 1%;
        flex: 1 1 auto;
        padding-left: 2px;
        padding-right: 2px;
    }
}
