/* Bilder Hub. Chrome and ink follow the dataviz reference palette; the single data colour is its validated slot 1. */
:root {
  color-scheme: light;
  --plane: #f9f9f7;
  --surface: #fcfcfb;
  --surface-2: #f1f0ec;
  --ink: #0b0b0b;
  --ink-2: #52514e;
  --muted: #7a7873;
  --hairline: #e1e0d9;
  --axis: #c3c2b7;
  --ring: rgba(11, 11, 11, 0.1);
  --accent: #2a78d6;
  --accent-strong: #1c5cab;
  --accent-soft: #e6effb;
  --series-1: #2a78d6;
  --good: #0ca30c;
  --good-text: #006300;
  --warning: #fab219;
  --warning-text: #8a5a00;
  --serious: #ec835a;
  --critical: #d03b3b;
  --critical-text: #b42d2d;
  --warning-soft: #fdf3dc;
  --critical-soft: #fbe7e7;
  --radius: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --plane: #0d0d0d;
    --surface: #1a1a19;
    --surface-2: #242422;
    --ink: #ffffff;
    --ink-2: #c3c2b7;
    --muted: #979589;
    --hairline: #2c2c2a;
    --axis: #45453f;
    --ring: rgba(255, 255, 255, 0.1);
    --accent: #3987e5;
    --accent-strong: #86b6ef;
    --accent-soft: #17273b;
    --series-1: #3987e5;
    --good-text: #0ca30c;
    --warning-text: #fab219;
    --critical-text: #e66767;
    --warning-soft: #33290f;
    --critical-soft: #3a1b1b;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--plane); color: var(--ink); font: 15px/1.5 var(--font); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code, pre, .code { font-family: var(--mono); font-size: 13px; }
hr { border: 0; border-top: 1px solid var(--hairline); margin: 20px 0; }
h1 { font-size: 24px; line-height: 1.2; margin: 0; font-weight: 650; letter-spacing: -0.01em; }
h2 { font-size: 16px; line-height: 1.3; margin: 0 0 12px; font-weight: 620; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
[hidden] { display: none !important; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ------------------------------------------------------------------ shell */
.shell { display: grid; grid-template-columns: 228px minmax(0, 1fr); min-height: 100vh; }
.nav { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 2px;
  padding: 18px 12px; background: var(--surface); border-right: 1px solid var(--hairline); }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; color: var(--ink); font-weight: 650; font-size: 16px; }
.brand:hover { text-decoration: none; }
.brand-mark { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px;
  background: var(--accent); color: #fff; font-weight: 700; font-size: 15px; }
.brand.big { font-size: 20px; padding: 0 0 6px; }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--ink-2);
  font: 500 14.5px/1.2 var(--font); border: 0; background: none; cursor: pointer; text-align: left; width: 100%; }
.nav-item:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.nav-item.active { background: var(--accent-soft); color: var(--accent-strong); }
.nav-item .icon { width: 19px; height: 19px; flex: none; }
.nav .logout { margin-top: auto; }
.main { padding: 26px 32px 64px; max-width: 1320px; width: 100%; display: flex; flex-direction: column; gap: 18px; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.head-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ------------------------------------------------------------------ blocks */
.card { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius); padding: 18px 20px; min-width: 0; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); }
.grid.cols-6 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr)); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-sm { display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; align-items: center; flex-wrap: wrap; }
.row.gap { gap: 8px; margin-top: 12px; }
.row.end { justify-content: flex-end; }
.grow { flex: 1 1 260px; }
.banner { border-radius: 10px; padding: 10px 14px; background: var(--surface-2); border: 1px solid var(--hairline); margin: 0; }
.banner.warning { background: var(--warning-soft); border-color: transparent; }
.banner.critical { background: var(--critical-soft); border-color: transparent; }

.hero-row { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(0, 2fr); gap: 16px; }
.hero-card .label, .tile .label { color: var(--ink-2); font-size: 13.5px; }
.hero { font-size: 56px; font-weight: 650; line-height: 1.05; letter-spacing: -0.02em; margin: 6px 0 4px; }
.hero-card .sub, .tile .sub { color: var(--muted); font-size: 13px; }
.tile { display: flex; flex-direction: column; gap: 2px; }
.tile .value { font-size: 28px; font-weight: 620; line-height: 1.15; }
.tile .value .of { font-size: 16px; color: var(--muted); font-weight: 500; }

.channel { display: flex; flex-direction: column; gap: 10px; }
.channel .top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.channel .title { font-weight: 600; color: var(--ink); }
.channel .title:hover { text-decoration: none; color: var(--accent); }
.channel .numbers { display: flex; gap: 18px; flex-wrap: wrap; }
.channel .numbers .n { font-size: 26px; font-weight: 620; line-height: 1.1; }
.channel .numbers .l { font-size: 12.5px; color: var(--muted); }
.channel .notes { display: flex; flex-wrap: wrap; gap: 4px 12px; color: var(--ink-2); font-size: 13px; margin: 0; padding: 0; list-style: none; }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 999px; font-size: 12.5px;
  font-weight: 550; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.pill.good::before { background: var(--good); }
.pill.warning::before { background: var(--warning); }
.pill.serious::before { background: var(--serious); }
.pill.critical::before { background: var(--critical); }
.pill.plain::before { display: none; }

.alerts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.alerts li { display: flex; gap: 10px; align-items: baseline; }
.alerts .src { font-weight: 600; white-space: nowrap; }
.alerts a { color: inherit; }

.workers { display: flex; flex-direction: column; }
.worker { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 10px 0; border-top: 1px solid var(--hairline); }
.worker:first-child { border-top: 0; }
.worker .name { font-weight: 600; }
.worker .detail { grid-column: 1 / -1; color: var(--muted); font-size: 13px; }
.worker .controls { display: flex; align-items: center; gap: 8px; }

.events { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; max-height: 420px; overflow: auto; }
.events li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; font-size: 13.5px; }
.events time { color: var(--muted); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 14px; min-height: 36px;
  border-radius: 9px; border: 1px solid var(--axis); background: var(--surface); color: var(--ink); font: 550 14px/1.2 var(--font);
  cursor: pointer; white-space: nowrap; text-decoration: none; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:disabled { opacity: 0.55; cursor: progress; }
.btn .icon { width: 17px; height: 17px; }
.btn.primary { background: var(--accent); border-color: transparent; color: #fff; }
.btn.primary:hover { background: var(--accent-strong); }
.btn.danger { color: var(--critical-text); }
.btn.ghost { border-color: transparent; background: none; }
.btn.small { min-height: 30px; padding: 5px 10px; font-size: 13px; }
.btn.wide { width: 100%; }
.icon-btn { padding: 6px; min-height: 32px; }

input, select, textarea { font: 14.5px/1.4 var(--font); color: var(--ink); background: var(--surface); border: 1px solid var(--axis);
  border-radius: 9px; padding: 8px 10px; width: 100%; min-height: 38px; }
textarea { resize: vertical; line-height: 1.5; }
textarea.code { font-family: var(--mono); font-size: 13px; white-space: pre; }
input[type="checkbox"], input[type="radio"] { width: auto; min-height: 0; accent-color: var(--accent); }
input[type="file"] { padding: 6px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--ink-2); }
.field.inline { flex-direction: row; align-items: center; gap: 8px; }
.field.inline select { width: auto; }
.check { display: inline-flex; gap: 8px; align-items: center; font-size: 14px; color: var(--ink); cursor: pointer; }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 10px 16px; }
.form-error { color: var(--critical-text); margin: 8px 0 0; font-size: 14px; }
.hint { color: var(--muted); font-size: 12.5px; }

.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex: none; }
.switch input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--axis); transition: background 0.15s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff;
  transition: transform 0.15s; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); }
.switch input:checked + span { background: var(--accent); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.segmented { display: inline-flex; border: 1px solid var(--axis); border-radius: 9px; overflow: hidden; }
.segmented button { border: 0; background: none; padding: 8px 14px; font: 550 14px var(--font); color: var(--ink-2); cursor: pointer; }
.segmented button[aria-checked="true"] { background: var(--accent-soft); color: var(--accent-strong); }
.segmented button:disabled { opacity: .55; cursor: default; }

/* «Кому писать» — под тумблером отправки, чтобы переключалось с телефона, а не искалось в настройках */
.audience-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 10px; }

.tabs { display: flex; gap: 2px; overflow-x: auto; border-bottom: 1px solid var(--hairline); scrollbar-width: none; }
.tab { padding: 9px 12px; border: 0; background: none; color: var(--ink-2); font: 550 14px var(--font); cursor: pointer;
  border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }

/* ------------------------------------------------------------------ tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--muted); font-weight: 550; font-size: 12.5px; padding: 8px 10px; border-bottom: 1px solid var(--hairline); white-space: nowrap; }
td { padding: 9px 10px; border-bottom: 1px solid var(--hairline); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td.nowrap { white-space: nowrap; }
td.text { min-width: 260px; max-width: 520px; }
.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; cursor: pointer; }
.clamp.open { -webkit-line-clamp: unset; }
.empty { color: var(--muted); padding: 14px 10px; }

/* ------------------------------------------------------------------ charts */
.chart { position: relative; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart .c-grid { stroke: var(--hairline); stroke-width: 1; shape-rendering: crispEdges; }
.chart .c-axis { stroke: var(--axis); stroke-width: 1; shape-rendering: crispEdges; }
.chart .c-tick { fill: var(--muted); font: 11px var(--font); font-variant-numeric: tabular-nums; }
.chart .c-bar { fill: var(--series-1); }
.chart .c-bar.lift { opacity: 0.78; }
.chart .c-hit { fill: transparent; cursor: default; }
.chart .c-hit:focus { outline: none; }
.chart .c-hit:focus-visible { stroke: var(--accent); stroke-width: 1; }
.chart-tip { position: absolute; pointer-events: none; background: var(--surface); border: 1px solid var(--hairline); border-radius: 8px;
  padding: 6px 9px; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12); font-size: 12.5px; white-space: nowrap; transform: translate(-50%, -100%); z-index: 5; }
.chart-tip strong { display: block; font-size: 14px; color: var(--ink); }
.chart-tip span { color: var(--ink-2); }
details.table-view summary { cursor: pointer; color: var(--muted); font-size: 12.5px; margin-top: 4px; }
details.table-view table { margin-top: 6px; font-size: 13px; }

/* ------------------------------------------------------------------- pages */
.status-card { display: flex; flex-direction: column; gap: 12px; }
.status-line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.status-line .account { font-weight: 620; font-size: 17px; }
.status-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.callout { border-radius: 10px; padding: 12px 14px; background: var(--critical-soft); display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.callout.warning { background: var(--warning-soft); }
.upload-row { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 14px; }
.config-form { display: flex; flex-direction: column; gap: 18px; }
.config-form fieldset, .secret-group { border: 0; padding: 0; margin: 0; }
.config-form legend, .secret-group legend { font-weight: 620; margin-bottom: 10px; padding: 0; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px 16px; align-items: end; }
.texts-head { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 8px; }
.texts-head .field { min-width: 240px; }
.variants { display: flex; flex-direction: column; gap: 12px; }
.variant { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: start; }
.variant textarea { min-height: 120px; }
.output { background: var(--surface-2); border-radius: 9px; padding: 10px 12px; white-space: pre-wrap; margin: 12px 0 0; max-height: 360px; overflow: auto; }
.log { margin: 0; white-space: pre-wrap; word-break: break-word; font-size: 12.5px; line-height: 1.5; max-height: calc(100vh - 220px); overflow: auto; }
.secret-group { margin-top: 18px; }
.secret-row { display: grid; grid-template-columns: minmax(200px, 1.2fr) minmax(160px, 1fr) auto auto; gap: 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--hairline); }
.secret-row.static { grid-template-columns: minmax(0, 1fr) auto auto; }
.secret-label { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 14px; margin: 0; }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.dialog { border: 1px solid var(--hairline); border-radius: 14px; background: var(--surface); color: var(--ink); padding: 20px; width: min(420px, calc(100vw - 24px)); }
.dialog::backdrop { background: rgba(0, 0, 0, 0.45); }
.qr-box { display: grid; place-items: center; background: #fff; border-radius: 12px; padding: 12px; min-height: 120px; margin: 12px 0; }
.qr-box img { width: 264px; height: 264px; max-width: 100%; }

.toasts { position: fixed; right: 16px; bottom: 16px; display: flex; flex-direction: column; gap: 8px; z-index: 60; max-width: min(420px, calc(100vw - 32px)); }
.toast { background: var(--ink); color: var(--plane); padding: 10px 14px; border-radius: 10px; font-size: 14px; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2); }
.toast.error { background: var(--critical); color: #fff; }

.login-page { display: grid; place-items: center; min-height: 100vh; padding: 16px; }
.login-card { width: min(400px, 100%); display: flex; flex-direction: column; gap: 14px; }
.login-block { border-top: 1px solid var(--hairline); padding-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.login-block h2 { margin: 0; }

/* ------------------------------------------------------------------ mobile */
@media (max-width: 900px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .nav { position: fixed; inset: auto 0 0 0; height: auto; flex-direction: row; justify-content: space-around; gap: 0;
    padding: 4px 2px calc(4px + env(safe-area-inset-bottom)); border-right: 0; border-top: 1px solid var(--hairline); z-index: 50; }
  .brand, .nav .logout, .nav .secondary { display: none; }
  .nav-item { flex-direction: column; gap: 3px; font-size: 10.5px; padding: 6px 2px; width: auto; flex: 1; align-items: center; text-align: center; }
  .nav-item .icon { width: 22px; height: 22px; }
  .main { padding: 16px 12px 96px; gap: 14px; }
  .hero-row { grid-template-columns: minmax(0, 1fr); }
  .hero { font-size: 48px; }
  .secret-row, .secret-row.static { grid-template-columns: minmax(0, 1fr) auto; }
  .secret-row input { grid-column: 1 / -1; }
  .events li { grid-template-columns: 74px minmax(0, 1fr); }
  h1 { font-size: 21px; }
}

/* ----------------------------------------------------------- channel pages */
.grid.cols-5 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); }
.field.wide { grid-column: 1 / -1; }
.days { display: flex; flex-wrap: wrap; gap: 6px 14px; padding-top: 2px; }
.filters { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 10px; }
.filters .field { min-width: 160px; }
.card-head.spaced { margin-top: 22px; }
.preview { border: 1px solid var(--hairline); border-radius: 10px; padding: 12px 14px; background: var(--surface-2);
  white-space: pre-wrap; font-size: 14px; max-height: 560px; overflow: auto; }
.preview .subject { font-weight: 620; margin-bottom: 8px; white-space: normal; }
.month-bar { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; }
.month-nav { display: flex; align-items: center; gap: 8px; }
.month-nav select { width: auto; min-width: 170px; }
.posts-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.post-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.post-card .thumb { aspect-ratio: 4 / 5; background: var(--surface-2); display: grid; place-items: center; color: var(--muted); font-size: 13px; }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-card .body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.post-card .when { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); }
.post-card h3 { margin: 0; font-size: 15.5px; line-height: 1.35; }
.post-card .clamp { white-space: pre-wrap; -webkit-line-clamp: 6; }
.post-card .actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 4px; }
.editor-dialog { width: min(720px, calc(100vw - 24px)); max-height: calc(100vh - 32px); overflow: auto; }
.char-count { font-size: 12.5px; color: var(--muted); text-align: right; margin-top: -4px; }
.char-count.over { color: var(--critical-text); font-weight: 600; }
.remote { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 16px; align-items: start; }
.remote .screen { background: #111; border-radius: 10px; overflow: hidden; min-height: 200px; }
.remote .screen img { width: 100%; display: block; cursor: crosshair; }
.keys { display: flex; flex-wrap: wrap; gap: 6px; }
.order { display: inline-flex; gap: 2px; }
.note-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: start; }
.note-row .meta { grid-column: 1 / -1; display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.note-row .meta.over { color: var(--critical-text); }
@media (max-width: 900px) {
  .remote { grid-template-columns: minmax(0, 1fr); }
}

/* --------------------------------------------------------------------- crm */
.crm-search { flex: 1 1 260px; }
.crm-counts { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 12px; }
.chip { border: 1px solid var(--hairline); background: var(--surface); color: var(--ink-2); border-radius: 999px; padding: 4px 11px;
  font: inherit; font-size: 13px; cursor: pointer; }
.chip.active { background: var(--ink); color: var(--plane); border-color: var(--ink); }
.crm-row { cursor: pointer; }
.crm-row:hover td, .crm-row:focus-visible td { background: var(--surface-2); }
.crm-name { font-weight: 600; }
.crm-contacts { display: flex; flex-direction: column; gap: 2px; }
.crm-notes { max-width: 340px; white-space: pre-wrap; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.lead-dialog { width: min(720px, calc(100vw - 24px)); }
.status-select { border: 1px solid var(--hairline); border-radius: 999px; padding: 3px 8px; background: var(--surface); color: var(--ink);
  font: inherit; font-size: 13px; cursor: pointer; max-width: 100%; }
.status-select:disabled { opacity: 0.6; cursor: progress; }
.status-edit-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto auto; gap: 6px; align-items: center; }
.crm-name { display: flex; align-items: center; gap: 8px; }
.lead-lamp { width: 10px; height: 10px; border-radius: 50%; flex: none; transition: background 0.25s, box-shadow 0.25s; }
.lead-lamp.green { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18), 0 0 8px rgba(34, 197, 94, 0.65); }
.lead-lamp.yellow { background: #f5b301; box-shadow: 0 0 0 3px rgba(245, 179, 1, 0.2), 0 0 7px rgba(245, 179, 1, 0.55); }
.lead-lamp.red { background: #ef4444; box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15); }
.chip .lead-lamp { display: inline-block; width: 8px; height: 8px; margin-right: 6px; vertical-align: 1px; box-shadow: none; }
.status-lamp { font: inherit; font-size: 13px; }
.pair-code { font: 650 20px/1.2 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 2px; }
.steps { margin: 4px 0 0; padding-left: 20px; }
.steps li + li { margin-top: 2px; }
.variant { border: 1px solid var(--hairline); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.variant legend { font-weight: 620; padding: 0 4px; }
.plan-days { margin: 4px 0 0; padding-left: 18px; font-size: 13px; }
.plan-days li + li { margin-top: 2px; }
.live-num { font-variant-numeric: tabular-nums; transition: color 0.9s ease; }
.live-num.up { color: var(--good); }
.live-num.down { color: var(--warning); }

/* «Почта»: the send switch that is always there, and the live counter of today's mails */
.send-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.send-head h2 { margin: 0 0 2px; }
.send-toggle { display: flex; align-items: center; gap: 10px; font-weight: 620; }
.send-toggle .switch { transform: scale(1.2); transform-origin: right center; }
.live-card { display: flex; flex-direction: column; gap: 12px; }
.live-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px 24px; flex-wrap: wrap; }
.live-card .label { color: var(--ink-2); font-size: 13.5px; }
.live-big { font-size: 64px; font-weight: 650; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin-top: 6px; }
.live-big .of { font-size: 22px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.live-side { display: flex; flex-direction: column; gap: 4px; text-align: right; }
.live-next { font-size: 17px; font-weight: 620; font-variant-numeric: tabular-nums; min-height: 1.3em; }
.progress { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: inherit; background: var(--accent); transition: width 0.6s ease; }
.channel-switch { display: flex; align-items: center; gap: 8px; margin-left: auto; align-self: center; }
@media (max-width: 600px) {
  .live-big { font-size: 48px; }
  .live-side { text-align: left; }
}

/* numbers in a row inside a card: the LinkedIn post statistics */
.stat-row { display: flex; flex-wrap: wrap; gap: 12px 28px; }
.stat-row .n { font-size: 26px; font-weight: 620; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-row .l { font-size: 12.5px; color: var(--muted); }
.steps code { font: 13px var(--mono); background: var(--surface-2); padding: 1px 5px; border-radius: 5px; overflow-wrap: anywhere; }
.steps .btn.small { margin-left: 4px; vertical-align: baseline; }
.send-live { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-top: 6px; font-size: 15px; font-variant-numeric: tabular-nums; }
/* a table header Erik can click to sort by that column */
th .sort { background: none; border: 0; padding: 0; margin: 0; font: inherit; color: inherit; cursor: pointer; }
th .sort:hover { color: var(--accent); }
th.sorted { color: var(--ink); }
