/* Scoute cabinet. Tokens first: light, then dark (system or chosen), then the layout. */
:root {
  --bg: #f5f5f2; --surface: #ffffff; --surface-2: #f0efeb; --surface-3: #e8e7e2;
  --text: #16161b; --muted: #6b6b76; --faint: #9a9aa3; --line: #e5e3dd; --line-strong: #d6d4cd;
  --accent: #5b4bff; --accent-text: #4a3be0; --accent-soft: #ecebff;
  --up: #0f7a55; --up-soft: #e2f3eb; --down: #c03d12; --down-soft: #fbe9e1;
  --warn: #9a6a00; --warn-soft: #fbf1d9;
  --shadow: 0 1px 2px rgba(20, 20, 30, .05), 0 4px 16px rgba(20, 20, 30, .04);
  --radius: 14px; --radius-s: 9px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0d11; --surface: #15151b; --surface-2: #1b1b23; --surface-3: #23232d;
    --text: #ececf1; --muted: #9b9ba8; --faint: #6e6e7a; --line: #24242e; --line-strong: #31313d;
    --accent: #8f84ff; --accent-text: #a79eff; --accent-soft: #221f3e;
    --up: #43d39b; --up-soft: #12281f; --down: #ff8b61; --down-soft: #2c1912;
    --warn: #f0c35b; --warn-soft: #2a2312;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0d0d11; --surface: #15151b; --surface-2: #1b1b23; --surface-3: #23232d;
  --text: #ececf1; --muted: #9b9ba8; --faint: #6e6e7a; --line: #24242e; --line-strong: #31313d;
  --accent: #8f84ff; --accent-text: #a79eff; --accent-soft: #221f3e;
  --up: #43d39b; --up-soft: #12281f; --down: #ff8b61; --down-soft: #2c1912;
  --warn: #f0c35b; --warn-soft: #2a2312;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.45 var(--font); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; letter-spacing: -.015em; }
h1 { font-size: 28px; font-weight: 650; }
h2 { font-size: 17px; font-weight: 620; margin: 28px 0 12px; }
h3 { font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 10px; }
small { color: var(--muted); }
.muted { color: var(--muted); }
.num, .kpi b, .score-badge b, .chart-card b { font-variant-numeric: tabular-nums; }
svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* --- top bar --- */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 82%, transparent);
       backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); border-bottom: 1px solid var(--line); }
.top-inner { max-width: 1240px; margin: 0 auto; padding: 0 24px; height: 58px; display: flex; align-items: center; gap: 18px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; font-size: 17px; letter-spacing: -.02em; }
.brand.big { font-size: 22px; margin-bottom: 28px; }
.dot { width: 11px; height: 11px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 5px var(--accent-soft); }
.client { color: var(--muted); font-weight: 520; padding-left: 16px; border-left: 1px solid var(--line-strong); }
.switch, .account { position: relative; }
.switch summary, .account summary { list-style: none; cursor: pointer; }
.switch summary::-webkit-details-marker, .account summary::-webkit-details-marker { display: none; }
.switch summary { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px 6px 16px; border-left: 1px solid var(--line-strong); color: var(--muted); font-weight: 520; }
.switch summary svg { width: 12px; height: 12px; }
.menu { position: absolute; top: calc(100% + 8px); min-width: 200px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
        box-shadow: var(--shadow); padding: 6px; display: grid; gap: 2px; }
.account .menu { right: 0; }
.menu a, .menu button { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; }
.menu a:hover, .menu button:hover, .menu a[aria-current] { background: var(--surface-2); }
.menu .who { padding: 9px 12px 10px; border-bottom: 1px solid var(--line); margin-bottom: 4px; display: grid; }
.tabs { display: flex; gap: 4px; margin-left: 8px; }
.tabs a { padding: 7px 12px; border-radius: 9px; color: var(--muted); font-weight: 540; }
.tabs a:hover { color: var(--text); background: var(--surface-2); }
.tabs a[aria-current] { color: var(--text); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.spacer { flex: 1; }
.icon { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); display: grid; place-items: center; cursor: pointer; }
.icon:hover { color: var(--text); }
.icon svg { width: 18px; height: 18px; }
.icon .fill { fill: currentColor; stroke: none; }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); font-weight: 650; }

/* --- page --- */
.page { max-width: 1240px; margin: 0 auto; padding: 28px 24px 64px; }
/* minmax(0, 1fr): the column never grows past the screen to fit what is inside */
.center { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr); place-items: center; padding: 32px 16px; }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.sub { margin: 6px 0 0; color: var(--muted); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 11px;
          border: 1px solid transparent; background: var(--accent); color: #fff; font: 600 15px var(--font); cursor: pointer; white-space: nowrap; }
.button:hover { filter: brightness(1.06); }
.button.ghost { background: var(--surface); color: var(--text); border-color: var(--line-strong); }

/* --- tabs over the list (the sheet's tabs) --- */
.seg-tabs { display: flex; gap: 4px; padding: 4px; background: var(--surface-2); border-radius: 12px; margin-bottom: 14px; width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg-tabs::-webkit-scrollbar { display: none; }
.seg-tabs a { display: inline-flex; align-items: center; gap: 7px; padding: 7px 13px; border-radius: 9px; color: var(--muted); font-weight: 560; white-space: nowrap; }
.seg-tabs a span { font-size: 12px; font-weight: 600; color: var(--faint); font-variant-numeric: tabular-nums; }
.seg-tabs a:hover { color: var(--text); }
.seg-tabs a[aria-current] { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0, 0, 0, .08), inset 0 0 0 1px var(--line); }
.seg-tabs a[aria-current] span { color: var(--accent-text); }

/* --- label kind --- */
.badge { display: inline-block; font-style: normal; font-size: 12px; font-weight: 650; padding: 2px 8px; border-radius: 6px; white-space: nowrap;
         background: var(--surface-2); color: var(--muted); }
.badge.free { background: var(--up); color: #fff; }
.badge.unknown { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--line-strong); }
.badge.major { background: var(--surface-3); color: var(--faint); }
.label .badge { margin-top: 3px; }
.pills .badge { font-size: 12.5px; padding: 3px 9px; border-radius: 999px; }

/* --- icons --- */
.ico { width: 16px; height: 16px; flex: none; }
.ico .fill { fill: currentColor; stroke: none; }

/* --- toolbar --- */
.toolbar { display: grid; gap: 10px; margin-bottom: 16px; }
.search { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.search svg { width: 18px; height: 18px; color: var(--faint); flex: none; }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; font: inherit; color: inherit; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.select { position: relative; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 10px 0 12px; border-radius: 999px;
          background: var(--surface); border: 1px solid var(--line); font-size: 13.5px; cursor: pointer; }
.select span { color: var(--muted); }
.select select { appearance: none; -webkit-appearance: none; border: 0; background: none; font: 560 13.5px var(--font); color: var(--text); padding-right: 14px; cursor: pointer; outline: 0;
                 field-sizing: content; max-width: 220px; text-overflow: ellipsis;
                 background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
                 background-position: calc(100% - 6px) 55%, calc(100% - 2px) 55%; background-size: 4px 4px; background-repeat: no-repeat; }
.select select option { color: initial; }
.select.on { background: var(--accent-soft); border-color: transparent; }
.select.on span, .select.on select { color: var(--accent-text); }
.reset { font-size: 13.5px; color: var(--accent-text); font-weight: 560; padding: 0 6px; }

/* --- the list --- */
.list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.list-head, .row { display: grid; grid-template-columns: minmax(190px, 2.2fr) 84px 100px 80px 112px minmax(130px, 1.3fr) 112px 146px; gap: 14px; align-items: center; padding: 0 18px; }
.list-head { height: 40px; font-size: 12px; color: var(--muted); font-weight: 560; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.row { min-height: 64px; padding-top: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); transition: background .12s; }
.row:last-child { border-bottom: 0; }
.row:hover { background: var(--surface-2); }
.row > span { min-width: 0; }
.num { text-align: right; }
.who b, .label b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who b { font-weight: 620; }
.who small, .label small, .num small, .state small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; }
.label b { font-weight: 500; }
.tag { font-style: normal; font-size: 11px; font-weight: 600; color: var(--warn); background: var(--warn-soft); border-radius: 5px; padding: 1px 6px; margin-right: 6px; }
.score { display: grid; justify-items: end; gap: 6px; }
.score b { font-size: 16px; font-weight: 650; }
.score svg, .score-badge svg { width: 64px; height: 4px; stroke: none; }
.track { fill: var(--surface-3); }
.bar { fill: var(--accent); }
.delta { font-style: normal; font-weight: 600; color: var(--muted); }
.delta.up { color: var(--up); }
.delta.down { color: var(--down); }
.pill { display: inline-block; font-style: normal; font-size: 12.5px; font-weight: 580; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.pill.work, .pill.accent { background: var(--accent-soft); color: var(--accent-text); }
.pill.sent { background: var(--up-soft); color: var(--up); }
.pill.no { background: var(--surface-2); color: var(--faint); text-decoration: line-through; }
.pill.none { background: transparent; color: var(--faint); box-shadow: inset 0 0 0 1px var(--line-strong); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.links { display: flex; gap: 4px; flex-wrap: nowrap; overflow: hidden; }
.c { font-style: normal; width: 26px; height: 26px; border-radius: 7px; display: inline-grid; place-items: center; background: var(--surface-2); color: var(--muted); }
.c .ico { width: 15px; height: 15px; }
.c.c-email { background: var(--up-soft); color: var(--up); }
.pager { display: flex; gap: 6px; justify-content: center; margin-top: 18px; flex-wrap: wrap; }
.pager a { min-width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface); font-weight: 560; }
.pager a[aria-current] { background: var(--text); color: var(--bg); border-color: var(--text); }
.empty { text-align: center; padding: 56px 16px; background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--radius); }
.empty.wide { max-width: 560px; margin: 48px auto; border-style: solid; }
.empty p { color: var(--muted); margin: 8px 0 18px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.tile { display: grid; gap: 4px; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.tile b { font-size: 18px; }

/* --- the artist card --- */
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-weight: 540; margin-bottom: 14px; }
.back svg { width: 14px; height: 14px; }
.back:hover { color: var(--text); }
.hero { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.hero h1 { font-size: 32px; }
.meta { margin: 6px 0 14px; color: var(--muted); }
.pills { display: flex; gap: 6px; flex-wrap: wrap; }
.hero-contacts { display: none; }
.score-badge { display: grid; justify-items: end; gap: 4px; text-align: right; }
.score-badge b { font-size: 40px; line-height: 1; font-weight: 700; color: var(--accent-text); }
.score-badge small { text-transform: uppercase; letter-spacing: .05em; font-size: 11.5px; font-weight: 600; }
.score-badge svg { width: 96px; margin-top: 6px; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.kpi { padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 4px; align-content: start; }
.kpi small { font-size: 12.5px; font-weight: 560; }
.kpi b { font-size: 24px; font-weight: 680; letter-spacing: -.02em; }
.kpi b i { font-style: normal; font-size: 15px; font-weight: 560; color: var(--muted); letter-spacing: 0; }
.kpi span { font-size: 12.5px; color: var(--faint); }
.card-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
.charts { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.chart-card { padding: 14px 16px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.chart-card header { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.chart-card header span { font-weight: 600; display: grid; }
.chart-card header small { font-weight: 450; font-size: 12.5px; }
.chart-card header b { font-size: 20px; font-weight: 680; }
.chart-card footer { font-size: 12.5px; color: var(--muted); }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 28px 0 12px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.seg { display: inline-flex; padding: 3px; background: var(--surface-2); border-radius: 10px; gap: 2px; }
.seg button { border: 0; background: none; font: 560 13px var(--font); color: var(--muted); padding: 6px 11px; border-radius: 8px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0, 0, 0, .08), inset 0 0 0 1px var(--line); }
.charts[data-mode="pct"] .view-abs, .charts[data-mode="abs"] .view-pct { display: none; }
.chart { display: block; width: 100%; height: auto; margin: 8px 0 4px; overflow: visible; }
.chart .stroke { stroke: var(--accent); stroke-width: 2; }
.chart .grid { stroke: var(--line); stroke-width: 1; stroke-dasharray: 3 4; }
.chart .grid.zero { stroke: var(--line-strong); stroke-dasharray: none; }
.chart .dot { fill: var(--accent); stroke: none; }
.chart .area { stroke: none; }
.chart .area-top { stop-color: var(--accent); stop-opacity: .22; }
.chart .area-bottom { stop-color: var(--accent); stop-opacity: 0; }
.chart .end { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }
.chart .hit { fill: transparent; stroke: none; }
.chart .axis { fill: var(--faint); stroke: none; font: 11.5px var(--font); font-variant-numeric: tabular-nums; }
.box { padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.side { display: grid; gap: 12px; margin-top: 58px; }
.contact-list { display: grid; gap: 6px; }
.contact { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); font-weight: 560; }
.contact:hover { background: var(--surface-3); }
.contact.placeholder, .contact.placeholder:hover { cursor: default; background: var(--surface-2); }
.contact span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.contact .ico { color: var(--muted); }
.contact .out { width: 14px; height: 14px; color: var(--faint); flex: none; }
.contact.c-email .ico { color: var(--up); }
.contact.c-email { background: var(--up-soft); color: var(--up); }
.profile-list { display: flex; flex-wrap: wrap; gap: 6px; }
.profile-list a { padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line-strong); font-size: 13.5px; font-weight: 540; }
.profile-list a:hover { background: var(--surface-2); }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; margin: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.facts .notes { text-align: left; grid-column: 1 / -1; background: var(--surface-2); padding: 8px 10px; border-radius: 8px; white-space: pre-wrap; }
.fine { font-size: 12.5px; color: var(--faint); margin: 12px 0 0; }
.sources { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13.5px; color: var(--muted); }
.sources b { color: var(--text); font-weight: 560; }
.audience { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 20px; }
.audience div { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.audience span { display: grid; font-weight: 560; }
.audience small { font-weight: 400; font-size: 12px; }
.audience b { display: grid; justify-items: end; }
.audience .stale b, .audience .stale span { color: var(--faint); }
.quality { margin-bottom: 14px; }
.quality .alarm { margin: 6px 0; font-weight: 560; }
.quality-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px 18px; margin-top: 8px; }
.quality-grid div { display: grid; gap: 2px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.quality-grid b { font-size: 20px; }
.quality-grid .below b { color: #c2410c; }

/* --- sign in --- */
.sign { width: 100%; max-width: 420px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 36px 32px 28px; }
.sign h1 { font-size: 24px; }
.sign .sub { margin-bottom: 22px; }
.alert { background: var(--down-soft); color: var(--down); padding: 10px 12px; border-radius: 10px; font-weight: 540; margin: 0 0 16px; }
.widget { min-height: 48px; display: grid; place-items: center; }
.widget iframe { max-width: 100%; }
.bot-login { text-align: center; margin: 14px 0 0; font-size: 13.5px; }
.bot-login a { color: var(--muted); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.bot-login a:hover { color: var(--text); }
.waiting { margin: 12px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-text);
           font-size: 13.5px; font-weight: 540; text-align: center; }
.sign .fine { margin-top: 24px; text-align: center; }

/* --- «Вы вошли как …» for 3 seconds after signing in (held while the pointer is on it) --- */
.hello { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 60; max-width: calc(100% - 32px);
         background: var(--text); color: var(--bg); padding: 11px 16px; border-radius: 12px; font-weight: 560; box-shadow: var(--shadow);
         animation: hello-out .4s ease 3s forwards; }
.hello a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.hello:hover { animation-play-state: paused; }
@keyframes hello-out { to { opacity: 0; visibility: hidden; } }

/* --- the superadmin's demo links --- */
.new-link { margin-bottom: 16px; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { flex: 1; min-width: 0; height: 42px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line-strong); background: var(--surface-2);
                  color: var(--text); font: 500 14px var(--font); }
.links-table { padding: 4px 0; }
.lt-row { display: grid; grid-template-columns: minmax(0, 2.2fr) 1fr 1.2fr .8fr 1.2fr; gap: 12px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); }
.lt-row:first-child { border-top: 0; }
.lt-head { color: var(--faint); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.lt-row .num { text-align: right; }
.lt-row small { display: block; color: var(--muted); font-size: 12.5px; }
.lt-row b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.lt-row.off { color: var(--faint); }
@media (max-width: 720px) {
  .head:has(form) { flex-direction: column; align-items: stretch; }
  .lt-head { display: none; }
  .lt-row { grid-template-columns: 1fr 1fr; }
  .lt-row span:first-child { grid-column: 1 / -1; }
  .lt-row span[data-label]:not(:first-child)::before { content: attr(data-label); display: block; color: var(--faint); font-size: 12px; }
  .lt-row .num { text-align: left; }
}

/* --- the team's work: status buttons, Ответственный, Заметки --- */
[hidden] { display: none !important; }
.row { position: relative; }
.row-link::after { content: ""; position: absolute; inset: 0; }
.row .state .status, .row .state small { position: relative; z-index: 1; }
.status { display: inline-flex; gap: 4px; }
.st { position: relative; border: 1px solid var(--line); background: var(--surface); color: var(--faint); border-radius: 8px; height: 30px; min-width: 32px;
      display: inline-grid; place-items: center; cursor: pointer; font: 600 13px var(--font); padding: 0 8px; transition: background .12s, color .12s; }
.st:hover { color: var(--text); border-color: var(--line-strong); }
.st .ico { width: 15px; height: 15px; }
.st.work[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.st.sent[aria-pressed="true"] { background: var(--up); border-color: var(--up); color: #fff; }
.st.no[aria-pressed="true"] { background: var(--surface-3); border-color: var(--line-strong); color: var(--muted); }
.status.full { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 6px; }
.status.full .st { height: 36px; color: var(--muted); }
.st.clear { color: var(--faint); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.status-line { margin: 10px 0 0; font-size: 13.5px; color: var(--muted); }
.field { display: grid; gap: 6px; margin-top: 14px; }
.field > span { font-size: 13px; color: var(--muted); font-weight: 560; display: flex; justify-content: space-between; gap: 8px; }
.field select, .field textarea { width: 100%; border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text); border-radius: 10px;
                                 font: 14px/1.45 var(--font); padding: 9px 11px; outline: 0; }
.field textarea { resize: vertical; min-height: 96px; }
.field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--text); color: var(--bg); padding: 10px 16px;
         border-radius: 10px; font-weight: 560; box-shadow: var(--shadow); z-index: 50; }

.guest { background: var(--warn-soft); color: var(--warn); text-align: center; font-weight: 580; font-size: 13.5px; padding: 8px 16px; }

/* --- tablet --- */
@media (max-width: 1080px) {
  .card-grid { grid-template-columns: 1fr; }
  .side { margin-top: 8px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
  .list-head, .row { grid-template-columns: minmax(180px, 2fr) 80px 90px 80px 110px minmax(110px, 1fr) 110px; }
  .list-head span:last-child, .row .links { display: none; }
}

/* --- phone --- */
@media (max-width: 720px) {
  body { font-size: 15px; }
  .top-inner { padding: 0 16px; gap: 10px; }
  .tabs { display: none; }
  .client, .switch summary { padding-left: 10px; max-width: 42vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .page { padding: 18px 16px 48px; }
  h1 { font-size: 24px; }
  .filters { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 16px 4px; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .select { flex: none; }
  .list { background: none; border: 0; box-shadow: none; display: grid; gap: 10px; overflow: visible; }
  .list-head { display: none; }
  .row { grid-template-columns: 1fr 1fr 1fr; grid-template-areas: "who who score" "reach week since" "label label state";
         gap: 10px 12px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
  .row:last-child { border-bottom: 1px solid var(--line); }
  .row .who { grid-area: who; }
  .row .score { grid-area: score; }
  .row > .num[data-label="Охват"] { grid-area: reach; }
  .row > .num[data-label="7 дней"] { grid-area: week; }
  .row > .num[data-label="С обнаружения"] { grid-area: since; }
  .row .label { grid-area: label; }
  .row .state { grid-area: state; text-align: right; }
  .row .links { display: none; }
  .row > .num[data-label] { text-align: left; }
  .row > .num[data-label]::before { content: attr(data-label); display: block; font-size: 11.5px; color: var(--muted); font-weight: 560; margin-bottom: 2px; }
  .row > .num[data-label] small { display: none; }
  .hero { padding: 18px; flex-direction: column; gap: 14px; }
  .hero-contacts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 14px; }
  .hero-contacts a, .hero-contacts .placeholder { display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 9px; background: var(--surface-2); font-weight: 580; font-size: 14px; }
  .hero-contacts a.c-email, .hero-contacts .placeholder.c-email { background: var(--up-soft); color: var(--up); }
  .hero h1 { font-size: 26px; }
  .score-badge { justify-items: start; text-align: left; grid-template-columns: auto auto; align-items: center; gap: 4px 10px; }
  .score-badge small { grid-column: 1 / -1; }
  .score-badge b { font-size: 32px; }
  .score-badge svg { margin-top: 0; }
  .kpis { grid-template-columns: 1fr 1fr; gap: 8px; }
  .kpi { padding: 12px 14px; }
  .kpi b { font-size: 20px; }
  .kpi b i { display: block; font-size: 13px; margin-top: 1px; }
  .kpi b i .sep { display: none; }
  .charts { grid-template-columns: 1fr; }
  .side { grid-template-columns: 1fr; }
  .sign { padding: 28px 20px 22px; border-radius: 18px; }
}
