/*
 * HENDAR UALL-Q — company-expense payment receipts and RTL finance bars.
 * Loaded after the cumulative UALL-P operability layer.
 */

.company-financial-receipt-picker {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px dashed color-mix(in srgb, var(--accent, #2563eb) 42%, var(--border, #dbe5ef));
  border-radius: 16px;
  background: color-mix(in srgb, var(--accent, #2563eb) 5%, var(--card, #fff));
}

.company-financial-receipt-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.company-financial-receipt-heading strong,
.company-financial-receipt-heading small {
  display: block;
}

.company-financial-receipt-heading strong {
  color: var(--ink, #17283a);
  font-size: 13px;
}

.company-financial-receipt-heading small,
.company-financial-receipt-picker > small {
  margin-top: 4px;
  color: var(--muted, #64748b);
  line-height: 1.65;
}

.company-financial-receipt-summary {
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--border, #dbe5ef);
  border-radius: 12px;
  background: var(--card, #fff);
  color: var(--muted, #64748b);
}

.company-financial-receipt-summary strong,
.company-financial-receipt-summary span {
  display: block;
}

.company-financial-receipt-summary strong {
  color: var(--ink, #17283a);
}

.company-financial-receipt-summary span {
  margin-top: 4px;
  overflow-wrap: anywhere;
  font-size: 10px;
  line-height: 1.7;
}

/*
 * The Arabic report reads right-to-left, so the colored value must begin at
 * the inline start (the right edge) and grow toward the left edge.
 */
.financial-bars i {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  direction: rtl;
  background: rgba(var(--accent-rgb), .12) !important;
}

.financial-bars i::after {
  content: "";
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  width: clamp(0%, var(--bar, 0%), 100%);
  border-radius: inherit;
  background: var(--accent);
}

.financial-bars.categories i {
  background: rgba(16, 185, 129, .12) !important;
}

.financial-bars.categories i::after {
  background: #10b981;
}

@media (max-width: 680px) {
  .company-financial-receipt-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .company-financial-receipt-heading .row-actions,
  .company-financial-receipt-heading .button {
    width: 100%;
  }
}
