/* BW3 P2P Market — component styles. Classes use tokens only. Plain HTML and CSS, no script. */
:root { --font-sans: "IBM Plex Sans", "Noto Sans Myanmar", system-ui, sans-serif; --font-mono: "JetBrains Mono", ui-monospace, monospace; }
body { margin: 0; font-family: var(--font-sans); font-size: 13px; line-height: 20px; background: var(--bg); color: var(--text); -webkit-font-smoothing: antialiased; }
.bw3 { font-family: var(--font-sans); font-size: 13px; line-height: 20px; color: var(--text); }
.bw3 *, .bw3 *::before, .bw3 *::after { box-sizing: border-box; }
.bw3 button, .bw3 input, .bw3 select { font-family: inherit; }
.bw3 :focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.bw3 svg { flex: none; }
.bw3-num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.bw3-muted { color: var(--muted); }
.bw3-my { line-height: 1.7; white-space: nowrap; }
.bw3-buy { color: var(--buy); }
.bw3-sell { color: var(--sell); }
.bw3-gold { color: var(--gold); }
.bw3-demo { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); padding: var(--space-4); }
.bw3-demo--col { flex-direction: column; align-items: stretch; }
.bw3-touch { --control-sm: 44px; --control-md: 44px; --row: var(--row-touch); }

/* Button */
.bw3-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); height: var(--control-md); padding: 0 var(--space-4); border: 1px solid var(--line-strong); border-radius: var(--radius-control); background: var(--raised); color: var(--text); font-size: 13px; line-height: 20px; font-weight: 600; white-space: nowrap; text-decoration: none; cursor: pointer; }
.bw3-btn:hover { background: var(--hover); }
.bw3-btn svg { width: 16px; height: 16px; }
.bw3-btn--primary { border-color: var(--gold-fill); background: var(--gold-fill); color: var(--on-gold); }
.bw3-btn--primary:hover { background: var(--gold-fill); }
.bw3-btn--buy { border-color: var(--buy-solid); background: var(--buy-solid); color: var(--on-buy); }
.bw3-btn--sell { border-color: var(--sell-solid); background: var(--sell-solid); color: var(--on-sell); }
.bw3-btn--quiet { border-color: transparent; background: transparent; color: var(--muted); }
.bw3-btn--sm { height: var(--control-sm); padding: 0 var(--space-3); font-size: 12px; line-height: 16px; }
.bw3-btn--lg { height: var(--control-lg); font-size: 14px; }
.bw3-btn--block { width: 100%; }
.bw3-btn[disabled] { opacity: .45; cursor: not-allowed; }

/* Icon button */
.bw3-icon-btn { display: inline-flex; align-items: center; justify-content: center; width: var(--control-sm); height: var(--control-sm); padding: 0; border: 1px solid transparent; border-radius: var(--radius-control); background: transparent; color: var(--muted); cursor: pointer; position: relative; }
.bw3-icon-btn:hover { background: var(--hover); color: var(--text); }
.bw3-icon-btn svg { width: 18px; height: 18px; }
.bw3-icon-btn--line { border-color: var(--line-strong); }
.bw3-icon-btn[aria-pressed="true"] { border-color: var(--gold); background: var(--gold-bg); color: var(--gold); }
.bw3-icon-btn__count { position: absolute; top: -4px; right: -4px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: var(--radius-pill); background: var(--gold-fill); color: var(--on-gold); font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 600; text-align: center; }

/* Segmented control */
.bw3-seg { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--bg); }
.bw3-seg > button { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-1); height: calc(var(--control-sm) - 6px); padding: 0 var(--space-3); border: 0; border-radius: var(--radius-sm); background: transparent; color: var(--muted); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.bw3-seg > button:hover { color: var(--text); }
.bw3-seg > button[aria-pressed="true"], .bw3-seg > button[aria-selected="true"] { background: var(--raised); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-strong); }
.bw3-seg--block { display: flex; }
.bw3-seg--block > button { flex: 1; min-width: 0; }
.bw3-seg--side { padding: 3px; }
.bw3-seg--side > button { height: calc(var(--control-lg) - 8px); font-size: 14px; line-height: 20px; }
.bw3-seg--side > button.is-buy[aria-selected="true"] { background: var(--buy-solid); color: var(--on-buy); box-shadow: none; }
.bw3-seg--side > button.is-sell[aria-selected="true"] { background: var(--sell-solid); color: var(--on-sell); box-shadow: none; }

/* Chip */
.bw3-chip { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-1); height: var(--control-sm); padding: 0 var(--space-3); border: 1px solid var(--line-strong); border-radius: var(--radius-pill); background: transparent; color: var(--muted); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.bw3-chip:hover { color: var(--text); }
.bw3-chip[aria-pressed="true"] { border-color: var(--gold); background: var(--gold-bg); color: var(--gold); }
.bw3-chip svg { width: 14px; height: 14px; }

/* Field */
.bw3-field { display: flex; flex-direction: column; gap: var(--space-1); min-width: 0; }
.bw3-label { display: flex; align-items: center; gap: var(--space-1); min-height: 20px; font-size: 12px; line-height: 16px; font-weight: 500; color: var(--muted); }
.bw3-input { display: flex; align-items: center; gap: var(--space-2); height: var(--control-lg); padding: 0 var(--space-1) 0 var(--space-3); border: 1px solid var(--line-strong); border-radius: var(--radius-control); background: var(--bg); }
.bw3-input:focus-within { border-color: var(--gold); }
.bw3-input > input { flex: 1; min-width: 0; border: 0; padding: 0; background: transparent; color: var(--text); font-family: var(--font-mono); font-size: 20px; line-height: 28px; font-weight: 600; outline: none; }
.bw3-input__unit { padding-right: var(--space-2); font-size: 12px; font-weight: 600; color: var(--muted); }
.bw3-hint { font-size: 12px; line-height: 16px; color: var(--muted); }
.bw3-select { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); width: 100%; height: var(--control-sm); padding: 0 var(--space-2) 0 var(--space-3); border: 1px solid var(--line-strong); border-radius: var(--radius-control); background: var(--raised); color: var(--text); font-size: 12px; line-height: 16px; font-weight: 600; cursor: pointer; }
.bw3-select svg { width: 14px; height: 14px; color: var(--muted); }

/* Tabs */
.bw3-tabs { display: flex; gap: var(--space-1); border-bottom: 1px solid var(--line); }
.bw3-tab { display: inline-flex; align-items: center; gap: var(--space-2); height: var(--control-lg); padding: 0 var(--space-4); border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); font-size: 13px; line-height: 20px; font-weight: 600; cursor: pointer; }
.bw3-tab[aria-selected="true"] { border-bottom-color: var(--gold); color: var(--text); }

/* Badge and tag */
.bw3-badge { display: inline-flex; align-items: center; gap: 2px; height: 18px; padding: 0 4px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); color: var(--muted); font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; }
.bw3-badge--gold { border-color: var(--gold); color: var(--gold); }
.bw3-badge svg { width: 12px; height: 12px; }
.bw3-tag { display: inline-flex; align-items: center; gap: var(--space-1); height: 24px; padding: 0 var(--space-2); border: 1px solid var(--line-strong); border-radius: var(--radius-pill); background: transparent; color: var(--muted); font-size: 12px; line-height: 16px; font-weight: 500; white-space: nowrap; cursor: pointer; }
.bw3-tag svg { width: 14px; height: 14px; }
.bw3-tag--info { border-color: transparent; background: var(--info-bg); color: var(--info); }
.bw3-tag--warn { border-color: transparent; background: var(--warn-bg); color: var(--warn); }

/* Freshness */
.bw3-fresh { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 var(--space-2); border-radius: var(--radius-pill); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; }
.bw3-fresh svg { width: 12px; height: 12px; }
.bw3-fresh--ok { background: var(--buy-bg); color: var(--buy); }
.bw3-fresh--partial, .bw3-fresh--stale { background: var(--warn-bg); color: var(--warn); }
.bw3-fresh--down { background: var(--sell-bg); color: var(--sell); }
.bw3-banner { display: flex; align-items: center; gap: var(--space-2); min-height: var(--control-md); padding: var(--space-2) var(--space-3); border-radius: var(--radius-control); background: var(--warn-bg); color: var(--warn); font-size: 13px; line-height: 20px; font-weight: 500; }
.bw3-banner svg { width: 16px; height: 16px; }
.bw3-banner > span { flex: 1; }
.bw3-banner--down { background: var(--sell-bg); color: var(--sell); }
.bw3-banner .bw3-btn { border-color: currentColor; background: transparent; color: inherit; }

/* Info tip */
.bw3-info { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; padding: 0; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--muted); cursor: pointer; }
.bw3-info:hover { color: var(--info); }
.bw3-info svg { width: 14px; height: 14px; }
.bw3-touch .bw3-info { width: 44px; height: 44px; margin: -12px; }
.bw3-pop { max-width: 260px; padding: var(--space-2) var(--space-3); border: 1px solid var(--line-strong); border-radius: var(--radius-control); background: var(--raised); box-shadow: var(--shadow-overlay); color: var(--text); font-size: 12px; line-height: 18px; font-weight: 400; }

/* Card */
.bw3-card { display: flex; flex-direction: column; min-width: 0; min-height: 0; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.bw3-card__head { display: flex; align-items: center; gap: var(--space-2); height: 44px; padding: 0 var(--space-3) 0 var(--space-4); border-bottom: 1px solid var(--line); flex: none; }
.bw3-card__title { margin: 0; font-size: 14px; line-height: 20px; font-weight: 600; }
.bw3-card__body { display: flex; flex-direction: column; gap: var(--space-3); padding: var(--space-4); min-height: 0; flex: 1; }
.bw3-spacer { flex: 1; }

/* Stat tile */
.bw3-stat { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.bw3-stat__label { display: flex; align-items: center; gap: var(--space-1); font-size: 12px; line-height: 16px; font-weight: 500; color: var(--muted); white-space: nowrap; }
.bw3-stat__value { font-family: var(--font-mono); font-size: 16px; line-height: 22px; font-weight: 600; white-space: nowrap; }

/* Rate bar */
.bw3-rate { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.bw3-rate__side { display: flex; flex-direction: column; justify-content: center; gap: 2px; padding: var(--space-3) var(--space-4); min-width: 0; }
.bw3-rate__side--sell { align-items: flex-end; text-align: right; }
.bw3-rate__label { display: flex; align-items: center; gap: var(--space-1); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; }
.bw3-rate__label svg { width: 14px; height: 14px; }
.bw3-rate__price { font-family: var(--font-mono); font-size: 28px; line-height: 32px; font-weight: 600; }
.bw3-rate__price small { font-family: var(--font-sans); font-size: 12px; font-weight: 500; color: var(--muted); }
.bw3-rate__mid { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: var(--space-2) var(--space-6); border-left: 1px solid var(--line); border-right: 1px solid var(--line); text-align: center; }
.bw3-rate__mid b { font-family: var(--font-mono); font-size: 16px; line-height: 22px; font-weight: 600; }
.bw3-rate--compact .bw3-rate__price { font-size: 20px; line-height: 28px; }
.bw3-rate--compact .bw3-rate__side { padding: var(--space-1) var(--space-3); }
.bw3-rate--compact .bw3-rate__mid { padding: var(--space-2) var(--space-3); }

/* Order-book ladder */
.bw3-ladder { display: flex; flex-direction: column; min-height: 0; }
.bw3-ladder__head, .bw3-ladder__row { display: grid; grid-template-columns: 68px minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr); align-items: center; padding: 0 var(--space-3); }
.bw3-ladder__head { height: 24px; font-size: 12px; line-height: 16px; font-weight: 500; color: var(--muted); }
.bw3-ladder__head > :not(:first-child) { text-align: right; }
.bw3-ladder__side { display: flex; align-items: center; gap: var(--space-1); height: 24px; padding: 0 var(--space-3); font-size: 12px; line-height: 16px; font-weight: 600; }
.bw3-ladder__side--ask { color: var(--sell); }
.bw3-ladder__side--bid { color: var(--buy); }
.bw3-ladder__row { position: relative; height: var(--row); font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 500; font-variant-numeric: tabular-nums; }
.bw3-ladder__row:hover { background: var(--hover); }
.bw3-ladder__row > span { position: relative; text-align: right; }
.bw3-ladder__row > span:first-of-type { display: flex; gap: 2px; text-align: left; }
.bw3-ladder__row > span:last-child { color: var(--muted); }
.bw3-ladder__depth { position: absolute; top: 1px; bottom: 1px; right: 0; border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.bw3-ladder__row--ask .bw3-ladder__depth { background: var(--sell-bg); }
.bw3-ladder__row--bid .bw3-ladder__depth { background: var(--buy-bg); }
.bw3-ladder__row--ask .bw3-ladder__price { color: var(--sell); font-weight: 600; }
.bw3-ladder__row--bid .bw3-ladder__price { color: var(--buy); font-weight: 600; }
.bw3-ladder__mid { display: flex; align-items: center; gap: var(--space-2); height: 36px; padding: 0 var(--space-2) 0 var(--space-3); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--bg); font-size: 12px; color: var(--muted); }
.bw3-ladder__mid b { font-family: var(--font-mono); font-size: 20px; line-height: 28px; font-weight: 600; color: var(--gold); }
.bw3-ladder__note { display: flex; align-items: center; gap: var(--space-1); min-height: 24px; padding: 2px var(--space-3); background: var(--warn-bg); color: var(--warn); font-size: 12px; line-height: 16px; font-weight: 500; }
.bw3-split { display: flex; height: 6px; gap: 2px; border-radius: var(--radius-pill); overflow: hidden; }
.bw3-split > i { display: block; }
.bw3-split > i:first-child { background: var(--buy); }
.bw3-split > i:last-child { background: var(--sell); }

/* Estimate result, key-value rows, meter, route */
.bw3-result { display: flex; flex-direction: column; gap: var(--space-2); padding: var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--bg); }
.bw3-result__main { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.bw3-result__value { font-family: var(--font-mono); font-size: 28px; line-height: 32px; font-weight: 600; white-space: nowrap; }
.bw3-result__value small { font-family: var(--font-sans); font-size: 12px; font-weight: 600; color: var(--muted); }
.bw3-kv { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); font-size: 13px; line-height: 20px; }
.bw3-kv > :first-child { display: flex; align-items: center; gap: var(--space-1); color: var(--muted); }
.bw3-kv > :last-child { font-family: var(--font-mono); font-weight: 500; white-space: nowrap; }
.bw3-meter { flex: 1; height: 6px; border-radius: var(--radius-pill); background: var(--line); overflow: hidden; }
.bw3-meter > i { display: block; height: 100%; border-radius: var(--radius-pill); background: var(--gold-fill); }
.bw3-route { display: flex; gap: 2px; height: 8px; border-radius: var(--radius-pill); overflow: hidden; }
.bw3-route > i { display: block; min-width: 3px; background: var(--gold-fill); }
.bw3-route > i:nth-child(even) { background: var(--info); }
.bw3-route-row { display: flex; align-items: center; gap: var(--space-2); height: 28px; font-size: 12px; line-height: 16px; }
.bw3-route-row > .bw3-route-row__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.bw3-route-row > .bw3-num { color: var(--muted); white-space: nowrap; }
.bw3-route-row b { color: var(--text); font-weight: 600; }
.bw3-paused { padding: var(--space-3); border-radius: var(--radius-control); background: var(--warn-bg); color: var(--warn); font-size: 13px; line-height: 20px; font-weight: 500; }

/* Menu and dialog */
.bw3-menu { display: flex; flex-direction: column; gap: 2px; min-width: 280px; padding: var(--space-1); border: 1px solid var(--line-strong); border-radius: var(--radius-card); background: var(--raised); box-shadow: var(--shadow-overlay); }
.bw3-menu__item { display: flex; align-items: center; gap: var(--space-2); height: var(--control-md); padding: 0 var(--space-3); border-radius: var(--radius-sm); color: var(--text); font-size: 13px; line-height: 20px; font-weight: 500; text-decoration: none; }
.bw3-menu__item:hover { background: var(--hover); }
.bw3-menu__item svg { width: 16px; height: 16px; color: var(--muted); }
.bw3-menu__req { margin-left: auto; }
.bw3-menu__foot { display: flex; gap: var(--space-2); padding: var(--space-2) var(--space-1) var(--space-1); margin-top: var(--space-1); border-top: 1px solid var(--line); }
.bw3-menu__foot > * { flex: 1; }
.bw3-dialog { display: flex; flex-direction: column; gap: var(--space-3); width: 400px; max-width: 100%; padding: var(--space-6); border: 1px solid var(--line-strong); border-radius: var(--radius-card); background: var(--surface); box-shadow: var(--shadow-overlay); }
.bw3-dialog__head { display: flex; align-items: center; gap: var(--space-2); }
.bw3-dialog__title { flex: 1; margin: 0; font-size: 16px; line-height: 22px; font-weight: 600; }
.bw3-dialog__text { margin: 0; color: var(--muted); }
.bw3-dialog__actions { display: flex; gap: var(--space-2); }
.bw3-link { color: var(--gold); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

/* Data states */
.bw3-skel { display: block; border-radius: var(--radius-sm); background: var(--hover); }
.bw3-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-2); padding: var(--space-6); color: var(--muted); text-align: center; }
.bw3-empty svg { width: 24px; height: 24px; }


.bw3-dot { display: inline-block; width: 6px; height: 6px; border-radius: var(--radius-pill); background: var(--buy); margin-right: var(--space-1); }
.bw3-tabbar { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); height: 60px; border-top: 1px solid var(--line); background: var(--surface); flex: none; }
.bw3-tabbar__item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border: 0; background: transparent; color: var(--muted); font-size: 12px; line-height: 16px; font-weight: 600; text-decoration: none; position: relative; }
.bw3-tabbar__item svg { width: 22px; height: 22px; }
.bw3-tabbar__item[aria-current="page"] { color: var(--gold); }
.bw3-tabbar__item[aria-current="page"]::before { content: ""; position: absolute; top: 0; left: 30%; right: 30%; height: 2px; border-radius: 0 0 2px 2px; background: var(--gold); }
.bw3-delta { display: inline-flex; align-items: center; gap: var(--space-1); font-family: var(--font-mono); font-size: 13px; line-height: 20px; font-weight: 600; white-space: nowrap; }
.bw3-delta svg { width: 10px; height: 10px; }
.bw3-phonebar { display: flex; align-items: center; gap: var(--space-2); height: var(--topbar); padding: 0 var(--space-3); border-bottom: 1px solid var(--line); background: var(--surface); flex: none; }
.bw3-phonebar img { width: 32px; height: 32px; border-radius: var(--radius-control); }
.bw3-route-head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); }
.bw3-touch .bw3-input { height: 52px; }
.bw3-result--hero .bw3-result__main { flex-direction: column; align-items: flex-start; gap: var(--space-1); }
.bw3-result--hero .bw3-result__value { font-size: 40px; line-height: 44px; }
.bw3-rate--compact .bw3-rate__price small { display: none; }

/* Venue badges */
.bw3-badge--bin { border-color: var(--venue-bin); background: var(--venue-bin); color: var(--on-venue-bin); }
.bw3-badge--byb { border-color: var(--venue-byb); background: var(--venue-byb); color: var(--on-venue-byb); }

/* Shell: top bar with navigation, market ticker, status line */
.bw3-shell { display: flex; flex-direction: column; background: var(--bg); }
.bw3-topbar { display: flex; align-items: center; gap: var(--space-3); height: var(--topbar); padding: 0 var(--space-4); border-bottom: 1px solid var(--line); background: var(--surface); flex: none; }
.bw3-topbar__logo { width: 36px; height: 36px; border-radius: var(--radius-control); object-fit: cover; }
.bw3-topbar__name { font-size: 14px; line-height: 20px; font-weight: 600; white-space: nowrap; }
.bw3-nav { display: flex; align-self: stretch; gap: var(--space-1); margin-left: var(--space-3); }
.bw3-nav__item { display: inline-flex; align-items: center; gap: var(--space-2); padding: 0 var(--space-3); border-top: 2px solid transparent; border-bottom: 2px solid transparent; color: var(--muted); font-size: 14px; line-height: 20px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.bw3-nav__item:hover { color: var(--text); }
.bw3-nav__item svg { width: 18px; height: 18px; }
.bw3-nav__item[aria-current="page"] { border-bottom-color: var(--gold); color: var(--text); }
.bw3-nav__item .bw3-lock svg { width: 12px; height: 12px; }
.bw3-lock { display: inline-flex; color: var(--muted); }
.bw3-ticker { display: flex; align-items: center; gap: var(--space-6); height: var(--ticker); padding: 0 var(--space-4); border-bottom: 1px solid var(--line); background: var(--surface); flex: none; }
.bw3-ticker__pair { font-size: 16px; line-height: 22px; font-weight: 600; white-space: nowrap; }
.bw3-ticker__price { font-family: var(--font-mono); font-size: 28px; line-height: 32px; font-weight: 600; }
.bw3-ticker__group { display: flex; align-items: center; gap: var(--space-2); }
.bw3-vr { width: 1px; height: 28px; background: var(--line); flex: none; }
.bw3-stat__value--lg { font-size: 20px; line-height: 24px; }
.bw3-stat__label svg { width: 14px; height: 14px; }
.bw3-statusline { display: flex; align-items: center; gap: var(--space-4); height: var(--statusline); padding: 0 var(--space-4); border-top: 1px solid var(--line); background: var(--surface); font-size: 12px; line-height: 16px; color: var(--muted); flex: none; white-space: nowrap; }
.bw3-statusline a { display: inline-flex; align-items: center; gap: var(--space-1); color: var(--muted); font-weight: 500; text-decoration: none; }
.bw3-statusline a:hover { color: var(--text); }
.bw3-statusline a svg { width: 12px; height: 12px; }
.bw3-statusline .bw3-vr { height: 16px; }
.bw3-tipline { display: inline-flex; align-items: center; gap: var(--space-2); height: 24px; padding: 0 var(--space-2); border: 1px solid var(--line-strong); border-radius: var(--radius-pill); background: transparent; color: var(--text); font-size: 12px; line-height: 16px; font-weight: 600; cursor: pointer; }
.bw3-tipline:hover { background: var(--hover); }
.bw3-tipline svg { width: 12px; height: 12px; color: var(--gold); }
.bw3-tipline .bw3-num { font-weight: 500; color: var(--muted); }
.bw3-tabbar__item .bw3-lock { position: absolute; top: 6px; right: calc(50% - 22px); }
.bw3-tabbar__item .bw3-lock svg { width: 12px; height: 12px; }

/* Referral links and support card */
.bw3-ref { display: flex; flex-direction: column; gap: var(--space-1); }
.bw3-ref__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
.bw3-ref__row .bw3-btn { padding: 0 var(--space-2); }
.bw3-btn .bw3-ext { width: 12px; height: 12px; color: var(--muted); }
.bw3-support { display: flex; flex-direction: column; gap: var(--space-3); width: 340px; max-width: 100%; padding: var(--space-4); border: 1px solid var(--line-strong); border-radius: var(--radius-card); background: var(--raised); box-shadow: var(--shadow-overlay); }
.bw3-support__addr { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-2) var(--space-2) var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--bg); }
.bw3-support__addr code { flex: 1; min-width: 0; font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 500; overflow-wrap: anywhere; }
.bw3-support__links { display: flex; gap: var(--space-4); padding-top: var(--space-3); border-top: 1px solid var(--line); }

/* Chart frame: top toolbar, docked drawing tools, panes with a price scale on the right, time scale, bottom toolbar */
.bw3-chart { display: flex; flex-direction: column; min-width: 0; min-height: 0; flex: 1; }
.bw3-chart__top, .bw3-chart__bottom { display: flex; align-items: center; gap: var(--space-1); height: 44px; padding: 0 var(--space-2); flex: none; }
.bw3-chart__top { border-bottom: 1px solid var(--line); }
.bw3-chart__bottom { height: 36px; border-top: 1px solid var(--line); font-size: 12px; }
.bw3-chart__sep { width: 1px; height: 20px; margin: 0 var(--space-1); background: var(--line); flex: none; }
.bw3-tool { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-1); min-width: var(--control-sm); height: var(--control-sm); padding: 0 var(--space-2); border: 0; border-radius: var(--radius-sm); background: transparent; color: var(--muted); font-size: 13px; line-height: 20px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.bw3-tool:hover { background: var(--hover); color: var(--text); }
.bw3-tool svg { width: 18px; height: 18px; }
.bw3-tool svg.bw3-tool__caret { width: 12px; height: 12px; }
.bw3-tool[aria-pressed="true"] { background: var(--gold-bg); color: var(--gold); }
.bw3-tool--sm { min-width: 28px; height: 28px; font-size: 12px; line-height: 16px; }
.bw3-chart__body { display: flex; flex: 1; min-height: 0; }
.bw3-chart__tools { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 44px; padding: var(--space-1) 0; border-right: 1px solid var(--line); flex: none; }
.bw3-chart__tools .bw3-chart__sep { width: 20px; height: 1px; margin: var(--space-1) 0; }
.bw3-chart__panes { display: flex; flex-direction: column; flex: 1; min-width: 0; min-height: 0; }
.bw3-chart__pane { display: flex; flex: 1; min-height: 0; }
.bw3-chart__pane + .bw3-chart__pane { border-top: 1px solid var(--line); }
.bw3-chart__pane--sub { flex: none; height: 96px; }
.bw3-chart__plot { position: relative; flex: 1; min-width: 0; }
.bw3-chart__plot > svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.bw3-chart__legend { position: absolute; left: var(--space-2); top: var(--space-1); z-index: 1; display: flex; flex-direction: column; gap: 2px; font-size: 12px; line-height: 16px; white-space: nowrap; }
.bw3-chart__legend > div { display: flex; align-items: center; gap: var(--space-2); min-height: 20px; }
.bw3-chart__legend b { font-size: 13px; font-weight: 600; }
.bw3-chart__legend .bw3-num { font-weight: 500; }
.bw3-chart__legend i { display: inline-block; width: 12px; height: 2px; border-radius: var(--radius-pill); background: var(--info); }
.bw3-chart__scale { position: relative; width: 64px; border-left: 1px solid var(--line); font-family: var(--font-mono); font-size: 12px; line-height: 16px; color: var(--muted); flex: none; }
.bw3-chart__scale > span { position: absolute; left: var(--space-2); transform: translateY(-50%); }
.bw3-chart__scale > .bw3-chart__last { left: 0; right: 0; padding: 2px var(--space-2); background: var(--gold-fill); color: var(--on-gold); font-weight: 600; }
.bw3-chart__scale > .bw3-chart__val { left: 0; right: 0; padding: 2px var(--space-2); background: var(--raised); color: var(--text); font-weight: 600; }
.bw3-chart__time { display: flex; height: 28px; border-top: 1px solid var(--line); flex: none; }
.bw3-chart__time > div:first-child { display: flex; align-items: center; justify-content: space-between; flex: 1; padding: 0 var(--space-4); font-family: var(--font-mono); font-size: 12px; line-height: 16px; color: var(--muted); }
.bw3-chart__time > div:last-child { display: flex; align-items: center; justify-content: center; width: 64px; border-left: 1px solid var(--line); flex: none; }
.bw3-touch .bw3-card__head { height: 52px; }
.bw3-touch .bw3-chart__top, .bw3-touch .bw3-chart__bottom { height: 52px; }
.bw3-touch .bw3-tool { min-width: 44px; height: 44px; }
.bw3 .bw3-tag { font-family: var(--font-sans); }
.bw3-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 0.9fr); gap: var(--space-2); }
.bw3-filters .bw3-select { white-space: nowrap; }
.bw3-chart__mark { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-family: var(--font-sans); font-size: 96px; line-height: 1; font-weight: 600; letter-spacing: 0.04em; color: var(--line); pointer-events: none; user-select: none; }
.bw3-touch .bw3-chart__mark { font-size: 64px; }
.bw3-ticker { gap: var(--space-4); }
