*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  background: none;
  border: none;
}

button {
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* Tabular Monospace Hygiene for All Numeric Data */
.mono,
.num,
.price,
.qty,
.pp-val,
.btc-val {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

/* Semantic Text Colors */
.text-buy { color: var(--color-buy-bright); }
.text-sell { color: var(--color-sell-bright); }
.text-btc { color: var(--color-btc-bright); }
.text-pp { color: var(--color-pp); }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-right { text-align: right; }
.text-center { text-align: center; }

/* Custom Minimal Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-canvas);
}
::-webkit-scrollbar-thumb {
  background: #26334d;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #3b4d71;
}

/* Skeleton Loader */
.skeleton-loader {
  padding: 48px 20px;
  text-align: center;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}

[hidden] {
  display: none !important;
}

