/* shell.css — login gate + home hub + per-monitor nav.
 * Built entirely on style.css design tokens so light/dark stays coherent.
 * (style.css already styles body, .hd, .brand, .brand-mark, .btn*, .ver — we reuse those.) */

/* ---------------- Login ---------------- */
.auth-wrap   { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.auth-card   { width: 100%; max-width: 384px; background: var(--card); border: 1px solid var(--border);
               border-radius: 16px; box-shadow: var(--shadow-md); padding: 30px 28px; }
.auth-brand  { display: flex; align-items: center; gap: 11px; justify-content: center; margin-bottom: 8px; }
.auth-brand .brand-mark { width: 40px; height: 40px; border-radius: 11px; }
.auth-brand .brand-mark svg { width: 22px; height: 22px; }
.auth-title  { font-size: 20px; font-weight: 700; color: var(--ink); text-align: center; }
.auth-sub    { font-size: 13px; color: var(--muted); text-align: center; margin: 4px 0 20px; }
.auth-card label { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-soft); margin: 14px 0 6px; }
.auth-card input { width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: 10px;
               background: var(--surface); color: var(--ink); font-family: inherit; font-size: 14px; box-sizing: border-box; }
.auth-card input:focus { outline: none; border-color: var(--blue); background: var(--card); }
.auth-card .btn  { width: 100%; justify-content: center; margin-top: 22px; padding: 11px; font-size: 14px; }
.auth-err    { color: var(--red-ink); background: var(--red-soft); border: 1px solid var(--red);
               border-radius: 9px; padding: 9px 12px; font-size: 12.5px; margin-top: 14px; display: none; }
.auth-err.show  { display: block; }
.auth-hint   { font-size: 12px; color: var(--amber-ink); background: var(--amber-soft);
               border-radius: 9px; padding: 9px 12px; margin-bottom: 4px; display: none; }
.auth-hint.show { display: block; }

/* ---------------- Home hub ---------------- */
.hub-main    { max-width: 900px; margin: 0 auto; padding: 40px 22px; }
.hub-head    { margin: 4px 0 24px; display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.hub-head h2 { font-size: 23px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); margin: 0; }
.hub-head p  { font-size: 14px; color: var(--muted); margin: 5px 0 0; }
.hub-summary { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--ink-soft); }
.hub-summary .hs-pill { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; }
.hub-summary .hs-dot  { width: 8px; height: 8px; border-radius: 50%; flex: none; }

.hub-grid    { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; align-items: stretch; }
@media (max-width: 1180px) { .hub-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .hub-grid { grid-template-columns: 1fr; } }
.hub-card    { position: relative; display: flex; flex-direction: column; text-decoration: none; overflow: hidden;
               background: var(--card); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow-sm);
               padding: 20px 20px 14px; transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease; }
.hub-card::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px; opacity: .95; }
.hub-card[data-platform="ltg"]::before     { background: linear-gradient(90deg, #2563eb, #1d4ed8); }
.hub-card[data-platform="ftn"]::before     { background: linear-gradient(90deg, #16a34a, #15803d); }
.hub-card[data-platform="stubhub"]::before { background: linear-gradient(90deg, #6f2dbd, #3b0a73); }
.hub-card[data-platform="viagogo"]::before { background: linear-gradient(90deg, #8bc34a, #5a6772); }
.hub-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: color-mix(in srgb, var(--blue) 55%, var(--border)); }
.hub-card[data-state="disconnected"] { border-color: color-mix(in srgb, var(--red) 32%, var(--border)); }
.hub-card.disabled { cursor: default; }
.hub-card.disabled:hover { transform: none; box-shadow: var(--shadow-sm); border-color: var(--border); }

.hub-card-head { display: flex; align-items: center; gap: 13px; margin-bottom: 12px; }
.hub-ico     { width: 46px; height: 46px; border-radius: 13px; display: flex; align-items: center;
               justify-content: center; color: #fff; flex: 0 0 auto; }
.hub-ico svg { width: 24px; height: 24px; }
.hub-ico.lft { background: linear-gradient(135deg, #2563eb, #1d4ed8); }
.hub-ico.ftn { background: linear-gradient(135deg, #16a34a, #15803d); }
.hub-ico.stubhub { background: linear-gradient(135deg, #6f2dbd, #3b0a73); }   /* StubHub purple */
.hub-ico.viagogo { background: linear-gradient(135deg, #8bc34a, #5a6772); }   /* viagogo green/grey */
.hub-card-id { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.hub-card-id h3 { font-size: 15.5px; font-weight: 700; color: var(--ink); margin: 0; line-height: 1.2;
                  max-width: 100%; }
.hub-go      { flex: 0 0 auto; font-size: 19px; color: var(--muted); opacity: 0; transform: translateX(-5px); transition: .14s ease; }
.hub-card:hover .hub-go { opacity: 1; transform: translateX(0); }
.hub-badge   { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 3px 10px; }

.hub-alert   { font-size: 12px; font-weight: 600; line-height: 1.4; border-radius: 10px; padding: 7px 11px; margin: 0 0 12px;
               color: var(--amber-ink); background: var(--amber-soft); border: 1px solid color-mix(in srgb, var(--amber-ink) 28%, transparent); }
.hub-card[data-state="disconnected"] .hub-alert { color: var(--red-ink); background: var(--red-soft);
               border-color: color-mix(in srgb, var(--red) 38%, transparent); }
.hub-card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px;
                 padding-top: 11px; border-top: 1px solid var(--border); }
.hub-logbtn  { flex: 0 0 auto; font-size: 11px; font-weight: 600; color: var(--ink-soft); background: var(--surface);
               border: 1px solid var(--border); border-radius: 999px; padding: 4px 11px; cursor: pointer;
               transition: .12s ease; white-space: nowrap; }
.hub-logbtn:hover { color: var(--ink); border-color: color-mix(in srgb, var(--blue) 55%, var(--border)); }

/* Scan-log modal — recent auto-reprice cycles for one platform */
.scanlog-body { max-height: 52vh; overflow-y: auto; margin: 8px 0 4px; }
.sl-row   { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 8px 2px; border-bottom: 1px solid var(--border); font-size: 13px; }
.sl-row:last-child { border-bottom: none; }
.sl-ico   { flex: 0 0 auto; width: 20px; text-align: center; }
.sl-when  { flex: 1 1 auto; color: var(--ink); font-weight: 600; }
.sl-rel   { color: var(--muted); font-size: 11.5px; font-weight: 400; }
.sl-tag   { flex: 0 0 auto; font-size: 10.5px; font-weight: 700; border-radius: 999px; padding: 2px 9px; }
.sl-detail{ flex: 1 1 100%; font-size: 11.5px; color: var(--muted); padding-left: 30px; }
.sl-ok      .sl-tag { background: var(--green-soft); color: var(--green-ink); }
.sl-skipped .sl-tag { background: var(--amber-soft); color: var(--amber-ink); }
.sl-error   .sl-tag { background: var(--red-soft);   color: var(--red-ink); }

/* ---------------- Platform logos (frontend/assets/*.png; SVG fallback if missing) ----------------
 * The <img> carries data-logo on its parent; on a load error JS removes data-logo, which
 * restores the coloured icon background + reveals the .plogo-fallback SVG. */
.hub-ico .plogo, .brand-mark .plogo { width: 100%; height: 100%; object-fit: contain; display: block; border-radius: inherit; }
.plogo-fallback { display: none; }
.hub-ico:not([data-logo]) .plogo-fallback   { display: block; width: 25px; height: 25px; }
.brand-mark:not([data-logo]) .plogo-fallback { display: block; width: 18px; height: 18px; }
.hub-ico[data-logo]   { background: none; overflow: hidden; }
.brand-mark[data-logo]{ background: none; overflow: hidden; }

/* ---------------- Per-monitor nav ---------------- */
.nav-back    { display: inline-flex; align-items: center; gap: 6px; color: #cdd6e4;
               text-decoration: none; font-size: 13px; font-weight: 600; margin-right: 4px; }
.nav-back:hover { color: #fff; }
.nav-back svg { width: 16px; height: 16px; }

/* ---------------- Toolbar action buttons (New listing / Bulk listing) — refined pair ---------------- */
.tb-btn      { display: inline-flex; align-items: center; gap: 7px; font-family: inherit; font-weight: 600;
               font-size: 13.5px; line-height: 1; letter-spacing: .01em; white-space: nowrap; cursor: pointer;
               padding: 10px 16px; border-radius: 10px; border: 1px solid transparent;
               transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease, background .14s ease; }
.tb-btn svg  { width: 16px; height: 16px; }
.tb-btn:hover { transform: translateY(-1px); }
.tb-btn:active { transform: translateY(0); }
.tb-btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
/* Primary — New listing: filled green gradient with a soft coloured shadow. */
.tb-primary  { color: #fff; background: linear-gradient(135deg, #1fbe5b, #15803d);
               box-shadow: 0 2px 10px color-mix(in srgb, #16a34a 34%, transparent); }
.tb-primary:hover { box-shadow: 0 5px 16px color-mix(in srgb, #16a34a 44%, transparent); }
/* Secondary — Bulk listing: clean outlined card that lifts to blue on hover. */
.tb-ghost    { color: var(--ink-soft); background: var(--card); border-color: var(--border); box-shadow: var(--shadow-sm); }
.tb-ghost:hover { color: var(--blue-ink); border-color: var(--blue); box-shadow: var(--shadow-md); }
.tb-ghost svg { color: var(--blue); }

/* ---------------- FTN monitor content ---------------- */
.ftn-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
               max-width: 1180px; margin: 18px auto 0; padding: 0 18px; }
.ftn-toolbar input { flex: 1; min-width: 220px; padding: 9px 13px; border: 1px solid var(--border);
               border-radius: 9px; background: var(--card); color: var(--ink); font-family: inherit; font-size: 13.5px; }
.ftn-wrap    { max-width: 1180px; margin: 0 auto; padding: 20px 18px 60px; }
/* Each event is a clearly-framed card — a stronger border + shadow + a tinted header band
 * make the boundary between one event and the next obvious at a glance. */
.ftn-event   { background: var(--card); border: 2px solid var(--border); border-radius: 14px;
               box-shadow: var(--shadow-md); margin-bottom: 22px; overflow: hidden;
               transition: border-color .12s ease, box-shadow .12s ease; }
.ftn-event:hover { border-color: color-mix(in srgb, var(--blue) 45%, var(--border)); box-shadow: var(--shadow-lg, var(--shadow-md)); }
/* a little more air between events when grouped under a date header (FTN-scoped) */
.ftn-wrap .date-group-body { gap: 18px; padding: 12px 10px; }
.ftn-wrap .date-group-body .ftn-event { margin-bottom: 0; }
.ftn-evhead  { display: flex; align-items: center; gap: 12px; padding: 15px 18px;
               background: var(--surface); border-bottom: 2px solid var(--line); }
.ftn-evhead .ev-title { font-size: 15.5px; font-weight: 700; color: var(--ink); }
.ftn-evhead .ev-meta  { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.ftn-evhead .ev-floor { margin-left: auto; text-align: right; font-size: 12.5px; color: var(--ink-soft); white-space: nowrap; }
.ftn-evhead .ev-floor b { color: var(--green-ink); font-size: 15px; }
.ftn-del     { background: none; border: none; color: var(--faint); cursor: pointer; font-size: 15px; padding: 4px 6px; border-radius: 6px; }
.ftn-del:hover { background: var(--red-soft); color: var(--red-ink); }
.ftn-bb-del        { color: var(--red-ink); border-color: color-mix(in srgb, var(--red) 45%, var(--border)); }
.ftn-bb-del:hover  { background: var(--red-soft); color: var(--red-ink); }
.ftn-table   { width: 100%; border-collapse: collapse; font-size: 13px; table-layout: fixed; }
/* Every listing is ONE line (like LFT) — long values (category/block/split) truncate with an
   ellipsis rather than wrapping; the full text is on the cell's title tooltip. */
.ftn-table td { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ftn-tb-title { font-size: 14px; font-weight: 700; color: var(--ink); }
.ftn-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .03em;
               color: var(--muted); font-weight: 600; padding: 9px 18px; background: var(--surface); }
.ftn-table th.num, .ftn-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.ftn-table td { padding: 9px 18px; border-top: 1px solid var(--line); color: var(--ink); }
/* Status cell holds the LIVE/PAUSED pill + the position chip — give it room (tight padding,
   no clipping) so the rank (#4) is always shown, never cut to an ellipsis. */
.ftn-table td:nth-child(2) { padding-left: 12px; padding-right: 4px; overflow: visible; }
.ftn-table td:nth-child(2) .ftn-pos { margin-left: 5px; }
.ftn-table tr:hover td { background: var(--surface); }
.ftn-cheap   { font-weight: 700; color: var(--green-ink); white-space: nowrap; }
.ftn-price-cell { white-space: nowrap; }
.ftn-chip    { display: inline-block; font-size: 10.5px; font-weight: 700; border-radius: 999px;
               padding: 1px 8px; background: var(--blue-soft); color: var(--blue-ink); white-space: nowrap; }
.ftn-chip.hosp { background: var(--gold-soft); color: var(--amber-ink); }
/* Rules (⚙️) button — hover-revealed, like LFT's auto-price gear. When a rule is set it shows
   the minimum inline (⚙️€100) and stays visible + green, so the floor reads at a glance. */
.ftn-set-min { background: none; border: none; cursor: pointer; opacity: 0; font-size: 12px;
               margin-left: 4px; padding: 0; transition: opacity .12s; vertical-align: middle; white-space: nowrap; }
.ftn-table tr:hover .ftn-set-min { opacity: .55; }
.ftn-set-min:hover { opacity: 1; }
/* When a rule is set the gear stays visible with a subtle green ring — signals a rule exists
   WITHOUT showing the minimum number (which could be confused with the listed price). */
.ftn-set-min.has-rule { opacity: 1; background: var(--green-soft); border-radius: 5px; padding: 1px 3px; }
.ftn-table tr:hover .ftn-set-min.has-rule { opacity: 1; }
/* The price TEXT is the click-to-edit target now (the old ✏️ pencil is gone). */
.ftn-edit-price { cursor: pointer; border-bottom: 1px dashed transparent; }
.ftn-table tr:hover .ftn-edit-price { border-bottom-color: var(--border); }
.ftn-edit-price:hover { border-bottom-color: var(--green-ink); }
/* Market button stays visible — it's the "see the competitors" data button (always one click away). */
.ftn-market-btn { background: none; border: none; cursor: pointer; opacity: .5; font-size: 13px;
                  margin-left: 4px; padding: 0; transition: opacity .12s; vertical-align: middle; }
.ftn-table tr:hover .ftn-market-btn { opacity: .8; }
.ftn-market-btn:hover { opacity: 1; }
/* Trend (📈) button — same treatment as the market button. */
.ftn-trend-btn { background: none; border: none; cursor: pointer; opacity: .5; font-size: 13px;
                 margin-left: 4px; padding: 0; transition: opacity .12s; vertical-align: middle; }
.ftn-table tr:hover .ftn-trend-btn { opacity: .8; }
.ftn-trend-btn:hover { opacity: 1; }
/* Cheapest crown — a compact inline 👑 right after the price when I'm the category low. */
.ftn-crown   { font-size: 13px; vertical-align: middle; }
/* Price-position chip (mirrors LFT): #N/M rank, 👑 cheapest, 🔒 held-at-floor, 🔻 undercut. */
.ftn-pos     { display: inline-block; margin-left: 6px; font-size: 10px; font-weight: 700; white-space: nowrap;
               border-radius: 999px; padding: 1px 7px; background: var(--surface-2); color: var(--muted); vertical-align: middle; }
.ftn-pos.lead     { background: var(--green-soft); color: var(--green-ink); }
.ftn-pos.lock     { background: var(--amber-soft); color: var(--amber-ink); }
.ftn-pos.undercut { background: var(--red-soft);   color: var(--red-ink); }
/* Phase-2 enrichment pending — a pulsing skeleton instead of a blank cell while the throttled market loads. */
.ftn-pos.ftn-pos-loading { letter-spacing: 1px; color: var(--muted); opacity: .55; animation: ftnPulse 1.2s ease-in-out infinite; }
@keyframes ftnPulse { 0%,100% { opacity: .30; } 50% { opacity: .70; } }
/* While FTN is in a rate-limit (1015) backoff, dim the position chips so the stale prices read as "paused". */
body.ftn-cooling .ftn-pos { opacity: .45; filter: grayscale(0.4); }
/* Passive FTN rate-limit banner (no poll, client-side countdown only). */
.ftn-cooldown-banner { margin: 10px 16px 0; padding: 8px 14px; border-radius: 10px; font-size: 13px; font-weight: 600;
               background: var(--amber-soft); color: var(--amber-ink); border: 1px solid var(--amber-ink); }
/* A stale (>10 min) hydrated snapshot is dimmed until the live load replaces it — old prices never look current. */
body.ftn-stale-snap #ftnTab { opacity: .55; transition: opacity .2s ease; }
/* Same cue on EVERY platform (Or 2026-07-02): while a full load / scan is in flight, or the page was
   painted from a stale snapshot, the grid dims — grey = the system is busy; edit once it lifts. */
body.vg-stale-snap #vgTab { opacity: .55; transition: opacity .2s ease; }
body.page-loading #vgTab, body.page-loading #ftnTab, body.page-loading #otherTab { opacity: .55; transition: opacity .2s ease; }
/* Profit-per-ticket chip (when the rule carries a cost). */
.ftn-profit  { display: inline-block; margin-left: 6px; font-size: 10px; font-weight: 700; white-space: nowrap;
               border-radius: 999px; padding: 1px 7px; vertical-align: middle; }
.ftn-profit.pos { background: var(--green-soft); color: var(--green-ink); }
.ftn-profit.neg { background: var(--red-soft);   color: var(--red-ink); }
/* Event with a live listing being undercut — a red left accent so it stands out (mirrors LFT). */
.ftn-event.not-cheapest { border-color: color-mix(in srgb, var(--red) 40%, var(--border)); }
.ftn-event.not-cheapest .ftn-evhead { border-left: 3px solid var(--red); }
/* Inline-editable cells (category / block / qty / split) — click to edit in place. */
.ftn-ed      { cursor: pointer; }
.ftn-ed:hover { background: var(--surface); box-shadow: inset 0 0 0 1px var(--border); border-radius: 6px; }
.ftn-cell-input { width: 100%; max-width: 100%; box-sizing: border-box; padding: 3px 5px; border: 1px solid var(--blue);
                  border-radius: 6px; background: var(--card); color: var(--ink); font-family: inherit; font-size: 12.5px; }
/* Event cards inside a date-group sit flush — spacing comes from the group body's flex gap. */
.date-group-body .ftn-event { margin-bottom: 0; }
.ftn-min     { font-size: 10.5px; font-weight: 700; color: var(--amber-ink); cursor: pointer;
               margin-top: 3px; white-space: nowrap; }
.ftn-min:hover { text-decoration: underline; }
.ftn-status-toggle { cursor: pointer; }
.ftn-status-toggle:hover .ftn-chip { outline: 1px solid currentColor; outline-offset: 1px; }
.ftn-split-cell  { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.ftn-split-cell > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ftn-del-listing { background: none; border: none; cursor: pointer; opacity: 0; font-size: 12px;
                   padding: 0; transition: opacity .12s; flex-shrink: 0; }
.ftn-table tr:hover .ftn-del-listing { opacity: .5; }
.ftn-del-listing:hover { opacity: 1; }
.ftn-price-edit  { display: inline-flex; align-items: center; gap: 4px; justify-content: flex-end; }
.ftn-price-input { width: 72px; padding: 3px 6px; border: 1px solid var(--blue); border-radius: 6px;
                   background: var(--card); color: var(--ink); font-family: inherit; font-size: 12.5px; text-align: right; }
.ftn-table .sel-col { width: 36px; text-align: center; padding-left: 14px; padding-right: 6px; }
.ftn-table .sel-col input { width: 15px; height: 15px; cursor: pointer; accent-color: var(--blue); }
.ftn-empty   { text-align: center; color: var(--muted); padding: 60px 20px; }
.ftn-empty h3 { color: var(--ink); font-size: 17px; margin: 0 0 8px; }
.ftn-partial { font-size: 11.5px; color: var(--amber-ink); background: var(--amber-soft);
               border-radius: 7px; padding: 2px 9px; display: inline-block; }
.ftn-err     { color: var(--red-ink); font-size: 12.5px; padding: 12px 18px; }

/* auto-reprice results */
.rp-row      { display: grid; grid-template-columns: 1fr auto auto; gap: 8px 16px; align-items: center;
               padding: 9px 4px; border-top: 1px solid var(--line); }
.rp-row:first-child { border-top: none; }
.rp-evt      { font-size: 13px; font-weight: 600; color: var(--ink); }
.rp-price    { font-size: 13.5px; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.rp-price b  { color: var(--green-ink); }
.rp-meta     { font-size: 11.5px; color: var(--muted); }
.rp-badge    { font-size: 10.5px; font-weight: 700; border-radius: 999px; padding: 1px 8px; margin-left: 4px; white-space: nowrap; }
.rp-change   { background: var(--blue-soft);  color: var(--blue-ink); }
.rp-ok       { background: var(--green-soft); color: var(--green-ink); }
.rp-same     { background: var(--surface-2);  color: var(--muted); }
.rp-skip     { background: var(--amber-soft); color: var(--amber-ink); }
.rp-err      { background: var(--red-soft);   color: var(--red-ink); }
.rp-warn     { background: var(--amber-soft); color: var(--amber-ink); }

/* add-listing event search rows */
.es-row      { display: flex; flex-direction: column; gap: 1px; padding: 8px 10px; cursor: pointer;
               border-radius: 8px; }
.es-row:hover { background: var(--surface-2); }
.es-name     { font-size: 13px; font-weight: 600; color: var(--ink); }

/* ---------------- Viagogo monitor (step 2: read-only inventory) ---------------- */
.vg-event     { background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
                box-shadow: var(--shadow-sm); overflow: hidden; }
.vg-evt-head  { display: flex; flex-wrap: nowrap; align-items: center; gap: 6px 12px;
                padding: 12px 16px; background: var(--card); border-bottom: 1px solid var(--border); }
.vg-evt-main  { display: flex; flex-direction: column; gap: 2px; flex: 1 1 auto; min-width: 0; }
/* keep the countdown + action buttons on ONE line (they used to wrap below on the wider "TOMORROW" chip) */
.vg-evt-head > .btn-tiny, .vg-evt-head > .evt-countdown { flex: 0 0 auto; }
.vg-evt-title { font-size: 14.5px; font-weight: 700; color: var(--ink); line-height: 1.25;
                white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vg-evt-sub   { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.vg-evt-comp  { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 600;
                color: var(--ink-soft); background: var(--surface-2); border-radius: 999px; padding: 1px 9px; white-space: nowrap; }
.vg-evt-meta  { font-size: 12px; color: var(--muted); }
.vg-evt-crests { display: inline-flex; gap: 3px; align-items: center; flex: 0 0 auto; }
.vg-evt-crests:empty { display: none; }
.vg-evt-crests .team-logo { width: 34px; height: 34px; font-size: 11.5px; flex: 0 0 auto; }
/* emphasise + enlarge the per-event "time until kickoff" countdown on viagogo */
.vg-evt-head .evt-countdown { font-size: 14.5px; font-weight: 800; padding: 7px 15px;
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--blue-ink) 24%, transparent); }
.vg-evt-head .evt-countdown .cd-val { font-size: 15.5px; font-weight: 800; letter-spacing: .2px; }
.vg-evt-head .evt-countdown.is-today { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--red) 35%, transparent); }
.vg-evt-head .evt-countdown.is-soon  { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--amber-ink) 30%, transparent); }
.vg-evt-count { margin-left: auto; font-size: 11px; font-weight: 600; color: var(--ink-soft);
                background: var(--surface-2); border-radius: 999px; padding: 2px 10px; white-space: nowrap; }
.vg-table     { width: 100%; border-collapse: collapse; }
.vg-table th  { text-align: left; font-size: 11px; font-weight: 600; text-transform: uppercase;
                letter-spacing: .03em; color: var(--muted); padding: 8px 16px; border-bottom: 1px solid var(--border); }
.vg-table td  { padding: 10px 16px; font-size: 13px; color: var(--ink); border-top: 1px solid var(--border); }
.vg-table tbody tr:first-child td { border-top: none; }
.vg-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.vg-row:hover td { background: var(--surface); }

/* ---- inventory listings framed as separated cards (scoped → market modal table unaffected) ---- */
.vg-event .vg-table { border-collapse: separate; border-spacing: 0 7px; margin: 4px 0 8px; }
.vg-event .vg-table th { border-bottom: none; padding: 8px 16px 0; }
.vg-event .vg-table td { background: var(--card); border-top: 1px solid var(--border);
                         border-bottom: 1px solid var(--border); padding: 12px 16px; transition: background .12s ease; }
.vg-event .vg-table td:first-child { border-left: 1px solid var(--border);
                         border-top-left-radius: 10px; border-bottom-left-radius: 10px; }
.vg-event .vg-table td:last-child  { border-right: 1px solid var(--border);
                         border-top-right-radius: 10px; border-bottom-right-radius: 10px; }
.vg-event .vg-table tbody tr:first-child td { border-top: 1px solid var(--border); }   /* every row fully framed */
.vg-event .vg-row:hover td { background: var(--surface-2); }
.vg-event .vg-row:hover td:first-child { box-shadow: inset 3px 0 0 -1px var(--accent, #4f7cff); }
.vg-sec       { font-weight: 600; color: var(--ink); }
.vg-type      { color: var(--ink-soft); font-size: 12.5px; }
.vg-price     { font-weight: 700; color: var(--ink); }
.vg-muted     { color: var(--muted); }
.vg-pill      { display: inline-block; max-width: 260px; overflow: hidden; text-overflow: ellipsis;
                white-space: nowrap; vertical-align: bottom; font-size: 11px; font-weight: 600;
                border-radius: 999px; padding: 2px 10px; }

/* --- Viagogo market modal (step 3) --- */
.vg-mkt-summary { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.vg-mkt-stat  { font-size: 12px; color: var(--ink-soft); background: var(--surface);
                border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px; }
.vg-mkt-stat b { color: var(--ink); }
.vg-mine-stat { background: var(--amber-soft); border-color: transparent; color: var(--amber-ink); }
.vg-mine-stat b { color: var(--amber-ink); }
.vg-mkt-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.vg-mine-only { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-soft); cursor: pointer; }
.vg-mkt-body  { max-height: 56vh; overflow: auto; border: 1px solid var(--border); border-radius: 10px; }
.vg-mkt-table th { position: sticky; top: 0; z-index: 1; background: var(--surface); }
.vg-mine-row td { background: var(--amber-soft) !important; }
.vg-mine-tag  { display: inline-block; font-size: 9.5px; font-weight: 800; letter-spacing: .04em;
                background: var(--amber-ink); color: #fff; border-radius: 4px; padding: 0 5px; margin-left: 4px; vertical-align: middle; }
.vg-notes     { display: flex; flex-wrap: wrap; gap: 4px; }
.vg-note      { font-size: 10.5px; color: var(--amber-ink); background: var(--amber-soft);
                border-radius: 5px; padding: 1px 7px; max-width: 230px; overflow: hidden;
                text-overflow: ellipsis; white-space: nowrap; }
.vg-sales-note { font-size: 11.5px; color: var(--muted); padding: 10px 4px 2px; }
.vg-create-evt { background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
                 padding: 9px 13px; margin-bottom: 12px; font-size: 13.5px; color: var(--ink); }

/* --- Viagogo history rows --- */
.hist-row     { display: flex; align-items: flex-start; gap: 12px; padding: 9px 4px; border-top: 1px solid var(--border); }
.hist-row:first-child { border-top: none; }
.hist-act     { flex: 0 0 auto; font-size: 10.5px; font-weight: 700; border-radius: 999px; padding: 2px 9px; white-space: nowrap; }
.hist-main    { flex: 1 1 auto; min-width: 0; }
.hist-evt     { font-size: 13px; font-weight: 600; color: var(--ink); }
.hist-det     { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.hist-when    { flex: 0 0 auto; font-size: 11px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }

/* --- Viagogo compact mode (C) --- */
.vg-compact .vg-table td      { padding: 5px 16px; font-size: 12px; }
.vg-compact .vg-table th      { padding: 5px 16px; }
.vg-compact .vg-evt-head      { padding: 8px 16px; }
.vg-compact .vg-event .vg-table { border-spacing: 0 4px; margin: 2px 0 5px; }
.vg-compact .vg-event .vg-table th { padding: 5px 16px 0; }
.vg-compact .date-group-body  { gap: 10px; padding: 8px 10px; }
.btn-icon.active              { background: var(--surface-2); color: var(--ink); }

/* --- Viagogo freshly-created row highlight --- */
.vg-just-created td             { background: var(--green-soft) !important; }   /* beat the framed-row td bg */
.vg-just-created td:first-child { box-shadow: inset 3px 0 0 var(--green-ink); }
.vg-new-tag { display: inline-block; font-size: 9.5px; font-weight: 800; letter-spacing: .04em;
              background: var(--green-ink); color: #fff; border-radius: 4px; padding: 0 5px;
              margin-right: 3px; vertical-align: middle; }

/* --- Viagogo repricer (step 4): gear, min-floor, profit, inline edit --- */
.vg-price-cell { white-space: nowrap; }
.vg-ed         { cursor: pointer; border-radius: 5px; padding: 1px 4px; }
.vg-ed:hover   { background: var(--surface-2); outline: 1px dashed var(--border); }
.vg-ed-input   { width: 86px; font-size: 12.5px; padding: 2px 5px; border: 1px solid var(--blue);
                 border-radius: 5px; background: var(--card); color: var(--ink);
                 font-variant-numeric: tabular-nums; text-align: right; }
.vg-gear       { background: none; border: none; cursor: pointer; font-size: 13px; color: var(--muted);
                 opacity: .5; padding: 1px 4px; border-radius: 999px; vertical-align: middle; line-height: 1; }
.vg-gear:hover { opacity: 1; background: var(--surface-2); }
.vg-gear.has-rule { opacity: 1; color: var(--green-ink); box-shadow: inset 0 0 0 1.5px var(--green-ink); }
.vg-lmkt       { background: none; border: none; cursor: pointer; font-size: 12.5px; opacity: .55;
                 padding: 1px 3px; border-radius: 6px; vertical-align: middle; line-height: 1; }
.vg-lmkt:hover { opacity: 1; background: var(--surface-2); }
.vg-act        { background: none; border: none; cursor: pointer; font-size: 12px; opacity: .5;
                 padding: 1px 4px; border-radius: 6px; vertical-align: middle; line-height: 1; margin-left: 2px; }
.vg-act:hover  { opacity: 1; background: var(--surface-2); }
.vg-del:hover  { background: var(--red-soft); }
.vg-pause:hover, .vg-publish:hover { background: var(--green-soft); }
.vg-hist-evt   { font-weight: 600; color: var(--ink-soft); background: var(--surface-2);
                 border-radius: 999px; padding: 1px 8px; margin-left: 4px; }
.vg-hist-evt button { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 11px; padding: 0 0 0 4px; }
.vg-hist-evt button:hover { color: var(--red-ink); }
.vg-min        { font-size: 10.5px; font-weight: 700; color: var(--amber-ink); background: var(--amber-soft);
                 border-radius: 5px; padding: 0 5px; margin-left: 5px; white-space: nowrap; vertical-align: middle; }
.vg-profit     { font-size: 10.5px; font-weight: 700; border-radius: 5px; padding: 0 5px; }
.vg-profit.pos { color: var(--green-ink); background: var(--green-soft); }
.vg-profit.neg { color: var(--red-ink);   background: var(--red-soft); }

/* inline market-position chip (lazy) */
.vg-pos        { font-size: 10.5px; font-weight: 800; border-radius: 5px; padding: 0 5px; margin-left: 5px;
                 white-space: nowrap; vertical-align: middle; letter-spacing: .01em; }
.vg-pos-top    { color: var(--green-ink); background: var(--green-soft); }
.vg-pos-mid    { color: var(--red-ink);   background: var(--red-soft); }
.vg-pos-solo   { color: var(--muted);     background: var(--surface-2); font-weight: 700; }
.vg-pos-na     { color: var(--amber-ink);  background: var(--amber-soft); font-weight: 700; opacity: .85; }
.vg-ltrend     { background: none; border: none; cursor: pointer; font-size: 12.5px; opacity: .55;
                 padding: 1px 3px; border-radius: 6px; vertical-align: middle; line-height: 1; }
.vg-ltrend:hover { opacity: 1; background: var(--surface-2); }

/* price-trend chart modal */
.vg-trend-chart { margin: 6px 0 10px; min-height: 188px; display: flex; align-items: center; justify-content: center; }
.vg-trend-svg   { width: 100%; height: 188px; overflow: visible; }
.vg-tg-grid     { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 3; }
.vg-tg-yl, .vg-tg-xl { fill: var(--muted); font-size: 10px; }
.vg-tg-yl       { text-anchor: end; }
.vg-tg-line     { fill: none; stroke: var(--accent, #4f7cff); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.vg-tg-area     { fill: var(--accent, #4f7cff); opacity: .10; stroke: none; }
.vg-tg-dot      { fill: var(--accent, #4f7cff); }
.vg-trend-stats { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-soft); }
.vg-trend-stats b { color: var(--ink); }
.vg-trend-delta.pos { color: var(--green-ink); font-weight: 700; }
.vg-trend-delta.neg { color: var(--red-ink);   font-weight: 700; }

/* bulk-select checkboxes + floating action bar */
.vg-sel, .vg-sel-all { vertical-align: middle; cursor: pointer; accent-color: var(--accent, #4f7cff); margin: 0 2px 0 0; }
.vg-row-sel td { background: var(--accent-soft, rgba(79,124,255,.10)) !important; }
.vg-bulkbar {
  position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 60;
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  background: var(--surface, #fff); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.18);
}
.vg-bulkbar[hidden] { display: none; }   /* author display:flex would otherwise override [hidden] */
.vg-evt-add { color: var(--green-ink); font-weight: 700; }
.vg-evt-add:hover { background: var(--green-soft); border-color: var(--green-ink); }
.vg-bb-count { font-size: 13px; color: var(--ink-soft); }
.vg-bb-count b { color: var(--ink); font-size: 14px; }
.vg-bb-sep   { width: 1px; align-self: stretch; background: var(--border); margin: 0 2px; }
.vg-bb-btn[disabled] { opacity: .4; cursor: not-allowed; }
.vg-bb-del:not([disabled]):hover { background: var(--red-soft); color: var(--red-ink); }
.vg-bb-clear { background: none; border: none; cursor: pointer; color: var(--muted); font-size: 14px; padding: 2px 6px; }
.vg-bb-clear:hover { color: var(--red-ink); }
.vg-edit-note { margin: 10px 0 2px; padding: 7px 10px; background: var(--surface-2); border-radius: 8px; font-size: 11.5px; }
.vg-edit-warn { margin: 6px 0 2px; padding: 6px 10px; background: var(--amber-soft); color: var(--amber-ink); border-radius: 8px; font-size: 11.5px; }
.vg-split-tag { display: inline-block; font-size: 9.5px; font-weight: 800; letter-spacing: .03em; color: var(--blue-ink); background: var(--blue-soft); border-radius: 5px; padding: 0 5px; margin-left: 4px; }
.vg-sync-tag { display: inline-block; font-size: 9.5px; font-weight: 800; letter-spacing: .03em; color: var(--amber-ink); background: var(--amber-soft); border-radius: 5px; padding: 0 5px; margin-left: 4px; }
.vg-split-row td { background: color-mix(in srgb, var(--blue-soft) 55%, transparent) !important; }
.vg-mkt-note { margin: 8px 2px 2px; padding: 7px 10px; background: var(--surface-2); border-radius: 8px; font-size: 11px; color: var(--ink-soft); line-height: 1.5; }
.bl-nosec-tag { font-size: 10px; font-weight: 700; color: var(--muted); background: var(--surface-2); border-radius: 5px; padding: 0 5px; white-space: nowrap; }
.bl-chip-nosec { box-shadow: inset 0 0 0 1.5px var(--border); }
.bl-fail-tag { font-size: 10px; font-weight: 800; color: var(--red-ink); background: var(--red-soft); border-radius: 5px; padding: 0 5px; white-space: nowrap; }
.bl-chip-fail { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--red-ink) 35%, transparent); }

/* ============================================================================
   StubHub Sales Pro monitor (stubhub.html / stubhub.js) — 4th marketplace
   ========================================================================== */
.sh-body { --sh: #6b1d7b; --sh-2: #9b30b8; }
.sh-body .ver { background: color-mix(in srgb, var(--sh) 16%, transparent); color: var(--sh); }
[data-theme="dark"] .sh-body .ver { color: #e6a9f4; }

/* StubHub identity: the green accent backgrounds become purple (scoped to .sh-body only,
   so viagogo / LFT / FTN keep their green). */
.sh-body .status-seg .seg-btn[data-status="live"].active { background: var(--sh); }
.sh-body .tb-primary { background: linear-gradient(135deg, var(--sh-2), var(--sh)); }
.sh-body .tb-primary:hover { box-shadow: 0 5px 16px color-mix(in srgb, var(--sh) 44%, transparent); }
/* keep the New-listing icon/text readable on purple */
.sh-body .tb-primary svg { color: #fff; }

.sh-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px;
  max-width: 1180px; margin: 18px auto 6px; padding: 0 22px; }
.sh-stat { background: var(--card); border: 1px solid var(--border); border-radius: 14px;
  padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; box-shadow: var(--shadow-xs); }
.sh-stat-num { font-size: 26px; font-weight: 800; color: var(--ink); line-height: 1.1; }
.sh-stat-lbl { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.sh-stat-cur .sh-stat-num { color: var(--sh); }

.sh-tabs { display: flex; gap: 4px; max-width: 1180px; margin: 14px auto 0; padding: 0 22px;
  border-bottom: 1px solid var(--border); }
.sh-tab { appearance: none; background: none; border: none; cursor: pointer;
  font: inherit; font-weight: 700; color: var(--muted); padding: 10px 16px; border-radius: 10px 10px 0 0;
  border-bottom: 2.5px solid transparent; margin-bottom: -1px; }
.sh-tab:hover { color: var(--ink); background: var(--surface-2); }
.sh-tab.active { color: var(--sh); border-bottom-color: var(--sh); }

.sh-main { max-width: 1180px; margin: 0 auto; padding: 18px 22px 60px; }
.sh-panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.sh-panel-head h2 { font-size: 18px; font-weight: 800; color: var(--ink); margin: 0; }
.sh-muted { color: var(--muted); font-size: 13px; }
.sh-link { color: var(--sh); font-weight: 700; text-decoration: none; }
.sh-link:hover { text-decoration: underline; }
.sh-check { font-size: 13px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }

.sh-empty { background: var(--card); border: 1px dashed var(--border); border-radius: 14px;
  padding: 30px 22px; text-align: center; color: var(--muted); }
.sh-empty-cta p { margin: 4px 0; }
.sh-empty-cta strong { color: var(--ink); font-size: 15px; }
.sh-err { color: var(--red-ink); border-color: color-mix(in srgb, var(--red-ink) 35%, transparent); }

.sh-event { background: var(--card); border: 1px solid var(--border); border-radius: 14px;
  padding: 14px 16px; margin-bottom: 12px; box-shadow: var(--shadow-xs); }
.sh-event-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.sh-event-name { font-weight: 800; color: var(--ink); font-size: 15px; }

.sh-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.sh-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .04em;
  color: var(--muted); font-weight: 700; padding: 6px 10px; border-bottom: 1px solid var(--border); }
.sh-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); color: var(--ink); }
.sh-table tr:last-child td { border-bottom: none; }
.sh-num { text-align: right; font-variant-numeric: tabular-nums; }
.sh-ev { font-weight: 600; }
.sh-pill { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted); }
.sh-pill-on { background: var(--green-soft); color: var(--green-ink); }

.sh-search-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; align-items: center; }
.sh-search-bar .other-search { flex: 1 1 280px; min-width: 220px; }
.sh-search-table th, .sh-search-table td { white-space: nowrap; }
.sh-search-table .sh-ev { white-space: normal; }

@media (max-width: 760px) {
  .sh-stats { grid-template-columns: repeat(2, 1fr); }
  .sh-stat-cur { display: none; }
}

/* StubHub create-listing modal */
.shc-results { margin-top: 10px; max-height: 320px; overflow-y: auto; }
.shc-ev-row { padding: 9px 12px; border: 1px solid var(--border); border-radius: 10px; margin-bottom: 6px; cursor: pointer; background: var(--card); }
.shc-ev-row:hover { border-color: var(--sh, #6b1d7b); background: var(--surface-2); }
.shc-ev-name { font-weight: 700; color: var(--ink); font-size: 14px; }
.shc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 16px; margin: 14px 0 10px; }
.shc-grid > label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.shc-grid input, .shc-grid select { font: inherit; font-weight: 500; color: var(--ink); padding: 7px 9px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); }
.shc-grid input:focus, .shc-grid select:focus { outline: 2px solid var(--sh, #6b1d7b); outline-offset: -1px; }
.shc-grid input[readonly] { background: var(--surface-2); color: var(--muted); }
.shc-opt { font-weight: 400; color: var(--faint); }
.shc-toggle { flex-direction: row !important; align-items: center; gap: 7px !important; font-size: 13px !important; color: var(--ink) !important; padding-top: 18px; }
.shc-toggle input { width: auto; }
.shc-pub { color: var(--red-ink) !important; font-weight: 700 !important; }
.shc-allin { font-size: 13px; color: var(--sh, #6b1d7b); font-weight: 700; margin: 2px 0 10px; min-height: 18px; }
.shc-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 8px; }
.modal-x { position: absolute; top: 14px; right: 16px; background: none; border: none; font-size: 18px; color: var(--muted); cursor: pointer; }
@media (max-width: 720px) { .shc-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Connection badge: Connected / Rate-limited / Disconnected ---------- */
.conn-badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 9px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap; line-height: 1.6;
  border: 1px solid var(--border); background: var(--surface); color: var(--muted);
}
.conn-badge .conn-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--muted); }
.conn-badge[data-state="connected"]    { color: var(--green-ink); border-color: color-mix(in srgb, var(--green) 45%, var(--border)); background: var(--green-soft); }
.conn-badge[data-state="connected"] .conn-dot { background: var(--green); box-shadow: 0 0 0 3px color-mix(in srgb, var(--green) 22%, transparent); }
/* Connected but the background scan loop has STALLED — session fine, nothing scanning (Or 2026-07-03).
   Amber the whole badge so a green-looking "Connected" can never hide a dead loop. */
.conn-badge[data-state="connected"][data-live="idle"] { color: var(--amber-ink); border-color: color-mix(in srgb, var(--amber) 50%, var(--border)); background: var(--amber-soft); }
.conn-badge[data-state="connected"][data-live="idle"] .conn-dot { background: var(--amber); box-shadow: 0 0 0 3px color-mix(in srgb, var(--amber) 22%, transparent); animation: conn-pulse 1.4s ease-in-out infinite; }
.conn-badge[data-state="cooldown"]     { color: var(--amber-ink); border-color: color-mix(in srgb, var(--amber) 45%, var(--border)); background: var(--amber-soft); }
.conn-badge[data-state="cooldown"] .conn-dot { background: var(--amber); }
.conn-badge[data-state="disconnected"] { color: var(--red-ink); border-color: color-mix(in srgb, var(--red) 45%, var(--border)); background: var(--red-soft); }
.conn-badge[data-state="disconnected"] .conn-dot { background: var(--red); }
.conn-badge[data-state="connecting"]   { color: var(--muted); }
.conn-badge[data-state="connecting"] .conn-dot { background: var(--muted); animation: conn-pulse 1s ease-in-out infinite; }
@keyframes conn-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
.conn-reconnect {
  margin-left: 3px; padding: 1px 8px; font-size: 11px; font-weight: 700; cursor: pointer;
  border: 1px solid currentColor; border-radius: 999px; background: transparent; color: inherit;
}
.conn-reconnect:hover { background: color-mix(in srgb, currentColor 14%, transparent); }

/* Hub card status: a Live/Offline pill + a "Last scan …" line (replaces the old corner status dot) */
.hub-status { margin-top: 14px; display: flex; flex-direction: column; gap: 5px; align-items: flex-start; }
.hub-status .hub-badge { margin-top: 0; display: inline-flex; align-items: center; gap: 6px; }
.hub-badge.online::before, .hub-badge.offline::before, .hub-badge.pending::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none;
}
.hub-badge.online  { background: var(--green-soft); color: var(--green-ink); }
.hub-badge.offline { background: var(--red-soft);   color: var(--red-ink); }
.hub-badge.pending { background: var(--surface);    color: var(--muted); border: 1px solid var(--border); }
.hub-lastscan { font-size: 11px; color: var(--ink-soft); line-height: 1.45; }
.hub-lastscan .ls-rel { font-weight: 600; color: var(--ink); }

/* Shared top progress bar — connect/login (shell.js) + scan/reprice (app.js). Shows % + stage + est. */
#gett-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 100001; pointer-events: none;
  opacity: 0; transition: opacity .25s ease; }
#gett-progress.show { opacity: 1; }
#gett-progress .gp-fill { height: 100%; width: 0; border-radius: 0 2px 2px 0;
  background: linear-gradient(90deg, var(--blue), var(--green));
  box-shadow: 0 0 10px color-mix(in srgb, var(--blue) 65%, transparent); transition: width .55s ease; }
#gett-progress .gp-label { position: fixed; top: 11px; left: 50%; transform: translateX(-50%);
  background: var(--card); color: var(--ink); border: 1px solid var(--border); border-radius: 999px;
  padding: 5px 14px; font-size: 12px; font-weight: 600; white-space: nowrap; box-shadow: var(--shadow-md); }

/* ---------- Elegant centered confirm / alert dialog (replaces native confirm/alert) ---------- */
.ui-dialog-overlay {
  position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center;
  padding: 24px; background: rgba(15, 23, 42, .5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  opacity: 0; transition: opacity .18s ease;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
.ui-dialog-overlay.show { opacity: 1; }
.ui-dialog {
  width: min(420px, 100%); background: var(--card); color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--border) 60%, transparent); border-radius: 18px;
  box-shadow: 0 30px 70px -20px rgba(2, 6, 23, .55), 0 8px 24px -12px rgba(2, 6, 23, .35);
  padding: 26px 26px 20px; transform: translateY(10px) scale(.96); opacity: 0;
  transition: transform .22s cubic-bezier(.2, .9, .25, 1), opacity .2s ease;
}
.ui-dialog-overlay.show .ui-dialog { transform: translateY(0) scale(1); opacity: 1; }
.ui-dialog-title { font-size: 17px; font-weight: 700; letter-spacing: -.015em; line-height: 1.3; margin: 0 0 9px; }
.ui-dialog.is-danger .ui-dialog-title { color: var(--red-ink); }
.ui-dialog-msg { font-size: 13.5px; line-height: 1.6; color: var(--muted); white-space: pre-line; margin: 0 0 24px; }
.ui-dialog-actions { display: flex; justify-content: flex-end; gap: 10px; }
.ui-dlg-btn {
  font-family: inherit; font-size: 13.5px; font-weight: 600; letter-spacing: -.005em; cursor: pointer;
  padding: 9px 18px; border-radius: 11px; border: 1px solid transparent;
  transition: background .14s ease, box-shadow .16s ease, transform .07s ease, border-color .14s ease;
}
.ui-dlg-btn:active { transform: translateY(1px); }
.ui-dlg-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 35%, transparent); }
.ui-dlg-cancel { background: var(--surface); color: var(--ink); border-color: var(--border); }
.ui-dlg-cancel:hover { background: var(--surface-2); }
.ui-dlg-primary { background: var(--blue); color: #fff; }
.ui-dlg-primary:hover { background: color-mix(in srgb, var(--blue) 86%, #000); box-shadow: 0 8px 20px -6px color-mix(in srgb, var(--blue) 55%, transparent); }
.ui-dlg-danger { background: var(--red); color: #fff; }
.ui-dlg-danger:hover { background: color-mix(in srgb, var(--red) 86%, #000); box-shadow: 0 8px 20px -6px color-mix(in srgb, var(--red) 55%, transparent); }
/* Rich-content confirm: a tidy key/value table + a publish/live warning row. */
.ui-dialog-msg .ui-confirm-table { width: 100%; border-collapse: collapse; font-size: 13px; margin: 2px 0 0; }
.ui-confirm-table th { text-align: left; font-weight: 500; color: var(--muted); padding: 7px 16px 7px 0; white-space: nowrap; vertical-align: top; }
.ui-confirm-table td { padding: 7px 0; font-weight: 600; color: var(--ink); text-align: right; }
.ui-confirm-table tr + tr th, .ui-confirm-table tr + tr td { border-top: 1px solid color-mix(in srgb, var(--border) 60%, transparent); }
.ui-confirm-warn { margin-top: 16px; padding: 9px 12px; border-radius: 10px; font-size: 12.5px; font-weight: 600;
  background: var(--amber-soft); color: var(--amber-ink); display: flex; align-items: center; gap: 7px; }

/* MULTI-ARENA position chips (FTN, 2026-07-02): one mini-chip per block size the listing sells */
.ftn-pos-multi { display: inline-flex; gap: 3px; margin-left: 6px; vertical-align: middle; }
.ftn-pos-multi .ftn-pos { margin-left: 0; }
/* Market modal: quick-switch buttons between my arenas */
.lm-mysizes { display: inline-flex; align-items: center; gap: 4px; margin-left: 8px; font-size: 11px; color: var(--muted); }
.lm-size-btn { padding: 2px 8px; border: 1px solid var(--border); border-radius: 999px; background: var(--card);
               color: var(--text); font-size: 11px; font-weight: 600; cursor: pointer; }
.lm-size-btn:hover { border-color: var(--accent, #2563eb); }
.lm-size-btn.active { background: var(--accent, #2563eb); border-color: var(--accent, #2563eb); color: #fff; }

/* POSITION column (FTN, 2026-07-02): labeled per-arena chips — "Pair 👑 · 4 tog #3" */
.ftn-pos-cell { white-space: nowrap; }
.ftn-pos-cell .ftn-pos, .ftn-pos-cell .ftn-pos-multi { margin-left: 0; }
.ftn-pos-size { display: inline-block; margin-right: 3px; padding: 0 4px; border-radius: 5px;
                background: rgba(15, 23, 42, .10); font-size: 9px; font-weight: 800;
                text-transform: uppercase; letter-spacing: .3px; opacity: .8; }

/* Emphasis on the key row fields (Or 2026-07-02): category, quantity and price pop at a glance */
.ftn-table td:nth-child(2) { font-weight: 700; }                      /* category name */
.ftn-table td:nth-child(4) { font-weight: 800; font-size: 12.5px; }   /* quantity */
.ftn-cheap { font-weight: 800; font-size: 13px; }                     /* price (keeps its green ink) */

/* Min-price tag under the price (Or 2026-07-02): the rule's floor is visible at a glance */
.ftn-price-stack { display: inline-flex; flex-direction: column; align-items: flex-end; vertical-align: middle; }
.ftn-min-tag { font-size: 9.5px; font-weight: 600; color: var(--muted); line-height: 1.25; white-space: nowrap; }

/* Bigger reading font + bold table headers (Or 2026-07-02) */
.ftn-table { font-size: 14px; }
.ftn-table th { font-weight: 800; }
.ftn-evhead .ev-title { font-size: 16.5px; }
.ftn-evhead .ev-meta { font-size: 13px; }
/* Away-team crest after the away team's name — UNIFORM size, centered to the text line */
.ftn-evhead .ev-title { display: flex; align-items: center; gap: 8px; }
.ftn-evhead .ev-title .team-logo, .ftn-evhead .ev-title .team-logo.has-img {
  width: 20px; height: 20px; min-width: 20px; flex-shrink: 0;
  font-size: 8px; margin-left: 0;
}
/* Colored date-group headers (FTN): today=red, tomorrow=yellow, this week=green, rest=blue family */
.ftn-wrap .date-group-header.is-today     { background: var(--red-soft);   color: var(--red-ink); }
.ftn-wrap .date-group-header.is-soon      { background: var(--amber-soft); color: var(--amber-ink); }
.ftn-wrap .date-group-header.is-week      { background: var(--green-soft); color: var(--green-ink); }
.ftn-wrap .date-group-header.is-month     { background: color-mix(in srgb, #3b82f6 16%, var(--card));
                                            color: color-mix(in srgb, #2563eb 80%, var(--ink)); }
.ftn-wrap .date-group-header.is-nextmonth { background: color-mix(in srgb, #6366f1 16%, var(--card));
                                            color: color-mix(in srgb, #4f46e5 80%, var(--ink)); }
.ftn-wrap .date-group-header.is-later     { background: color-mix(in srgb, #06b6d4 14%, var(--card));
                                            color: color-mix(in srgb, #0e7490 80%, var(--ink)); }
.ftn-wrap .date-group-header.is-other     { background: var(--surface); }
/* Min-price tag — larger, readable (Or 2026-07-02: 9.5px was far too small) */
.ftn-min-tag { font-size: 12px; font-weight: 700; }

/* ==== StubHub/viagogo (vg-clone) design ports (Or 2026-07-03) ==== */
/* Multi-arena position chips */
.vg-pos-multi { display: inline-flex; gap: 3px; vertical-align: middle; }
.vg-pos-multi .vg-pos { margin-left: 0; }
/* Colored date-group headers — GENERIC (all monitor pages): today=red, tomorrow=yellow,
   this week=green, rest=blue family. Matches the FTN/LFT scheme exactly. */
.date-group-header.is-today     { background: var(--red-soft);   color: var(--red-ink); }
.date-group-header.is-soon      { background: var(--amber-soft); color: var(--amber-ink); }
.date-group-header.is-week      { background: var(--green-soft); color: var(--green-ink); }
.date-group-header.is-month     { background: color-mix(in srgb, #3b82f6 16%, var(--card));
                                  color: color-mix(in srgb, #2563eb 80%, var(--ink)); }
.date-group-header.is-nextmonth { background: color-mix(in srgb, #6366f1 16%, var(--card));
                                  color: color-mix(in srgb, #4f46e5 80%, var(--ink)); }
.date-group-header.is-later     { background: color-mix(in srgb, #06b6d4 14%, var(--card));
                                  color: color-mix(in srgb, #0e7490 80%, var(--ink)); }
.date-group-header.is-other     { background: var(--surface); }
/* Bigger reading font + bold headers + field emphasis (vg tables = StubHub + viagogo) */
.vg-table { font-size: 14px; }
.vg-table th { font-weight: 800; }
.vg-sec { font-weight: 700; }
.vg-price { font-weight: 800; font-size: 13.5px; }

/* StubHub table restructure (Or 2026-07-03: FTN-style — Category · Block · Qty · Split) */
.vg-block, .vg-split-cell { font-size: 12.5px; color: var(--muted); white-space: nowrap; }

/* StubHub table (Or 2026-07-03): centered Price, dedicated Position column, LFT-sized icons */
.vg-table th.ctr, .vg-table td.ctr { text-align: center; }
.vg-price-cell .ftn-price-stack { align-items: center; }
.vg-pos-cell { white-space: nowrap; }
.vg-act, .vg-lmkt, .vg-ltrend, .vg-gear { font-size: 13px; line-height: 1; padding: 2px 5px; border-radius: 6px; }

/* Countdown + date-line refresh (Or 2026-07-03) — FTN + vg pages */
.ftn-evhead .ev-meta { font-size: 13.5px; color: var(--ink-soft); font-weight: 500; }
.vg-evt-sub .vg-evt-meta { font-size: 13px; color: var(--ink-soft); }
.evt-date-str { font-weight: 800; color: var(--ink); font-size: 13.5px; letter-spacing: .1px; white-space: nowrap; }

/* Rank-tone backgrounds for position chips (Or 2026-07-03): #1 green · #2–5 amber · #6+ red.
   Each arena is colored by ITS OWN rank (green in singles + red in pairs on the same listing is normal). */
.pos-t-green { background: var(--green-soft) !important; color: var(--green-ink) !important; }
.pos-t-amber { background: var(--amber-soft) !important; color: var(--amber-ink) !important; }
.pos-t-red   { background: var(--red-soft)   !important; color: var(--red-ink)   !important; }
/* Emphasized minimum-price tag (Or 2026-07-03): gold pill so a set floor is obvious at a glance */
.ftn-min-tag { color: var(--amber-ink); background: var(--amber-soft); border-radius: 5px; padding: 0 5px; }

/* Buyer-facing visibility chip (viagogo, Or 2026-07-03): distinguishes a truly on-sale LIVE listing
   from one that's published while its event is still "On sale soon" (0% visibility). */
.vg-vis { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px;
          font-size: 10.5px; font-weight: 700; white-space: nowrap; vertical-align: middle; }
.vg-vis-green { background: var(--green-soft); color: var(--green-ink); }
.vg-vis-amber { background: var(--amber-soft); color: var(--amber-ink); }
.vg-vis-red   { background: var(--red-soft);   color: var(--red-ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--red) 35%, transparent); }

/* Post-create report dialog — clean, table-based summary (Or 2026-07-03) */
.cr-box { max-width: 480px; }
.cr-title { margin: 0 0 3px; }
.cr-sub { font-size: 13px; color: var(--muted); margin: 0 0 12px; }
.cr-config { display: grid; grid-template-columns: auto 1fr; gap: 5px 16px; align-items: center;
             padding: 11px 14px; margin: 0 0 12px; border-radius: 11px;
             background: var(--surface, rgba(127,127,127,.06)); border: 1px solid var(--border); font-size: 12.5px; }
.cr-cfg-k { color: var(--muted); font-weight: 600; }
.cr-cfg-v { text-align: right; color: var(--ink); font-weight: 700; }
.cr-table-wrap { max-height: 42vh; overflow: auto; border: 1px solid var(--border); border-radius: 11px; margin: 0 0 14px; }
.cr-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.cr-table thead th { position: sticky; top: 0; z-index: 1; text-align: left; padding: 9px 13px;
                     font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px;
                     color: var(--muted); background: var(--surface, var(--card)); border-bottom: 1px solid var(--border); }
.cr-table td { padding: 9px 13px; border-top: 1px solid var(--border); }
.cr-ev { font-weight: 600; color: var(--ink); }
.cr-table th.cr-st, .cr-table td.cr-st { text-align: right; white-space: nowrap; }
.cr-ok { color: var(--green-ink); font-weight: 700; }
.cr-fail { color: var(--red-ink); font-weight: 700; }
.cr-actions { flex-wrap: wrap; gap: 6px; }

/* Pre-create bulk confirm: numbered match table with dates (Or 2026-07-03) */
.bl-confirm-tbl-wrap { max-height: 36vh; overflow: auto; border: 1px solid var(--border); border-radius: 10px; margin: 10px 0 4px; }
.bl-confirm-tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.bl-confirm-tbl thead th { position: sticky; top: 0; z-index: 1; text-align: left; padding: 7px 11px;
  font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); background: var(--surface, var(--card)); border-bottom: 1px solid var(--border); }
.bl-confirm-tbl td { padding: 6px 11px; border-top: 1px solid var(--border); }
.bl-confirm-tbl td.num { color: var(--muted); font-weight: 700; width: 28px; }
.bl-confirm-tbl td:first-child + td { font-weight: 600; }
.bl-confirm-tbl td:last-child { white-space: nowrap; color: var(--muted); }

/* ---- Cross-platform linkage (Or 2026-07-04) ---- */
.lnk-hd-btn { border: 1px solid var(--border); background: transparent; color: inherit; border-radius: 9px;
  padding: 3px 9px; font-size: 14px; cursor: pointer; }
.lnk-hd-btn:hover { background: var(--surface-2, rgba(127,127,127,.12)); }
.lnk-chip { display: inline-block; margin-left: 5px; padding: 0 6px; border-radius: 999px; font-size: 10.5px;
  font-weight: 800; background: color-mix(in srgb, #6366f1 16%, transparent); color: #6366f1;
  border: 1px solid color-mix(in srgb, #6366f1 40%, transparent); cursor: pointer; vertical-align: middle; }
.lnk-box { max-width: 760px; }
.lnk-settings { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: center; font-size: 13px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface, rgba(127,127,127,.05)); }
.lnk-settings label { display: inline-flex; align-items: center; gap: 5px; }
.lnk-armed { display: inline-flex; gap: 10px; align-items: center; }
.lnk-groups-wrap { max-height: 34vh; overflow: auto; display: flex; flex-direction: column; gap: 10px; }
.lnk-group { border: 1px solid var(--border); border-radius: 11px; overflow: hidden; }
.lnk-group-head { padding: 7px 12px; font-weight: 700; font-size: 12.5px; background: var(--surface, rgba(127,127,127,.06)); border-bottom: 1px solid var(--border); }
.lnk-tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.lnk-tbl th, .lnk-tbl td { padding: 6px 10px; text-align: left; border-top: 1px solid var(--border); }
.lnk-tbl thead th { border-top: none; font-size: 10px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); }
.lnk-tbl .r { text-align: right; }
.lnk-manual { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.lnk-manual select { max-width: 285px; padding: 5px 8px; font-size: 12px; border: 1px solid var(--border); border-radius: 7px; background: transparent; color: inherit; }
.lnk-log { max-height: 20vh; overflow: auto; border: 1px solid var(--border); border-radius: 10px; padding: 6px 10px; font-size: 12px; }
.lnk-log-row { padding: 3px 0; border-bottom: 1px dashed color-mix(in srgb, var(--border) 60%, transparent); }
.lnk-log-row:last-child { border-bottom: none; }
.lnk-k-action { color: var(--green-ink); } .lnk-k-error { color: var(--red-ink); } .lnk-k-dry { color: var(--amber-ink); }

/* ---- Per-listing linkage wizard (Or 2026-07-04) ---- */
.lnk-chip-ghost { opacity: .38; background: transparent; color: var(--muted); border-color: var(--border); }
.lnk-chip-ghost:hover { opacity: 1; color: #6366f1; border-color: #6366f1; }
.lnk-src-card { padding: 10px 13px; border: 1px solid color-mix(in srgb, #6366f1 45%, var(--border)); border-radius: 11px;
  background: color-mix(in srgb, #6366f1 8%, transparent); font-size: 13.5px; }
.lnk-linked-now { margin-top: 8px; font-size: 12.5px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.lnk-linked-item { display: inline-flex; gap: 5px; align-items: center; padding: 2px 8px; border: 1px solid var(--border);
  border-radius: 999px; background: var(--green-soft); color: var(--green-ink); }
.lnk-unlink-x { border: none; background: transparent; cursor: pointer; font-size: 11px; padding: 0 2px; }
.lnk-pills { display: flex; gap: 7px; flex-wrap: wrap; margin: 0 0 8px; }
.lnk-pill { padding: 5px 13px; border-radius: 999px; border: 1px solid var(--border); background: transparent;
  color: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; }
.lnk-pill.active { background: #6366f1; border-color: #6366f1; color: #fff; }
.lnk-pill.down { opacity: .45; }
.lnk-cands { max-height: 34vh; overflow: auto; border: 1px solid var(--border); border-radius: 11px; display: flex; flex-direction: column; }
.lnk-cand { display: flex; gap: 10px; align-items: center; padding: 8px 12px; border-bottom: 1px solid color-mix(in srgb, var(--border) 60%, transparent); cursor: pointer; font-size: 13px; }
.lnk-cand:last-child { border-bottom: none; }
.lnk-cand:hover { background: color-mix(in srgb, #6366f1 6%, transparent); }
.lnk-cand.is-match { background: color-mix(in srgb, #6366f1 5%, transparent); }
.lnk-cand.is-linked { opacity: .55; }
.lnk-cand-main { flex: 1; min-width: 0; }
.lnk-cand-sub { display: block; font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.lnk-tag-match { font-size: 10.5px; font-weight: 800; color: #6366f1; white-space: nowrap; }
.lnk-tag-linked { font-size: 10.5px; font-weight: 700; color: var(--green-ink); white-space: nowrap; }

/* Prominent LINKED badge + labeled header button (Or 2026-07-04) */
.lnk-chip-on { background: #6366f1 !important; color: #fff !important; border-color: #6366f1 !important;
  font-size: 11px; padding: 1.5px 8px; box-shadow: 0 1px 5px color-mix(in srgb, #6366f1 45%, transparent); }
.lnk-chip-on:hover { background: #4f52e0 !important; }
.lnk-hd-btn { font-size: 12.5px; font-weight: 700; display: inline-flex; align-items: center; gap: 5px; }
.lnk-hd-count { display: inline-flex; align-items: center; justify-content: center; min-width: 17px; height: 17px;
  padding: 0 4px; border-radius: 999px; background: #6366f1; color: #fff; font-size: 10.5px; font-weight: 800; }

/* ---- Linkage visual upgrade (Or 2026-07-05) ---- */
/* Header button: gradient pill, impossible to miss */
.lnk-hd-btn { background: linear-gradient(135deg, #6366f1, #8b5cf6); color: #fff !important; border: none;
  border-radius: 999px; padding: 5px 14px; font-size: 12.5px; font-weight: 800; letter-spacing: .2px;
  box-shadow: 0 2px 10px rgba(99, 102, 241, .35); transition: filter .15s, transform .15s; }
.lnk-hd-btn:hover { background: linear-gradient(135deg, #6366f1, #8b5cf6); filter: brightness(1.1); transform: translateY(-1px); }
.lnk-hd-count { background: rgba(255, 255, 255, .28); color: #fff; }
/* Linked row: soft indigo wash + accent bar on the first cell — elegant, not shouting */
tr.lnk-row-linked > td { background: linear-gradient(90deg, color-mix(in srgb, #6366f1 8%, transparent), color-mix(in srgb, #6366f1 2%, transparent) 60%, transparent); }
tr.lnk-row-linked > td:first-child { box-shadow: inset 3px 0 0 #6366f1; }
/* Linked chip: gradient, roomier, subtle ring */
.lnk-chip-on { background: linear-gradient(135deg, #6366f1, #8b5cf6) !important; border: none !important;
  padding: 2.5px 10px; letter-spacing: .3px; border-radius: 999px;
  box-shadow: 0 1px 6px rgba(99, 102, 241, .4), inset 0 0 0 1px rgba(255, 255, 255, .18); }
.lnk-chip-on:hover { filter: brightness(1.1); }

/* Linkage consistency warnings (Or 2026-07-05) */
.lnk-tag-warn { font-size: 10.5px; font-weight: 800; color: var(--red-ink); background: var(--red-soft);
  border-radius: 999px; padding: 1px 7px; white-space: nowrap; margin-left: 4px; }
.lnk-mismatch { margin-top: 12px; border: 1px solid color-mix(in srgb, var(--red) 45%, var(--border));
  background: var(--red-soft); border-radius: 11px; padding: 11px 13px; font-size: 12.5px; }
.lnk-mismatch-head { font-weight: 800; color: var(--red-ink); margin-bottom: 6px; }
.lnk-mismatch-item { color: var(--red-ink); margin: 4px 0; }
.lnk-mismatch-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 9px; }

/* Platform brand colors in linkage UI (Or 2026-07-05): LFT red · FTN dark green · SH purple · VGG light green */
.lnk-plat { display: inline-block; margin: 0 2px; padding: 1px 7px; border-radius: 6px; color: #fff;
  font-size: 10px; font-weight: 800; letter-spacing: .35px; vertical-align: middle; line-height: 1.5; }
.lnk-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
/* Linked row chip becomes a soft container so the colored platform tags carry the identity */
.lnk-chip-on { background: color-mix(in srgb, #6366f1 10%, transparent) !important;
  color: #6366f1 !important; border: 1px solid color-mix(in srgb, #6366f1 45%, transparent) !important;
  padding: 1.5px 7px 1.5px 6px; box-shadow: none; display: inline-flex; align-items: center; gap: 1px; }
.lnk-chip-on:hover { background: color-mix(in srgb, #6366f1 18%, transparent) !important; filter: none; }

/* Unlinked rows: the Link button must be VISIBLE, not a ghost (Or 2026-07-05) */
.lnk-chip-ghost { opacity: 1 !important; background: transparent !important; color: #6366f1 !important;
  border: 1.5px dashed color-mix(in srgb, #6366f1 55%, transparent) !important;
  padding: 1.5px 9px; font-size: 11px; font-weight: 800; border-radius: 999px; letter-spacing: .2px; }
.lnk-chip-ghost:hover { background: color-mix(in srgb, #6366f1 12%, transparent) !important;
  border-style: solid !important; transform: translateY(-1px); }

/* In-modal wait widget: progress bar + elapsed timer (Or 2026-07-05) */
.lnk-wait { padding: 26px 10px 18px; text-align: center; }
.lnk-wait-label { font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.lnk-wait-bar { height: 8px; border-radius: 999px; overflow: hidden;
  background: color-mix(in srgb, #6366f1 12%, transparent); }
.lnk-wait-fill { height: 100%; border-radius: 999px; width: 2%;
  background: linear-gradient(90deg, #6366f1, #8b5cf6); transition: width .25s linear; position: relative; }
.lnk-wait-fill::after { content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent);
  animation: lnkShimmer 1.2s linear infinite; }
@keyframes lnkShimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.lnk-wait-meta { display: flex; justify-content: space-between; margin-top: 8px;
  font-size: 11.5px; font-weight: 700; color: var(--muted); }
.lnk-wait-meta [data-w-pct] { color: #6366f1; }

/* Linked-now comparison table in the wizard (Or 2026-07-05) */
.lnk-cmp-wrap { margin-top: 6px; border: 1px solid var(--border); border-radius: 11px; overflow: auto; max-height: 30vh; }
.lnk-cmp { font-size: 12px; }
.lnk-cmp thead th { position: sticky; top: 0; background: var(--surface, var(--card)); z-index: 1; }
.lnk-cmp td, .lnk-cmp th { white-space: nowrap; }
.lnk-cmp td:nth-child(2) { white-space: normal; min-width: 130px; }
.lnk-cmp-src > td { background: color-mix(in srgb, #6366f1 8%, transparent); font-weight: 600; }
