/* ============ AUTOMATIC BOOKING INCOME (booking-income.js) ============ */

/* Edit property: the one toggle and its start month */
.bi-setting { margin-top: 18px; padding: 14px 16px; border: 1px solid var(--divider-strong); border-radius: 16px; }
.bi-setting .settings-hint { margin: 6px 0 0; }
.bi-setting .bi-from { margin-top: 12px; }
.bi-setting .bi-from label { margin-top: 0; }
.bi-setting .bi-warn { color: var(--gold); }

/* "Booked ahead": never part of a total */
.bi-ahead {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 10px 2px 4px;
  font-size: 0.88em; color: var(--muted);
}
.bi-ahead b { color: var(--brand-teal-ink); font-weight: 700; }
.bi-ahead small { flex-basis: 100%; font-size: 0.92em; }
.ym-total + .bi-ahead, .pnl-summary + .bi-ahead { margin-top: 8px; }

/* Mark as reviewed: a small, quiet line under the month's income */
.bi-review { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 10px; font-size: 0.86em; color: var(--muted); }
.bi-review.done { color: var(--brand-teal-ink); font-weight: 600; }
.bi-review.changed { color: var(--gold); }
.bi-check { font-weight: 800; }
.bi-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); }
.bi-link {
  background: none; border: none; padding: 2px 0; margin: 0; width: auto; min-height: 0; box-shadow: none;
  color: var(--plum); font: inherit; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 2px;
}
.bi-review .bi-link { margin-left: auto; }
.bi-review:not(.done):not(.changed) .bi-link { margin-left: 0; }
.bi-link:disabled { opacity: 0.5; cursor: default; }
.bi-flag { margin-top: 10px; font-size: 0.84em; color: var(--gold); line-height: 1.4; }

/* Read-only booking lines in transaction lists */
.tx-tag {
  display: inline-block; font-size: 0.74em; font-weight: 700; padding: 1px 7px; border-radius: 999px;
  background: rgba(var(--brand-teal-rgb), 0.12); color: var(--brand-teal-ink); vertical-align: 1px; margin-left: 4px;
}

/* Booking details sheet */
.bi-backdrop { position: fixed; inset: 0; background: var(--backdrop); z-index: 45; }
.bi-sheet {
  position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 480px;
  max-height: 88vh; overflow-y: auto; background: var(--sheet-background); border: 1px solid var(--border);
  border-bottom: none; border-radius: 26px 26px 0 0; padding: 18px 20px calc(24px + env(safe-area-inset-bottom));
  z-index: 46; box-shadow: 0 -20px 50px var(--shadow-sheet);
}
.bi-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.bi-head h2 { margin: 0; font-size: 1.2em; }
.bi-sub { margin: 4px 0 14px; color: var(--muted); font-size: 0.9em; }
.bi-row { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--divider); font-size: 0.93em; }
.bi-row span { color: var(--text-subtle); }
.bi-row b { text-align: right; font-weight: 600; }
.bi-note { margin: 12px 0 0; font-size: 0.84em; color: var(--muted); line-height: 1.45; }
