/* ==========================================================================
   Orblivion: live trades with their receipts (web/activity.html)
   On top of the docs' tokens and top bar (/docs/docs.css): the same colours, type and light/dark themes, in the
   league page's look.
   ========================================================================== */

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
/* the brand's gradient stops, themed (this page allows no inline styles) */
#mk-ring stop:nth-child(1) { stop-color: var(--mk-ring-0); }
#mk-ring stop:nth-child(2) { stop-color: var(--mk-ring-1); }
#mk-orbit stop:nth-child(1) { stop-color: var(--mk-orbit-0); }
#mk-orbit stop:nth-child(2) { stop-color: var(--mk-orbit-1); }
#mk-orbit stop:nth-child(3) { stop-color: var(--mk-orbit-2); }
#wm-o-grad stop:nth-child(1) { stop-color: var(--wm-o-0); }
#wm-o-grad stop:nth-child(2) { stop-color: var(--wm-o-1); }
#wm-o-grad stop:nth-child(3) { stop-color: var(--wm-o-2); }

.ac {
  max-width: 1180px; margin: 0 auto; padding: 36px var(--gutter) 64px; outline: none;
  overflow-wrap: anywhere;
}
.ac-head { max-width: 780px; margin-bottom: 26px; }
.ac-eyebrow {
  margin: 0 0 10px; font: 500 11px var(--mono); letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-3);
}
.ac h1 {
  margin: 0 0 12px;
  font-family: var(--display); font-weight: 400; font-size: clamp(24px, 3.6vw, 34px); line-height: 1.2;
  letter-spacing: 0.02em;
  background: var(--heading); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ac-lead { margin: 0; font-size: 16.5px; color: var(--text-2); }
.ac-notice {
  margin: 18px 0 0; padding: 12px 16px; border: 1px solid var(--line); border-left: 3px solid var(--accent);
  border-radius: 8px; font-size: 14.5px; line-height: 1.55; color: var(--text-2);
}
.ac-notice strong { color: var(--text); }
.ac-notice[hidden] { display: none; }
.ac-note { color: var(--text-2); }
.ac-note code { font: 13px var(--mono); }
.ac-footer { margin-top: 44px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 13px; color: var(--text-3); }
.ac-footer p { margin: 0; }
.ac-footer p + p { margin-top: 8px; }

/* ---------- cards and tiles ---------- */

.card {
  margin: 0 0 18px; padding: 20px 22px;
  border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface);
  min-width: 0;
}
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 14px; }
.card h2 { margin: 0; font-size: 18px; font-weight: 600; letter-spacing: -0.005em; }
.card-sub { margin: 0; font-size: 13px; color: var(--text-3); }
.card p { margin: 0 0 12px; }
.card p:last-child { margin-bottom: 0; }

.mono { font-family: var(--mono); }
.muted { color: var(--text-3); }
.small { font-size: 12.5px; }
.empty { margin: 4px 0 0; color: var(--text-3); font-size: 14px; }

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0 0 18px; }
.tile { padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); min-width: 0; }
.tile-label { display: block; margin-bottom: 6px; font: 500 10.5px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3); }
.tile-v { font: 500 22px/1.3 var(--font); }
.tile-v .mono { font-family: var(--mono); font-size: 21px; }
.tile-v .small-v { display: block; font-size: 15px; line-height: 1.5; }
.tile-s { margin-top: 6px; font-size: 12.5px; line-height: 1.5; color: var(--text-3); }
.tile-ok { border-left: 3px solid var(--up); }
.tile-warn { border-left: 3px solid var(--amber); }

.badge {
  display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; white-space: nowrap;
  font: 600 10.5px/1.75 var(--mono); letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-2); background: var(--surface-3); vertical-align: 1px;
}
.badge-up { color: var(--up); background: var(--up-soft); }
.badge-down { color: var(--down); background: var(--down-soft); }
.badge-team { margin-left: 0; color: var(--accent-bright); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-line); }

.err {
  margin: 0 0 16px; padding: 12px 16px; border: 1px solid var(--line-strong); border-left: 3px solid var(--down);
  border-radius: var(--radius-sm); background: var(--down-soft); font-size: 14px;
}

/* ---------- the call to action ---------- */

.cta { display: flex; align-items: center; justify-content: space-between; gap: 14px 24px; flex-wrap: wrap;
  border-left: 3px solid var(--accent); }
.cta-text { flex: 1 1 380px; min-width: 0; }
.cta h2 { margin-bottom: 6px; }
.cta p { margin: 0; color: var(--text-2); font-size: 14.5px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 40px; padding: 0 18px; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--text);
  font: 500 14px var(--font); white-space: nowrap;
}
.btn-primary { border-color: transparent; background: var(--accent-grad); color: white; }
.btn-primary:hover { opacity: 0.92; text-decoration: none; }
.btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ---------- the trades ---------- */

.tbl-wrap { overflow-x: auto; scrollbar-width: thin; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.45; }
.tbl th, .tbl td { padding: 9px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.tbl thead th {
  font: 500 10.5px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3); white-space: nowrap;
}
.tbl tbody tr:last-child td { border-bottom: 0; }
.trade { white-space: normal; }
.trade .arrow { color: var(--text-3); }
.kv-line { white-space: nowrap; }
.addr, .tx { font: 12.5px var(--mono); }
.tx { white-space: nowrap; }
.nowrap { white-space: nowrap; }
.trades td:first-child { min-width: 9.5em; }

/* ---------- the refusals ---------- */

.codes { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.codes li {
  display: flex; align-items: baseline; gap: 6px 12px; padding: 8px 12px;
  border-radius: var(--radius-sm); background: var(--surface-2); font-size: 13.5px;
}
.code-n { flex: none; min-width: 3.5em; color: var(--text); font-weight: 600; }
.codes code { font: 12.5px var(--mono); color: var(--text); }

/* ---------- narrower ---------- */

@media (max-width: 980px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .ac { padding-top: 26px; }
  .card { padding: 16px 14px; }
  .tiles { grid-template-columns: minmax(0, 1fr); }
  .cta .btn { flex: 1 1 auto; }
  /* the table becomes cards: each trade a block, each value on its label's line */
  .tbl thead { display: none; }
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; width: 100%; }
  .tbl tr { padding: 10px 0; border-bottom: 1px solid var(--line); }
  .tbl tbody tr:last-child { border-bottom: 0; }
  .tbl td { padding: 3px 0; border: 0; }
  .tbl td[data-label] { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
  .tbl td[data-label]::before {
    content: attr(data-label); flex: none; max-width: 42%;
    font: 500 10px var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3);
  }
  .tbl td[data-label] > * { min-width: 0; text-align: right; }
  .kv-line { white-space: normal; }
  .tbl .nowrap { white-space: normal; }
  .codes li { flex-wrap: wrap; }
}
@media (max-width: 480px) {
  .topbar-home { display: none; }
}
