.rl-panel {
  max-width: 1580px;
  margin: 12px auto 0;
  padding: 13px 15px;
  border: 1px solid #ded8e5;
  border-left: 4px solid var(--purple);
  border-radius: 12px;
  background: linear-gradient(135deg,#fff 0%,#faf8fc 100%);
  box-shadow: var(--shadow-xs);
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 12px 18px;
  align-items: center;
}
.rl-panel.finance_pending,
.rl-panel.lost_finance_pending { border-left-color: var(--orange); }
.rl-panel.close_pending { border-left-color: #28755a; }
.rl-panel.archived,
.rl-panel.lost { border-left-color: #687080; background: #f7f8fa; }
.rl-panel.error { border-left-color: var(--red); }
.rl-main { min-width: 0; display: grid; gap: 10px; }
.rl-heading { display: grid; gap: 2px; }
.rl-heading > span { color: var(--purple); font-size: 8px; font-weight: 850; letter-spacing: .08em; }
.rl-heading > strong { color: var(--text); font-size: 14px; }
.rl-heading > p { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.5; }
.rl-steps { display: grid; grid-template-columns: repeat(4,minmax(88px,1fr)); gap: 5px; }
.rl-steps span { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 8px; font-weight: 800; }
.rl-steps i { width: 20px; height: 20px; border: 1px solid #d9dce2; border-radius: 50%; display: grid; place-items: center; background: white; font-style: normal; }
.rl-steps span::after { content: ''; height: 1px; background: #e1e3e8; flex: 1; }
.rl-steps span:last-child::after { display: none; }
.rl-steps .done { color: #28755a; }
.rl-steps .done i { border-color: #afd5c6; background: #eaf7f1; }
.rl-steps .current { color: var(--purple); }
.rl-steps .current i { border-color: var(--purple); background: #f1e8f8; }
.rl-actions { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 7px; max-width: 510px; }
.rl-saving { color: var(--purple); font-size: 9px; font-weight: 800; }
.rl-inline-error { grid-column: 1 / -1; padding: 8px 10px; border: 1px solid #edc6cc; border-radius: 8px; background: #fff4f5; color: var(--red); font-size: 9px; }
.rl-blockers { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; }
.rl-blockers li { display: grid; gap: 1px; padding: 6px 8px; border-radius: 7px; background: #fff7ee; }
.rl-blockers strong { font-size: 8px; }
.rl-blockers span { color: var(--muted); font-size: 7px; }

body.rl-modal-open { overflow: hidden; }
.rl-modal-backdrop { position: fixed; inset: 0; z-index: 10020; display: grid; place-items: center; padding: 22px; background: rgba(24,24,32,.62); backdrop-filter: blur(4px); }
.rl-modal { width: min(680px,100%); max-height: calc(100vh - 44px); overflow: auto; border-radius: 15px; background: white; box-shadow: 0 24px 80px rgba(20,18,25,.35); }
.rl-modal > header { position: sticky; top: 0; z-index: 2; display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 18px 20px; border-bottom: 1px solid var(--border); background: white; }
.rl-modal > header span { color: var(--purple); font-size: 8px; font-weight: 850; letter-spacing: .08em; }
.rl-modal > header h2 { margin: 3px 0 0; font-size: 20px; }
.rl-modal > header button { width: 34px; height: 34px; border: 0; border-radius: 9px; background: #f0f1f4; color: var(--text); font-size: 24px; cursor: pointer; }
.rl-modal-body { padding: 18px 20px 20px; display: grid; gap: 12px; }
.rl-modal-body > p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.rl-modal-body > label,
.rl-cash-fields label { display: grid; gap: 5px; }
.rl-modal-body label > span { color: var(--text); font-size: 9px; font-weight: 800; }
.rl-modal-body input,
.rl-modal-body select,
.rl-modal-body textarea { width: 100%; min-height: 40px; padding: 9px 10px; border: 1px solid #d9dce2; border-radius: 9px; background: white; color: var(--text); font: inherit; font-size: 10px; }
.rl-modal-body textarea { min-height: 92px; resize: vertical; }
.rl-modal-body small { color: var(--muted); font-size: 8px; }
.rl-cash-fields { display: grid; gap: 12px; padding: 12px; border: 1px solid #d9c7e7; border-radius: 10px; background: #faf7fd; }
.rl-cash-fields[hidden] { display: none; }
.rl-modal-warning { display: grid; gap: 3px; padding: 11px 12px; border-left: 3px solid var(--orange); border-radius: 8px; background: #fff8ef; }
.rl-modal-warning strong { font-size: 9px; }
.rl-modal-warning span { color: var(--muted); font-size: 8px; line-height: 1.45; }
.rl-modal-body footer { position: sticky; bottom: -20px; display: flex; justify-content: flex-end; gap: 8px; margin: 4px -20px -20px; padding: 13px 20px; border-top: 1px solid var(--border); background: white; }
.rl-confirm { display: flex !important; grid-template-columns: auto 1fr; align-items: center; gap: 8px !important; padding: 11px; border-radius: 8px; background: #f6f2f9; }
.rl-attestation { display: flex !important; grid-template-columns: auto 1fr; align-items: center; gap: 8px !important; padding: 11px; border-radius: 8px; background: #f6f2f9; }
.rl-confirm input,
.rl-attestation input { width: 17px; min-height: 17px; }
.rl-modal-error { padding: 12px; border: 1px solid #edc6cc; border-radius: 8px; background: #fff4f5; color: var(--red); }
.rl-form-error { padding: 9px 10px; border: 1px solid #edc6cc; border-radius: 8px; background: #fff4f5; color: var(--red); font-size: 9px; font-weight: 750; }
.rl-form-error[hidden] { display: none; }

@media (max-width: 900px) {
  .rl-panel { grid-template-columns: 1fr; }
  .rl-actions { justify-content: flex-start; max-width: none; }
}
@media (max-width: 620px) {
  .rl-panel { margin: 9px 0 0; padding: 11px; }
  .rl-steps { grid-template-columns: repeat(2,1fr); }
  .rl-blockers { grid-template-columns: 1fr; }
  .rl-modal-backdrop { padding: 8px; }
  .rl-modal { max-height: calc(100vh - 16px); }
}
