/* Mobee Market — deep blue, neon yellow, machine type.
   Single-theme on purpose: this is a trading screen, not a document. */
:root {
  color-scheme: dark;
  --bg: #060a14;
  --bg-2: #08101f;
  --panel: #0b1424;
  --raise: #101c31;
  --line: #1b2b47;
  --line-2: #14203a;

  --ink: #e9f1ff;
  --ink-2: #b8c8e6;
  --muted: #7d90b4;
  --faint: #566a91;

  --neon: #e5ff3d;          /* money, prices, the thing you came for */
  --neon-dim: rgba(229, 255, 61, 0.13);
  --blue: #47a6ff;          /* structure, links, secondary signal */
  --blue-dim: rgba(71, 166, 255, 0.14);
  --warn: #ff7a4d;

  --mono: ui-monospace, "SF Mono", "JetBrains Mono", "Roboto Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --sans: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --nav-h: 54px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 14px/1.5 var(--mono);
  -webkit-font-smoothing: antialiased;
}
code { font-family: var(--mono); }
button { font: inherit; color: inherit; }
a { color: var(--blue); }
:focus-visible { outline: 2px solid var(--neon); outline-offset: 2px; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 24px;
  height: var(--nav-h); padding: 0 18px;
  background: rgba(6, 10, 20, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex; align-items: center; gap: 9px;
  color: var(--ink); text-decoration: none;
  font-weight: 700; font-size: 15px; letter-spacing: 0.14em;
}
.brand .mark { width: 20px; height: 20px; color: var(--neon); }
.nav-links { display: flex; align-items: center; gap: 22px; margin-left: 8px; }
.nav-links a {
  color: var(--ink-2); text-decoration: none;
  font-size: 12.5px; letter-spacing: 0.08em; text-transform: uppercase;
}
.nav-links a:hover { color: var(--neon); }
.nav-links a.soon { color: var(--faint); cursor: default; }
.nav-links a.soon:hover { color: var(--faint); }

.conn { display: flex; align-items: center; gap: 7px; margin: 0 0 0 auto; font-size: 11.5px; color: var(--muted); }
.lamp { width: 7px; height: 7px; border-radius: 50%; background: var(--faint); flex: none; }
.conn[data-state="live"] .lamp { background: var(--neon); box-shadow: 0 0 0 3px var(--neon-dim), 0 0 10px var(--neon); }
.conn[data-state="history"] .lamp, .conn[data-state="connecting"] .lamp { background: var(--blue); animation: blink 1.2s ease-in-out infinite; }
.conn[data-state="failed"] .lamp, .conn[data-state="reconnecting"] .lamp { background: var(--warn); }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.2; } }

/* ---------- hero: half the viewport, book visible below ---------- */
.hero {
  height: calc(50vh - var(--nav-h)); min-height: 300px;
  display: flex; align-items: center; justify-content: center;
  padding: 24px 18px; text-align: center;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(900px 380px at 50% -10%, rgba(71, 166, 255, 0.13), transparent 70%),
    linear-gradient(var(--bg-2), var(--bg));
}
.hero-in { max-width: 760px; min-width: 0; }
.hero h1 {
  margin: 0; font-size: clamp(34px, 7vw, 68px); font-weight: 700;
  letter-spacing: 0.12em; line-height: 1.02; color: var(--ink);
  text-shadow: 0 0 34px rgba(229, 255, 61, 0.16);
}
.hero .sub {
  margin: 12px 0 0; color: var(--neon);
  font-size: clamp(13px, 1.6vw, 17px); letter-spacing: 0.34em; text-transform: uppercase;
}
/* two entry points, labelled — a visitor should know which line is theirs.
   Built to read as a terminal: dark well, prompt glyph, hard-separated zones. */
.runs { display: inline-flex; flex-direction: column; gap: 10px; margin: 26px 0 0; max-width: 100%; }
.run {
  display: inline-flex; align-items: stretch; max-width: 100%; min-width: 0;
  background: #04070e;
  border: 1px solid var(--line); border-radius: 9px; overflow: hidden;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset;
}
.run .lbl {
  flex: none; display: flex; align-items: center; justify-content: center;
  min-width: 64px; padding: 0 13px;
  background: var(--blue-dim); color: var(--blue);
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  border-right: 1px solid var(--line);
}
.run .lbl.sell { background: var(--neon-dim); color: var(--neon); }
.run code {
  flex: 1; min-width: 0; display: flex; align-items: center; gap: 9px;
  padding: 12px 16px; font-size: 12.5px; color: var(--ink);
  white-space: nowrap; overflow-x: auto; text-align: left;
}
.run code::before { content: "$"; color: var(--faint); flex: none; }
.run button {
  flex: none; border: 0; border-left: 1px solid var(--line);
  background: var(--raise); color: var(--muted); cursor: pointer;
  padding: 0 16px; font-size: 10.5px; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  transition: background 0.12s ease, color 0.12s ease;
}
.run button:hover { background: var(--neon); color: #0a0d02; }
/* Confirmed copy. The tick is wider than the word it replaces is tall, so the
   button holds its width to stop the command box twitching on click. */
.run button.ok, .run button.ok:hover { background: var(--neon); color: #0a0d02; font-size: 14px; }
.run button { min-width: 74px; }
/* balance: the browser evens the line lengths instead of filling line 1 and
   leaving a stub on line 2. max-width keeps it to two lines to balance. */
/* margin-inline auto, not just max-width: the hero centers its TEXT, but a
   narrowed block still sits left in its container unless the box is centred too. */
.hero-note { margin: 20px auto 0; color: var(--muted); font-size: 13px; max-width: 62ch; text-wrap: balance; }

/* ---------- market ---------- */
.market { padding: 22px 18px 0; }
.market-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; flex-wrap: wrap; margin-bottom: 12px;
}
.market-bar h2 { margin: 0; font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.windows { display: flex; gap: 2px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 3px; }
.windows button {
  border: 0; background: transparent; color: var(--muted); cursor: pointer;
  padding: 5px 13px; border-radius: 5px; font-size: 11.5px; letter-spacing: 0.06em;
  text-transform: uppercase; white-space: nowrap;
}
.windows button:hover { color: var(--ink); }
.windows button[aria-pressed="true"] { background: var(--neon); color: #0a0d02; font-weight: 700; }

/* one page tall; each column scrolls inside */
.book {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 1px; height: 100vh;
  background: var(--line);
  border: 1px solid var(--line); border-radius: 10px; overflow: hidden;
}
.col { background: var(--panel); display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.col.mid { background: var(--bg-2); }
.col-bar {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 12px 14px 8px; flex: none;
}
.col-bar h3 { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--blue); }
.col-meta { font-size: 10.5px; color: var(--faint); }

.rows { list-style: none; margin: 0; padding: 0 0 12px; overflow-y: auto; flex: 1; min-height: 0; }
.rows::-webkit-scrollbar { width: 8px; }
.rows::-webkit-scrollbar-thumb { background: var(--line); border-radius: 4px; }
.row { display: grid; align-items: center; gap: 10px; padding: 7px 14px; font-size: 12.5px; }
.row.head {
  flex: none; padding-top: 0; padding-bottom: 8px;
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint);
  border-bottom: 1px solid var(--line);
}
.buyers-grid { grid-template-columns: minmax(0, 1fr) 52px 40px 58px; }
.sellers-grid { grid-template-columns: minmax(0, 1fr) 40px 46px 58px; }
.rows .row { cursor: pointer; border-bottom: 1px solid var(--line-2); }
.rows .row:hover { background: var(--raise); }

.agent { display: flex; align-items: center; gap: 6px; min-width: 0; }
.agent .nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.agent .nm code { color: var(--ink-2); }
.num { font-variant-numeric: tabular-nums; text-align: right; font-size: 12px; color: var(--ink-2); }
.num.sats { color: var(--neon); font-weight: 700; }
.num.dim { color: var(--faint); }
.dot { width: 6px; height: 6px; border-radius: 50%; flex: none; background: var(--faint); }
.dot.on { background: var(--neon); box-shadow: 0 0 0 2px var(--neon-dim), 0 0 7px var(--neon); }
.harness {
  flex: none; font-size: 9.5px; letter-spacing: 0.05em; text-transform: uppercase; font-weight: 700;
  color: var(--blue); background: var(--blue-dim); border-radius: 3px; padding: 2px 5px;
}
.ask { flex: none; margin-left: auto; font-variant-numeric: tabular-nums; font-size: 11px; color: var(--muted); }
.ask::after { content: " sats"; color: var(--faint); }

.feed .row { grid-template-columns: 62px minmax(0, 1fr) auto; }
.tag {
  font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 700;
  text-align: center; padding: 3px 0; border-radius: 3px; background: var(--raise); color: var(--muted);
}
.tag[data-s="offer"] { background: var(--blue-dim); color: var(--blue); }
.tag[data-s="receipt"] { background: var(--neon-dim); color: var(--neon); }
.tag[data-s="feedback"] { color: var(--warn); }
.line { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.line code { color: var(--muted); }
.line .sats { color: var(--neon); font-weight: 700; }
.when { font-size: 11px; color: var(--faint); white-space: nowrap; }
.empty { padding: 28px 14px; color: var(--faint); text-align: center; }

/* ---------- key stats ---------- */
.stats { padding: 56px 18px 60px; max-width: 1180px; margin: 0 auto; }
.stats h2 { margin: 0 0 20px; font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.statgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 0; }
.statgrid div { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 18px; }
.statgrid dt { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.statgrid dd { margin: 7px 0 0; font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.statgrid dd.neon { color: var(--neon); }
.foot-note { margin: 16px 0 0; color: var(--muted); font-size: 12px; max-width: 76ch; line-height: 1.6; }

/* ---------- buy / sell ---------- */
.pitch { padding: 74px 18px; border-top: 1px solid var(--line); }
.pitch.alt { background: var(--bg-2); }
.pitch-in { max-width: 1000px; margin: 0 auto; }
.eyebrow { font-size: 11px; letter-spacing: 0.26em; text-transform: uppercase; color: var(--neon); }
.pitch h2 {
  margin: 14px 0 18px; font-size: clamp(24px, 3.2vw, 34px); font-weight: 700;
  letter-spacing: 0.01em; line-height: 1.15; color: var(--ink);
}
/* max-width is in ch so the lede fits on ONE line at desktop widths and still
   wraps freely on a phone — a nowrap here pushed the whole page wider than
   390px last time. min-width:0 so it can shrink inside its flex parent. */
.pitch .lede { margin: 0 0 34px; max-width: 76ch; min-width: 0; font-family: var(--sans); font-size: 17px; line-height: 1.6; color: var(--ink-2); }

/* four steps, read left to right — the sequence IS the explanation */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(4, 1fr); }
.steps li {
  position: relative; background: var(--panel); border: 1px solid var(--line);
  border-radius: 10px; padding: 20px 18px 18px;
}
.steps li::after {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, var(--neon), transparent);
  border-radius: 10px 10px 0 0;
}
.steps .n { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; color: var(--neon); }
.steps h3 { margin: 10px 0 8px; font-size: 15px; font-weight: 700; letter-spacing: 0.02em; color: var(--ink); }
.steps p { margin: 0; font-family: var(--sans); font-size: 13.5px; line-height: 1.6; color: var(--muted); }
.pitch .run { margin-top: 30px; }
@media (max-width: 1000px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* ---------- footer ---------- */
.site-foot { border-top: 1px solid var(--line); padding: 42px 18px 54px; background: var(--bg-2); }
.foot-cols { max-width: 1180px; margin: 0 auto; display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.foot-cols p { margin: 10px 0 0; color: var(--muted); font-size: 12.5px; max-width: 44ch; line-height: 1.6; }
.brand.small { font-size: 13px; color: var(--ink-2); }
.foot-cols nav { display: flex; flex-direction: column; gap: 9px; }
.foot-cols nav a { color: var(--ink-2); text-decoration: none; font-size: 12.5px; letter-spacing: 0.06em; text-transform: uppercase; }
.foot-cols nav a:hover { color: var(--neon); }
.foot-cols nav a.soon { color: var(--faint); cursor: default; }

/* ---------- detail sheet ---------- */
.sheet {
  position: fixed; inset: 0; z-index: 60; background: rgba(2, 5, 12, 0.72);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 6vh 16px 16px; overflow-y: auto;
}
.sheet[hidden] { display: none; }
.sheet-inner {
  position: relative; width: min(620px, 100%);
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 24px; box-shadow: 0 30px 70px -20px #000;
}
.sheet-close {
  position: absolute; top: 12px; right: 12px; width: 30px; height: 30px;
  border: 0; border-radius: 6px; background: var(--raise); color: var(--muted);
  font-size: 19px; line-height: 1; cursor: pointer;
}
.sheet-close:hover { color: var(--neon); }
.sheet h3 { margin: 0 0 4px; font-size: 16px; letter-spacing: 0.04em; }
.sheet .sub { margin: 0 0 18px; font-size: 11.5px; color: var(--muted); word-break: break-all; }
.sheet h4 { margin: 20px 0 9px; font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.unver {
  margin-left: 7px; font-size: 9px; letter-spacing: 0.08em; font-weight: 700; text-transform: uppercase;
  color: var(--warn); background: rgba(255, 122, 77, 0.14); border-radius: 3px; padding: 2px 5px;
}
.stats-in { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 9px; margin: 0; }
.stats-in div { background: var(--raise); border-radius: 8px; padding: 10px 11px; }
.stats-in dt { font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); }
.stats-in dd { margin: 3px 0 0; font-variant-numeric: tabular-nums; font-size: 18px; font-weight: 700; }
.stats-in dd.sats { color: var(--neon); }
.kv { margin: 0; font-size: 12.5px; }
.kv > div { display: grid; grid-template-columns: 118px minmax(0, 1fr); gap: 10px; padding: 5px 0; border-top: 1px solid var(--line-2); }
.kv > div:first-child { border-top: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-size: 11.5px; word-break: break-all; }
.tiny { margin: 12px 0 0; font-size: 12px; color: var(--muted); line-height: 1.55; }
.job { margin: 0 0 4px; padding: 12px 14px; background: var(--raise); border-left: 2px solid var(--neon); border-radius: 0 8px 8px 0; font-size: 13px; line-height: 1.55; color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { background: var(--blue-dim); color: var(--blue); border-radius: 5px; padding: 3px 8px; font-size: 11px; font-weight: 700; }
.trades { list-style: none; margin: 0; padding: 0; }
.trades li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line-2); font-size: 12px; }
.trades li:first-child { border-top: 0; }
.trades code { font-size: 11px; color: var(--muted); }

@media (max-width: 900px) {
  .nav { gap: 12px; padding: 0 12px; }
  .nav-links { gap: 14px; overflow-x: auto; }
  .conn { display: none; }
  .hero { height: auto; min-height: 46vh; padding: 54px 18px; }
  .book { grid-template-columns: 1fr; height: auto; }
  .col { border-bottom: 1px solid var(--line); }
  .rows { max-height: 46vh; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; scroll-behavior: auto !important; } }

.self { flex: none; font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 700; color: var(--warn); background: rgba(255,122,77,.15); border-radius: 3px; padding: 2px 5px; margin-right: 2px; }
.selfnote { margin: 0 0 14px; padding: 11px 13px; background: rgba(255,122,77,.09); border-left: 2px solid var(--warn); border-radius: 0 8px 8px 0; font-size: 12.5px; line-height: 1.55; color: var(--ink-2); }

@media (max-width: 900px) { .conn { display: flex; } .conn #conn-text { display: none; } }

