/* «کانال سیگنال من» (mychannel.js): the third tab, the Mother Card and the
   cards' channel button. Built on copytrade.html's tokens (--g-*), light and
   dark, right to left; nothing here applies without mychannel.js's markup. */

/* The chart lines: a validated categorical order (light and dark checked
   against the card surface), the combined line in the page's teal, a grey
   past the seventh source. Green and red stay for results only. */
:root, :root[data-theme="light"] {
  --mc-s1:#2a78d6; --mc-s2:#eb6834; --mc-s3:#1baf7a; --mc-s4:#eda100; --mc-s5:#e87ba4; --mc-s6:#008300; --mc-s7:#4a3aa7;
  --mc-combined:#0B9DB0; --mc-other:#8A97A6; --mc-band:rgba(11,157,176,.08);
  /* small text on white or the teal tint: AA (4.5:1) where the site's --g-up / --g-teal-ink are 3.3 / 4.3 */
  --mc-up-ink:#15803D; --mc-teal-ink:#06707D;
}
:root[data-theme="dark"] {
  --mc-s1:#3987e5; --mc-s2:#d95926; --mc-s3:#199e70; --mc-s4:#c98500; --mc-s5:#d55181; --mc-s6:#008300; --mc-s7:#9085e9;
  --mc-combined:#20A8B4; --mc-other:#5F7071; --mc-band:rgba(41,227,227,.07);
  --mc-up-ink:var(--g-up); --mc-teal-ink:var(--g-teal-ink);
}

/* ---- the three tabs: on phones the exact titles wrap to two lines rather than shrink ---- */
@media (max-width:600px) {
  .ct-tabs.mc-tabs button {
    white-space:normal; height:auto; min-height:44px; line-height:1.35; padding:4px 6px; font-size:13px; text-align:center;
  }
}

/* ---- the card's foot: the channel button (no price), then «کپی» as before ---- */
.mc-foot { margin-top:auto; display:flex; flex-direction:column; gap:6px; min-width:0; }
.mc-foot .ct-copy { margin-top:0; }
.mc-cta {
  position:relative; z-index:2;     /* above the card's open button (.ct-open::after) */
  width:100%; min-height:33px; margin:0; padding:4px 12px; border-radius:10px; border:1px solid transparent;
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  font-family:inherit; font-size:13.5px; font-weight:800; line-height:1.4; text-align:center; cursor:pointer;
  transition:filter .15s, border-color .15s, background .15s;
}
.mc-cta.add { background:var(--g-teal); color:#fff; }
.mc-cta.add:hover { filter:brightness(.94); }
:root[data-theme="dark"] .mc-cta.add { color:#0B1314; }
.mc-cta.locked { background:var(--g-flat-soft); color:var(--g-ink-2); border:1px dashed var(--g-line); }
.mc-cta.locked:hover { border-color:var(--g-teal-line); color:var(--g-ink); }
.mc-cta.on { background:var(--g-teal-soft); color:var(--g-teal-ink); border-color:var(--g-teal-line); }
.mc-cta.on:hover { border-color:var(--g-teal); }
.mc-cta.pay { background:var(--g-card); color:var(--g-star); border-color:var(--g-star); }
.mc-cta.off { background:var(--g-flat-soft); color:var(--g-ink-3); border-radius:99px; cursor:default; }
button.mc-cta.off { cursor:pointer; }
.mc-cta:disabled, .mc-cta[aria-busy="true"], .mc-btn[aria-busy="true"] { opacity:.65; cursor:progress; }
.mc-cta .ct-spin { width:14px; height:14px; }
.mc-cta.add .ct-spin { border-color:rgba(255,255,255,.45); border-top-color:#fff; }
.mc-note.mc-credit { color:var(--g-teal-ink); font-weight:800; }
.mc-note { margin:0; font-size:12px; line-height:1.8; font-weight:600; color:var(--g-ink-3); }
.mc-note.warn { color:var(--g-star); }
.mc-chip {
  display:inline-flex; align-items:center; gap:4px; max-width:100%; padding:2px 9px; border-radius:99px;
  font-size:11.5px; font-weight:800; line-height:1.6; background:var(--g-flat-soft); color:var(--g-ink-2);
}
.mc-chip.ok { background:var(--g-teal-soft); color:var(--g-teal-ink); }
.mc-chip.warn { background:var(--g-flat-soft); color:var(--g-star); }
.mc-chip.bad { background:var(--g-down-soft); color:var(--g-down); }
.mc-foot .mc-chip { align-self:flex-start; }

/* ---- a channel leaf's list (owner, 2026-10-20: «اصلاً پیچیده نکن»): each card's one button ---- */
.mc-cta.first { background:var(--g-card); color:var(--g-teal-ink); border-color:var(--g-teal-line); }
.mc-cta.first:hover { border-color:var(--g-teal); background:var(--g-teal-soft); }
.mc-in-row { position:relative; z-index:2; display:flex; align-items:center; gap:8px; min-width:0; }
.mc-in {
  flex:1 1 auto; min-width:0; min-height:33px; display:inline-flex; align-items:center; justify-content:center; padding:4px 10px;
  border-radius:10px; background:var(--g-teal-soft); color:var(--g-teal-ink); border:1px solid var(--g-teal-line);
  font-size:13.5px; font-weight:800; line-height:1.4;
}
.mc-in:focus { outline:none; }
.mc-in:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-cta-x {
  flex:none; min-height:33px; min-width:56px; padding:4px 12px; border-radius:10px; border:1px solid var(--g-line);
  background:var(--g-card); color:var(--g-ink-2); font-family:inherit; font-size:13px; font-weight:800; cursor:pointer;
  display:inline-flex; align-items:center; justify-content:center; gap:6px;
}
.mc-cta-x:hover { border-color:var(--g-down); color:var(--g-down); }
.mc-cta-x:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-cta-x[aria-busy="true"] { opacity:.65; cursor:progress; }
.mc-cta-x .ct-spin { width:13px; height:13px; }
.mc-act.mc-pick-foot .mc-in, .mc-act.mc-pick-foot .mc-cta-x { min-height:42px; border-radius:12px; font-size:14.5px; }
/* The leaf's two numbered parts: «۱. کانال تلگرامت را وصل کن» (the connect box) and «۲. منابع را اضافه کن» (the list). */
.mc-step-k { color:var(--g-teal-ink); font-weight:800; }
.mc-sources { scroll-margin-top:112px; }
.mc-sources > h2:focus { outline:none; }
.mc-sources > h2:focus-visible { outline:2px solid var(--g-teal); outline-offset:3px; border-radius:6px; }
.mc-step-n.is-key { width:auto; min-width:28px; padding:0 7px; border-radius:99px; font-size:12px; }
.mc-mini .mc-step-n.is-key { min-width:26px; height:24px; }

/* ---- the source's page: beside the inactive «کپی» ---- */
/* Round 6 (D11) made the label «🔒 افزودن به کانال سیگنال شخصی (رایگان)»: room for it on one line (the review of round 6:
   at 280 px it wrapped to two lines inside a fixed 42 px), and a button that grows rather than clips if it still wraps. */
.mc-act { display:flex; flex-direction:column; gap:4px; min-width:176px; max-width:340px; }
.mc-act .mc-cta { min-height:42px; height:auto; border-radius:12px; font-size:14.5px; padding:6px 18px; }
.mc-act .mc-note { font-size:11.5px; }
.ct-pf-actions:has(> .mc-act) { align-items:flex-start; }
@media (max-width:760px) {
  .ct-pf-actions { flex-wrap:wrap; }
  .ct-pf-actions .mc-act { order:9; flex:1 1 100%; max-width:none; min-width:0; }
}

/* ---- «مقایسه با منابع من» on a source's page: a section of its own ---- */
.mc-why { padding:16px 20px; display:flex; flex-direction:column; gap:14px; }
.mc-why-foot { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:8px 16px; }
.mc-why-foot .mc-meta { flex:1 1 240px; min-width:0; }
.mc-why-foot .mc-btn { flex:none; }
.mc-why-foot .mc-btn .ico { color:var(--g-teal); }
@media (max-width:760px) {
  .mc-why { padding:14px 16px; }
}

/* ---- a selected source whose daily rating is late ---- */
.mc-rating-stale { color:var(--g-star); }
.mc-h-id .mc-rating-stale { font-size:11.5px; line-height:1.6; }
/* «۸۰٪ سیگنال‌هایش با X یکی است؛ تکراری‌ها یک بار ارسال می‌شوند» under a source's name (2026-10-18): a quiet note that wraps
   (a phone's card: on a line of its own under the small figures, the copy in td.mc-h-sub; a tablet's: a row of its own,
   tr.mc-h-ovrow; the name's hidden there). */
.mc-overlap { font-size:11.5px; font-weight:600; line-height:1.6; color:var(--g-ink-3); white-space:normal; max-width:100%; overflow-wrap:anywhere; }
.mc-conn .ct-strip { margin:2px 0; }

/* ---- the dashboard's note when the status could not be refreshed ---- */
.mc-stale { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:2px 12px; }
.mc-stale .mc-link { padding:0; color:inherit; text-decoration:underline; }

/* ---- buttons, links, small text ---- */
.mc-btn {
  display:inline-flex; align-items:center; justify-content:center; gap:8px; height:40px; padding:0 16px; border-radius:12px;
  border:1px solid var(--g-line); background:var(--g-card); color:var(--g-ink); font-family:inherit; font-size:13.5px; font-weight:800;
  text-decoration:none; white-space:nowrap; cursor:pointer; transition:border-color .15s, filter .15s;
}
.mc-btn:hover { border-color:var(--g-teal-line); }
.mc-btn.primary { background:var(--g-teal); border-color:var(--g-teal); color:#fff; }
.mc-btn.primary:hover { filter:brightness(.94); }
:root[data-theme="dark"] .mc-btn.primary { color:#0B1314; }
.mc-btn.danger { color:var(--g-down); }
.mc-btn.danger:hover { border-color:var(--g-down); }
.mc-btn.big { height:48px; padding:0 22px; font-size:15px; }
.mc-btn.sm { height:34px; padding:0 12px; font-size:12.5px; }
.mc-btn:disabled { opacity:.55; cursor:not-allowed; }
.mc-btn.primary .ct-spin { border-color:rgba(255,255,255,.45); border-top-color:#fff; }
.mc-link { border:0; background:none; padding:4px 0; color:var(--g-teal-ink); font-family:inherit; font-size:13.5px; font-weight:800; cursor:pointer; }
.mc-link:hover { text-decoration:underline; }
.mc-meta { margin:0; font-size:12px; font-weight:600; line-height:1.8; color:var(--g-ink-3); }
.mc-hint { margin:0; font-size:12px; line-height:1.9; color:var(--g-ink-3); }
.mc-sub { margin:0; font-size:14px; font-weight:800; display:flex; flex-wrap:wrap; align-items:baseline; gap:4px 8px; }
.mc-sw { display:inline-block; flex:none; width:10px; height:10px; border-radius:3px; background:var(--c, var(--g-ink-3)); }
.mc-seg { flex-wrap:wrap; }
.mc-seg button { height:32px; min-width:52px; }
.mc-seg button:disabled { opacity:.5; cursor:not-allowed; }
.ct-month-wrap:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }

/* ---- the Mother Card on the list: compact and minimal (owner, 2026-10-16) ----
   On wide screens every part in one row (right to left): the sources'
   photos, the title line with the state, three figures, «مدیریت کانال ←»;
   smaller screens wrap it (below). The photos are the card's own button:
   its ::after covers the card (as a source card's name does), «مدیریت
   کانال» sits above it. */
#ctMotherBox { min-width:0; }
.mc-mother {
  position:relative; isolation:isolate; min-width:0;
  display:grid; grid-template-columns:auto minmax(0, 1fr) auto auto; grid-template-areas:"open id figs manage" "note note note note";
  align-items:center; gap:4px 24px; padding:12px 18px;
  background:var(--g-card); border:1px solid var(--g-teal-line); border-inline-start:4px solid var(--g-teal); border-radius:18px;
  box-shadow:var(--g-shadow); cursor:pointer; transition:box-shadow .15s, border-color .15s;
}
.mc-mother:hover { border-color:var(--g-teal); box-shadow:var(--g-lift); }
.mc-mother-open {
  grid-area:open;
  display:flex; align-items:center; min-width:0; min-height:34px; margin:0; padding:0; border:0; background:none;
  color:inherit; font-family:inherit; cursor:pointer; -webkit-tap-highlight-color:transparent;
}
.mc-mother-open::after { content:''; position:absolute; inset:0; z-index:1; border-radius:14px; }
.mc-mother-open:focus-visible { outline:none; }
.mc-mother-open:focus-visible::after { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-mother-manage { grid-area:manage; position:relative; z-index:2; flex:none; padding:4px 2px; font-size:13px; white-space:nowrap; }
.mc-mother-id { grid-area:id; min-width:0; display:flex; align-items:center; flex-wrap:wrap; gap:4px 10px; }
.mc-mother > .mc-issue { grid-area:note; }
/* one title line: a long channel name ends in an ellipsis rather than wrap */
.mc-mother-id h2 { margin:0; min-width:0; max-width:100%; display:flex; align-items:center; gap:6px; font-size:15.5px; font-weight:800; line-height:1.6; }
.mc-mother-id h2 > * { flex:none; }
.mc-mother-id h2 .ico { color:var(--g-teal-ink); }
.mc-mother-id h2 > bdi { flex:0 1 auto; min-width:0; color:var(--g-teal-ink); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-dot { color:var(--g-ink-3); }
.mc-avatars { display:flex; align-items:center; }
.mc-avatars .ct-avatar { width:32px; height:32px; font-size:12.5px; box-shadow:0 0 0 2px var(--g-card); }
.mc-avatars .ct-avatar + .ct-avatar, .mc-avatars .mc-more { margin-inline-start:-8px; }
.mc-more {
  position:relative;   /* painted over the photo before it, as the photos are (.ct-avatar is positioned) */
  display:inline-grid; place-items:center; min-width:32px; height:32px; padding:0 6px; border-radius:99px;
  background:var(--g-flat-soft); color:var(--g-ink-2); font-size:12px; font-weight:800; box-shadow:0 0 0 2px var(--g-card);
}
/* three figures in a row, thin dividers between them */
.mc-figs { grid-area:figs; margin:0; flex:none; display:flex; align-items:flex-start; min-width:0; }
.mc-fig { display:flex; flex-direction:column; min-width:0; padding-inline:18px; border-inline-start:1px solid var(--g-line); }
.mc-fig:first-child { padding-inline-start:0; border-inline-start:0; }
.mc-fig:last-child { padding-inline-end:0; }
.mc-fig dt { font-size:11.5px; font-weight:700; line-height:1.6; color:var(--g-ink-3); white-space:nowrap; }
.mc-fig dd { margin:0; font-size:16px; font-weight:800; line-height:1.5; color:var(--g-ink); white-space:nowrap; font-variant-numeric:tabular-nums; }
.mc-fig dd.up { color:var(--g-up); } .mc-fig dd.down { color:var(--g-down); }
.mc-mother-warn { font-size:12.5px; }
/* Narrower wide screens: the figures under the photos, the title and the link. */
@media (max-width:900px) {
  .mc-mother { grid-template-columns:auto minmax(0, 1fr) auto; grid-template-areas:"open id manage" "figs figs figs" "note note note"; gap:8px 18px; }
}

/* ---- the tab (owner, 2026-10-16: minimal, generous white space; 2026-10-17: the status, today, one section) ---- */
.mc-dash { display:flex; flex-direction:column; gap:20px; min-width:0; }
.mc-dash > * { min-width:0; }
.mc-dash > [data-mc-box]:empty { display:none; }
.mc-box {
  background:var(--g-card); border:1px solid var(--g-line); border-radius:18px; box-shadow:var(--g-shadow);
  padding:20px 22px; display:flex; flex-direction:column; gap:14px; min-width:0;
}
.mc-box:focus { outline:none; }
.mc-box:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-box > .ct-strip, .mc-box .ct-add-lead { margin:0; }
.mc-box-head { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:8px 12px; }
.mc-box-head h2 { margin:0; font-size:16px; font-weight:800; display:flex; align-items:center; gap:8px; }
.mc-box-head h2 .ico { color:var(--g-teal); }
.mc-box-links { display:flex; flex-wrap:wrap; align-items:center; gap:2px 18px; }
.mc-count {
  display:inline-grid; place-items:center; min-width:24px; height:22px; padding:0 7px; border-radius:99px;
  background:var(--g-flat-soft); color:var(--g-ink-2); font-size:12px; font-weight:800;
}
.mc-signin, .mc-empty { align-items:flex-start; }
.mc-signin h2 { margin:0; font-size:16px; font-weight:800; }
.mc-signin .ico { color:var(--g-teal); }
.mc-empty p { margin:0; font-size:14px; line-height:1.9; color:var(--g-ink-2); }
.mc-empty .mc-box-head { align-self:stretch; }

/* 1. the channel's status card in one row (owner, 2026-10-16): @name · state · «رایگان» · the type · the basis ⓘ (a select),
   the ⋯ menu; smaller screens put the basis on a second line. Problems under it. */
.mc-status-head { display:flex; align-items:center; gap:12px; min-width:0; }
.mc-status-ico {
  flex:none; display:grid; place-items:center; width:40px; height:40px; border-radius:12px;
  background:var(--g-teal-soft); color:var(--g-teal-ink);
}
.mc-status-id { flex:1; min-width:0; display:flex; flex-direction:column; gap:1px; }
.mc-status-row { display:flex; flex-direction:row; flex-wrap:wrap; align-items:center; column-gap:8px; row-gap:2px; }
.mc-status-id h2 { margin:0; font-size:16.5px; font-weight:800; line-height:1.55; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-status-row h2 { flex:0 1 auto; min-width:0; max-width:100%; }
.mc-status-break { display:none; }
.mc-status-line {
  margin:0; display:flex; flex-wrap:wrap; align-items:center; gap:2px 8px;
  font-size:12.5px; font-weight:700; line-height:1.8; color:var(--g-ink-3);
}
.mc-sep { opacity:.6; }
.mc-state { display:inline-flex; align-items:center; gap:6px; font-weight:800; }
.mc-state::before { content:''; flex:none; width:7px; height:7px; border-radius:50%; background:currentColor; }
.mc-state.ok { color:var(--g-up); }
.mc-state.dry { color:var(--g-star); cursor:help; }
.mc-state.bad { color:var(--g-down); }
.mc-badge {
  display:inline-block; max-width:100%; padding:0 10px; border-radius:10px; line-height:1.9;
  font-size:12px; font-weight:800; background:var(--g-flat-soft); color:var(--g-ink-2);
}
.mc-badge.ok { background:var(--g-teal-soft); color:var(--g-teal-ink); }
.mc-badge.warn { color:var(--g-star); }
/* the ⋯ menu: a disclosure (the channel in Telegram, «قطع اتصال») */
.mc-menu-wrap { position:relative; flex:none; align-self:flex-start; }
.mc-icon-btn {
  display:grid; place-items:center; width:38px; height:38px; border-radius:10px; border:1px solid transparent;
  background:none; color:var(--g-ink-2); cursor:pointer;
}
.mc-icon-btn:hover, .mc-icon-btn[aria-expanded="true"] { background:var(--g-flat-soft); color:var(--g-ink); }
.mc-menu {
  position:absolute; top:calc(100% + 6px); inset-inline-end:0; z-index:20; min-width:220px; padding:6px;
  display:flex; flex-direction:column; gap:2px;
  background:var(--g-card); border:1px solid var(--g-line); border-radius:12px; box-shadow:var(--g-pop);
}
.mc-menu-item {
  display:flex; align-items:center; gap:8px; height:40px; padding:0 12px; border:0; border-radius:8px; background:none;
  color:var(--g-ink); font-family:inherit; font-size:13.5px; font-weight:700; text-decoration:none; text-align:start; white-space:nowrap; cursor:pointer;
}
.mc-menu-item .ico { color:var(--g-ink-3); }
.mc-menu-item:hover, .mc-menu-item:focus-visible { background:var(--g-flat-soft); }
.mc-menu-item.danger { color:var(--g-down); }
.mc-menu-item:disabled { opacity:.6; cursor:progress; }
/* a real problem: one short line, a dot of its tone */
.mc-issue {
  margin:0; display:flex; flex-wrap:wrap; align-items:center; gap:2px 10px;
  font-size:13px; font-weight:700; line-height:1.8; color:var(--g-ink-2);
}
.mc-issue::before { content:''; flex:none; width:6px; height:6px; border-radius:50%; background:currentColor; }
.mc-issue > span { flex:1 1 200px; min-width:0; }
.mc-issue.warn { color:var(--g-star); }
.mc-issue.bad { color:var(--g-down); }
.mc-issue.note { color:var(--g-ink-3); }
.mc-issue .mc-link { padding:0; font-size:13px; }
.mc-issue .mc-link:disabled { color:var(--g-ink-3); cursor:not-allowed; text-decoration:none; }
/* the channel's own basis in the row (owner, 2026-10-17): «مبنای کانال» and a compact select, saved at once («ذخیره شد» a
   moment beside it); the ⓘ's note opens under the row */
.mc-basis { display:inline-flex; align-items:center; flex-wrap:wrap; gap:2px 6px; min-width:0; }
.mc-basis-line { cursor:pointer; }
.mc-basis-select {
  height:30px; min-width:76px; padding:0 8px; border-radius:9px; border:1px solid var(--g-line); background:var(--g-card); color:var(--g-ink);
  font-family:inherit; font-size:13px; font-weight:800; font-variant-numeric:tabular-nums; cursor:pointer;
}
.mc-basis-select:hover { border-color:var(--g-teal-line); }
.mc-basis-select:focus-visible { outline:2px solid var(--g-teal); outline-offset:1px; border-color:var(--g-teal); }
.mc-basis-select:disabled { opacity:.65; cursor:progress; }
:root[data-theme="dark"] .mc-basis-select { color-scheme:dark; }
.mc-basis .ct-spin { width:13px; height:13px; }
/* «پیشنهادی هر منبع» (owner, 2026-10-17, phase 2): amber, as the list's chip; its words in the ⓘ's note on a line of
   their own; a source's own ratio under those figures (amber: its recommendation; plain: «۱:۱ · بدون پیشنهاد»); a post
   sent under it, beside its TP. */
/* sized to the chosen option where the browser can (the long «پیشنهادی هر منبع» would widen it at every ratio) */
.mc-basis-select { field-sizing:content; }
.mc-basis-select.best { color:var(--g-amber-ink); border-color:var(--g-amber-line); }
.mc-basis-select option { color:var(--g-ink); }
.mc-basis-select option.mc-opt-best { color:var(--g-amber-ink); font-weight:800; }
.mc-tip-best { display:block; margin-top:4px; }
.mc-tip-best b { color:var(--g-amber-ink); font-weight:800; }
.mc-rr {
  display:inline-block; max-width:100%; padding:0 7px; border-radius:7px; font-size:11px; font-weight:800; line-height:1.7;
  white-space:nowrap; background:var(--g-flat-soft); color:var(--g-ink-3); font-variant-numeric:tabular-nums;
}
.mc-rr.best { background:var(--g-amber-soft); color:var(--g-amber-ink); box-shadow:inset 0 0 0 1px var(--g-amber-line); }
.mc-cell-name .mc-rr { flex:none; }
.mc-sig-best { color:var(--g-amber-ink); font-weight:800; }
.mc-sig-best.none { color:var(--g-ink-3); }
.mc-saved { display:inline-flex; align-items:center; gap:4px; color:var(--g-up); font-weight:800; }
/* «انتخاب منابع از فهرست ←»: beside the ⋯ menu on wide screens, a line of its own on phones */
.mc-status-go { flex:none; align-self:center; }
.mc-pick { color:var(--g-teal-ink); border-color:var(--g-teal-line); }
.mc-pick:hover { border-color:var(--g-teal); }
.mc-tip-btn {
  display:inline-grid; place-items:center; flex:none; width:28px; height:28px; margin:-2px 0; padding:0; border:0; border-radius:50%;
  background:none; color:var(--g-ink-3); cursor:pointer;
}
.mc-tip-btn:hover, .mc-tip-btn[aria-expanded="true"] { background:var(--g-flat-soft); color:var(--g-teal-ink); }
.mc-tip-btn:focus-visible { outline:2px solid var(--g-teal); outline-offset:1px; }
.mc-tip-note { margin:0; padding:8px 12px; border-radius:10px; background:var(--g-flat-soft); font-size:12px; font-weight:600; line-height:1.9; color:var(--g-ink-2); }
.mc-basis-row {
  margin:0; display:flex; flex-wrap:wrap; align-items:center; gap:2px 8px; padding-top:12px; border-top:1px solid var(--g-line-soft);
  font-size:12.5px; font-weight:700; line-height:1.8; color:var(--g-ink-3);
}
.mc-status .mc-hint { margin-top:-6px; font-size:11.5px; line-height:1.8; }
@media (max-width:760px) {
  .mc-status-row > .mc-status-basis { flex-basis:100%; }
  .mc-status-row > .mc-status-basis > .mc-sep:first-child { display:none; }
}
/* Phones: @name · state, then sources · «رایگان», then the basis's select ⓘ (its own line, as from 760 px); «انتخاب منابع از
   فهرست ←» the full width under them. */
@media (max-width:600px) {
  .mc-status-head { flex-wrap:wrap; }
  .mc-status-break { display:block; flex-basis:100%; height:0; }
  .mc-status-more > .mc-sep:first-child { display:none; }
  .mc-status-go { order:9; flex:1 1 100%; }
  .mc-status-go .mc-pick { width:100%; height:40px; }
}
.mc-status .ct-add-error { margin:0; }
/* the connect form and its flows, inside the same card */
.mc-connect .ct-link { align-self:flex-start; }
.mc-connect .ct-link:disabled { color:var(--g-ink-3); cursor:not-allowed; text-decoration:none; }
.mc-conn { display:flex; flex-direction:column; gap:6px; min-width:0; }
.mc-conn-title { margin:0; display:flex; align-items:center; gap:8px; font-size:16px; font-weight:800; }
.mc-conn-name { margin:0; font-size:15px; font-weight:800; color:var(--g-teal-ink); overflow-wrap:anywhere; }
.mc-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.mc-steps { margin:4px 0 0; padding-inline-start:22px; list-style:persian; font-size:13.5px; line-height:2; color:var(--g-ink-2); }
.mc-live { display:flex; align-items:center; gap:8px; }
/* A public channel's quick request: the wait, «ربات را دستی ادمین کنید» (no deep link since 2026-10-17) and the countdown */
.mc-quick { gap:8px; }
.mc-quick-hint { font-size:13px; font-weight:700; color:var(--g-ink-2); }
.mc-quick-left { display:flex; flex-wrap:wrap; align-items:baseline; gap:4px; }
.mc-clock { display:inline-block; min-width:4.5ch; font-size:13px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; }
a.mc-btn:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
/* The connect guide (owner, 2026-10-17): four numbered cards, two a row on wide screens and one on phones; the form in
   the third. Telegram's own labels as small LTR chips; each step's screenshots as thumbnails cropped on what they mark
   (object-position from the page), a wide site shot at the card's width; a larger view in a dialog (.mc-shot-box). */
.mc-guide { display:flex; flex-direction:column; gap:10px; min-width:0; }
.mc-guide-title { margin:0; font-size:14px; font-weight:800; color:var(--g-ink); }
.mc-steps-cards { list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(2, minmax(0, 1fr)); gap:12px; }
.mc-step {
  min-width:0; display:flex; flex-direction:column; gap:10px; padding:14px 16px;
  background:var(--g-flat-soft); border:1px solid transparent; border-radius:14px;
}
.mc-step-now { background:var(--g-card); border-color:var(--g-teal-line); }
.mc-step-head { display:flex; align-items:center; flex-wrap:wrap; gap:4px 10px; min-width:0; }
.mc-step-n {
  flex:none; display:grid; place-items:center; width:28px; height:28px; border-radius:50%;
  background:var(--g-teal); color:#fff; font-size:14px; font-weight:800; line-height:1;
}
:root[data-theme="dark"] .mc-step-n { color:#0B1314; }
.mc-step-head h3 { margin:0; flex:1 1 auto; min-width:0; font-size:15px; font-weight:800; line-height:1.6; color:var(--g-ink); }
.mc-step-skip {
  flex:none; padding:0 9px; border-radius:99px; background:var(--g-card); border:1px solid var(--g-line);
  font-size:11.5px; font-weight:700; line-height:1.9; color:var(--g-ink-3);
}
.mc-step-text { margin:0; font-size:13.5px; font-weight:500; line-height:2.1; color:var(--g-ink-2); }
.mc-tg {
  display:inline-block; padding:0 6px; border-radius:6px; border:1px solid var(--g-line); background:var(--g-card);
  font-size:12.5px; font-weight:800; line-height:1.7; color:var(--g-ink); white-space:nowrap;
}
.mc-arr { margin:0 2px; color:var(--g-ink-3); font-weight:800; }
.mc-step .ct-add-form { max-width:none; }
/* the input keeps its height when the page stacks the row on phones (a column's flex-basis 0 would squash it) */
.mc-connect .ct-add-input { flex:1 1 auto; }
.mc-step .mc-conn { padding:2px 0; }
/* the bot's id, to copy */
.mc-bot {
  display:flex; align-items:center; flex-wrap:wrap; gap:6px 10px; min-width:0; padding:8px 10px;
  background:var(--g-card); border:1px dashed var(--g-teal-line); border-radius:12px;
}
.mc-bot-k { font-size:12px; font-weight:700; color:var(--g-ink-3); }
.mc-bot-id {
  min-width:0; overflow-wrap:anywhere; font-family:inherit; font-size:15px; font-weight:800; color:var(--g-teal-ink);
  -webkit-user-select:all; user-select:all;
}
.mc-copy { margin-inline-start:auto; }
.mc-copy.done { color:var(--g-up); border-color:var(--g-up); }
/* the thumbnails */
.mc-shots { list-style:none; margin:0; padding:0; display:flex; flex-wrap:wrap; gap:8px; }
.mc-shots li { min-width:0; }
.mc-shot {
  display:block; width:88px; height:66px; padding:0; overflow:hidden; border:1px solid var(--g-line); border-radius:10px;
  background:var(--g-card); cursor:zoom-in; transition:border-color .15s, box-shadow .15s;
}
.mc-shot img { display:block; width:100%; height:100%; object-fit:cover; }
.mc-shot:hover { border-color:var(--g-teal); box-shadow:var(--g-shadow); }
.mc-shot:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-shots.wide li { flex:1 1 100%; }
.mc-shots.wide .mc-shot { width:min(100%, 380px); height:auto; }
.mc-shots.wide .mc-shot img { height:auto; object-fit:contain; }
/* a screenshot, larger */
.mc-shot-box { width:min(560px, 100%); gap:10px; padding:14px 16px; }
.mc-shot-top { display:flex; align-items:center; justify-content:space-between; gap:8px; min-width:0; }
.mc-shot-top h2 { font-size:15px; min-width:0; }
.mc-shot-fig { margin:0; display:flex; flex-direction:column; gap:8px; min-width:0; }
.mc-shot-frame { display:grid; place-items:center; min-height:120px; overflow:hidden; border-radius:12px; background:var(--g-flat-soft); }
.mc-shot-frame img {
  display:block; width:auto; max-width:100%; height:auto; object-fit:contain;
  max-height:calc(100vh - 230px); max-height:calc(100dvh - 230px);
}
.mc-shot-fig figcaption { display:flex; flex-wrap:wrap; align-items:baseline; gap:2px 8px; font-size:13px; font-weight:600; line-height:1.9; color:var(--g-ink-2); }
.mc-shot-n { flex:none; padding:0 8px; border-radius:99px; background:var(--g-flat-soft); font-size:12px; font-weight:800; color:var(--g-ink-3); }
.mc-shot-nav { display:flex; justify-content:space-between; gap:8px; }
.mc-shot-none { margin:0; padding:40px 12px; font-size:13px; font-weight:700; color:var(--g-ink-3); }
@media (max-width:760px) {
  .mc-steps-cards { grid-template-columns:minmax(0, 1fr); }
}
@media (max-width:600px) {
  .mc-step { padding:12px; }
  /* the bot's id and «کپی» on one line: «آیدی ربات» is said to screen readers only */
  .mc-bot-k { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); clip-path:inset(50%); white-space:nowrap; }
  .mc-shot { width:84px; height:63px; }
  .mc-shot-box { padding:12px; }
  .mc-shot-nav .mc-btn { flex:1 1 0; }
}
.mc-skipped > summary { cursor:pointer; font-size:12.5px; font-weight:700; color:var(--g-ink-2); line-height:1.9; }
.mc-skipped ul { list-style:none; margin:8px 0 0; padding:0; display:flex; flex-direction:column; gap:4px; }
.mc-skipped li { display:flex; flex-wrap:wrap; gap:2px 12px; padding:6px 10px; border-radius:10px; background:var(--g-flat-soft); font-size:12px; font-weight:600; }

.mc-an-sent { font-size:12px; color:var(--g-ink-3); }
/* «نمایش همه» under a long list; .mc-more stays the Mother Card's «+N» bubble. */
.mc-showall {
  align-self:center; border:0; background:none; padding:6px 14px; border-radius:10px;
  color:var(--g-teal-ink); font-family:inherit; font-size:13px; font-weight:800; cursor:pointer;
}
.mc-showall:hover { background:var(--g-teal-soft); }
.mc-legend { display:flex; flex-wrap:wrap; gap:6px; }
.mc-key {
  display:inline-flex; align-items:center; gap:6px; max-width:100%; height:30px; padding:0 10px; border-radius:99px;
  border:1px solid var(--g-line); background:var(--g-card); color:var(--g-ink-2); font-family:inherit; font-size:12.5px; font-weight:700; cursor:pointer;
}
.mc-key i { flex:none; width:16px; height:3px; border-radius:2px; background:var(--c); }
.mc-key.bold i { height:5px; }
.mc-key bdi { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-key[aria-pressed="false"] { color:var(--g-ink-3); background:var(--g-flat-soft); }
.mc-key[aria-pressed="false"] i { opacity:.35; }
.mc-key[aria-pressed="false"] bdi { text-decoration:line-through; }
.mc-chart { position:relative; height:260px; direction:ltr; touch-action:pan-y; }
.mc-chart svg { display:block; width:100%; height:100%; overflow:visible; }
.mc-chart text { font-family:inherit; font-size:11px; fill:var(--g-ink-3); }
.mc-chart text.mc-end { font-size:11.5px; font-weight:700; fill:var(--g-ink-2); }
.mc-chart-none { display:flex; flex-direction:column; align-items:flex-start; gap:8px; padding:20px 0; }
.mc-chart-empty { padding-top:100px; text-align:center; direction:rtl; }
.mc-tip { line-height:1.85; z-index:3; }
.mc-tip-row { display:flex; align-items:center; gap:6px; }
.mc-tip-row i { flex:none; width:8px; height:8px; border-radius:2px; background:var(--c); }
.mc-table thead button {
  border:0; background:none; padding:0; font:inherit; color:inherit; cursor:pointer; display:inline-flex; align-items:center; gap:3px; white-space:nowrap;
}
.mc-table th[aria-sort="ascending"] button, .mc-table th[aria-sort="descending"] button { color:var(--g-teal-ink); }
.mc-table .hl { background:var(--g-teal-soft); }
.mc-table tbody th { text-align:start; }
.mc-cell-name { display:inline-flex; align-items:center; gap:6px; max-width:180px; }
.mc-cell-name bdi { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

/* 2. the channel's signals, folded (closed by default): the head one button (its count and the period's summary in sight),
   then one row each, newest first (source and time · state, side · levels) */
.mc-sigs { gap:12px; }
.mc-sigs:not(.open) { padding-block:14px; }
.mc-fold-h { margin:0; font-size:16px; font-weight:800; }
.mc-fold {
  width:100%; display:flex; align-items:center; flex-wrap:wrap; gap:6px 12px; margin:0; padding:2px 0; border:0; border-radius:10px;
  background:none; color:var(--g-ink); font:inherit; text-align:start; cursor:pointer;
}
.mc-fold:focus-visible { outline:2px solid var(--g-teal); outline-offset:4px; }
.mc-fold-ico {
  flex:none; display:grid; place-items:center; width:26px; height:26px; border-radius:8px;
  background:var(--g-flat-soft); color:var(--g-ink-2); transition:transform .15s;
}
.mc-fold:hover .mc-fold-ico { color:var(--g-teal-ink); }
.mc-fold[aria-expanded="true"] .mc-fold-ico { transform:rotate(180deg); }
.mc-fold-t { display:inline-flex; align-items:center; gap:8px; }
.mc-sig-sum {
  margin-inline-start:auto; display:inline-flex; flex-wrap:wrap; align-items:baseline; gap:2px 8px;
  font-size:13px; font-weight:700; line-height:1.8; color:var(--g-ink-2);
}
.mc-sig-sum b { font-size:14.5px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; }
.mc-sig-sum b.up { color:var(--g-up); } .mc-sig-sum b.down { color:var(--g-down); }
.mc-sig-basis { font-size:12px; color:var(--g-ink-3); }
.mc-sig-body { display:flex; flex-direction:column; gap:12px; min-width:0; }
.mc-sig-body > .ct-note { margin:0; }
.mc-sig-counts { margin-top:-4px; }
.mc-sig-list { list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:8px; }
.mc-sig {
  display:grid; grid-template-columns:minmax(0, 1fr) auto; grid-template-areas:"src when" "res res" "lvl lvl";
  align-items:center; gap:6px 12px; min-width:0; padding:10px 12px; border:1px solid var(--g-line-soft); border-radius:12px;
}
.mc-sig.open { border-color:var(--g-teal-line); }
.mc-sig-src { grid-area:src; display:flex; align-items:center; gap:8px; min-width:0; }
.mc-sig-src .ct-avatar { width:26px; height:26px; font-size:11px; }
.mc-sig-name { min-width:0; font-size:13.5px; font-weight:800; color:var(--g-ink); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-sig-when { grid-area:when; font-size:12px; font-weight:700; color:var(--g-ink-3); white-space:nowrap; }
.mc-sig-res { grid-area:res; display:flex; flex-wrap:wrap; align-items:center; gap:6px 8px; min-width:0; }
.mc-sig-res .ct-res b.up { color:var(--g-up); }
.mc-sig-res .ct-res b.down { color:var(--g-down); }
.mc-sig-r { font-size:11.5px; font-weight:700; color:var(--g-ink-3); }
.mc-sig .ct-levels { grid-area:lvl; min-width:0; }
.mc-sig .ct-levels small { font-size:11px; font-weight:600; color:var(--g-ink-3); }
.mc-sig-live { font-weight:700; color:var(--g-ink-2); }
.mc-sig-live.in, .mc-sig-live.in bdi { color:var(--g-teal-ink); }
.mc-sig-live.done { color:var(--g-star); }
.mc-sig-stale { color:var(--g-star); }
/* Wide screens: one line per signal (source · state · levels · time). */
@media (min-width:900px) {
  .mc-sig { grid-template-columns:minmax(0, 200px) max-content minmax(0, 1fr) max-content; grid-template-areas:"src res lvl when"; padding:8px 14px; }
}

/* the section's filter (past 10 sources), a source's name and its «×» */
.mc-filter { position:relative; display:flex; align-items:center; }
.mc-filter .ico { position:absolute; inset-inline-start:12px; color:var(--g-ink-3); pointer-events:none; }
.mc-filter-input {
  width:100%; height:40px; padding-block:0; padding-inline:38px 12px; border:1px solid var(--g-line); border-radius:12px;
  background:var(--g-card); color:var(--g-ink); font-family:inherit; font-size:14px; outline:none;
}
.mc-filter-input::placeholder { color:var(--g-ink-3); }
.mc-filter-input:focus { border-color:var(--g-teal); }
:root[data-theme="dark"] .mc-filter-input { color-scheme:dark; }
.mc-name {
  min-width:0; max-width:100%; margin:0; padding:0; border:0; background:none; color:var(--g-ink); font-family:inherit;
  font-size:14.5px; font-weight:800; line-height:1.6; text-align:start; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
button.mc-name { cursor:pointer; }
button.mc-name:hover { color:var(--g-teal-ink); text-decoration:underline; }
.mc-x {
  justify-self:end; display:grid; place-items:center; width:34px; height:34px; border-radius:10px; border:0;
  background:none; color:var(--g-ink-3); cursor:pointer;
}
.mc-x:hover, .mc-x:focus-visible { background:var(--g-down-soft); color:var(--g-down); }
.mc-x .ct-spin { width:14px; height:14px; }
/* billing (only with checkout open and free mode off): a table on wide screens, stacked rows on phones */
.mc-bill-total {
  display:flex; flex-wrap:wrap; align-items:baseline; gap:4px 12px; padding:12px 14px; border-radius:12px;
  background:var(--g-teal-soft); border:1px solid var(--g-teal-line);
}
.mc-bill-total span { font-size:13px; font-weight:700; color:var(--g-ink-2); }
.mc-bill-total b { font-size:18px; font-weight:800; color:var(--g-teal-ink); }
.mc-bill-total small { flex-basis:100%; font-size:12px; font-weight:600; color:var(--g-ink-3); }
.mc-bill-wrap { overflow-x:auto; border:1px solid var(--g-line-soft); border-radius:12px; }
.mc-bill td small { display:block; font-size:11px; font-weight:600; color:var(--g-ink-3); }
.mc-bill tbody th { text-align:start; }
.mc-pay-row { max-width:520px; }

/* ---- the anchored panel and the dialog ---- */
.mc-pop {
  position:fixed; z-index:70; display:flex; flex-direction:column; gap:8px; padding:12px;
  background:var(--g-card); border:1px solid var(--g-line); border-radius:14px; box-shadow:var(--g-pop);
  font-size:13px; line-height:1.9; color:var(--g-ink-2); text-align:start;
}
.mc-pop p { margin:0; }
.mc-pop-btn {
  height:38px; padding:0 12px; border-radius:10px; border:1px solid var(--g-line); background:var(--g-card); color:var(--g-ink);
  font-family:inherit; font-size:13px; font-weight:800; cursor:pointer;
}
.mc-pop-btn:hover { border-color:var(--g-teal-line); }
.mc-pop-btn.primary { background:var(--g-teal); border-color:var(--g-teal); color:#fff; }
:root[data-theme="dark"] .mc-pop-btn.primary { color:#0B1314; }
.mc-pop-btn.danger { color:var(--g-down); }
.mc-pop-btn.danger:hover { border-color:var(--g-down); }
.mc-scrim { position:fixed; inset:0; z-index:90; display:grid; place-items:center; padding:16px; background:var(--g-scrim); }
.mc-dialog {
  width:min(560px, 100%); max-height:calc(100vh - 32px); max-height:calc(100dvh - 32px); overflow-y:auto;
  background:var(--g-card); border:1px solid var(--g-line); border-radius:18px; box-shadow:var(--g-pop);
  padding:18px; display:flex; flex-direction:column; gap:12px;
}
.mc-dialog h2 { margin:0; font-size:17px; font-weight:800; }
.mc-dialog-text { font-size:14px; line-height:2; color:var(--g-ink-2); display:flex; flex-direction:column; gap:10px; }
.mc-dialog-text p { margin:0; }
.mc-dialog-actions { display:flex; flex-wrap:wrap; gap:8px; }
.mc-cmp { display:grid; grid-template-columns:repeat(2, minmax(0, 1fr)); gap:10px; }
.mc-cmp-col { min-width:0; padding:12px; border:1px solid var(--g-line); border-radius:14px; display:flex; flex-direction:column; gap:8px; }
.mc-cmp-col:last-child { border-color:var(--g-teal-line); background:var(--g-teal-soft); }
.mc-cmp-role { margin:0; font-size:11.5px; font-weight:800; color:var(--g-ink-3); }
.mc-cmp-name { margin:0; display:flex; align-items:center; gap:8px; font-size:14.5px; font-weight:800; color:var(--g-ink); min-width:0; }
.mc-cmp-name .ct-avatar { width:32px; height:32px; font-size:13px; }
.mc-cmp dl { margin:0; display:flex; flex-direction:column; }
.mc-cmp dl > div { display:flex; justify-content:space-between; align-items:baseline; gap:8px; padding:5px 0; border-top:1px solid var(--g-line-soft); }
.mc-cmp dt { font-size:12px; font-weight:700; color:var(--g-ink-3); }
.mc-cmp dd { margin:0; font-size:13px; font-weight:800; white-space:nowrap; }
/* the comparisons' chart (both lines on one chart) and table */
.mc-dialog.wide { width:min(720px, 100%); }
.mc-cmp-plot { display:flex; flex-direction:column; gap:6px; min-width:0; }
.mc-cmp-chart { direction:ltr; min-width:0; }
.mc-cmp-chart svg { display:block; width:100%; height:auto; overflow:visible; }
.mc-cmp-chart text { font-family:inherit; font-size:11px; fill:var(--g-ink-3); }
.mc-cmp-legend { list-style:none; margin:0; padding:0; display:flex; flex-wrap:wrap; gap:4px 14px; font-size:12.5px; font-weight:700; line-height:1.8; color:var(--g-ink-2); }
.mc-cmp-legend li { display:inline-flex; align-items:center; gap:6px; min-width:0; max-width:100%; }
.mc-cmp-legend li.bold { color:var(--g-ink); font-weight:800; }
.mc-cmp-legend i { flex:none; width:16px; height:3px; border-radius:2px; background:var(--c); }
.mc-cmp-legend li.bold i { height:5px; }
.mc-cmp-legend bdi { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-cmp-table tr.mc-cand > * { background:var(--g-teal-soft); }
.mc-cmp-table tbody th .mc-chip { margin-inline-start:4px; }
.mc-dialog .ct-month-wrap + .ct-note, .mc-dialog .mc-cmp + .ct-note { margin:0; font-size:12px; line-height:1.9; }

@media (prefers-reduced-motion:reduce) {
  .mc-cta, .mc-btn, .mc-fold-ico { transition:none; }
}

/* ---- smaller screens ---- */
@media (max-width:760px) {
  .mc-dash { gap:14px; }
  .mc-box { padding:16px; border-radius:16px; }
  .mc-chart { height:220px; }
}
@media (max-width:600px) {
  /* The Mother Card: the photos and «مدیریت کانال ←», the title, then three equal figures, each value over its label. */
  .mc-mother { grid-template-columns:minmax(0, 1fr) auto; grid-template-areas:"open manage" "id id" "figs figs" "note note"; gap:10px 12px; padding:12px 14px; }
  .mc-figs { display:grid; grid-template-columns:repeat(3, minmax(0, 1fr)); }
  .mc-fig { padding-inline:10px; }
  .mc-fig dd { order:-1; font-size:15px; }
  .mc-fig dt { font-size:11px; white-space:normal; }
  /* The signals' summary under their title. */
  .mc-sig-sum { margin-inline-start:0; flex-basis:100%; padding-inline-start:38px; }
  .mc-cmp { grid-template-columns:minmax(0, 1fr); }
  .mc-dialog-actions .mc-btn { flex:1 1 100%; }
  /* Billing: each row a small card, its labels beside the values. */
  .mc-bill-wrap { overflow:visible; border:0; border-radius:0; }
  .mc-bill thead { display:none; }
  .mc-bill, .mc-bill tbody, .mc-bill tr, .mc-bill th, .mc-bill td { display:block; width:100%; }
  .mc-bill tr { margin-bottom:8px; padding:6px 12px; border:1px solid var(--g-line-soft); border-radius:12px; }
  .mc-bill tbody tr:last-child > * { border-bottom:0; }
  .mc-bill th, .mc-bill td {
    display:flex; justify-content:space-between; align-items:baseline; gap:12px; padding:5px 0; white-space:normal; text-align:end;
    border-bottom:1px solid var(--g-line-soft);
  }
  .mc-bill tr > *:last-child { border-bottom:0; }
  .mc-bill th::before, .mc-bill td::before { content:attr(data-label); flex:none; font-size:12px; font-weight:700; color:var(--g-ink-3); }
  .mc-bill td small { display:inline; margin-inline-start:6px; }
}
@media (max-width:420px) {
  .mc-box { padding:14px; }
  .mc-status-ico { display:none; }
  .mc-cell-name { max-width:120px; }
}

/* ---- Personal and Professional (owner, 2026-10-17), phase 1 ----
   The entry: two big cards and their comparison; PERSONAL's chip, cap and upgrade; PROFESSIONAL's logo, its
   sending in the status box, today, the standings in «عملکرد کانال و منابع», and its branding dialog.
   Only the page's tokens, light and dark; 44 px targets; no page scroll sideways at 320 px. */
.mc-btn.outline { border-color:var(--g-teal-line); color:var(--g-teal-ink); }
.mc-btn.outline:hover { border-color:var(--g-teal); background:var(--g-teal-soft); }
.mc-btn.big { min-height:48px; }

/* the entry: a heading, the two cards (side by side from 720 px), the comparison card */
.mc-entry { display:flex; flex-direction:column; gap:16px; min-width:0; }
.mc-entry:focus { outline:none; }
.mc-entry-head { display:flex; flex-direction:column; gap:4px; padding:0 4px; }
.mc-entry-head h2 { margin:0; font-size:18px; font-weight:800; color:var(--g-ink); }
.mc-entry-back { padding:0 4px; }
.mc-entry-back .mc-link { min-height:44px; }
.mc-plans { display:grid; grid-template-columns:minmax(0, 1fr); gap:14px; }
@media (min-width:720px) { .mc-plans { grid-template-columns:repeat(2, minmax(0, 1fr)); } }
.mc-plan {
  min-width:0; display:flex; flex-direction:column; gap:12px; padding:20px 22px;
  background:var(--g-card); border:1px solid var(--g-line); border-radius:20px; box-shadow:var(--g-shadow);
}
.mc-plan.pro { border-color:var(--g-teal-line); background:linear-gradient(180deg, var(--g-teal-soft), var(--g-card) 140px); }
.mc-plan.on { box-shadow:0 0 0 2px var(--g-teal); }
.mc-plan-top { display:flex; align-items:center; flex-wrap:wrap; gap:6px 10px; min-width:0; }
.mc-plan-emoji {
  flex:none; display:grid; place-items:center; width:46px; height:46px; border-radius:14px;
  background:var(--g-flat-soft); font-size:24px; line-height:1;
}
.mc-plan.pro .mc-plan-emoji { background:var(--g-card); box-shadow:inset 0 0 0 1px var(--g-teal-line); }
.mc-plan-top h3 { margin:0; flex:1 1 auto; min-width:0; font-size:19px; font-weight:800; line-height:1.5; color:var(--g-ink); }
.mc-plan-line { margin:0; font-size:14px; font-weight:600; line-height:2; color:var(--g-ink-2); }
.mc-plan-list { list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:6px; }
.mc-plan-list li { display:flex; align-items:flex-start; gap:8px; font-size:14px; font-weight:700; line-height:1.8; color:var(--g-ink); }
.mc-plan-list .ico { flex:none; margin-top:4px; color:var(--g-teal); }
.mc-plan-cta { margin-top:auto; width:100%; }
.mc-plan-cta[aria-disabled="true"] { opacity:.6; cursor:progress; }
/* the comparison card: a real table, three columns, the Professional one tinted */
.mc-plan-cmp {
  min-width:0; display:flex; flex-direction:column; gap:12px; padding:18px 20px;
  background:var(--g-card); border:1px solid var(--g-line); border-radius:20px; box-shadow:var(--g-shadow);
}
.mc-plan-cmp h3 { margin:0; font-size:16px; font-weight:800; color:var(--g-ink); }
.mc-plan-wrap { min-width:0; border:1px solid var(--g-line-soft); border-radius:14px; overflow:hidden; }
.mc-plan-table { width:100%; border-collapse:collapse; table-layout:fixed; font-size:13.5px; font-weight:700; color:var(--g-ink-2); }
.mc-plan-table th, .mc-plan-table td { padding:10px 12px; border-bottom:1px solid var(--g-line-soft); text-align:center; line-height:1.7; overflow-wrap:anywhere; }
.mc-plan-table thead th { background:var(--g-flat-soft); color:var(--g-ink); font-size:13.5px; font-weight:800; }
.mc-plan-table thead th:first-child { width:38%; }
.mc-plan-table tbody th { text-align:start; font-weight:800; color:var(--g-ink); }
.mc-plan-table tbody tr:last-child > * { border-bottom:0; }
.mc-plan-table .pro { background:var(--g-teal-soft); color:var(--mc-teal-ink); }
.mc-plan-table thead th.pro { color:var(--mc-teal-ink); }
.mc-yes { font-size:16px; font-weight:800; color:var(--g-up); }
.mc-plan-table .pro .mc-yes { color:var(--mc-teal-ink); }
/* the same card in the upgrade's dialog: the dialog is the card */
.mc-plan-cmp.in-dialog { padding:0; border:0; border-radius:0; background:none; box-shadow:none; gap:8px; }
.mc-plan-cmp.in-dialog h3 { font-size:14.5px; }
.mc-dialog-text .mc-upgrade-oneway { color:var(--g-ink); }
.mc-no { color:var(--g-ink-3); }
.mc-plan-free { margin:0; font-size:12.5px; font-weight:700; line-height:1.9; color:var(--g-ink-3); }
@media (max-width:600px) {
  .mc-plan { padding:16px; border-radius:18px; }
  .mc-plan-cmp { padding:14px 12px; border-radius:18px; }
  .mc-plan-table { font-size:12.5px; }
  .mc-plan-table th, .mc-plan-table td { padding:8px 6px; }
  .mc-plan-table thead th { font-size:12px; }
  .mc-plan-table thead th:first-child { width:34%; }
}
/* the type chosen, over the connect guide */
.mc-usage-line { margin:0; display:flex; flex-wrap:wrap; align-items:center; gap:2px 8px; font-size:13px; font-weight:700; color:var(--g-ink-3); }
.mc-usage-line b { color:var(--g-ink); font-weight:800; }
.mc-usage-line .mc-link { min-height:44px; padding:0 4px; }

/* the status card: the type's chip, «ارتقا به کانال حرفه‌ای», a Professional channel's logo */
.mc-type { background:var(--g-flat-soft); color:var(--g-ink-2); }
.mc-type.pro { background:var(--g-teal-soft); color:var(--mc-teal-ink); box-shadow:inset 0 0 0 1px var(--g-teal-line); }
.mc-upgrade { position:relative; padding:0 2px; font-size:12.5px; white-space:nowrap; }
.mc-upgrade::after { content:''; position:absolute; inset:-14px -4px; }   /* a 44 px target around a small link */
.mc-upgrade:disabled { color:var(--g-ink-3); cursor:progress; }
.mc-brand-logo {
  flex:none; display:grid; place-items:center; width:40px; height:40px; border-radius:12px; overflow:hidden; object-fit:cover;
  background:var(--g-teal-soft); color:var(--g-teal-ink); font-size:18px; font-weight:800; line-height:1;
}
.mc-brand-logo.mono { box-shadow:inset 0 0 0 1px var(--g-teal-line); }
img.mc-brand-logo { background:var(--g-flat-soft); }
.mc-mother-logo { width:22px; height:22px; border-radius:7px; font-size:12px; }
.mc-price { margin-top:-4px; display:flex; flex-wrap:wrap; align-items:baseline; gap:2px 8px; }
.mc-price b { color:var(--g-ink); font-weight:800; }

/* PERSONAL: «۷ از ۱۰ منبع» (amber at the cap), the line of a channel above its cap */
.mc-cap {
  display:inline-grid; place-items:center; height:24px; padding:0 9px; border-radius:99px;
  background:var(--g-flat-soft); color:var(--g-ink-2); font-size:12px; font-weight:800; white-space:nowrap;
}
.mc-cap.warn { background:var(--g-amber-soft); color:var(--g-amber-ink); box-shadow:inset 0 0 0 1px var(--g-amber-line); }
.mc-over .mc-link { padding:0; font-size:13px; }

/* PROFESSIONAL: a source's standing, a dot and its word (green, amber, red); in the table a button whose panel says why */
.mc-stand { display:inline-flex; align-items:center; gap:2px 6px; font-size:12px; font-weight:800; line-height:1.7; white-space:nowrap; }
.mc-stand > i { flex:none; width:8px; height:8px; border-radius:50%; background:currentColor; }
.mc-stand.good { color:var(--mc-up-ink); }
.mc-stand.review { color:var(--g-amber-ink); }
.mc-stand.weak { color:var(--g-down); }
button.mc-stand { position:relative; margin:0; padding:3px 9px; border:0; border-radius:99px; background:none; font-family:inherit; cursor:pointer; }
button.mc-stand::after { content:''; position:absolute; inset:-9px -2px; }   /* a 44 px target around a small word */
button.mc-stand:hover, button.mc-stand[aria-expanded="true"] { background:var(--g-flat-soft); }
.mc-stand-s { display:none; }   /* the short word: a phone's row only */

/* 3. «عملکرد امروز»: five tiles */
.mc-today-tiles { margin:0; display:grid; grid-template-columns:repeat(5, minmax(0, 1fr)); gap:10px; }
.mc-today-tile {
  min-width:0; display:flex; flex-direction:column; align-items:center; gap:2px; padding:12px 6px; border-radius:14px;
  background:var(--g-flat-soft); text-align:center;
}
.mc-today-tile dt { order:2; font-size:12.5px; font-weight:800; color:var(--g-ink-3); }
.mc-today-tile dd { order:1; margin:0; font-size:24px; font-weight:800; line-height:1.3; color:var(--g-ink); font-variant-numeric:tabular-nums; }
.mc-today-tile.up dd { color:var(--g-up); }
.mc-today-tile.down dd { color:var(--g-down); }
.mc-today .mc-meta { margin-top:-4px; }

/* The sending, the status box's second line (owner, 2026-10-17: the old «وضعیت ارسال» box): «● ارسال فعال · آخرین
   ارسال … · امروز n ارسال · n خطا», under the channel's name (past its logo); the day's unsent signals folded under it. */
.mc-deliv-line {
  display:flex; flex-wrap:wrap; align-items:center; gap:2px 8px; margin-top:-6px; padding-inline-start:52px;
  font-size:12.5px; font-weight:700; line-height:1.8; color:var(--g-ink-2);
}
.mc-deliv-state { display:inline-flex; align-items:center; flex-wrap:wrap; gap:2px 6px; }
.mc-deliv-state > i { flex:none; width:8px; height:8px; border-radius:50%; background:currentColor; box-shadow:0 0 0 3px var(--g-flat-soft); }
.mc-deliv-state > b { font-weight:800; }
.mc-deliv-state.ok { color:var(--mc-up-ink); }
.mc-deliv-state.warn { color:var(--g-amber-ink); }
.mc-deliv-state.bad { color:var(--g-down); }
.mc-deliv-why { font-weight:700; color:var(--g-ink-2); }
.mc-deliv-facts { display:inline-flex; flex-wrap:wrap; align-items:center; gap:2px 8px; min-width:0; }
.mc-deliv-facts b { color:var(--g-ink); font-weight:800; font-variant-numeric:tabular-nums; }
.mc-deliv-err.bad, .mc-deliv-err.bad b { color:var(--g-down); }
.mc-deliv-line + .mc-skipped { margin-top:-6px; padding-inline-start:52px; }

/* 4. «عملکرد کانال و منابع» (owner, 2026-10-17: the Mother Card, «نمودار عملکرد», «مقایسه منابع» and «منابع
   منتخب» in one section): its head (the count and the period), the strip (the channel in the period and a small
   curve), the folded chart, then one table, a row per source; on phones each row a small card of three lines. */
.mc-hub { gap:16px; }
.mc-hub-head { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:10px 16px; }
.mc-hub-head h2 { margin:0; display:flex; align-items:center; flex-wrap:wrap; gap:4px 10px; font-size:16px; font-weight:800; }
.mc-hub-head .mc-count { padding:0 9px; }
.mc-period-seg button { min-width:68px; }
.mc-hub-strip {
  display:flex; align-items:center; justify-content:space-between; gap:10px 24px; min-width:0; padding:12px 16px; border-radius:14px;
  background:var(--g-flat-soft);
}
.mc-hub-sum { min-width:0; display:flex; flex-direction:column; gap:2px; }
.mc-hub-k { margin:0; display:flex; flex-wrap:wrap; align-items:center; gap:0 8px; font-size:12.5px; font-weight:700; line-height:1.9; color:var(--g-ink-2); }
.mc-hub-k > b { color:var(--g-ink); font-weight:800; }
.mc-hub-figs { margin:0; display:flex; flex-wrap:wrap; align-items:baseline; gap:2px 10px; font-size:13.5px; font-weight:700; line-height:1.8; color:var(--g-ink-2); }
.mc-hub-figs b { font-size:18px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; }
.mc-hub-figs b.up { color:var(--g-up); }
.mc-hub-figs b.down { color:var(--g-down); }
.mc-hub-figs.none { font-size:13.5px; }
.mc-spark { flex:none; width:160px; height:36px; direction:ltr; }
.mc-spark svg { display:block; width:100%; height:100%; overflow:visible; }
.mc-spark-line { fill:none; stroke:var(--mc-combined); stroke-width:2; stroke-linejoin:round; stroke-linecap:round; vector-effect:non-scaling-stroke; }
.mc-spark-zero { stroke:var(--g-ink-3); stroke-opacity:.45; stroke-dasharray:3 3; vector-effect:non-scaling-stroke; }
.mc-spark.ct-skel { display:flex; align-items:center; }
.mc-spark.ct-skel .bar { width:100%; height:6px; }
/* «نمودار کامل» (Personal: «نمودار»), folded: closed by default, kept for this browser tab */
.mc-hub-chart { display:flex; flex-direction:column; gap:12px; min-width:0; }
.mc-chart-h { font-size:14px; }
.mc-chart-h .mc-fold { min-height:40px; }
.mc-hub-chart-body { display:flex; flex-direction:column; gap:12px; min-width:0; }
.mc-hub-chart-body[hidden] { display:none; }
.mc-hub-chart-body .ct-note { margin:0; }
/* the table: sortable heads, the period's growth first; a filter past 10 sources */
.mc-hub-tools { display:flex; flex-direction:column; gap:10px; min-width:0; }
.mc-hub-phone { display:none; }
@media (min-width:761px) { .mc-hub-tools:not(:has(.mc-filter)) { display:none; } }
.mc-hub-wrap { min-width:0; overflow-x:auto; border:1px solid var(--g-line-soft); border-radius:12px; }
.mc-hub-wrap:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-hub-table th, .mc-hub-table td { padding:8px 10px; vertical-align:middle; }
.mc-hub-table thead button { min-height:32px; }
.mc-hub-table tbody th { text-align:start; }
.mc-h-who { display:flex; align-items:center; gap:10px; min-width:0; max-width:250px; }
.mc-h-who .ct-avatar { flex:none; width:30px; height:30px; font-size:12px; }
.mc-h-id { min-width:0; display:flex; flex-direction:column; align-items:flex-start; gap:2px; }
.mc-h-id .mc-name { font-size:14px; }
.mc-h-id .mc-chip { max-width:100%; }
.mc-h-gv { font-size:14px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; }
.mc-h-gv.up { color:var(--g-up); }
.mc-h-gv.down { color:var(--g-down); }
.mc-hub-table td .down { color:var(--g-down); }
.mc-h-lab { display:none; }
td.mc-h-sub { display:none; }
.mc-h-rrh { display:inline-flex; align-items:center; gap:2px; }
.mc-rr-tip { position:relative; width:26px; height:26px; }
.mc-rr-tip::after { content:''; position:absolute; inset:-9px; }   /* a 44 px target around a small ⓘ */
/* each source's own risk-reward: a compact select, saved at once (its own value in teal; «پیشنهادی منبع» in amber) */
.mc-rr-cell { display:inline-flex; align-items:center; justify-content:center; flex-wrap:wrap; gap:2px 6px; }
.mc-rr-select {
  height:34px; max-width:100%; padding:0 8px; border-radius:9px; border:1px solid var(--g-line); background:var(--g-card); color:var(--g-ink-2);
  font-family:inherit; font-size:12.5px; font-weight:700; cursor:pointer; field-sizing:content;
}
.mc-rr-select.set { border-color:var(--g-teal-line); color:var(--mc-teal-ink); font-weight:800; }
.mc-rr-select.best { border-color:var(--g-amber-line); color:var(--g-amber-ink); }
.mc-rr-select option { color:var(--g-ink); font-weight:700; }
.mc-rr-select option.mc-opt-best { color:var(--g-amber-ink); }
.mc-rr-select:hover { border-color:var(--g-teal-line); }
.mc-rr-select:focus-visible { outline:2px solid var(--g-teal); outline-offset:1px; border-color:var(--g-teal); }
.mc-rr-select:disabled { opacity:.65; cursor:progress; }
:root[data-theme="dark"] .mc-rr-select { color-scheme:dark; }
.mc-rr-cell .ct-spin { width:13px; height:13px; }
.mc-rr-cell .mc-saved { font-size:12px; }
.mc-rr-used { display:block; margin-top:2px; font-size:11px; font-weight:600; line-height:1.6; color:var(--g-ink-3); white-space:normal; }
/* «جایگزین؟» (the server's suggestion for this source: its comparison) and «×» */
.mc-h-acts { display:inline-flex; align-items:center; justify-content:flex-end; gap:6px; }
.mc-swap {
  position:relative; min-height:32px; padding:0 11px; border-radius:99px; border:1px solid var(--g-amber-line); background:var(--g-amber-soft);
  color:var(--g-amber-ink); font-family:inherit; font-size:12px; font-weight:800; white-space:nowrap; cursor:pointer;
}
.mc-swap::after { content:''; position:absolute; inset:-6px -2px; }   /* a 44 px target */
.mc-swap:hover { border-color:var(--g-amber); }
.mc-swap[aria-busy="true"] { opacity:.6; cursor:progress; }
.mc-h-alert td { padding:0 12px 10px; text-align:start; white-space:normal; }
.mc-h-alert .ct-add-error { margin:0; }
.mc-hub-foot { display:flex; flex-wrap:wrap; align-items:center; gap:0 24px; margin-top:-6px; }
.mc-hub-foot .mc-link { min-height:40px; }
.mc-hub-note { margin:-8px 0 0; }
/* the panels by a standing or the ⓘ */
.mc-pop-h { display:flex; flex-wrap:wrap; align-items:center; gap:2px 10px; font-weight:800; color:var(--g-ink); }
.mc-pop-why { color:var(--g-ink-2); }
.mc-pop-sug { font-size:12.5px; color:var(--g-ink-2); }
.mc-pop-sug .up { color:var(--g-up); }
.mc-pop-sug .down { color:var(--g-down); }
/* The tablet's copy of the overlap note (the review of 2026-10-18): a row of its own under the source's, the table's
   width, shown at 761–1000 px alone (there the name's column is too narrow for it: seven lines in 70 px). */
.mc-hub-table tr.mc-h-ovrow { display:none; }
.mc-hub-table tr.mc-h-ovrow td { padding:0 12px 10px; text-align:start; white-space:normal; }
/* Narrower screens: the table scrolls inside its own frame before it becomes cards. */
@media (max-width:1000px) and (min-width:761px) {
  .mc-h-who { max-width:180px; }
  .mc-hub-table tr.mc-h-ovrow { display:table-row; }
  .mc-hub-table .mc-h-id .mc-overlap { display:none; }
  .mc-hub-table tr:has(+ tr.mc-h-ovrow) > * { border-bottom-color:transparent; }
}
/* Phones: each source a card of three lines (who · standing · growth; its figures, small; its risk-reward and actions);
   the heads hidden, so the order is a select and the risk-reward's ⓘ sits beside it; every target 44 px. */
@media (max-width:760px) {
  .mc-hub-strip { flex-direction:column; align-items:stretch; padding:12px 14px; }
  .mc-spark { width:100%; height:40px; }
  .mc-hub-head .mc-period-seg { flex:1 1 100%; }
  .mc-hub-head .mc-period-seg button { flex:1 1 0; min-width:0; height:44px; }
  .mc-hub-phone { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:6px 12px; }
  .mc-hub-sort { display:inline-flex; align-items:center; gap:8px; font-size:12.5px; font-weight:700; color:var(--g-ink-2); }
  .mc-hub-sort .mc-basis-select { height:44px; }
  .mc-hub-rrk { display:inline-flex; align-items:center; gap:4px; font-size:12.5px; font-weight:700; color:var(--g-ink-2); }
  .mc-hub-wrap { overflow:visible; border:0; border-radius:0; }
  .mc-hub-table thead { display:none; }
  .mc-hub-table, .mc-hub-table tbody { display:block; width:100%; }
  .mc-hub-table tr {
    display:grid; grid-template-columns:minmax(0, 1fr) auto auto; grid-template-areas:"src st g" "sub sub sub" "rr rr act";
    align-items:center; gap:2px 10px; margin-bottom:8px; padding:8px 12px; border:1px solid var(--g-line-soft); border-radius:12px;
  }
  .mc-hub-table:not(.pro) tr { grid-template-areas:"src src g" "sub sub sub" "rr rr act"; }
  .mc-hub-table th, .mc-hub-table td { display:block; min-width:0; padding:0; border:0; background:none; text-align:start; white-space:nowrap; }
  .mc-hub-table .hl { background:none; }
  .mc-hub-table .mc-h-src { grid-area:src; }
  .mc-hub-table .mc-h-standing { grid-area:st; }
  .mc-hub-table .mc-h-growth { grid-area:g; text-align:end; }
  .mc-hub-table td.mc-h-win, .mc-hub-table td.mc-h-perDay, .mc-hub-table td.mc-h-dd { display:none; }
  .mc-hub-table td.mc-h-sub {
    grid-area:sub; display:flex; flex-wrap:wrap; align-items:center; gap:0 8px; padding-inline-start:40px;
    font-size:12px; font-weight:700; line-height:1.9; color:var(--g-ink-3); white-space:normal;
  }
  .mc-hub-table .mc-h-id .mc-overlap { display:none; }
  .mc-hub-table td.mc-h-sub .mc-overlap-sub { flex:1 1 100%; }
  .mc-hub-table .mc-h-rr { grid-area:rr; }
  .mc-hub-table .mc-h-act { grid-area:act; justify-self:end; }
  .mc-hub-table .mc-h-who { max-width:none; }
  .mc-hub-table .mc-h-id .mc-name { position:relative; }
  .mc-hub-table .mc-h-id button.mc-name::after { content:''; position:absolute; inset:-11px 0; }   /* a 44 px target */
  .mc-hub-table .mc-h-gv { font-size:15px; }
  .mc-hub-table .mc-stand-w { display:none; }
  .mc-hub-table .mc-stand-s { display:inline; }
  /* its risk-reward: a small caption over the select (one look in every row, whatever the option's length) */
  .mc-hub-table .mc-rr-cell { display:inline-grid; grid-template-columns:minmax(0, auto) auto auto; justify-content:start; align-items:center; gap:0 6px; max-width:100%; }
  .mc-hub-table .mc-rr-cell .mc-h-lab { display:block; grid-column:1 / -1; font-size:11.5px; font-weight:700; line-height:1.7; color:var(--g-ink-3); }
  .mc-hub-table .mc-h-act { align-self:end; }
  .mc-hub-table .mc-rr-select { height:44px; }
  .mc-hub-table .mc-x { width:44px; height:44px; }
  .mc-hub-table .mc-swap { min-height:36px; }
  .mc-hub-table .mc-swap::after { inset:-4px -2px; }
  .mc-hub-table tr.mc-h-alert { display:block; margin:-6px 0 8px; padding:0 4px; border:0; }
  .mc-hub-table tr.mc-h-alert td { padding:0; white-space:normal; }   /* the cards' nowrap is for their figures, never a refusal */
  .mc-hub-foot .mc-link { min-height:44px; }
  .mc-chart-h .mc-fold { min-height:44px; }
  .mc-deliv-line, .mc-deliv-line + .mc-skipped { padding-inline-start:0; }
  .mc-deliv-line { margin-top:-4px; }
}
@media (max-width:600px) {
  .mc-deliv-facts { flex-basis:100%; }
  .mc-deliv-facts > .mc-sep:first-child { display:none; }
}
/* Narrow phones: a row with «جایگزین؟» puts its actions under the risk-reward's select (the narrowest, every row). */
@media (max-width:420px) {
  .mc-hub-table.pro tr.mc-h-swaps { grid-template-areas:"src st g" "sub sub sub" "rr rr rr" "act act act"; }
  .mc-hub-table:not(.pro) tr.mc-h-swaps { grid-template-areas:"src src g" "sub sub sub" "rr rr rr" "act act act"; }
}
@media (max-width:350px) {
  .mc-hub-table.pro tr { grid-template-areas:"src st g" "sub sub sub" "rr rr rr" "act act act"; }
  .mc-hub-table:not(.pro) tr { grid-template-areas:"src src g" "sub sub sub" "rr rr rr" "act act act"; }
}




/* the branding dialog: the name, the logo's preview and its buttons, the note */
.mc-brand-box { width:min(520px, 100%); }
.mc-brand-form { display:flex; flex-direction:column; gap:14px; min-width:0; }
.mc-brand-field { display:flex; flex-direction:column; gap:6px; min-width:0; }
/* the site's .ct-add-input is flex:1 (a row's); in this column its 0 basis would squash the 44 px height */
.mc-brand-field .ct-add-input { flex:none; }
.mc-brand-row { display:flex; align-items:center; flex-wrap:wrap; gap:12px 16px; min-width:0; }
.mc-brand-prev { flex:none; display:grid; place-items:center; width:72px; height:72px; border-radius:18px; overflow:hidden; background:var(--g-flat-soft); }
.mc-brand-prev img { display:block; width:100%; height:100%; object-fit:cover; }
.mc-brand-prev .mc-brand-logo { width:72px; height:72px; border-radius:18px; font-size:30px; }
.mc-brand-acts { display:flex; flex-wrap:wrap; gap:8px; min-width:0; }
.mc-brand-acts .mc-btn { height:44px; }
.mc-file { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0 0 0 0); clip-path:inset(50%); white-space:nowrap; border:0; }
.mc-file:focus-visible + label { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-brand-box .mc-dialog-actions .mc-btn { min-height:44px; }

@media (max-width:760px) {
  .mc-today-tiles { grid-template-columns:repeat(3, minmax(0, 1fr)); }
}
@media (max-width:600px) {
  .mc-today-tiles { gap:8px; }
  .mc-today-tile { padding:10px 4px; }
  .mc-today-tile dd { font-size:21px; }
}
@media (max-width:420px) {
  .mc-status-head .mc-status-logo { width:34px; height:34px; border-radius:10px; font-size:15px; }
}

/* ctnav release 1 (design §7.8, §7.10): a type's leaf — the steps a line each with the form in the third; its
   «راهنما» (owner, 20 October 2026 ~20:40, in «راهنمای اتصال و مقایسه»'s place) — the guide cards and the two types
   side by side, opened in place at the leaf's top. */
.mc-steps-mini { list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:10px; }
.mc-mini { display:flex; align-items:flex-start; gap:10px; min-width:0; padding:10px 12px; border-radius:12px; background:var(--g-flat-soft); }
.mc-mini.mc-step-now { background:var(--g-card); border:1px solid var(--g-teal-line); }
.mc-mini .mc-step-n { width:24px; height:24px; font-size:12.5px; margin-top:3px; }
.mc-mini-body { flex:1 1 auto; min-width:0; display:flex; flex-direction:column; gap:8px; }
.mc-mini-t { margin:0; display:flex; flex-wrap:wrap; gap:2px 8px; font-size:13.5px; line-height:2; color:var(--g-ink-2); }
.mc-mini-t b { color:var(--g-ink); font-weight:800; }
.mc-mini-body .ct-add-form { max-width:none; }
.mc-guide-page { display:flex; flex-direction:column; gap:12px; }
/* «راهنما»: a small button at the leaf's top (its end), the guide under it while open. */
.mc-leaf-guide { display:flex; flex-direction:column; gap:12px; min-width:0; }
.mc-leaf-bar { display:flex; justify-content:flex-end; }
.mc-guide-btn {
  display:inline-flex; align-items:center; gap:6px; min-height:44px; padding:0 14px; border-radius:99px; border:1px solid var(--g-line);
  background:var(--g-card); color:var(--g-teal-ink); font:inherit; font-size:13.5px; font-weight:800; cursor:pointer;
  /* «کدام نوع برای من مناسب است؟» brings it to the top (openGuide): under the site's sticky header, as #ctBarBox (the
     review of 21 October 2026: it landed under the header, focused and out of sight). */
  scroll-margin-top:112px;
}
@media (max-width:760px) { .mc-guide-btn { scroll-margin-top:104px; } }
.mc-guide-btn:hover { border-color:var(--g-teal-line); background:var(--g-teal-soft); }
.mc-guide-btn:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-guide-btn .mc-guide-caret { transition:transform .15s ease; }
.mc-guide-btn[aria-expanded="true"] { background:var(--g-teal-soft); border-color:var(--g-teal-line); }
.mc-guide-btn[aria-expanded="true"] .mc-guide-caret { transform:rotate(180deg); }
@media (prefers-reduced-motion:reduce) { .mc-guide-btn .mc-guide-caret { transition:none; } }
.mc-leaf-guide-body { display:flex; flex-direction:column; gap:12px; min-width:0; }
/* The other type's leaf of a connected channel: one line (where the channel is, or the upgrade). */
.mc-other { display:flex; flex-wrap:wrap; align-items:center; gap:4px 10px; }
.mc-other .mc-link { display:inline-flex; align-items:center; min-height:44px; text-decoration:none; }
.mc-other .mc-btn { height:44px; }
/* (ct4 review) «کانال سیگنال سازمانی»'s one-way line under the connect field (the hero that said it went). */
.mc-oneway { display:flex; align-items:flex-start; gap:6px; color:var(--g-ink-2); font-weight:700; }
.mc-oneway .ico { flex:none; margin-top:4px; }
.mc-cmp3 .mc-plan-table thead th:first-child { width:30%; }
.mc-off { gap:10px; }

/* ---- retire-org C3/C4 (owner, 28 October 2026): «سیگنال‌های کانال من», the day's and the week's signals, open under
   the status box. One markup: a card per signal in a narrow box (mobile first; each cell's label above its value), a
   real table once the box is 760 px wide or more (a container query: the box, not the window, decides; a browser
   without container queries keeps the cards). Numbers left to right and tabular; «بستن دستی» a danger outline,
   ≥ 44 px tall; the dialog's commit a solid danger. Light and dark from the page's tokens. ---- */
.mc-sl { container-type:inline-size; container-name:mcsl; }
.mc-sl-head { display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; }
.mc-sl-head h2 { margin:0; font-size:16px; font-weight:800; }
.mc-sl-tabs { flex:none; }
.mc-sl-tabs button { min-height:36px; min-width:64px; }
.mc-sl-tabs button:focus-visible { outline:2px solid var(--g-teal); outline-offset:2px; }
.mc-sl-count { margin-inline-start:auto; }
.mc-sl-wrap { min-width:0; }
.mc-sl-table { width:100%; border-collapse:separate; border-spacing:0; font-size:13px; }
.mc-sl-table caption { text-align:start; }
.mc-sl-table thead { display:none; }
.mc-sl-table tbody { display:flex; flex-direction:column; gap:8px; }
/* the card (≤ the table's width): line 1 source · time; line 2 side · result (status chip, pips); line 3 entry / TP / SL;
   line 4 the button, the card's width */
.mc-sl-row {
  display:grid; grid-template-columns:repeat(3, minmax(0, 1fr)); grid-template-areas:"src src when" "side res res" "e t s" "act act act";
  align-items:center; gap:8px 10px; padding:10px 12px; border:1px solid var(--g-line-soft); border-radius:12px; min-width:0;
}
.mc-sl-row.open { border-color:var(--g-teal-line); }
.mc-sl-row > * { padding:0; border:0; min-width:0; text-align:start; font-weight:inherit; }
.mc-sl-src { grid-area:src; }
.mc-sl-when { grid-area:when; justify-self:end; font-size:12px; font-weight:700; color:var(--g-ink-3); white-space:nowrap; }
.mc-sl-side { grid-area:side; }
.mc-sl-result { grid-area:res; justify-self:end; }
.mc-sl-entry { grid-area:e; } .mc-sl-tp { grid-area:t; } .mc-sl-sl { grid-area:s; }
.mc-sl-act { grid-area:act; }
.mc-sl-act:empty { display:none; }
.mc-sl-who { display:flex; align-items:center; gap:8px; min-width:0; }
.mc-sl-who .ct-avatar { flex:none; width:26px; height:26px; font-size:11px; }
.mc-sl-name { min-width:0; font-size:13.5px; font-weight:800; color:var(--g-ink); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mc-sl-who .mc-chip { flex:none; }
.mc-sl-num { display:flex; flex-direction:column; align-items:flex-start; gap:1px; font-variant-numeric:tabular-nums; }
.mc-sl-num::before { content:attr(data-label); font-size:11px; font-weight:700; color:var(--g-ink-3); }
.mc-sl-num bdi { color:var(--g-ink); font-weight:800; font-size:13px; unicode-bidi:isolate; }
.mc-sl-res { display:inline-flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:4px 8px; }
.mc-sl-row .mc-sl-res .mc-sl-chip { order:-1; }
.mc-sl-pips { font-size:13.5px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; white-space:nowrap; }
.mc-sl-pips.up { color:var(--g-up); } .mc-sl-pips.down { color:var(--g-down); }
.mc-sl-live { font-size:11px; font-weight:700; color:var(--g-ink-3); }
.mc-sl-none { color:var(--g-ink-3); }
.mc-sl-chip {
  display:inline-flex; align-items:center; padding:1px 8px; border-radius:99px; font-size:11.5px; font-weight:800; line-height:1.7;
  background:var(--g-flat-soft); color:var(--g-ink-2); white-space:nowrap;
}
.mc-sl-chip.open { background:var(--g-teal-soft); color:var(--g-teal-ink); }
.mc-sl-chip.wait { background:var(--g-amber-soft); color:var(--g-amber-ink); }
.mc-sl-chip.win { background:var(--g-up-soft); color:var(--mc-up-ink); }
.mc-sl-chip.loss { background:var(--g-down-soft); color:var(--g-down); }
.mc-sl-chip.hand { background:var(--g-flat-soft); color:var(--g-ink); box-shadow:inset 0 0 0 1px var(--g-line); }
.mc-sl-close { width:100%; min-height:44px; height:auto; }
.mc-btn.danger { border-color:color-mix(in srgb, var(--g-down) 45%, var(--g-line)); }
.mc-btn.danger:focus-visible, .mc-sl-close:focus-visible { outline:2px solid var(--g-down); outline-offset:2px; }
.mc-btn.danger.solid { background:var(--g-down); border-color:var(--g-down); color:#fff; }
.mc-btn.danger.solid:hover { filter:brightness(.94); }
:root[data-theme="dark"] .mc-btn.danger.solid { color:#0B1314; }
.mc-sl-foot { margin:0; }
/* the table (the box ≥ 760 px): 8 columns, rows ≥ 44 px, the button inline */
@container mcsl (min-width:760px) {
  .mc-sl-table thead { display:table-header-group; }
  .mc-sl-table tbody { display:table-row-group; }
  .mc-sl-row { display:table-row; padding:0; border:0; }
  .mc-sl-table th, .mc-sl-table td {
    display:table-cell; height:44px; padding:6px 10px; vertical-align:middle; border-bottom:1px solid var(--g-line-soft); white-space:nowrap;
  }
  .mc-sl-table thead th { height:auto; font-size:12px; font-weight:700; color:var(--g-ink-3); text-align:start; }
  .mc-sl-table thead th.mc-sl-num { text-align:end; }
  .mc-sl-row:last-child > * { border-bottom:0; }
  .mc-sl-row.open > * { background:var(--g-teal-soft); }
  .mc-sl-src { max-width:220px; }
  .mc-sl-when { text-align:start; }
  .mc-sl-num { text-align:end; }
  .mc-sl-num::before { content:none; }
  .mc-sl-result { text-align:start; }
  .mc-sl-res { justify-content:flex-start; }
  .mc-sl-row .mc-sl-res .mc-sl-chip { order:0; }
  .mc-sl-act { width:1%; text-align:end; }
  .mc-sl-act:empty { display:table-cell; }
  .mc-sl-close { width:auto; min-height:34px; }
}
/* the close dialog's rows: label and value on one line, numbers left to right */
.mc-close-dl { margin:0; display:flex; flex-direction:column; }
.mc-close-dl > div { display:flex; justify-content:space-between; align-items:baseline; gap:12px; padding:6px 0; border-top:1px solid var(--g-line-soft); }
.mc-close-dl > div:first-child { border-top:0; }
.mc-close-dl dt { font-size:12.5px; font-weight:700; color:var(--g-ink-3); }
.mc-close-dl dd { margin:0; font-size:14px; font-weight:800; color:var(--g-ink); font-variant-numeric:tabular-nums; min-width:0; overflow-wrap:anywhere; }
.mc-close-dl dd b.up { color:var(--g-up); } .mc-close-dl dd b.down { color:var(--g-down); }
/* retire-org-2 review round 2, finding 2 (C2, the owner: «مبنای کانال / پیشنهادی هر منبع: اینو هم بردار»): the channel
   leaf's source list (copytrade.js in 'pick' mode, before a channel is connected) shows no «ریسک‌ریوارد مبنا» chip — a
   channel's ratio is always the platform's — nor the win-rate chip, which stays locked until a ratio is chosen.
   copytrade.js is unchanged; «پاک کردن فیلترها» still clears any filter chosen on the ranking. */
.cp-sources .ct-chip[data-chip="ratio"], .cp-sources .ct-chip[data-chip="win"] { display:none; }
/* review round 2, finding 7: «حذف‌شده از کانال» beside a removed source's name; the name keeps its width, the chip wraps
   under it when the line is short (a phone's card, the table's 220 px cell). */
.mc-sl-who.gone { flex-wrap:wrap; row-gap:4px; }
