/* ═══ Живое демо: окно Lobby и CRM, свёрстанное как настоящее. Геометрия и цвета окна — Lobby (mocups/lobby-variants.html):
   таблетки, скругления, обои. Вокруг окна — фирстиль лендинга. Янтарь — только у подготовленного ИИ. ═══ */
.dm { --w-bg: #E6E6E4; --w-panel: #FFFFFF; --w-line: #ECECEB; --w-ink: #1E1E1E; --w-ink2: #4A4A4A; --w-muted: #737373; --w-rail: #141414; --w-out: #1E1E1E; margin-top: clamp(32px, 4vw, 56px); }
.js .copilot__visual--static { display: none; }
html:not(.js) .dm { display: none; }

/* ── Этапы над окном ── */
.dm__stages { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.dm__stage { position: relative; display: flex; align-items: baseline; gap: 10px; min-height: 48px; padding: 14px 0 12px; border: 0; background: none; color: #8E8E8E; text-align: start; font-size: 16px; font-weight: 500; transition: color .2s; }
.dm__stage::before, .dm__stage::after { content: ''; position: absolute; left: 0; top: 0; height: 3px; }
.dm__stage::before { right: 0; background: var(--g60); }
.dm__stage::after { right: 0; background: var(--red-hi); transform: scaleX(var(--p, 0)); transform-origin: 0 50%; transition: transform .12s linear; }
.dm__stage b { font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: .06em; }
.dm__stage:hover, .dm__stage.is-past { color: #D4D4D4; }
.dm__stage.is-on { color: #fff; }
.dm__stage.is-on b { color: var(--red-hi); }
.dm__cap { min-height: 2.8em; margin: 4px 0 8px; font-size: clamp(18px, 1.5vw, 22px); line-height: 1.36; color: #F1F1F1; max-width: 46em; }

/* ── Окно ── */
.dm-win { position: relative; display: grid; grid-template-columns: 76px 264px minmax(0, 1fr) minmax(0, .86fr); gap: 8px; height: clamp(600px, calc(100vh - 220px), 800px); padding: 8px; overflow: hidden; border-radius: 14px; background: var(--w-bg); color: var(--w-ink); font-size: 14px; line-height: 1.4; box-shadow: 0 30px 80px rgba(0, 0, 0, .45); transition: grid-template-columns .5s cubic-bezier(.2,.7,.2,1); }
.dm-win.is-board { grid-template-columns: 76px 0 minmax(0, .8fr) minmax(0, 1fr); }
.dm-win.is-board .dm-listcol { visibility: hidden; margin-right: -8px; }
.dm-win p, .dm-win dl, .dm-win dd, .dm-win ul, .dm-win ol { margin: 0; }
.dm-win b { font-weight: 600; }
.dm-win small { font-size: 12px; color: var(--w-muted); }
.dm-rail { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 0; border-radius: 12px; background: var(--w-rail); color: #8E8E8E; }
.dm-rail__logo { width: 34px; height: 34px; margin-bottom: 10px; border-radius: 9px; }
.dm-rail__i { position: relative; display: grid; justify-items: center; gap: 2px; width: 62px; padding: 7px 0 5px; border-radius: 12px; }
.dm-rail__i small { font-size: 12px; line-height: 1.2; color: inherit !important; white-space: nowrap; }
.dm-rail__i i { position: absolute; left: 34px; top: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: #E2483A; color: #fff; font: 600 12px/17px var(--sans); text-align: center; }
.dm-rail__i.on { background: #262626; color: #fff; }
.dm-rail__user { width: 34px; height: 34px; margin-top: auto; border-radius: 50%; object-fit: cover; }
.is-lead .dm-rail__user { box-shadow: 0 0 0 2px var(--red-hi); }

.dm-listcol { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border-radius: 12px; background: var(--w-panel); }
.dm-listcol__head { display: grid; grid-template-columns: 1fr auto 1fr; padding: 13px 14px 8px; font-size: 15px; color: var(--w-muted); }
.dm-listcol__head b { color: var(--w-ink); }
.dm-listcol__search { display: flex; align-items: center; gap: 8px; margin: 0 10px 8px !important; padding: 6px 12px; border-radius: 16px; background: #F4F4F3; color: var(--w-muted); }
.dm-listcol__search .dm-ic, .dm-listcol__search svg { width: 15px; height: 15px; }
.dm-list { flex: 1; overflow: hidden; padding: 0 6px 6px; }
.dm-row { position: relative; display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; transition: background-color .2s; }
.dm-row.is-on { background: #4C91C7; color: #fff; }
.dm-row.is-on small, .dm-row.is-on p { color: rgba(255, 255, 255, .86); }
.dm-row.is-on .dm-row__tag { border-color: rgba(255, 255, 255, .5); color: #fff; }
.dm-row__tag { flex: none; margin-inline-end: auto; padding: 0 5px; border: 1px solid var(--g20); border-radius: 5px; font-style: normal; font-size: 12px; line-height: 16px; color: var(--w-muted); }
.dm-row__main { flex: 1; min-width: 0; }
.dm-row__line { display: flex; justify-content: space-between; gap: 6px; }
.dm-row__line { align-items: center; }
.dm-row__line small { margin-inline-start: auto; }
.dm-row__line b { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; }
.dm-row p { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: 13px; line-height: 1.3; color: var(--w-muted); padding-inline-end: 22px; }
.dm-dot { position: absolute; right: 12px; bottom: 16px; width: 10px; height: 10px; border-radius: 50%; background: var(--red); }
.dm-badge { position: absolute; right: 10px; bottom: 10px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--red); color: #fff; font: 600 12px/18px var(--sans); text-align: center; }
.dm-av { flex: none; display: grid; place-items: center; width: 44px; height: 44px; overflow: hidden; border-radius: 50%; background: #E2E2E0; color: var(--w-ink); font-size: 13px; font-weight: 600; }
.dm-av img { width: 100%; height: 100%; object-fit: cover; }
.dm-av--ai { background: var(--w-ink); color: #fff; }
.dm-av--c { background: #2F7D76; color: #fff; }
.dm-av--g1 { background: #2C6A9E; color: #fff; }
.dm-av--g2 { background: #8A5A3C; color: #fff; }
.dm-av--g3 { background: #5B4BA6; color: #fff; }
.dm-chat__head .dm-av { width: 38px; height: 38px; }

/* ── Чат ── */
.dm-chat { position: relative; display: flex; flex-direction: column; min-width: 0; overflow: hidden; border-radius: 12px; background: #ECECEC url('demo/wall.svg') repeat; }
.dm-chat__head { display: flex; align-items: center; gap: 10px; margin: 8px 8px 0; padding: 7px 12px 7px 8px; border-radius: 26px; background: rgba(255, 255, 255, .88); }
.dm-chat__who { min-width: 0; flex: 1; padding-inline-end: 170px; }
.dm-chat__who b { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; }
.dm-chat__who small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dm-view { position: absolute; top: 17px; right: 18px; z-index: 2; padding: 3px 10px; border-radius: 12px; background: var(--w-bg); font-size: 12px; color: var(--w-ink2); }
.is-lead .dm-view { background: var(--w-ink); color: #fff; }
.dm-threads { position: relative; flex: 1; min-height: 0; }
.dm-stream { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 8px; padding: 14px 14px 10px; overflow: hidden auto; scrollbar-width: none; }
.dm-stream::-webkit-scrollbar { display: none; }
.dm-stream > :first-child { margin-top: auto; }
.dm-b { flex: none; max-width: 86%; padding: 9px 12px; border-radius: 17px; font-size: 14px; line-height: 1.4; }
.dm-b small { display: flex; justify-content: flex-end; align-items: center; gap: 4px; margin-top: 2px; font-size: 12px; }
.dm-b--out { align-self: flex-end; background: var(--w-out); color: #fff; }
.dm-b--out small { color: rgba(255, 255, 255, .6); }
.dm-b--in, .dm-b--ai { align-self: flex-start; background: #fff; }
.dm-b__who { display: block; margin-bottom: 1px; font-size: 13px; color: #2F7D76; }
.dm-b--voice { width: 86%; }
.dm-wave { display: flex; align-items: center; gap: 2px; height: 24px; margin-bottom: 8px; }
.dm-wave i { flex: 1; min-width: 0; max-width: 3px; min-height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .7); }
.dm-wave b { margin-inline-start: auto; font-size: 12px; font-weight: 500; }
.dm-tool { flex: none; display: flex; align-items: center; gap: 8px; padding: 1px 2px; font-size: 13px; color: var(--w-ink2); }
.dm-tool .think { gap: 3px; }
.dm-tool .think i { width: 5px; height: 5px; }
.dm-tool__ok { display: inline-flex; color: #2F7D76; }
.dm-pill { flex: none; align-self: center; padding: 3px 12px; border-radius: 12px; background: #fff; color: var(--w-ink2); font-size: 13px; }
.dm-typing { display: inline-flex; gap: 4px; padding: 12px 14px; }
.dm-typing i { width: 6px; height: 6px; background: #A3A3A3; animation: think 1.05s steps(1) infinite; }
.dm-typing i:nth-child(2) { animation-delay: .35s; }
.dm-typing i:nth-child(3) { animation-delay: .7s; }
.dm-file { display: flex; align-items: center; gap: 10px; }
.dm-file b { display: block; font-size: 14px; }
.dm-b--media { width: 86%; }
.dm-album { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; margin: -3px -6px 8px; overflow: hidden; border-radius: 10px; }
.dm-album img { width: 100%; height: 70px; object-fit: cover; }

/* ── Черновик ── */
.dm-card { flex: none; align-self: stretch; max-width: 100%; overflow: hidden; border: 2px solid var(--amber); border-radius: 16px; background: var(--amber-bg); transition: border-color .25s, background-color .25s; }
.dm-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 10px 12px 8px; }
.dm-card__head b { display: block; font-size: 15px; }
.dm-card .draft-tag { flex: none; font-family: var(--sans); font-size: 12px; letter-spacing: 0; text-transform: none; }
.dm-card__body { padding: 0 12px 10px; }
.dm-card__text { font-size: 14px; line-height: 1.45; white-space: pre-wrap; }
.dm-human { padding: 0 1px; background: rgba(30, 30, 30, .07); }
.dm-fields { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid #F1E3C4; }
.dm-f { padding: 6px 0; border-bottom: 1px solid #F1E3C4; }
.dm-f:nth-child(odd) { padding-right: 10px; }
.dm-f dt { display: flex; justify-content: space-between; gap: 6px; font-size: 12px; color: var(--w-muted); }
.dm-f dt em { font-style: normal; font-size: 12px; color: var(--amber-ink); }
.dm-f dd { font-weight: 600; }
.dm-docs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px !important; }
.dm-docs span { padding: 3px 10px; border: 1px solid var(--g20); border-radius: 12px; background: #fff; font-size: 13px; }
.dm-docs span.on { border-color: var(--w-ink); background: var(--w-ink); color: #fff; }
.dm-card__foot { display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 0 12px 12px; }
.dm-your { display: none; font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; color: var(--red); }
.dm-go { min-height: 40px; padding: 0 18px; border: 0; border-radius: 20px; background: var(--w-ink); color: #fff; font-size: 14px; font-weight: 600; }
.dm-go.is-wait { background: var(--red); animation: dm-pulse 1.5s ease-out infinite; }
.dm-go.is-wait:hover { background: #A50D26; }
.dm-card__foot:has(.is-wait) .dm-your { display: inline; }
@keyframes dm-pulse { 0% { box-shadow: 0 0 0 0 rgba(200, 16, 46, .45); } 80%, 100% { box-shadow: 0 0 0 14px rgba(200, 16, 46, 0); } }
.dm-card.is-done { border-color: var(--w-line); background: #fff; }
.dm-card.is-done .draft-tag { color: var(--w-ink); }
.dm-card.is-done .draft-tag::before { background: var(--w-ink); }
.dm-card.is-done .dm-fields, .dm-card.is-done .dm-f { border-color: var(--w-line); }
.dm-card.is-done .dm-f dt em { color: var(--w-muted); }
.dm-stop { flex: none; display: flex; align-items: center; gap: 8px; padding: 7px 10px; border: 1px solid var(--red); border-radius: 10px; background: #fff; color: var(--red); font-size: 13px; font-weight: 500; }
.dm-stop .dm-ic { display: inline-flex; }
.dm-link { padding-bottom: 8px; font-size: 13px; color: var(--w-ink2); }
.dm-checks { display: grid; gap: 4px; padding-top: 8px; border-top: 1px solid #F1E3C4; }
.is-done .dm-checks { border-color: var(--w-line); }
.dm-checks li { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.dm-checks li.is-open i { flex: none; width: 10px; height: 10px; margin: 0 2px; background: var(--amber); }
.dm-strip { flex: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.dm-plate { overflow: hidden; border-radius: 10px; background: #fff; }
.dm-plate img { width: 100%; height: 76px; object-fit: cover; }
.dm-plate > div { padding: 6px 8px 8px; }
.dm-plate b { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13px; }
.dm-plate span { display: block; font-size: 13px; }
.dm-plate small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* ── Поле ввода ── */
.dm-sugg { align-self: flex-start; margin: 0 8px 6px 56px; max-width: calc(100% - 64px); min-height: 34px; padding: 5px 14px; border: 0; border-radius: 17px; background: #fff; color: var(--w-ink); font-size: 14px; text-align: start; box-shadow: 0 0 0 1px var(--g20); }
.dm-sugg:hover { box-shadow: 0 0 0 1px var(--w-ink); }
.dm-comp__clip { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #fff; color: var(--w-ink2); }
.dm-comp { display: flex; align-items: flex-end; gap: 8px; margin: 0 8px 8px; }
.dm-comp__box { flex: 1; min-width: 0; min-height: 40px; max-height: 108px; overflow: hidden; display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 20px; background: #fff; color: var(--w-muted); font-size: 14px; line-height: 1.4; }
.dm-comp__ph { flex: 1; }
.dm-comp__text { display: none; flex: 1; min-width: 0; color: var(--w-ink); }
.dm-comp.is-typing .dm-comp__ph, .dm-comp.is-rec .dm-comp__ph { display: none; }
.dm-comp.is-typing .dm-comp__text, .dm-comp.is-rec .dm-comp__text { display: block; }
.dm-comp.is-typing .dm-comp__text::after { content: ''; display: inline-block; width: 8px; height: 8px; margin-left: 3px; background: var(--red); animation: think 1.05s steps(1) infinite; }
.dm-comp__rec { display: none; flex: none; width: 10px; height: 10px; align-self: flex-start; margin-top: 5px; background: var(--red); animation: think 1.05s steps(1) infinite; }
.dm-comp.is-rec .dm-comp__rec { display: block; }
.dm-comp__mic { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--w-ink); color: #fff; transition: background-color .2s, transform .2s; }
.dm-comp.is-rec .dm-comp__mic { background: var(--red); transform: scale(1.12); }

/* ── Панель CRM ── */
.dm-syscol { position: relative; display: flex; flex-direction: column; min-width: 0; overflow: hidden; border-radius: 12px; background: #fff; }
.dm-syscol__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px 0; }
.dm-syscol__head > span { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: .05em; text-transform: uppercase; color: var(--w-muted); }
.dm-tabs { display: flex; gap: 2px; padding: 10px 10px 8px; border-bottom: 1px solid var(--w-line); }
.dm-tabs span { padding: 4px 10px; border-radius: 14px; font-size: 13px; color: var(--w-muted); transition: background-color .2s, color .2s; }
.dm-tabs span.is-on { background: var(--w-ink); color: #fff; }
.dm-sys { flex: 1; min-height: 0; overflow: hidden; padding: 10px; }
.dm-sys__h { margin-bottom: 8px !important; color: var(--w-muted); font-size: 12px; }
.dm-recs { display: grid; gap: 2px; }
.dm-rec { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 56px; padding: 8px 10px; border: 1px solid transparent; border-bottom-color: var(--w-line); border-radius: 8px; }
.dm-rec b { display: block; }
.dm-rec > div { min-width: 0; }
.dm-rec small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dm-stage { flex: none; padding: 2px 9px; border-radius: 11px; background: var(--w-bg); font-size: 12px; color: var(--w-ink2); }
.dm-stage.is-ok { background: var(--w-ink); color: #fff; }
.dm-rec.is-ghost { border: 1px dashed var(--amber); background: var(--amber-bg); }
.dm-rec.is-ghost .dm-stage { background: none; color: var(--amber-ink); }
.dm-audit { margin-top: auto; padding: 8px 12px 10px; border-top: 1px solid var(--w-line); font-size: 12px; line-height: 1.35; color: var(--w-muted); min-height: 56px; }
.dm-audit li { display: flex; gap: 8px; }
.dm-audit time { flex: none; font-family: var(--mono); }
.dm-audit span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dm-audit li:first-child { color: var(--w-ink); }

.dm-cat__bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.dm-cat__q { flex: 1; min-width: 0; min-height: 34px; display: flex; align-items: center; gap: 6px; padding: 4px 12px; border: 1px solid var(--g20); border-radius: 17px; font-size: 13px; }
.dm-cat__q .dm-ic { display: inline-flex; }
.dm-cat__q svg { width: 14px; height: 14px; }
.dm-cat__count { flex: none; }
.dm-cat__n { font-size: 15px; font-variant-numeric: tabular-nums; }
.dm-cat { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.dm-tile { min-width: 0; overflow: hidden; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px var(--w-line); }
.dm-tile img { width: 100%; height: clamp(70px, 8.4vw, 118px); object-fit: cover; }
.dm-tile > div { padding: 6px 8px 8px; }
.dm-tile b, .dm-tile small, .dm-tile span { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dm-tile b { font-size: 13px; }
.dm-tile span { margin-top: 2px; font-size: 13px; font-weight: 600; }

.dm-lead__top { display: flex; align-items: center; gap: 10px; }
.dm-lead__top b { display: block; font-size: 16px; }
.dm-steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; margin: 14px 0 16px !important; }
.dm-steps i { display: block; height: 4px; background: var(--g10); transition: background-color .4s; }
.dm-steps span { display: block; margin-top: 4px; font-size: 12px; color: var(--w-muted); white-space: nowrap; }
.dm-steps li.on i { background: var(--w-ink); }
.dm-steps li.now i { background: var(--red); }
.dm-steps li.now span { color: var(--w-ink); font-weight: 600; }
.dm-lead__h { color: var(--w-muted); font-size: 12px; margin-bottom: 6px !important; }
.dm-hist li { padding: 8px 6px; border-bottom: 1px solid var(--w-line); font-size: 14px; }

.dm-board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.dm-col { min-height: 132px; padding: 8px; border-radius: 10px; background: var(--w-bg); }
.dm-col .mono { margin-bottom: 8px !important; font-size: 12px; letter-spacing: .02em; text-transform: none; color: var(--w-ink2); }
.dm-kb { position: relative; padding: 7px 8px; margin-bottom: 6px; border-radius: 8px; background: #fff; }
.dm-kb b, .dm-kb small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dm-kb--on { z-index: 1; background: var(--w-ink); color: #fff; }
.dm-kb--on small { color: rgba(255, 255, 255, .72) !important; }
.dm-calc { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--w-line); border-radius: 10px; }
.dm-calc .mono { margin-bottom: 6px !important; font-size: 12px; letter-spacing: .02em; text-transform: none; color: var(--w-muted); }
.dm-calc__r { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; border-bottom: 1px solid var(--w-line); }
.dm-calc__r b { font-variant-numeric: tabular-nums; }
.dm-payout { display: flex; align-items: center; gap: 8px; margin-top: 8px !important; font-weight: 500; }
.dm-payout::before { content: ''; flex: none; width: 9px; height: 9px; background: var(--red); }

/* ── Перелёт, курсор, смена экрана ── */
.dm-fly { position: absolute; left: 0; top: 0; z-index: 8; padding: 5px 12px; border-radius: 14px; background: var(--w-ink); color: #fff; font: 600 13px/1.3 var(--sans); white-space: nowrap; pointer-events: none; box-shadow: 0 8px 24px rgba(0, 0, 0, .3); }
.dm-cursor { position: absolute; left: 0; top: 0; z-index: 9; width: 22px; height: 22px; pointer-events: none; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .35)); }
.dm-switch { position: absolute; left: 50%; top: 58px; z-index: 7; padding: 6px 14px; border-radius: 16px; background: var(--red); color: #fff; font-size: 14px; font-weight: 600; white-space: nowrap; transform: translateX(-50%); }

/* ── Табло и финал ── */
.dm-tv { position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 10px; padding: 24px; background: var(--ink); color: #fff; text-align: center; }
.dm-tv__k { color: #A8A8A8; }
.dm-tv__b { font-family: var(--display); font-weight: 800; font-size: clamp(44px, 7vw, 104px); line-height: 1; letter-spacing: var(--track-display); }
.dm-tv__b i { display: inline-block; width: .2em; height: .2em; margin-left: .05em; background: var(--red); }
.dm-tv__w { font-size: clamp(18px, 2vw, 28px); }
.dm-tv__t { margin-top: 16px !important; display: flex; align-items: baseline; gap: 8px; color: #A8A8A8; }
.dm-tv__t b { font-size: 32px; color: #fff; font-variant-numeric: tabular-nums; }
.dm-end { position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 16px; padding: clamp(24px, 6vw, 96px); background: rgba(14, 14, 14, .95); color: #fff; }
.dm-end h3 { font-family: var(--display); font-weight: 800; font-size: clamp(32px, 4.4vw, 68px); line-height: 1.04; letter-spacing: var(--track-display); max-width: 14em; }
:lang(ru) .dm-end h3 { font-weight: 700; }
.dm-end p { max-width: 34em; font-size: clamp(17px, 1.5vw, 21px); color: #D4D4D4; }
.dm-end__row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 8px; }
.dm-end__cta { display: inline-flex; align-items: center; min-height: 56px; padding: 0 24px; background: #fff; color: var(--graphite); font-weight: 600; text-decoration: none; }
.dm-end__cta:hover { background: var(--g10); }
.dm-end__again { min-height: 56px; padding: 0 22px; border: 1px solid var(--g60); background: none; color: #fff; font-weight: 600; }
.dm-end__again:hover { border-color: #fff; }

/* ── Управление ── */
.dm__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 18px; margin-top: 14px; font-size: 15px; color: #A8A8A8; }
.dm__ctl { min-width: 44px; min-height: 44px; padding: 0; border: 0; background: none; color: #F1F1F1; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--g60); }
.dm__ctl:hover { text-decoration-color: currentColor; }
.dm__hint { margin-inline-start: auto !important; }

@media (prefers-reduced-motion: reduce) {
  .dm-go.is-wait, .dm-typing i, .dm-comp__rec, .dm-comp.is-typing .dm-comp__text::after { animation: none; }
  .dm-win, .dm__stage::after { transition: none; }
}

@media (max-width: 1240px) {
  .dm-win { grid-template-columns: 76px minmax(0, 1fr) minmax(0, .86fr); }
  .dm-win.is-board { grid-template-columns: 76px minmax(0, .8fr) minmax(0, 1fr); }
  .dm-listcol { display: none; }
}
@media (max-width: 860px) {
  /* Телефон: чат и под ним CRM. Рейл и список — лишние, история читается и без них. */
  .dm { margin-inline: calc(var(--gutter) * -1); padding-inline: 12px; }
  .dm__stages { gap: 3px; }
  .dm__stage { justify-content: center; }
  .dm__stage span { display: none; }
  .dm__stage.is-on span { display: inline; }
  .dm__stages { grid-template-columns: repeat(5, auto); }
  .dm__cap { min-height: 4.2em; font-size: 17px; }
  .dm-win, .dm-win.is-board { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) 172px; height: clamp(560px, calc(100svh - 196px), 680px); padding: 6px; gap: 6px; }
  .dm-rail { display: none; }
  .dm-comp__clip { display: none; }
  .dm-sugg { margin-inline-start: 8px; max-width: calc(100% - 16px); }
  .dm-chat__who { padding-inline-end: 0; }
  .dm-view { display: none; }
  .is-lead .dm-view { display: block; position: static; align-self: center; margin-top: 4px; }
  .dm-win small, .dm-f dt, .dm-f dt em, .dm-card .draft-tag, .dm-stage, .dm-your, .dm-sys__h, .dm-view { font-size: 13px; }
  .dm-go { min-height: 44px; }
  .dm-tabs { padding: 8px 6px 6px; overflow: hidden; }
  .dm-syscol__head { display: none; }
  .dm-audit { display: none; }
  .dm-sys { padding: 6px; }
  .dm-rec { min-height: 48px; padding: 5px 8px; }
  .dm-tile img { height: 52px; }
  .dm-tile small { display: none; }
  .dm-steps { margin: 8px 0 6px !important; }
  .dm-steps span { display: none; }
  .dm-lead__h { display: none; }
  .dm-hist li { padding: 4px 2px; font-size: 13px; }
  .dm-board { display: none; }
  .dm-calc { margin-top: 0; padding: 4px 8px; }
  .dm-calc__r { padding: 2px 0; font-size: 13px; }
  .dm-calc .mono { display: none; }
  .dm__hint { display: none; }
  .dm__foot { margin-top: 4px; }
  .dm-card__foot { flex-wrap: wrap; }
  .dm-f dd { font-size: 13px; }
  .dm-switch { top: 54px; max-width: calc(100% - 20px); font-size: 13px; white-space: normal; text-align: center; }
  .dm-end { padding: 24px; }
  .dm-tabs span { padding: 3px 8px; }
}
