body {
  background: #f7f7fb;
}

.navbar.fixed-top ~ .page-body-wrapper {
  padding-top: 70px;
}

.content-wrapper {
  padding-top: 2.75rem !important;
}

.page-header {
  margin-top: 1rem !important;
  padding-top: 1rem;
}

@media (max-width: 575px) {
  .content-wrapper {
    padding-top: 2.25rem !important;
  }
}

.compact-filters {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid #e5e8f0;
  border-radius: 5px;
  background: #f8f9fc;
  width: fit-content;
  max-width: 100%;
  flex-wrap: wrap;
}

.compact-filters-label {
  color: #5f6675;
  font-size: 12px;
  font-weight: 600;
  margin-right: 3px;
}

.compact-filters input,
.compact-filters select {
  height: 30px;
  min-width: 135px;
  padding: 3px 7px;
  border: 1px solid #dfe3ed;
  border-radius: 3px;
  background: #fff;
  color: #4a5060;
  font-size: 12px;
}

.compact-filters select {
  min-width: 145px;
}

.compact-filters-separator {
  color: #8b91a0;
  font-size: 11px;
}

.compact-filters-apply,
.compact-filters-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 3px;
  cursor: pointer;
}

.compact-filters-apply {
  background: #6f42c1;
  color: #fff;
}

.compact-filters-clear {
  background: #e9ecf2;
  color: #626a78;
  text-decoration: none;
}

@media (max-width: 575px) {
  .compact-filters { width: 100%; }
  .compact-filters input, .compact-filters select { flex: 1 1 120px; min-width: 0; }
}

.card,
.alert {
  border-radius: 8px;
}

.stat-card {
  border: 0;
  color: #fff;
  overflow: hidden;
}

.stat-card .card-title,
.stat-card .text-muted {
  color: rgba(255, 255, 255, .82) !important;
}

.stat-card h2 {
  color: #fff;
}

.stat-card-purple { background: linear-gradient(135deg, #6f42c1, #9b6ee8); }
.stat-card-blue { background: linear-gradient(135deg, #2186c4, #54c3e5); }
.stat-card-orange { background: linear-gradient(135deg, #e27843, #f6b26b); }
.stat-card-green { background: linear-gradient(135deg, #198754, #52bf8a); }

.stat-icon {
  font-size: 32px;
  opacity: .8;
}

.badge-outline-success {
  border: 1px solid #1bcfb4;
  color: #159d89;
  padding: 6px 10px;
}

.overview-chart {
  height: 260px;
  padding-top: 18px;
}

.chart-bars {
  height: 210px;
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  gap: 10px;
  border-bottom: 1px solid #e9e9ef;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent 51px, #f0f0f5 52px);
}

.chart-bars span {
  width: 5.5%;
  min-height: 24px;
  border-radius: 5px 5px 0 0;
  background: linear-gradient(to top, #9b6ee8, #dca8ff);
}

.chart-labels {
  display: flex;
  justify-content: space-around;
  padding-top: 10px;
  color: #9a9aab;
  font-size: 11px;
}

.activity-row {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f0f0f4;
}

.activity-row:last-child {
  border-bottom: 0;
}

.activity-dot {
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  margin-top: 5px;
  border-radius: 50%;
  background: #6f42c1;
}

.activity-success { background: #1bcfb4; }
.activity-warning { background: #fe9496; }
.activity-info { background: #198ae3; }

.investment-chart-wrap {
  height: 320px;
  position: relative;
}

.investment-doughnut-wrap {
  height: 250px;
  position: relative;
}

.investment-summary-row .card-description strong {
  color: #6f42c1;
}

.investment-total-row {
  background: #fffde7;
  border-top: 2px solid #f4e300;
}

.investment-total-row th {
  color: #5d5200;
  font-size: 15px;
}

.ledger-summary-row .card {
  height: 100%;
}

.ledger-total-card {
  border: 0;
  color: #fff;
}

.ledger-total-card .card-title,
.ledger-total-card h2 {
  color: #fff;
}

.ledger-withdrawal { background: linear-gradient(135deg, #d9534f, #f08a85); }
.ledger-deposit { background: linear-gradient(135deg, #198754, #52bf8a); }
.ledger-closing { background: linear-gradient(135deg, #4b77be, #7fa7e5); }

.ledger-expense-chart-wrap {
  height: 360px;
  position: relative;
}

.petty-cash-row-tallied,
.ledger-petty-cash-tallied {
  --bs-table-bg: #eaf8ef;
  background-color: #eaf8ef !important;
}

.petty-cash-row-pending,
.ledger-petty-cash-pending {
  --bs-table-bg: #fff0f0;
  background-color: #fff0f0 !important;
}

.petty-cash-row-tallied > td,
.ledger-petty-cash-tallied > td {
  background-color: #eaf8ef !important;
}

.petty-cash-row-tallied > td {
  background-color: inherit !important;
}

.petty-cash-row-pending > td,
.ledger-petty-cash-pending > td {
  background-color: #fff0f0 !important;
}

.petty-cash-tally {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 4px;
  color: #fff;
  font-weight: 700;
}

.petty-cash-tally-yes {
  background: #198754;
}

.petty-cash-tally-no {
  background: #dc3545;
}

.master-filter {
  display: flex;
  align-items: center;
  max-width: 360px;
}

.master-filter .form-control {
  min-width: 210px;
}

.badge-outline-primary {
  border: 1px solid #b66dff;
  color: #8446c4;
  background: #faf7ff;
}

.modal-content {
  border: 0;
  border-radius: 8px;
  box-shadow: 0 10px 35px rgba(88, 64, 120, .2);
}

.modal-header {
  background: linear-gradient(135deg, #8446c4, #b66dff);
  color: #fff;
  border-radius: 8px 8px 0 0;
}

.modal-header .btn-close {
  filter: brightness(0) invert(1);
}

.attachment-preview-body {
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.attachment-preview-body iframe {
  width: 100%;
  height: 70vh;
  border: 0;
}

.attachment-preview-body img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
}
