.aea-content:has([data-aea-payments]) > .aea-module {
  display: none !important;
}

.aea-payments {
  --ink: #0f172a;
  --muted: #64748b;
  --teal: #0f766e;
  font-family: "DM Sans", sans-serif;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 4px 2px 28px;
}

.aea-pay-head, .aea-pay-top, .aea-pay-filters, .aea-pay-pager, .aea-pay-person, .aea-pay-method {
  display: flex;
  align-items: center;
  gap: 10px;
}
.aea-pay-head h1 { margin: 0; font-size: 26px; letter-spacing: -0.03em; }
.aea-pay-head p { margin: 2px 0 0; color: var(--muted); font-size: 13.5px; }
.aea-pay-mark {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #d1fae5;
  color: #047857;
  flex: none;
}

.aea-pay-top { justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.aea-pay-tabs { display: flex; gap: 6px; flex-wrap: wrap; background: #fff; border: 1px solid #eef3f6; border-radius: 14px; padding: 6px; }
.aea-pay-tab, .aea-pay-line, .aea-pay-go, .aea-pay-ghost {
  height: 36px;
  border-radius: 10px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font: 700 13px "DM Sans", sans-serif;
  cursor: pointer;
}
.aea-pay-tab { border: 0; background: transparent; color: #64748b; }
.aea-pay-tab.is-on { background: #042f2e; color: #fff; }
.aea-pay-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.aea-pay-line { border: 1px solid #d1fae5; background: #fff; color: var(--teal); }
.aea-pay-go { border: 0; background: var(--teal); color: #fff; }
.aea-pay-ghost { border: 1px solid #e7eef2; background: #fff; color: #334155; }

.aea-pay-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.aea-pay-kpi {
  background: #fff;
  border: 1px solid #eef3f6;
  border-radius: 16px;
  padding: 12px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  min-width: 0;
}
.aea-pay-kpi b { display: block; font-size: 18px; letter-spacing: -0.03em; }
.aea-pay-kpi span, .aea-pay-kpi small { color: var(--muted); font-size: 12px; font-weight: 700; }
.aea-pay-kpi small { color: #059669; }
.aea-pay-ico {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: none;
}
.aea-pay-kpi.is-green { background: #f0fdf4; }
.aea-pay-kpi.is-green .aea-pay-ico { background: #dcfce7; color: #15803d; }
.aea-pay-kpi.is-blue { background: #eff6ff; }
.aea-pay-kpi.is-blue .aea-pay-ico { background: #dbeafe; color: #1d4ed8; }
.aea-pay-kpi.is-amber { background: #fffbeb; }
.aea-pay-kpi.is-amber .aea-pay-ico { background: #fef3c7; color: #b45309; }
.aea-pay-kpi.is-red { background: #fff1f2; }
.aea-pay-kpi.is-red .aea-pay-ico { background: #ffe4e6; color: #be123c; }
.aea-pay-kpi.is-violet { background: #f5f3ff; }
.aea-pay-kpi.is-violet .aea-pay-ico { background: #ede9fe; color: #6d28d9; }

.aea-pay-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; align-items: start; }
.aea-pay-main, .aea-pay-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.aea-pay-card {
  background: #fff;
  border: 1px solid #eef3f6;
  border-radius: 18px;
  padding: 14px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}
.aea-pay-card h2 { margin: 0; font-size: 16px; }
.aea-pay-filters { flex-wrap: wrap; margin-bottom: 12px; }
.aea-pay-input, .aea-pay-select {
  height: 38px;
  border: 1px solid #e6edf2;
  border-radius: 10px;
  padding: 0 10px;
  font: 600 13px "DM Sans", sans-serif;
  color: var(--ink);
  background: #fff;
  box-sizing: border-box;
  min-width: 0;
}
.aea-pay-q { width: min(280px, 100%); flex: 1; }
.aea-pay-dates { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 700; }
.aea-pay-dates input { width: 138px; }

.aea-pay-scroll { overflow-x: auto; }
.aea-payments table { width: 100%; border-collapse: collapse; min-width: 980px; }
.aea-payments th, .aea-payments td {
  text-align: left;
  padding: 10px 8px;
  border-top: 1px solid #f1f5f9;
  font-size: 13px;
  white-space: nowrap;
  vertical-align: middle;
}
.aea-payments th { color: #94a3b8; font-size: 12px; font-weight: 700; }
.aea-pay-stack { display: grid; }
.aea-pay-stack small, .aea-pay-muted { color: var(--muted); font-size: 12px; font-weight: 600; }
.aea-pay-avatar {
  width: 28px;
  height: 28px;
  border-radius: 99px;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  color: #0f766e;
  background: #d1fae5;
  flex: none;
}
.aea-pay-amt { font-weight: 800; }
.aea-pay-status {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 800;
}
.aea-pay-status.is-paid { background: #dcfce7; color: #15803d; }
.aea-pay-status.is-pending { background: #fef3c7; color: #b45309; }
.aea-pay-status.is-failed { background: #ffe4e6; color: #be123c; }
.aea-pay-status.is-refunded { background: #ffe4e6; color: #e11d48; }
.aea-pay-iconbtn {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  border: 1px solid #e7eef2;
  background: #fff;
  color: #475569;
  display: grid;
  place-items: center;
  cursor: pointer;
}
.aea-pay-menu {
  position: absolute;
  right: 0;
  top: 34px;
  z-index: 5;
  background: #fff;
  border: 1px solid #e7eef2;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  min-width: 160px;
  padding: 6px;
}
.aea-pay-menu button {
  border: 0;
  background: transparent;
  text-align: left;
  padding: 8px 10px;
  border-radius: 8px;
  font: 700 13px "DM Sans", sans-serif;
  cursor: pointer;
  color: #334155;
}
.aea-pay-menu button:hover { background: #f8fafc; }
.aea-pay-empty { text-align: center; color: var(--muted); padding: 22px !important; }

.aea-pay-pager { justify-content: space-between; margin-top: 12px; color: var(--muted); font-size: 13px; font-weight: 700; flex-wrap: wrap; }
.aea-pay-pages { display: flex; gap: 4px; align-items: center; }
.aea-pay-pages button, .aea-pay-size {
  min-width: 32px;
  height: 32px;
  border-radius: 9px;
  border: 1px solid #e7eef2;
  background: #fff;
  font: 700 13px "DM Sans", sans-serif;
  cursor: pointer;
  color: #475569;
}
.aea-pay-pages button.is-on { background: var(--teal); border-color: var(--teal); color: #fff; }
.aea-pay-size { padding: 0 8px; }

.aea-pay-side-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.aea-pay-pill { background: #f1f5f9; color: #64748b; border-radius: 999px; padding: 4px 8px; font-size: 12px; font-weight: 800; }
.aea-pay-chart { display: flex; gap: 14px; align-items: center; margin-top: 14px; }
.aea-pay-donut {
  width: 132px;
  height: 132px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: none;
  background: conic-gradient(#7c3aed 0 40.2%, #0f766e 40.2% 73%, #f59e0b 73% 93.6%, #cbd5e1 93.6% 100%);
}
.aea-pay-donut div {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 8px;
}
.aea-pay-donut strong { font-size: 12px; letter-spacing: -0.03em; }
.aea-pay-donut span { color: var(--muted); font-size: 10px; font-weight: 700; }
.aea-pay-legend { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.aea-pay-legend div { display: grid; grid-template-columns: 10px 1fr auto; gap: 6px; align-items: center; font-size: 12px; font-weight: 700; }
.aea-pay-legend i { width: 8px; height: 8px; border-radius: 99px; display: block; }
.aea-pay-legend b { color: var(--ink); }
.aea-pay-link { border: 0; background: transparent; color: var(--teal); font: 800 12px "DM Sans", sans-serif; cursor: pointer; }
.aea-pay-refund { display: flex; justify-content: space-between; gap: 8px; padding: 10px 0; border-top: 1px solid #f1f5f9; }
.aea-pay-refund b { color: #e11d48; }
.aea-pay-tag { color: #e11d48; font-size: 11px; font-weight: 800; }

.aea-pay-shade { position: fixed; inset: 0; background: rgba(15, 23, 42, 0.28); display: flex; z-index: 40; }
.aea-pay-drawer {
  margin-left: auto;
  width: min(420px, 100%);
  height: 100%;
  background: #fff;
  padding: 20px;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.aea-pay-modal {
  width: min(480px, calc(100% - 32px));
  margin: auto;
  background: #fff;
  border-radius: 18px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: calc(100% - 32px);
  overflow: auto;
}
.aea-pay-modal h2, .aea-pay-drawer h2 { margin: 0; }
.aea-pay-field { display: grid; gap: 6px; font-size: 12px; font-weight: 700; color: #475569; }
.aea-pay-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.aea-pay-error { margin: 0; background: #fff1f2; color: #be123c; border-radius: 10px; padding: 8px 10px; font-size: 13px; font-weight: 700; }
.aea-pay-modal-actions { display: flex; justify-content: flex-end; gap: 8px; }
.aea-pay-bar { height: 8px; border-radius: 99px; background: #f1f5f9; overflow: hidden; }
.aea-pay-bar span { display: block; height: 100%; border-radius: 99px; }
.aea-pay-report-row { display: grid; grid-template-columns: 72px 1fr auto; gap: 8px; align-items: center; font-size: 13px; font-weight: 700; }

@media (max-width: 1200px) {
  .aea-pay-kpis, .aea-pay-layout { grid-template-columns: 1fr; }
}
