/* ---------- live trade view (home): funnel, chutes and bins (events or sectors), see site/js/tradeflow.js ---------- */
.flow { padding: 16px; margin-bottom: 22px; }
.flow-head { display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: flex-end; justify-content: space-between; margin-bottom: 12px; }
.flow-head h2 { font-size: 17px; display: flex; align-items: center; gap: 8px; margin-bottom: 3px; }
.flow-head .hint { margin-bottom: 0; max-width: 78ch; }
.flow-live { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.flow[data-state="live"] .flow-live { background: var(--up); animation: pulse 1.6s ease-in-out infinite; }
.flow-stats { display: flex; gap: 24px; }
.feed-jump { display: none; }
.flow-stats div { display: grid; }
.flow-stats b { font-size: 24px; font-weight: 650; letter-spacing: -0.02em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.flow-stats span { color: var(--muted); font-size: 12px; white-space: nowrap; }
/* Above the stage: what the bins are, and the sound. */
.flow-tools { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.flow-mode, .flow-sound { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.flow-sound[hidden] { display: none; }
.flow-picks { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
/* The topic filter (topicfilter.js, styled in app.css) sits here only when the view is docked: on the home page it is in the bar above. */
.flow:not(.docked) .flow-topics { display: none; }
.flow-mode button, .f-mute, .feed-filter button { font: inherit; display: inline-flex; align-items: center; gap: 5px; padding: 3px 11px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--ink-2); cursor: pointer; }
.flow-mode button:hover, .f-mute:hover, .feed-filter button:hover { color: var(--ink); border-color: var(--muted); }
.flow-mode button[aria-pressed="true"], .f-mute[aria-pressed="true"], .feed-filter button[aria-pressed="true"] { background: var(--ink); color: var(--page); border-color: var(--ink); font-weight: 600; }
.f-volume { width: 96px; accent-color: var(--ink); cursor: pointer; }
.flow-body { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; }
.flow-stage { position: relative; min-height: clamp(460px, 66vh, 620px); border-radius: 10px; background: var(--page); border: 1px solid var(--hairline); overflow: hidden; touch-action: pan-y; --labels: 42px; }
.flow-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* The bins' names and figures sit in a strip under the piles; the script sets its height (--labels). */
.flow-bins { position: absolute; left: 0; right: 0; bottom: 0; height: var(--labels); display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); background: var(--surface); }
.flow-bin { display: grid; align-content: center; justify-items: center; gap: 0; min-width: 0; padding: 0 2px; border-top: 3px solid var(--axis); text-decoration: none; line-height: 1.2; }
.flow-bin + .flow-bin { border-left: 1px solid var(--hairline); }
.flow-bin b { font-size: 12px; font-weight: 650; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.flow-bin span { font-size: 12px; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
a.flow-bin:hover b { text-decoration: underline; }
/* Event bins: an event's name takes two lines, and a bin flashes when it changes hands. */
.flow-bins.by-event .flow-bin b { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; text-align: center; line-height: 1.15; font-size: 11.5px; overflow-wrap: anywhere; }
.flow-bin.idle b { color: var(--muted); }
.flow-bin.hot { border-top-color: #ffc93c; } /* the crowned bin (the crown itself is drawn on the stage) */
/* A big trade landing: the banner a slot machine shows for a win. Gold on black in both themes, like the lights. */
.flow-win { position: absolute; left: 50%; top: 27%; transform: translate(-50%, -50%) scale(0.6); display: grid; justify-items: center; gap: 1px; max-width: calc(100% - 24px); padding: 8px 22px 9px;
  border-radius: 14px; border: 2px solid #ffc93c; background: rgba(12, 10, 4, 0.86); color: #ffe9a8; text-align: center; pointer-events: none; opacity: 0; z-index: 1;
  box-shadow: 0 0 0 4px rgba(255, 201, 60, 0.18), 0 0 34px rgba(255, 201, 60, 0.45); }
.flow-win[hidden] { display: none; }
.flow-win.show { animation: flowWin 0.45s cubic-bezier(0.2, 1.6, 0.4, 1) forwards; }
@keyframes flowWin { to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
.flow-win small { font-size: 12px; font-weight: 700; letter-spacing: 0.22em; color: #ffc93c; }
.flow-win > b { font-size: 34px; font-weight: 800; line-height: 1.05; letter-spacing: -0.01em; color: #fff; font-variant-numeric: tabular-nums; text-shadow: 0 0 14px rgba(255, 201, 60, 0.9); }
.flow-win span { font-size: 12px; color: #ffe9a8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
/* Four sizes. From the second up the banner is festive red with gold; the third is larger and shimmers; the fourth pulses. */
.flow-win.rank2, .flow-win.rank3, .flow-win.rank4 { background: linear-gradient(180deg, #b3161b, #6d090d); border-color: #ffd866; color: #ffe9a8; }
.flow-win.rank2 > b { font-size: 42px; }
.flow-win.rank3 > b { font-size: 52px; }
.flow-win.rank4 > b { font-size: 64px; background: linear-gradient(180deg, #fff6c9, #ffc93c 55%, #ff9d2e); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 0 10px rgba(255, 201, 60, 0.9)); }
.flow-win.rank3, .flow-win.rank4 { border-width: 3px; padding: 10px 30px 12px; overflow: hidden; }
.flow-win.rank3 small, .flow-win.rank4 small { font-size: 14px; color: #ffe27a; }
.flow-win.rank4 small { font-size: 17px; letter-spacing: 0.3em; }
.flow-win.rank3::after, .flow-win.rank4::after { content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%; transform: skewX(-20deg);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent); animation: flowShine 1.3s ease-in-out infinite; }
@keyframes flowShine { to { left: 120%; } }
.flow-win.rank4.show { animation: flowWin 0.45s cubic-bezier(0.2, 1.6, 0.4, 1) forwards, flowWhale 0.6s ease-in-out 0.45s infinite; }
@keyframes flowWhale { 0%, 100% { transform: translate(-50%, -50%) scale(1); box-shadow: 0 0 0 4px rgba(255, 201, 60, 0.25), 0 0 40px rgba(255, 201, 60, 0.6); }
  50% { transform: translate(-50%, -50%) scale(1.06); box-shadow: 0 0 0 8px rgba(255, 201, 60, 0.4), 0 0 70px rgba(255, 201, 60, 0.95); } }
.flow-stage canvas.shake { animation: flowShake 0.5s linear; }
@keyframes flowShake { 10% { transform: translate(-5px, 3px); } 25% { transform: translate(6px, -4px); } 40% { transform: translate(-6px, -2px); } 55% { transform: translate(4px, 4px); } 70% { transform: translate(-3px, -3px); } 85% { transform: translate(2px, 1px); } }
.flow-bin.swap { animation: flowSwap 1s ease-out; }
@keyframes flowSwap { from { background: rgba(255, 201, 60, 0.45); } to { background: transparent; } }
.flow-msg { position: absolute; left: 50%; top: 12px; transform: translateX(-50%); max-width: calc(100% - 130px); padding: 6px 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); color: var(--ink-2); font-size: 13px; text-align: center; pointer-events: none; }
.flow-msg[hidden], .flow-card[hidden] { display: none; }
.flow-call { position: absolute; left: 0; top: 0; max-width: min(320px, calc(100% - 8px)); padding: 3px 9px; border-radius: 999px; background: var(--ink); color: var(--page);
  font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; opacity: 0; transition: opacity 0.35s; will-change: transform; }
.flow-call.show { opacity: 0.94; }
.flow-card { position: absolute; left: 0; top: 0; width: min(270px, calc(100% - 8px)); padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22); font-size: 13px; overflow-wrap: anywhere; pointer-events: none; will-change: transform; z-index: 2; }
.flow-card.pinned { pointer-events: auto; border-color: var(--ink-2); }
.fc-top { display: flex; gap: 8px; align-items: center; }
/* The × that closes a pinned card (only a pinned card takes taps). */
.fc-x { display: none; place-items: center; position: absolute; top: 3px; right: 3px; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 50%;
  background: none; color: var(--muted); font: inherit; font-size: 22px; line-height: 1; cursor: pointer; }
.fc-x:hover { background: var(--wash); color: var(--ink); }
.flow-card.pinned .fc-x { display: grid; }
.flow-card.pinned .fc-top { padding-right: 26px; }
.fc-title { font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.flow-card a { text-decoration: underline; text-underline-offset: 2px; }
.fc-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 14px; margin-top: 6px; }
.fc-actions small { color: var(--muted); }
@media (pointer: coarse) {
  .fc-actions a { display: inline-flex; align-items: center; min-height: 44px; }
  .fc-x { top: 0; right: 0; width: 44px; height: 44px; }
  .flow-card.pinned .fc-top { padding-right: 32px; }
}
.fc-amount { font-size: 22px; font-weight: 650; letter-spacing: -0.02em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.fc-line { color: var(--ink-2); }
.fc-meta { color: var(--muted); font-size: 12px; margin-top: 4px; }
.fc-meta i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; }
/* Beside the stage: every ball as a line, newest on top. It is as tall as the stage and scrolls inside itself. */
.flow-side { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.feed-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 26px; }
.feed-head h3 { font-size: 13px; font-weight: 650; margin: 0; }
.feed-filter { display: flex; gap: 5px; font-size: 12px; }
.feed-filter .sw-gold { width: 9px; height: 9px; border-radius: 50%; border: 2px solid #ffc93c; flex: none; }
.feed-filter button.ping { animation: feedPing 1.4s ease-out; }
@keyframes feedPing { 0% { box-shadow: 0 0 0 0 rgba(255, 201, 60, 0.95); border-color: #ffc93c; } 60% { border-color: #ffc93c; } 100% { box-shadow: 0 0 0 11px rgba(255, 201, 60, 0); } }
.feed-box { position: relative; flex: 1; min-height: 0; border-radius: 10px; background: var(--page); border: 1px solid var(--hairline); overflow: hidden; }
.f-feed { position: absolute; inset: 0; margin: 0; padding: 5px 5px 34px; list-style: none; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin;
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 44px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 44px), transparent); }
.f-feed .emptyrow { padding: 10px; }
/* A line. --t is its trade's colour (green: a buy, red: a sale); --w how far the bar behind it reaches, for the trade's size. */
.f-feed li:not(.emptyrow) { --t: var(--up); position: relative; isolation: isolate; display: grid; grid-template-rows: 1fr; overflow: hidden; border-radius: 8px; margin-bottom: 2px; }
.f-feed li.sell { --t: var(--down); }
.f-feed li:not(.emptyrow)::before { content: ""; position: absolute; z-index: -1; inset: 0 auto 0 0; width: var(--w, 0%);
  background: linear-gradient(90deg, color-mix(in srgb, var(--t) 20%, transparent), color-mix(in srgb, var(--t) 3%, transparent)); }
.feed-in { min-height: 0; overflow: hidden; }
.feed-row { font: inherit; color: inherit; text-align: left; width: 100%; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 1px 9px; align-items: center;
  padding: 6px 9px 6px 7px; border: 0; background: none; cursor: pointer; }
.feed-pic { grid-row: 1 / 3; width: 30px; height: 30px; border-radius: 50%; object-fit: cover; background: var(--wash); border: 2px solid var(--t); transition: border-color 0.5s; }
.feed-title { font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed-amt { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.feed-said { grid-column: 2; font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed-row time { font-size: 11px; color: var(--muted); text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
/* The picture wears its ball's rim while the ball lies on the stage: gold round a big trade, grey once the ball has burst. */
/* A big trade's line: larger, in gold, headed by the banner's words for its size; the bigger the trade, the bigger its figure.
   --gold-ink is a gold that can be read on the page; --tint how much gold lies over the line. */
.flow { --gold-ink: #8a5a00; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .flow { --gold-ink: #ffc93c; } }
:root[data-theme="dark"] .flow { --gold-ink: #ffc93c; }
.f-feed li.big { --tint: 0.13; box-shadow: inset 0 0 0 1.5px rgba(255, 201, 60, 0.85); background: linear-gradient(rgba(255, 201, 60, var(--tint)), rgba(255, 201, 60, var(--tint))), var(--page); }
.f-feed li.big .feed-row { grid-template-columns: 36px minmax(0, 1fr) auto; padding-top: 7px; padding-bottom: 7px; }
.f-feed li.big .feed-pic { grid-row: 1 / 4; width: 36px; height: 36px; box-shadow: 0 0 0 2px #ffc93c; }
.feed-tag { grid-column: 2; grid-row: 1; font-size: 10px; font-weight: 800; letter-spacing: 0.16em; line-height: 1.3; color: var(--gold-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-feed li.big .feed-title { grid-column: 2; grid-row: 2; }
.f-feed li.big .feed-said { grid-row: 3; }
.f-feed li.big .feed-amt { grid-column: 3; grid-row: 1 / 3; font-size: 15px; font-weight: 800; transform-origin: right center; }
.f-feed li.big time { grid-column: 3; grid-row: 3; }
.f-feed li.big .feed-more { padding-left: 52px; }
.f-feed li.rank2 { --tint: 0.24; box-shadow: inset 0 0 0 2px #ffc93c; }
.f-feed li.rank2 .feed-amt { font-size: 17px; }
/* The two largest sizes are gold on black in both themes, like the banner. */
.f-feed li.rank3, .f-feed li.rank4 { --ink: #f0efec; --ink-2: #ffe9a8; --muted: #c9b578; --gold-ink: #ffc93c; --page: #14110a; --tint: 0.1; color: var(--ink);
  box-shadow: inset 0 0 0 2px #ffc93c, inset 0 0 18px rgba(255, 201, 60, 0.35); }
.f-feed li.rank3 .feed-tag, .f-feed li.rank4 .feed-tag { font-size: 11px; letter-spacing: 0.22em; }
.f-feed li.rank3 .feed-amt { font-size: 20px; color: #fff; text-shadow: 0 0 12px rgba(255, 201, 60, 0.9); }
.f-feed li.rank4 .feed-amt { font-size: 24px; background: linear-gradient(180deg, #fff6c9, #ffc93c 55%, #ff9d2e); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 8px rgba(255, 201, 60, 0.8)); }
.f-feed li.rank3 a, .f-feed li.rank4 a { color: #ffe9a8; }
.f-feed li.gone .feed-pic { border-color: var(--axis); }
.feed-row:hover, .f-feed li.on .feed-row, .f-feed li.open .feed-row { background: color-mix(in srgb, var(--ink) 8%, transparent); }
.f-feed li.on, .f-feed li.open { box-shadow: inset 0 0 0 1.5px var(--ink-2); }
.feed-row:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: 8px; }
/* An open line: the whole question, and where the trade leads. */
.f-feed li.open .feed-title, .f-feed li.open .feed-said { white-space: normal; overflow-wrap: anywhere; }
.feed-more { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 14px; padding: 2px 9px 9px 46px; font-size: 12px; overflow-wrap: anywhere; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.feed-more a { text-decoration: underline; text-underline-offset: 2px; }
.feed-more small { color: var(--muted); }
@media (pointer: coarse) { .feed-more a { display: inline-flex; align-items: center; min-height: 44px; } }
/* A new line pushes the others down as it opens, and a light in its trade's colour runs across it; a big trade also glows gold for a while. */
.f-feed li.in { animation: feedIn 0.36s cubic-bezier(0.2, 0.9, 0.3, 1); }
.f-feed li.in::after { content: ""; position: absolute; inset: 0; pointer-events: none; transform: translateX(-101%);
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--t) 45%, transparent), transparent); animation: feedScan 0.8s ease-out 0.08s; }
.f-feed li.big.in { animation: feedIn 0.36s cubic-bezier(0.2, 0.9, 0.3, 1), feedGold 2.6s ease-out; }
.f-feed li.big.in::after { background: linear-gradient(90deg, transparent, rgba(255, 201, 60, 0.7), transparent); }
@keyframes feedIn { from { grid-template-rows: 0fr; opacity: 0; } }
@keyframes feedScan { to { transform: translateX(101%); } }
@keyframes feedGold { from { box-shadow: inset 0 0 0 2px #ffc93c, inset 0 0 26px rgba(255, 201, 60, 0.8); background: rgba(255, 201, 60, 0.3); } }
/* The list celebrates a big trade with the stage, as its ball lands. The frame blinks with the lights (red and gold for the two
   largest sizes); the line flashes and its figure, counting up, jumps out; a light keeps running across the two largest sizes,
   and the largest of all goes on throbbing. The script sets how many times the frame blinks (--blinks). */
.feed-box.win { animation: feedFrame 0.36s ease-in-out var(--blinks, 5); }
.feed-box.win.hotter { animation: feedFrameHot 0.72s ease-in-out calc(var(--blinks, 10) / 2); }
@keyframes feedFrame { 50% { border-color: #ffc93c; box-shadow: 0 0 0 2px rgba(255, 201, 60, 0.6), 0 0 22px rgba(255, 201, 60, 0.6); } }
@keyframes feedFrameHot { 25% { border-color: #ff3b3b; box-shadow: 0 0 0 2px rgba(255, 59, 59, 0.7), 0 0 24px rgba(255, 59, 59, 0.6); }
  75% { border-color: #ffc93c; box-shadow: 0 0 0 2px rgba(255, 201, 60, 0.7), 0 0 24px rgba(255, 201, 60, 0.7); } }
.f-feed li.win { animation: feedBlink 0.36s ease-in-out 5; }
.f-feed li.win.rank2 { animation-iteration-count: 7; }
.f-feed li.win.rank3 { animation-iteration-count: 9; }
.f-feed li.win.rank4 { animation: feedBlink 0.36s ease-in-out 12, feedThrob 0.7s ease-in-out 4.4s infinite; }
@keyframes feedBlink { 50% { filter: brightness(1.55) saturate(1.25); box-shadow: inset 0 0 0 2px #fff7d6, inset 0 0 28px rgba(255, 201, 60, 0.95); } }
@keyframes feedThrob { 50% { box-shadow: inset 0 0 0 3px #ffc93c, inset 0 0 34px rgba(255, 201, 60, 0.85); } }
.f-feed li.win .feed-amt { animation: feedPop 0.55s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes feedPop { from { transform: scale(1.5); } }
.feed-in { position: relative; }
.f-feed li.win.rank3 .feed-in::after, .f-feed li.win.rank4 .feed-in::after { content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%; transform: skewX(-20deg); pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent); animation: flowShine 1.3s ease-in-out infinite; }
/* What arrived while the list was being read. */
.feed-new { position: absolute; left: 50%; top: 8px; transform: translateX(-50%); z-index: 1; font: inherit; font-size: 12px; font-weight: 600; padding: 4px 12px; border: 0; border-radius: 999px;
  background: var(--ink); color: var(--page); white-space: nowrap; cursor: pointer; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3); }
.feed-new[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .f-feed li.in, .f-feed li.in::after, .f-feed li.big.in, .feed-filter button.ping, .feed-box.win, .f-feed li.win, .f-feed li.win .feed-amt, .f-feed li.win .feed-in::after { animation: none !important; } }
.flow-legend { display: flex; flex-wrap: wrap; gap: 4px 18px; align-items: center; margin-top: 10px; color: var(--muted); font-size: 12px; }
.flow-legend span { display: inline-flex; align-items: center; gap: 6px; }
.flow-legend .sw { width: 12px; height: 12px; border-radius: 50%; border: 3px solid var(--up); flex: none; }
.flow-legend .sw.sell { border: 3px solid var(--down); }
.flow-legend .sw.gold { border: 2px solid #ffc93c; }
/* Off the home page the view is docked at the left of the window: folded to a tab, or open as a small panel. */
.flow-dockbar { display: none; }
.flow.docked { position: fixed; left: 12px; bottom: 12px; z-index: 40; width: min(390px, calc(100vw - 24px)); margin: 0; padding: 6px 10px 10px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.38); }
.flow.docked .flow-dockbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.flow.docked .flow-head, .flow.docked .flow-side, .flow.docked .flow-legend, .flow.docked .flow-mode > span { display: none; }
.flow.docked .flow-body { grid-template-columns: minmax(0, 1fr); }
.flow.docked .flow-stage { min-height: 0; height: min(340px, 50vh); }
.flow.docked .flow-tools { margin-bottom: 8px; }
.flow.docked .f-volume { width: 72px; }
.flow.docked.folded { width: auto; padding: 0; border-radius: 999px; position: fixed; }
.flow.docked.folded > :not(.flow-dockbar), .flow.docked.folded .f-full { display: none; }
.flow.docked.folded .flow-dockbar { margin: 0; }
.f-fold { font: inherit; font-weight: 650; display: inline-flex; align-items: center; gap: 10px; padding: 7px 4px; border: 0; background: none; color: var(--ink); cursor: pointer; border-radius: 999px; text-align: left; }
.f-fold::after { content: "▾"; color: var(--muted); }
.f-words { display: grid; line-height: 1.2; }
.f-name { display: inline-flex; align-items: center; gap: 7px; }
.f-back { font-style: normal; font-size: 12px; font-weight: 500; color: var(--ink-2); }
.f-thumb, .f-back { display: none; }
.f-mini { font-weight: 500; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.f-mini:empty { display: none; }
/* Folded: a tab that is hard to miss. A round picture of the game, a ring in the logo's colours that breathes, and "Keep watching". */
.flow.docked.folded { overflow: visible; border: 2px solid transparent; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(90deg, var(--brand-a), var(--brand-b), #ffc93c) border-box; animation: flowBeckon 3.6s ease-in-out infinite; }
@keyframes flowBeckon { 0%, 100% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 0 0 rgba(255, 201, 60, 0.55); } 50% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 0 9px rgba(255, 201, 60, 0); } }
.flow.docked.folded .f-fold { padding: 7px 18px 7px 7px; font-size: 15px; }
.flow.docked.folded .f-fold::after { content: "▸"; color: var(--ink); font-size: 16px; }
.flow.docked.folded .f-back { display: block; }
.flow.docked.folded.has-shot .f-thumb { display: block; width: 46px; height: 46px; border-radius: 50%; flex: none; background: var(--page) center 62% / 230% auto no-repeat; border: 1px solid var(--border); }
.flow.docked.folded.landing { opacity: 0.25; animation: none; }
.flow.docked.folded.arrived { animation: flowArrive 0.7s cubic-bezier(0.2, 1.7, 0.4, 1), flowRing 1.1s ease-out 2; }
@keyframes flowArrive { 0% { transform: scale(0.7); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes flowRing { from { box-shadow: 0 0 0 0 rgba(255, 201, 60, 0.9); } to { box-shadow: 0 0 0 26px rgba(255, 201, 60, 0); } }
/* The picture of the game that flies into the tab on leaving the home page. */
.flow-ghost { position: fixed; z-index: 60; pointer-events: none; object-fit: cover; border: 1px solid var(--border); border-radius: 10px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45); transform-origin: center; }
@media (prefers-reduced-motion: reduce) { .flow.docked.folded, .flow.docked.folded.arrived, .flow-win.rank4.show, .flow-win::after, .flow-stage canvas.shake { animation: none !important; } }
.f-full { font-size: 12px; white-space: nowrap; }
/* The docked view can be dragged to any corner (tradeflow.js place) and hidden with its ×. */
.flow.docked[data-corner$="r"] { left: auto; right: 12px; }
.flow.docked[data-corner^="t"] { bottom: auto; top: calc(var(--head-h, 64px) + 12px); }
.flow.docked.closed { display: none; }
.flow.docked .flow-dockbar { touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.flow.docked.dragging { animation: none; transition: none; cursor: grabbing; opacity: 0.92; }
.flow.docked.dragging .flow-dockbar, .flow.docked.dragging .f-fold { cursor: grabbing; }
.f-close { display: none; font: inherit; font-size: 15px; line-height: 1; width: 26px; height: 26px; flex: none; border-radius: 50%; border: 1px solid var(--border); background: var(--surface); color: var(--ink-2); cursor: pointer; padding: 0; }
.f-close:hover, .f-close:focus-visible { color: var(--ink); border-color: var(--ink-2); }
.flow.docked .f-close { display: inline-grid; place-items: center; }
.flow.docked.folded .f-close { position: absolute; top: -9px; right: -9px; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35); }
body.flow-tab-low { padding-bottom: 84px; }
@media (max-width: 1000px) {
  .flow-stats { flex-wrap: wrap; align-items: center; }
  .flow:not(.docked) .feed-jump { display: inline-block; font: inherit; font-size: 13px; color: var(--accent); background: none; border: 0; padding: 8px 0; cursor: pointer; }
  .feed-head { scroll-margin-top: calc(var(--head-h, 100px) + 8px); }
  .flow-body { grid-template-columns: minmax(0, 1fr); }
  .feed-box { flex: none; height: min(380px, 60vh); }
}
@media (max-width: 760px) {
  .flow { padding: 12px; }
  .flow-stats { gap: 16px; }
  .flow-stats b { font-size: 20px; }
  .flow-stage { min-height: 0; height: clamp(400px, 62vh, 480px); }
  .flow-bin b, .flow-bin span, .flow-bins.by-event .flow-bin b { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) { .flow-live { animation: none !important; } .flow-bin.swap { animation: none; } }
