.fi-resource-relation-manager .psr-active-cell {
    background-color: var(--ps-active-cell-bg) !important;
    color: var(--ps-row-input-text) !important;
}

.fi-resource-relation-manager .psr-active-cell--stripe {
    box-shadow: inset 4px 0 0 var(--ps-active-cell-stripe);
}

.fi-resource-relation-manager .psr-active-cell *,
.fi-resource-relation-manager .psr-active-cell .fi-ta-text,
.fi-resource-relation-manager .psr-active-cell .fi-input,
.fi-resource-relation-manager .psr-active-cell input,
.fi-resource-relation-manager .psr-active-cell textarea {
    color: var(--ps-row-input-text) !important;
}

.fi-resource-relation-manager .psr-active-cell .fi-input-wrp,
.fi-resource-relation-manager .psr-active-cell .fi-input-wrp-content-ctn,
.fi-resource-relation-manager .psr-active-cell .fi-input,
.fi-resource-relation-manager .psr-active-cell input,
.fi-resource-relation-manager .psr-active-cell textarea {
    background: transparent !important;
    border-color: var(--ps-row-input-border) !important;
}

.fi-resource-relation-manager .psr-active-cell .fi-input-wrp {
    background: var(--ps-row-input-bg) !important;
}

.fi-resource-relation-manager .psr-row-input--quantity,
.fi-resource-relation-manager .psr-row-input--quantity .fi-input-wrp,
.fi-resource-relation-manager .psr-row-input--quantity .fi-input-wrp-content-ctn,
.fi-resource-relation-manager .psr-row-input--quantity .fi-input,
.fi-resource-relation-manager .psr-row-input--quantity input {
    width: var(--ps-quantity-width) !important;
    min-width: var(--ps-quantity-width) !important;
    max-width: var(--ps-quantity-width) !important;
}

.fi-resource-relation-manager .psr-row-input--quantity {
    flex: 0 0 var(--ps-quantity-width);
}

.fi-resource-relation-manager td:has(.psr-row-input--quantity) {
    padding-inline-end: 0.75rem !important;
}

.fi-resource-relation-manager .psr-row-input--comment,
.fi-resource-relation-manager .psr-row-input--comment .fi-input-wrp,
.fi-resource-relation-manager .psr-row-input--comment .fi-input-wrp-content-ctn,
.fi-resource-relation-manager .psr-row-input--comment .fi-input,
.fi-resource-relation-manager .psr-row-input--comment input,
.fi-resource-relation-manager .psr-row-input--comment textarea {
    min-width: var(--ps-comment-width) !important;
}

.fi-resource-relation-manager .psr-row-input--comment {
    min-width: var(--ps-comment-width);
}

.fi-resource-relation-manager .psr-quantity-input__field {
    appearance: textfield;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    padding-right: 0.75rem !important;
    text-align: right;
}

.fi-resource-relation-manager .psr-quantity-input__field::-webkit-outer-spin-button,
.fi-resource-relation-manager .psr-quantity-input__field::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Offer count badge inline with product name */
.psr-offer-badge-wrap {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
}

.psr-product-name-link {
    color: var(--color-brand-primary);
}

.psr-product-name-link:hover {
    text-decoration: underline;
}

.psr-offer-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.25rem;
    height: 1.25rem;
    padding: 0 0.3rem;
    border-radius: 9999px;
    font-size: 0.7rem;
    font-weight: 600;
    line-height: 1;
    flex-shrink: 0;
}

/* Есть предложения — success-зелёный. */
.psr-offer-badge--has-offers {
    background-color: var(--color-success-bg);
    color: var(--color-success-text);
}

/* Ноль предложений — warning (требует внимания), чтобы бейдж был заметен. */
.psr-offer-badge--no-offers {
    background-color: var(--color-warning-bg);
    color: var(--color-warning-text);
}
/* Dark-mode переопределяется автоматически через семантические токены в tokens.css. */
