:root {
  --bg: #101114;
  --surface: #16181d;
  --surface-2: #1d2027;
  --surface-hover: #22262f;
  --border: #272b34;
  --border-strong: #3b4150;
  --text: #f3f4f6;
  --muted: #9ca3af;
  --dim: #6b7280;
  --green: #22c55e;
  --green-soft: rgba(34, 197, 94, 0.14);
  --red: #ef4444;
  --red-soft: rgba(239, 68, 68, 0.14);
  --accent: #e5e7eb;
  --blue: #60a5fa;
  --amber: #eab308;
  --radius: 8px;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 22px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* Flat, clean top bar */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: -0.02em;
}
.brand img { width: 26px; height: 26px; border-radius: 6px; }
.brand-sub { font-size: 0.78rem; color: var(--dim); font-weight: 500; }

.nav-right { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.nav-right a { color: var(--muted); text-decoration: none; font-size: 0.88rem; }
.nav-right a:hover { color: var(--text); }

.lang-btn {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}
.lang-btn:hover { border-color: var(--border-strong); }

/* Direct, left-aligned hero + real screenshot */
.hero {
  padding: 46px 0 36px;
  border-bottom: 1px solid var(--border);
}

.hero-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 28px;
}

.hero-copy { flex: 1 1 460px; max-width: 575px; }

.meta-strip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 14px;
}
.ver-tag {
  background: var(--green-soft);
  color: #4ade80;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 700;
}

h1 {
  font-size: clamp(1.9rem, 3.8vw, 2.75rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  font-weight: 750;
  color: var(--text);
  margin-bottom: 14px;
}

.lead {
  color: var(--muted);
  font-size: 1rem;
  max-width: 58ch;
  margin-bottom: 22px;
}

.cta-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 16px;
  border-radius: 7px;
  font-size: 0.89rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .12s, border-color .12s;
}
.btn-primary { background: #22c55e; color: #052e16; }
.btn-primary:hover { background: #4ade80; }
.btn-secondary { background: var(--surface-2); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { background: var(--surface-hover); border-color: var(--border-strong); }
.btn-secondary.active { background: var(--green-soft); border-color: var(--green); color: #4ade80; }
.btn-sm { padding: 6px 11px; font-size: 0.79rem; border-radius: 6px; }

.hero-stats {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  flex-shrink: 0;
}
.stat-item { display: flex; flex-direction: column; }
.stat-label { font-size: 0.7rem; color: var(--dim); text-transform: uppercase; letter-spacing: 0.05em; }
.stat-val { font-size: 0.98rem; font-weight: 700; margin-top: 2px; }

/* Real Screenshot Showcase — flat crisp window border, zero glow */
.shot-frame {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: #0b0c0f;
}
.shot-frame img { display: block; width: 100%; height: auto; }

.spec-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 16px;
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}

/* Sections */
section { padding: 40px 0; border-bottom: 1px solid var(--border); }
.sec-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 18px; }
h2 { font-size: 1.35rem; letter-spacing: -0.02em; font-weight: 700; }
.sec-sub { color: var(--muted); font-size: 0.9rem; margin-top: 3px; }

/* Scanner Table */
.scanner-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.scanner-controls {
  padding: 12px 14px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}
.search-input {
  flex: 1 1 240px;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 11px;
  font-size: 0.87rem;
  outline: none;
}
.search-input:focus { border-color: var(--border-strong); }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  background: var(--bg);
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}
.chip.active, .chip:hover { color: var(--text); border-color: var(--border-strong); background: var(--surface-hover); }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
th {
  text-align: left;
  padding: 10px 14px;
  font-size: 0.72rem;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--dim);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
td {
  padding: 11px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  vertical-align: middle;
}
td.mono, .spread-badge { white-space: nowrap; }
tbody tr { cursor: pointer; }
tbody tr:hover { background: var(--surface-hover); }
tbody tr.selected { background: rgba(96, 165, 250, 0.1); }
.q-cell { max-width: 390px; }
.q-title { font-weight: 600; color: var(--text); display: block; line-height: 1.35; }
.q-meta { font-size: 0.74rem; color: var(--dim); margin-top: 2px; }

.odds-bar { display: flex; align-items: center; gap: 8px; min-width: 118px; }
.odds-track { flex: 1; height: 6px; border-radius: 3px; background: var(--red-soft); overflow: hidden; }
.odds-fill { height: 100%; background: var(--green); }
.yes-val { color: #4ade80; font-weight: 700; min-width: 44px; text-align: right; }

.spread-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 0.76rem;
  font-weight: 600;
}
.spread-tight { background: var(--green-soft); color: #4ade80; }
.spread-mid { background: rgba(148, 163, 184, 0.14); color: #cbd5e1; }
.spread-wide { background: rgba(234, 179, 8, 0.16); color: #facc15; }

/* Orderbook Panel */
.book-panel {
  border-top: 1px solid var(--border-strong);
  background: #0d0e12;
  padding: 18px;
}
.book-panel.hidden { display: none; }
.book-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.book-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 720px) { .book-grid { grid-template-columns: 1fr; } }
.book-side { background: var(--surface); border: 1px solid var(--border); border-radius: 7px; padding: 12px; }
.book-side h4 { font-size: 0.74rem; font-family: var(--mono); text-transform: uppercase; margin-bottom: 8px; }
.book-side.bids h4 { color: #4ade80; }
.book-side.asks h4 { color: #f87171; }
.imb-track { height: 6px; border-radius: 3px; background: var(--red-soft); overflow: hidden; margin: 8px 0 4px; }
.imb-fill { height: 100%; background: var(--green); }

.mini-ladder { display: flex; flex-direction: column; gap: 4px; font-size: 0.78rem; }
.ladder-row {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  padding: 5px 8px;
  border-radius: 4px;
  overflow: hidden;
}
.ladder-row .bar { position: absolute; top: 0; bottom: 0; right: 0; opacity: 0.2; pointer-events: none; }
.ladder-ask .bar { background: var(--red); }
.ladder-bid .bar { background: var(--green); }
.ladder-ask .px { color: #f87171; font-weight: 700; }
.ladder-bid .px { color: #4ade80; font-weight: 700; }

/* Downloads */
.dl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(238px, 1fr)); gap: 12px; }
.dl-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.dl-card.recommended { border-color: #22c55e; }
.dl-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dl-title { font-weight: 700; font-size: 0.98rem; }
.dl-tag { font-size: 0.71rem; font-family: var(--mono); padding: 2px 7px; border-radius: 4px; background: var(--surface-2); color: var(--muted); }
.dl-card.recommended .dl-tag { background: var(--green-soft); color: #4ade80; }
.dl-desc { font-size: 0.83rem; color: var(--muted); flex: 1; }
.dl-hash {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 6px 8px;
  font-size: 0.71rem;
  color: var(--dim);
  word-break: break-all;
}

/* Notes */
.notes-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}
.note-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}
.note-box h3 { font-size: 0.95rem; margin-bottom: 6px; font-weight: 700; }
.note-box p { font-size: 0.86rem; color: var(--muted); }

.notice {
  margin-top: 16px;
  padding: 12px 15px;
  border-radius: 7px;
  background: rgba(234, 179, 8, 0.08);
  border: 1px solid rgba(234, 179, 8, 0.25);
  font-size: 0.81rem;
  color: #fde047;
}

footer {
  padding: 26px 0 42px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.83rem;
  color: var(--dim);
}
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--text); }
.status-line { padding: 24px; text-align: center; color: var(--muted); font-size: 0.88rem; }
