form.cart > .bbfe-product-options {
    flex: 0 0 100% !important;
    align-self: flex-start;
    width: 100%;
    margin: 0;
}

.bbfe-product-options h3 {
    margin: 0 0 12px;
}

.bbfe-product-options > .bbfe-section:last-child,
.bbfe-product-options .bbfe-custom-options > .bbfe-section:last-child {
    margin-bottom: 0;
}

.bbfe-custom-options {
    margin: 0;
}

.bbfe-colourations > .bbfe-custom-options {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.bbfe-section {
    margin-bottom: 16px;
    --bbfe-heading-size: 1em;
}

.bbfe-option-panel {
    box-sizing: border-box;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    background: linear-gradient(145deg, #2b2d35, #272930);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

.bbfe-product-options .bbfe-option-panel > h4 {
    margin: 0 0 12px;
}

.bbfe-colourations > .bbfe-swatch-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 0;
}

.bbfe-colourations .bbfe-swatch {
    margin-right: 0.5em;
    border: 2px solid transparent;
    border-radius: 4px;
}

.bbfe-colourations .bbfe-swatch img {
    border-radius: 2px;
}

.bbfe-colourations > .bbfe-swatch-grid > .bbfe-swatch {
    width: 72px;
    height: 72px;
}

.bbfe-colourations > .bbfe-swatch-grid > .bbfe-swatch img {
    width: 68px;
    height: 68px;
}

.bbfe-colourations .bbfe-swatch.is-selected {
    border-color: #11bbff;
    box-shadow: 0 0 0 2px rgba(17, 187, 255, 0.2);
}

.bbfe-product-options .bbfe-section > h4,
.bbfe-product-options .bbfe-section > label {
    font-size: var(--bbfe-heading-size);
}

.bbfe-colouration-selected-label {
    margin: 12px 0 0;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: calc(var(--bbfe-heading-size) - 2pt);
    line-height: 1.3;
    font-weight: 400;
}

.bbfe-colouration-selected-name {
    font-weight: 600;
}

.bbfe-colouration-selected-desc {
    font-weight: 400;
    opacity: 0.75;
}

/* Sale display uses spans — avoid <del> because theme/custom CSS often has
   `del span.amount { display:none }` which would hide the full price. */
.bbfe-price-sale .bbfe-price-full,
.bbfe-price-sale .bbfe-price-full .woocommerce-Price-amount,
.bbfe-price-sale .bbfe-price-full .amount {
    display: inline !important;
    color: #8a8a8a !important;
    opacity: 1 !important;
    margin-right: 0.4em;
    text-decoration: line-through !important;
    font-weight: 400 !important;
}

.bbfe-price-sale .bbfe-price-net,
.bbfe-price-sale .bbfe-price-net .woocommerce-Price-amount,
.bbfe-price-sale .bbfe-price-net .amount {
    display: inline !important;
    text-decoration: none !important;
    font-weight: 700;
    background: transparent;
}

.bbfe-price-sale {
    display: inline;
    white-space: nowrap;
}

.bbfe-section label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
}

.bbfe-section select {
    min-width: 240px;
}

.bbfe-section .bbfe-style-select-hidden {
    display: none !important;
}

.bbfe-product-options .bbfe-pill-heading {
    margin: 0 0 8px;
}

.bbfe-pill-group {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: stretch;
    gap: 8px;
}

.bbfe-product-options button.bbfe-pill {
    appearance: none;
    box-sizing: border-box;
    flex: 1 1 auto;
    width: auto;
    max-width: 100%;
    min-width: max-content;
    min-height: 44px;
    margin: 0;
    padding: 8px 14px;
    border: 2px solid transparent;
    border-radius: 6px;
    background: #373a44;
    color: #f7f7f7;
    font: inherit;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    text-align: center;
    text-transform: none;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.16);
    transition: background-color 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.bbfe-product-options button.bbfe-pill:hover {
    background: #454954;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.22);
}

.bbfe-product-options button.bbfe-pill.is-selected {
    border-color: #11bbff;
    background: #373a44;
    color: #f7f7f7;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.16);
}

.bbfe-product-options button.bbfe-pill:focus-visible {
    outline: 2px solid #11bbff;
    outline-offset: 2px;
}

.bbfe-swatch-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 10px;
}

.bbfe-swatch {
    position: relative;
    overflow: hidden;
    padding: 0;
    width: 60px;
    height: 60px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: none;
    animation: none;
}

.bbfe-swatch img {
    width: 56px;
    height: 56px;
    object-fit: cover;
    transition: none;
    animation: none;
}

/* Sale % overlay — matches baked-in swatch style (white fill, thick black stroke, bottom). */
.bbfe-swatch-sale-badge {
    position: absolute;
    left: 50%;
    bottom: 2px;
    z-index: 1;
    transform: translateX(-50%);
    margin: 0;
    padding: 0;
    color: #fff;
    font-family: "Arial Black", "Helvetica Black", Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
    font-size: 13px;
    font-weight: 900;
    font-style: normal;
    line-height: 1;
    letter-spacing: -0.05em;
    white-space: nowrap;
    pointer-events: none;
    user-select: none;
    -webkit-text-stroke: 2.5px #000;
    paint-order: stroke fill;
    text-shadow:
        -1px -1px 0 #000,
         1px -1px 0 #000,
        -1px  1px 0 #000,
         1px  1px 0 #000,
         0   -1.5px 0 #000,
         0    1.5px 0 #000,
        -1.5px 0 0 #000,
         1.5px 0 0 #000;
}

.bbfe-swatch.is-selected {
    border-color: #ffffff;
    border-width: 2px;
    box-shadow: none;
}

.bbfe-swatch.is-selected::after {
    content: "✓";
    position: absolute;
    top: 2px;
    right: 2px;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #43d675;
    color: #20222b;
    font-family: Arial, sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    pointer-events: none;
}

.bbfe-swatch-label {
    font-size: 12px;
    text-align: center;
    padding: 4px;
}

.bbfe-custom-toggle {
    background: #1e87f0;
    color: #fff;
    border: none;
    padding: 8px 14px;
    cursor: pointer;
}

.bbfe-price-loading {
    position: relative;
}

.bbfe-price-loading::after {
    content: "";
    position: absolute;
    right: 4px;
    top: 50%;
    z-index: 2;
    transform: translateY(-50%);
    box-sizing: border-box;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #11bbff;
    border-radius: 50%;
    animation: bbfe-price-spin 700ms linear infinite;
    pointer-events: none;
}

.bbfe-price-feedback {
    display: none;
    margin: 4px 0 0;
    color: #d7d9df;
    font-size: 0.82em;
    line-height: 1.4;
}

.bbfe-price-feedback.is-visible {
    display: block;
}

body.bbfe-managed-product .bbfe-price-feedback .bbfe-price-refresh {
    appearance: none;
    width: auto !important;
    min-height: 0 !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #11bbff !important;
    font: inherit;
    line-height: inherit !important;
    text-decoration: underline;
    text-underline-offset: 2px;
    animation: none !important;
    cursor: pointer;
}

@keyframes bbfe-price-spin {
    to {
        transform: translateY(-50%) rotate(360deg);
    }
}

.bbfe-upgrade-inputs {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.bbfe-upgrade-pill.is-unavailable,
.bbfe-upgrades.is-empty {
    display: none;
}

body.single-product.bbfe-managed-product form.cart .bbfe-product-options ~ .ux-quantity.quantity {
    display: none !important;
}

body.single-product.bbfe-managed-product form.cart .single_add_to_cart_button:not(.disabled) {
    min-height: 44px !important;
    margin: 12px 0 0 !important;
    border: 1px solid #11bbff !important;
    border-radius: 6px !important;
    background-color: #11bbff !important;
    box-shadow: none !important;
    color: #20222b !important;
    animation: none !important;
    transition: background-color 150ms ease, border-color 150ms ease !important;
}

body.single-product.bbfe-managed-product form.cart .single_add_to_cart_button:not(.disabled):hover {
    border-color: #46c9ff !important;
    background-color: #46c9ff !important;
}

body.single-product.bbfe-managed-product form.cart .ux-buy-now-button {
    min-height: 44px !important;
    margin: 8px 0 0 !important;
    border: 1px solid rgba(255, 255, 255, 0.45) !important;
    border-radius: 6px !important;
    background-color: #373a44 !important;
    box-shadow: none !important;
    color: #fff !important;
    animation: none !important;
    transition: background-color 150ms ease, border-color 150ms ease !important;
}

body.single-product.bbfe-managed-product form.cart .ux-buy-now-button:hover {
    border-color: rgba(255, 255, 255, 0.7) !important;
    background-color: #454954 !important;
}

body.single-product.bbfe-managed-product .add-to-cart-container form.cart {
    margin-bottom: 0 !important;
}

body.single-product.bbfe-managed-product .Product_First_Info .mto-indicator-container {
    margin-top: 14px !important;
    margin-bottom: 24px !important;
}

@media (max-width: 479px) {
    .bbfe-option-panel {
        padding: 14px;
    }
}

.bbfe-product-options .bbfe-fulfillment-tabs,
form.cart .bbfe-product-options .bbfe-fulfillment-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 0;
    margin: 0 0 14px;
    padding: 0;
    overflow: hidden;
    box-sizing: border-box;
    border: 0;
    border-bottom: 2px solid #11bbff;
    border-radius: 0;
    background: transparent;
}

.bbfe-product-options .bbfe-fulfillment-tab,
form.cart .bbfe-product-options .bbfe-fulfillment-tab {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-width: 0;
    min-height: 46px;
    height: auto;
    margin: 0 !important;
    padding: 10px 14px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #242730 !important;
    box-shadow: none !important;
    color: #d8dae0 !important;
    font: inherit;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0;
    text-transform: none !important;
    text-shadow: none;
    animation: none !important;
    cursor: pointer;
}

.bbfe-product-options .bbfe-fulfillment-tab:hover:not(.is-selected),
form.cart .bbfe-product-options .bbfe-fulfillment-tab:hover:not(.is-selected) {
    background: #30333d !important;
    color: #fff !important;
}

.bbfe-product-options .bbfe-fulfillment-tab.is-selected,
form.cart .bbfe-product-options .bbfe-fulfillment-tab.is-selected {
    background: #11bbff !important;
    color: #20222b !important;
}

.bbfe-product-options .bbfe-fulfillment-tab:focus-visible,
form.cart .bbfe-product-options .bbfe-fulfillment-tab:focus-visible {
    position: relative;
    z-index: 1;
    outline: 2px solid #fff;
    outline-offset: -4px;
}

.bbfe-tab-panel {
    display: none;
}

.bbfe-tab-panel.is-active {
    display: block;
}

.bbfe-tab-panel-rts {
    container-type: inline-size;
}

.bbfe-rts-results-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 6px 12px;
    min-height: 24px;
    margin: 0 0 10px;
    color: #d7d9df;
    font-size: 0.9em;
}

.bbfe-rts-count {
    margin: 0;
    color: inherit;
    font-size: inherit;
}

.bbfe-rts-loading-label {
    display: none;
    align-items: center;
    gap: 6px;
    color: #11bbff;
    font-weight: 600;
}

.bbfe-product-options.bbfe-rts-loading .bbfe-rts-loading-label {
    display: inline-flex;
}

.bbfe-product-options.bbfe-rts-loading .bbfe-rts-loading-label::before {
    content: "";
    box-sizing: border-box;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #11bbff;
    border-radius: 50%;
    animation: bbfe-rts-spin 700ms linear infinite;
}

.bbfe-rts-grid {
    position: relative;
    min-height: 120px;
    overflow: hidden;
}

.bbfe-inventory-products.products {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0 !important;
}

.bbfe-inventory-products.products > .product-small.col {
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.bbfe-inventory-products .product-small.box {
    height: 100%;
    margin: 0;
}

.bbfe-inventory-products .box-image {
    overflow: hidden;
    border-radius: 6px 6px 0 0;
}

.bbfe-inventory-products .box-text {
    padding-right: 8px;
    padding-left: 8px;
}

@container (min-width: 520px) {
    .bbfe-inventory-products.products {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.bbfe-rts-grid .add_to_cart_button,
.bbfe-rts-grid .ajax_add_to_cart,
.bbfe-rts-grid form.cart {
    display: none !important;
}

.bbfe-rts-empty {
    display: grid;
    gap: 4px;
    place-items: center;
    min-height: 140px;
    padding: 24px;
    border: 1px dashed rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    color: #d7d9df;
    text-align: center;
}

.bbfe-rts-pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin: 18px 0 4px;
}

body.bbfe-managed-product .bbfe-rts-page {
    appearance: none;
    min-width: 38px;
    min-height: 38px;
    margin: 0 !important;
    padding: 6px 10px;
    border: 1px solid rgba(255, 255, 255, 0.22) !important;
    border-radius: 4px;
    background: #30333d !important;
    box-shadow: none !important;
    color: #fff !important;
    font: inherit;
    line-height: 1;
    text-transform: none;
    animation: none !important;
    cursor: pointer;
}

body.bbfe-managed-product .bbfe-rts-page:hover,
body.bbfe-managed-product .bbfe-rts-page.is-current {
    border-color: #11bbff !important;
    background: #11bbff !important;
    color: #20222b !important;
}

.bbfe-product-options.bbfe-rts-loading .bbfe-inventory-products,
.bbfe-product-options.bbfe-rts-loading .bbfe-rts-empty {
    opacity: 0.5;
    pointer-events: none;
}

.col-inner.bbfe-tab-ready-to-ship > .product-price-container,
.col-inner.bbfe-tab-ready-to-ship .mto-indicator-container,
form.cart.bbfe-tab-ready-to-ship .single_add_to_cart_button,
form.cart.bbfe-tab-ready-to-ship .ux-buy-now-button,
form.cart.bbfe-tab-ready-to-ship .ux-quantity.quantity {
    display: none !important;
}

@keyframes bbfe-rts-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 479px) {
    .bbfe-product-options .bbfe-fulfillment-tab,
    form.cart .bbfe-product-options .bbfe-fulfillment-tab {
        padding-right: 8px !important;
        padding-left: 8px !important;
        font-size: 0.92em;
    }

    .bbfe-inventory-products.products {
        gap: 10px;
    }
}
