  :root {
    --bg: #04070e;
    --surface: #070c15;
    --surface2: #0c1220;
    --surface3: #111a2c;
    --border: #162032;
    --border2: #1e2e42;
    --long: #ff3d55;
    --long-dim: rgba(255,61,85,0.09);
    --long-glow: rgba(255,61,85,0.45);
    --short: #00e5b4;
    --short-dim: rgba(0,229,180,0.07);
    --short-glow: rgba(0,229,180,0.38);
    --text: #dce8f5;
    --text2: #7a96b0;
    --muted: #2e4458;
    --accent: #4d8ef7;
    --accent-dim: rgba(77,142,247,0.1);
    --gold: #ffb800;
    --gold-dim: rgba(255,184,0,0.1);
    --gold-glow: rgba(255,184,0,0.45);
    --header-h: 52px;
    --stats-h: 72px;
  }

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

  body {
    background: var(--bg);
    color: var(--text);
    font-family: 'DM Sans', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
  }

  /* Subtle dot grid background */
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: radial-gradient(circle, rgba(77,142,247,0.08) 1px, transparent 1px);
    background-size: 32px 32px;
    pointer-events: none;
    z-index: 0;
  }

  /* Top ambient glow */
  body::after {
    content: '';
    position: fixed;
    top: -200px; left: 50%;
    transform: translateX(-50%);
    width: 900px; height: 400px;
    background: radial-gradient(ellipse, rgba(77,142,247,0.06) 0%, transparent 65%);
    pointer-events: none;
    z-index: 0;
  }

  /* ── HEADER ── */
  header {
    position: relative;
    z-index: 10;
    padding: 0 20px;
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    background: rgba(7,12,21,0.97);
    backdrop-filter: blur(12px);
  }

  .logo {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  /* Logo icon mark */
  .logo-icon {
    width: 26px; height: 26px;
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(255,61,85,0.2), rgba(77,142,247,0.2));
    border: 1px solid rgba(255,61,85,0.3);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
  }
  .logo-icon svg { width: 13px; height: 13px; }

  .logo-text {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    background: linear-gradient(135deg, #e2e8f0 0%, #7ab8d4 60%, #4d8ef7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  .logo-text em {
    font-style: normal;
    font-weight: 300;
    margin: 0 4px;
    opacity: 0.4;
    font-size: 0.75rem;
  }

  .logo-sep {
    width: 1px;
    height: 14px;
    background: var(--border2);
    flex-shrink: 0;
  }

  .logo-badge {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: #F3BA2F;
    letter-spacing: 0.14em;
    background: rgba(77,142,247,0.08);
    border: 1px solid rgba(77,142,247,0.2);
    padding: 2px 7px;
    border-radius: 20px;
  }

  .live-pill {
    display: flex;
    align-items: center;
    gap: 5px;
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: var(--text);
    letter-spacing: 0.1em;
    background: var(--surface2);
    border: 1px solid var(--border);
    padding: 3px 9px;
    border-radius: 20px;
  }

  .live-indicator {
    width: 5px; height: 5px;
    background: var(--long);
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
    animation: livePulse 2s ease-in-out infinite;
  }

  .live-indicator::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1px solid var(--long);
    opacity: 0;
    animation: liveRing 2s ease-in-out infinite;
  }

  @keyframes livePulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--long-glow); }
    50% { opacity: 0.25; box-shadow: none; }
  }

  @keyframes liveRing {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(3.2); opacity: 0; }
  }

  .dot { display: none; }
  .status-dot { display: none; }

  .status-bar {
    display: flex;
    align-items: center;
    gap: 6px;
  }

  .header-btn {
    font-family: 'Space Mono', monospace;
    font-size: 0.5rem;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text2);
    padding: 5px 11px;
    border-radius: 4px;
    cursor: pointer;
    letter-spacing: 0.1em;
    transition: all 0.15s;
    white-space: nowrap;
  }

  .header-btn:hover { border-color: rgba(77,142,247,0.4); color: var(--text); background: var(--surface3); }
  .header-btn.lang { border-color: rgba(77,142,247,0.35); color: var(--accent); background: rgba(77,142,247,0.07); }
  .header-btn.sound { color: var(--short); border-color: rgba(0,229,180,0.3); background: rgba(0,229,180,0.05); }

  .min-filter {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: 'Space Mono', monospace;
    font-size: 0.5rem;
    color: var(--muted);
  }

  .min-filter label { color: var(--text2); letter-spacing: 0.08em; white-space: nowrap; }

  .filter-select {
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text);
    font-family: 'Space Mono', monospace;
    font-size: 0.54rem;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    outline: none;
    transition: border-color 0.15s;
  }
  .filter-select:focus { border-color: var(--accent); }
  .filter-select option { background: #0c1220; color: #dce8f5; }

  /* ── STATS ── */
  .stats-row {
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: var(--border);
    gap: 1px;
    border-bottom: 1px solid var(--border);
  }

  .stat-card {
    background: var(--surface);
    padding: 12px 20px 11px;
    display: flex;
    flex-direction: column;
    gap: 1px;
    position: relative;
    overflow: hidden;
    transition: background 0.2s;
  }

  /* Colored left accent */
  .stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; bottom: 0;
    width: 2px;
    opacity: 0.5;
    transition: opacity 0.25s, width 0.25s;
  }

  .stat-card:nth-child(1)::before { background: var(--text2); }
  .stat-card:nth-child(2)::before { background: var(--long); }
  .stat-card:nth-child(3)::before { background: var(--short); }
  .stat-card:nth-child(4)::before { background: var(--gold); }

  .stat-card:hover { background: var(--surface2); }
  .stat-card:hover::before { opacity: 1; width: 3px; }

  .stat-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.5rem;
    color: var(--muted);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 3px;
  }

  .stat-value {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.65rem;
    letter-spacing: 0.03em;
    line-height: 1;
  }

  .stat-value.long-color { color: var(--long); }
  .stat-value.short-color { color: var(--short); }
  .stat-value.neutral { color: var(--text); }

  .stat-sub {
    font-family: 'Space Mono', monospace;
    font-size: 0.52rem;
    color: var(--muted);
    margin-top: 2px;
    letter-spacing: 0.04em;
  }

  /* ── MAIN LAYOUT ── */
  .main {
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 1fr 280px;
    height: calc(100vh - var(--header-h) - var(--stats-h));
  }

  /* ── FEED ── */
  .feed-container {
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  .feed-header { display: none; }
  .feed-header-center { display: none; }
  .feed-title { display: none; }
  .feed-count { display: none; }

  .feed {
    flex: 1;
    overflow-y: auto;
    padding: 4px 0;
  }

  .feed::-webkit-scrollbar { width: 2px; }
  .feed::-webkit-scrollbar-track { background: transparent; }
  .feed::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }

  /* ── LIQ CARD ── */
  .liq-card {
    display: grid;
    grid-template-columns: 3px 62px 1fr auto auto;
    align-items: center;
    gap: 14px;
    padding: 9px 16px 9px 0;
    margin: 0;
    border-bottom: 1px solid var(--border);
    animation: slideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transition: background 0.1s;
    cursor: default;
    position: relative;
  }

  .liq-card:last-child { border-bottom: none; }

  .liq-card::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.15s;
    pointer-events: none;
  }

  .liq-card.is-long::before  { background: linear-gradient(90deg, rgba(255,61,85,0.05) 0%, transparent 35%); }
  .liq-card.is-short::before { background: linear-gradient(90deg, rgba(0,229,180,0.04) 0%, transparent 35%); }
  .liq-card:hover::before { opacity: 1; }
  .liq-card:hover { background: var(--surface2); }

  @keyframes slideIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .liq-card.mega {
    background: linear-gradient(90deg, rgba(255,184,0,0.04) 0%, transparent 50%);
    border-bottom: 1px solid rgba(255,184,0,0.1);
  }

  .card-bar {
    width: 3px;
    align-self: stretch;
    border-radius: 0;
    flex-shrink: 0;
  }

  .card-bar.long-bar  { background: var(--long); box-shadow: 2px 0 8px var(--long-glow); }
  .card-bar.short-bar { background: var(--short); box-shadow: 2px 0 8px var(--short-glow); }

  .card-symbol {
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: right;
    min-width: 62px;
    color: var(--text);
  }

  .card-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }

  .card-direction {
    display: flex;
    align-items: center;
    gap: 6px;
  }

  .dir-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 700;
    letter-spacing: 0.1em;
  }

  .dir-tag.long-tag {
    background: var(--long-dim);
    color: var(--long);
    border: 1px solid rgba(255,61,85,0.2);
  }

  .dir-tag.short-tag {
    background: var(--short-dim);
    color: var(--short);
    border: 1px solid rgba(0,229,180,0.2);
  }

  .card-price {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    color: var(--text2);
    letter-spacing: 0.02em;
  }

  .card-amount {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.3rem;
    letter-spacing: 0.04em;
    text-align: right;
    min-width: 108px;
    line-height: 1;
  }

  .card-amount.long-amt  { color: var(--long); }
  .card-amount.short-amt { color: var(--short); }
  .card-amount.mega-amt  { color: var(--gold); }

  .card-time {
    font-family: 'Space Mono', monospace;
    font-size: 0.5rem;
    color: var(--muted);
    text-align: right;
    min-width: 48px;
    padding-right: 14px;
    letter-spacing: 0.02em;
  }

  .mega-badge {
    font-family: 'Space Mono', monospace;
    font-size: 0.44rem;
    background: rgba(255,184,0,0.1);
    color: var(--gold);
    border: 1px solid rgba(255,184,0,0.3);
    padding: 1px 5px;
    border-radius: 3px;
    letter-spacing: 0.12em;
    animation: megaPulse 1.2s ease-in-out infinite;
  }

  @keyframes megaPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
  }

  /* ── SIDEBAR ── */
  .sidebar {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--surface);
  }

  .sidebar-section {
    border-bottom: 1px solid var(--border);
    padding: 14px 16px;
  }

  .sidebar-title {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    letter-spacing: 0.22em;
    color: var(--text2);
    text-transform: uppercase;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 7px;
  }

  .sidebar-title::before {
    content: '';
    display: inline-block;
    width: 2px; height: 8px;
    border-radius: 1px;
    background: var(--accent);
    flex-shrink: 0;
  }

  /* ── DOMINANCE BAR ── */
  .dom-bar-wrap {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .dom-bar-labels {
    display: flex;
    justify-content: space-between;
    font-family: 'Space Mono', monospace;
    font-size: 0.52rem;
    color: var(--muted);
    letter-spacing: 0.06em;
  }

  .dom-bar-labels span:first-child { color: rgba(255,61,85,0.7); }
  .dom-bar-labels span:last-child  { color: rgba(0,229,180,0.7); text-align: right; }

  .dom-bar-track {
    height: 6px;
    background: rgba(0,229,180,0.1);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
  }

  .dom-bar-fill {
    height: 100%;
    background: var(--long);
    border-radius: 3px;
    transition: width 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .dom-pct {
    display: flex;
    justify-content: space-between;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.5rem;
    letter-spacing: 0.04em;
    line-height: 1;
  }

  .dom-pct span:first-child { color: var(--long); }
  .dom-pct span:last-child  { color: var(--short); }

  /* ── TOP COINS ── */
  .top-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 200px;
    overflow-y: auto;
  }

  .top-list::-webkit-scrollbar { width: 2px; }
  .top-list::-webkit-scrollbar-thumb { background: var(--border2); }

  .top-item {
    display: grid;
    grid-template-columns: 18px 1fr auto;
    align-items: center;
    gap: 8px;
  }

  .top-rank {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: var(--muted);
    text-align: right;
  }

  .top-symbol {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    color: var(--text);
    font-weight: 700;
    letter-spacing: 0.04em;
  }

  .top-amt {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    color: var(--text2);
    text-align: right;
  }

  .top-bar-row {
    grid-column: 2 / -1;
    height: 2px;
    background: var(--border);
    border-radius: 1px;
    margin-top: -2px;
  }

  .top-bar-fill {
    height: 100%;
    background: rgba(77,142,247,0.5);
    border-radius: 1px;
    transition: width 0.5s ease;
  }

  /* ── MEGA FEED ── */
  .mega-feed {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 5px;
  }

  .mega-feed::-webkit-scrollbar { width: 2px; }
  .mega-feed::-webkit-scrollbar-thumb { background: var(--border2); }

  .mega-item {
    background: var(--surface2);
    border: 1px solid rgba(255,184,0,0.15);
    border-left: 2px solid var(--gold);
    border-radius: 0 6px 6px 0;
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    animation: fadeInScale 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transition: border-color 0.2s, background 0.15s;
  }

  .mega-item:hover { border-color: rgba(255,184,0,0.35); background: var(--surface3); }

  @keyframes fadeInScale {
    from { opacity: 0; transform: translateX(-6px); }
    to   { opacity: 1; transform: translateX(0); }
  }

  .mega-item-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
  }

  .mega-sym {
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--gold);
  }

  .mega-usd {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.1rem;
    color: var(--gold);
    letter-spacing: 0.04em;
    line-height: 1;
  }

  .mega-item-bot {
    display: flex;
    justify-content: space-between;
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: var(--muted);
    letter-spacing: 0.04em;
  }

  /* ── EMPTY STATE ── */
  .empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 280px;
    gap: 14px;
    color: var(--muted);
  }

  .empty-icon {
    font-size: 2rem;
    opacity: 0.12;
    animation: emptyPulse 2.5s ease-in-out infinite;
  }

  @keyframes emptyPulse {
    0%, 100% { opacity: 0.12; transform: scale(1); }
    50% { opacity: 0.25; transform: scale(1.06); }
  }

  .empty-text {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.14em;
    text-align: center;
    line-height: 2.2;
    color: var(--muted);
  }

  .empty-dots {
    display: flex;
    gap: 6px;
  }

  .empty-dot {
    width: 4px; height: 4px;
    border-radius: 50%;
    background: var(--border2);
    animation: dotBounce 1.4s ease-in-out infinite;
  }

  .empty-dot:nth-child(2) { animation-delay: 0.2s; }
  .empty-dot:nth-child(3) { animation-delay: 0.4s; }

  @keyframes dotBounce {
    0%, 80%, 100% { transform: scale(1); opacity: 0.35; }
    40% { transform: scale(1.5); opacity: 1; background: var(--accent); }
  }

  /* ── CONNECTING OVERLAY ── */
  .connecting {
    position: fixed;
    inset: 0;
    background: rgba(4,7,14,0.94);
    backdrop-filter: blur(12px);
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    transition: opacity 0.6s;
  }

  .connecting.hidden { opacity: 0; pointer-events: none; }

  .connect-logo {
    font-family: 'Space Mono', monospace;
    font-size: 1rem;
    letter-spacing: 0.3em;
    color: var(--text2);
    font-weight: 700;
  }

  .connect-text {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    color: var(--muted);
    letter-spacing: 0.18em;
    animation: blink 1.4s infinite;
  }

  @keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.15; }
  }

  .spinner {
    width: 24px; height: 24px;
    border: 1.5px solid var(--border2);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
  }

  @keyframes spin { to { transform: rotate(360deg); } }

  /* ── FLASH OVERLAY ── */
  .flash-overlay {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 50;
    opacity: 0;
    transition: opacity 0.08s;
  }

  .flash-overlay.long-flash  { background: radial-gradient(ellipse at center, rgba(255,61,85,0.08) 0%, transparent 60%); }
  .flash-overlay.short-flash { background: radial-gradient(ellipse at center, rgba(0,229,180,0.07) 0%, transparent 60%); }
  .flash-overlay.active { opacity: 1; }

  /* ── MEGA ALERT OVERLAY ── */
  .mega-alert {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 90;
    padding: 11px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(7,12,21,0.96);
    border-bottom: 1px solid rgba(255,184,0,0.35);
    backdrop-filter: blur(16px);
    transform: translateY(-100%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .mega-alert.visible { transform: translateY(0); }

  .mega-alert-left {
    display: flex;
    align-items: center;
    gap: 12px;
  }

  .mega-alert-icon {
    font-size: 1.1rem;
    animation: alertShake 0.5s ease-in-out;
  }

  @keyframes alertShake {
    0%, 100% { transform: rotate(0); }
    25% { transform: rotate(-12deg); }
    75% { transform: rotate(12deg); }
  }

  .mega-alert-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: var(--gold);
    letter-spacing: 0.22em;
    text-transform: uppercase;
  }

  .mega-alert-sym {
    font-family: 'Space Mono', monospace;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.04em;
  }

  .mega-alert-amt {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.6rem;
    color: var(--gold);
    letter-spacing: 0.04em;
    line-height: 1;
  }

  /* ── COIN FILTER PANEL ── */
  .coin-filter-panel {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 8px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .coin-filter-top {
    display: flex;
    align-items: center;
    gap: 6px;
  }

  .coin-filter-label { display: none; }
  .coin-filter-label-row { display: none; }

  .filter-divider {
    width: 1px;
    height: 16px;
    background: var(--border2);
    flex-shrink: 0;
    margin: 0 2px;
  }

  .coin-search-wrap {
    position: relative;
    flex: 1;
    min-width: 0;
  }

  .coin-search-input {
    width: 100%;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text);
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    padding: 5px 10px;
    border-radius: 4px;
    outline: none;
    transition: border-color 0.15s;
    letter-spacing: 0.05em;
    text-transform: uppercase;
  }

  .coin-search-input::placeholder {
    color: var(--muted);
    text-transform: none;
    letter-spacing: 0;
    font-size: 0.56rem;
  }

  .coin-search-input:focus { border-color: var(--accent); background: var(--surface3); }

  .coin-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0; right: 0;
    background: var(--surface3);
    border: 1px solid var(--border2);
    border-top: 1px solid rgba(77,142,247,0.5);
    border-radius: 0 0 6px 6px;
    max-height: 220px;
    overflow-y: auto;
    z-index: 999;
    display: none;
    box-shadow: 0 12px 32px rgba(0,0,0,0.6);
  }

  .coin-dropdown.open { display: block; }
  .coin-dropdown::-webkit-scrollbar { width: 2px; }
  .coin-dropdown::-webkit-scrollbar-thumb { background: var(--border2); }

  .dropdown-item {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    padding: 7px 12px;
    cursor: pointer;
    color: var(--text2);
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.1s;
    border-bottom: 1px solid var(--border);
  }

  .dropdown-item:last-child { border-bottom: none; }
  .dropdown-item:hover { background: rgba(77,142,247,0.08); color: var(--text); }
  .dropdown-item .coin-vol { font-size: 0.5rem; color: var(--muted); }

  .btn-add-coin { display: none; }

  .btn-clear-coins {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--muted);
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    letter-spacing: 0.08em;
    white-space: nowrap;
    transition: all 0.15s;
    flex-shrink: 0;
  }

  .btn-clear-coins:hover { border-color: rgba(255,61,85,0.4); color: var(--long); background: rgba(255,61,85,0.05); }

  .btn-all-coins {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--muted);
    padding: 4px 9px;
    border-radius: 4px;
    cursor: pointer;
    letter-spacing: 0.08em;
    white-space: nowrap;
    transition: all 0.15s;
    flex-shrink: 0;
  }

  .btn-all-coins.active {
    border-color: rgba(0,229,180,0.4);
    color: var(--short);
    background: rgba(0,229,180,0.06);
  }

  .selected-coins-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-items: center;
    min-height: 0;
  }

  .selected-coins-row:empty { display: none; }

  .selected-coins-empty {
    font-family: 'Space Mono', monospace;
    font-size: 0.48rem;
    color: var(--muted);
    letter-spacing: 0.06em;
  }

  .coin-chip {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--surface3);
    border: 1px solid var(--border2);
    border-radius: 4px;
    padding: 2px 6px 2px 8px;
    font-family: 'Space Mono', monospace;
    font-size: 0.5rem;
    color: var(--text2);
    letter-spacing: 0.06em;
    animation: chipIn 0.15s ease;
  }

  @keyframes chipIn {
    from { opacity: 0; transform: scale(0.85); }
    to   { opacity: 1; transform: scale(1); }
  }

  .chip-remove {
    cursor: pointer;
    color: var(--muted);
    font-size: 0.6rem;
    line-height: 1;
    transition: color 0.1s;
  }

  .chip-remove:hover { color: var(--long); }

  /* ── RESPONSIVE ── */
  @media (max-width: 768px) {
    header { padding: 0 14px; }
    .logo-badge { display: none; }
    .logo-sep { display: none; }
    .stats-row { grid-template-columns: repeat(2, 1fr); }
    .stat-card { padding: 10px 14px; }
    .stat-value { font-size: 1.3rem; }
    .main { grid-template-columns: 1fr; grid-template-rows: 1fr auto; height: auto; min-height: calc(100vh - 110px); }
    .feed-container { border-right: none; border-bottom: 1px solid var(--border); height: 58vh; }
    .coin-filter-panel { padding: 7px 12px; }
    .liq-card { grid-template-columns: 3px 46px 1fr auto; gap: 10px; padding: 8px 12px 8px 0; }
    .card-time { display: none; }
    .card-symbol { font-size: 0.65rem; min-width: 46px; }
    .card-amount { font-size: 1rem; min-width: 80px; }
    .card-price { font-size: 0.54rem; }
    .sidebar { flex-direction: row; overflow-x: auto; overflow-y: hidden; border-top: 1px solid var(--border); height: auto; min-height: 175px; scrollbar-width: none; }
    .sidebar::-webkit-scrollbar { display: none; }
    .sidebar-section { min-width: 190px; flex-shrink: 0; border-bottom: none; border-right: 1px solid var(--border); padding: 12px 14px; overflow: hidden; }
    .sidebar-section:last-child { border-right: none; }
    .sidebar-section[style*="flex:1"] { flex: 0 0 190px !important; }
    .top-list { max-height: 110px; }
    .mega-feed { max-height: 110px; }
    .mega-alert { padding: 10px 16px; }
  }

  @media (max-width: 480px) {
    header { padding: 0 10px; }
    .logo-text { font-size: 0.72rem; }
    .live-pill { display: none; }
    #soundBtn { display: none !important; }
    .stats-row { grid-template-columns: repeat(2, 1fr); }
    .stat-card { padding: 8px 10px; }
    .stat-value { font-size: 1.1rem; }
    .stat-label { font-size: 0.44rem; }
    .feed-container { height: 52vh; }
    .liq-card { grid-template-columns: 3px 38px 1fr auto; gap: 8px; padding: 7px 10px 7px 0; }
    .card-symbol { font-size: 0.6rem; min-width: 38px; }
    .card-amount { font-size: 0.88rem; min-width: 68px; }
    .sidebar { min-height: 150px; }
    .sidebar-section { min-width: 160px; padding: 10px 11px; }
    .sidebar-title { font-size: 0.44rem; margin-bottom: 8px; }
    .dom-pct { font-size: 1.1rem; }
    .connect-logo { font-size: 0.78rem; }
    .coin-filter-top { gap: 4px; }
    .filter-divider { display: none; }
  }
