/* Final dashboard parity fixes. Kept separate so these states can be removed cleanly. */

input[type="number"].bb-number-input {
  -moz-appearance: textfield;
  appearance: textfield;
}

input[type="number"].bb-number-input::-webkit-inner-spin-button,
input[type="number"].bb-number-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.bb-bulk-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  margin: 0 0 10px;
}

.bb-selection-indicator {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 1px solid #474747;
  border-radius: 5px;
  background: #474747;
  color: #fff;
  font-size: 16px;
  line-height: 1;
}

.bb-danger-button,
.bb-primary-button,
.bb-secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 18px;
  border-radius: 8px;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}

.bb-danger-button {
  border: 1px solid #ed3f4d;
  background: #ed3f4d;
  color: #fff;
}

.bb-primary-button {
  border: 1px solid #1949bf;
  background: #1949bf;
  color: #fff;
}

.bb-secondary-button {
  border: 1px solid #e1e1e1;
  background: #fff;
  color: #333;
}

.bb-danger-button:hover { background: #d93442; }
.bb-primary-button:hover { background: #123da6; }
.bb-secondary-button:hover { background: #f4f4f4; }

.bb-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: grid;
  place-items: center;
  padding: 32px;
  background: rgba(25, 25, 25, 0.46);
}

.bb-modal {
  width: min(720px, calc(100vw - 64px));
  max-height: min(760px, calc(100vh - 96px));
  overflow: auto;
  border: 1px solid #e2e2e2;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.2);
}

.bb-modal--small { width: min(410px, calc(100vw - 48px)); }

.bb-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 26px;
  border-bottom: 1px solid #e7e7e7;
}

.bb-modal-header h2 {
  margin: 0;
  color: #1949bf;
  font-size: 24px;
  font-weight: 600;
}

.bb-modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 8px;
  background: #ff6b80;
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.bb-modal-body { padding: 24px 26px; }
.bb-modal-body > :first-child { margin-top: 0; }
.bb-modal-body > :last-child { margin-bottom: 0; }

.bb-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 0 26px 24px;
}

.bb-segmented {
  display: inline-flex;
  align-items: stretch;
  overflow: hidden;
  border: 1px solid #e2e2e2;
  border-radius: 7px;
  background: #f1f1f1;
}

.bb-segmented button {
  min-height: 42px;
  padding: 0 20px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #707070;
  font: inherit;
  cursor: pointer;
}

.bb-segmented button[aria-selected="true"] {
  background: #1949bf;
  color: #fff;
}

.bb-recipient-section {
  margin-top: 22px;
  padding: 20px;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
  background: #fff;
}

.bb-recipient-section h3 {
  margin: 0 0 14px;
  color: #1949bf;
  font-size: 20px;
  font-weight: 500;
}

.bb-recipient-summary {
  margin: 12px 0 0;
  color: #757575;
  font-size: 14px;
}

.bb-picker-search {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  height: 44px;
  margin: 18px 0 12px;
  padding: 0 14px;
  border: 1px solid #dedede;
  border-radius: 7px;
  background: #fff;
}

.bb-picker-search input {
  width: 100%;
  border: 0;
  outline: 0;
  font: inherit;
}

.bb-picker-list {
  overflow: hidden;
  border: 1px solid #e3e3e3;
  border-radius: 7px;
}

.bb-picker-row {
  display: grid;
  grid-template-columns: 24px 48px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 62px;
  padding: 8px 14px;
  border-bottom: 1px solid #e7e7e7;
  cursor: pointer;
}

.bb-picker-row:last-child { border-bottom: 0; }
.bb-picker-row:hover { background: #f6f8ff; }
.bb-picker-row:has(input:checked) { background: #f0f4ff; }

.bb-picker-row img {
  width: 48px;
  height: 48px;
  border-radius: 7px;
  object-fit: cover;
}

.bb-picker-row strong,
.bb-picker-row span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bb-membership-equal-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  align-items: start !important;
  gap: 24px !important;
}

.bb-membership-equal-grid > * {
  box-sizing: border-box;
  min-width: 0 !important;
  width: 100% !important;
}

@media (max-width: 900px) {
  .bb-membership-equal-grid {
    grid-template-columns: 1fr !important;
  }
}
