:root { --purple: #5b2bd6; --ink: #17151f; --muted: #6b6878; --line: #e6e3ee; --bg: #f7f6fb; --ok: #12805c; --bad: #b42318; --warn: #9a5b00; }
* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); }
.top { display: flex; align-items: center; gap: 18px; padding: 10px 18px; background: #1d1433; color: #fff; position: sticky; top: 0; z-index: 2; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 24px; width: auto; display: block; }
.brand span { font-size: 13px; color: #b9addf; border-left: 1px solid #4a3a7a; padding-left: 10px; }
.login-logo { height: 30px; width: auto; justify-self: start; margin-bottom: 6px; }
nav { display: flex; gap: 4px; flex-wrap: wrap; }
nav button { background: transparent; color: #d9d0f5; border: 0; padding: 6px 10px; border-radius: 8px; cursor: pointer; font: inherit; }
nav button.active, nav button:hover { background: #3a2a66; color: #fff; }
.who { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.pill { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; background: #eee; color: #333; white-space: nowrap; }
.pill.test { background: #fff4d6; color: #6a4a00; }
main { padding: 18px; max-width: 1280px; margin: 0 auto; }
h1 { font-size: 20px; margin: 0 0 12px; }
h2 { font-size: 16px; margin: 22px 0 8px; }
.login { max-width: 420px; margin: 60px auto; background: #fff; padding: 24px; border: 1px solid var(--line); border-radius: 14px; display: grid; gap: 10px; }
input, select, textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
button { font: inherit; padding: 7px 12px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; }
button.primary { background: var(--purple); color: #fff; border-color: var(--purple); font-weight: 600; }
button.danger { color: var(--bad); border-color: #f0c4bf; }
button.link { background: none; border: 0; color: #d9d0f5; text-decoration: underline; }
.error { color: var(--bad); }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.tile .k { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.tile .v { font-size: 22px; font-weight: 700; margin-top: 2px; }
.tile.ok { border-left: 4px solid var(--ok); }
.tile.bad { border-left: 4px solid var(--bad); }
.tile.warn { border-left: 4px solid #d99a1e; }
table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
th, td { text-align: left; padding: 7px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: #faf9fd; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
tr.click { cursor: pointer; }
tr.click:hover td { background: #f6f2ff; }
td.num { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; word-break: break-all; }
.muted { color: var(--muted); }
.st { font-weight: 600; font-size: 12px; padding: 2px 8px; border-radius: 999px; background: #eee; white-space: nowrap; }
.st.matched, .st.balanced, .st.settled, .st.refunded, .st.completed, .st.sent, .st.delivered { background: #e3f4ec; color: var(--ok); }
.st.mismatch, .st.unbalanced, .st.rejected, .st.failed, .st.expired, .st.dead { background: #fdecea; color: var(--bad); }
.st.under_review, .st.underpaid, .st.decision_pending, .st.refund_pending, .st.awaiting_destination { background: #fff3dc; color: var(--warn); }
.toolbar { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 900px) { .two { grid-template-columns: 1fr; } }
.box { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 4px 12px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { padding: 6px 0 6px 14px; border-left: 2px solid #ddd2fb; position: relative; }
.timeline li::before { content: ''; position: absolute; left: -5px; top: 11px; width: 8px; height: 8px; border-radius: 50%; background: var(--purple); }
.posting { font-size: 12px; }
.pos { color: var(--ok); } .neg { color: var(--bad); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.notice { background: #fff8e6; border: 1px solid #f1dca4; border-radius: 10px; padding: 10px 12px; margin-bottom: 12px; }
pre { white-space: pre-wrap; font-size: 12px; background: #faf9fd; padding: 8px; border-radius: 8px; margin: 4px 0; }
[hidden] { display: none !important; }
.flush { margin: 0; }
