body { background: #f5f6f8; }
.stat-card { border-width: 0 0 0 4px; border-style: solid; }
tr.clickable { cursor: pointer; }
.legend i { display: inline-block; width: .8rem; height: .8rem; border-radius: 2px; vertical-align: -1px; margin-right: .25rem; }
.fc .fc-event { cursor: pointer; font-size: .8rem; }
.fc a.fc-col-header-cell-cushion, .fc a.fc-daygrid-day-number, .fc a.fc-list-day-text,
.fc a.fc-list-day-side-text { color: inherit; text-decoration: none; }
.fc .fc-daygrid-day.fc-day-today { background: #fff3cd; }
.test-bar { background: repeating-linear-gradient(45deg, #ffc107, #ffc107 12px, #ffcd39 12px, #ffcd39 24px); color: #212529; }
.bg-purple { background-color: #6f42c1 !important; }
.bg-bounced { background-color: #842029 !important; }
.nav-badge { font-size: .6rem; vertical-align: top; }
.type-badge { font-size: .7rem; font-weight: 500; vertical-align: middle; }
.bottom-nav a { position: relative; }
.bottom-nav .nav-badge { position: absolute; top: .15rem; left: calc(50% + .35rem); }
.table td, .table th { white-space: nowrap; }
/* [hidden] must win over Bootstrap's d-flex etc. */
.cheque-only[hidden], .monthly-only[hidden], [data-act][hidden] { display: none !important; }
.table td.wrap { white-space: normal; }

/* Phone bottom navigation */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030;
  display: flex; background: #212529;
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -2px 8px rgba(0, 0, 0, .15);
}
.bottom-nav a {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: .45rem 0 .4rem; font-size: .7rem; color: #adb5bd; text-decoration: none;
}
.bottom-nav a i { font-size: 1.25rem; line-height: 1.2; }
.bottom-nav a.active { color: #fff; }
.bottom-nav a.add i {
  background: #198754; color: #fff; border-radius: 50%;
  width: 2.4rem; height: 2.4rem; display: flex; align-items: center; justify-content: center;
  margin-top: -1rem; box-shadow: 0 2px 6px rgba(0, 0, 0, .3);
}

@media (min-width: 992px) {
  .w-lg-auto { width: auto !important; }
}

@media (max-width: 991.98px) {
  main.has-bottom-nav { padding-bottom: calc(5rem + env(safe-area-inset-bottom)) !important; }
}

@media (max-width: 767.98px) {
  h1.h3 { font-size: 1.3rem; }
  .stat-card .card-body { padding: .6rem .75rem; }
  .stat-card .fs-5 { font-size: 1rem !important; }
  .table { font-size: .875rem; }
  .card-body { padding: .75rem; }
  /* 16px stops iOS zooming into inputs on focus */
  .form-control, .form-select, .input-group-text { font-size: 16px; }
  .btn { padding-top: .45rem; padding-bottom: .45rem; }
  .fc .fc-toolbar { flex-wrap: wrap; gap: .5rem; }
  .fc .fc-toolbar-title { font-size: 1.1rem; }
  .fc .fc-button { padding: .3rem .55rem; font-size: .85rem; }
  .fc .fc-daygrid-event { font-size: .7rem; }
}
