/* ============================================================
   Дополнения к терминальному интерфейсу: ссылки, формы,
   трекер, статусы, админка, печать.
   ============================================================ */

a {
  color: inherit;
  text-decoration: none;
}

/* Ссылки внутри окна по умолчанию зелёные. :where() не добавляет
   специфичности, поэтому цвета активных вкладок и чипов ниже
   перекрывают это правило, а не наоборот. */
.win-body a:where(:not(.btn, .srow, .tabs a, .subtabs a, .chat-inbox-item, .chat-tab)) {
  color: var(--grn-soft);
}

a.brand {
  display: inline-block;
  text-decoration: none;
}

/* --- вкладки-ссылки: те же правила, что у кнопок --- */
.tabs a {
  display: block;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  background: transparent;
  border: 0;
  border-bottom: 1px solid transparent;
  padding: 12px 18px;
  cursor: pointer;
  white-space: nowrap;
  transition: 0.18s;
}
.tabs a:hover {
  color: var(--grn-soft);
}
.tabs a.on {
  color: #05160e;
  font-weight: 700;
  background: var(--grn);
  border-bottom-color: var(--grn);
  box-shadow:
    0 0 12px rgba(0, 232, 154, 0.6),
    0 0 42px rgba(0, 232, 154, 0.24);
  border-radius: 4px 4px 0 0;
}
.tabs a .n {
  opacity: 0.55;
  margin-right: 7px;
}
.tabs a.on .n {
  opacity: 0.7;
}

/* --- курсор-подчёркивание (вместо прямоугольника) --- */
.cursor {
  display: inline-block;
  margin-left: 0.06em;
  color: var(--grn);
  font-weight: inherit;
  text-shadow: 0 0 10px rgba(0, 232, 154, 0.5);
  animation: blink 1.05s steps(1) infinite;
}

/* --- текстовое поле --- */
.inp-wrap textarea {
  flex: 1;
  min-height: 104px;
  background: transparent;
  border: 0;
  outline: none;
  color: #f0fff8;
  font: inherit;
  font-size: 13.5px;
  line-height: 1.6;
  padding: 12px 0;
  resize: vertical;
  caret-color: var(--grn);
}
.inp-wrap textarea::placeholder {
  color: rgba(190, 245, 225, 0.24);
}
.inp-wrap.align-top {
  align-items: flex-start;
}
.inp-wrap.align-top .ps {
  padding-top: 12px;
}

/* --- кнопки: мелочи --- */
.btn[disabled] {
  opacity: 0.55;
  cursor: progress;
  transform: none;
  box-shadow: none;
}
.btn-sm {
  font-size: 10px;
  padding: 7px 11px;
  letter-spacing: 0.08em;
}
.btn-row {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
}
.btn-row .btn {
  width: auto;
}

/* --- информационные блоки --- */
.notice {
  border: 1px solid rgba(0, 232, 154, 0.24);
  border-left: 3px solid var(--grn);
  border-radius: 4px;
  background: rgba(0, 232, 154, 0.035);
  padding: 12px 14px;
  font-size: 12px;
  color: var(--dim);
  line-height: 1.6;
}
.notice b {
  color: var(--grn-soft);
  font-weight: 500;
}
.notice.warn {
  border-color: rgba(245, 193, 104, 0.4);
  border-left-color: var(--amber);
  background: rgba(245, 193, 104, 0.05);
}
.notice.warn b {
  color: var(--amber);
}
.notice.err {
  border-color: rgba(255, 78, 104, 0.4);
  border-left-color: var(--red);
  background: rgba(255, 78, 104, 0.05);
}
.notice.err b {
  color: var(--red);
}
.notice + .notice {
  margin-top: 10px;
}

/* --- статусы --- */
.status.cancelled {
  color: var(--red);
  border-color: rgba(255, 78, 104, 0.5);
  background: rgba(255, 78, 104, 0.07);
  box-shadow: none;
}
.status.review {
  color: var(--amber);
  border-color: rgba(245, 193, 104, 0.45);
  background: rgba(245, 193, 104, 0.06);
  box-shadow: none;
}
.status.done {
  color: #04150d;
  background: var(--grn);
  border-color: var(--grn);
}
.ts.cancel {
  color: var(--red);
  border-color: rgba(255, 78, 104, 0.36);
}

/* --- большой код заказа --- */
.code-big {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.code-big b {
  font-size: clamp(17px, 2.2vw, 22px);
  letter-spacing: 0.08em;
  color: var(--grn);
  text-shadow: 0 0 12px rgba(0, 232, 154, 0.45);
  font-weight: 700;
}
.copy {
  font: inherit;
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  background: transparent;
  border: 1px solid rgba(0, 232, 154, 0.26);
  border-radius: 3px;
  padding: 4px 8px;
  cursor: pointer;
  transition: 0.16s;
}
.copy:hover {
  color: var(--grn);
  border-color: var(--grn);
}

/* --- поиск заказа --- */
.lookup {
  max-width: 520px;
}
.lookup .inp-wrap {
  margin-top: 14px;
}
.lookup input.neon {
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.lookup .hint-row {
  margin-top: 14px;
  font-size: 11px;
  color: var(--dim2);
}

/* --- админка --- */
.admin-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.admin-stats {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.admin-stats b {
  color: var(--grn);
  font-weight: 500;
}
.admin-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ocard {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.018);
  padding: 14px 16px;
}
.ocard-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.ocard-code {
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--grn);
}
.ocard-code span {
  color: var(--dim2);
  font-size: 10px;
  letter-spacing: 0.1em;
  margin-left: 10px;
}
.ocard-title {
  margin-top: 6px;
  font-size: 13.5px;
  color: #e4fbf0;
}
.ocard-sub {
  margin-top: 4px;
  font-size: 11px;
  color: var(--dim2);
}
.ocard-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.ocard-foot .sp {
  flex: 1;
}
.spec-ai {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.spec-wait {
  margin: 10px 0 0;
  padding: 8px 10px;
  font-size: 11px;
  line-height: 1.5;
  color: var(--grn-soft);
  border: 1px dashed rgba(0, 232, 154, 0.28);
  border-radius: 3px;
}
.select {
  font: inherit;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--grn-soft);
  background: rgba(4, 12, 8, 0.9);
  border: 1px solid rgba(0, 232, 154, 0.3);
  border-radius: 3px;
  padding: 6px 8px;
  cursor: pointer;
}
.select:focus {
  outline: none;
  border-color: var(--grn);
}
.empty {
  padding: 34px 0;
  text-align: center;
  color: var(--dim2);
  font-size: 12px;
}

/* --- трекер: компактные детали --- */
.tzrow .v .lnk {
  color: var(--grn-soft);
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: start;
}
.hr {
  height: 1px;
  border: 0;
  border-top: 1px dashed rgba(0, 232, 154, 0.14);
  margin: 18px 0;
}
.small {
  font-size: 10.5px;
  color: var(--dim2);
  line-height: 1.6;
}
.mono-break {
  word-break: break-word;
}

/* --- печать ТЗ --- */
@media print {
  body {
    background: #fff !important;
    color: #111 !important;
  }
  body::before,
  .crt,
  .boot,
  .top,
  .tabs,
  .win-foot,
  .win-top,
  .actions,
  .noprint {
    display: none !important;
  }
  .wrap {
    padding: 0 !important;
    max-width: none !important;
  }
  .win,
  .panel,
  .preview {
    background: #fff !important;
    border-color: #ccc !important;
    box-shadow: none !important;
    animation: none !important;
  }
  .win::after {
    display: none !important;
  }
  .win-body {
    padding: 0 !important;
  }
  .code,
  .code b,
  .otitle,
  .price-big,
  .tzrow .v,
  .meta b,
  .status,
  .ts {
    color: #111 !important;
    text-shadow: none !important;
  }
  .tzrow .k,
  .meta,
  .price-sub {
    color: #555 !important;
  }
  .ts.now {
    background: #eee !important;
    color: #111 !important;
  }
  .order-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 900px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .ocode-foot {
    flex-wrap: wrap;
  }
}

/* ================= DAY THEME ================= */
body.day a.brand {
  color: #0b241a;
}
body.day .tabs a {
  color: var(--dim2);
}
body.day .tabs a:hover {
  color: #00795a;
}
body.day .tabs a.on {
  background: #00795a;
  color: #fff;
  box-shadow: none;
}
body.day .win-body a:where(:not(.btn, .srow, .tabs a, .subtabs a, .chat-inbox-item, .chat-tab)) {
  color: #006b4f;
}
body.day .cursor {
  color: #00795a;
}
body.day .inp-wrap textarea {
  color: #0b241a;
}
body.day .inp-wrap textarea::placeholder {
  color: #93aa9d;
}
body.day .notice {
  background: #f4faf6;
  border-color: rgba(0, 110, 80, 0.2);
  border-left-color: #00795a;
  color: #3a5648;
}
body.day .notice b {
  color: #006b4f;
}
body.day .notice.warn {
  background: #fdf6e7;
  border-color: rgba(138, 97, 0, 0.3);
  border-left-color: #8a6100;
}
body.day .notice.warn b {
  color: #8a6100;
}
body.day .notice.err {
  background: #fdedf0;
  border-color: rgba(196, 35, 60, 0.3);
  border-left-color: #c4233c;
}
body.day .notice.err b {
  color: #c4233c;
}
body.day .status.cancelled {
  color: #c4233c;
  border-color: rgba(196, 35, 60, 0.4);
  background: rgba(196, 35, 60, 0.06);
}
body.day .status.review {
  color: #8a6100;
  border-color: rgba(138, 97, 0, 0.35);
  background: rgba(138, 97, 0, 0.06);
}
body.day .status.done {
  color: #fff;
  background: #00795a;
  border-color: #00795a;
}
body.day .ts.cancel {
  color: #c4233c;
  border-color: rgba(196, 35, 60, 0.3);
}
body.day .code-big b {
  color: #00795a;
}
body.day .copy {
  color: #5c7668;
  border-color: rgba(0, 110, 80, 0.26);
}
body.day .copy:hover {
  color: #00795a;
  border-color: #00795a;
}
body.day .lookup .hint-row {
  color: var(--dim2);
}
body.day .admin-stats {
  color: var(--dim2);
}
body.day .admin-stats b {
  color: #00795a;
}
body.day .ocard {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .ocard-code {
  color: #00795a;
}
body.day .ocard-code span {
  color: var(--dim2);
}
body.day .ocard-title {
  color: #132b20;
}
body.day .ocard-foot {
  border-top-color: rgba(0, 110, 80, 0.12);
}
body.day .select {
  color: #006b4f;
  background: #fff;
  border-color: rgba(0, 110, 80, 0.28);
}
body.day .select:focus {
  border-color: #00795a;
}
body.day .hr {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .small {
  color: var(--dim2);
}

/* ================= AUTH / ACCOUNT ================= */
.whoami {
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: var(--grn-soft);
  border: 1px solid rgba(0, 232, 154, 0.26);
  border-radius: 3px;
  padding: 4px 9px;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: 0.16s;
}
.whoami:hover {
  color: var(--grn);
  border-color: var(--grn);
}
/* «выйти» — та же компактная кнопка, но это <button>, а не ссылка */
button.whoami {
  font-family: inherit;
  background: transparent;
  cursor: pointer;
}
button.whoami[disabled] {
  opacity: 0.55;
  cursor: progress;
}

/* --- кнопка телеграм-канала в шапке --- */
.tg-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: var(--grn-soft);
  border: 1px solid rgba(0, 232, 154, 0.26);
  border-radius: 3px;
  padding: 4px 9px;
  white-space: nowrap;
  transition: 0.16s;
}
.tg-link svg {
  display: block;
  flex: none;
}
.tg-link:hover {
  color: var(--grn);
  border-color: var(--grn);
}
body.day .tg-link {
  color: #00795a;
  border-color: rgba(0, 107, 79, 0.24);
}
body.day .tg-link:hover {
  color: #006b4f;
  border-color: #00795a;
}
.auth-form {
  max-width: 520px;
}
.auth-form .field {
  margin-top: 16px;
}
.auth-done {
  max-width: 560px;
}
.check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 16px;
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--dim);
  cursor: pointer;
}
.check input {
  appearance: none;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin-top: 1px;
  border: 1px solid rgba(0, 232, 154, 0.45);
  border-radius: 3px;
  background: transparent;
  position: relative;
  cursor: pointer;
}
.check input:checked {
  background: var(--grn);
  border-color: var(--grn);
}
.check input:checked::after {
  content: "✓";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #04150d;
  font-size: 11px;
}
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.turnstile {
  margin-top: 16px;
}

/* ================= OFFER ================= */
.legal {
  max-width: 760px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.legal section {
  border-left: 1px solid rgba(0, 232, 154, 0.22);
  padding-left: 14px;
}
.legal h3 {
  margin: 0 0 7px;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn);
}
.legal p,
.legal li {
  margin: 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--dim);
}
.legal ul {
  margin: 0;
  padding-left: 18px;
}
.legal li + li {
  margin-top: 6px;
}

/* ================= PAYMENT ================= */
.pay-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.14);
}
.pay-total span {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.pay-total b {
  font-size: clamp(17px, 2.2vw, 20px);
  color: var(--grn);
  font-weight: 700;
}
.pay-bar {
  height: 6px;
  background: rgba(0, 232, 154, 0.1);
  border-radius: 3px;
  overflow: hidden;
  margin: 10px 0 4px;
}
.pay-bar .fill {
  display: block;
  height: 100%;
  background: var(--grn);
  box-shadow: 0 0 10px rgba(0, 232, 154, 0.45);
  transition: width 0.4s;
}
.pay-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 11px 0;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.pay-row:first-of-type {
  border-top: 0;
}
.pay-mark {
  color: var(--dim2);
  font-size: 12px;
}
.pay-row.done .pay-mark {
  color: var(--grn);
}
.pay-main {
  flex: 1;
  min-width: 0;
}
.pay-title {
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e4fbf0;
}
.pay-amount {
  text-align: right;
  white-space: nowrap;
}
.pay-amount b {
  display: block;
  color: var(--grn-soft);
  font-weight: 600;
}
.pay-details {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 4px;
  background: rgba(0, 232, 154, 0.03);
  font-size: 11px;
  color: var(--dim);
  line-height: 1.7;
}
.pay-label {
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
  margin-bottom: 6px;
}
.pay-details .copy {
  margin-top: 8px;
}
.crypto-rate {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  align-items: baseline;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px dashed rgba(0, 232, 154, 0.28);
  border-radius: 4px;
  background: rgba(0, 232, 154, 0.05);
}
.crypto-rate > div {
  display: flex;
  align-items: baseline;
  gap: 7px;
}
.crypto-rate span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.crypto-rate b {
  color: var(--grn-soft);
  font-weight: 600;
}
.crypto-rate-at {
  width: 100%;
  font-size: 10px;
  color: var(--dim2);
}
body.day .crypto-rate {
  border-color: rgba(0, 110, 80, 0.22);
  background: rgba(0, 110, 80, 0.04);
}
body.day .crypto-rate b {
  color: #0f6b4e;
}
.delivery {
  margin: 12px 0 10px;
  padding: 12px;
  border: 1px dashed rgba(0, 232, 154, 0.24);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.18);
  font: inherit;
  font-size: 11.5px;
  line-height: 1.6;
  color: #dff8ee;
  white-space: pre-wrap;
}

/* ================= ADMIN MONEY ================= */
.admin-money {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.mini-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.mini-field span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.mini-field input {
  width: 124px;
  font: inherit;
  font-size: 11px;
  color: var(--grn-soft);
  background: rgba(4, 12, 8, 0.9);
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 3px;
  padding: 6px 8px;
}
.mini-field input:focus {
  outline: none;
  border-color: var(--grn);
}
.admin-split {
  font-size: 10px;
  color: var(--dim2);
}
.admin-split b {
  color: var(--grn-soft);
  font-weight: 500;
}
.admin-paid {
  margin-top: 10px;
  font-size: 10.5px;
  color: var(--dim2);
}
.admin-paid b {
  color: var(--grn-soft);
  font-weight: 500;
}
.admin-delivery {
  margin-top: 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  padding-top: 10px;
}
.admin-delivery summary {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  cursor: pointer;
}
.admin-delivery textarea {
  width: 100%;
  margin: 10px 0 8px;
  font: inherit;
  font-size: 11.5px;
  line-height: 1.6;
  color: #e4fbf0;
  background: rgba(4, 12, 8, 0.6);
  border: 1px solid rgba(0, 232, 154, 0.22);
  border-radius: 4px;
  padding: 10px;
  resize: vertical;
}
.ocard.muted {
  opacity: 0.72;
}
.status.awaiting_deposit,
.status.awaiting_final,
.status.awaiting_review {
  color: var(--amber);
  border-color: rgba(245, 193, 104, 0.45);
  background: rgba(245, 193, 104, 0.06);
  box-shadow: none;
}

/* ================= DAY THEME: new blocks ================= */
body.day .whoami {
  color: #006b4f;
  border-color: rgba(0, 110, 80, 0.3);
}
body.day .whoami:hover {
  color: #00795a;
  border-color: #00795a;
}
body.day .check {
  color: #3a5648;
}
body.day .check input {
  border-color: rgba(0, 110, 80, 0.45);
}
body.day .check input:checked {
  background: #00795a;
  border-color: #00795a;
}
body.day .legal section {
  border-left-color: rgba(0, 110, 80, 0.2);
}
body.day .legal h3 {
  color: #00795a;
}
body.day .legal p,
body.day .legal li {
  color: #3a5648;
}
body.day .pay-total {
  border-bottom-color: rgba(0, 110, 80, 0.14);
}
body.day .pay-total b {
  color: #00795a;
}
body.day .pay-bar {
  background: rgba(0, 110, 80, 0.12);
}
body.day .pay-bar .fill {
  background: #00795a;
  box-shadow: none;
}
body.day .pay-row {
  border-top-color: rgba(0, 110, 80, 0.12);
}
body.day .pay-mark {
  color: #93aa9d;
}
body.day .pay-row.done .pay-mark {
  color: #00795a;
}
body.day .pay-title {
  color: #132b20;
}
body.day .pay-amount b {
  color: #006b4f;
}
body.day .pay-details {
  background: #f4faf6;
  border-color: rgba(0, 110, 80, 0.18);
  color: #3a5648;
}
body.day .delivery {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.2);
  color: #132b20;
}
body.day .mini-field input {
  background: #fff;
  color: #006b4f;
  border-color: rgba(0, 110, 80, 0.28);
}
body.day .admin-split b,
body.day .admin-paid b {
  color: #006b4f;
}
body.day .admin-delivery {
  border-top-color: rgba(0, 110, 80, 0.12);
}
body.day .admin-delivery textarea {
  background: #fff;
  color: #132b20;
  border-color: rgba(0, 110, 80, 0.22);
}
body.day .status.awaiting_deposit,
body.day .status.awaiting_final,
body.day .status.awaiting_review {
  color: #8a6100;
  border-color: rgba(138, 97, 0, 0.35);
  background: rgba(138, 97, 0, 0.06);
}

@media (max-width: 640px) {
  .pay-row {
    flex-wrap: wrap;
  }
  .pay-amount {
    text-align: left;
    width: 100%;
    padding-left: 24px;
  }
  .admin-money {
    align-items: stretch;
  }
  .mini-field input {
    width: 100%;
  }
}
.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  align-items: center;
  justify-content: center;
  margin-top: 16px;
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--dim2);
}
.legal-links a {
  color: var(--dim2);
  border-bottom: 1px dotted rgba(169, 247, 212, 0.22);
  transition: 0.16s;
}
.legal-links a:hover {
  color: var(--grn-soft);
  border-bottom-color: var(--grn);
}
body.day .legal-links,
body.day .legal-links a {
  color: #5f7a6d;
}
body.day .legal-links a:hover {
  color: #006b4f;
}

/* --- партнёрский баннер Timeweb --- */
.partner-strip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  max-width: 728px;
  margin: 22px auto 0;
  padding: 0 4px;
}
.partner-label {
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
body.day .partner-label {
  color: #5f7a6d;
}
.partner-banner {
  display: block;
  line-height: 0;
  border: 1px solid rgba(169, 247, 212, 0.12);
  border-radius: 4px;
  overflow: hidden;
  transition: 0.16s;
}
.partner-banner:hover {
  border-color: rgba(169, 247, 212, 0.32);
}
body.day .partner-banner {
  border-color: rgba(0, 107, 79, 0.16);
}
.partner-banner img {
  display: block;
  width: 100%;
  max-width: 728px;
  height: auto;
}
.partner-section {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(169, 247, 212, 0.08);
}
.partner-section .partner-strip {
  align-items: flex-start;
  margin: 0;
  padding: 0;
}
body.day .partner-section {
  border-top-color: rgba(0, 107, 79, 0.12);
}

/* ================= ЛЕНДИНГ ================= */
.land-hero {
  padding: 10px 0 4px;
}
.lead {
  max-width: 760px;
  margin-top: 14px;
  color: var(--dim);
  font-size: 14px;
  line-height: 1.72;
}
.land-section {
  margin-top: 34px;
  padding-top: 22px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.land-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.land-services {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.land-service {
  display: flex;
  flex-direction: column;
  gap: 5px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.018);
  padding: 14px 15px;
  transition: 0.18s;
}
.land-service:hover {
  border-color: var(--line2);
  background: rgba(0, 232, 154, 0.05);
  transform: translateY(-2px);
}
.land-service-top {
  display: flex;
  align-items: baseline;
  gap: 9px;
}
.land-service-top .idx {
  color: var(--grn);
  font-size: 10px;
  opacity: 0.7;
}
.land-service-name {
  color: #eafff6;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.land-service-desc {
  color: var(--dim2);
  font-size: 11px;
}
.land-service-meta {
  color: var(--grn-soft);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  margin-top: 4px;
}
.land-service-go {
  color: var(--dim2);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 6px;
  transition: 0.16s;
}
.land-service:hover .land-service-go {
  color: var(--grn);
}

/* ---------- страницы услуг ---------- */
.prompt a {
  color: var(--dim2);
  border-bottom: 1px dotted rgba(0, 232, 154, 0.24);
  transition: 0.16s;
}
.prompt a:hover {
  color: var(--grn);
  border-bottom-color: var(--grn);
}
.seo-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.seo-fact {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 142px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 13px;
  background: rgba(0, 232, 154, 0.018);
}
.seo-fact span {
  color: var(--dim2);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.seo-fact b {
  color: var(--grn-soft);
  font-size: 13px;
  font-weight: 500;
}
.seo-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
  max-width: 860px;
}
.seo-list li {
  position: relative;
  padding-left: 26px;
  color: var(--dim);
  font-size: 12.5px;
  line-height: 1.65;
}
.seo-list li::before {
  content: "[ok]";
  position: absolute;
  left: 0;
  top: 1px;
  color: var(--grn);
  font-size: 9.5px;
  letter-spacing: 0.04em;
  opacity: 0.8;
}
.seo-list-cols {
  grid-template-columns: 1fr 1fr;
  max-width: none;
  gap: 8px 26px;
}
.seo-faq {
  display: grid;
  gap: 8px;
  max-width: 860px;
}
.seo-faq details {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.014);
  padding: 0 15px;
  transition: 0.16s;
}
.seo-faq details:hover {
  border-color: var(--line2);
}
.seo-faq summary {
  cursor: pointer;
  padding: 12px 0;
  color: #eafff6;
  font-size: 12.5px;
  line-height: 1.5;
  list-style: none;
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.seo-faq summary::-webkit-details-marker {
  display: none;
}
.seo-faq summary::before {
  content: "+";
  color: var(--grn);
  font-size: 13px;
  width: 10px;
  flex: none;
}
.seo-faq details[open] summary::before {
  content: "\2212";
}
.seo-faq details[open] summary {
  color: var(--grn-soft);
}
.seo-faq p {
  margin: 0 0 14px;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.7;
}

.land-steps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.land-step {
  display: flex;
  gap: 13px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px 15px;
  background: rgba(0, 232, 154, 0.014);
}
.land-step-n {
  color: var(--grn);
  font-size: 11px;
  letter-spacing: 0.1em;
}
.land-step-title {
  color: #eafff6;
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.land-step p {
  margin-top: 5px;
  color: var(--dim2);
  font-size: 11.5px;
  line-height: 1.6;
}

.land-safety {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 22px;
  align-items: center;
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.03);
  padding: 20px;
}
.land-safety p {
  margin-top: 10px;
  color: var(--dim);
  font-size: 12.5px;
  line-height: 1.65;
}
.land-safety-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.land-pay {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.land-pay span {
  color: var(--dim2);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.land-pay b {
  color: var(--grn);
  font-size: 24px;
  font-weight: 500;
  text-shadow: 0 0 14px rgba(0, 232, 154, 0.35);
}
.land-pay-line {
  width: 46px;
  height: 1px;
  background: repeating-linear-gradient(
    to right,
    rgba(0, 232, 154, 0.6) 0 4px,
    transparent 4px 8px
  );
}

.land-works {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.land-work {
  display: flex;
  flex-direction: column;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px 15px;
  background: rgba(0, 232, 154, 0.014);
  transition: 0.18s;
}
.land-work:hover {
  border-color: var(--line2);
  background: rgba(0, 232, 154, 0.05);
}
.land-work-service {
  color: var(--grn);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.land-work-title {
  color: #eafff6;
  font-size: 12.5px;
  line-height: 1.5;
}
.land-work-result {
  color: var(--dim2);
  font-size: 11px;
  line-height: 1.55;
}
.land-work-meta {
  margin-top: auto;
  color: var(--grn-soft);
  font-size: 10.5px;
}

.land-reviews {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.land-review {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 15px;
  background: rgba(0, 232, 154, 0.014);
}
.land-review p {
  margin: 9px 0 10px;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.65;
}
.land-review-empty {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  border: 1px dashed rgba(0, 232, 154, 0.24);
  border-radius: 6px;
  padding: 16px;
  color: var(--dim2);
  font-size: 12px;
}
.land-final {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 34px;
  padding: 22px;
  border: 1px solid rgba(0, 232, 154, 0.3);
  border-radius: 8px;
  background:
    radial-gradient(60% 120% at 0% 0%, rgba(0, 232, 154, 0.08), transparent 70%),
    rgba(0, 232, 154, 0.02);
}
.land-final h2 {
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #f0fff8;
}
.land-final p {
  margin-top: 6px;
  color: var(--dim2);
  font-size: 12px;
}

/* ================= РАБОТЫ ================= */
.works-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.work {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0, 232, 154, 0.014);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.work-top {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.work-index {
  color: var(--grn);
  opacity: 0.75;
}
.work-service {
  color: var(--grn-soft);
}
.work-price {
  margin-left: auto;
  color: var(--dim2);
}
.work-title {
  font-size: 14.5px;
  font-weight: 500;
  color: #eafff6;
  line-height: 1.45;
}
.work-client {
  color: var(--dim2);
  font-size: 10.5px;
  letter-spacing: 0.04em;
}
.work-block {
  border-left: 2px solid rgba(0, 232, 154, 0.18);
  padding-left: 10px;
}
.work-label {
  display: block;
  color: var(--grn);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.work-block p {
  color: var(--dim);
  font-size: 11.5px;
  line-height: 1.6;
}
.work-block p.work-result {
  color: var(--grn-soft);
}
.work-foot {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.work-stack {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.work-stack span {
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 3px;
  padding: 2px 6px;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--dim2);
}
.work-days {
  color: var(--dim2);
  font-size: 10px;
  letter-spacing: 0.06em;
}
.work-link {
  color: var(--grn);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  text-decoration: none;
}
.work-link:hover {
  text-decoration: underline;
}
.work-review {
  border: 1px solid rgba(0, 232, 154, 0.16);
  border-radius: 5px;
  background: rgba(0, 232, 154, 0.03);
  padding: 12px;
}
.work-review-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}
.work-review p {
  color: var(--dim);
  font-size: 11.5px;
  line-height: 1.6;
}
.work-review-author {
  margin-top: 8px;
  color: var(--grn-soft);
  font-size: 10px;
  letter-spacing: 0.04em;
}

/* ================= ОТЗЫВЫ ================= */
.reviews-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}
.reviews-score {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}
.reviews-score b {
  color: var(--grn);
  font-size: 34px;
  font-weight: 500;
  line-height: 1;
  text-shadow: 0 0 16px rgba(0, 232, 154, 0.3);
}
.review-stars {
  color: var(--grn);
  font-size: 13px;
  letter-spacing: 0.14em;
}
.review-stars span {
  color: var(--dim2);
  opacity: 0.5;
}
.reviews-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.review-card {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0, 232, 154, 0.014);
  padding: 16px;
}
.review-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.review-name {
  color: #eafff6;
  font-size: 13px;
}
.review-service {
  color: var(--dim2);
  font-size: 10px;
  letter-spacing: 0.06em;
  margin-top: 2px;
}
.review-text {
  margin-top: 10px;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.68;
  white-space: pre-line;
}
.review-date {
  margin-top: 10px;
  color: var(--dim2);
  font-size: 9.5px;
  letter-spacing: 0.08em;
}
.review-foot {
  margin-top: 10px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.review-foot .review-date {
  margin-top: 0;
}
.review-work {
  color: var(--grn-soft);
  font-size: 10px;
  letter-spacing: 0.04em;
  text-decoration: none;
}
.review-work:hover {
  color: var(--grn);
  text-decoration: underline;
}
.reviews-empty {
  border: 1px dashed rgba(0, 232, 154, 0.24);
  border-radius: 8px;
  padding: 34px 22px;
  text-align: center;
}
.reviews-empty-mark {
  color: var(--grn);
  font-size: 20px;
  opacity: 0.6;
}
.reviews-empty h3 {
  margin: 10px 0 8px;
  font-size: 15px;
  font-weight: 500;
  color: #eafff6;
}
.reviews-empty p {
  max-width: 560px;
  margin: 0 auto 18px;
  color: var(--dim2);
  font-size: 12px;
  line-height: 1.65;
}
.review-form .ph,
.review-add .ph {
  margin-bottom: 10px;
}
.review-add-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 110px 140px;
  gap: 10px;
}
.review-add-check {
  justify-content: flex-end;
}
.check-inline {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--dim);
}
.check-inline input {
  accent-color: var(--grn);
}
.review-stars-input {
  display: flex;
  align-items: center;
  gap: 4px;
}
.review-stars-input button {
  background: transparent;
  border: 0;
  color: rgba(190, 245, 225, 0.24);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
  padding: 2px;
  transition: 0.15s;
}
.review-stars-input button.on {
  color: var(--grn);
  text-shadow: 0 0 10px rgba(0, 232, 154, 0.4);
}
.review-stars-input .small {
  margin-left: 6px;
}
.review-row .review-text {
  margin: 8px 0 0;
}

/* ================= ЧАТ ================= */
.chat {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  padding-bottom: 9px;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.14);
}
.chat-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--grn);
  text-transform: lowercase;
  letter-spacing: 0.04em;
  font-size: 10px;
}
.chat-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 300px;
  overflow-y: auto;
  padding: 12px 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.25) transparent;
}
.chat-list::-webkit-scrollbar {
  width: 6px;
}
.chat-list::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.22);
  border-radius: 3px;
}
.chat-empty {
  color: var(--dim2);
  font-size: 11.5px;
  line-height: 1.6;
  padding: 14px 0;
}
.chat-msg {
  max-width: 82%;
  align-self: flex-start;
}
.chat-msg.mine {
  align-self: flex-end;
  text-align: right;
}
.chat-meta {
  display: flex;
  gap: 8px;
  margin-bottom: 3px;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
}
.chat-msg.mine .chat-meta {
  justify-content: flex-end;
}
.chat-bubble {
  display: inline-block;
  text-align: left;
  border: 1px solid rgba(0, 232, 154, 0.16);
  background: rgba(0, 232, 154, 0.035);
  border-radius: 6px;
  padding: 8px 11px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--txt);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.chat-msg.mine .chat-bubble {
  border-color: rgba(0, 232, 154, 0.34);
  background: rgba(0, 232, 154, 0.1);
  color: #eafff6;
}
.chat-form {
  border-top: 1px dashed rgba(0, 232, 154, 0.14);
  padding-top: 10px;
}
.chat-form textarea {
  width: 100%;
  background: rgba(4, 12, 8, 0.6);
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 4px;
  color: #f0fff8;
  font: inherit;
  font-size: 12.5px;
  line-height: 1.55;
  padding: 9px 11px;
  resize: vertical;
  caret-color: var(--grn);
}
.chat-form textarea:focus {
  outline: none;
  border-color: rgba(0, 232, 154, 0.5);
}
.chat-form-foot {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.chat-error {
  margin-top: 8px;
  color: var(--red);
  font-size: 11px;
}
.chat-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  margin-left: 6px;
  border-radius: 8px;
  background: var(--grn);
  color: #04150d;
  font-size: 9px;
  font-weight: 700;
  line-height: 1;
}
.chat-open {
  display: inline-flex;
  align-items: center;
}
.chat-panel .chat-list {
  max-height: 340px;
}
.chat-dock {
  border: 1px solid rgba(0, 232, 154, 0.26);
  border-radius: 7px;
  background: rgba(6, 21, 14, 0.6);
  padding: 12px 14px 14px;
  margin-bottom: 18px;
}
.chat-dock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}
.chat-dock-title {
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn);
}
.chat-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  padding-bottom: 2px;
  border-bottom: 1px solid rgba(0, 232, 154, 0.16);
  scrollbar-width: thin;
}
.chat-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  max-width: 240px;
  padding: 7px 9px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 4px 4px 0 0;
  color: var(--dim2);
  font-size: 10.5px;
  cursor: pointer;
  user-select: none;
  transition: 0.15s;
}
.chat-tab:hover {
  color: var(--grn-soft);
  background: rgba(0, 232, 154, 0.04);
}
.chat-tab.on {
  color: #04150d;
  background: var(--grn);
}
.chat-tab-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chat-tab-code {
  /* Уникальный код заказа остаётся в DOM, но не отображается. */
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.chat-tab-x {
  border: 0;
  background: transparent;
  color: inherit;
  opacity: 0.5;
  font: inherit;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  padding: 0 1px;
}
.chat-tab-x:hover {
  opacity: 1;
}
.chat-tab.on .chat-badge {
  background: #04150d;
  color: var(--grn);
}
.chat-active-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 9px 0 7px;
  font-size: 10.5px;
  color: var(--dim2);
}
.chat-active-bar b {
  color: var(--grn);
  font-weight: 500;
}
.chat-dock .chat-list {
  max-height: 240px;
}
.chat-empty-dock {
  padding: 20px 0 6px;
  text-align: center;
}

.review-add textarea,
.mini-field textarea {
  width: 100%;
  background: rgba(4, 12, 8, 0.66);
  border: 1px solid rgba(0, 232, 154, 0.22);
  border-radius: 4px;
  color: #f0fff8;
  font: inherit;
  font-size: 12px;
  line-height: 1.55;
  padding: 8px 10px;
  resize: vertical;
  caret-color: var(--grn);
}
.review-add textarea:focus,
.mini-field textarea:focus {
  outline: none;
  border-color: rgba(0, 232, 154, 0.5);
}
body.day .review-add textarea,
body.day .mini-field textarea {
  background: #fff;
  color: #132b20;
  border-color: rgba(0, 110, 80, 0.24);
}

/* ================= DAY: новые блоки ================= */
body.day .lead,
body.day .land-step p,
body.day .land-work-result,
body.day .work-block p,
body.day .work-review p,
body.day .review-text,
body.day .chat-empty {
  color: #3a5648;
}
body.day .land-service,
body.day .land-step,
body.day .land-work,
body.day .land-review,
body.day .work,
body.day .work-review,
body.day .review-card,
body.day .chat-dock {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.18);
}
body.day .land-service:hover,
body.day .land-work:hover {
  background: #f0f8f3;
  border-color: rgba(0, 110, 80, 0.32);
}
body.day .land-service-name,
body.day .land-step-title,
body.day .land-work-title,
body.day .work-title,
body.day .review-name,
body.day .reviews-empty h3,
body.day .land-final h2 {
  color: #132b20;
}
body.day .land-service-meta,
body.day .land-work-meta,
body.day .work-block p.work-result,
body.day .land-pay b,
body.day .reviews-score b {
  color: #006b4f;
  text-shadow: none;
}
body.day .land-services .idx,
body.day .land-step-n,
body.day .work-index,
body.day .work-label,
body.day .work-review-author,
body.day .work-link,
body.day .review-work,
body.day .land-work-service,
body.day .chat-dock-title,
body.day .chat-live {
  color: #00795a;
}
body.day .seo-fact,
body.day .seo-faq details {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.18);
}
body.day .seo-fact span,
body.day .seo-list li,
body.day .seo-faq p {
  color: #3a5648;
}
body.day .seo-fact b,
body.day .seo-faq details[open] summary {
  color: #006b4f;
  text-shadow: none;
}
body.day .seo-faq summary {
  color: #132b20;
}
body.day .prompt a {
  color: #5c7668;
}
body.day .land-safety {
  background: #f4faf6;
  border-color: rgba(0, 110, 80, 0.22);
}
body.day .land-safety p,
body.day .land-final p,
body.day .reviews-empty p,
body.day .land-review-empty,
body.day .reviews-score .small {
  color: #3a5648;
}
body.day .land-review p {
  color: #2c463a;
}
body.day .land-review-empty,
body.day .reviews-empty {
  border-color: rgba(0, 110, 80, 0.26);
}
body.day .land-final {
  background: #f4faf6;
  border-color: rgba(0, 110, 80, 0.28);
}
body.day .review-stars,
body.day .review-stars-input button.on {
  color: #00795a;
  text-shadow: none;
}
body.day .review-stars span,
body.day .review-stars-input button {
  color: #b8c9bf;
}
body.day .work-stack span {
  border-color: rgba(0, 110, 80, 0.22);
  color: #5f7a6d;
}
body.day .chat-bubble {
  background: #fff;
  border-color: rgba(0, 110, 80, 0.2);
  color: #132b20;
}
body.day .chat-msg.mine .chat-bubble {
  background: #e8f7ee;
  border-color: rgba(0, 110, 80, 0.32);
  color: #0d2a1c;
}
body.day .chat-form textarea {
  background: #fff;
  color: #132b20;
  border-color: rgba(0, 110, 80, 0.24);
}
body.day .chat-tab {
  color: #5f7a6d;
}
body.day .chat-tab.on {
  color: #fff;
  background: #00795a;
}
body.day .chat-tab.on .chat-badge {
  background: #fff;
  color: #006b4f;
}
body.day .chat-badge {
  background: #00795a;
  color: #fff;
}
body.day .chat-head,
body.day .chat-meta,
body.day .chat-active-bar {
  color: #5f7a6d;
}

@media (max-width: 900px) {
  .land-services,
  .land-works {
    grid-template-columns: 1fr 1fr;
  }
  .review-add-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 720px) {
  .land-services,
  .land-works,
  .land-steps,
  .land-reviews,
  .works-grid,
  .reviews-grid {
    grid-template-columns: 1fr;
  }
  .seo-list-cols {
    grid-template-columns: 1fr;
  }
  .seo-fact {
    flex: 1 1 auto;
    min-width: 0;
  }
  .land-safety {
    grid-template-columns: 1fr;
  }
  .land-safety-right {
    justify-content: flex-start;
  }
  .reviews-score {
    align-items: flex-start;
  }
  .chat-tab {
    max-width: 200px;
  }
}

.no-boot .boot{display:none!important}

/* ================= LOADING SKELETON ================= */
.skeleton{display:flex;flex-direction:column;gap:10px;margin-top:18px}
.sk{
  height:12px;border-radius:3px;
  background:linear-gradient(90deg,rgba(0,232,154,.08),rgba(0,232,154,.2),rgba(0,232,154,.08));
  background-size:200% 100%;
  animation:skShimmer 1.4s linear infinite;
}
.sk.w40{width:40%}
.sk.w60{width:60%}
.sk.w80{width:80%}
.sk.box{height:120px}
body.day .sk{
  background:linear-gradient(90deg,rgba(0,110,80,.08),rgba(0,110,80,.18),rgba(0,110,80,.08));
  background-size:200% 100%;
}
@keyframes skShimmer{
  0%{background-position:200% 0}
  100%{background-position:-200% 0}
}
@media (prefers-reduced-motion: reduce){
  .sk{animation:none}
}

/* ================= AI SPEC ================= */
.spec-build {
  margin-top: 18px;
}
.spec-empty {
  border: 1px dashed rgba(0, 232, 154, 0.22);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.02);
  padding: 16px;
}
.spec-empty p {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--dim);
}
.spec-empty p + p {
  margin-top: 8px;
}
.spec-loading {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.025);
  padding: 18px;
  font-size: 12.5px;
  color: var(--dim);
  letter-spacing: 0.04em;
}
.spec-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--grn);
  box-shadow: 0 0 10px rgba(0, 232, 154, 0.7);
  animation: specPulse 1.1s ease-in-out infinite;
}
@keyframes specPulse {
  0%, 100% { opacity: 0.35; transform: scale(0.85); }
  50% { opacity: 1; transform: scale(1); }
}
.spec-preview {
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.025);
  padding: 16px;
}
.spec-tools {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.spec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.spec-head h3 {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #e4fbf0;
}
.spec-model {
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 3px;
  padding: 3px 7px;
}
.spec-summary {
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--dim);
}
.spec-blocks {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}
.spec-block {
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  padding-top: 10px;
}
.spec-block:first-child {
  border-top: 0;
  padding-top: 0;
}
.spec-label {
  display: block;
  margin-bottom: 6px;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(0, 232, 154, 0.55);
}
.spec-block ul {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding-left: 16px;
}
.spec-block li,
.spec-block p {
  font-size: 12px;
  line-height: 1.6;
  color: var(--dim);
}
.spec-block li b {
  color: #dffcef;
  font-weight: 500;
}
.spec-questions {
  border: 1px solid rgba(245, 193, 104, 0.28);
  border-radius: 4px;
  background: rgba(245, 193, 104, 0.04);
  padding: 10px;
}
.spec-questions .spec-label {
  color: var(--amber);
}

/* --- ТЗ в заказе: коротко, один экран --- */
.spec-view .spec-blocks {
  gap: 8px;
  margin-top: 8px;
}
.spec-view .spec-block {
  padding-top: 8px;
}
.spec-view .spec-summary {
  margin-top: 6px;
}
.spec-view .spec-label {
  margin-bottom: 4px;
}
.spec-view .spec-timeline-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.spec-view .spec-timeline-row .spec-label {
  margin-bottom: 0;
}
.spec-view .spec-timeline-row p {
  margin: 0;
  text-align: right;
  color: #dffcef;
}
.spec-more {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.spec-more > summary {
  list-style: none;
  cursor: pointer;
  padding: 3px 0;
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.spec-more > summary::-webkit-details-marker {
  display: none;
}
.spec-more > summary::after {
  content: "+";
  float: right;
  color: var(--grn);
  font-size: 12px;
  line-height: 1;
}
.spec-more[open] > summary::after {
  content: "−";
}
.spec-more .spec-blocks {
  margin-top: 8px;
}
body.day .spec-more {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .spec-view .spec-timeline-row p {
  color: #0B2B1E;
}

/* --- заявка: краткая суть вместо таблицы строк --- */
.brief {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.brief-goal {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.65;
  color: #dffcef;
}
.brief-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding-left: 16px;
}
.brief-list li {
  font-size: 12px;
  line-height: 1.55;
  color: var(--dim);
}
.brief-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  padding-top: 10px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  font-size: 10.5px;
  line-height: 1.6;
  color: var(--dim2);
}
.brief-meta b {
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(0, 232, 154, 0.55);
}
.brief-note {
  margin: 0;
  padding: 8px 10px;
  font-size: 11px;
  line-height: 1.6;
  color: var(--dim2);
  border: 1px dashed rgba(0, 232, 154, 0.14);
  border-radius: 3px;
}
.spec-ask {
  border: 1px solid rgba(245, 193, 104, 0.3);
  border-radius: 6px;
  background: rgba(245, 193, 104, 0.045);
  padding: 14px;
}
.spec-ask-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.spec-ask-head .spec-label {
  color: var(--amber);
}
.spec-ask-count {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--amber);
  opacity: 0.8;
}
.spec-ask-hint {
  margin-top: 8px;
  line-height: 1.6;
  color: var(--dim2);
}
.spec-ask-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}
.spec-ask-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  cursor: text;
}
.spec-ask-q {
  font-size: 12.5px;
  line-height: 1.55;
  color: #dffcef;
}
.spec-ask-row textarea {
  width: 100%;
  min-height: 52px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.22);
  color: #f0fff8;
  font: inherit;
  font-size: 12.5px;
  line-height: 1.5;
  padding: 8px 10px;
  outline: none;
  caret-color: var(--grn);
}
.spec-ask-row textarea:focus {
  border-color: rgba(245, 193, 104, 0.55);
  box-shadow: 0 0 0 2px rgba(245, 193, 104, 0.08);
}
.spec-ask-row textarea::placeholder {
  color: var(--dim2);
}
.spec-ask-actions {
  margin-top: 14px;
}
.spec-assumptions {
  border: 1px solid rgba(245, 193, 104, 0.24);
  border-radius: 4px;
  background: rgba(245, 193, 104, 0.03);
  padding: 10px;
}
.spec-assumptions .spec-label {
  color: var(--amber);
}
body.day .spec-ask {
  background: rgba(138, 97, 0, 0.05);
  border-color: rgba(138, 97, 0, 0.3);
}
body.day .spec-ask-q {
  color: #132b20;
}
body.day .spec-ask-row textarea {
  background: #fff;
  color: #132b20;
}
body.day .spec-assumptions {
  background: rgba(138, 97, 0, 0.04);
  border-color: rgba(138, 97, 0, 0.26);
}
.spec-view.compact .spec-head h3 {
  font-size: 13.5px;
}
.spec-view.compact .spec-summary,
.spec-view.compact .spec-block li,
.spec-view.compact .spec-block p {
  font-size: 11.5px;
}
.admin-spec {
  margin-top: 10px;
}

/* --- отдельная страница сметы --- */
.quote-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 0 24px;
  padding: 4px 0;
}
.quote-split {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.quote-split > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.quote-split span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.quote-split b {
  font-size: 13px;
  color: var(--grn-soft);
}
body.day .quote-split b {
  color: #0f6b4e;
}

body.day .spec-empty,
body.day .spec-preview,
body.day .spec-loading {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.18);
}
body.day .spec-head h3 {
  color: #0b241a;
}
body.day .spec-summary,
body.day .spec-block li,
body.day .spec-block p {
  color: #3a5648;
}
body.day .spec-block li b {
  color: #132b20;
}
body.day .spec-label {
  color: #00795a;
}
body.day .spec-model {
  border-color: rgba(0, 110, 80, 0.2);
}
body.day .spec-questions {
  background: rgba(138, 97, 0, 0.05);
  border-color: rgba(138, 97, 0, 0.28);
}
body.day .brief-goal {
  color: #132b20;
}
body.day .brief-list li {
  color: #3a5648;
}
body.day .brief-meta {
  color: #5c7466;
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .brief-note {
  color: #5c7466;
  border-color: rgba(0, 110, 80, 0.16);
}
.spec-loading .spec-wait {
  display: block;
  margin-top: 4px;
  font-size: 10.5px;
  letter-spacing: 0.02em;
  color: var(--dim2);
}
body.day .spec-loading .spec-wait {
  color: #6b8578;
}

/* ================= AI USAGE ================= */
.ai-panel {
  margin-bottom: 18px;
}
.ai-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.ai-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.02);
  padding: 12px;
}
.ai-stat > span {
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(0, 232, 154, 0.55);
}
.ai-stat > b {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #e4fbf0;
}
.ai-stat > small {
  font-size: 10.5px;
  line-height: 1.4;
  color: var(--dim2);
}
.ai-account {
  margin-top: 14px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  padding-top: 12px;
}
.ai-account-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ai-account-head > span:last-child {
  color: var(--grn-soft);
  letter-spacing: 0.06em;
}
.ai-account-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.ai-account-grid > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.ai-account-grid span {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ai-account-grid b {
  font-size: 14px;
  font-weight: 600;
  color: var(--grn-soft);
}
.ai-note {
  margin-top: 8px;
  max-width: 78ch;
  line-height: 1.55;
}
.ai-log {
  margin-top: 14px;
}
.ai-log summary {
  cursor: pointer;
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ai-log summary:hover {
  color: var(--grn-soft);
}
.ai-table {
  display: flex;
  flex-direction: column;
  margin-top: 10px;
}
.ai-row {
  display: grid;
  grid-template-columns: 1.2fr 1.2fr 0.7fr 0.8fr 1fr;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.1);
  font-size: 11.5px;
  color: var(--dim);
}
.ai-row-head {
  border-bottom: 1px solid var(--line);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ai-id {
  font-size: 10.5px;
  color: var(--dim2);
}

body.day .ai-stat {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .ai-stat > span {
  color: #00795a;
}
body.day .ai-stat > b {
  color: #0b241a;
}
body.day .ai-account-grid b {
  color: #0a6a4f;
}
body.day .ai-row {
  color: #3a5648;
  border-bottom-color: rgba(0, 110, 80, 0.1);
}

@media (max-width: 760px) {
  .ai-stats,
  .ai-account-grid {
    grid-template-columns: 1fr 1fr;
  }
  .ai-row {
    grid-template-columns: 1fr 1fr;
  }
  .ai-row .ai-id {
    display: none;
  }
}

/* ================= КАТАЛОГ ПО ГРУППАМ ================= */
.land-groups {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.land-group-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.land-group-head .idx {
  font-size: 10px;
  color: var(--grn);
  opacity: 0.7;
}
.land-group-head b {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn-soft);
}
.land-group-head small {
  font-size: 10.5px;
  color: var(--dim2);
}
.land-service-other {
  border-style: dashed;
  border-color: rgba(0, 232, 154, 0.28);
}
.land-service-other .land-service-name {
  color: var(--grn-soft);
}
.land-service-main {
  border-color: rgba(0, 232, 154, 0.4);
  background: rgba(0, 232, 154, 0.055);
}
.land-service-main .land-service-name {
  color: #eafff6;
}
.seo-parent-link {
  margin-top: 14px;
}
.seo-parent-link a {
  color: var(--grn-soft);
  border-bottom: 1px dotted rgba(0, 232, 154, 0.35);
}
.seo-parent-link a:hover {
  color: var(--grn);
  border-bottom-color: var(--grn);
}
body.day .land-service-main {
  background: #eef8f2;
  border-color: rgba(0, 120, 88, 0.3);
}
body.day .land-service-main .land-service-name,
body.day .seo-parent-link a {
  color: #00795a;
}

/* мастер: выбор продукта по группам */
.svc-picker {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 18px;
}
.svc-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(0, 232, 154, 0.55);
}
.svc-group-head small {
  font-size: 10px;
  letter-spacing: 0.02em;
  text-transform: none;
  color: var(--dim2);
}
.svc-group .opts {
  margin-top: 0;
}
.svc-product {
  margin-top: 14px;
}

body.day .land-group-head b {
  color: #00795a;
}
body.day .svc-group-head {
  color: #00795a;
}
body.day .svc-product .small {
  color: #5c7568;
}

@media (max-width: 900px) {
  .land-services {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   Админка: подвкладки, реестр, сводка, инбокс, настройки.
   ============================================================ */
.subtabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin: 0 0 20px;
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.2);
}
.subtabs a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 4px;
  padding: 7px 11px;
  transition: 0.18s;
}
.subtabs a:hover {
  color: var(--grn-soft);
  border-color: rgba(0, 232, 154, 0.45);
}
.subtabs a.on {
  color: #05160e;
  background: var(--grn);
  border-color: var(--grn);
  box-shadow: 0 0 16px -6px rgba(0, 232, 154, 0.8);
}
.subtabs a .n {
  opacity: 0.55;
}

.admin-filters {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.014);
}
.admin-filters .mini-field {
  margin: 0;
}

.admin-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  white-space: nowrap;
}
.admin-table th,
.admin-table td {
  text-align: left;
  padding: 9px 11px;
  border-bottom: 1px solid rgba(0, 232, 154, 0.12);
  vertical-align: top;
}
.admin-table th {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
  font-weight: 500;
  background: rgba(0, 232, 154, 0.03);
}
.admin-table tr:last-child td {
  border-bottom: 0;
}
.admin-table tr.late td {
  color: var(--red);
}
.admin-table tr.muted-row td {
  opacity: 0.55;
}

.admin-due {
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--dim2);
}
.admin-due.late {
  color: var(--red);
}

.summary-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 16px;
}
.summary-money {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.summary-money > div {
  border: 1px solid rgba(0, 232, 154, 0.14);
  border-radius: 5px;
  padding: 10px 12px;
}
.summary-label {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
  margin-bottom: 5px;
}
.summary-money b {
  font-size: 17px;
  color: var(--grn);
  font-weight: 600;
}
.summary-status {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.summary-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 11.5px;
  padding: 5px 0;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.1);
}
.summary-status-row b {
  color: var(--grn);
  font-weight: 600;
}

.chat-inbox {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}
.chat-inbox-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 620px;
  overflow-y: auto;
  padding-right: 4px;
}
.chat-inbox-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
  font: inherit;
  color: inherit;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: rgba(0, 232, 154, 0.014);
  padding: 9px 11px;
  cursor: pointer;
  transition: 0.16s;
}
.chat-inbox-item:hover {
  border-color: rgba(0, 232, 154, 0.4);
}
.chat-inbox-item.on {
  border-color: rgba(0, 232, 154, 0.65);
  background: rgba(0, 232, 154, 0.06);
}
.chat-inbox-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
}
.chat-inbox-code {
  font-size: 9.5px;
  letter-spacing: 0.1em;
  color: var(--dim2);
}
.chat-inbox-last {
  font-size: 11px;
  color: var(--dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-inbox-time {
  font-size: 9.5px;
  color: var(--dim2);
}
.chat-inbox-main {
  min-width: 0;
}

.chat-templates {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 8px;
}
.chat-template {
  font: inherit;
  font-size: 10px;
  color: var(--grn-soft);
  background: transparent;
  border: 1px dashed rgba(0, 232, 154, 0.28);
  border-radius: 4px;
  padding: 4px 7px;
  cursor: pointer;
  transition: 0.16s;
}
.chat-template:hover {
  border-style: solid;
  border-color: var(--grn);
  color: #eafff6;
}

.settings-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.settings-list > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding: 6px 0;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.12);
  font-size: 11.5px;
}
.settings-list span {
  color: var(--dim2);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.settings-list b {
  font-weight: 500;
  word-break: break-word;
  text-align: right;
}

body.day .subtabs {
  border-bottom-color: rgba(0, 110, 80, 0.16);
}
body.day .subtabs a {
  color: #4f6b5e;
  border-color: rgba(0, 110, 80, 0.2);
}
body.day .subtabs a.on {
  color: #fff;
  background: #00795a;
  border-color: #00795a;
  box-shadow: none;
}
body.day .admin-filters,
body.day .admin-table-wrap {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .admin-table th {
  background: #eef6f1;
  color: #5c7568;
}
body.day .admin-table th,
body.day .admin-table td {
  border-bottom-color: rgba(0, 110, 80, 0.1);
}
body.day .summary-money > div {
  border-color: rgba(0, 110, 80, 0.16);
  background: #f7fbf8;
}
body.day .summary-money b,
body.day .summary-status-row b {
  color: #00795a;
}
body.day .summary-status-row {
  border-bottom-color: rgba(0, 110, 80, 0.1);
}
body.day .chat-inbox-item {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .chat-inbox-item.on {
  background: #eaf5ef;
  border-color: #00795a;
}
body.day .chat-template {
  color: #006e50;
  border-color: rgba(0, 110, 80, 0.3);
}
body.day .settings-list > div {
  border-bottom-color: rgba(0, 110, 80, 0.1);
}

@media (max-width: 900px) {
  .summary-grid,
  .chat-inbox {
    grid-template-columns: 1fr;
  }
  .chat-inbox-list {
    max-height: 260px;
  }
}

/* ================= СМЕТА / ОТЧЁТ / АНАЛИЗ ИИ ================= */
.report {
  margin-top: 12px;
}
.report-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.report-badge {
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  border: 1px solid rgba(0, 232, 154, 0.26);
  border-radius: 3px;
  padding: 4px 8px;
}
.report-badge.ok {
  color: var(--grn);
  border-color: rgba(0, 232, 154, 0.5);
  background: rgba(0, 232, 154, 0.06);
}
.report-badge.wait {
  color: var(--amber);
  border-color: rgba(245, 193, 104, 0.45);
  background: rgba(245, 193, 104, 0.06);
}
.report-code {
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--dim2);
}
.report-scope {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 18px;
  margin: 0 0 14px;
}
.report-scope > div {
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  padding-top: 8px;
  min-width: 0;
}
.report-scope dt {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
  margin-bottom: 3px;
}
.report-scope dd {
  margin: 0;
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--dim);
  word-break: break-word;
}
.report-list {
  margin-top: 14px;
}
.report-list-title {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn);
  margin-bottom: 6px;
}
.report-list ol {
  margin: 0;
  padding-left: 18px;
}
.report-list li {
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--dim);
}
.report-list li + li {
  margin-top: 4px;
}
.report-list.muted li {
  color: var(--dim2);
}
.report-calc {
  margin-top: 16px;
  border-top: 1px dashed rgba(0, 232, 154, 0.14);
  padding-top: 12px;
}
.report-calc-title {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn);
  margin-bottom: 6px;
}
.report-calc table {
  width: 100%;
  border-collapse: collapse;
}
.report-calc td {
  padding: 4px 0;
  font-size: 11.5px;
  color: var(--dim);
  vertical-align: top;
}
.report-calc td:last-child {
  text-align: right;
  white-space: nowrap;
  padding-left: 12px;
  color: var(--grn-soft);
}
.report-calc tr.strong td {
  border-top: 1px dashed rgba(0, 232, 154, 0.18);
  padding-top: 8px;
  font-weight: 600;
  color: var(--grn);
  font-size: 12.5px;
}
.report-split {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.report-split > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.report-split span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.report-split b {
  font-size: 12px;
  color: var(--grn-soft);
}
.report-foot {
  margin-top: 12px;
}
.report.compact .report-scope {
  gap: 8px 14px;
}
.report.compact .report-list li,
.report.compact .report-calc td,
.report.compact .report-scope dd {
  font-size: 10.5px;
}
.admin-quote-state {
  margin-top: 8px;
  font-size: 10.5px;
}
.admin-quote-state.ok {
  color: var(--grn-soft);
}
.admin-quote-state.wait {
  color: var(--amber);
}
.ai-analysis {
  margin-top: 12px;
}
.ai-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
}
.ai-metrics > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.ai-metrics span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ai-metrics b {
  font-size: 12px;
  color: var(--grn-soft);
  font-weight: 600;
}
.ai-block {
  margin-top: 12px;
}
.ai-title {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grn);
  margin-bottom: 6px;
}
.ai-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.ai-block ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ai-block li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 5px 0;
  border-top: 1px dashed rgba(0, 232, 154, 0.1);
  font-size: 11px;
  color: var(--dim);
}
.ai-block li:first-child {
  border-top: 0;
}
.ai-block li b {
  color: var(--grn-soft);
  font-weight: 500;
  white-space: nowrap;
}
.ai-prompt {
  margin: 6px 0 0;
  max-height: 320px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 11px;
  line-height: 1.6;
  color: #dff8ee;
  background: rgba(4, 12, 8, 0.55);
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 4px;
  padding: 10px;
}
body.day .report-badge {
  color: #5b7568;
  border-color: rgba(0, 110, 80, 0.24);
}
body.day .report-badge.ok {
  color: #00795a;
  border-color: rgba(0, 110, 80, 0.4);
  background: rgba(0, 110, 80, 0.06);
}
body.day .report-badge.wait {
  color: #8a6100;
  border-color: rgba(138, 97, 0, 0.35);
  background: rgba(138, 97, 0, 0.06);
}
body.day .report-scope > div {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .report-scope dd,
body.day .report-list li,
body.day .report-calc td {
  color: #3a5648;
}
body.day .report-list.muted li {
  color: #6b8377;
}
body.day .report-list-title,
body.day .ai-title {
  color: #00795a;
}
body.day .report-calc {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .report-calc td:last-child,
body.day .report-split b,
body.day .ai-metrics b,
body.day .ai-block li b {
  color: #006b4f;
}
body.day .report-calc tr.strong td {
  border-top-color: rgba(0, 110, 80, 0.18);
  color: #00795a;
}
body.day .ai-block li {
  border-top-color: rgba(0, 110, 80, 0.12);
  color: #3a5648;
}
body.day .ai-prompt {
  background: #f7fbf8;
  border-color: rgba(0, 110, 80, 0.2);
  color: #132b20;
}
body.day .admin-quote-state.ok {
  color: #00795a;
}
body.day .admin-quote-state.wait {
  color: #8a6100;
}
@media (max-width: 640px) {
  .report-scope {
    grid-template-columns: 1fr;
  }
}

/* ================= ПЕРЕХОД К ОКНУ СМЕТЫ ================= */
#quote {
  scroll-margin-top: 16px;
}
#quote:target {
  border-color: rgba(0, 232, 154, 0.75);
  box-shadow:
    0 0 0 1px rgba(0, 232, 154, 0.18),
    0 0 36px -14px rgba(0, 232, 154, 0.9);
}
body.day #quote:target {
  border-color: #00795a;
  box-shadow:
    0 0 0 1px rgba(0, 121, 90, 0.16),
    0 0 26px -14px rgba(0, 121, 90, 0.6);
}

a.status.status-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--grn);
  cursor: pointer;
  transition: 0.16s;
}
a.status.status-link:hover,
a.status.status-link:focus-visible {
  color: #04150d;
  background: var(--grn);
  border-color: var(--grn);
  box-shadow: 0 0 16px -8px rgba(0, 232, 154, 0.8);
  outline: none;
}
body.day a.status.status-link {
  color: #00795a;
}
body.day a.status.status-link:hover,
body.day a.status.status-link:focus-visible {
  color: #fff;
  background: #00795a;
  border-color: #00795a;
}

a.quote-jump {
  border-bottom: 1px dashed rgba(0, 232, 154, 0.55);
  transition: 0.16s;
}
a.quote-jump:hover,
a.quote-jump:focus-visible {
  color: var(--grn);
  border-bottom-color: var(--grn);
}
body.day a.quote-jump {
  color: #006b4f;
  border-bottom-color: rgba(0, 121, 90, 0.45);
}
body.day a.quote-jump:hover {
  color: #00795a;
  border-bottom-color: #00795a;
}

/* ================= МОБИЛЬНАЯ АДАПТАЦИЯ ================= */
@media (max-width: 760px) {
  .wrap {
    padding: 14px 10px 36px;
  }
  .top {
    gap: 10px 12px;
    padding-bottom: 14px;
  }
  .brand {
    font-size: 20px;
    letter-spacing: 0.12em;
  }
  .top .sys {
    width: 100%;
    margin-left: auto;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "who theme"
      "tg online";
    align-items: center;
    justify-items: start;
    gap: 8px 12px;
    font-size: 9.5px;
    letter-spacing: 0.1em;
  }
  /* слева: личный кабинет, под ним мы в telegram */
  .top .sys .whoami {
    grid-area: who;
  }
  .top .sys .tg-link {
    grid-area: tg;
  }
  /* справа: переключатель тем, под ним online */
  .top .sys .tswitch {
    grid-area: theme;
    justify-self: end;
  }
  .top .sys .online {
    grid-area: online;
    justify-self: end;
  }
  /* обе кнопки — одинаковые по ширине и высоте */
  .top .sys .tg-link,
  .top .sys .whoami {
    min-width: 148px;
    min-height: 36px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 10px;
    letter-spacing: 0.06em;
  }
  .tg-link {
    gap: 5px;
  }
  .win {
    border-radius: 10px;
  }
  .win-top {
    gap: 8px;
    padding: 9px 12px;
    font-size: 9.5px;
  }
  .win-path {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .win-top .right {
    flex: none;
  }
  .win-body {
    padding: 18px 12px 22px;
    min-height: 0;
  }
  .tabs {
    padding: 8px 10px 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .tabs::-webkit-scrollbar {
    display: none;
  }
  .tabs a {
    min-height: 48px;
    padding: 12px 14px;
    font-size: 12.5px;
  }
  .win-foot {
    gap: 8px 12px;
    padding: 8px 12px;
    font-size: 9px;
  }
  .legal-links {
    gap: 6px 10px;
    padding: 0 4px;
    font-size: 9px;
  }

  /* --- заказ --- */
  .order-head {
    gap: 10px;
  }
  .order-head > div {
    min-width: 0;
  }
  .order-head .status {
    white-space: normal;
  }
  .status {
    font-size: 9.5px;
    letter-spacing: 0.1em;
    padding: 6px 9px;
  }
  a.status.status-link {
    min-height: 44px;
  }
  .track {
    gap: 4px;
    margin: 18px 0 4px;
    font-size: 9px;
    letter-spacing: 0.05em;
  }
  .ts {
    padding: 5px 7px;
  }
  .tsep {
    display: none;
  }
  .order-grid {
    gap: 12px;
    margin-top: 18px;
  }
  .panel {
    padding: 14px;
    border-radius: 6px;
  }
  .panel .ph {
    margin-bottom: 12px;
  }
  .tzrow {
    font-size: 12px;
    padding: 8px 0;
  }
  .price-big {
    font-size: 20px;
  }
  .pay-row {
    gap: 8px;
  }
  .pay-amount {
    font-size: 11px;
  }
  .pay-details {
    font-size: 11px;
    padding: 10px 12px;
  }
  .btn {
    min-height: 44px;
    padding: 12px 16px;
  }
  .btn-sm {
    min-height: 44px;
    padding: 11px 13px;
  }
  .actions .btn {
    min-height: 44px;
  }
  .chat-list {
    max-height: 380px;
  }
  .chat-msg {
    max-width: 92%;
  }
  .chat-form-foot {
    justify-content: flex-start;
  }
  .chat-form-foot .small {
    order: 2;
    width: 100%;
  }
  .chat-form-foot .btn {
    width: 100%;
  }
  .chat-panel,
  .chat-locked {
    padding: 14px;
  }

  /* --- админка --- */
  .admin-head {
    gap: 10px;
    margin-bottom: 14px;
  }
  .admin-stats {
    gap: 10px 16px;
    font-size: 9.5px;
  }
  .admin-filters {
    gap: 10px;
    padding: 10px;
  }
  .admin-filters .mini-field {
    width: 100%;
  }
  .admin-filters .btn {
    width: 100%;
  }
  .subtabs {
    gap: 5px;
  }
  .subtabs a {
    min-height: 44px;
    padding: 8px 10px;
  }
  .admin-table {
    font-size: 11px;
  }
  .admin-table th,
  .admin-table td {
    padding: 8px;
  }
  .summary-grid {
    gap: 12px;
  }
  .summary-money {
    grid-template-columns: 1fr;
  }
  .chat-inbox-list {
    max-height: none;
  }
  .chat-inbox-item {
    padding: 10px 11px;
  }
  .ocard {
    padding: 12px 13px;
  }
  .ocard-foot {
    gap: 8px;
  }
  .ocard-foot .sp {
    display: none;
  }
  .settings-list > div {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }
  .settings-list span {
    font-size: 9px;
  }
  .settings-list b {
    text-align: left;
  }
  .report-scope {
    grid-template-columns: 1fr;
  }
  .report-calc td:last-child {
    white-space: normal;
  }
  .report-split {
    gap: 12px 20px;
  }
  .quote-split {
    gap: 12px 20px;
  }

  /* --- лендинг --- */
  .hero {
    letter-spacing: -0.01em;
  }
  .sub {
    font-size: 12.5px;
  }
  .land-head,
  .land-section {
    gap: 10px;
  }

  .tswitch button {
    min-height: 36px;
    padding: 9px 10px;
  }
  .whoami {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
  }

  /* iOS не приближает страницу, если поле не меньше 16px */
  input:not([type="hidden"]):not(.opt-input),
  select,
  textarea {
    font-size: 16px;
  }
  .mini-field input {
    width: 100%;
  }
}

@media (max-width: 420px) {
  .wrap {
    padding: 10px 8px 30px;
  }
  .win-body {
    padding: 14px 10px 18px;
  }
  .panel {
    padding: 12px;
  }
  .order-head .status {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
  .code {
    font-size: 10px;
    letter-spacing: 0.08em;
  }
  .win-top .right {
    display: none;
  }
  .win-top {
    font-size: 9px;
  }
  .ts {
    font-size: 8.5px;
  }
  .btn {
    font-size: 11px;
    letter-spacing: 0.06em;
  }
  .summary-money b {
    font-size: 15px;
  }
  .chat-msg {
    max-width: 100%;
  }
}

/* Кликабельный статус сохраняет цвет своего состояния (ожидание — янтарный). */
a.status.status-link.awaiting_deposit,
a.status.status-link.awaiting_final,
a.status.status-link.awaiting_review {
  color: var(--amber);
  border-color: rgba(245, 193, 104, 0.5);
  background: rgba(245, 193, 104, 0.08);
}
a.status.status-link.awaiting_deposit:hover,
a.status.status-link.awaiting_deposit:focus-visible,
a.status.status-link.awaiting_final:hover,
a.status.status-link.awaiting_final:focus-visible,
a.status.status-link.awaiting_review:hover,
a.status.status-link.awaiting_review:focus-visible {
  color: #04150d;
  background: var(--amber);
  border-color: var(--amber);
  box-shadow: 0 0 16px -8px rgba(245, 193, 104, 0.85);
}
body.day a.status.status-link.awaiting_deposit,
body.day a.status.status-link.awaiting_final,
body.day a.status.status-link.awaiting_review {
  color: #8a6100;
  border-color: rgba(138, 97, 0, 0.4);
  background: rgba(138, 97, 0, 0.07);
}
body.day a.status.status-link.awaiting_deposit:hover,
body.day a.status.status-link.awaiting_deposit:focus-visible,
body.day a.status.status-link.awaiting_final:hover,
body.day a.status.status-link.awaiting_final:focus-visible,
body.day a.status.status-link.awaiting_review:hover,
body.day a.status.status-link.awaiting_review:focus-visible {
  color: #fff;
  background: #8a6100;
  border-color: #8a6100;
}

/* ================= CHAT ================= */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.chat-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(300px, 0.9fr);
  gap: 16px;
  margin-top: 18px;
  align-items: start;
}
.chat-main {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 540px;
}
.chat-head {
  display: flex;
  gap: 12px;
  align-items: center;
}
.chat-avatar {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--grn);
  background: rgba(0, 232, 154, 0.06);
}
.chat-head b {
  display: block;
  font-weight: 500;
  font-size: 12px;
  color: #E9FFF4;
}
.chat-head small {
  display: block;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--dim2);
}
.chat-count {
  color: var(--grn);
  font-variant-numeric: tabular-nums;
}
.chat-log {
  flex: 1 1 auto;
  min-height: 240px;
  max-height: 48vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.02);
  scroll-behavior: smooth;
}
.chat-msg {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.chat-msg.from-client {
  flex-direction: row-reverse;
}
.chat-role {
  flex: 0 0 24px;
  padding-top: 6px;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
  text-align: left;
}
.chat-msg.from-client .chat-role {
  text-align: right;
  color: var(--grn);
}
.chat-bubble {
  max-width: min(100%, 560px);
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.05);
  font-size: 12.5px;
  line-height: 1.62;
  overflow-wrap: anywhere;
}
.chat-msg.from-client .chat-bubble {
  background: rgba(0, 232, 154, 0.13);
  border-color: var(--line2);
  color: #E9FFF4;
}
.chat-msg.from-system .chat-bubble {
  border-style: dashed;
  color: var(--dim);
  background: transparent;
}
.chat-form {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}
.chat-input {
  flex: 1 1 auto;
  min-width: 0;
}
.chat-input textarea {
  display: block;
  width: 100%;
  min-height: 54px;
  max-height: 170px;
  resize: vertical;
  padding: 10px 12px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  background: transparent;
  color: var(--txt);
  font-family: inherit;
  font-size: 12.5px;
  line-height: 1.55;
}
.chat-input textarea:focus {
  outline: none;
  border-color: var(--grn);
  box-shadow: 0 0 0 1px rgba(0, 232, 154, 0.22);
}
.chat-hint {
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--dim2);
}
.chat-captcha .field {
  margin-top: 0;
}

/* ---------- модальное окно проверки ---------- */
body.modal-open {
  overflow: hidden;
}
.modal {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: grid;
  place-items: center;
  padding: 18px;
}
.modal[hidden] {
  display: none;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 8, 5, 0.74);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
body.day .modal-backdrop {
  background: rgba(18, 40, 30, 0.46);
}
.modal-card {
  position: relative;
  width: min(360px, 100%);
  padding: 18px 20px 22px;
  border: 1px solid var(--line2);
  border-radius: 10px;
  background: var(--panel);
  box-shadow: 0 0 0 1px rgba(0, 232, 154, 0.06), 0 26px 70px rgba(0, 0, 0, 0.55),
    0 0 34px rgba(0, 232, 154, 0.12);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.modal-head b {
  color: var(--grn);
  font-weight: 500;
}
.modal-text {
  margin-bottom: 14px;
  font-size: 12px;
  line-height: 1.55;
  color: var(--dim);
}
.modal-q {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  color: var(--dim);
}
.modal-q b {
  color: var(--grn);
  font-size: 16px;
  letter-spacing: 0.08em;
}
.modal-actions {
  margin-top: 14px;
}
.modal-actions .btn {
  display: block;
  width: 100%;
  text-align: center;
}
.chat-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}
.chat-spec .chat-spec-body {
  max-height: 46vh;
  overflow-y: auto;
  padding-right: 4px;
}
.chat-spec-empty p {
  margin: 0 0 10px;
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--dim);
}
.spec-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.spec-actions .field {
  margin: 0;
}
.spec-actions .btn {
  width: 100%;
  justify-content: center;
}
.spec-stale {
  margin: 0;
  padding: 8px 10px;
  font-size: 11px;
  line-height: 1.5;
  color: #ffcf70;
  border: 1px dashed rgba(255, 205, 100, 0.4);
  border-radius: 3px;
}
body.day .spec-stale {
  color: #7A5400;
  background: #FFF6E0;
  border-color: rgba(150, 100, 0, 0.3);
}
.chat-spec-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.chat-empty-text {
  font-size: 12px;
  line-height: 1.6;
  color: var(--dim);
  margin-bottom: 12px;
}
.chat-submit .btn {
  width: 100%;
  justify-content: center;
}
.chat-submit-note {
  margin: 12px 0;
  font-size: 10.5px;
  line-height: 1.55;
  color: var(--dim2);
}
.chat-company {
  display: none;
}
body.day .chat-log {
  background: #F2F8F4;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .chat-head b {
  color: #22392E;
}
body.day .chat-bubble {
  background: #FFFFFF;
  border-color: rgba(0, 110, 80, 0.16);
  color: #22392E;
}
body.day .chat-msg.from-client .chat-bubble {
  background: #E4F6EC;
  border-color: rgba(0, 110, 80, 0.3);
  color: #123024;
}
body.day .chat-input textarea {
  border-color: rgba(0, 110, 80, 0.24);
  color: #22392E;
}
body.day .chat-avatar {
  background: rgba(0, 110, 80, 0.06);
  color: #0A6B4A;
}

/* --- файлы готового ТЗ --- */
.chat-files.drop {
  border-color: var(--grn);
}
.chat-files-form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.chat-file-pick {
  cursor: pointer;
  margin: 0;
  position: relative;
  overflow: hidden;
}
.chat-file-pick input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.chat-files-status {
  font-size: 10.5px;
  line-height: 1.4;
  color: var(--dim2);
}
.chat-files-status.on {
  color: var(--grn);
}
.chat-files-status.err {
  color: var(--red);
}
.chat-file-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}
.chat-file {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.03);
}
.chat-file-main {
  min-width: 0;
}
.chat-file-name {
  display: block;
  font-size: 12px;
  color: var(--txt);
  overflow-wrap: anywhere;
}
.chat-file-meta {
  margin-top: 3px;
  font-size: 10px;
  color: var(--dim2);
}
.chat-file-x {
  flex: 0 0 auto;
  padding: 0 5px;
  border: 0;
  background: transparent;
  color: var(--dim2);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}
.chat-file-x:hover {
  color: var(--red);
}
body.day .chat-file {
  background: #F2F8F4;
  border-color: rgba(0, 110, 80, 0.16);
}
body.day .chat-file-name {
  color: #22392E;
}

.admin-files-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 4px 0;
}
.admin-file {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.admin-file-top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-file-name {
  font-size: 12px;
  overflow-wrap: anywhere;
}
.admin-file-badge {
  padding: 1px 6px;
  border: 1px solid var(--line2);
  border-radius: 4px;
  font-size: 9.5px;
  letter-spacing: 0.04em;
  color: var(--dim2);
}
.admin-file-badge.ok {
  border-color: rgba(0, 232, 154, 0.4);
  color: var(--grn);
}
.admin-file-text {
  margin-top: 8px;
}
.admin-file-text summary {
  font-size: 10.5px;
  color: var(--dim2);
  cursor: pointer;
}
.admin-file-text pre {
  max-height: 340px;
  overflow: auto;
  margin: 8px 0 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.18);
  color: var(--txt);
  font-family: inherit;
  font-size: 11.5px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.admin-file-empty {
  margin-top: 6px;
}
body.day .admin-file-text pre {
  background: #F2F8F4;
  border-color: rgba(0, 110, 80, 0.16);
  color: #22392E;
}

.admin-files-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 4px 0 8px;
}
.admin-file-ai-parse {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.admin-file-all-result {
  margin-bottom: 10px;
  border-color: rgba(0, 232, 154, 0.28);
}
.admin-file-ai-result {
  margin-top: 10px;
  padding: 8px 10px 10px;
  border: 1px solid rgba(0, 232, 154, 0.24);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.035);
}
.admin-file-ai-result > summary {
  font-size: 10.5px;
  letter-spacing: 0.04em;
  color: var(--grn-soft);
  cursor: pointer;
}
.admin-file-ai-meta {
  margin-top: 6px;
}
.admin-file-ai-warn {
  margin-top: 6px;
  color: var(--warn, #d7a54a);
}
.admin-file-ai-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}
.admin-file-field input,
.admin-file-field textarea {
  width: 100%;
}
.admin-file-field input.neon {
  width: 100%;
  font: inherit;
  font-size: 11.5px;
  color: var(--grn-soft);
  background: rgba(4, 12, 8, 0.9);
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 3px;
  padding: 7px 9px;
}
.admin-file-field input.neon:focus {
  outline: none;
  border-color: var(--grn);
}
.admin-scope-editor {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.admin-scope-label {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.admin-scope-row {
  display: grid;
  grid-template-columns: minmax(140px, 0.9fr) minmax(180px, 1.4fr);
  gap: 6px;
  align-items: start;
}
.admin-scope-row input,
.admin-scope-row textarea {
  width: 100%;
  font: inherit;
  font-size: 11.5px;
  color: var(--grn-soft);
  background: rgba(4, 12, 8, 0.9);
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 3px;
  padding: 7px 9px;
}
.admin-scope-row textarea {
  line-height: 1.5;
  resize: vertical;
}
.admin-scope-row input:focus,
.admin-scope-row textarea:focus {
  outline: none;
  border-color: var(--grn);
}
.admin-scope-row-new {
  opacity: 0.8;
}
.admin-file-ai-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}
body.day .admin-file-ai-result {
  background: #F2F8F4;
  border-color: rgba(0, 110, 80, 0.2);
}
body.day .admin-file-ai-result > summary {
  color: #07624A;
}
body.day .admin-file-field input.neon,
body.day .admin-scope-row input,
body.day .admin-scope-row textarea {
  background: #fff;
  color: #132b20;
  border-color: rgba(0, 110, 80, 0.24);
}
body.day .admin-file-field textarea {
  background: #fff;
  color: #132b20;
  border-color: rgba(0, 110, 80, 0.24);
}
@media (max-width: 760px) {
  .admin-scope-row {
    grid-template-columns: 1fr;
  }
  .admin-files-toolbar {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 760px) {
  .chat-shell {
    grid-template-columns: 1fr;
  }
  .chat-main {
    min-height: 0;
  }
  .chat-log {
    max-height: 46vh;
    min-height: 200px;
  }
  .chat-form {
    flex-direction: column;
    align-items: stretch;
  }
  .chat-form .btn {
    width: 100%;
    min-height: 44px;
  }
  .chat-spec .chat-spec-body {
    max-height: none;
  }
}

/* ============================================================
   Админка: посещения (своя статистика).
   ============================================================ */
.visit-periods {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.visit-periods a {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 4px;
  padding: 6px 10px;
  transition: 0.18s;
}
.visit-periods a:hover {
  color: var(--grn-soft);
  border-color: rgba(0, 232, 154, 0.45);
}
.visit-periods a.on {
  color: #05160e;
  background: var(--grn);
  border-color: var(--grn);
}

.visit-kpi {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.visit-kpi-card {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px 18px;
}
.visit-kpi-card.is-live {
  border-color: rgba(0, 232, 154, 0.42);
  box-shadow: 0 0 22px -14px rgba(0, 232, 154, 0.9);
}
.visit-kpi-label {
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.visit-kpi-num {
  font-size: 27px;
  line-height: 1.2;
  font-weight: 500;
  color: var(--grn-soft);
}
.visit-kpi-card.is-live .visit-kpi-num {
  color: var(--grn);
}
.visit-kpi-sub {
  font-size: 10px;
  color: var(--dim2);
}

.visit-behavior-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}
.visit-behavior-grid > div {
  border: 1px solid rgba(0, 232, 154, 0.14);
  border-radius: 5px;
  padding: 9px 11px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.visit-behavior-grid b {
  font-size: 16px;
  font-weight: 500;
  color: var(--txt);
}
.visit-behavior-grid b .small {
  font-size: 9.5px;
  color: var(--dim2);
}
.visit-bots {
  color: var(--dim2) !important;
}

/* Метка автоматической проверки визита. */
.visit-badge {
  display: inline-block;
  padding: 1px 7px;
  border: 1px solid rgba(150, 165, 158, 0.25);
  border-radius: 999px;
  font-size: 9.5px;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: var(--dim2);
}
.visit-badge.is-human {
  color: var(--grn-soft);
  border-color: rgba(0, 232, 154, 0.42);
}
.visit-badge.is-bot {
  color: var(--dim);
  border-color: rgba(150, 165, 158, 0.4);
}
.visit-badge.is-pending {
  color: var(--amber);
  border-color: rgba(215, 165, 74, 0.42);
}
.visit-badge.is-muted {
  color: var(--dim2);
  border-color: rgba(150, 165, 158, 0.18);
}

/* Люди и боты: доли, полоса соотношения и вердикт. */
.visit-split {
  margin-bottom: 16px;
}
.visit-split-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 28px;
  margin-bottom: 12px;
}
.visit-split-side {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 160px;
}
.visit-split-num {
  font-size: 30px;
  line-height: 1.15;
  font-weight: 500;
  color: var(--grn-soft);
}
.visit-split-side.is-bot .visit-split-num {
  color: var(--dim);
}
.visit-split-bar {
  display: flex;
  height: 12px;
  border-radius: 6px;
  overflow: hidden;
  background: rgba(0, 232, 154, 0.08);
}
.visit-split-bar span {
  display: block;
  height: 100%;
  transition: width 0.2s;
}
.visit-split-bar .is-human {
  background: linear-gradient(90deg, rgba(0, 232, 154, 0.45), var(--grn));
}
.visit-split-bar .is-bot {
  background: rgba(150, 165, 158, 0.55);
}
.visit-split-verdict {
  margin-top: 9px;
  font-size: 11px;
  color: var(--dim2);
}

.visit-legend {
  display: flex;
  gap: 16px;
  margin-top: 8px;
  font-size: 10px;
  color: var(--dim2);
}
.visit-legend i {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  margin-right: 4px;
  vertical-align: -1px;
}
.visit-legend i.is-human {
  background: var(--grn);
}
.visit-legend i.is-bot {
  background: rgba(150, 165, 158, 0.55);
}

.visit-row-track.is-bot i {
  background: linear-gradient(90deg, rgba(150, 165, 158, 0.35), rgba(150, 165, 158, 0.7));
}

.visit-chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 168px;
  padding: 10px 2px 0;
  border-bottom: 1px solid rgba(0, 232, 154, 0.18);
}
.visit-bar {
  flex: 1 1 0;
  min-width: 2px;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
}
.visit-bar span {
  display: block;
  width: 100%;
  max-width: 34px;
  min-height: 0;
  border-radius: 2px 2px 0 0;
  background: linear-gradient(180deg, rgba(0, 255, 156, 0.85), rgba(0, 232, 154, 0.35));
  box-shadow: 0 0 12px -6px rgba(0, 232, 154, 0.9);
  transition: 0.18s;
}
.visit-bar span.is-human {
  border-radius: 0;
}
.visit-bar span.is-bot {
  border-radius: 2px 2px 0 0;
  background: rgba(150, 165, 158, 0.5);
  box-shadow: none;
}
.visit-bar:hover span.is-human {
  background: var(--grn-bright);
}
.visit-chart-x {
  display: flex;
  gap: 3px;
  margin-top: 6px;
}
.visit-chart-x span {
  flex: 1 1 0;
  min-width: 2px;
  font-size: 8.5px;
  color: var(--dim2);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
}

.visit-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}
.visit-trios {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.visit-rows {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.visit-row {
  display: grid;
  grid-template-columns: minmax(72px, 34%) 1fr 40px;
  align-items: center;
  gap: 10px;
  font-size: 11px;
}
.visit-row-name {
  color: var(--txt);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.visit-row-track {
  display: block;
  height: 6px;
  border-radius: 3px;
  background: rgba(0, 232, 154, 0.09);
  overflow: hidden;
}
.visit-row-track i {
  display: block;
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, rgba(0, 232, 154, 0.45), var(--grn));
}
.visit-row b {
  font-size: 11px;
  font-weight: 500;
  color: var(--dim);
  text-align: right;
}

body.day .visit-kpi-card.is-live {
  box-shadow: 0 0 22px -16px rgba(0, 110, 80, 0.6);
}
body.day .visit-behavior-grid > div {
  border-color: rgba(0, 110, 80, 0.18);
}
body.day .visit-chart {
  border-bottom-color: rgba(0, 110, 80, 0.22);
}
body.day .visit-bar span.is-human {
  background: linear-gradient(180deg, #00a874, #6fd8b4);
  box-shadow: none;
}
body.day .visit-bar span.is-bot {
  background: #b9c4bf;
  box-shadow: none;
}
body.day .visit-split-bar {
  background: rgba(0, 110, 80, 0.1);
}
body.day .visit-split-bar .is-human {
  background: linear-gradient(90deg, #6fd8b4, #00a874);
}
body.day .visit-split-bar .is-bot {
  background: #b9c4bf;
}
body.day .visit-legend i.is-human {
  background: #00a874;
}
body.day .visit-legend i.is-bot {
  background: #b9c4bf;
}
body.day .visit-row-track.is-bot i {
  background: #b9c4bf;
}
body.day .visit-row-track {
  background: rgba(0, 110, 80, 0.1);
}
body.day .visit-row-track i {
  background: #00a874;
}

@media (max-width: 980px) {
  .visit-kpi {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .visit-behavior-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .visit-trios {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 760px) {
  .visit-cols,
  .visit-trios {
    grid-template-columns: 1fr;
  }
  .visit-behavior-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .visit-kpi-num {
    font-size: 23px;
  }
  .visit-chart {
    height: 140px;
  }
  .visit-split-num {
    font-size: 25px;
  }
  .visit-split-head {
    gap: 18px;
  }
}
@media (max-width: 480px) {
  .visit-kpi {
    grid-template-columns: 1fr 1fr;
  }
  .visit-kpi-card {
    padding: 13px 14px;
  }
}

/* ============================================================
   Админка: колонка разделов слева, рабочая область справа.
   Сама страница не прокручивается — скролл только у контента.
   ============================================================ */
body.admin-app {
  height: 100dvh;
  overflow: hidden;
}
body.admin-app .wrap {
  max-width: none;
  width: 100%;
  height: 100dvh;
  margin: 0;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
body.admin-app .top {
  flex: none;
  padding-bottom: 0;
}
body.admin-app .brand {
  font-size: clamp(18px, 2.2vw, 28px);
}
body.admin-app .legal-links {
  display: none;
}

body.admin-app .admin-shell {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 14px;
}

body.admin-app .admin-side {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(6, 21, 14, 0.92), rgba(4, 12, 8, 0.96));
  box-shadow: 0 0 0 1px rgba(0, 232, 154, 0.04), 0 0 22px -12px rgba(0, 232, 154, 0.5);
}
body.admin-app .admin-side-head {
  flex: none;
  padding: 13px 14px 11px;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.16);
}
body.admin-app .admin-side-kicker {
  display: block;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
body.admin-app .admin-side-title {
  display: block;
  margin-top: 3px;
  color: var(--grn-soft);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.06em;
}

body.admin-app .admin-nav {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow-y: auto;
  padding: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.35) transparent;
}
body.admin-app .admin-nav::-webkit-scrollbar {
  width: 6px;
}
body.admin-app .admin-nav::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.28);
  border-radius: 3px;
}
body.admin-app .admin-nav a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--dim2);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.3;
  transition: 0.16s;
}
body.admin-app .admin-nav a .n {
  flex: none;
  width: 18px;
  font-size: 9px;
  opacity: 0.55;
}
body.admin-app .admin-nav a .lbl {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
body.admin-app .admin-nav a .ar {
  flex: none;
  color: var(--grn);
  opacity: 0;
  transform: translateX(-3px);
  transition: 0.16s;
}
body.admin-app .admin-nav a:hover {
  color: var(--grn-soft);
  border-color: rgba(0, 232, 154, 0.32);
  background: rgba(0, 232, 154, 0.035);
}
body.admin-app .admin-nav a:hover .ar {
  opacity: 0.8;
  transform: none;
}
body.admin-app .admin-nav a.on {
  color: #05160e;
  background: var(--grn);
  border-color: var(--grn);
  box-shadow: 0 0 18px -8px rgba(0, 232, 154, 0.85);
}
body.admin-app .admin-nav a.on .n {
  opacity: 0.7;
}
body.admin-app .admin-nav a.on .ar {
  color: #05160e;
  opacity: 1;
  transform: none;
}

body.admin-app .admin-side-foot {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.16);
}
body.admin-app .admin-side-user {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  color: var(--dim2);
}
body.admin-app .admin-side-foot .whoami {
  font-size: 9.5px;
}

body.admin-app .admin-stage {
  min-width: 0;
  min-height: 0;
  display: flex;
}
body.admin-app .admin-stage > .win {
  flex: 1;
  width: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
body.admin-app .admin-stage .win .tabs {
  display: none;
}
body.admin-app .admin-stage .win-top,
body.admin-app .admin-stage .win-foot {
  flex: none;
}
body.admin-app .admin-stage .win-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.35) transparent;
}
body.admin-app .admin-stage .win-body::-webkit-scrollbar {
  width: 9px;
}
body.admin-app .admin-stage .win-body::-webkit-scrollbar-track {
  background: transparent;
}
body.admin-app .admin-stage .win-body::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.26);
  border: 2px solid transparent;
  border-radius: 5px;
  background-clip: padding-box;
}

/* дневная тема */
body.day.admin-app .admin-side {
  background: #F4F9F5;
  border-color: rgba(0, 110, 80, 0.24);
  box-shadow: 0 8px 30px -22px rgba(0, 70, 50, 0.5);
}
body.day.admin-app .admin-side-head,
body.day.admin-app .admin-side-foot {
  border-color: rgba(0, 110, 80, 0.14);
}
body.day.admin-app .admin-side-kicker,
body.day.admin-app .admin-side-user {
  color: #5E7A6C;
}
body.day.admin-app .admin-side-title {
  color: #006B4F;
}
body.day.admin-app .admin-nav a {
  color: #4A665A;
}
body.day.admin-app .admin-nav a:hover {
  color: #006B4F;
  border-color: rgba(0, 121, 90, 0.35);
  background: rgba(0, 121, 90, 0.05);
}
body.day.admin-app .admin-nav a .ar {
  color: #00795A;
}
body.day.admin-app .admin-nav a.on {
  color: #fff;
  background: #00795A;
  border-color: #00795A;
  box-shadow: 0 8px 18px -12px rgba(0, 121, 90, 0.8);
}
body.day.admin-app .admin-nav a.on .ar {
  color: #fff;
}

/* на узких экранах разделы уходят в горизонтальную строку */
@media (max-width: 900px) {
  body.admin-app .wrap {
    padding: 10px;
    gap: 10px;
  }
  body.admin-app .admin-shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    gap: 10px;
  }
  body.admin-app .admin-side {
    flex-direction: row;
    align-items: stretch;
    border-radius: 10px;
  }
  body.admin-app .admin-side-head,
  body.admin-app .admin-side-foot {
    display: none;
  }
  body.admin-app .admin-nav {
    flex-direction: row;
    gap: 4px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 6px;
  }
  body.admin-app .admin-nav a {
    flex: none;
    padding: 8px 9px;
  }
  body.admin-app .admin-nav a .n {
    width: auto;
  }
  body.admin-app .admin-nav a .lbl {
    flex: none;
  }
  body.admin-app .admin-nav a .ar {
    display: none;
  }
  body.admin-app .admin-stage .win {
    border-radius: 10px;
  }
}

/* ============================================================
   Админка: рабочий экран-дашборд.
   Страница не прокручивается: шапка фиксирована, панели
   делят остаток высоты, длинные списки листаются внутри панели.
   ============================================================ */
body.admin-app .prompt {
  display: none;
}
body.admin-app .win-body {
  min-height: 0;
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
body.admin-app .admin-stage .win-body {
  overflow: hidden;
}
body.admin-app .notice {
  margin: 0 !important;
  padding: 8px 11px;
  font-size: 11px;
}
body.admin-app .admin-filters {
  flex: none;
}
body.admin-app .admin-filters input[type="search"] {
  width: 100%;
}
body.day.admin-app .visit-periods a.on {
  color: #fff;
  background: #00795a;
  border-color: #00795a;
}

.admin-page {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.admin-page-head {
  flex: none;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.admin-page-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.admin-page-kicker {
  font-size: 9.5px;
  letter-spacing: 0.06em;
  color: var(--dim2);
}
.admin-page-kicker b {
  color: var(--grn);
  font-weight: 500;
}
.admin-page-head .otitle {
  margin: 0;
  font-size: clamp(17px, 1.6vw, 21px);
  line-height: 1.12;
}
.admin-page-head .btn-row {
  align-items: center;
}
.admin-page-head .small {
  font-size: 9.5px;
}
.admin-page-note {
  flex: none;
  font-size: 9.5px;
  color: var(--dim2);
  letter-spacing: 0.02em;
}
.admin-page .panel-note {
  margin-top: 8px;
  font-size: 9.5px;
  line-height: 1.55;
  color: var(--dim2);
}
.admin-page .panel-note b {
  color: var(--grn-soft);
  font-weight: 500;
}

.admin-page-body {
  flex: 1;
  min-height: 0;
  display: grid;
  gap: 10px;
}
.admin-page > .panel {
  flex: 1 1 auto;
}
.admin-page-body.cols-2 {
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
}
.admin-page-body.cols-2-even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.admin-page-body.cols-3 {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
}

.admin-page-body .panel,
.admin-pane {
  margin: 0;
  padding: 12px 14px;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.admin-page-body .panel > .ph,
.admin-pane > .ph {
  flex: none;
  margin-bottom: 9px;
}
.admin-pane-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.3) transparent;
}
.admin-pane-body::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
.admin-pane-body::-webkit-scrollbar-track {
  background: transparent;
}
.admin-pane-body::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.24);
  border: 2px solid transparent;
  border-radius: 5px;
  background-clip: padding-box;
}
.admin-pane-body::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 232, 154, 0.4);
  background-clip: padding-box;
}
.admin-pane-body.table {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.admin-pane-body .admin-table-wrap {
  border: 0;
  border-radius: 0;
  overflow: visible;
}
body.admin-app .admin-table {
  white-space: normal;
}
.admin-pane-body .admin-table th,
.admin-pane-body .admin-table td {
  padding: 7px 10px;
}
.admin-pane-body.table .admin-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #081d13;
}
body.day.admin-app .admin-pane-body.table .admin-table th {
  background: #eff7f2;
}
body.admin-app .admin-table .status {
  display: inline-block;
  white-space: nowrap;
}
.clients-table {
  table-layout: fixed;
}
.clients-table td {
  white-space: normal;
  overflow-wrap: anywhere;
}
.clients-table .status {
  font-size: 9px;
  letter-spacing: 0.02em;
  padding: 2px 6px;
}
.clients-table td .small {
  font-size: 9.5px;
}
body.admin-app .admin-list {
  gap: 8px;
}
body.admin-app .empty {
  padding: 22px 0;
}

.admin-toolbar {
  flex: none;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-toolbar .admin-filters {
  flex: 1 1 300px;
  margin: 0;
  padding: 7px 10px;
  gap: 8px 12px;
}
.admin-toolbar .admin-filters .mini-field span {
  font-size: 8.5px;
}
.admin-toolbar .admin-filters .neon,
.admin-toolbar .admin-filters .select {
  padding: 5px 8px;
  font-size: 11px;
}
.admin-statline {
  flex: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px 14px;
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
}
.admin-statline b {
  color: var(--grn-soft);
  font-weight: 500;
}

.admin-subnav {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.admin-seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.03);
}
.admin-seg a {
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
  transition: 0.15s;
}
.admin-seg a:hover {
  color: var(--grn-soft);
}
.admin-seg a.on {
  color: #05160e;
  background: var(--grn);
}
body.day.admin-app .admin-seg {
  border-color: rgba(0, 110, 80, 0.2);
  background: rgba(0, 121, 90, 0.04);
}
body.day.admin-app .admin-seg a {
  color: #4f6b5e;
}
body.day.admin-app .admin-seg a.on {
  color: #fff;
  background: #00795a;
}

/* --- карточка заявки: свёрнутая, управление по раскрытию --- */
body.admin-app .ocard {
  padding: 10px 12px;
}
body.admin-app .ocard-code {
  font-size: 12px;
}
body.admin-app .ocard-title {
  margin-top: 3px;
  font-size: 12.5px;
  line-height: 1.35;
}
body.admin-app .ocard-sub {
  margin-top: 3px;
  font-size: 10.5px;
}
.ocard-more {
  margin-top: 7px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  padding-top: 5px;
}
.ocard-more > summary {
  cursor: pointer;
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  padding: 2px 0;
  transition: 0.15s;
}
.ocard-more > summary:hover {
  color: var(--grn-soft);
}
.ocard-more[open] > summary {
  margin-bottom: 8px;
}
body.day .ocard-more {
  border-top-color: rgba(0, 110, 80, 0.14);
}

/* --- сводка: деньги, статусы, сроки, ИИ --- */
.summary-dash {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
}
.summary-dash .admin-pane {
  padding: 11px 13px;
}
.summary-dash .summary-money {
  gap: 7px;
}
.summary-dash .summary-money > div {
  padding: 7px 9px;
}
.summary-dash .summary-label {
  font-size: 8.5px;
  margin-bottom: 3px;
}
.summary-dash .summary-money b {
  font-size: 15px;
}
.summary-dash .summary-status {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 18px;
}
.summary-dash .summary-status-row {
  padding: 4px 0;
  font-size: 10.5px;
}
.summary-dash .panel-note {
  margin-top: 8px;
  font-size: 9.5px;
  line-height: 1.5;
  color: var(--dim2);
}
.summary-dash .admin-table th,
.summary-dash .admin-table td {
  padding: 6px 8px;
  font-size: 10.5px;
}
.summary-dash .admin-table th {
  font-size: 8.5px;
}

/* --- монитор ИИ в компактном виде --- */
.admin-page .ai-panel {
  margin: 0;
}
.ai-compact .ph {
  margin-bottom: 6px;
}
.ai-compact .ph > span:last-child {
  max-width: 56%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 9px;
}
.ai-compact .ai-stats {
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}
.ai-compact .ai-stat {
  padding: 5px 8px;
  gap: 1px;
}
.ai-compact .ai-stat > span {
  font-size: 8px;
}
.ai-compact .ai-stat > b {
  font-size: 14px;
}
.ai-compact .ai-stat > small {
  font-size: 8.5px;
}
.ai-compact .ai-note {
  display: none;
}
.ai-compact .btn-row {
  margin-top: 6px !important;
}

/* --- посещения: обзор --- */
.admin-page .visit-kpi {
  gap: 8px;
  margin: 0;
}
.admin-page .visit-kpi-card {
  padding: 10px 12px;
}
.admin-page .visit-kpi-num {
  font-size: 21px;
}
.admin-page .visit-kpi-sub {
  font-size: 9.5px;
}
.admin-page .visit-periods a {
  padding: 5px 8px;
  font-size: 9.5px;
}
.visit-overview {
  grid-template-rows: auto minmax(0, 1fr);
}
.visit-overview-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(210px, 1fr);
  gap: 10px;
}
.visit-overview-side {
  min-height: 0;
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.visit-overview .admin-pane {
  padding: 11px 13px;
}
.visit-chart-panel .admin-pane-body {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.visit-chart-panel .visit-chart {
  flex: 1;
  min-height: 84px;
  height: auto;
}
.visit-chart-panel .visit-chart-x {
  flex: none;
}
.visit-chart-panel .visit-legend {
  flex: none;
  margin-top: 4px;
}
.visit-overview .visit-split {
  margin: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.visit-overview .visit-split-head {
  gap: 16px;
  flex-wrap: nowrap;
  margin-bottom: 6px;
}
.visit-overview .visit-split-side {
  min-width: 0;
  flex: 1 1 0;
}
.visit-overview .visit-split-side .visit-kpi-sub {
  display: none;
}
.visit-overview .visit-split-num {
  font-size: 20px;
  line-height: 1.1;
}
.visit-overview .visit-split-verdict {
  margin-top: 5px;
  font-size: 9px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.visit-overview .visit-behavior-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}
.visit-overview .visit-behavior-grid > div {
  padding: 4px 7px;
  gap: 1px;
}
.visit-overview .visit-behavior-grid > div > .visit-kpi-label {
  font-size: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.visit-overview .visit-behavior-grid b {
  font-size: 14px;
  line-height: 1.15;
}
.visit-overview .visit-behavior-grid b .small {
  display: none;
}
.visit-audience {
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
}
.visit-audience .visit-pages {
  grid-row: 1 / span 2;
}
.visit-audience .admin-pane {
  padding: 11px 13px;
}
.visit-audience .visit-rows {
  gap: 6px;
}
.visit-audience .visit-row,
.visit-bots .visit-row {
  grid-template-columns: minmax(0, 46%) 1fr 34px;
  gap: 7px;
  font-size: 10.5px;
}
.visit-bots {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.visit-log {
  grid-template-columns: minmax(0, 1fr);
}

/* --- работы и отзывы --- */
.works-dash {
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
}
.works-dash .admin-pane {
  padding: 11px 13px;
}
.works-table {
  table-layout: fixed;
}
.works-table td {
  white-space: normal;
  overflow-wrap: anywhere;
}
.works-table th,
.works-table td {
  padding: 6px 8px;
}
.works-table td .small {
  font-size: 9.5px;
  line-height: 1.45;
}
.works-table .btn-sm {
  padding: 4px 7px;
  font-size: 9px;
}
.works-reviews {
  overflow: hidden;
}
.works-add {
  flex: none;
  margin-bottom: 8px;
  border: 1px dashed rgba(0, 232, 154, 0.2);
  border-radius: 5px;
  padding: 0 10px;
}
.works-add > summary {
  cursor: pointer;
  padding: 7px 0;
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  transition: 0.15s;
}
.works-add > summary:hover {
  color: var(--grn-soft);
}
.works-add[open] {
  padding-bottom: 10px;
}
.works-add[open] > summary {
  margin-bottom: 6px;
}
.works-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px 10px;
  align-items: end;
}
.works-fields .mini-field input,
.works-fields .mini-field .select {
  width: 100%;
}
.works-check {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 0 7px;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.works-add textarea {
  min-height: 52px;
}
body.day .works-add {
  border-color: rgba(0, 110, 80, 0.2);
}

/* --- настройки --- */
.settings-dash {
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
}
.settings-dash .admin-pane {
  padding: 11px 13px;
}
.settings-side {
  min-height: 0;
  display: grid;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.settings-side .admin-pane {
  justify-content: flex-start;
}
.settings-dash .settings-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 20px;
}
.settings-dash .settings-list > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 5px 0;
  font-size: 10.5px;
}
.settings-dash .settings-list span {
  font-size: 8.5px;
}
.settings-dash .settings-list b {
  text-align: left;
  font-size: 10px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

/* --- чаты: на всю высоту, списки листаются внутри --- */
.chat-page {
  grid-template-columns: minmax(0, 1fr);
}
.chat-page .chat-inbox {
  height: 100%;
  min-height: 0;
  align-items: stretch;
  grid-template-columns: minmax(200px, 290px) minmax(0, 1fr);
  gap: 10px;
}
.chat-page .chat-inbox-list {
  max-height: none;
  min-height: 0;
  overflow-y: auto;
}
.chat-page .chat-inbox-main {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.chat-page .chat-inbox-main .chat {
  flex: 1;
  min-height: 0;
}
.chat-page .chat-list {
  flex: 1;
  max-height: none;
  min-height: 0;
}
.chat-page .chat-active-bar {
  flex: none;
}

/* --- монитор ИИ --- */
.ai-dash {
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
}
.ai-dash .ai-stats {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.ai-dash .ai-stat {
  padding: 9px 11px;
}
.ai-dash .ai-stat > b {
  font-size: 17px;
}
.ai-dash .admin-pane {
  padding: 11px 13px;
}
.ai-dash .ai-panel .ph > span:first-child {
  white-space: nowrap;
}
.ai-dash .ai-panel .ph > span:last-child {
  font-size: 9px;
  text-align: right;
}

/* --- адаптив рабочего экрана: на узких экранах рабочая
       область листается целиком, страница по-прежнему нет --- */
@media (max-width: 900px) {
  /* Селектор обязан совпадать по весу с body.admin-app .admin-stage .win-body
     (overflow: hidden), иначе рабочая область остаётся обрезанной. */
  body.admin-app .admin-stage .win-body {
    display: block;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
  }
  .admin-page {
    display: block;
  }
  .admin-page-head {
    margin-bottom: 10px;
  }
  .admin-page-body {
    display: block;
  }
  .admin-page-body > * {
    margin-bottom: 10px;
  }
  .admin-page-body .panel,
  .admin-pane {
    overflow: visible;
  }
  .admin-pane-body {
    overflow: visible;
  }
  .summary-dash,
  .works-dash,
  .works-side,
  .settings-dash,
  .settings-side,
  .ai-dash,
  .visit-overview,
  .visit-overview-grid,
  .visit-overview-side,
  .visit-audience,
  .visit-bots {
    display: block;
  }
  .summary-dash > *,
  .works-dash > *,
  .works-side > *,
  .settings-dash > *,
  .settings-side > *,
  .ai-dash > *,
  .visit-overview > *,
  .visit-overview-grid > *,
  .visit-overview-side > *,
  .visit-audience > *,
  .visit-bots > * {
    margin-bottom: 10px;
  }
  .visit-audience .visit-pages {
    grid-row: auto;
  }
  .visit-chart-panel .visit-chart {
    height: 140px;
  }
  .chat-page .chat-inbox {
    grid-template-columns: minmax(0, 1fr);
    height: auto;
  }
  .chat-page .chat-inbox-list {
    max-height: 220px;
  }
  .chat-page .chat-inbox-main .chat-list {
    max-height: 320px;
  }
  .settings-dash .settings-list {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-height: 620px) {
  .admin-page .visit-kpi-card {
    padding: 8px 10px;
  }
  .admin-page .visit-kpi-num {
    font-size: 18px;
  }
}

/* ============================================================
   Личный кабинет: тот же рабочий каркас, что и в админке.
   Кабинет и чат не прокручивают страницу; заказ листается
   внутри рабочей области.
   ============================================================ */
body.lk-app .admin-shell {
  grid-template-columns: 214px minmax(0, 1fr);
}
body.lk-app .admin-stage .win-body {
  overflow-y: auto;
}
body.lk-app .admin-stage .win-body.lk-fixed {
  overflow: hidden;
}

.lk-dash-body {
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
}
.lk-aside {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.lk-panel {
  margin: 0;
  padding: 11px 13px;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.lk-panel > .ph {
  flex: none;
  margin-bottom: 6px;
}
.lk-aside .lk-panel:first-child {
  flex: 1 1 auto;
}
.lk-aside .lk-how {
  flex: 0 1 auto;
}

.lk-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 0;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.12);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-meta:last-child {
  border-bottom: 0;
}
.lk-meta b {
  min-width: 0;
  max-width: 62%;
  text-align: right;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-transform: none;
  color: #E9FFF4;
  overflow-wrap: anywhere;
}
.lk-meta b a {
  color: var(--grn-soft);
}
.lk-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 6px;
}
.lk-stats > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 4px;
  border: 1px solid rgba(0, 232, 154, 0.16);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.03);
}
.lk-stats b {
  font-size: 15px;
  font-weight: 500;
  color: var(--grn-soft);
  font-variant-numeric: tabular-nums;
}
.lk-stats span {
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
body.day .lk-stats > div {
  border-color: rgba(0, 110, 80, 0.16);
  background: rgba(0, 121, 90, 0.04);
}
body.day .lk-stats b {
  color: #006B4F;
}
body.day .lk-meta {
  border-bottom-color: rgba(0, 110, 80, 0.14);
}
body.day .lk-meta b {
  color: #0B2B1E;
}

.lk-subhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 2px 0 7px;
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-subhead:not(:first-child) {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px dashed rgba(0, 232, 154, 0.14);
}
body.day .lk-subhead:not(:first-child) {
  border-top-color: rgba(0, 110, 80, 0.14);
}
.lk-empty-active {
  padding: 12px 0 4px;
}

.lk-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.lk-steps li {
  display: flex;
  gap: 9px;
  align-items: flex-start;
}
.lk-steps .n {
  flex: none;
  width: 20px;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--grn);
  padding-top: 1px;
}
.lk-steps .t {
  min-width: 0;
}
.lk-steps b {
  display: block;
  font-size: 10.5px;
  font-weight: 500;
  color: #E9FFF4;
}
.lk-steps small {
  display: block;
  margin-top: 1px;
  font-size: 9px;
  line-height: 1.3;
  color: var(--dim2);
}
body.day .lk-steps b {
  color: #0B2B1E;
}
body.day .lk-steps .n {
  color: #00795A;
}

/* --- чат как раздел кабинета --- */
.lk-chat-page {
  min-height: 0;
}
.lk-chat-page .chat-shell {
  flex: 1;
  min-height: 0;
  margin-top: 0;
  align-items: stretch;
}
.lk-chat-page .chat-main {
  min-height: 0;
}
.lk-chat-page .chat-log {
  min-height: 0;
}
.lk-chat-page .chat-side {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  gap: 10px;
  padding-right: 3px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.3) transparent;
}
.lk-chat-page .chat-side .panel {
  padding: 10px 12px;
}
.lk-chat-page .chat-side .chat-empty-text {
  margin-bottom: 8px;
}
.lk-chat-page .chat-side::-webkit-scrollbar {
  width: 8px;
}
.lk-chat-page .chat-side::-webkit-scrollbar-track {
  background: transparent;
}
.lk-chat-page .chat-side::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.24);
  border: 2px solid transparent;
  border-radius: 5px;
  background-clip: padding-box;
}
.lk-chat-page .chat-spec .chat-spec-body {
  max-height: none;
  overflow: visible;
  padding-right: 0;
}
.lk-chat-page .chat-files,
.lk-chat-page .chat-spec,
.lk-chat-page .chat-submit,
.lk-chat-page .chat-done,
.lk-chat-page .chat-spec-empty {
  flex: none;
}

@media (max-width: 900px) {
  body.lk-app .admin-stage .win-body.lk-fixed {
    display: block;
    overflow-y: auto;
  }
  .lk-dash-body {
    display: block;
  }
  .lk-dash-body > * {
    margin-bottom: 10px;
  }
  .lk-aside {
    display: block;
  }
  .lk-aside .panel {
    margin-bottom: 10px;
  }
  .lk-panel {
    overflow: visible;
  }
  .lk-chat-page .chat-shell {
    display: block;
    flex: none;
  }
  .lk-chat-page .chat-main {
    min-height: 520px;
  }
  .lk-chat-page .chat-side {
    overflow: visible;
  }
}

/* --- вложения чата по заказу --- */
.chat-form-tools {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  flex: 1 1 auto;
  flex-wrap: wrap;
}
.chat-files-hint {
  color: var(--dim2);
}
.chat-files-hint.on {
  flex: 1 1 100%;
}
.chat-pending {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin: 0;
}
.chat-pending[hidden] {
  display: none;
}
.chat-pending-item {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  max-width: 100%;
}
.chat-pending-text {
  min-width: 0;
  color: var(--grn);
  font-size: 11px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  border-bottom: 1px dotted rgba(0, 232, 154, 0.32);
}
.chat-attach-x {
  flex: 0 0 auto;
  padding: 0 1px;
  border: 0;
  background: none;
  color: var(--dim2);
  font-size: 13px;
  line-height: 1.2;
  cursor: pointer;
}
.chat-attach-x:hover {
  color: var(--red);
}
.chat .chat-msg {
  display: block;
  max-width: 82%;
}
.chat .chat-msg .chat-bubble {
  display: inline-block;
  max-width: 100%;
}
.chat-attachments {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 6px;
  max-width: 100%;
}
.chat-msg.mine .chat-attachments {
  align-items: flex-end;
}
.chat-attach {
  display: block;
  max-width: 100%;
  padding: 0;
  color: var(--grn);
  font-size: 11px;
  line-height: 1.45;
  text-align: left;
  text-decoration: none;
  overflow-wrap: anywhere;
  border-bottom: 1px dotted rgba(0, 232, 154, 0.32);
}
.chat-attach:hover {
  color: var(--txt);
  border-bottom-color: var(--txt);
}
.chat-attach-size {
  color: var(--dim2);
}
body.day .chat-pending-text {
  color: #0A6B4A;
  border-bottom-color: rgba(0, 110, 80, 0.3);
}
body.day .chat-attach-x {
  color: #57756A;
}
body.day .chat-attach {
  color: #0A6B4A;
  border-bottom-color: rgba(0, 110, 80, 0.3);
}
body.day .chat-attach:hover {
  color: #22392E;
}

@media (max-width: 640px) {
  .chat-form-tools {
    width: 100%;
  }
  .chat-files-hint {
    flex: 1 1 100%;
  }
  .chat-attach {
    max-width: 100%;
  }
}

/* Чат по заказу: композер — колонка, а не строка как в чате с ИИ. */
.chat .chat-form {
  display: block;
}
.chat .chat-form textarea {
  display: block;
}

/* ================= КОНТАКТЫ ================= */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.contact-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.018);
  padding: 16px 17px;
  transition: 0.18s;
}
.contact-card:hover {
  border-color: var(--line2);
  background: rgba(0, 232, 154, 0.05);
  transform: translateY(-2px);
}
.contact-kicker {
  color: var(--grn);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.75;
}
.contact-card b {
  color: #eafff6;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.contact-card > span:not(.contact-kicker):not(.contact-go) {
  color: var(--dim);
  font-size: 12px;
  line-height: 1.6;
}
.contact-go {
  margin-top: auto;
  padding-top: 8px;
  color: var(--grn-soft);
  font-size: 10.5px;
  letter-spacing: 0.04em;
}
.contact-primary {
  border-color: rgba(0, 232, 154, 0.35);
  background: rgba(0, 232, 154, 0.045);
}
.contact-primary .contact-go {
  color: var(--grn);
}
body.day .contact-card b {
  color: #10382a;
}
body.day .contact-primary {
  border-color: rgba(0, 110, 80, 0.35);
  background: rgba(0, 110, 80, 0.05);
}
@media (max-width: 760px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   Телефон: разделы админки в выдвижном меню.
   До 900px боковая колонка превращается в шторку, а в шапке окна
   появляется кнопка с названием текущего раздела. Без JS остаётся
   прежняя горизонтальная лента, поэтому разметка работает всегда.
   ============================================================ */
.win-menu-btn,
.admin-side-close,
.admin-scrim {
  display: none;
}

@media (max-width: 900px) {
  /* --- компактная шапка: бренд, пользователь и тема в одну строку --- */
  body.amenu .top {
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding-bottom: 10px;
  }
  body.amenu .top-left {
    gap: 8px;
    min-width: 0;
  }
  body.amenu .top .brand {
    flex: none;
    font-size: 17px;
    letter-spacing: 0.12em;
  }
  body.amenu .top .sys {
    display: flex;
    width: auto;
    margin-left: auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 8px;
    min-width: 0;
    font-size: 9px;
  }
  body.amenu .top .sys .tswitch {
    grid-area: auto;
    justify-self: auto;
  }
  body.amenu .top .online {
    display: none;
  }
  body.amenu .top .whoami {
    display: none;
  }
  body.amenu .top .tswitch {
    flex: none;
  }
  body.amenu .top .tswitch button {
    padding: 5px 7px;
    font-size: 8px;
  }

  /* --- широкие таблицы листаются вбок, а не обрезаются --- */
  body.amenu .admin-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }

  /* --- кнопка меню в шапке окна --- */
  .win-menu-btn {
    display: inline-flex;
    flex: none;
    align-items: center;
    gap: 7px;
    min-height: 34px;
    margin-right: 2px;
    padding: 0 9px;
    border: 1px solid rgba(0, 232, 154, 0.32);
    border-radius: 5px;
    background: rgba(0, 232, 154, 0.07);
    color: var(--grn-soft, #9FF3D2);
    font: inherit;
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .win-menu-btn:active {
    background: rgba(0, 232, 154, 0.18);
  }
  .wmb-bars {
    display: inline-flex;
    flex-direction: column;
    gap: 3px;
    width: 14px;
    flex: none;
  }
  .wmb-bars i {
    display: block;
    height: 2px;
    border-radius: 1px;
    background: currentColor;
  }
  .wmb-text {
    max-width: 92px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.day .win-menu-btn {
    border-color: rgba(0, 110, 80, 0.32);
    background: rgba(0, 121, 90, 0.07);
    color: #006B4F;
  }

  /* --- затемнение под шторкой --- */
  body.amenu .admin-scrim:not([hidden]) {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 94;
    background: rgba(2, 8, 5, 0.72);
    touch-action: none;
  }

  /* --- сама шторка --- */
  body.amenu .admin-shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    gap: 0;
  }
  body.amenu .admin-stage {
    grid-row: 1;
  }
  body.amenu .admin-side {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 95;
    width: min(84vw, 320px);
    max-width: 320px;
    min-height: 0;
    padding: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    border-radius: 0 14px 14px 0;
    background: linear-gradient(180deg, rgba(6, 21, 14, 0.99), rgba(4, 12, 8, 1));
    box-shadow: 18px 0 50px -26px rgba(0, 0, 0, 0.95);
    transform: translateX(-103%);
    visibility: hidden;
    transition: transform 0.2s ease, visibility 0.2s ease;
    overflow: hidden;
    overscroll-behavior: contain;
  }
  body.amenu.menu-open .admin-side {
    transform: none;
    visibility: visible;
  }

  /* шапка и подвал шторки снова видны */
  body.amenu .admin-side-head {
    display: block;
    position: relative;
    padding: 13px 96px 11px 14px;
  }
  body.amenu .admin-side-foot {
    display: flex;
    padding: 10px 12px;
  }
  body.amenu .admin-side-foot .whoami {
    min-height: 36px;
    padding: 0 12px;
  }
  body.amenu .admin-side-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 9px;
    right: 9px;
    min-height: 30px;
    padding: 0 9px;
    border: 1px solid rgba(0, 232, 154, 0.26);
    border-radius: 5px;
    background: transparent;
    color: var(--dim2);
    font: inherit;
    font-size: 9px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
  }
  body.day.admin-app .admin-side-close {
    border-color: rgba(0, 110, 80, 0.28);
  }

  /* разделы — вертикальный список с крупными зонами нажатия */
  body.amenu .admin-side .admin-nav {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 6px 8px 10px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  body.amenu .admin-side .admin-nav a {
    flex: none;
    min-height: 46px;
    padding: 10px 12px;
    font-size: 12px;
    border-radius: 7px;
  }
  body.amenu .admin-side .admin-nav a .n {
    width: 24px;
    flex: none;
  }
  body.amenu .admin-side .admin-nav a .ar {
    display: inline-flex;
    margin-left: auto;
  }
}

/* ============================================================
   Быстрая заявка: три поля вместо длинного диалога.
   ============================================================ */
.quick {
  margin-top: 6px;
  padding: 18px;
  border: 1px solid rgba(0, 232, 154, 0.32);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(6, 21, 14, 0.72), rgba(4, 12, 8, 0.82));
  box-shadow: 0 0 0 1px rgba(0, 232, 154, 0.04), 0 0 30px -18px rgba(0, 232, 154, 0.6);
}
.quick-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.quick-kicker {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.quick-title {
  margin: 4px 0 0;
  font-size: 20px;
  line-height: 1.15;
  font-weight: 500;
  color: #E9FFF4;
}
.quick-time {
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grn);
}
.quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}
.qchip {
  font: inherit;
  font-size: 10px;
  letter-spacing: 0.04em;
  padding: 7px 11px;
  min-height: 32px;
  border: 1px solid rgba(0, 232, 154, 0.24);
  border-radius: 999px;
  background: transparent;
  color: var(--dim2);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.qchip:hover {
  color: var(--grn-soft, #9FF3D2);
  border-color: rgba(0, 232, 154, 0.45);
}
.qchip.on {
  background: rgba(0, 232, 154, 0.14);
  border-color: rgba(0, 232, 154, 0.65);
  color: var(--grn);
}
.quick-contacts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}
.quick .field {
  margin: 0 0 12px;
}
.quick .field > span {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim2);
  margin-bottom: 6px;
}
.quick .field input,
.quick .field textarea {
  display: block;
  width: 100%;
  padding: 11px 12px;
  background: rgba(0, 232, 154, 0.04);
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 6px;
  color: #E9FFF4;
  font: inherit;
  font-size: 13px;
  line-height: 1.5;
  caret-color: var(--grn);
  -webkit-appearance: none;
  appearance: none;
}
.quick .field input:focus,
.quick .field textarea:focus {
  outline: none;
  border-color: rgba(0, 232, 154, 0.68);
  box-shadow: 0 0 0 1px rgba(0, 232, 154, 0.18);
}
.quick .field input::placeholder,
.quick .field textarea::placeholder {
  color: rgba(190, 245, 225, 0.28);
}
.quick textarea.neon {
  width: 100%;
  resize: vertical;
  min-height: 84px;
}
.quick .btn-run {
  margin-top: 4px;
}
.quick-note {
  margin: 10px 0 0;
  font-size: 10px;
  line-height: 1.55;
  color: var(--dim2);
}
.quick-wait {
  margin: 8px 0 0;
  font-size: 10.5px;
  line-height: 1.5;
  color: var(--grn-soft);
}
.quick-wait[hidden] {
  display: none;
}
body.day .quick {
  background: #F7FBF8;
  border-color: rgba(0, 110, 80, 0.28);
  box-shadow: none;
}
body.day .quick-title {
  color: #0B2A1F;
}
body.day .quick .field input,
body.day .quick .field textarea {
  background: #FFFFFF;
  border-color: rgba(0, 110, 80, 0.3);
  color: #0B2A1F;
}
body.day .quick .field input::placeholder,
body.day .quick .field textarea::placeholder {
  color: rgba(11, 42, 31, 0.38);
}
body.day .qchip {
  border-color: rgba(0, 110, 80, 0.28);
  color: #3D6355;
}
body.day .qchip.on {
  background: rgba(0, 121, 90, 0.14);
  border-color: rgba(0, 110, 80, 0.6);
  color: #006B4F;
}
@media (max-width: 760px) {
  .quick {
    padding: 14px;
  }
  .quick-contacts {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

/* --- чат под быстрой заявкой --- */
.chat-ai {
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(0, 232, 154, 0.02);
}
.chat-ai > summary {
  cursor: pointer;
  padding: 13px 16px;
  list-style: none;
  display: flex;
  gap: 10px;
  align-items: baseline;
  flex-wrap: wrap;
  color: var(--grn-soft, #9FF3D2);
  font-size: 11.5px;
  letter-spacing: 0.04em;
}
.chat-ai > summary::-webkit-details-marker {
  display: none;
}
.chat-ai > summary::before {
  content: "+";
  color: var(--grn);
  font-variant-numeric: tabular-nums;
}
.chat-ai[open] > summary::before {
  content: "–";
}
.chat-ai-hint {
  color: var(--dim2);
  font-size: 10px;
}
.chat-ai .chat-shell {
  margin: 0 14px 14px;
}
@media (max-width: 900px) {
  .chat-ai .chat-shell {
    margin: 0 10px 10px;
  }
}

/* --- подсказка «что дальше» в заказе --- */
.order-next {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 16px 0 0;
  padding: 12px 14px;
  border: 1px solid rgba(0, 232, 154, 0.28);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.05);
  font-size: 12px;
  line-height: 1.5;
  color: #D8F5E8;
}
.order-next b {
  color: var(--grn);
  font-weight: 500;
}
.order-next a {
  color: var(--grn);
  text-decoration: underline;
}
body.day .order-next {
  background: rgba(0, 121, 90, 0.05);
  border-color: rgba(0, 110, 80, 0.22);
  color: #123C2D;
}

/* --- фильтры-счётчики в админке --- */
.admin-statline a {
  color: inherit;
  text-decoration: none;
  padding: 2px 7px;
  border-radius: 4px;
}
.admin-statline a:hover {
  background: rgba(0, 232, 154, 0.08);
  color: var(--grn-soft, #9FF3D2);
}
.admin-statline a.on {
  background: rgba(0, 232, 154, 0.14);
  color: var(--grn);
}

/* --- быстрые действия в карточке заявки --- */
.ocard-next {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 8px 0 2px;
}
.ocard-next .next-label {
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
  margin-right: 2px;
}
.ocard-next form {
  display: inline-flex;
  margin: 0;
}
.ocard-next .btn {
  min-height: 30px;
}

/* ============================================================
   Заказ в кабинете: компактный рабочий экран.
   Слева — заявка и ТЗ, в центре — чат, справа — оплата.
   Страница не прокручивается: каждая панель листается внутри.
   На телефоне разделы переключаются вкладками.
   ============================================================ */
.order-page {
  gap: 8px;
}
.order-top {
  align-items: center;
  gap: 8px 14px;
}
.order-top .otitle {
  max-width: 62ch;
}
.order-top-side {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 12px;
  min-width: 0;
}
.order-money {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.15;
}
.order-money b {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #E9FFF4;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.order-money span {
  font-size: 8.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim2);
  white-space: nowrap;
}
.order-top-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
}
.order-top-actions .btn,
.order-top-actions .copy {
  min-height: 30px;
  padding: 6px 10px;
  font-size: 9px;
  letter-spacing: 0.06em;
}
body.day .order-money b {
  color: #0B2B1E;
}

/* --- этапы: ТЗ → заявка → предоплата → работа → сдача --- */
.order-steps {
  flex: none;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}
.order-step {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  padding: 6px 10px;
  border: 1px solid rgba(0, 232, 154, 0.16);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.025);
  color: var(--dim2);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.order-step .n {
  flex: none;
  font-size: 9px;
  color: rgba(0, 232, 154, 0.45);
}
.order-step .lbl {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Единственный этап (отмена заказа) занимает всю строку. */
.order-steps > .order-step:only-child {
  grid-column: 1 / -1;
}
.order-step.done {
  color: var(--grn-soft);
  border-color: rgba(0, 232, 154, 0.3);
}
.order-step.done .n {
  color: var(--grn);
}
.order-step.now {
  color: #CFFFEA;
  background: rgba(0, 232, 154, 0.16);
  border-color: rgba(0, 232, 154, 0.62);
  box-shadow: inset 0 0 0 1px rgba(0, 232, 154, 0.12), 0 0 18px -10px rgba(0, 232, 154, 0.9);
}
.order-step.now .n {
  color: var(--grn);
}
body.day .order-step {
  border-color: rgba(0, 110, 80, 0.16);
  background: #fff;
  color: #57756A;
}
body.day .order-step .n {
  color: rgba(0, 110, 80, 0.5);
}
body.day .order-step.done {
  color: #00795A;
  border-color: rgba(0, 110, 80, 0.3);
}
body.day .order-step.now {
  color: #00654A;
  background: rgba(0, 121, 90, 0.1);
  border-color: rgba(0, 110, 80, 0.55);
  box-shadow: inset 0 0 0 1px rgba(0, 110, 80, 0.08);
}
body.day .order-step.now .n {
  color: #00795A;
}

/* --- подсказка «что сейчас» --- */
.order-page .order-next {
  flex: none;
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 7px 12px;
  font-size: 11.5px;
  line-height: 1.45;
}
.order-next-text {
  flex: 1 1 auto;
  min-width: 0;
}
.order-page .order-next .btn {
  flex: none;
  min-height: 32px;
  padding: 7px 12px;
}
.order-fresh {
  flex: none;
  font-size: 10.5px;
}

/* --- вкладки разделов (только телефон) --- */
.order-tabs {
  display: none;
}
.order-tabs button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 40px;
  padding: 6px 4px;
  border: 1px solid rgba(0, 232, 154, 0.2);
  border-radius: 5px;
  background: rgba(0, 232, 154, 0.03);
  color: var(--dim2);
  font: inherit;
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.order-tabs button .n {
  font-size: 8.5px;
  opacity: 0.55;
}
.order-tabs button.on {
  color: #04150D;
  background: var(--grn);
  border-color: var(--grn);
}
.order-tabs button.on .n {
  opacity: 0.65;
}
body.day .order-tabs button {
  border-color: rgba(0, 110, 80, 0.2);
  background: #fff;
  color: #57756A;
}
body.day .order-tabs button.on {
  color: #fff;
  background: #00795A;
  border-color: #00795A;
}

/* --- один раздел на весь экран: слева вкладки, справа содержимое --- */
.order-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
}
.order-body > .order-pane {
  grid-area: 1 / 1;
  margin: 0;
  padding: 12px 16px;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
/* Без JS показываем только раздел, отмеченный сервером (.is-on). */
.order-page .order-body > .order-pane {
  display: none;
}
.order-page .order-body > .order-pane.is-on {
  display: flex;
}

/* Широкий экран: строка текста не должна растягиваться на весь монитор. */
@media (min-width: 901px) {
  .order-body > .order-pane {
    padding: 16px 20px;
  }
  .order-body > .order-pane > .order-pane-body {
    max-width: 940px;
  }
  .order-body > .order-chat > .order-pane-body {
    max-width: none;
  }
}

/* --- разделы заказа в сайдбаре кабинета --- */
body.lk-app .admin-nav .lk-back {
  margin-top: auto;
  border-top: 1px dashed rgba(0, 232, 154, 0.16);
  border-radius: 0;
  color: var(--dim2);
  font-size: 9.5px;
}
body.lk-app .admin-nav .lk-back:hover {
  color: var(--grn-soft);
  background: transparent;
  border-color: rgba(0, 232, 154, 0.16);
}
body.lk-app .admin-nav .lk-back .ar {
  display: none;
}
body.day.lk-app .admin-nav .lk-back {
  border-top-color: rgba(0, 110, 80, 0.14);
}
.order-pane > .ph {
  flex: none;
  margin-bottom: 7px;
  gap: 8px;
  font-size: 9px;
}
.order-pane-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.28) transparent;
  padding-right: 3px;
}
.order-pane-body::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.order-pane-body::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.22);
  border-radius: 3px;
}

/* --- чат внутри панели --- */
.order-chat .order-pane-body {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-right: 0;
}
.order-chat .chat {
  flex: 1;
  min-height: 0;
}
.order-chat .chat-head {
  display: none;
}
.order-chat .chat-list {
  flex: 1;
  max-height: none;
  min-height: 0;
}
.order-chat .chat-form {
  flex: none;
}
.order-chat .chat-form textarea {
  resize: none;
}

/* --- свёрнутые блоки --- */
.order-fold {
  margin-top: 9px;
  padding-top: 7px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
}
.order-fold > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 3px 0;
  list-style: none;
  cursor: pointer;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
  -webkit-tap-highlight-color: transparent;
}
.order-fold > summary::-webkit-details-marker {
  display: none;
}
.order-fold > summary::after {
  content: "+";
  flex: none;
  margin-left: auto;
  padding-left: 8px;
  color: var(--grn);
  font-size: 12px;
  line-height: 1;
}
.order-fold[open] > summary::after {
  content: "−";
}
.order-fold > summary b {
  color: var(--grn-soft);
  font-weight: 500;
  white-space: nowrap;
}
.order-fold-body {
  padding-top: 8px;
}
body.day .order-fold {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .order-fold > summary b {
  color: #00795A;
}
.order-extras {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.order-extras li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 10.5px;
  color: var(--dim);
  padding: 3px 0;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.1);
}
.order-extras li:last-child {
  border-bottom: 0;
}
.order-extras li b {
  flex: none;
  font-weight: 500;
  color: var(--grn-soft);
  font-variant-numeric: tabular-nums;
}
.order-extras li.on {
  color: #E9FFF4;
}
body.day .order-extras li {
  border-bottom-color: rgba(0, 110, 80, 0.12);
}
body.day .order-extras li b {
  color: #00795A;
}
body.day .order-extras li.on {
  color: #0B2B1E;
}

/* --- журнал и отзыв внутри панели --- */
.order-fold-body .log {
  display: flex;
  gap: 8px;
  padding: 3px 0;
  font-size: 10.5px;
  color: var(--dim);
}
.order-fold-body .log .t {
  flex: none;
  color: rgba(0, 232, 154, 0.34);
  font-size: 9.5px;
  padding-top: 1px;
}
.order-fold-body .log.warn {
  color: var(--amber);
}
.order-page .order-review {
  margin: 0 0 10px;
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(0, 232, 154, 0.12);
}
body.day .order-page .order-review {
  border-bottom-color: rgba(0, 110, 80, 0.14);
}
.order-page .review-form.panel {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
}
.order-page .review-form.panel > .ph {
  margin-bottom: 8px;
}

/* --- оплата: служебные ссылки --- */
.order-pay-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed rgba(0, 232, 154, 0.12);
  font-size: 9.5px;
  color: var(--dim2);
}
.order-pay-links b {
  font-weight: 500;
  color: #C6EEDD;
}
body.day .order-pay-links {
  border-top-color: rgba(0, 110, 80, 0.14);
}
body.day .order-pay-links b {
  color: #0B2B1E;
}

/* --- четыре шага кабинета: заблокированные вкладки --- */
body.admin-app .admin-nav .lk-step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px dashed rgba(0, 232, 154, 0.14);
  border-radius: 6px;
  color: rgba(214, 244, 231, 0.38);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.3;
  cursor: not-allowed;
}
body.admin-app .admin-nav .lk-step .n {
  flex: none;
  width: 18px;
  font-size: 9px;
  opacity: 0.55;
}
body.admin-app .admin-nav .lk-step .lbl {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
body.admin-app .admin-nav .lk-step .lock {
  flex: none;
  font-size: 7.5px;
  letter-spacing: 0.06em;
  opacity: 0.45;
}
body.day.admin-app .admin-nav .lk-step {
  border-color: rgba(0, 110, 80, 0.16);
  color: rgba(18, 60, 45, 0.42);
}

/* --- статус: строка состояния и чат внутри раздела --- */
.order-statusline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 9px 12px;
  margin-bottom: 10px;
  border: 1px solid rgba(0, 232, 154, 0.18);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.04);
}
.order-statusline .small {
  min-width: 0;
  color: var(--dim);
  font-size: 10.5px;
  line-height: 1.45;
}
body.day .order-statusline {
  background: rgba(0, 121, 90, 0.04);
  border-color: rgba(0, 110, 80, 0.16);
}
.order-chatbox {
  display: flex;
  flex-direction: column;
  min-height: 0;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.16);
}
.order-chatbox-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.order-chatbox-head .g {
  color: var(--grn);
}
.order-chatbox .chat {
  padding: 10px 12px;
  border: 1px solid rgba(0, 232, 154, 0.14);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.12);
}
.order-chatbox .chat-list {
  max-height: 320px;
}
body.day .order-chatbox {
  border-top-color: rgba(0, 110, 80, 0.16);
}
body.day .order-chatbox .chat {
  border-color: rgba(0, 110, 80, 0.14);
  background: rgba(0, 110, 80, 0.03);
}

/* --- заявка и приёмка --- */
.brief-head,
.accept-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0 8px;
}
.brief-label {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.accept-wait {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px;
  border: 1px dashed rgba(0, 232, 154, 0.2);
  border-radius: 8px;
}
.accept-wait-mark {
  flex: none;
  color: var(--dim2);
  font-size: 18px;
  line-height: 1;
}
.accept-wait p {
  margin: 4px 0 10px;
}
.accept-done,
.accept-pay {
  margin-top: 12px;
}
.accept-decision {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed rgba(0, 232, 154, 0.16);
}
.accept-decision-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 12px;
  margin-bottom: 10px;
}
.accept-decision-head b {
  color: #E9FFF4;
  font-weight: 500;
  font-size: 12.5px;
}
.accept-comment {
  display: block;
  margin-bottom: 10px;
}
.accept-actions {
  flex-wrap: wrap;
}
.accept-actions .btn {
  min-height: 38px;
}
body.day .accept-decision-head b {
  color: #0B2B1E;
}

@media (min-width: 901px) {
  .order-page .order-next .btn {
    display: none;
  }
}

@media (max-width: 900px) {
  /* кабинет на телефоне: компактная шапка и лента разделов */
  body.lk-app .top {
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
  }
  body.lk-app .top-left {
    gap: 8px;
    min-width: 0;
  }
  body.lk-app .top .brand {
    flex: none;
    font-size: 17px;
    letter-spacing: 0.12em;
  }
  body.lk-app .top .sys {
    display: flex;
    width: auto;
    margin-left: auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 6px;
    min-width: 0;
  }
  body.lk-app .top .tswitch {
    grid-area: auto;
    justify-self: auto;
    flex: none;
  }
  body.lk-app .top .online,
  body.lk-app .top .whoami {
    display: none;
  }
  body.lk-app .top .tswitch button {
    padding: 5px 7px;
    font-size: 8px;
  }
  body.lk-app .top .tg-link span {
    display: none;
  }

  /* кабинет на телефоне: боковая колонка становится лентой разделов */
  body.lk-app .admin-shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
  }
  body.lk-app .admin-nav {
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 5px;
  }
  body.lk-app .admin-nav a {
    flex: 1 1 0;
    justify-content: center;
    min-height: 42px;
    padding: 8px;
  }
  body.lk-app .admin-nav a .ar {
    display: none;
  }
  body.lk-app .admin-nav .lk-step {
    flex: 1 1 0;
    justify-content: center;
    min-height: 42px;
    padding: 8px;
  }
  body.lk-app .admin-nav .lk-step .lock {
    display: none;
  }

  .order-page {
    display: block;
  }
  .order-page > * + * {
    margin-top: 8px;
  }
  .order-top {
    align-items: flex-start;
  }
  .order-top-side {
    justify-content: flex-start;
    width: 100%;
    gap: 8px;
  }
  .order-money {
    align-items: flex-start;
  }
  .order-steps {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 3px;
  }
  .order-step {
    justify-content: center;
    text-align: center;
    padding: 5px 4px;
    gap: 0;
    font-size: 8.5px;
    letter-spacing: 0.02em;
  }
  /* На телефоне пять этапов должны влезть в строку: маркер [✓] скрываем,
     состояние читается заливкой и цветом. */
  .order-step .n {
    display: none;
  }
  .order-page[data-js="1"] .order-body {
    display: block;
  }
  .order-body > .order-pane {
    padding: 12px;
  }
  .order-pane-body {
    overflow: visible;
    padding-right: 0;
  }
  .order-page[data-js="1"] .order-body > [data-pane="chat"].is-on {
    min-height: 380px;
    overflow: hidden;
  }
  .order-page[data-js="1"] .order-body > [data-pane="chat"].is-on .order-pane-body {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .order-chat .chat-list {
    max-height: none;
  }
  .order-chatbox .chat-list {
    max-height: 340px;
  }

  /* в полосе разделов «кабинет» — только стрелка, чтобы влезли 4 вкладки */
  body.lk-app .admin-nav .lk-back {
    flex: 0 0 auto;
    margin-top: 0;
    padding-left: 7px;
    padding-right: 7px;
    border-top: 0;
    border-left: 1px dashed rgba(0, 232, 154, 0.16);
  }
  body.lk-app .admin-nav .lk-back .lbl {
    display: none;
  }
  body.day.lk-app .admin-nav .lk-back {
    border-left-color: rgba(0, 110, 80, 0.14);
  }
  .order-tabs button {
    min-height: 44px;
  }
}

@media (max-width: 380px) {
  /* четыре раздела и «кабинет» должны влезать в строку без прокрутки */
  body.lk-app .admin-nav {
    gap: 3px;
    padding: 6px 5px;
  }
  body.lk-app .admin-nav a {
    padding: 7px 5px;
    gap: 5px;
    font-size: 9px;
  }
  body.lk-app .admin-nav .lk-back {
    padding-left: 5px;
    padding-right: 5px;
  }
  body.lk-app .top .tg-link {
    display: none;
  }
  body.lk-app .top .brand {
    font-size: 15px;
  }
  body.lk-app .top .tswitch button {
    padding: 5px 5px;
    font-size: 7.5px;
  }
  .order-step {
    padding: 5px 2px;
    font-size: 7.5px;
    letter-spacing: 0;
  }
}

@media print {
  body.admin-app,
  body.lk-app {
    height: auto;
    overflow: visible;
  }
  body.admin-app .wrap,
  body.admin-app .admin-shell,
  body.lk-app .wrap,
  body.lk-app .admin-shell {
    display: block;
    height: auto;
  }
  body.admin-app .admin-side,
  .win-top,
  .tabs,
  .order-tabs,
  .order-top-actions,
  .order-next,
  .order-steps,
  .win-foot {
    display: none !important;
  }
  body.lk-app .admin-stage .win-body.lk-fixed,
  body.admin-app .admin-stage .win-body {
    display: block !important;
    height: auto !important;
    overflow: visible !important;
  }
  .order-body {
    display: flex !important;
    flex-direction: column;
  }
  .order-body > [data-pane="brief"] { order: 1; }
  .order-body > [data-pane="status"] { order: 2; }
  .order-body > [data-pane="accept"] { order: 3; }
  .order-body > .order-pane {
    display: flex !important;
    overflow: visible !important;
    break-inside: avoid;
    margin-bottom: 10px;
  }
  .order-pane-body {
    overflow: visible !important;
  }
  .order-chatbox .chat-list {
    max-height: none !important;
    overflow: visible !important;
  }

  /* Печать: тёмную тему принудительно переводим в чёрное на белом,
     иначе светлый текст исчезает на белой бумаге. */
  body,
  body.admin-app,
  body.lk-app {
    background: #fff !important;
  }
  .order-page,
  .order-page * {
    color: #111 !important;
    text-shadow: none !important;
    box-shadow: none !important;
    animation: none !important;
  }
  .order-page .panel,
  .order-page .order-pane,
  .order-page .order-fold-body {
    background: #fff !important;
    border-color: #c9c9c9 !important;
  }
  .order-page select,
  .order-page input,
  .order-page textarea {
    background: #fff !important;
    color: #111 !important;
    border-color: #999 !important;
  }
  .order-page .status,
  .order-page .order-step,
  .order-page .report-badge,
  .order-page .pay-bar,
  .order-page .order-tabs button {
    background: #f4f4f4 !important;
    border-color: #999 !important;
  }
  .order-page .pay-bar .fill,
  .order-page .order-step.now {
    background: #dff2e9 !important;
    border-color: #0b7a57 !important;
  }
  .order-page .order-fold {
    border-top-color: #ddd !important;
    padding-top: 8px;
  }
  .order-page .order-fold > summary::after {
    color: #111 !important;
  }
  .order-page .order-chat,
  .order-page .order-chat .order-pane-body,
  .order-page .order-chat .chat,
  .order-page .order-chat .chat-list {
    display: block !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }
  .order-page .order-chat .chat-form {
    display: none !important;
  }
  .order-page a {
    color: #0b5c43 !important;
  }
  .order-page .mono-break,
  .order-page .delivery {
    background: #fafafa !important;
    border-color: #ddd !important;
    white-space: pre-wrap !important;
  }
}

/* ============================================================
   Новая заявка в кабинете: два рабочих поля вместо терминала.
   Слева — диалог, справа — черновик ТЗ и файлы, внизу — шаг.
   ============================================================ */
body.lk-chat-focus .top .sys,
body.lk-chat-focus .top-left .whoami {
  display: none;
}
body.lk-chat-focus .admin-shell,
body.lk-chat-focus .admin-stage,
body.lk-chat-focus .admin-stage > .win {
  min-height: 0;
}
body.lk-chat-focus .admin-shell {
  grid-template-columns: minmax(0, 1fr);
}
body.lk-chat-focus .admin-stage .win-top,
body.lk-chat-focus .admin-stage .win-foot {
  display: none;
}
body.lk-chat-focus .admin-stage .win {
  border: 0;
  background: transparent;
  box-shadow: none;
}
body.lk-chat-focus .admin-stage .win::after {
  display: none;
}
body.lk-chat-focus .admin-stage .win-body {
  padding: 0;
}

.lk-chat-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.lk-chat-head {
  flex: none;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.lk-chat-head-main {
  min-width: 0;
}
.lk-chat-kicker {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-chat-head .otitle {
  margin: 3px 0 0;
  font-size: clamp(19px, 1.9vw, 25px);
  line-height: 1.15;
}
.lk-chat-sub {
  margin: 7px 0 0;
  max-width: 64ch;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--dim);
}

.lk-settings {
  position: relative;
  flex: none;
}
.lk-settings > summary {
  cursor: pointer;
  list-style: none;
  padding: 8px 12px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  font-size: 11px;
  color: var(--dim);
}
.lk-settings > summary::-webkit-details-marker {
  display: none;
}
.lk-settings[open] > summary {
  color: var(--grn);
  border-color: rgba(0, 232, 154, 0.5);
}
.lk-settings-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 40;
  min-width: 210px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--line2);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45);
}
.lk-settings-menu a,
.lk-settings-link {
  padding: 2px 0;
  border: 0;
  background: transparent;
  color: var(--txt);
  font: inherit;
  font-size: 12px;
  text-align: left;
  cursor: pointer;
}
.lk-settings-menu a:hover,
.lk-settings-link:hover {
  color: var(--grn);
}
.lk-settings-menu .tswitch {
  display: flex;
  gap: 4px;
}
.lk-settings-menu .tswitch button {
  flex: 1;
  padding: 6px 8px;
  font-size: 9px;
}
body.day .lk-settings-menu {
  background: #FFFFFF;
  border-color: rgba(0, 110, 80, 0.22);
  box-shadow: 0 16px 36px rgba(20, 50, 38, 0.18);
}

.lk-progress {
  flex: none;
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.lk-progress li {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0, 232, 154, 0.02);
  color: var(--dim2);
}
.lk-progress li.on {
  color: #E9FFF4;
  border-color: rgba(0, 232, 154, 0.55);
  background: rgba(0, 232, 154, 0.08);
}
.lk-progress-n {
  flex: none;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}
.lk-progress-t {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}
.lk-progress li:not(.on) .lk-progress-t {
  opacity: 0.7;
}
.lk-progress-t-short {
  display: none;
}
body.day .lk-progress li.on {
  color: #0B2B1E;
  border-color: rgba(0, 110, 80, 0.5);
  background: rgba(0, 121, 90, 0.08);
}

.lk-chat-grid {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 14px;
  align-items: stretch;
}
.lk-chat-talk {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.lk-chat-talk .chat-shell {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0;
  display: flex;
}
.lk-chat-talk .chat-shell[hidden] {
  display: none;
}
.lk-chat-talk .chat-main {
  width: 100%;
  min-height: 0;
  gap: 10px;
}
.lk-chat-page .chat-head {
  display: none;
}
.lk-chat-talk .chat-log {
  min-height: 0;
  max-height: none;
  flex: 1 1 auto;
}
.lk-quick {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: 0;
}
.lk-quick[hidden] {
  display: none;
}
.lk-quick .quick-form {
  display: flex;
  flex-direction: column;
}
.lk-quick .quick-form .btn-run {
  align-self: flex-start;
}

.lk-chat-side {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 3px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.45) transparent;
}
.lk-chat-side::-webkit-scrollbar {
  width: 9px;
}
.lk-chat-side::-webkit-scrollbar-thumb {
  background: rgba(0, 232, 154, 0.42);
  border: 2px solid transparent;
  border-radius: 5px;
  background-clip: padding-box;
}
.lk-chat-side .panel {
  flex: none;
  padding: 11px 13px;
}
.lk-chat-side .chat-spec .chat-spec-body {
  /* Прокрутка одна — у всей правой колонки: вложенный скролл внутри
     карточки ТЗ путал и обрезал текст на середине строки. */
  max-height: none;
  overflow: visible;
}
.lk-chat-side .chat-files {
  order: 2;
}
.lk-chat-side .chat-spec {
  order: 1;
}
.lk-chat-side .chat-approve {
  order: 3;
}
.lk-chat-side .chat-submit-note {
  margin: 0 0 10px;
}
.lk-chat-side .chat-submit .field {
  margin-bottom: 10px;
}
.lk-chat-side .chat-submit .btn {
  width: 100%;
}

.spec-rebuild > summary {
  cursor: pointer;
  list-style: none;
  font-size: 11px;
  color: var(--dim2);
}
.spec-rebuild > summary::-webkit-details-marker {
  display: none;
}
.spec-rebuild > summary::before {
  content: "+";
  margin-right: 6px;
  color: var(--grn);
}
.spec-rebuild[open] > summary::before {
  content: "–";
}
.spec-rebuild .field {
  margin: 10px 0 8px;
}

.chat-approve {
  border: 1px solid rgba(0, 232, 154, 0.3);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.04);
}
.chat-approve[hidden] {
  display: none;
}
.chat-approve > summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  font-size: 12.5px;
  color: #E9FFF4;
}
.chat-approve > summary::-webkit-details-marker {
  display: none;
}
.chat-approve > summary::before {
  content: "+";
  flex: none;
  color: var(--grn);
  font-variant-numeric: tabular-nums;
}
.chat-approve[open] > summary::before {
  content: "–";
}
.chat-approve > summary small {
  margin-left: auto;
  color: var(--dim2);
  font-size: 10px;
  text-align: right;
}
.chat-approve[open] > summary {
  border-bottom: 1px dashed var(--line);
}
.chat-approve .chat-submit {
  padding: 12px 14px 14px;
}
body.day .chat-approve {
  border-color: rgba(0, 110, 80, 0.28);
  background: #F4FBF7;
}
body.day .chat-approve > summary {
  color: #0B2B1E;
}

.lk-chat-bottom {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.lk-chat-bottom-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.lk-chat-bottom-text b {
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grn);
}
.lk-chat-bottom-text span {
  font-size: 12px;
  color: var(--dim);
}
.lk-chat-bottom .btn {
  flex: none;
}

/* --- читаемый диалог: абзацы, заголовки, списки --- */
.chat-bubble p {
  margin: 0 0 8px;
}
.chat-bubble p:last-child {
  margin-bottom: 0;
}
.chat-bubble .msg-head {
  margin: 10px 0 6px;
  font-weight: 600;
  color: #E9FFF4;
}
.chat-bubble .msg-head:first-child {
  margin-top: 0;
}
.chat-bubble .msg-list {
  margin: 6px 0 8px;
  padding-left: 18px;
}
.chat-bubble .msg-list:last-child {
  margin-bottom: 0;
}
.chat-bubble .msg-list li {
  margin: 0 0 3px;
}
body.day .chat-bubble .msg-head {
  color: #123024;
}
.msg-dump > summary {
  cursor: pointer;
  font-size: 11px;
  color: var(--dim2);
}
.msg-dump pre {
  margin: 8px 0 0;
  max-height: 170px;
  overflow: auto;
  white-space: pre-wrap;
  font-size: 10.5px;
  line-height: 1.5;
  color: var(--dim2);
}

@media (max-width: 980px) {
  body.lk-chat-focus .admin-stage .win-body.lk-fixed {
    overflow-y: auto;
  }
  .lk-chat-page {
    height: auto;
  }
  .lk-chat-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .lk-chat-talk {
    min-height: 520px;
  }
  .lk-chat-side {
    overflow: visible;
    padding-right: 0;
  }
  .lk-chat-side .chat-spec .chat-spec-body {
    max-height: none;
    overflow: visible;
  }
}
@media (max-width: 640px) {
  .lk-chat-page {
    gap: 10px;
  }
  .lk-chat-sub {
    font-size: 12px;
  }
  .lk-progress {
    gap: 4px;
  }
  .lk-progress li {
    justify-content: center;
    padding: 7px 5px;
  }
  .lk-progress li.on {
    flex: 2.2 1 0;
  }
  .lk-progress-t,
  .lk-progress li.on .lk-progress-t {
    display: none;
  }
  .lk-progress li.on .lk-progress-t-short {
    display: inline;
  }
  .lk-chat-talk {
    min-height: 440px;
  }
  .lk-chat-talk .chat-main {
    padding: 10px;
  }
  .lk-chat-bottom {
    padding: 9px 0;
  }
  .lk-chat-bottom-text span {
    font-size: 11px;
  }
  .lk-chat-bottom .btn {
    padding: 10px 14px;
  }
  /* меню настроек раскрывается влево от кнопки — на узком экране
     оно уходило за левый край, поэтому прижимаем его к кнопке */
  .lk-settings-menu {
    left: 0;
    right: auto;
    width: min(230px, calc(100vw - 24px));
    min-width: 0;
  }
}

@media (max-height: 660px) and (min-width: 981px) {
  body.lk-chat-focus .admin-stage .win-body.lk-fixed {
    overflow-y: auto;
  }
  .lk-chat-page {
    height: auto;
  }
  .lk-chat-grid {
    min-height: 520px;
  }
  .lk-chat-talk {
    min-height: 520px;
  }
}

/* ============================================================
   Новая заявка — каркас ticket view (Metronic) в терминальной
   палитре: крошки, шапка-тикет, вкладки-этапы, сводка заявки.
   ============================================================ */
.lk-chat-page {
  gap: 8px;
}

.lk-ticket-crumb {
  flex: none;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-ticket-crumb i {
  font-style: normal;
  color: rgba(0, 232, 154, 0.35);
}
.lk-ticket-crumb b {
  color: var(--grn);
  font-weight: 500;
}

.lk-chat-page .lk-chat-head {
  align-items: flex-start;
}
.lk-chat-page .lk-chat-head-main {
  flex: 1 1 auto;
  min-width: 0;
}
.lk-chat-page .lk-chat-sub {
  max-width: none;
}
.lk-ticket-meta em {
  font-style: normal;
  color: var(--txt);
}
.lk-ticket-meta em.is-ok {
  color: var(--grn);
}
.lk-ticket-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.lk-chat-page .lk-ticket-title .otitle {
  margin: 0;
  font-size: clamp(18px, 1.75vw, 24px);
  letter-spacing: 0.01em;
}
.lk-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px 2px;
  border: 1px solid var(--line2);
  background: rgba(0, 232, 154, 0.07);
  color: var(--grn);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}
.lk-badge i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 3px rgba(0, 232, 154, 0.12);
}

.lk-ticket-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin-top: 8px;
  font-size: 11px;
  color: var(--txt);
}
.lk-ticket-meta span {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  min-width: 0;
}
.lk-ticket-meta b {
  font-weight: 500;
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-ticket-meta span + span {
  position: relative;
  padding-left: 18px;
}
.lk-ticket-meta span + span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  bottom: 2px;
  width: 1px;
  background: var(--line);
}

/* этапы — вкладки тикета, а не отдельные карточки */
.lk-chat-page .lk-progress {
  gap: 0;
  border-bottom: 1px solid var(--line2);
  overflow-x: auto;
  scrollbar-width: none;
}
.lk-chat-page .lk-progress::-webkit-scrollbar {
  display: none;
}
.lk-chat-page .lk-progress li {
  flex: 0 0 auto;
  gap: 8px;
  padding: 8px 18px 9px 2px;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: transparent;
  margin-bottom: -1px;
  color: var(--dim2);
}
.lk-chat-page .lk-progress li + li {
  padding-left: 18px;
}
.lk-chat-page .lk-progress li.on {
  color: #E9FFF4;
  border-bottom-color: var(--grn);
  background: linear-gradient(180deg, rgba(0, 232, 154, 0.1), rgba(0, 232, 154, 0));
}
.lk-chat-page .lk-progress-n {
  width: auto;
  height: auto;
  display: inline;
  border: 0;
  border-radius: 0;
  font-size: 9.5px;
  letter-spacing: 0.08em;
  color: var(--dim2);
}
.lk-chat-page .lk-progress li.on .lk-progress-n {
  color: var(--grn);
}
.lk-chat-page .lk-progress-t {
  font-size: 11px;
  letter-spacing: 0.02em;
}

/* панели — карточки тикета */
.lk-chat-page .panel {
  border-color: var(--line);
  background:
    linear-gradient(180deg, rgba(0, 232, 154, 0.05), rgba(0, 232, 154, 0) 120px),
    var(--panel);
}
.lk-chat-page .panel .ph {
  text-transform: uppercase;
  letter-spacing: 0.13em;
  font-size: 9.5px;
}

.lk-ticket-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0 6px;
  margin-bottom: 2px;
  border-bottom: 1px dashed var(--line);
}
.lk-ticket-id {
  flex: none;
  padding: 2px 6px;
  border: 1px solid var(--line2);
  background: rgba(0, 232, 154, 0.06);
  color: var(--grn);
  font-size: 10px;
  letter-spacing: 0.1em;
}
.lk-ticket-subject {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  color: #E9FFF4;
}
.lk-ticket-live {
  margin-left: auto;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-ticket-live i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--grn);
  box-shadow: 0 0 8px rgba(0, 232, 154, 0.8);
  animation: lk-pulse 1.8s ease-in-out infinite;
}
@keyframes lk-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}
@media (prefers-reduced-motion: reduce) {
  .lk-ticket-live i { animation: none; }
}

/* сообщения — реплики тикета */
.lk-chat-page .chat-log {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 10px 0 4px;
}
.lk-chat-page .chat-bubble {
  border-radius: 0;
  border-left: 2px solid var(--line2);
  background: rgba(0, 232, 154, 0.04);
}
.lk-chat-page .chat-msg.from-client .chat-bubble {
  border-left-color: var(--grn);
  background: rgba(0, 232, 154, 0.1);
}
.lk-chat-page .chat-role {
  font-size: 8.5px;
}
.lk-chat-page .lk-chat-bottom {
  border-top-color: var(--line2);
}

/* мобильная раскладка: вкладки остаются вкладками */
@media (max-width: 640px) {
  .lk-chat-page .lk-progress li,
  .lk-chat-page .lk-progress li.on {
    flex: 1 1 0;
    justify-content: center;
    padding: 7px 4px;
  }
  .lk-chat-page .lk-progress li + li {
    padding-left: 4px;
  }
  .lk-chat-page .lk-progress-n {
    display: inline;
    font-size: 9px;
  }
  .lk-chat-page .lk-progress-t-short {
    font-size: 10px;
  }
  .lk-chat-page .lk-progress li.on .lk-progress-t-short {
    display: inline;
  }
  .lk-ticket-meta {
    gap: 4px 12px;
  }
  .lk-ticket-meta span + span {
    padding-left: 12px;
  }
}

/* дневная тема */
body.day .lk-chat-page .panel {
  background: #FFFFFF;
}
body.day .lk-badge {
  color: #0B6B4E;
  border-color: rgba(0, 110, 80, 0.35);
  background: rgba(0, 121, 90, 0.08);
}
body.day .lk-ticket-crumb b {
  color: #00795A;
}
body.day .lk-ticket-meta em.is-ok {
  color: #00795A;
}
body.day .lk-ticket-id {
  color: #00795A;
  border-color: rgba(0, 110, 80, 0.35);
  background: rgba(0, 121, 90, 0.06);
}
body.day .lk-chat-page .lk-progress li.on {
  color: #0B2B1E;
  border-bottom-color: #00795A;
  background: linear-gradient(180deg, rgba(0, 121, 90, 0.1), rgba(0, 121, 90, 0));
}
body.day .lk-chat-page .lk-progress li.on .lk-progress-n {
  color: #00795A;
}
body.day .lk-chat-page .chat-bubble {
  background: rgba(0, 121, 90, 0.04);
}
body.day .lk-chat-page .chat-msg.from-client .chat-bubble {
  background: rgba(0, 121, 90, 0.09);
}
body.day .lk-ticket-subject {
  color: #123024;
}
/* ============================================================
   Кабинет клиента: app-shell на всю высоту окна.
   Страница не прокручивается: рабочая область — открытая
   вкладка, а длинные списки и чат листаются внутри панелей.
   Сайдбар спрятан за левой кромкой и выезжает при наведении.
   ============================================================ */
body.lk2-app {
  height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  overscroll-behavior: none;
}
.lk2 {
  position: relative;
  height: 100vh;
  height: 100dvh;
  display: flex;
  overflow: hidden;
}

/* ---------- узкая рейка: видимые значки разделов ---------- */
.lk2-rail {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: 56px;
  z-index: 64;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 10px 0 12px;
  border-right: 1px solid var(--line2);
  background: linear-gradient(180deg, rgba(6, 21, 14, 0.99), rgba(4, 12, 8, 0.995));
  transition: opacity 0.18s ease;
}
body.lk2-nav-open .lk2-rail {
  opacity: 0;
  pointer-events: none;
}
.lk2-rail-brand {
  flex: none;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line2);
  border-radius: 8px;
  color: var(--grn);
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0;
  text-decoration: none;
}
.lk2-rail-brand:hover {
  border-color: rgba(0, 232, 154, 0.5);
  color: #E9FFF4;
  background: rgba(0, 232, 154, 0.08);
}
.lk2-rail-nav {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
}
.lk2-rail-nav::-webkit-scrollbar {
  display: none;
}
.lk2-rail .admin-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: visible;
}
.lk2-rail .admin-nav a,
.lk2-rail .admin-nav .lk-step {
  width: 38px;
  height: 38px;
  min-height: 0;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  padding: 0;
  gap: 0;
  border: 1px solid transparent;
  border-radius: 7px;
  color: var(--dim);
  background: transparent;
}
.lk2-rail .admin-nav a:hover {
  color: var(--grn);
  background: rgba(0, 232, 154, 0.06);
  border-color: var(--line);
}
.lk2-rail .admin-nav a.on {
  color: var(--grn);
  background: rgba(0, 232, 154, 0.1);
  border-color: rgba(0, 232, 154, 0.4);
}
.lk2-rail .admin-nav .lk-step {
  color: rgba(190, 245, 225, 0.35);
}
.lk2-rail .admin-nav .n,
.lk2-rail .admin-nav .lbl,
.lk2-rail .admin-nav .ar,
.lk2-rail .admin-nav .lock {
  display: none;
}
.lk2-rail .admin-nav .lk-back {
  margin-top: 6px;
  border-top: 1px dashed var(--line);
  border-radius: 0;
}
.lk2-rail-hint {
  flex: none;
  color: var(--grn);
  font-size: 14px;
  line-height: 1;
  opacity: 0.55;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.lk2-rail:hover .lk2-rail-hint {
  opacity: 1;
  transform: translateX(2px);
}
/* в полном сайдбаре значки не нужны — там номера и подписи */
.admin-nav .ic {
  display: none;
}
.lk2-rail .admin-nav .ic {
  display: block;
}

/* ---------- сайдбар ---------- */
.lk2-side {
  position: fixed;
  inset: 0 auto 0 0;
  width: 272px;
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-right: 1px solid var(--line2);
  background: linear-gradient(180deg, rgba(6, 21, 14, 0.99), rgba(4, 12, 8, 0.995));
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  z-index: 70;
  transform: translateX(-101%);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  will-change: transform;
}
body.lk2-nav-open .lk2-side,
.lk2-side:focus-within {
  transform: translateX(0);
  box-shadow: 18px 0 60px rgba(0, 0, 0, 0.45);
}

.lk2-side-head {
  flex: none;
  padding: 14px 14px 10px;
  border-bottom: 1px solid var(--line);
}
.lk2-side-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.lk2-brand {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: 0.04em;
  color: #E9FFF4;
  text-decoration: none;
  white-space: nowrap;
}
.lk2-brand i {
  font-style: normal;
  color: var(--grn);
}
.lk2-pin,
.lk2-close {
  flex: none;
  border: 1px solid var(--line2);
  border-radius: 5px;
  background: transparent;
  color: var(--dim2);
  font: inherit;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.lk2-pin {
  padding: 5px 7px;
}
.lk2-close {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  padding: 0;
  font-size: 15px;
  line-height: 1;
}
.lk2-pin:hover,
.lk2-close:hover {
  color: var(--grn);
  border-color: rgba(0, 232, 154, 0.5);
}
.lk2-pin[aria-pressed="true"] {
  color: var(--grn);
  border-color: rgba(0, 232, 154, 0.5);
  background: rgba(0, 232, 154, 0.1);
}

.lk2-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  font-size: 8.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk2-crumb a {
  color: var(--dim2);
  text-decoration: none;
}
.lk2-crumb a:hover {
  color: var(--grn);
}
.lk2-crumb b {
  color: #E9FFF4;
  font-weight: 500;
}
.lk2-crumb-sep {
  font-style: normal;
  color: rgba(0, 232, 154, 0.4);
}

.lk2-side-nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.4) transparent;
}
.lk2-side .admin-nav {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin: 0;
  padding: 0;
}
.lk2-side .admin-nav a,
.lk2-side .admin-nav .lk-step {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--txt);
  font-size: 12px;
  text-decoration: none;
}
.lk2-side .admin-nav a .n,
.lk2-side .admin-nav .lk-step .n {
  flex: none;
  font-size: 9.5px;
  letter-spacing: 0.1em;
  color: var(--dim2);
}
.lk2-side .admin-nav a .lbl,
.lk2-side .admin-nav .lk-step .lbl {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lk2-side .admin-nav a .ar {
  flex: none;
  color: var(--dim2);
  opacity: 0;
  transition: opacity 0.15s ease;
}
.lk2-side .admin-nav a:hover {
  color: #E9FFF4;
  background: rgba(0, 232, 154, 0.05);
  border-color: var(--line2);
}
.lk2-side .admin-nav a:hover .ar {
  opacity: 1;
}
.lk2-side .admin-nav a.on {
  color: #E9FFF4;
  background: rgba(0, 232, 154, 0.1);
  border-color: rgba(0, 232, 154, 0.4);
}
.lk2-side .admin-nav a.on .n {
  color: var(--grn);
}
.lk2-side .admin-nav a.on .ar {
  color: var(--grn);
  opacity: 1;
}
.lk2-side .admin-nav .lk-step {
  color: var(--dim2);
}
.lk2-side .admin-nav .lk-step .lock {
  margin-left: auto;
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(190, 245, 225, 0.35);
}
.lk2-side .admin-nav .lk-back {
  margin-top: 8px;
  border-top: 1px dashed var(--line);
  border-radius: 0;
  padding-top: 13px;
}

.lk2-side-foot {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 14px 12px;
  border-top: 1px solid var(--line);
}
.lk2-side-user {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}
.lk2-avatar {
  flex: none;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line2);
  border-radius: 50%;
  background: rgba(0, 232, 154, 0.07);
  color: var(--grn);
  font-size: 11px;
  font-weight: 500;
}
.lk2-side-user span {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.lk2-side-user strong {
  font-size: 11px;
  font-weight: 500;
  color: #E9FFF4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lk2-side-user em {
  font-style: normal;
  font-size: 9px;
  color: var(--dim2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lk2-side-links {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 12px;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.lk2-side-links a {
  color: var(--dim2);
  text-decoration: none;
}
.lk2-side-links a:hover {
  color: var(--grn);
}
.lk2-side-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 2px;
}
.lk2-side-tools .tswitch button {
  padding: 4px 7px;
  font-size: 8px;
}
.lk2-logout {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--dim2);
  font: inherit;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.lk2-logout:hover {
  color: var(--grn);
}

/* ---------- рабочая область ---------- */
.lk2-main {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: padding-left 0.22s ease;
}

.lk2-content {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 14px 20px 16px;
}
.lk2-content > * {
  flex: 1 1 auto;
  min-height: 0;
}

.lk2-burger {
  display: none;
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 62;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line2);
  border-radius: 7px;
  background: rgba(4, 12, 8, 0.86);
  cursor: pointer;
}
.lk2-bars {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.lk2-bars i {
  width: 15px;
  height: 1.5px;
  background: var(--grn);
}
.lk2-scrim {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 68;
  border: 0;
  background: rgba(2, 8, 5, 0.62);
  cursor: pointer;
}

/* ---------- закреплённый сайдбар двигает контент, а не перекрывает ---------- */
@media (min-width: 1101px) {
  /* рейка занимает свою полосу, контент не перекрывается */
  .lk2-main {
    padding-left: 56px;
  }
  body.lk2-pinned .lk2-side {
    transform: translateX(0);
    box-shadow: none;
  }
  body.lk2-pinned .lk2-main {
    padding-left: 272px;
  }
  body.lk2-pinned .lk2-rail {
    display: none;
  }
}

/* ---------- кабинет: списки листаются внутри ---------- */
body.lk2-app .admin-page {
  min-height: 0;
  overflow: hidden;
}
body.lk2-app .admin-page-head,
body.lk2-app .admin-page > .notice {
  flex: none;
}
body.lk2-app .lk-dash-body {
  min-height: 0;
  overflow: hidden;
}
body.lk2-app .lk-orders {
  min-height: 0;
}
body.lk2-app .lk-orders .admin-pane-body {
  min-height: 0;
  overflow-y: auto;
}
body.lk2-app .lk-aside {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.3) transparent;
}
body.lk2-app .lk-aside .lk-panel {
  flex: 0 0 auto;
  overflow: visible;
}

/* ---------- новая заявка: каталог листается, кнопка под рукой ---------- */
body.lk2-app .lk-pick-page {
  min-height: 0;
  max-width: none;
  overflow: hidden;
}
body.lk2-app .lk-pick-page .lk-chat-head,
body.lk2-app .lk-pick-page .lk-progress,
body.lk2-app .lk-pick-page > .notice {
  flex: none;
}
body.lk2-app .lk-pick-page .lk-pick {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 6px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.3) transparent;
}
body.lk2-app .lk-pick-submit {
  position: sticky;
  bottom: -1px;
  z-index: 5;
  margin-top: 2px;
  padding: 12px 0 2px;
  background: linear-gradient(180deg, rgba(4, 12, 8, 0), rgba(4, 12, 8, 0.96) 38%);
}
body.day.lk2-app .lk-pick-submit {
  background: linear-gradient(180deg, rgba(238, 244, 239, 0), rgba(238, 244, 239, 0.97) 38%);
}

/* ---------- заказ: панель занимает всю высоту, тело листается ---------- */
body.lk2-app .order-page {
  min-height: 0;
  overflow: hidden;
}
body.lk2-app .order-page > * {
  flex: none;
}
body.lk2-app .order-page .order-body {
  flex: 1 1 auto;
  min-height: 0;
}
/* верх панели статуса листается, а чат с полем ввода закреплён внизу */
body.lk2-app .order-status .order-pane-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
  padding-right: 0;
}
body.lk2-app .order-status-scroll {
  flex: 0 1 auto;
  max-height: 42%;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 232, 154, 0.28) transparent;
}
body.lk2-app .order-chatbox {
  flex: 1 1 auto;
  min-height: 0;
  margin-top: 0;
  padding-top: 8px;
  display: flex;
  flex-direction: column;
}
body.lk2-app .order-chatbox .chat-head {
  display: none;
}
body.lk2-app .order-chatbox .chat {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
body.lk2-app .order-chatbox .chat-list {
  flex: 1 1 auto;
  min-height: 100px;
  max-height: none;
}
body.lk2-app .order-chatbox .chat-form {
  flex: none;
}

/* ---------- мобильная версия: drawer и обычный скролл контента ---------- */
@media (max-width: 1100px) {
  .lk2-rail {
    display: none;
  }
  .lk2-side {
    width: 286px;
    max-width: 86vw;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  }
  body.lk2-nav-open .lk2-scrim {
    display: block;
  }
  .lk2-main {
    padding-left: 0;
  }
  .lk2-burger {
    display: inline-flex;
  }
  .lk2-pin {
    display: none;
  }
  .lk2-content {
    padding: 54px 14px 14px;
  }
  /* в drawer навигация остаётся вертикальной, а не лентой разделов */
  body.lk2-app .lk2-side .lk2-side-nav {
    overflow-y: auto;
  }
  body.lk2-app .lk2-side .admin-nav {
    flex-direction: column;
    overflow: visible;
    padding: 0;
  }
  body.lk2-app .lk2-side .admin-nav a,
  body.lk2-app .lk2-side .admin-nav .lk-step {
    flex: 0 0 auto;
    justify-content: flex-start;
    min-height: 0;
    padding: 9px 10px;
  }
  body.lk2-app .lk2-side .admin-nav a .ar,
  body.lk2-app .lk2-side .admin-nav .lk-step .lock {
    display: block;
  }
  body.lk2-app .lk2-side .admin-nav .lk-back {
    margin-top: 8px;
    padding: 13px 10px 9px;
    border-top: 1px dashed var(--line);
    border-left: 0;
  }
  body.lk2-app .lk2-side .admin-nav .lk-back .lbl {
    display: inline;
  }
}
@media (max-width: 900px) {
  /* На телефоне рабочая область прокручивается целиком:
     фиксированная высота тут только мешает. */
  body.lk2-app .lk2-content {
    display: block;
    overflow-y: auto;
  }
  body.lk2-app .lk2-content > * {
    flex: 0 0 auto;
  }
  body.lk2-app .admin-page,
  body.lk2-app .admin-page-body,
  body.lk2-app .lk-dash-body,
  body.lk2-app .lk-aside,
  body.lk2-app .lk-pick-page,
  body.lk2-app .lk-pick-page .lk-pick,
  body.lk2-app .order-page,
  body.lk2-app .order-page .order-body {
    overflow: visible;
    min-height: 0;
  }
  body.lk2-app .order-status .order-pane-body {
    display: block;
    overflow: visible;
  }
  body.lk2-app .order-status-scroll {
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }
  body.lk2-app .order-chatbox {
    display: block;
    margin-top: 12px;
  }
  body.lk2-app .order-chatbox .chat-list {
    max-height: 42vh;
    overflow-y: auto;
  }
  body.lk2-app .lk-pick-submit {
    position: static;
    background: none;
    padding-top: 2px;
  }
  body.lk2-app .lk-aside .lk-panel {
    overflow: hidden;
  }
}

/* ---------- дневная тема ---------- */
body.day .lk2-side {
  background: linear-gradient(180deg, #FFFFFF, #F3F8F5);
  border-right-color: rgba(0, 110, 80, 0.18);
}
body.day .lk2-side-head,
body.day .lk2-side-foot {
  border-color: rgba(0, 110, 80, 0.14);
}
body.day .lk2-brand,
body.day .lk2-crumb b,
body.day .lk2-side-user strong {
  color: #0B2B1E;
}
body.day .lk2-rail {
  background: linear-gradient(180deg, #FFFFFF, #F3F8F5);
  border-right-color: rgba(0, 110, 80, 0.18);
}
body.day .lk2-rail-brand {
  color: #0B2B1E;
  border-color: rgba(0, 110, 80, 0.24);
}
body.day .lk2-rail .admin-nav a {
  color: #57756A;
}
body.day .lk2-rail .admin-nav a:hover {
  color: #00795A;
  background: rgba(0, 121, 90, 0.05);
  border-color: rgba(0, 121, 90, 0.22);
}
body.day .lk2-rail .admin-nav a.on {
  color: #00795A;
  background: rgba(0, 121, 90, 0.1);
  border-color: rgba(0, 121, 90, 0.4);
}
body.day .lk2-burger {
  background: rgba(244, 249, 246, 0.92);
}
body.day .lk2-scrim {
  background: rgba(2, 8, 5, 0.4);
}
body.day .lk2-side .admin-nav a {
  color: #3D5A4D;
}
body.day .lk2-side .admin-nav a:hover {
  color: #006B4F;
  background: rgba(0, 121, 90, 0.05);
  border-color: rgba(0, 121, 90, 0.22);
}
body.day .lk2-side .admin-nav a.on {
  color: #006B4F;
  background: rgba(0, 121, 90, 0.09);
  border-color: rgba(0, 121, 90, 0.38);
}
body.day .lk2-avatar {
  color: #00795A;
  border-color: rgba(0, 110, 80, 0.3);
  background: rgba(0, 121, 90, 0.07);
}

/* ============================================================
   Выбор продукта: новая заявка без ИИ
   ============================================================ */
.lk-pick-page {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 1180px;
}
.lk-pick-active {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 8px;
}
.lk-pick-active a {
  color: var(--grn);
  text-decoration: none;
}
.lk-pick-active a:hover {
  text-decoration: underline;
}
.lk-pick-active-note {
  color: var(--dim);
}

.lk-pick {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.lk-pick-group {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.015);
  overflow: hidden;
}
.lk-pick-group-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-pick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 10px;
  padding: 12px;
}
.lk-pick-grid-one {
  grid-template-columns: 1fr;
}

.lk-pick-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line2);
  border-radius: 7px;
  background: rgba(6, 21, 14, 0.55);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.lk-pick-card:hover {
  border-color: rgba(0, 232, 154, 0.4);
}
.lk-pick-card:has(input[type="radio"]:checked) {
  border-color: rgba(0, 232, 154, 0.65);
  background: rgba(0, 232, 154, 0.08);
}
.lk-pick-card:has(input[type="radio"]:focus-visible) {
  outline: 2px solid rgba(0, 232, 154, 0.6);
  outline-offset: 2px;
}
.lk-pick-card-main {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  cursor: pointer;
}
.lk-pick-card-main input[type="radio"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.lk-pick-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.lk-pick-idx {
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--dim2);
}
.lk-pick-go {
  color: var(--dim2);
  opacity: 0;
  transition: opacity 0.15s ease;
}
.lk-pick-card:hover .lk-pick-go,
.lk-pick-card:has(input:checked) .lk-pick-go {
  opacity: 1;
  color: var(--grn);
}
.lk-pick-name {
  font-size: 14px;
  color: var(--txt);
}
.lk-pick-desc {
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--dim);
}
.lk-pick-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--dim2);
}
.lk-pick-meta b {
  color: var(--grn);
  font-size: 12px;
}
.lk-pick-meta em {
  font-style: normal;
}

.lk-pick-product {
  margin: 0 12px 12px;
  width: calc(100% - 24px);
  padding: 9px 10px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  background: rgba(2, 8, 5, 0.5);
  color: var(--txt);
  font: inherit;
  font-size: 12.5px;
}
.lk-pick-product:focus {
  outline: none;
  border-color: rgba(0, 232, 154, 0.55);
}

.lk-pick-details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 232, 154, 0.015);
}
.lk-pick-details-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 14px;
}
.lk-pick-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
}
.lk-pick-field > span {
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.lk-pick-field textarea {
  width: 100%;
  min-height: 92px;
  padding: 10px 12px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  background: rgba(2, 8, 5, 0.5);
  color: var(--txt);
  font: inherit;
  font-size: 13px;
  line-height: 1.5;
  resize: vertical;
}
.lk-pick-field textarea:focus {
  outline: none;
  border-color: rgba(0, 232, 154, 0.55);
}

.lk-pick-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
}
.lk-pick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.lk-pick-chips label {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 7px 10px;
  border: 1px solid var(--line2);
  border-radius: 6px;
  background: rgba(2, 8, 5, 0.4);
  cursor: pointer;
}
.lk-pick-chips input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.lk-pick-chips span {
  font-size: 11.5px;
  color: var(--txt);
}
.lk-pick-chips em {
  font-style: normal;
  font-size: 9.5px;
  color: var(--dim2);
}
.lk-pick-chips label:hover {
  border-color: rgba(0, 232, 154, 0.4);
}
.lk-pick-chips label:has(input:checked) {
  border-color: rgba(0, 232, 154, 0.65);
  background: rgba(0, 232, 154, 0.08);
}
.lk-pick-chips label:has(input:focus-visible) {
  outline: 2px solid rgba(0, 232, 154, 0.6);
  outline-offset: 2px;
}

.lk-pick-submit {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding-top: 2px;
}
.lk-pick-submit-note {
  font-size: 10.5px;
  color: var(--dim2);
}

/* день */
body.day .lk-pick-group,
body.day .lk-pick-details {
  background: rgba(0, 121, 90, 0.02);
  border-color: rgba(0, 110, 80, 0.18);
}
body.day .lk-pick-group-head {
  border-bottom-color: rgba(0, 110, 80, 0.14);
}
body.day .lk-pick-card {
  background: #FFFFFF;
  border-color: rgba(0, 110, 80, 0.2);
}
body.day .lk-pick-card:hover {
  border-color: rgba(0, 110, 80, 0.45);
}
body.day .lk-pick-card:has(input:checked) {
  border-color: rgba(0, 110, 80, 0.6);
  background: rgba(0, 121, 90, 0.07);
}
body.day .lk-pick-name {
  color: #0B2B1E;
}
body.day .lk-pick-product,
body.day .lk-pick-field textarea,
body.day .lk-pick-chips label {
  background: #FFFFFF;
  border-color: rgba(0, 110, 80, 0.22);
  color: #0B2B1E;
}
body.day .lk-pick-chips span {
  color: #0B2B1E;
}

@media (max-width: 720px) {
  .lk-pick-grid,
  .lk-pick-row {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .lk-pick-page .lk-progress li {
    gap: 5px;
    padding: 6px 7px;
  }
  .lk-pick-page .lk-progress-n {
    width: 16px;
    height: 16px;
    font-size: 9px;
  }
  .lk-pick-page .lk-progress-t {
    display: none;
  }
  .lk-pick-page .lk-progress-t-short {
    display: inline;
    font-size: 9.5px;
  }
}

.lk-pick-submit-note a {
  color: var(--dim);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.lk-pick-submit-note a:hover {
  color: var(--grn);
}

/* ---------- печать: снимаем app-shell, чтобы заказ печатался целиком ---------- */
@media print {
  body.lk2-app {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }
  .lk2,
  .lk2-main,
  .lk2-content {
    display: block !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding-left: 0 !important;
  }
  .lk2-rail,
  .lk2-burger,
  .lk2-side,
  .lk2-scrim {
    display: none !important;
  }
  body.lk2-app .admin-page,
  body.lk2-app .order-page,
  body.lk2-app .admin-page-body,
  body.lk2-app .order-body {
    display: block !important;
    height: auto !important;
    overflow: visible !important;
  }
  body.lk2-app .order-status .order-pane-body,
  body.lk2-app .order-status-scroll,
  body.lk2-app .order-chatbox {
    display: block !important;
    max-height: none !important;
    overflow: visible !important;
  }
}