/* YM Pilot — «спокойный» вид (30.10, выбор владельца: вариант 1 + чат из варианта 2).
   Светлый тёплый фон, много воздуха, одна главная фраза; чат — как мессенджер. Подключается последним и переопределяет старое. */

:root {
  --bg: #f7f5f0; --surface: #ffffff; --surface-2: #f0ece4; --line: #ebe6dc;
  --ink: #1b1b1b; --ink-2: #5c574e; --ink-3: #8a857b;
  --side: #f0ece4; --side-2: #e4dfd4; --side-ink: #5c574e;
  --radius: 20px;
  --msg-bg: #eef0f7; --msg-me: #7b61ff; --msg-line: #d9dcf0; --msg-ink: #5a4bd1;
}
:root[data-theme="dark"] { --msg-bg: #17181f; --msg-me: #7b61ff; --msg-line: #2c2f45; --msg-ink: #b3a8ff; }
body { font-size: 15px; }

/* ── Боковая панель: светлая, без «кабины самолёта» ── */
.side { background: var(--side); color: var(--side-ink); border-right: 1px solid var(--line); }
.brand { color: var(--ink); }
.brand small, .ws-pick .k, .me .who span { color: var(--ink-3); }
.ws-pick { background: var(--surface); border-color: var(--line); color: var(--ink); }
.nav-h { color: var(--ink-3); }
.nav-h a { color: var(--accent); }
.nav a:hover, .proj a:hover, .nav a.on, .proj a.on { background: var(--surface); color: var(--ink); }
.side .me { border-top-color: var(--line); }
.me .who { color: var(--ink); }
.side .icon-btn { color: var(--ink-2); }
:root[data-theme="dark"] .brand, :root[data-theme="dark"] .ws-pick, :root[data-theme="dark"] .me .who { color: var(--ink); }

/* ── Шапка и вкладки: меньше линий, вкладки — мягкие «таблетки» ── */
.top { background: var(--bg); border-bottom: 0; padding-top: 20px; padding-bottom: 6px; }
.top .crumbs h1 { font-size: 22px; }
.tabs { background: var(--bg); border-bottom: 0; gap: 6px; padding-top: 6px; padding-bottom: 6px; }
.tabs a { border: 0; border-radius: 999px; padding: 8px 14px; color: var(--ink-2); }
.tabs a:hover { background: var(--surface-2); text-decoration: none; }
.tabs a.on { background: var(--ink); color: var(--bg); }
.card, .kpi { border-color: var(--line); border-radius: var(--radius); }

/* ── Главная: одна фраза, одно дело, три плитки ── */
.calm { max-width: 640px; }
.calm-hi { font-size: 15px; color: var(--ink-3); }
.calm-big { font-size: 36px; line-height: 1.1; font-weight: 750; letter-spacing: -.035em; margin: 8px 0 8px; }
.calm-big.bad b { color: var(--bad); }
.calm-big.warn b { color: var(--warn); }
.calm-big.good b { color: var(--good); }
.calm-big b { font-weight: 750; }
.calm-sub { font-size: 17px; color: var(--ink-2); line-height: 1.45; margin: 0; }
.calm-bar { height: 12px; border-radius: 9px; background: var(--surface-2); margin: 20px 0 8px; overflow: hidden; }
.calm-bar i { display: block; height: 100%; border-radius: 9px; background: var(--ink-3); }
.calm-bar.bad i { background: var(--bad); } .calm-bar.warn i { background: var(--warn); } .calm-bar.good i { background: var(--good); }
.calm-barl { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; color: var(--ink-3); }
.calm-todo { margin-top: 26px; background: var(--surface); border-radius: 22px; padding: 22px; box-shadow: 0 1px 0 var(--line); }
.calm-k { font-size: 12.5px; font-weight: 650; color: var(--ink-3); text-transform: uppercase; letter-spacing: .07em; }
.calm-q { font-size: 20px; font-weight: 650; line-height: 1.3; margin: 8px 0 6px; letter-spacing: -.01em; }
.calm-q b { color: var(--bad); white-space: nowrap; }
.calm-todo p { color: var(--ink-2); font-size: 15px; line-height: 1.5; margin: 0 0 4px; }
.calm-todo .calm-pre { font-size: 13px; color: var(--ink-3); }
.calm-btns { display: flex; gap: 8px; margin-top: 16px; }
.calm-btns > * { flex: 1; text-align: center; padding: 14px; border-radius: 14px; font: 600 15px/1.2 var(--font); border: 0; cursor: pointer; text-decoration: none; }
.calm-yes { background: var(--btn); color: var(--btn-ink); }
.calm-yes:hover { text-decoration: none; opacity: .9; }
.calm-no { background: var(--surface-2); color: var(--ink-2); }
.calm-extra { display: block; margin-top: 14px; font-size: 14px; font-weight: 600; color: var(--accent); }
.calm-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.calm-tiles > div { background: var(--surface); border-radius: 18px; padding: 16px 14px; }
.calm-tiles b { display: block; font-size: 24px; font-weight: 750; letter-spacing: -.02em; }
.calm-tiles span { display: block; font-size: 13px; color: var(--ink-3); line-height: 1.3; margin-top: 2px; }
.calm-more-btn { display: block; margin: 22px 0 6px; max-width: 640px; width: 100%; background: none; border: 0; font: 500 15px var(--font); color: var(--ink-3); cursor: pointer; padding: 10px; }
.calm-more-btn:hover { color: var(--ink); }
.calm-more { margin-top: 18px; }
.calm-more[hidden] { display: none; }
.cs-main .calm-more > * + * { margin-top: 18px; }
.cs-main .calm, .cs-main .calm-more-btn { margin-left: auto; margin-right: auto; }
.cs-main .calm + .calm-more-btn { margin-top: 22px; }

/* ── Кабинет клиента: шапка без стекла и линий ── */
.cs-top { background: var(--bg); border-bottom: 0; backdrop-filter: none; }
.cs-tabs a.on { background: var(--ink); color: var(--bg); }

/* ── Чат как мессенджер ── */
.msg-av { width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 17px;
  background: linear-gradient(135deg, #7b61ff, #ff7a59); }
.msg-av.sm { width: 28px; height: 28px; font-size: 13px; }
.msg-on { color: #3aa76d !important; }
.cw-fab { background: var(--surface); color: var(--ink); border: 1px solid var(--line); padding: 8px 18px 8px 8px; box-shadow: 0 12px 32px rgba(40, 30, 90, .18); }
.msgr { background: var(--msg-bg); border: 0; }
.msgr .cw-h, .msgr .cs-chat-h { background: var(--surface); border-bottom: 1px solid var(--msg-line); padding: 14px 16px; }
.msgr .cw-h b, .msgr .cs-chat-h b { font-size: 16px; }
.msgr .cs-av { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg, #7b61ff, #ff7a59); font-size: 17px; }
.msgr .cw-body, .msgr .cs-chat-body { padding: 16px 14px; gap: 8px; }
.msgr .cw-b { background: var(--surface); border: 0; border-radius: 20px 20px 20px 6px; font-size: 15.5px; line-height: 1.45; padding: 12px 14px; max-width: 86%; }
.msgr .cw-m.me .cw-b { background: var(--msg-me); color: #fff; border-radius: 20px 20px 6px 20px; }
.msgr .cs-chat .cw-m.mgr .cw-b, .msgr .cw-m.mgr .cw-b { background: var(--good-soft); }
.msg-day { align-self: center; font-size: 12px; color: var(--ink-3); background: var(--msg-line); border-radius: 10px; padding: 3px 10px; margin: 2px 0 4px; }
.msg-num { display: block; font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin: 4px 0 2px; }
.msgr .msg-card { padding: 0; overflow: hidden; max-width: 90%; }
.msg-card > p { padding: 12px 14px 10px; margin: 0; }
.msg-acts { display: flex; flex-wrap: wrap; border-top: 1px solid var(--msg-bg); }
.msg-acts > * { flex: 1 1 110px; min-height: 44px; white-space: nowrap; text-align: center; padding: 13px 8px; font: 600 15px/1.2 var(--font); color: var(--msg-me); background: none; border: 0; cursor: pointer; text-decoration: none; }
.msg-acts > * + * { border-left: 1px solid var(--msg-bg); color: var(--ink-3); }
.msg-acts a:hover { text-decoration: none; background: var(--msg-bg); }
.msgr .cw-chip { background: var(--surface); border: 1px solid var(--msg-line); color: var(--msg-ink); border-radius: 18px; padding: 8px 12px; font-size: 14px; font-weight: 500; }
.msgr .cw-chips { padding: 4px 14px 10px; }
.msgr .cw-in { border-top: 0; background: transparent; padding: 0 10px 14px; }
.msgr .cw-in textarea { background: var(--surface); border: 0; border-radius: 24px; padding: 12px 16px; font-size: 15px; }
.msgr .cw-in .btn { border-radius: 50%; background: var(--msg-me); border-color: var(--msg-me); color: #fff; }
.msgr .cs-mic { border-radius: 50%; }
.msgr .cw-links .btn { border-radius: 999px; }

@media (max-width: 720px) {
  .calm-big { font-size: 30px; }
  .calm-sub { font-size: 16px; }
  .calm-todo { padding: 18px; }
  .calm-q { font-size: 18px; }
  .calm-tiles b { font-size: 21px; }
  .calm-tiles > div { padding: 14px 12px; }
  .top { padding-top: 12px; }
  .cw-fab span:last-child { display: inline; }
  .top > .row { width: auto; margin-left: auto; }
  .top > .row .btn { flex: none; }
  .content, .cs-main { padding-bottom: 96px; }
}

/* ── Правила проекта ── */
.rl { max-width: 760px; }
.rl-h { font-size: 30px; margin: 6px 0 6px; letter-spacing: -.03em; }
.rl-sub { color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.rl-sec { margin: 26px 0 10px; font-size: 17px; }
.rl-sec .muted { font-weight: 500; font-size: 14px; }
.rl-list { display: flex; flex-direction: column; gap: 8px; }
.rl-it { display: flex; gap: 14px; align-items: flex-start; background: var(--surface); border-radius: 18px; padding: 16px; cursor: pointer; }
.rl-it.off { opacity: .55; }
.rl-it b { display: block; font-size: 15.5px; }
.rl-it p { margin: 3px 0 0; color: var(--ink-2); font-size: 14px; line-height: 1.45; }
.rl-it > div:nth-child(2) { flex: 1; min-width: 0; }
.rl-it .sw { margin-top: 2px; background: var(--line); width: 40px; height: 24px; cursor: pointer; }
.rl-it .sw i { width: 20px; height: 20px; }
.rl-it .sw.on { background: var(--good); }
.rl-it .sw.on i { left: 18px; }
.rl-btns { display: flex; gap: 4px; align-items: center; }
.rl-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.rl-empty { background: var(--surface); border-radius: 18px; padding: 16px; margin: 0; }
.rl-log { background: var(--surface); border-radius: 18px; padding: 6px 16px; }
.rl-log > div { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); flex-wrap: wrap; font-size: 14px; }
.rl-log > div:first-child { border-top: 0; }
.rl-log .when { color: var(--ink-3); font-size: 12.5px; width: 110px; }
.rl-log .muted { flex: 1; }
.rl-cond { display: grid; grid-template-columns: minmax(0, 1fr) 64px 96px auto; gap: 6px; margin-bottom: 6px; align-items: center; }
.rl-cond .inp { width: 100%; min-width: 0; }
.rl-link { display: block; background: var(--surface); border-radius: 16px; padding: 14px 16px; margin-bottom: 18px; color: var(--ink-2); font-size: 14.5px; }
.rl-link:hover { text-decoration: none; color: var(--ink); }
.rl-why { display: flex; flex-wrap: wrap; gap: 6px; }
.stars { display: flex; align-items: center; gap: 2px; margin-top: 8px; }
.stars button { background: none; border: 0; font-size: 20px; color: var(--line); cursor: pointer; padding: 0 1px; line-height: 1; }
.stars button.on, .stars button:hover { color: #f2b443; }
.stars span { margin-left: 8px; }

/* ── amoCRM / Битрикс24 ── */
.crm-tabs { display: inline-flex; background: var(--surface-2); border-radius: 12px; padding: 3px; gap: 2px; margin-bottom: 10px; }
.crm-tabs button { border: 0; background: none; padding: 8px 16px; border-radius: 9px; font: 600 14px var(--font); color: var(--ink-2); cursor: pointer; }
.crm-tabs button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.crm-map { display: flex; flex-direction: column; gap: 6px; }
.crm-map > div { display: grid; grid-template-columns: minmax(0, 1fr) 170px; gap: 10px; align-items: center; font-size: 14px; }
.crm-map .inp { width: 100%; }

/* ── выбор кампании с поиском ── */
.cpick { position: relative; }
.cpick-btn { display: inline-flex; align-items: center; gap: 8px; width: auto; max-width: 340px; cursor: pointer; text-align: left; }
.cpick-btn span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cpick-btn svg { width: 16px; height: 16px; flex: none; opacity: .6; }
.cpick-pop { position: absolute; z-index: 50; top: calc(100% + 6px); left: 0; width: min(440px, 86vw); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 50px rgba(20,20,40,.18); padding: 10px; }
.cpick-pop .inp { width: 100%; margin-bottom: 6px; }
.cpick-list { max-height: 360px; overflow: auto; display: flex; flex-direction: column; }
.cpick-list button { display: flex; align-items: center; gap: 8px; border: 0; background: none; text-align: left; padding: 8px 10px; border-radius: 10px; font: 500 14px var(--font); color: var(--ink); cursor: pointer; }
.cpick-list button:hover { background: var(--surface-2); }
.cpick-list button.on { background: var(--accent-soft, #fff1ea); }
.cpick-list button span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cpick-list em { font-style: normal; font-size: 12px; color: var(--ink-2); background: var(--surface-2); border-radius: 8px; padding: 1px 7px; }
.cpick-list .dot { width: 8px; height: 8px; border-radius: 50%; background: #c9c7c0; flex: none; }
.cpick-list .dot.on { background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,.18); }
.cpick-h { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); padding: 10px 10px 4px; }

/* ── Аналитика: РНП и сквозная по креативам ── */
.an-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.an-head h2 { font-size: 24px; letter-spacing: -.02em; }
.an-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; vertical-align: -1px; }
.an-dot.bad { background: #ffd9d4; box-shadow: inset 0 0 0 1px #f3a69b; }
.an-dot.good { background: #d6f5df; box-shadow: inset 0 0 0 1px #8fd9a6; }
.an-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin-bottom: 16px; }
.an-kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; position: relative; overflow: hidden; }
.an-kpi::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: linear-gradient(90deg, #ff8a5b, #ff5f8f, #8b6cff); opacity: .8; }
.an-kpi span { font-size: 12px; color: var(--ink-2); font-weight: 600; }
.an-kpi b { font-size: 22px; letter-spacing: -.02em; }
.an-kpi em { font-style: normal; font-size: 12px; color: var(--ink-2); }
.an-kpi.good b { color: #16a34a; } .an-kpi.bad b { color: #dc4a36; }
.an-card { margin-bottom: 16px; }
.an-wrap { overflow: auto; margin: 6px -4px 0; max-height: 640px; border-radius: 12px; }
.an-tbl { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 13px; font-variant-numeric: tabular-nums; }
.an-tbl th { position: sticky; top: 0; z-index: 2; background: var(--surface); font-size: 11px; font-weight: 700; color: var(--ink-2); text-transform: uppercase; letter-spacing: .03em; padding: 8px 10px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.an-tbl tr.an-g th { top: 0; text-align: center; border-bottom: 0; padding: 6px 4px 2px; }
.an-tbl thead tr:nth-child(2) th { top: 26px; }
.an-tbl tr.an-g th:not(:first-child) { border-radius: 8px 8px 0 0; }
.an-tbl .g-t { color: #3b82f6; } .an-tbl .g-l { color: #e2552b; } .an-tbl .g-c { color: #16a34a; }
.an-tbl td { padding: 9px 10px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.an-tbl tbody tr:hover td { background: var(--surface-2); }
.an-tbl td.bad { background: #ffeae6; color: #b4321f; font-weight: 600; }
.an-tbl td.good { background: #e3f7e9; color: #137a3a; font-weight: 600; }
.an-tbl .an-day { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; }
.an-tbl th.an-day { z-index: 3; }
.an-tbl td.an-day b { display: block; font-size: 13px; } .an-tbl td.an-day span { font-size: 11px; color: var(--ink-2); }
.an-tbl tfoot td { font-weight: 700; background: var(--surface-2); border-bottom: 0; position: sticky; bottom: 0; }
.an-cr td:first-child, .an-cr th:first-child { text-align: left; }
.an-ad { display: flex; gap: 10px; align-items: center; min-width: 280px; max-width: 420px; white-space: normal; }
.an-ad img, .an-noimg { width: 52px; height: 52px; border-radius: 12px; object-fit: cover; flex: none; background: var(--surface-2); display: grid; place-items: center; font-size: 22px; }
.an-ad b { display: block; font-size: 13px; line-height: 1.3; }
.an-ad span { display: block; font-size: 11px; color: var(--ink-2); margin: 2px 0 4px; }
.an-tag { font-style: normal; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 8px; background: var(--surface-2); color: var(--ink-2); }
.an-tag.good { background: #e3f7e9; color: #137a3a; } .an-tag.info { background: #e6efff; color: #2456c9; } .an-tag.bad { background: #ffeae6; color: #b4321f; }
[data-theme=dark] .an-tbl td.bad { background: rgba(220,74,54,.18); color: #ff9a8a; }
[data-theme=dark] .an-tbl td.good { background: rgba(22,163,74,.18); color: #7be3a0; }
[data-theme=dark] .an-tag.good { background: rgba(22,163,74,.18); color: #7be3a0; } [data-theme=dark] .an-tag.info { background: rgba(59,130,246,.18); color: #93b8ff; } [data-theme=dark] .an-tag.bad { background: rgba(220,74,54,.18); color: #ff9a8a; }
@media (max-width: 900px) { .an-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 520px) { .an-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .an-kpi b { font-size: 19px; } }

/* ── Тариф по бюджету ── */
.bl-spend { margin-top: 14px; display: grid; grid-template-columns: 1fr auto; gap: 2px 14px; padding: 14px 16px; border-radius: 14px; background: linear-gradient(120deg, #fff3ec, #fdeef6 60%, #f1edff); }
.bl-spend span { font-size: 13px; color: var(--ink-2); } .bl-spend b { grid-row: span 2; align-self: center; font-size: 26px; letter-spacing: -.02em; }
.bl-spend em { font-style: normal; font-size: 13px; font-weight: 600; color: #c2410c; }
.bl-use { margin-top: 10px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.bl-use > div { padding: 12px 14px; border-radius: 14px; background: var(--card-2, #f7f5fb); display: grid; gap: 4px; }
.bl-use span { font-size: 13px; color: var(--ink-2); } .bl-use b { font-size: 18px; letter-spacing: -.01em; }
.bl-use i { height: 6px; border-radius: 6px; background: rgba(120, 100, 160, .15); overflow: hidden; }
.bl-use i s { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, #ff7a3d, #e5487f); }
.bl-use em { grid-column: 1 / -1; font-style: normal; font-size: 12px; color: var(--ink-3, #8a8496); }
@media (max-width: 600px) { .bl-use { grid-template-columns: 1fr; } }
[data-theme=dark] .bl-spend { background: linear-gradient(120deg, rgba(255,138,91,.14), rgba(255,95,143,.1) 60%, rgba(139,108,255,.12)); }
.bl-plans { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }
.bl-plans .plan h2 { font-size: 19px; margin: 2px 0 8px; }
.bl-plans .price { font-size: 24px; }
.bl-all { margin-top: 16px; } .bl-all ul { columns: 2; margin: 10px 0 0; padding-left: 18px; } .bl-all li { margin: 4px 0; font-size: 14px; }
@media (max-width: 1500px) { .bl-plans { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; } }
@media (max-width: 640px) { .bl-plans { grid-template-columns: 1fr !important; } .bl-all ul { columns: 1; } }

/* ── Главная v3: живой денежный блок ── */
.calm { max-width: 760px; }
.calm-hero { position: relative; overflow: hidden; display: flex; align-items: center; gap: 22px; padding: 26px 28px; border-radius: 28px; color: #fff;
  background: radial-gradient(120% 140% at 100% 0%, rgba(255,122,80,.55), transparent 55%), radial-gradient(90% 120% at 0% 100%, rgba(139,108,255,.55), transparent 60%), linear-gradient(135deg, #1b1830, #2a1f3d 55%, #3a1f2f); box-shadow: 0 20px 50px -20px rgba(42,31,61,.55); }
.calm-hero.good { background: radial-gradient(120% 140% at 100% 0%, rgba(52,211,153,.5), transparent 55%), radial-gradient(90% 120% at 0% 100%, rgba(139,108,255,.45), transparent 60%), linear-gradient(135deg, #12241f, #1c2a3d 60%, #23203a); }
.calm-hero::after { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.08) 1px, transparent 1px); background-size: 18px 18px; mask-image: linear-gradient(90deg, transparent, #000 70%); pointer-events: none; }
.calm-hero-t { flex: 1; min-width: 0; position: relative; z-index: 1; }
.calm-hero .calm-hi { color: rgba(255,255,255,.7); }
.calm-hero .calm-big { color: #fff; font-size: 38px; }
.calm-hero .calm-big.bad b { color: #ff9c7a; } .calm-hero .calm-big.warn b { color: #ffd27a; } .calm-hero .calm-big.good b { color: #6ff0b4; }
.calm-hero .calm-sub { color: rgba(255,255,255,.82); }
.calm-hero .calm-barl { margin-top: 14px; color: rgba(255,255,255,.62); }
.calm-ring { position: relative; z-index: 1; width: 132px; height: 132px; flex: none; }
.calm-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.calm-ring circle { fill: none; stroke: rgba(255,255,255,.14); stroke-width: 11; }
.calm-ring circle.v { stroke: #ff8a5b; stroke-linecap: round; transition: stroke-dasharray .8s ease; filter: drop-shadow(0 0 6px rgba(255,138,91,.6)); }
.calm-ring.good circle.v { stroke: #34d399; filter: drop-shadow(0 0 6px rgba(52,211,153,.6)); } .calm-ring.warn circle.v { stroke: #fbbf24; }
.calm-ring > div { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.calm-ring b { font-size: 26px; font-weight: 750; letter-spacing: -.02em; } .calm-ring span { font-size: 11px; color: rgba(255,255,255,.65); max-width: 90px; line-height: 1.2; }
.calm-todo { display: flex; gap: 16px; align-items: flex-start; position: relative; margin-top: 16px; border-radius: 24px; padding: 22px; background: var(--surface); box-shadow: 0 10px 30px -18px rgba(226,85,43,.35); border: 1.5px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(120deg, #ff8a5b, #ff5f8f 50%, #8b6cff) border-box; }
.calm-todo-b { flex: 1; min-width: 0; }
.calm-ico { width: 46px; height: 46px; flex: none; border-radius: 14px; display: grid; place-items: center; font-size: 22px; background: linear-gradient(135deg, #fff1e8, #ffe6f0); }
[data-theme=dark] .calm-ico { background: linear-gradient(135deg, rgba(255,138,91,.2), rgba(255,95,143,.18)); }
.calm-yes { background: linear-gradient(120deg, #e2552b, #ff5f8f); color: #fff; box-shadow: 0 8px 20px -10px rgba(226,85,43,.8); }
.calm-tiles { grid-template-columns: repeat(3, 1fr); }
.calm-tiles > div { position: relative; overflow: hidden; border: 1px solid var(--line); padding: 16px; }
.calm-tiles > div i { font-style: normal; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 17px; margin-bottom: 10px; background: #eef2ff; }
.calm-tiles > div.t1 i { background: #e7f8ee; } .calm-tiles > div.t2 i { background: #fff1e8; } .calm-tiles > div.t3 i { background: #fdeef6; }
[data-theme=dark] .calm-tiles > div i { background: rgba(255,255,255,.08); }
.calm-tiles > div::after { content: ''; position: absolute; right: -30px; top: -30px; width: 90px; height: 90px; border-radius: 50%; background: radial-gradient(circle, rgba(139,108,255,.12), transparent 70%); }
.calm-tiles > div.t1::after { background: radial-gradient(circle, rgba(52,211,153,.14), transparent 70%); } .calm-tiles > div.t2::after { background: radial-gradient(circle, rgba(255,138,91,.16), transparent 70%); }
.calm-more-btn { max-width: 760px; }
@media (max-width: 600px) { .calm-hero { flex-direction: column; align-items: flex-start; padding: 22px; } .calm-hero .calm-big { font-size: 30px; } .calm-ring { width: 110px; height: 110px; align-self: center; } .calm-todo { flex-direction: column; } .calm-tiles { grid-template-columns: 1fr 1fr; } }

/* ── Настройки проекта: плитки и группы ── */
.set-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.set-tile { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 4px; padding: 18px; border-radius: 22px; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); transition: transform .15s, box-shadow .15s; }
.set-tile:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -18px rgba(40,30,80,.4); text-decoration: none; }
.set-tile i { font-style: normal; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; font-size: 22px; margin-bottom: 8px; color: #fff; }
.set-tile b { font-size: 15px; } .set-tile small { font-size: 12.5px; color: var(--ink-2); line-height: 1.35; }
.set-tile::after { content: '→'; position: absolute; right: 16px; top: 18px; color: var(--ink-3); font-size: 16px; }
.t-meta i { background: linear-gradient(135deg, #4f7cff, #8b6cff); } .t-crm i { background: linear-gradient(135deg, #22c55e, #14b8a6); }
.t-mode i { background: linear-gradient(135deg, #ff8a5b, #e2552b); } .t-rules i { background: linear-gradient(135deg, #ff5f8f, #8b6cff); }
.set-grp { padding: 14px; border-radius: 16px; background: var(--surface-2); margin-top: 10px; }
.set-gh { font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.set-econ .grid.g2 { gap: 10px; }
.set-lim .limit { border-radius: 16px; }
.set-rules { padding: 0; }
.set-rules > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; align-items: center; padding: 18px 20px; }
.set-rules > summary::-webkit-details-marker { display: none; }
.set-rules > summary span { grid-row: span 2; width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-size: 20px; background: linear-gradient(135deg, #fff1e8, #f1edff); }
.set-rules > summary b { font-size: 16px; } .set-rules > summary em { font-style: normal; font-size: 13px; color: var(--ink-2); }
.set-rules[open] > summary { border-bottom: 1px solid var(--line); }
.set-rules > .grid { padding: 16px 20px 20px; }
[data-theme=dark] .set-rules > summary span { background: rgba(255,255,255,.08); }
@media (max-width: 900px) { .set-tiles { grid-template-columns: 1fr 1fr; } }
