/* ==========================================================================
   DzivaProdTrek — дизайн-система прототипа
   Фирменные шрифты Gilroy · фирменная зелёная палитра · Apple-подход к UI
   ========================================================================== */

/* --- Шрифты ------------------------------------------------------------ */

@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Light.woff2') format('woff2');     font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Regular.woff2') format('woff2');   font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Medium.woff2') format('woff2');    font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Semibold.woff2') format('woff2');  font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Bold.woff2') format('woff2');      font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Extrabold.woff2') format('woff2'); font-weight: 800; font-style: normal; font-display: swap; }
@font-face { font-family: 'Gilroy'; src: url('/assets/fonts/Gilroy-Black.woff2') format('woff2');     font-weight: 900; font-style: normal; font-display: swap; }

/* --- Токены ------------------------------------------------------------ */

:root {
  /* Фирменные цвета DzivaProduct */
  --green-900: #214806;
  --green-800: #274C1D;
  --green-700: #37692A;
  --green-600: #518036;
  --green-500: #588847;
  --green-400: #88CA53;
  --green-300: #A1D42E;
  --green-vivid: #28C900;
  --ink: #252525;

  /* Поверхности */
  --bg: #F6F7F4;
  --surface: #FFFFFF;
  --surface-sunken: #FAFBF8;
  --surface-tint: #F1F6EC;

  /* Текст */
  --text: #252525;
  --text-2: #6C716C;
  --text-3: #9CA29C;
  --text-on-dark: #FFFFFF;
  --text-on-dark-2: rgba(255, 255, 255, 0.72);

  /* Линии */
  --line: rgba(37, 37, 37, 0.08);
  --line-strong: rgba(37, 37, 37, 0.14);
  --line-on-dark: rgba(255, 255, 255, 0.16);

  /* Статусы */
  --warn: #C98A16;
  --warn-bg: #FDF6E7;
  --danger: #C7412F;
  --danger-bg: #FCEFEC;
  --ok: #2E7D32;
  --ok-bg: #ECF6EC;

  /* Скругления */
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-2xl: 32px;
  --r-full: 999px;

  /* Тени */
  --shadow-1: 0 1px 2px rgba(37, 37, 37, 0.05), 0 1px 1px rgba(37, 37, 37, 0.03);
  --shadow-2: 0 6px 20px -8px rgba(37, 37, 37, 0.14), 0 1px 3px rgba(37, 37, 37, 0.05);
  --shadow-3: 0 28px 60px -24px rgba(39, 76, 29, 0.30), 0 4px 12px -4px rgba(37, 37, 37, 0.08);
  --shadow-green: 0 10px 24px -10px rgba(81, 128, 54, 0.55);

  /* Движение (кривая из Apple HIG) */
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --t-fast: 160ms;
  --t: 260ms;
  --t-slow: 480ms;

  /* Сетка */
  --sidebar-w: 264px;
  --gap: 24px;
}

/* --- Сброс ------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Gilroy', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', system-ui, sans-serif;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, figure { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; padding: 0; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--green-600);
  outline-offset: 2px;
  border-radius: 6px;
}

::selection { background: rgba(136, 202, 83, 0.32); }

/* Скроллбары — тонкие, в стиле macOS */
* { scrollbar-width: thin; scrollbar-color: rgba(37, 37, 37, 0.18) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb {
  background: rgba(37, 37, 37, 0.16);
  border-radius: var(--r-full);
  border: 3px solid transparent;
  background-clip: content-box;
}
*::-webkit-scrollbar-thumb:hover { background: rgba(37, 37, 37, 0.28); background-clip: content-box; }

/* --- Типографика ------------------------------------------------------- */

.t-display { font-size: 42px; line-height: 1.06; font-weight: 800; letter-spacing: -0.032em; }
.t-title1  { font-size: 29px; line-height: 1.15; font-weight: 700; letter-spacing: -0.026em; }
.t-title2  { font-size: 22px; line-height: 1.25; font-weight: 700; letter-spacing: -0.022em; }
.t-title3  { font-size: 18px; line-height: 1.32; font-weight: 600; letter-spacing: -0.016em; }
.t-headline{ font-size: 16px; line-height: 1.4;  font-weight: 600; letter-spacing: -0.012em; }
.t-body    { font-size: 15px; line-height: 1.52; font-weight: 500; }
.t-callout { font-size: 14px; line-height: 1.45; font-weight: 500; }
.t-caption { font-size: 12.5px; line-height: 1.4; font-weight: 500; letter-spacing: 0; }
.t-overline {
  font-size: 11px; font-weight: 700; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--text-3);
}
.t-num { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }

.muted  { color: var(--text-2); }
.muted-2{ color: var(--text-3); }
.accent { color: var(--green-600); }

/* --- Кнопки ------------------------------------------------------------ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 18px;
  border-radius: var(--r-full);
  font-size: 14.5px; font-weight: 600; letter-spacing: -0.01em;
  white-space: nowrap;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease), box-shadow var(--t) var(--ease), opacity var(--t-fast);
}
.btn:active { transform: scale(0.97); }
.btn[disabled] { opacity: 0.4; pointer-events: none; }
.btn svg { width: 17px; height: 17px; flex: none; }

.btn--primary {
  background: var(--green-600); color: #fff;
  box-shadow: var(--shadow-green);
}
.btn--primary:hover { background: var(--green-700); }

.btn--secondary {
  background: rgba(37, 37, 37, 0.05); color: var(--text);
}
.btn--secondary:hover { background: rgba(37, 37, 37, 0.09); }

.btn--ghost { background: transparent; color: var(--text-2); }
.btn--ghost:hover { background: rgba(37, 37, 37, 0.05); color: var(--text); }

.btn--outline { background: var(--surface); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-strong); }
.btn--outline:hover { background: var(--surface-sunken); }

.btn--onDark { background: rgba(255, 255, 255, 0.14); color: #fff; backdrop-filter: blur(12px); }
.btn--onDark:hover { background: rgba(255, 255, 255, 0.22); }

.btn--lg { height: 48px; padding: 0 26px; font-size: 16px; border-radius: var(--r-full); }
.btn--sm { height: 32px; padding: 0 14px; font-size: 13px; }
.btn--block { width: 100%; }

.btn--icon { width: 38px; height: 38px; padding: 0; border-radius: var(--r-full); }

/* --- Чипы и бейджи ----------------------------------------------------- */

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 11px;
  border-radius: var(--r-full);
  background: rgba(37, 37, 37, 0.05);
  font-size: 12.5px; font-weight: 600; color: var(--text-2);
  letter-spacing: -0.005em; white-space: nowrap;
}
.chip--green   { background: var(--surface-tint); color: var(--green-700); }
.chip--warn    { background: var(--warn-bg); color: var(--warn); }
.chip--danger  { background: var(--danger-bg); color: var(--danger); }
.chip--ok      { background: var(--ok-bg); color: var(--ok); }
.chip--onDark  { background: rgba(255, 255, 255, 0.16); color: #fff; }

.chip svg { width: 13px; height: 13px; flex: none; }

.dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.dot--pulse { animation: pulse 2s var(--ease) infinite; }

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.82); }
}

/* --- Карточки ---------------------------------------------------------- */

.card {
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1);
}
.card--pad { padding: 22px; }
.card--raised { box-shadow: var(--shadow-2); }

/* --- Аватар ------------------------------------------------------------ */

.avatar {
  display: grid; place-items: center; flex: none;
  width: 36px; height: 36px; border-radius: var(--r-full);
  background: linear-gradient(140deg, var(--green-500), var(--green-800));
  color: #fff; font-size: 13px; font-weight: 700; letter-spacing: 0.01em;
}
.avatar--lg { width: 44px; height: 44px; font-size: 15px; }

/* --- Поля ввода -------------------------------------------------------- */

.field { display: grid; gap: 7px; }
.field label { font-size: 13px; font-weight: 600; color: var(--text-2); }
.input {
  height: 48px; padding: 0 16px;
  background: var(--surface-sunken);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 15px; font-weight: 500;
  transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease), box-shadow var(--t-fast);
}
.input::placeholder { color: var(--text-3); }
.input:focus {
  outline: none; background: var(--surface);
  border-color: var(--green-500);
  box-shadow: 0 0 0 4px rgba(88, 136, 71, 0.14);
}

/* --- Сегментированный контрол (iOS-стиль) ------------------------------ */

.segmented {
  display: inline-flex; gap: 2px; padding: 3px;
  background: rgba(37, 37, 37, 0.055);
  border-radius: var(--r-full);
}
.segmented button {
  height: 32px; padding: 0 15px;
  border-radius: var(--r-full);
  font-size: 13.5px; font-weight: 600; color: var(--text-2);
  transition: all var(--t-fast) var(--ease);
}
.segmented button:hover { color: var(--text); }
.segmented button[aria-selected='true'] {
  background: var(--surface); color: var(--text);
  box-shadow: var(--shadow-1);
}

/* --- Прогресс ---------------------------------------------------------- */

.progress {
  position: relative; height: 6px; border-radius: var(--r-full);
  background: rgba(37, 37, 37, 0.08); overflow: hidden;
}
.progress > i {
  position: absolute; inset: 0 auto 0 0;
  border-radius: var(--r-full);
  background: linear-gradient(90deg, var(--green-600), var(--green-400));
  transition: width var(--t-slow) var(--ease);
}
.progress--onDark { background: rgba(255, 255, 255, 0.2); }
.progress--onDark > i { background: linear-gradient(90deg, var(--green-300), #fff); }

/* ==========================================================================
   Экран входа
   ========================================================================== */

.login {
  display: grid; grid-template-columns: 1.05fr 1fr;
  min-height: 100vh;
}

.login__brand {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 48px;
  background-color: var(--green-900);
  color: #fff;
}

/* Фотография производства */
.login__brand::before {
  content: ''; position: absolute; inset: 0;
  background-image: url('/assets/img/login-cover.webp');
  background-size: cover;
  background-position: 58% center;
  transform: scale(1.02);
}

/* Оверлей: тонирует фото в фирменный зелёный и гарантирует контраст текста.
   Верх притемнён под логотип, низ — плотнее, под заголовок и описание. */
.login__brand::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(180deg,
      rgba(20, 40, 8, 0.78) 0%,
      rgba(20, 40, 8, 0.42) 22%,
      rgba(24, 48, 10, 0.62) 52%,
      rgba(20, 40, 8, 0.93) 82%,
      rgba(16, 33, 6, 0.97) 100%),
    linear-gradient(120deg, rgba(39, 76, 29, 0.72) 0%, rgba(33, 72, 6, 0.34) 55%, rgba(33, 72, 6, 0.62) 100%);
}
.login__brand > * { position: relative; z-index: 1; }
.login__logo { height: 34px; width: auto; }
.login__pitch { max-width: 460px; }
.login__pitch h1 {
  font-size: 40px; line-height: 1.1; font-weight: 800; letter-spacing: -0.032em;
  text-shadow: 0 2px 28px rgba(0, 0, 0, 0.45);
}
.login__pitch p {
  margin-top: 16px; font-size: 16.5px; line-height: 1.55; color: rgba(255, 255, 255, 0.86);
  text-shadow: 0 1px 16px rgba(0, 0, 0, 0.5);
}
.login__logo { filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.4)); }
.login__features .chip--onDark {
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.login__features { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 28px; }

.login__form {
  display: grid; place-items: center; padding: 48px;
  background: var(--surface);
}
.login__inner { width: 100%; max-width: 372px; }

.login__accounts { display: grid; gap: 10px; margin-top: 12px; }
.login__account {
  display: flex; align-items: center; gap: 13px;
  padding: 13px 15px; text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: all var(--t-fast) var(--ease);
}
.login__account:hover {
  border-color: var(--green-400);
  background: var(--surface-tint);
  transform: translateY(-1px);
  box-shadow: var(--shadow-2);
}
.login__account strong { display: block; font-size: 14px; font-weight: 600; }
.login__account span { font-size: 12.5px; color: var(--text-2); }

.divider {
  display: flex; align-items: center; gap: 14px;
  margin: 26px 0; color: var(--text-3); font-size: 12px; font-weight: 600;
}
.divider::before, .divider::after {
  content: ''; flex: 1; height: 1px; background: var(--line);
}

.error-msg {
  margin-top: 14px; padding: 11px 14px;
  background: var(--danger-bg); color: var(--danger);
  border-radius: var(--r-sm); font-size: 13.5px; font-weight: 600;
}

/* ==========================================================================
   Каркас приложения менеджера
   ========================================================================== */

/* Высота фиксирована по экрану: список заказов и карточка прокручиваются независимо */
.app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; height: 100vh; }

.sidebar {
  display: flex; flex-direction: column;
  padding: 24px 16px 18px;
  background: var(--surface);
  border-right: 1px solid var(--line);
  position: sticky; top: 0; height: 100vh;
}
.sidebar__logo { padding: 0 10px 26px; }
.sidebar__logo img { height: 28px; width: auto; }

.nav { display: grid; gap: 2px; }
.nav__label { padding: 16px 12px 7px; }
.nav a {
  display: flex; align-items: center; gap: 11px;
  height: 40px; padding: 0 12px;
  border-radius: var(--r-sm);
  font-size: 14.5px; font-weight: 600; color: var(--text-2);
  transition: all var(--t-fast) var(--ease);
}
.nav a svg { width: 18px; height: 18px; flex: none; opacity: 0.75; }
.nav a:hover { background: rgba(37, 37, 37, 0.045); color: var(--text); }
.nav a.is-active {
  background: var(--surface-tint); color: var(--green-700);
}
.nav a.is-active svg { opacity: 1; }
.nav a .count {
  margin-left: auto; font-size: 12px; font-weight: 700; color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.sidebar__user {
  display: flex; align-items: center; gap: 11px;
  margin-top: auto; padding: 12px 10px 0;
  border-top: 1px solid var(--line);
}
.sidebar__user .name { font-size: 14px; font-weight: 600; line-height: 1.25; }
.sidebar__user .role { font-size: 12px; color: var(--text-3); line-height: 1.3; }

.main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }

.topbar {
  display: flex; align-items: center; gap: 16px;
  height: 68px; padding: 0 28px;
  background: rgba(246, 247, 244, 0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.topbar__spacer { flex: 1; }

.search {
  position: relative; width: 300px;
}
.search svg {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  width: 16px; height: 16px; color: var(--text-3); pointer-events: none;
}
.search input {
  width: 100%; height: 38px; padding: 0 14px 0 37px;
  background: rgba(37, 37, 37, 0.05);
  border: 1px solid transparent; border-radius: var(--r-full);
  font-size: 14px; font-weight: 500;
  transition: all var(--t-fast) var(--ease);
}
.search input::placeholder { color: var(--text-3); }
.search input:focus {
  outline: none; background: var(--surface);
  border-color: var(--green-400);
  box-shadow: 0 0 0 4px rgba(136, 202, 83, 0.16);
}

/* --- Рабочая область: список + карточка -------------------------------- */

.workspace {
  display: grid; grid-template-columns: 396px 1fr;
  flex: 1; min-height: 0;
}

.orders {
  display: flex; flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--surface-sunken);
  min-height: 0;
}
.orders__head {
  display: flex; align-items: center; gap: 10px;
  padding: 20px 20px 14px;
}
.orders__list { flex: 1; overflow-y: auto; padding: 0 12px 20px; display: grid; gap: 8px; align-content: start; }

.order-card {
  position: relative; display: grid; gap: 11px;
  padding: 15px 16px; text-align: left; width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: all var(--t-fast) var(--ease);
}
.order-card:hover { border-color: var(--line-strong); transform: translateY(-1px); box-shadow: var(--shadow-2); }
.order-card.is-active {
  border-color: var(--green-500);
  box-shadow: 0 0 0 3px rgba(88, 136, 71, 0.13), var(--shadow-2);
}
.order-card__top { display: flex; align-items: center; gap: 8px; }
.order-card__num { font-size: 11.5px; font-weight: 700; color: var(--text-3); letter-spacing: 0.03em; font-variant-numeric: tabular-nums; }
.order-card__title { font-size: 15.5px; font-weight: 700; letter-spacing: -0.018em; line-height: 1.25; }
.order-card__brand { font-size: 13px; font-weight: 500; color: var(--text-2); margin-top: 2px; }
.order-card__meta { display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--text-2); }
.order-card__stage { display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; color: var(--green-700); }

/* --- Детальная карточка заказа ----------------------------------------- */

.detail { overflow-y: auto; min-height: 0; padding: 26px 30px 40px; }
.detail__inner { max-width: 880px; margin: 0 auto; display: grid; gap: 18px; }

.detail__head { display: grid; gap: 14px; }
.detail__crumbs { display: flex; align-items: center; gap: 9px; }
.detail__title { display: flex; align-items: flex-start; gap: 16px; }
.detail__title h1 { font-size: 30px; line-height: 1.12; font-weight: 800; letter-spacing: -0.03em; }

.facts {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--surface); border-radius: var(--r-lg);
  box-shadow: var(--shadow-1); overflow: hidden;
}
.fact { padding: 16px 18px; border-right: 1px solid var(--line); }
.fact:last-child { border-right: none; }
.fact dt { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.fact dd { margin: 5px 0 0; font-size: 15.5px; font-weight: 600; letter-spacing: -0.014em; }

/* Панель текущего этапа — главный акцент экрана */
.stage-panel {
  position: relative; overflow: hidden;
  padding: 24px 26px;
  border-radius: var(--r-xl);
  background: linear-gradient(140deg, #2F5C23 0%, var(--green-800) 52%, var(--green-900) 100%);
  color: #fff;
  box-shadow: var(--shadow-3);
}
.stage-panel::after {
  content: ''; position: absolute; width: 420px; height: 420px;
  right: -140px; top: -200px; border-radius: 50%;
  background: radial-gradient(circle, rgba(161, 212, 46, 0.28), transparent 62%);
  pointer-events: none;
}
.stage-panel > * { position: relative; z-index: 1; }
.stage-panel__row { display: flex; align-items: flex-end; gap: 24px; }
.stage-panel__now { flex: 1; min-width: 0; }
.stage-panel__now h2 { font-size: 27px; font-weight: 700; letter-spacing: -0.026em; line-height: 1.15; margin-top: 8px; }
.stage-panel__now p { margin-top: 7px; font-size: 14px; color: var(--text-on-dark-2); }
.stage-panel__progress { margin-top: 22px; display: grid; gap: 9px; }
.stage-panel__progress .row { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--text-on-dark-2); font-weight: 600; }
.stage-panel__actions { display: flex; gap: 10px; margin-top: 22px; }

.mirror {
  display: flex; align-items: center; gap: 10px;
  margin-top: 18px; padding: 12px 15px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--line-on-dark);
  border-radius: var(--r-md);
  font-size: 13px; color: #fff;
}
.mirror svg { width: 17px; height: 17px; flex: none; opacity: 0.85; }
.mirror b { font-weight: 700; }

/* --- Маршрут (степпер) -------------------------------------------------- */

.route { padding: 6px 0; }
.route__head { display: flex; align-items: center; gap: 12px; padding: 18px 22px 6px; }
.route__head h3 { white-space: nowrap; }
.route__head .hint { text-align: right; }
@media (max-width: 1500px) { .route__head .hint { display: none; } }

.step {
  position: relative; display: grid;
  grid-template-columns: 34px 1fr auto; gap: 14px; align-items: start;
  padding: 11px 22px;
  transition: background var(--t-fast) var(--ease);
}
.step + .step { margin-top: -2px; }
.step__marker { position: relative; display: grid; place-items: center; padding-top: 1px; }
.step__bullet {
  width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--surface); border: 2px solid var(--line-strong);
  color: #fff; transition: all var(--t) var(--ease); z-index: 1;
}
.step__bullet svg { width: 12px; height: 12px; }
.step:not(:last-child) .step__marker::after {
  content: ''; position: absolute; top: 24px; bottom: -24px; left: 50%;
  width: 2px; margin-left: -1px; background: var(--line-strong);
}
.step__title { font-size: 14.5px; font-weight: 600; letter-spacing: -0.012em; }
.step__dept  { font-size: 12.5px; color: var(--text-3); margin-top: 1px; }
.step__date  { font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; white-space: nowrap; padding-top: 2px; }

.step.is-done .step__bullet { background: var(--green-600); border-color: var(--green-600); }
.step.is-done .step__marker::after { background: var(--green-400); }
.step.is-done .step__title { color: var(--text-2); }

.step.is-current { background: var(--surface-tint); }
.step.is-current .step__bullet {
  background: #fff; border-color: var(--green-600);
  box-shadow: 0 0 0 5px rgba(136, 202, 83, 0.22);
}
.step.is-current .step__bullet i {
  width: 8px; height: 8px; border-radius: 50%; background: var(--green-600);
  animation: pulse 2s var(--ease) infinite;
}
.step.is-current .step__title { font-weight: 700; color: var(--green-800); }

.step.is-todo .step__title { color: var(--text-3); }

/* Разделители клиентских этапов внутри маршрута */
.route__group {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 22px 6px;
}
.route__group span { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.route__group i { flex: 1; height: 1px; background: var(--line); }

/* --- Секции ------------------------------------------------------------ */

.section__head {
  display: flex; align-items: center; gap: 12px;
  padding: 18px 22px 12px;
}
.doc-row {
  display: flex; align-items: center; gap: 13px;
  padding: 13px 22px; border-top: 1px solid var(--line);
  transition: background var(--t-fast) var(--ease);
}
.doc-row:hover { background: var(--surface-sunken); }
.doc-row__icon {
  display: grid; place-items: center; width: 34px; height: 34px; flex: none;
  border-radius: var(--r-sm); background: var(--surface-tint); color: var(--green-700);
}
.doc-row__icon svg { width: 17px; height: 17px; }
.doc-row__name { font-size: 14px; font-weight: 600; }
.doc-row__meta { font-size: 12px; color: var(--text-3); }

/* ==========================================================================
   Личный кабинет клиента
   ========================================================================== */

.portal { min-height: 100vh; background: var(--surface); }

.portal__bar {
  display: flex; align-items: center; gap: 16px;
  height: 72px; padding: 0 40px;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 30;
}
.portal__bar img { height: 26px; width: auto; }
.portal__bar .sep { width: 1px; height: 22px; background: var(--line-strong); }

.portal__wrap { max-width: 1120px; margin: 0 auto; padding: 40px 40px 80px; }

.portal__hello { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.portal__hello h1 { font-size: 34px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.portal__hello p { margin-top: 8px; font-size: 16px; color: var(--text-2); }

/* Главная карточка активного заказа */
.hero {
  position: relative; overflow: hidden;
  border-radius: var(--r-2xl);
  background: linear-gradient(145deg, #325F25 0%, var(--green-800) 50%, var(--green-900) 100%);
  color: #fff; padding: 34px 38px 32px;
  box-shadow: var(--shadow-3);
}
.hero::before {
  content: ''; position: absolute; width: 620px; height: 620px;
  right: -200px; top: -280px; border-radius: 50%;
  background: radial-gradient(circle, rgba(161, 212, 46, 0.26), transparent 62%);
}
.hero > * { position: relative; z-index: 1; }
.hero__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
.hero__title { font-size: 32px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; margin-top: 10px; }
.hero__sub { margin-top: 9px; font-size: 15px; color: var(--text-on-dark-2); }

.ring { position: relative; flex: none; width: 116px; height: 116px; }
.ring svg { transform: rotate(-90deg); width: 116px; height: 116px; }
.ring circle { fill: none; stroke-linecap: round; }
.ring .track { stroke: rgba(255, 255, 255, 0.18); stroke-width: 9; }
.ring .bar {
  stroke: url(#ringGrad); stroke-width: 9;
  transition: stroke-dashoffset 900ms var(--ease);
}
.ring__label {
  position: absolute; inset: 0; display: grid; place-items: center; text-align: center;
}
.ring__label b { display: block; font-size: 27px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.ring__label span { font-size: 10.5px; font-weight: 600; color: var(--text-on-dark-2); letter-spacing: 0.04em; }

/* Клиентский таймлайн из 7 этапов */
.timeline {
  display: grid; grid-template-columns: repeat(7, 1fr);
  margin-top: 34px; padding-top: 30px;
  border-top: 1px solid var(--line-on-dark);
}
.tl {
  position: relative; padding-right: 12px;
}
.tl__dot {
  position: relative; z-index: 1;
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.16);
  border: 2px solid transparent;
  transition: all var(--t) var(--ease);
}
.tl__dot svg { width: 13px; height: 13px; color: var(--green-900); }
.tl:not(:last-child)::before {
  content: ''; position: absolute; left: 26px; right: 0; top: 13px; height: 2px;
  background: rgba(255, 255, 255, 0.18);
}
.tl.is-done .tl__dot { background: var(--green-300); }
.tl.is-done::before { background: var(--green-300); }
.tl.is-current .tl__dot {
  background: #fff; border-color: rgba(255, 255, 255, 0.45);
  box-shadow: 0 0 0 7px rgba(255, 255, 255, 0.14);
}
.tl.is-current .tl__dot i {
  width: 9px; height: 9px; border-radius: 50%; background: var(--green-700);
  animation: pulse 2s var(--ease) infinite;
}
.tl__title {
  margin-top: 13px; min-height: 36px;
  font-size: 13px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.32;
  color: rgba(255, 255, 255, 0.55);
}
.tl__date { margin-top: 3px; font-size: 11.5px; color: rgba(255, 255, 255, 0.42); font-variant-numeric: tabular-nums; }
.tl.is-done .tl__title, .tl.is-current .tl__title { color: #fff; }
.tl.is-current .tl__date { color: var(--green-300); }

.hero__foot {
  display: flex; align-items: center; gap: 22px;
  margin-top: 30px; padding-top: 22px;
  border-top: 1px solid var(--line-on-dark);
}
.hero__stat span { display: block; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(255, 255, 255, 0.5); }
.hero__stat b { display: block; margin-top: 5px; font-size: 16px; font-weight: 700; letter-spacing: -0.016em; }

/* Список заказов клиента */
.portal__section { margin-top: 46px; }
.portal__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; margin-top: 18px; }

.p-card {
  display: grid; gap: 14px; text-align: left; padding: 22px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg);
  transition: all var(--t) var(--ease);
}
.p-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: var(--green-400); }
.p-card.is-active { border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(88, 136, 71, 0.12); }
.p-card__title { font-size: 17px; font-weight: 700; letter-spacing: -0.02em; }
.p-card__row { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--text-2); }

/* --- Тост -------------------------------------------------------------- */

.toasts {
  position: fixed; right: 26px; bottom: 26px; z-index: 100;
  display: grid; gap: 10px; justify-items: end;
}
.toast {
  display: flex; align-items: center; gap: 13px;
  min-width: 300px; max-width: 420px; padding: 15px 19px;
  background: rgba(37, 37, 37, 0.94);
  backdrop-filter: blur(20px);
  color: #fff; border-radius: var(--r-lg);
  box-shadow: 0 20px 44px -16px rgba(0, 0, 0, 0.45);
  animation: toast-in 460ms var(--ease-out) both;
}
.toast.is-leaving { animation: toast-out 300ms var(--ease) both; }
.toast__icon {
  display: grid; place-items: center; width: 34px; height: 34px; flex: none;
  border-radius: 50%; background: var(--green-vivid); color: #fff;
}
.toast__icon svg { width: 18px; height: 18px; }
.toast strong { display: block; font-size: 14.5px; font-weight: 700; letter-spacing: -0.012em; }
.toast span { display: block; font-size: 13px; color: rgba(255, 255, 255, 0.66); margin-top: 1px; }

@keyframes toast-in {
  from { opacity: 0; transform: translateY(18px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateY(10px) scale(0.97); }
}

/* --- Подсветка обновления ---------------------------------------------- */

@keyframes flash {
  0%   { box-shadow: var(--shadow-3), 0 0 0 0 rgba(161, 212, 46, 0.6); }
  60%  { box-shadow: var(--shadow-3), 0 0 0 16px rgba(161, 212, 46, 0); }
  100% { box-shadow: var(--shadow-3), 0 0 0 0 rgba(161, 212, 46, 0); }
}
.is-flashing { animation: flash 1400ms var(--ease-out); }

@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
.rise { animation: rise 420ms var(--ease-out) both; }

/* --- Индикатор соединения ---------------------------------------------- */

.live {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 600; color: var(--text-3);
}
.live i { width: 7px; height: 7px; border-radius: 50%; background: var(--green-vivid); }
.live.is-live i { animation: pulse 2.4s var(--ease) infinite; }
.live.is-off i { background: var(--text-3); animation: none; }

/* --- Пустое состояние -------------------------------------------------- */

.empty { display: grid; place-items: center; gap: 10px; padding: 80px 20px; text-align: center; color: var(--text-3); }

/* ==========================================================================
   Разделы менеджера: общие блоки
   ========================================================================== */

.view { flex: 1; overflow-y: auto; min-height: 0; padding: 26px 30px 48px; }
.view__inner { max-width: 1240px; margin: 0 auto; display: grid; gap: 20px; }
.view__head { display: flex; align-items: flex-end; gap: 16px; }
.view__head p { margin-top: 6px; }

.row-gap { display: grid; gap: 14px; }
.flex { display: flex; align-items: center; gap: 12px; }
.flex-1 { flex: 1; }

/* Плитки показателей */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.stat {
  padding: 18px 20px; background: var(--surface);
  border-radius: var(--r-lg); box-shadow: var(--shadow-1);
}
.stat span { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.stat b { display: block; margin-top: 7px; font-size: 30px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.stat em { display: block; margin-top: 7px; font-size: 12.5px; font-style: normal; color: var(--text-2); }
.stat--accent { background: linear-gradient(140deg, var(--green-700), var(--green-900)); color: #fff; }
.stat--accent span, .stat--accent em { color: rgba(255, 255, 255, 0.66); }

/* Таблица */
.table-card { background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; }
.table { width: 100%; border-collapse: collapse; }
.table th {
  padding: 13px 18px; text-align: left; white-space: nowrap;
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-3); background: var(--surface-sunken);
  border-bottom: 1px solid var(--line);
}
.table td { padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 14px; vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: none; }
.table tbody tr { transition: background var(--t-fast) var(--ease); }
.table tbody tr:hover { background: var(--surface-sunken); }
.table .strong { font-weight: 600; }

/* Доска производства */
.board { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; }
.board__col { background: rgba(37, 37, 37, 0.035); border-radius: var(--r-lg); padding: 10px; display: grid; gap: 8px; align-content: start; min-width: 0; }
.board__head { display: flex; align-items: center; gap: 6px; padding: 3px 5px 1px; }
.board__head b { font-size: 12px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; }
.board__head span { margin-left: auto; font-size: 11.5px; font-weight: 700; color: var(--text-3); }
.bcard {
  display: grid; gap: 7px; padding: 11px 12px; text-align: left; width: 100%; min-width: 0;
  background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-1);
  transition: all var(--t-fast) var(--ease);
}
.bcard:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }
.bcard__title { font-size: 13px; font-weight: 700; letter-spacing: -0.014em; line-height: 1.25; }
.bcard__meta { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--text-2); min-width: 0; }
.bcard__meta > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Диаграмма загрузки цехов */
.gantt { background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; }
.gantt__row { display: grid; grid-template-columns: 196px 1fr; border-bottom: 1px solid var(--line); }
.gantt__row:last-child { border-bottom: none; }
.gantt__row--head { background: var(--surface-sunken); }
.gantt__side { padding: 14px 18px; border-right: 1px solid var(--line); }
.gantt__side b { display: block; font-size: 14px; font-weight: 700; letter-spacing: -0.014em; }
.gantt__side span { display: block; margin-top: 2px; font-size: 12px; line-height: 1.35; color: var(--text-3); }
.gantt__side span + span { font-size: 11px; color: var(--text-3); opacity: 0.8; }
.gantt__track { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; min-height: 78px; }
.gantt__cell { border-left: 1px solid var(--line); }
.gantt__cell--weekend { background: rgba(37, 37, 37, 0.028); }
.gantt__cell--today { background: rgba(136, 202, 83, 0.12); }
.gantt__day { padding: 11px 0 10px; text-align: center; border-left: 1px solid var(--line); }
.gantt__day b { display: block; font-size: 13px; font-weight: 700; letter-spacing: -0.01em; }
.gantt__day span { display: block; font-size: 10.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-3); margin-top: 1px; }
.gantt__day.is-today b { color: var(--green-700); }
.gantt__bar {
  position: absolute; top: 14px; height: 38px;
  display: flex; align-items: center; gap: 8px; padding: 0 12px;
  border-radius: 10px; overflow: hidden; white-space: nowrap;
  font-size: 12.5px; font-weight: 600; color: #fff;
  background: linear-gradient(135deg, var(--green-600), var(--green-500));
  box-shadow: var(--shadow-1);
  transition: transform var(--t-fast) var(--ease);
}
.gantt__bar:hover { transform: translateY(-1px); z-index: 3; }
.gantt__bar--planned { background: var(--surface-tint); color: var(--green-800); box-shadow: inset 0 0 0 1px var(--green-400); }
.gantt__bar--done { background: rgba(37, 37, 37, 0.09); color: var(--text-2); }
.gantt__bar--service {
  background: repeating-linear-gradient(45deg, #EDF0EA, #EDF0EA 7px, #E2E7DE 7px, #E2E7DE 14px);
  color: var(--text-2);
}
.gantt__now { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--green-vivid); z-index: 2; pointer-events: none; }
.gantt__now::before {
  content: ''; position: absolute; top: -4px; left: -3px;
  width: 8px; height: 8px; border-radius: 50%; background: var(--green-vivid);
}

/* Очередь контроля качества */
.qc {
  display: grid; grid-template-columns: 44px 1fr auto; gap: 15px; align-items: center;
  padding: 17px 22px; border-bottom: 1px solid var(--line);
}
.qc:last-child { border-bottom: none; }
.qc__icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--r-md); background: var(--surface-tint); color: var(--green-700); }
.qc__icon svg { width: 20px; height: 20px; }
.qc__icon--warn { background: var(--warn-bg); color: var(--warn); }
.qc__title { font-size: 15px; font-weight: 700; letter-spacing: -0.016em; }
.qc__detail { font-size: 13px; color: var(--text-2); margin-top: 2px; }
.qc__checks { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.qc__checks .chip { height: 22px; font-size: 11.5px; padding: 0 9px; }

/* Карточки клиентов */
.companies { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.company { padding: 22px; background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-1); display: grid; gap: 16px; text-align: left; transition: all var(--t) var(--ease); }
.company:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }
.company__logo {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--r-md);
  background: linear-gradient(140deg, var(--green-500), var(--green-800));
  color: #fff; font-size: 16px; font-weight: 800;
}
.company__nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding-top: 14px; border-top: 1px solid var(--line); }
.company__nums div span { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-3); }
.company__nums div b { display: block; margin-top: 3px; font-size: 16px; font-weight: 700; letter-spacing: -0.018em; }

/* Рецептуры */
.formulation__head { display: flex; align-items: center; gap: 12px; padding: 18px 22px 14px; border-bottom: 1px solid var(--line); }
.bom-total { display: flex; align-items: center; gap: 14px; padding: 14px 22px; background: var(--surface-sunken); font-size: 13px; }
.bom-total svg { width: 18px; height: 18px; flex: none; color: var(--green-600); }

/* ==========================================================================
   Модальное окно и мастер создания заказа
   ========================================================================== */

.backdrop {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center; padding: 32px;
  background: rgba(22, 30, 18, 0.42);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  animation: fade 240ms var(--ease) both;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.modal {
  width: min(900px, 100%); max-height: 88vh;
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); border-radius: var(--r-2xl);
  box-shadow: 0 48px 96px -32px rgba(0, 0, 0, 0.45);
  animation: modal-in 380ms var(--ease-out) both;
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(22px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal__head { padding: 24px 30px 20px; border-bottom: 1px solid var(--line); }
.modal__body { flex: 1; overflow-y: auto; padding: 28px 30px; }
.modal__foot { display: flex; align-items: center; gap: 12px; padding: 18px 30px; border-top: 1px solid var(--line); background: var(--surface-sunken); }

/* Шаги мастера */
.wsteps { display: flex; align-items: center; gap: 10px; margin-top: 18px; }
.wstep { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 600; color: var(--text-3); white-space: nowrap; }
.wstep i {
  display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%;
  background: rgba(37, 37, 37, 0.07); font-size: 11.5px; font-style: normal; font-weight: 700;
  transition: all var(--t) var(--ease);
}
.wstep i svg { width: 12px; height: 12px; }
.wstep.is-done { color: var(--green-700); }
.wstep.is-done i { background: var(--surface-tint); color: var(--green-700); }
.wstep.is-active { color: var(--green-800); }
.wstep.is-active i { background: var(--green-600); color: #fff; box-shadow: 0 0 0 4px rgba(136, 202, 83, 0.22); }
.wsep { flex: 1; height: 1px; background: var(--line); }

/* Карточки-переключатели вместо радиокнопок */
.choices { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.choice {
  display: grid; gap: 3px; padding: 14px 16px; text-align: left;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  transition: all var(--t-fast) var(--ease);
}
.choice:hover { border-color: var(--green-400); background: var(--surface-tint); }
.choice.is-on { border-color: var(--green-600); background: var(--surface-tint); box-shadow: 0 0 0 3px rgba(88, 136, 71, 0.13); }
.choice b { font-size: 14.5px; font-weight: 700; letter-spacing: -0.014em; }
.choice span { font-size: 12.5px; color: var(--text-2); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }

/* Итоговая сводка мастера */
.summary { background: var(--surface-sunken); border-radius: var(--r-lg); padding: 20px 22px; display: grid; gap: 12px; }
.summary__row { display: flex; align-items: baseline; gap: 14px; font-size: 14px; }
.summary__row dt { width: 190px; flex: none; color: var(--text-2); font-size: 13px; }
.summary__row dd { margin: 0; font-weight: 600; }

/* ==========================================================================
   Чат
   ========================================================================== */

.chat { display: flex; flex-direction: column; min-height: 0; }
.chat__feed {
  flex: 1; overflow-y: auto; padding: 20px 22px;
  display: grid; gap: 14px; align-content: start;
  max-height: 440px;
}
.chat__day { justify-self: center; font-size: 11.5px; font-weight: 700; color: var(--text-3); padding: 3px 12px; background: rgba(37, 37, 37, 0.045); border-radius: var(--r-full); }

.msg { display: grid; gap: 5px; max-width: 78%; animation: rise 320ms var(--ease-out) both; }
.msg__bubble {
  padding: 11px 15px; border-radius: 18px;
  font-size: 14.5px; line-height: 1.45; font-weight: 500;
}
.msg__meta { font-size: 11.5px; color: var(--text-3); }

.msg--in .msg__bubble { background: rgba(37, 37, 37, 0.055); border-bottom-left-radius: 6px; }
.msg--out { justify-self: end; }
.msg--out .msg__bubble {
  background: linear-gradient(135deg, var(--green-600), var(--green-500));
  color: #fff; border-bottom-right-radius: 6px;
}
.msg--out .msg__meta { text-align: right; }

.chat__composer { display: flex; gap: 10px; align-items: center; padding: 14px 18px; border-top: 1px solid var(--line); }
.chat__composer input {
  flex: 1; height: 44px; padding: 0 16px;
  background: var(--surface-sunken); border: 1px solid var(--line); border-radius: var(--r-full);
  font-size: 14.5px; font-weight: 500;
  transition: all var(--t-fast) var(--ease);
}
.chat__composer input:focus {
  outline: none; background: var(--surface); border-color: var(--green-500);
  box-shadow: 0 0 0 4px rgba(88, 136, 71, 0.13);
}
.chat__send { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--green-600); color: #fff; flex: none; transition: all var(--t-fast) var(--ease); }
.chat__send:hover { background: var(--green-700); }
.chat__send:active { transform: scale(0.93); }
.chat__send svg { width: 19px; height: 19px; }

/* Индикатор непрочитанных */
.unread {
  display: inline-grid; place-items: center; min-width: 19px; height: 19px; padding: 0 6px;
  border-radius: var(--r-full); background: var(--green-vivid); color: #fff;
  font-size: 11px; font-weight: 800; line-height: 1;
}

/* --- Адаптив (демо ориентирован на десктоп) ---------------------------- */

@media (max-width: 1180px) {
  .workspace { grid-template-columns: 340px 1fr; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .fact:nth-child(2) { border-right: none; }
  .fact:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 900px) {
  .login { grid-template-columns: 1fr; }
  .login__brand { display: none; }
  .timeline { grid-template-columns: repeat(4, 1fr); row-gap: 24px; }
  .tl:nth-child(4)::before { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
