/* Test UI dashboard layouts (stats / miner / worker / worker-blocks). */
.tx-page { display: grid; gap: 18px; padding-top: 12px; }
.tx-page > .err { margin: 0; }
.tx-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; padding: 8px 2px 4px; }
.tx-hero-side { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tx-kicker { display: flex; align-items: center; gap: 8px; color: var(--cyan); font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: .16em; }
.tx-title { margin: 6px 0 4px; font: 800 clamp(40px, 5vw, 64px)/.95 Manrope, system-ui, sans-serif; letter-spacing: -.055em; color: var(--ink); word-break: break-all; }
.tx-title span { color: var(--cyan); }
.tx-lede { margin: 6px 0 0; color: var(--muted); max-width: 560px; font-size: 14px; line-height: 1.6; }
.tx-addr { display: inline-block; max-width: min(720px, 100%); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255,255,255,.04); color: var(--muted); font: 12px var(--font-mono); }
.tx-addr b, .tx-addr strong { color: var(--cyan); }
.tx-live { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 12px var(--lime); }
.tx-pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255,255,255,.05); color: var(--muted); font: 12px var(--font-mono); }
.tx-pill b { color: var(--ink); }
.tx-pill.hidden { display: none; }
.tx-command { display: flex; align-items: center; gap: 10px; min-width: min(420px, 100%); padding: 6px 6px 6px 14px; border-radius: 16px; border: 1px solid var(--line); background: rgba(27,22,43,.8); box-shadow: 0 0 0 1px rgba(155,108,255,.12), 0 16px 40px rgba(0,0,0,.3); }
.tx-command span { color: var(--violet); }
.tx-command input { flex: 1; min-width: 0; border: 0 !important; outline: 0; background: transparent !important; color: var(--ink); font: 13px var(--font-mono); padding: 8px 0; }
.tx-command button, .tx-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255,255,255,.06); color: var(--ink); font: 700 12px Manrope, system-ui, sans-serif; text-decoration: none; cursor: pointer; white-space: nowrap; }
.tx-command button { border: 0; background: linear-gradient(90deg, var(--violet), var(--cyan)); color: #09070f; }
.tx-btn:hover:not(:disabled) { border-color: var(--cyan); color: var(--cyan); }
.tx-btn:disabled { opacity: .45; cursor: not-allowed; }
.tx-bento { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 14px; }
.tx-bento-tight { grid-template-columns: repeat(4, 1fr); }
.tx-luck-pair { display: grid; grid-template-columns: 1fr; gap: 8px; }
.tx-luck-pair .tx-metric { font-size: clamp(18px, 1.8vw, 26px); white-space: nowrap; }
.tx-bento-7 { grid-template-columns: 1.4fr repeat(5, 1fr); }
.tx-tile, .tx-card {
  position: relative; min-width: 0; border-radius: 22px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(36,29,58,.72), rgba(19,16,32,.82));
  box-shadow: 0 20px 60px rgba(0,0,0,.28), inset 0 1px rgba(255,255,255,.06);
}
.tx-tile { padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.tx-tile-hero { background: radial-gradient(420px 200px at 0% 0%, rgba(155,108,255,.32), transparent 70%), radial-gradient(360px 200px at 100% 100%, rgba(50,230,255,.18), transparent 70%), linear-gradient(180deg, rgba(36,29,58,.8), rgba(19,16,32,.85)); }
.tx-label { display: flex; align-items: center; gap: 7px; color: var(--muted); font: 500 10.5px var(--font-mono); text-transform: uppercase; letter-spacing: .12em; }
.tx-metric { color: var(--ink); font: 800 clamp(20px, 2.1vw, 28px)/1.1 Manrope, system-ui, sans-serif; letter-spacing: -.03em; overflow-wrap: anywhere; }
.tx-tile-hero .tx-metric { font-size: clamp(30px, 3.4vw, 44px); }
.tx-metric small { margin-left: 4px; color: var(--muted); font: 500 12px var(--font-mono); }
.tx-metric a { color: var(--cyan); text-decoration: none; }
.tx-grad { background: linear-gradient(90deg, #c9b0ff, var(--cyan)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tx-sub { color: var(--muted); font-size: 12px; }
.tx-sub b { color: var(--ink); font-family: var(--font-mono); font-weight: 500; }
.tx-segments { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; margin-top: 4px; }
.tx-segments i { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--violet), var(--cyan)); opacity: .85; }
.tx-card { padding: 18px 20px; }
.tx-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; }
.tx-card-head h3 { margin: 4px 0 0; font: 800 20px Manrope, system-ui, sans-serif; letter-spacing: -.03em; color: var(--ink); }
.tx-controls { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tx-muted { color: var(--muted); font-size: 12px; }
.tx-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 12px; border: 1px solid var(--line); background: rgba(9,7,15,.55); }
.tu .tx-seg .chip { border: 0; border-radius: 9px; padding: 5px 10px; background: transparent; color: var(--muted); font: 600 11px var(--font-mono); }
.tu .tx-seg .chip.active { background: linear-gradient(90deg, rgba(155,108,255,.45), rgba(50,230,255,.35)); color: var(--ink); }
.tu .tx-card .chip-toggle { border-radius: 12px; }
.tx-chart-card .chart-stage { border-radius: 16px; border: 1px solid var(--line); background: radial-gradient(600px 220px at 50% 0%, rgba(155,108,255,.12), transparent 70%), rgba(9,7,15,.55); padding: 8px 6px 0; }
.tx-chart-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
/* Chart strokes: violet → cyan instead of production teal/gold. */
.tu .chart .line { stroke: var(--cyan) !important; filter: drop-shadow(0 0 8px rgba(50,230,255,.55)) !important; }
.tu .chart .grid { stroke: rgba(208,193,255,.1) !important; }
.tu .chart-hover-line { stroke: rgba(208,193,255,.45) !important; }
.tu .chart-hover-dot { fill: var(--cyan) !important; stroke: #09070f !important; }
.tu .chart-snake-path { stroke: var(--violet) !important; }
.tu .block-mark, .tu .block-mark-icon { color: var(--lime) !important; }
.tu .chart-tooltip { background: rgba(19,16,32,.96) !important; border-color: var(--line) !important; border-radius: 12px !important; }
.tu .chart-xaxis-tick { color: var(--dim) !important; }
.tx-flowbar { display: flex; height: 18px; gap: 3px; border-radius: 999px; overflow: hidden; background: rgba(255,255,255,.05); }
.tx-flowbar i { min-width: 4px; box-shadow: 0 0 18px rgba(155,108,255,.35); }
.tx-flowlegend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; font-size: 12px; color: var(--muted); }
.tx-flowlegend a, .tx-flowlegend > span { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); text-decoration: none; }
.tx-flowlegend a:hover code { color: var(--cyan); }
.tx-flowlegend b { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.tx-flowlegend code { color: var(--ink); font: 12px var(--font-mono); }
.tx-flowlegend span span { color: var(--ink); font-family: var(--font-mono); }
.tx-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.tx-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.tu .tx-table th { padding: 10px 10px; text-align: left; color: var(--dim); font: 500 10.5px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; border-bottom: 1px solid var(--line); background: transparent; }
.tu .tx-table td { padding: 11px 10px; border-bottom: 1px solid rgba(208,193,255,.07); color: var(--ink); }
.tu .tx-table tbody tr:hover td { background: rgba(155,108,255,.08); }
.tu .tx-table tbody tr[data-addr], .tu .tx-table tbody tr[data-height], .tu .tx-table tbody tr[data-worker] { cursor: pointer; }
.tu .tx-table a { color: var(--cyan); }
.tu .tx-table .th-sort { color: inherit; font: inherit; letter-spacing: inherit; text-transform: inherit; }
.tu .tx-table .th-sort.is-active { color: var(--cyan); }
.tx-pager { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; }
.tx-pager[hidden] { display: none; }
.tx-audit { border-color: rgba(50,230,255,.35); box-shadow: 0 0 0 1px rgba(50,230,255,.12), 0 20px 60px rgba(0,0,0,.35); }
.tx-audit.hidden { display: none; }
.tx-search input { width: 240px; padding: 8px 12px; border-radius: 12px; border: 1px solid var(--line); background: rgba(9,7,15,.6); color: var(--ink); font: 12px var(--font-mono); }
.tx-miner-top { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 14px; }
.tx-ring-card { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.tx-ring { --pct: 0; width: 168px; height: 168px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--cyan) 0, var(--violet) calc(var(--pct) * 1%), rgba(255,255,255,.07) calc(var(--pct) * 1%)); box-shadow: 0 0 40px rgba(155,108,255,.25); }
.tx-ring > div { width: 132px; height: 132px; border-radius: 50%; display: grid; place-content: center; background: #120d1f; }
.tx-ring .tx-metric { font-size: 26px; }
.tx-ring small { color: var(--muted); font: 10px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; }
.tx-meter-row { display: flex; align-items: center; gap: 10px; width: 100%; color: var(--muted); font: 11px var(--font-mono); }
.tu .tx-meter { flex: 1; height: 6px; border-radius: 3px; background: rgba(255,255,255,.08); }
.tu .tx-meter .meter-fill { background: linear-gradient(90deg, var(--violet), var(--cyan)); border-radius: 3px; }
.tx-status-row { display: grid !important; grid-template-columns: repeat(4, 1fr); gap: 14px; border: 0 !important; background: none !important; box-shadow: none !important; padding: 0 !important; }
.tu .tx-status { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--line); background: rgba(27,22,43,.72); color: var(--muted); font: 500 10.5px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; cursor: pointer; text-align: left; }
.tu .tx-status b { font: 800 26px Manrope, system-ui, sans-serif; letter-spacing: -.03em; text-transform: none; }
.tu .tx-status.ok b { color: var(--cyan); }
.tu .tx-status.warn b { color: var(--violet); }
.tu .tx-status.bad b { color: #ff6b8b; }
.tu .tx-status.attention b { color: #ffb86b; }
.tu .tx-status[aria-pressed="true"] { border-color: var(--cyan); background: linear-gradient(180deg, rgba(50,230,255,.14), rgba(27,22,43,.8)); box-shadow: 0 0 24px rgba(50,230,255,.2); }
.tu .status-pill { border-radius: 999px; }
@media (max-width: 1100px) {
  .tx-bento, .tx-bento-7 { grid-template-columns: repeat(2, 1fr); }
  .tx-tile-hero { grid-column: 1 / -1; }
  .tx-grid-2, .tx-miner-top { grid-template-columns: 1fr; }
  .tx-bento-tight { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .tx-status-row { grid-template-columns: repeat(2, 1fr); }
  .tx-command { min-width: 100%; }
  .tx-search input { width: 100%; }
}

/* ---- v3: dashboard balance ---- */
.tx-dash-main { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(280px, 1fr); gap: 18px; align-items: stretch; }
.tx-dash-main .tx-chart-card { display: flex; flex-direction: column; }
.tx-dash-main .tx-chart-card .chart-stage { flex: 1; min-height: 260px; }
.tx-window-card { display: flex; flex-direction: column; gap: 14px; }
.tx-donut { align-self: center; width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.07); box-shadow: 0 0 40px rgba(155,108,255,.22); }
.tx-donut > div { width: 112px; height: 112px; border-radius: 50%; display: grid; place-content: center; text-align: center; background: #150f24; }
.tx-donut b { font: 800 30px Manrope, system-ui, sans-serif; letter-spacing: -.03em; color: var(--ink); }
.tx-donut small { color: var(--muted); font: 10px var(--font-mono); text-transform: uppercase; letter-spacing: .12em; }
.tx-window-card .tx-flowlegend { flex-direction: column; flex-wrap: nowrap; gap: 8px; margin: 0; flex: 1; }
.tx-window-card .tx-flowlegend > a, .tx-window-card .tx-flowlegend > span { display: grid; grid-template-columns: 10px minmax(0, 1fr) 70px 58px; align-items: center; gap: 8px; }
.tx-window-card .tx-flowlegend code { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-window-card .tx-flowlegend i { height: 6px; border-radius: 3px; background: rgba(255,255,255,.08); overflow: hidden; display: block; }
.tx-window-card .tx-flowlegend em { display: block; height: 100%; border-radius: 3px; }
.tx-window-card .tx-flowlegend > * > span { text-align: right; }

/* Miners as compact cards sized to content; auto-fit fills the row for 1..n miners. */
.tu .tx-miner-cards thead { display: none; }
.tu .tx-miner-cards, .tu .tx-miner-cards tbody { display: block; }
.tu .tx-miner-cards tbody { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; }
.tu .tx-miner-cards tr { display: grid; grid-template-columns: 34px minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "rank addr addr" ". hr share" ". wk blk"; align-items: center; gap: 6px 18px; padding: 14px 16px; border-radius: 16px; border: 1px solid var(--line); background: rgba(255,255,255,.035); }
/* Every card, at every width: rank + address header, then a 2x2 stat grid (Hashrate|Share over
   Workers|Blocks). Placement is explicit via grid-area, so the 6 cells can never auto-flow into
   the 34px rank track (the desktop overlap: "HASHRATESHARE" with values on top of each other). */
.tu .tx-miner-cards td:nth-child(1) { grid-area: rank; }
.tu .tx-miner-cards td:nth-child(2) { grid-area: addr; min-width: 0; }
.tu .tx-miner-cards td:nth-child(3) { grid-area: hr; }
.tu .tx-miner-cards td:nth-child(4) { grid-area: share; }
.tu .tx-miner-cards td:nth-child(5) { grid-area: wk; }
.tu .tx-miner-cards td:nth-child(6) { grid-area: blk; }
.tu .tx-miner-cards td:nth-child(n+3) { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tu .tx-miner-cards tr:hover { border-color: rgba(50,230,255,.45); background: rgba(155,108,255,.08); }
.tu .tx-miner-cards td { display: flex; flex-direction: column; gap: 3px; padding: 0 !important; border: 0 !important; background: none !important; font-size: 14px; white-space: nowrap; }
.tu .tx-miner-cards td:nth-child(1) { width: 30px; height: 30px; border-radius: 10px; align-items: center; justify-content: center; background: linear-gradient(145deg, var(--violet), var(--cyan)) !important; color: #09070f; font-weight: 800; font-size: 13px; box-shadow: 0 0 18px rgba(93,166,255,.25); }
.tu .tx-miner-cards td:nth-child(2) { color: var(--ink); font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
.tu .tx-miner-cards td:nth-child(n+3)::before { color: var(--dim); font: 500 9.5px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; }
.tu .tx-miner-cards td:nth-child(3)::before { content: "Hashrate"; }
.tu .tx-miner-cards td:nth-child(4)::before { content: "Share"; }
.tu .tx-miner-cards td:nth-child(5)::before { content: "Workers"; }
.tu .tx-miner-cards td:nth-child(6)::before { content: "Blocks"; }
.tu .tx-miner-cards td[colspan] { grid-column: 1 / -1; width: auto; height: auto; background: none; color: var(--muted); font-weight: 500; }
.tu .tx-miner-cards tr:has(td[colspan]) { display: block; }
.tu .tx-blocks td { white-space: nowrap; }
.tu .tx-blocks td:nth-child(2) { max-width: 260px; overflow: hidden; text-overflow: ellipsis; }

/* ---- v3: miner/worker chart ---- */
.tu .tx-seg .chip { font-size: 12px !important; padding: 6px 12px !important; min-width: 44px; }
.tu .tx-seg .chip:hover:not(.active) { color: var(--ink); background: rgba(255,255,255,.06); }
.tx-chart-v3 .chart-stage { position: relative; height: 300px; padding: 0 !important; overflow: visible; }
.tx-chart-v3 .chart-stage .chart { position: absolute; inset: 0 0 0 0; width: 100%; height: 100%; }
.tx-chart-v3 .tu-grid { stroke: rgba(208,193,255,.09); stroke-width: 1; }
.tx-chart-v3 .tu-line { fill: none; stroke-width: 2.5; stroke-linecap: round; filter: drop-shadow(0 4px 14px rgba(50,230,255,.35)); }
.tx-chart-v3 .tu-ylabels { position: absolute; inset: 0; pointer-events: none; }
.tx-chart-v3 .tu-ylabels span { position: absolute; left: 14px; transform: translateY(-120%); color: var(--dim); font: 10.5px var(--font-mono); }
.tx-chart-v3 .tu-xaxis { position: relative; height: 22px; margin-top: 6px; }
.tx-chart-v3 .tu-xaxis span { position: absolute; top: 4px; transform: translateX(-50%); color: var(--dim); font: 10.5px var(--font-mono); white-space: nowrap; }
.tx-chart-v3 .tu-xaxis span:first-child { transform: none; }
.tx-chart-v3 .tu-xaxis span:last-child { transform: translateX(-100%); }
.tx-chart-v3 .tu-cross { position: absolute; top: 0; bottom: 0; width: 1px; background: linear-gradient(180deg, rgba(50,230,255,.0), rgba(50,230,255,.7), rgba(155,108,255,.0)); pointer-events: none; opacity: 0; transition: opacity .12s; }
.tx-chart-v3 .tu-dot { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--cyan); border: 2px solid #09070f; box-shadow: 0 0 0 4px rgba(50,230,255,.25), 0 0 18px var(--cyan); pointer-events: none; opacity: 0; }
.tx-chart-v3 .tu-tip { position: absolute; z-index: 5; display: grid; gap: 2px; min-width: 150px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: rgba(19,16,32,.96); box-shadow: 0 12px 30px rgba(0,0,0,.45); pointer-events: none; opacity: 0; transition: opacity .12s; }
.tx-chart-v3 .tu-tip time { color: var(--muted); font: 10.5px var(--font-mono); }
.tx-chart-v3 .tu-tip b { color: var(--ink); font: 800 17px Manrope, system-ui, sans-serif; }
.tx-chart-v3 .tu-tip span { color: var(--muted); font-size: 11.5px; }
.tx-chart-v3 .tu-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font: 12px var(--font-mono); }
.tx-chart-v3 .chart-tooltip, .tx-chart-v3 .chart-hover-line, .tx-chart-v3 .chart-hover-dot, .tx-chart-v3 .chart-xaxis { display: none !important; }
@media (max-width: 1100px) { .tx-dash-main { grid-template-columns: 1fr; } }
@media (max-width: 600px) {
  /* Miner cards: rank + address on top, then a clean 2x2 stat grid. */
  .tu .tx-miner-cards tbody { grid-template-columns: minmax(0, 1fr); }
  .tu .tx-miner-cards tr, .tu .tx-miner-cards tbody:has(tr:nth-child(2)) tr {
    grid-template-columns: 34px minmax(0, 1fr) minmax(0, 1fr) !important;
    grid-template-areas: "rank addr addr" ". hr share" ". wk blk";
    gap: 10px 14px; padding: 14px;
  }
  .tu .tx-miner-cards td:nth-child(1) { grid-area: rank; }
  .tu .tx-miner-cards td:nth-child(2), .tu .tx-miner-cards tbody:has(tr:nth-child(2)) td:nth-child(2) { grid-area: addr; max-width: none; width: auto; font-size: 13px; }
  .tu .tx-miner-cards td:nth-child(3) { grid-area: hr; }
  .tu .tx-miner-cards td:nth-child(4) { grid-area: share; }
  .tu .tx-miner-cards td:nth-child(5) { grid-area: wk; }
  .tu .tx-miner-cards td:nth-child(6) { grid-area: blk; }
  .tu .tx-miner-cards td:nth-child(n+3) { min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
  .tx-chart-v3 .chart-stage { height: 220px; }
}
/* Recent blocks: fixed-height scroller so 25 rows never dominate the page. */
.tu .tx-blocks-scroll { max-height: 430px; overflow-y: auto; border-radius: 12px; }
.tu .tx-blocks-scroll thead th { position: sticky; top: 0; z-index: 1; background: #171128; }

/* ---- v4: block markers (Zcash emblem on a dashed rule) ---- */
.tx-chart-v3 .chart-blocks { display: none !important; }
.tx-chart-v3 .tu-solo { stroke-width: 3; }
.tx-chart-v3 .tu-blocks { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.tx-chart-v3 .tu-bmark { position: absolute; top: 0; bottom: 0; width: 18px; margin-left: -9px; pointer-events: auto; text-decoration: none; }
.tx-chart-v3 .tu-rule { position: absolute; left: 50%; top: 22px; bottom: 4px; border-left: 1px dashed rgba(244,183,40,.45); }
.tx-chart-v3 .tu-badge { position: absolute; top: 4px; left: 50%; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 3px; padding: 1px; border-radius: 999px; background: rgba(19,16,32,.85); }
.tx-chart-v3 .tu-bmark.group .tu-badge { padding: 1px 6px 1px 1px; }
.tx-chart-v3 .tu-zec { width: 15px; height: 15px; display: block; filter: drop-shadow(0 0 6px rgba(244,183,40,.45)); }
.tx-chart-v3 .tu-badge b { color: #f4b728; font: 700 10px var(--font-mono); }
.tx-chart-v3 .tu-bmark:not(.mine) .tu-zec { opacity: .8; }
.tx-chart-v3 .tu-bmark:hover .tu-rule { border-left-color: #f4b728; border-left-style: solid; }
.tx-chart-v3 .tu-bmark:hover .tu-zec { opacity: 1; transform: scale(1.15); }
.tx-chart-v3 .tu-btip { position: absolute; top: 26px; left: 50%; transform: translateX(-50%); display: none; gap: 6px; min-width: 190px; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(244,183,40,.35); background: rgba(19,16,32,.97); box-shadow: 0 12px 30px rgba(0,0,0,.5); color: var(--muted); font-size: 11.5px; white-space: nowrap; z-index: 6; }
.tx-chart-v3 .tu-bmark:hover .tu-btip { display: grid; }
.tx-chart-v3 .tu-btip strong { color: #f4b728; font-size: 12px; }
.tx-chart-v3 .tu-btip div { display: grid; gap: 1px; }
.tx-chart-v3 .tu-btip div b { color: var(--ink); font-family: var(--font-mono); }
.tx-chart-v3 .tu-btip em { color: var(--dim); font-style: normal; }
.tx-chart-v3 .tu-bmark:first-child .tu-btip { left: 0; transform: none; }
.tx-chart-v3 .tu-bmark:last-child:not(:first-child) .tu-btip { left: auto; right: 0; transform: none; }

/* ---- v5: mobile / touch for the hashrate chart ---- */
.tx-chart-v3 .tu-bmark.open .tu-btip { display: grid; }
.tx-chart-v3 .tu-bmark.open .tu-rule { border-left-color: #f4b728; border-left-style: solid; }
.tx-chart-v3 .chart-stage { touch-action: pan-y; }
@media (hover: none) {
  .tx-chart-v3 .tu-bmark:hover .tu-btip { display: none; }
  .tx-chart-v3 .tu-bmark.open .tu-btip { display: grid; }
  .tx-chart-v3 .tu-bmark { width: 32px; margin-left: -16px; }
}
@media (max-width: 600px) {
  .tx-chart-v3 .tx-seg { display: flex; flex-wrap: wrap; width: 100%; }
  .tu .tx-chart-v3 .tx-seg .chip { flex: 1 1 0; min-height: 38px; min-width: 0; padding: 8px 6px !important; }
  .tx-chart-v3 .tu-ylabels span { left: 8px; padding: 1px 5px; border-radius: 6px; background: rgba(19,16,32,.72); font-size: 10px; }
  .tx-chart-v3 .tu-xaxis span { font-size: 10px; }
  .tx-chart-v3 .tu-xaxis span:nth-child(2), .tx-chart-v3 .tu-xaxis span:nth-child(4) { display: none; }
  .tx-chart-v3 .tu-btip { min-width: 0; width: max-content; max-width: min(280px, calc(100vw - 48px)); white-space: normal; }
  .tx-chart-v3 .tu-tip { min-width: 0; }
  .tx-chart-v3 .card-head button, .tx-chart-v3 button.chip { min-height: 38px; }
}
/* Phones: range buttons + Blocks toggle share one row (pool and wallet charts). */
@media (max-width: 600px) {
  .tx-chart-card .tx-controls:has(> .chip-toggle) { flex-wrap: nowrap; width: 100%; gap: 6px; }
  .tx-chart-card .tx-controls:has(> .chip-toggle) > .tx-seg { flex: 1 1 auto; width: auto; min-width: 0; flex-wrap: nowrap; }
  .tu .tx-chart-card .tx-controls:has(> .chip-toggle) > .tx-seg .chip { flex: 1 1 0; min-width: 0; min-height: 38px; padding: 8px 2px !important; font-size: 11px !important; }
  .tu .tx-chart-card .tx-controls > .chip-toggle { flex: none; min-height: 38px; padding: 6px 9px; font-size: 11px; gap: 4px; white-space: nowrap; }
}
