/* Cella007FX PRO panel-trend.css — panel v2 (11 Nov 2026, design/panel-v2/SPEC.md §4.4 / §4.7): Trend card (#w-mtf,
   classes mt2-*, widgets/mtf.js) and Price card (#w-quote, classes q2-*, widgets/quote.js). The Range card (#w-stats,
   st2-*) lives in panel-levels.css: the build swapped stats.js / quote.js between the two owners. Tokens only; shared kit in panel.css. */

/* ---- Trend #w-mtf ------------------------------------------------------------------------------------------------- */
#w-mtf.vz-card { margin-bottom: 0; }   /* app.css #w-mtf margin-bottom: 10px — the kit's card gap handles spacing now */
.mt2-biasbox { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.mt2-bias { justify-content: space-between; flex-wrap: wrap; row-gap: 2px; }
.mt2-bias-w { font: 700 var(--vz-fs-em)/1.2 var(--font-ui); letter-spacing: .03em; white-space: nowrap; }
.mt2-bias-n { font-size: var(--vz-fs-body); color: var(--text-1); }
#w-mtf .vz-split { height: 10px; }
.mt2-trend { font: 700 var(--vz-fs-em)/1.2 var(--font-ui); letter-spacing: .03em; }
.mt2-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.mt2-grid > .vz-stat { padding: 6px 8px; background: var(--bg-3); border: 1px solid var(--line); border-radius: var(--radius); gap: 3px; }
.mt2-grid > .vz-stat > .vz-meter { margin-top: 2px; }
.mt2-sqrow { display: flex; align-items: center; gap: 6px; min-width: 0; margin-top: 2px; }
.mt2-sqrow > .vz-meter { flex: 1 1 auto; }
.mt2-comp { font-size: var(--vz-fs-sm); color: var(--text-1); }
.mt2-tablewrap { min-width: 0; }
/* 5 columns in a 269 px card: fixed 11 px type (not the phone's 12 px) and headers that may wrap ("% of / price") */
.mt2-table { width: 100%; border-collapse: collapse; table-layout: auto; font-size: 11px; }
.mt2-table th, .mt2-table td { padding: 4px 2px; text-align: left; white-space: nowrap; border-bottom: 1px solid var(--line); }
.mt2-table thead th { font-size: var(--vz-fs-micro); font-weight: 600; letter-spacing: 0; line-height: 1.15; vertical-align: bottom; white-space: normal; text-transform: uppercase; color: var(--text-2); }
.mt2-table tbody tr:last-child > * { border-bottom: 0; }
.mt2-table .mt2-c-n { text-align: right; }
.mt2-c-tf { font-weight: 700; color: var(--text-1); }
.mt2-c-tr { font-weight: 600; }
.mt2-c-gr { font-size: var(--vz-fs-micro); font-weight: 700; letter-spacing: .03em; }
.mt2-table tr.is-active { background: var(--bg-3); }
.mt2-table tr.is-active .mt2-c-tf { color: var(--vz-ink-gold); }
.mt2-table .vz-ink { color: var(--vz-ink, var(--text-0)); }
@media (max-width: 340px) {   /* narrow sheet: the table keeps every column, it just tightens */
  .mt2-table th, .mt2-table td { padding: 4px 1px; }
}

/* ---- header trend strip (#hdr-stats, widgets/header.js; base rules in app.css / mobile.css) ---------------------------- */
/* 11 Nov 2026: M30 makes 7 chips. In one line ("M15 ▲") they no longer fit beside the bid below ~375 px, nor beside
   "TREND ▼ BEARISH  3 of 7 down" on a 1101-1279 px desktop (the strip clipped H1..D1 at 1110 px), so there each chip
   stacks its label over its arrow (width: min-content wraps at the space, like the Trend card tiles): 7 chips ≈ 180 px,
   inside the 200 px the phone header leaves at 320 px. From 1280 px the one-line chips fit again (measured: 560 of
   609 px). Loaded after mobile.css, so these rules win. */
@media (max-width: 767px), (min-width: 1101px) and (max-width: 1279px) {
  .mtf-hdr-tfs { gap: 3px; }
  .mtf-hdr-tf { width: min-content; white-space: normal; padding: 1px 4px; font-size: 10px; line-height: 12px; min-height: 28px; border-radius: 7px; text-align: center; vertical-align: middle; }
}
@media (max-width: 767px) {
  /* the bias word + tally are hidden on phones (their 8 px gap stayed); top-aligned + 2 px so the two-line chips sit in
     the middle of the 32 px row (baseline alignment pushed them 6 px down, past the header's bottom edge) */
  #hdr-stats > .mtf-hdr-tfs { margin-left: 0; vertical-align: top; margin-top: 2px; }
  /* 11 Nov 2026 (review UX F7): the chips are too small to tap one by one, so on a phone they are read-only and the
     whole strip is ONE button (header.js) that opens the Trend card */
  .mtf-hdr-tf { pointer-events: none; }
  #hdr-stats > .mtf-hdr-tfs { cursor: pointer; border-radius: 8px; -webkit-tap-highlight-color: transparent; }
  #hdr-stats > .mtf-hdr-tfs:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; }
  #hdr-stats > .mtf-hdr-tfs:active { opacity: .7; }
}
/* chip ink: the AA text inks (fill tokens --up / --down measured 3.8-4.3:1 at 10 px; review UX F8, 11 Nov 2026) */
.mtf-hdr-tf.up { color: var(--vz-ink-up); }
.mtf-hdr-tf.down { color: var(--vz-ink-down); }
/* touch screens wider than a phone (tablet, landscape): finger-sized chips (review UX F9) */
@media (pointer: coarse) and (min-width: 768px) {
  .mtf-hdr-tf { min-height: 32px; }
}
@media (min-width: 1101px) and (max-width: 1279px) {
  #hdr-stats > .mtf-hdr-tfs { align-self: center; }   /* #hdr-stats aligns on the baseline; centre the two-line chips */
}
@media (max-width: 360px) {
  .mtf-hdr-tfs { gap: 2px; }
  .mtf-hdr-tf { padding: 1px 3px; }
}

/* ---- Price #w-quote (q2-*) ------------------------------------------------------------------------------------------- */
.q2-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; flex-wrap: wrap; min-width: 0; }
.q2-bidbox { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
#w-quote .q2-bid { font: 700 var(--vz-fs-big)/1.05 var(--font-mono); font-variant-numeric: tabular-nums; color: var(--text-0); }
.q2-chg { font-size: var(--vz-fs-body); font-weight: 700; padding-bottom: 3px; border-radius: 4px; }
#w-quote .q2-one { margin: -2px 0 0; line-height: 1.35; text-wrap: balance; }   /* 12 Nov 2026: "One price on this feed…" under a one-price feed */
.q2-spread { min-height: var(--vz-tap); border-radius: var(--radius); }
.q2-k { flex: 0 0 auto; }
.q2-meter { display: block; }
.q2-meter > .vz-meter { width: 100%; height: 8px; border-radius: 4px; }
.q2-spread-v { font-size: var(--vz-fs-body); font-weight: 600; white-space: pre; }
#w-quote .q2-kv { grid-template-columns: auto minmax(0, 1fr); }   /* keys never wrap; a long Source value wraps instead */
#w-quote .q2-kv > :nth-child(odd) { white-space: nowrap; }
#w-quote .q2-kv > .vz-ink { color: var(--vz-ink, var(--text-0)); }
#w-quote .q2-kv > #q-src { white-space: normal; overflow-wrap: anywhere; text-align: right; font-family: var(--font-ui); }
/* source state colours as AA text inks (app.css uses the fill tokens: --ok on the light card measured 4.2:1, 11 Nov 2026) */
#w-quote #q-src.state-live { color: var(--vz-ink-up); }
#w-quote #q-src.state-delayed, #w-quote #q-src.state-paused, #w-quote #q-src.state-fallback { color: var(--vz-ink-warn); }
#w-quote #q-src.state-quote_only, #w-quote #q-src.state-offline { color: var(--vz-ink-down); }
.q2-ctl { min-height: var(--vz-tap); }
