/* TAIF V5 — Bulk editor pair cleanup
   Hide self/counterpart pair inputs for the counterpart currency and legacy zero-drop currencies,
   while preserving the desktop grid alignment and keeping USD pair fields editable. */
.taif-currency-management-modal--bulk-editor .currency-management-bulk-card__cell--hidden-pair{
  min-height:32px;
  visibility:hidden;
  pointer-events:none;
  user-select:none;
}

.taif-currency-management-modal--bulk-editor .currency-management-bulk-card__cell--hidden-pair::before{
  content:"";
  display:block;
  width:100%;
  min-height:32px;
}

/* TAIF V5 — USD pair rate text color unification
   Main Currency Management: USD pair buy/sell values are neutral black, while counterpart pair columns keep buy green and sell red. */
.panel[data-view="currency-management"] .currency-management-num-pill--ratio-buy,
.panel[data-view="currency-management"] .currency-management-num-pill--ratio-sell{
  color:#0f172a !important;
}

/* Bulk Editor: default USD pair inputs are neutral black. */
.taif-currency-management-modal--bulk-editor .currency-management-bulk-card:not(.currency-management-bulk-card--counterpart-pair-hidden) .currency-management-bulk-card__cell--ratio .currency-management-bulk-input[data-bulk-field="ratioBuy"],
.taif-currency-management-modal--bulk-editor .currency-management-bulk-card:not(.currency-management-bulk-card--counterpart-pair-hidden) .currency-management-bulk-card__cell--ratio .currency-management-bulk-input[data-bulk-field="ratioSell"]{
  color:#0f172a !important;
  -webkit-text-fill-color:#0f172a !important;
}

/* Bulk Editor exception only: counterpart currency and zero-drop currencies keep the semantic green/red USD rates. */
.taif-currency-management-modal--bulk-editor .currency-management-bulk-card--counterpart-pair-hidden .currency-management-bulk-card__cell--ratio .currency-management-bulk-input[data-bulk-field="ratioBuy"]{
  color:#15803d !important;
  -webkit-text-fill-color:#15803d !important;
}

.taif-currency-management-modal--bulk-editor .currency-management-bulk-card--counterpart-pair-hidden .currency-management-bulk-card__cell--ratio .currency-management-bulk-input[data-bulk-field="ratioSell"]{
  color:#dc2626 !important;
  -webkit-text-fill-color:#dc2626 !important;
}

/* Price screen scoped counterpart editor: only buy/sell rate fields are visible. */
.taif-currency-management-modal--price-screen-rate-only.taif-currency-management-modal--grand.taif-currency-management-modal--size-md{
  width:min(520px, 52vw);
  height:auto;
  min-height:0;
  max-height:min(34vh, 285px);
}

.taif-currency-management-modal__body--price-screen-rate-only{
  min-height:0;
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-single-editor-panel--rate-only{
  min-height:0;
  height:auto;
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-single-editor-scroll--rate-only{
  flex:0 0 auto;
  overflow:visible;
  padding:14px 14px 10px;
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-form-grid--rate-only{
  gap:10px;
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-form-grid--rate-only > .currency-management-form-grid--two{
  grid-template-columns:repeat(2, minmax(0, 1fr));
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-field--single-editor-terminal-rate{
  min-width:0;
}

.taif-currency-management-modal--price-screen-rate-only .currency-management-field--single-editor-terminal-rate .currency-management-input{
  min-height:42px;
  font-size:13.2px;
  font-weight:800;
}

@media (max-width: 760px){
  .taif-currency-management-modal--price-screen-rate-only.taif-currency-management-modal--grand.taif-currency-management-modal--size-md{
    width:min(94vw, 520px);
    max-height:min(44vh, 310px);
  }
}
