/* Markets lane: shared System A pieces for markets, orders, perps, copy, wallets and Elysium.
   The wallet dialog and confirm dialogs become slabs; the page head is the open-floor hero. No boxes, no pills, no monospace. */

/* the hidden attribute always wins over a component's display */
.qa [hidden] { display: none !important; }

/* skip link: hidden until focused */
.qa .mk-skip { position: absolute; z-index: 100; left: 12px; top: -60px; padding: 10px 14px; border-radius: var(--qa-r-m); background: var(--qa-slab-a); color: var(--qa-tx); font-weight: 680; box-shadow: var(--qa-slab-edge), var(--qa-shadow-pop); }
.qa .mk-skip:focus { top: 12px; }

/* wallet trigger inside the shell slot (wallet-site.css styles .qhc-trigger as a pill; the shell button wins here) */
.qa-hdr .qa-wallet .qa-btn.qhc-trigger { min-height: 0; border: 0; border-radius: var(--qa-r-m); font-size: 14px; font-weight: 740; }
.qa-hdr .qa-wallet .qa-btn--primary.qhc-trigger { color: var(--qa-tx-on-gold); background: var(--qa-gold-metal); }
.qa-hdr .qa-wallet .qa-btn--secondary.qhc-trigger { color: var(--qa-tx); background: var(--qa-wash-2); }
.qa-hdr .qa-wallet .qa-btn--secondary.qhc-trigger:hover { background: var(--qa-rule-2); }

/* ---------- dialogs: the wallet dialog and confirmations are slabs ---------- */
.qa .qhc-dialog, .qa dialog.mk-slab { width: min(440px, calc(100% - 24px)); max-height: calc(100dvh - 40px); padding: 22px; border: 0; border-radius: var(--qa-r-slab); color: var(--qa-tx);
  background: var(--qa-slab); box-shadow: var(--qa-slab-edge), var(--qa-slab-shadow); font-family: var(--qa-sans); font-size: 15px; }
.qa .qhc-dialog::backdrop, .qa dialog.mk-slab::backdrop { background: rgba(0, 0, 0, .6); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.qa .qhc-dialog p { color: var(--qa-tx-2); font-size: 14px; line-height: 1.5; }
.qa .qhc-heading h2 { font-size: var(--qa-fs-display-s); font-weight: 820; font-stretch: var(--qa-wd-head); letter-spacing: var(--qa-track-head); }
.qa .qhc-heading button { width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--qa-wash-2); color: var(--qa-tx); font-size: 22px; }
.qa .qhc-choice, .qa .qhc-secondary { min-height: 46px; padding: 0 14px; border: 0; border-radius: var(--qa-r-m); background: var(--qa-wash-2); color: var(--qa-tx); font-weight: 680; display: flex; align-items: center; }
.qa .qhc-choice:hover, .qa .qhc-secondary:hover { background: var(--qa-rule-2); }
.qa .qhc-login > .qhc-choice { justify-content: center; color: var(--qa-tx-on-gold); background: var(--qa-gold-metal); box-shadow: inset 0 1px 0 rgba(255,255,255,.5); }
.qa .qhc-login, .qa .qhc-mobile { border-bottom: 0; box-shadow: 0 1px 0 var(--qa-rule); }
.qa .qhc-dialog .qhc-footnote { border-top: 0; box-shadow: 0 -1px 0 var(--qa-rule); color: var(--qa-tx-3); font-size: 12.5px; }
.qa .qhc-address { font-family: var(--qa-sans); font-weight: 620; color: var(--qa-tx); }
.qa .qhc-dialog select { border: 0; border-radius: var(--qa-r-m); background: var(--qa-wash-2); color: var(--qa-tx); padding: 10px 12px; }

/* ---------- page head on the open floor ---------- */
.mk-hero { position: relative; padding: 28px 0 8px; }
.mk-hero__kick { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 680; color: var(--qa-gold-hi); }
.mk-hero__kick .qa-live { font-size: 13px; }
.mk-hero h1 { margin-top: 10px; font-size: 44px; line-height: .95; font-weight: 850; font-stretch: var(--qa-wd-display); letter-spacing: var(--qa-track-display); text-wrap: balance; }
.mk-hero__lede { margin-top: 14px; max-width: 54ch; font-size: 16px; line-height: 1.45; color: var(--qa-tx-2); }
.mk-hero__acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.mk-hero__acts .qa-btn.is-connected { color: var(--qa-tx); background: var(--qa-wash-2); box-shadow: none; }
.mk-status:empty { display: none; }
.mk-status { margin-top: 14px; font-size: 14px; font-weight: 600; color: var(--qa-gold-hi); }

/* live tags and figures shared by the lane */
.mk-tick { transition: color var(--qa-t-flash) var(--qa-ease), text-shadow var(--qa-t-flash) var(--qa-ease); }
.mk-tick.is-up { color: var(--qa-buy) !important; text-shadow: 0 0 18px rgba(62,221,143,.6); transition: none; }
.mk-tick.is-down { color: var(--qa-sell) !important; text-shadow: 0 0 18px rgba(255,94,100,.55); transition: none; }
.mk-enter { animation: qa-row-in .55s var(--qa-ease-out) both; }
.mk-coin { position: relative; display: inline-grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; overflow: hidden; font-size: 15px; font-weight: 820; font-stretch: 112%; color: var(--qa-tx-on-gold);
  background: var(--qa-gold-metal) center / cover; box-shadow: 0 0 0 1px rgba(255,255,255,.1), 0 8px 18px -8px rgba(0,0,0,.8); }
.mk-coin img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

@media (min-width: 1100px) {
  .mk-hero { padding-top: 44px; }
  .mk-hero h1 { font-size: 72px; }
  .mk-hero__lede { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) { .mk-enter { animation: none; } .mk-tick { transition: none; } }

/* ---------- live market rows (markets, orders): token art, ticking price, age ---------- */
.mk-mlist { margin: 0 calc(var(--qa-pad) * -1); }
.mk-mrow { position: relative; box-shadow: 0 1px 0 var(--qa-rule-row); }
.mk-mrow__a { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; grid-template-areas: "coin id px" "coin id chg"; column-gap: 12px; align-items: center; min-height: 64px; padding: 10px var(--qa-pad);
  transition: background-color var(--qa-t-quick) var(--qa-ease); }
.mk-mrow__a:hover { background: var(--qa-wash); }
.mk-mrow.is-on .mk-mrow__a { background: linear-gradient(90deg, var(--qa-gold-wash), transparent 70%); }
.mk-mrow .mk-coin { grid-area: coin; width: 40px; height: 40px; font-size: 16px; }
.mk-mrow__id { grid-area: id; display: grid; min-width: 0; }
.mk-mrow__id b { font-size: 16px; font-weight: 760; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-mrow__id small { font-size: 12.5px; color: var(--qa-tx-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-mrow__px { grid-area: px; justify-self: end; font-size: 16px; font-weight: 760; white-space: nowrap; }
.mk-mrow__chg { grid-area: chg; justify-self: end; font-size: 12.5px; font-weight: 700; }
.mk-mrow__mc, .mk-mrow__age { display: none; font-size: 13px; color: var(--qa-tx-2); white-space: nowrap; }
.mk-mlist__empty { padding: 18px var(--qa-pad); color: var(--qa-tx-2); }
@media (min-width: 1100px) {
  .mk-mlist { margin: 0; }
  .mk-mrow__a { padding: 10px 6px; }
}
