@import url('https://fonts.googleapis.com/css2?family=Geologica:wght@400;500;600;700&display=swap');

/* Визуал кабинета — по дизайну сайта ЛидЗахват (docs/visual/README.md, 2026-09-15): шрифт
   Geologica, розовый акцент #FF4FA3 для кнопок-призывов, голубой #2CCBFF дополнительный,
   тёмное боковое меню, светлое содержимое. Если Google Fonts недоступен — системный шрифт. */
:root {
  --bg: #F4F7F8;
  --card: #FFFFFF;
  --text: #10151B;
  --sidebar: #0B1220;
  --text-muted: #5F6776;
  --border: #DDE2EB;
  --line: rgba(20, 25, 34, .07);
  --track: #E4E8EF;
  --accent: #FF4FA3;
  --accent-dark: #E63A8F;
  --accent-soft: #FFE8F3;
  --accent-ink: #B8246F;
  --blue: #2CCBFF;
  /* «blue-dark» исторически — цвет ссылок, фокуса и выбранного; по дизайну сайта это розовый */
  --blue-dark: #E0328A;
  --blue-soft: #FFE8F3;
  --success: #22A45D;
  --success-soft: #E3F6EA;
  --switch-on: #FF4FA3;
  --danger: #D9463F;
  --danger-soft: #FCEBEA;
  --radius: 18px;
  --radius-sm: 11px;
  --shadow: 0 1px 2px rgba(20, 25, 34, .05), 0 0 0 1px rgba(20, 25, 34, .04);
  --shadow-lift: 0 14px 32px -16px rgba(20, 25, 34, .24), 0 0 0 1px rgba(20, 25, 34, .04);
  --font: "Geologica", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "Cascadia Code", Consolas, ui-monospace, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, h5 { font-weight: 600; letter-spacing: -.01em; text-wrap: balance; }
:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 2px; }

/* ---------- Каркас: боковое меню + содержимое ---------- */
.lz-app { display: flex; min-height: 100vh; }

.lz-sidebar {
  width: 236px;
  flex: none;
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: sticky;
  top: 0;
  height: 100vh;
}

.lz-logo { display: flex; align-items: center; gap: 10px; padding: 4px 10px 22px; font-weight: 600; font-size: 16px; letter-spacing: -.01em; }
.lz-logo-dot {
  width: 28px; height: 28px; border-radius: 9px; flex: none;
  background: linear-gradient(135deg, var(--accent), var(--blue));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 4px 12px -4px rgba(47, 111, 237, .45);
}

.lz-nav a, .lz-ws-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; margin-bottom: 2px;
  border-radius: var(--radius-sm);
  color: var(--text-muted); font-size: 14px; font-weight: 500; text-decoration: none;
  transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.lz-nav a svg, .lz-ws-nav a svg { width: 18px; height: 18px; flex: none; }
.lz-nav a:hover, .lz-ws-nav a:hover { background: rgba(20, 25, 34, .05); color: var(--text); text-decoration: none; }
.lz-nav a.active, .lz-ws-nav a.active { background: var(--card); color: var(--text); box-shadow: var(--shadow); }

.lz-sidebar-footer { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.lz-user { font-size: 12.5px; color: var(--text-muted); padding: 0 12px 8px; overflow-wrap: anywhere; }
.lz-logout {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 9px 12px; border: none; border-radius: var(--radius-sm); background: none;
  font: inherit; font-size: 13.5px; color: var(--text-muted); text-align: left; cursor: pointer;
}
.lz-logout svg { width: 17px; height: 17px; flex: none; }
.lz-logout:hover { background: var(--danger-soft); color: var(--danger); }

.lz-main { flex: 1; min-width: 0; padding: 30px 36px 48px; max-width: 1120px; }
.lz-page-title { font-size: 26px; line-height: 1.2; font-weight: 600; letter-spacing: -.02em; margin: 0 0 6px; color: var(--text); }
.lz-page-subtitle { color: var(--text-muted); font-size: 14px; margin: 0 0 26px; }

.lz-card { background: var(--card); border-radius: var(--radius); padding: 22px; margin-bottom: 16px; box-shadow: var(--shadow); }
.lz-card h3, .lz-card h4 { font-size: 15.5px; margin: 0 0 12px; }

/* ---------- Кнопки ---------- */
.lz-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border: none; border-radius: var(--radius-sm);
  font: inherit; font-size: 14px; font-weight: 500; white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: background .15s ease, box-shadow .15s ease, color .15s ease;
}
.lz-btn:hover { text-decoration: none; }
.lz-btn:disabled { opacity: .55; cursor: default; }
.lz-btn-primary { background: var(--text); color: #fff; }
.lz-btn-primary:hover { background: #2A3140; }
.lz-btn-blue { background: var(--blue-dark); color: #fff; }
.lz-btn-blue:hover { background: #245FD6; }
.lz-btn-outline { background: var(--card); color: var(--text); box-shadow: inset 0 0 0 1px var(--border); }
.lz-btn-outline:hover { background: #FAFBFC; box-shadow: inset 0 0 0 1px #C6CDD8; }
.lz-btn-danger { background: var(--danger-soft); color: var(--danger); }
.lz-btn-danger:hover { background: #F8DAD8; }
.lz-btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 9px; }

/* ---------- Поля ---------- */
.lz-field { margin-bottom: 16px; }
.lz-field label { display: block; margin-bottom: 6px; font-size: 12.5px; font-weight: 500; color: var(--text-muted); }
/* :where() обнуляет силу селектора: иначе цепочка :not() перебивала ширины полей в строках
   конструктора (текст варианта сплющивался, а цена растягивалась на всю ширину). */
.lz-field :where(input:not([type="checkbox"]):not([type="radio"]):not([type="color"]):not([type="file"]), select, textarea) {
  width: 100%; padding: 10px 13px; border: 0; border-radius: var(--radius-sm);
  font: inherit; font-size: 14px; color: var(--text); background: #fff;
  box-shadow: inset 0 0 0 1px var(--border);
  transition: box-shadow .15s ease;
}
.lz-field textarea { resize: vertical; min-height: 64px; line-height: 1.45; }
.lz-field input:disabled { background: #F4F6F9; color: var(--text-muted); }
.lz-field input:focus, .lz-field select:focus, .lz-field textarea:focus {
  outline: none;
  box-shadow: inset 0 0 0 1.5px var(--blue-dark), 0 0 0 4px rgba(47, 111, 237, .14);
}
.lz-field small { display: block; margin-top: 6px; font-size: 12px; line-height: 1.45; color: var(--text-muted); }
.lz-field input[type="checkbox"] { accent-color: var(--blue-dark); }
.lz-hint { color: var(--text-muted); font-size: 12.5px; }
.lz-label-note { display: inline-block; margin-left: 6px; padding: 0 7px; border-radius: 999px; background: var(--track); font-size: 11px; font-weight: 500; line-height: 18px; color: var(--text-muted); }

/* ---------- Сегментированный переключатель ---------- */
.lz-seg { display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; max-width: 100%; padding: 3px; border-radius: 11px; background: var(--track); }
.lz-seg input { position: absolute; opacity: 0; pointer-events: none; }
.lz-seg label, .lz-field .lz-seg label {
  display: block; margin: 0; padding: 6px 12px; border-radius: 8px;
  font-size: 13px; font-weight: 400; color: var(--text-muted); text-align: center; white-space: nowrap;
  cursor: pointer; user-select: none; transition: background .15s ease, color .15s ease;
}
.lz-seg label:hover { color: var(--text); }
.lz-seg input:checked + label { background: var(--card); color: var(--text); font-weight: 500; box-shadow: 0 1px 2px rgba(20, 25, 34, .12), 0 0 0 .5px rgba(20, 25, 34, .06); }
.lz-seg input:focus-visible + label { outline: 2px solid var(--blue-dark); outline-offset: 1px; }

/* ---------- Дашборд ---------- */
.lz-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.lz-calc-card {
  display: flex; flex-direction: column;
  padding: 18px 18px 16px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow);
  transition: box-shadow .2s ease;
}
.lz-calc-card:hover { box-shadow: var(--shadow-lift); }
.lz-calc-card h3 { margin: 0 0 4px; font-size: 16px; }
.lz-calc-card .niche { margin: 4px 0 10px; font-size: 13px; color: var(--text-muted); }
.lz-calc-card .actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 14px; }

.lz-group-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.lz-group-pill {
  height: 32px; padding: 0 14px; border: 0; border-radius: 999px;
  background: var(--card); box-shadow: var(--shadow);
  font: inherit; font-size: 13px; font-weight: 500; color: var(--text-muted); cursor: pointer;
}
.lz-group-pill:hover { color: var(--text); }
.lz-group-pill.active { background: var(--text); color: #fff; box-shadow: none; }

.lz-badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 500; }
.lz-badge-yellow { background: var(--accent-soft); color: var(--accent-ink); }
.lz-badge-blue { background: var(--blue-soft); color: #2456B8; }
.lz-badge-green { background: var(--success-soft); color: #1B7F47; }
.lz-badge-gray { background: var(--track); color: var(--text-muted); }

/* ---------- Таблица заявок ---------- */
table.lz-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.lz-table th {
  padding: 10px 12px; border-bottom: 1px solid var(--line);
  font-size: 11.5px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; text-align: left; color: var(--text-muted);
}
table.lz-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.lz-table tr:last-child td { border-bottom: none; }

.lz-empty { padding: 40px 20px; text-align: center; color: var(--text-muted); }
.lz-error { margin-bottom: 14px; padding: 10px 14px; border-radius: 12px; background: var(--danger-soft); color: #B23A34; font-size: 13.5px; }
.lz-success { margin-bottom: 14px; padding: 10px 14px; border-radius: 12px; background: var(--success-soft); color: #1B7F47; font-size: 13.5px; }

/* ---------- Конструктор вопросов ---------- */
.lz-question-block { margin-bottom: 10px; padding: 14px; border-radius: 14px; background: #F6F8FB; box-shadow: inset 0 0 0 1px var(--line); }
/* Строки конструктора переносятся, когда редактор узкий (справа открыто превью): текст вопроса
   и варианта остаётся читаемым, а тип, цена и картинка уходят на вторую строку. */
.lz-question-block .row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; }
.lz-question-block .q-text { flex: 1 1 220px; min-width: 0; }
.lz-question-block .q-type { flex: 0 1 200px; min-width: 0; }
.lz-option-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.lz-option-row input[type="text"] { flex: 1 1 160px; min-width: 0; }
.lz-option-row input[type="number"] { flex: none; width: 96px; }
.lz-option-row .lz-image-upload { flex: none; }
.lz-option-row > .lz-remove, .lz-question-block .row > .lz-remove { margin-left: auto; }
.lz-btn svg, .lz-icon-tile svg { pointer-events: none; }
.lz-opt-icon-btn { flex: none; width: 34px; height: 34px; }
.lz-opt-icon-empty { font-size: 17px; line-height: 1; color: var(--text-muted); }
.lz-opt-icon-btn .lz-opt-emoji, .lz-emoji-tile { font-size: 19px; line-height: 1; }
.lz-emoji-tile.selected { background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px var(--accent); }
.lz-icon-pop-label { width: 100%; margin: 4px 0 2px; font-size: 11px; font-weight: 500; letter-spacing: .05em; text-transform: uppercase; color: var(--text-muted); }
.lz-icon-pop-label:first-child { margin-top: 0; }
/* Палитра знаков и эмодзи длинная — прокручиваем её внутри, а не растягиваем строку варианта */
.lz-opt-icon-pop { max-height: 260px; overflow-y: auto; }
.lz-opt-icon-pop .lz-icon-grid { width: 100%; }
.lz-option-row .lz-opt-icon-pop { flex-basis: 100%; }
.lz-icon-color { flex-wrap: wrap; }
.lz-icon-btn { width: 34px; padding: 0; }
.lz-icon-btn svg { width: 17px; height: 17px; }
.lz-icon-btn.is-loading { opacity: .5; }
.lz-remove {
  flex: none; width: 30px; height: 30px; padding: 0; border: none; border-radius: 8px; background: none;
  font-size: 14px; color: var(--text-muted); cursor: pointer; transition: background .15s ease, color .15s ease;
}
.lz-remove:hover { background: var(--danger-soft); color: var(--danger); }

.lz-swatch { width: 30px; height: 30px; border-radius: 8px; border: 2px solid transparent; cursor: pointer; }
.lz-swatch.selected { border-color: var(--text); }
.lz-swatch-row { display: flex; gap: 10px; margin-bottom: 6px; }

.lz-embed-box {
  padding: 16px; border-radius: 12px; background: #141922; color: #D7E4F5;
  font-family: var(--mono); font-size: 12.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-all;
}

/* ---------- Хлебные крошки ---------- */
.lz-breadcrumb { margin-bottom: 6px; font-size: 13px; color: var(--text-muted); }
.lz-breadcrumb a { color: var(--text-muted); }
.lz-breadcrumb .current { color: var(--text); font-weight: 500; }

/* ---------- Рабочее пространство виджета ---------- */
.lz-workspace { display: grid; grid-template-columns: 200px 1fr; gap: 24px; align-items: start; }
.lz-workspace-3col { grid-template-columns: 180px minmax(560px, 1fr) 230px; gap: 18px; }
.lz-workspace-3col.lz-preview-hidden { grid-template-columns: 180px minmax(560px, 1fr); }
.lz-ws-main { min-width: 0; }
.lz-ws-nav { position: sticky; top: 20px; }
.lz-preview-col { position: sticky; top: 20px; }
.lz-preview-hidden .lz-preview-col { display: none; }
.lz-preview-toggle {
  height: 32px; padding: 0 12px; border: 0; border-radius: 9px; background: var(--card); box-shadow: var(--shadow);
  font: inherit; font-size: 13px; font-weight: 500; color: var(--text-muted); cursor: pointer;
}
.lz-preview-toggle:hover { color: var(--text); }
.lz-ws-section { display: none; }
.lz-ws-section.active { display: block; }

.lz-tabs { display: inline-flex; gap: 2px; margin-bottom: 18px; padding: 3px; border-radius: 11px; background: var(--track); }
.lz-q-tab-row { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.lz-q-tab {
  height: 32px; padding: 0 14px; border: 0; border-radius: 8px; background: transparent;
  font: inherit; font-size: 13px; font-weight: 400; color: var(--text-muted); cursor: pointer;
}
.lz-q-tab:hover { color: var(--text); }
.lz-q-tab.active { background: var(--card); color: var(--text); font-weight: 500; box-shadow: 0 1px 2px rgba(20, 25, 34, .12), 0 0 0 .5px rgba(20, 25, 34, .06); }

/* ---------- Тумблер ---------- */
.lz-toggle { position: relative; display: inline-block; flex: none; width: 40px; height: 24px; }
.lz-toggle input { position: absolute; width: 0; height: 0; opacity: 0; }
.lz-toggle .track { position: absolute; inset: 0; border-radius: 999px; background: var(--track); cursor: pointer; transition: background .18s ease; }
.lz-toggle input:checked + .track { background: var(--switch-on); }
.lz-toggle input:focus-visible + .track { outline: 2px solid var(--blue-dark); outline-offset: 2px; }
.lz-toggle .thumb {
  position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(20, 25, 34, .25); pointer-events: none; transition: transform .18s ease;
}
.lz-toggle input:checked ~ .thumb { transform: translateX(16px); }
.lz-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.lz-toggle-row:last-child { border-bottom: none; }
.lz-toggle-label { display: block; }
.lz-toggle-hint { display: block; margin-top: 2px; font-size: 12px; line-height: 1.4; color: var(--text-muted); }
.lz-toggle-group { margin: -4px 0 14px; }

/* ---------- Содержимое: список блоков + редактор ---------- */
.lz-content-grid { display: grid; grid-template-columns: 230px 1fr; gap: 16px; align-items: start; }
.lz-block-list { padding: 8px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); position: sticky; top: 20px; }
.lz-block-group-label { padding: 12px 10px 4px; font-size: 11px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); }
.lz-block-item {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 10px; border-radius: var(--radius-sm);
  font-size: 13.5px; font-weight: 400; cursor: pointer; transition: background .15s ease;
}
.lz-block-item:hover { background: #F2F4F8; }
.lz-block-item.active { background: var(--accent-soft); color: var(--text); font-weight: 500; }
.lz-bi-icon { display: inline-flex; flex: none; width: 18px; height: 18px; color: var(--text-muted); }
.lz-block-item.active .lz-bi-icon { color: var(--accent-ink); }
.lz-bi-icon svg, .lz-bi-icon .lz-icon-mask { width: 100%; height: 100%; }
.lz-bi-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lz-block-add-row { padding: 4px 6px; }
.lz-block-add-row .lz-btn { justify-content: flex-start; color: var(--text-muted); box-shadow: none; background: transparent; }
.lz-block-add-row .lz-btn:hover { background: #F2F4F8; color: var(--text); box-shadow: none; }

.lz-subsection { margin: 24px 0 4px; padding-top: 20px; border-top: 1px solid var(--line); }
.lz-subsection-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.lz-subsection-head h5 { margin: 0; font-size: 15px; }
.lz-subsection-head p { margin: 0; font-size: 12.5px; color: var(--text-muted); }
.lz-subsection-head a { font-size: 13px; }

/* Кнопка сохранения прилипает к низу экрана — длинный редактор не нужно прокручивать до конца */
.lz-save-row {
  position: sticky; bottom: 0; z-index: 5;
  margin: 18px -22px -22px; padding: 14px 22px 18px;
  border-radius: 0 0 var(--radius) var(--radius);
  background: linear-gradient(rgba(255, 255, 255, 0), #fff 38%);
}

/* ---------- Быстрые ссылки экрана после отправки ---------- */
.lz-link-row {
  position: relative;
  display: grid; grid-template-columns: 38px 1fr 30px; align-items: start; gap: 10px;
  margin-bottom: 8px; padding: 12px; border-radius: 14px; background: #F6F8FB; box-shadow: inset 0 0 0 1px var(--line);
}
.lz-link-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.lz-link-fields .ln-url, .lz-link-fields .lz-inline-check { grid-column: 1 / -1; }
.lz-field .lz-inline-check { display: inline-flex; align-items: center; gap: 8px; margin: 2px 0 0; font-size: 13px; font-weight: 400; color: var(--text-muted); cursor: pointer; }
.lz-link-icon-pop {
  grid-column: 1 / -1;
  display: flex; flex-wrap: wrap; gap: 6px; padding: 10px; border-radius: 12px; background: #fff; box-shadow: var(--shadow-lift);
}

/* ---------- Внешний вид: сетка позиций + живое превью ---------- */
.lz-pos-grid { display: grid; grid-template-columns: repeat(2, 1fr); grid-template-rows: repeat(3, 1fr); gap: 6px; width: 96px; height: 132px; padding: 7px; border-radius: 14px; background: var(--track); }
.lz-pos-cell { border-radius: 8px; background: #fff; cursor: pointer; transition: background .15s ease; }
.lz-pos-cell:hover { background: #F7F9FB; }
.lz-pos-cell.selected { background: var(--text); }
.lz-preview-frame { overflow: hidden; min-height: 340px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.lz-preview-toolbar { display: flex; flex-wrap: wrap; gap: 2px; margin: 8px 8px 0; padding: 3px; border-radius: 10px; background: var(--track); }
.lz-preview-toolbar button {
  flex: 1; padding: 5px 8px; border: 0; border-radius: 7px; background: transparent;
  font: inherit; font-size: 12px; font-weight: 400; color: var(--text-muted); cursor: pointer;
}
.lz-preview-toolbar button.active { background: var(--card); color: var(--text); font-weight: 500; box-shadow: 0 1px 2px rgba(20, 25, 34, .12); }
.lz-preview-viewport { position: relative; height: 320px; margin: 8px auto 0; overflow: hidden; background: linear-gradient(180deg, #F7F9FC, #EEF2F7); transition: width .2s ease; }
.lz-preview-viewport.mobile { width: 180px; box-shadow: inset 1px 0 0 var(--line), inset -1px 0 0 var(--line); }
.lz-preview-viewport.desktop { width: 100%; }
.lz-preview-menu-item { display: flex; align-items: center; gap: 5px; padding: 6px 10px; font-size: 10.5px; font-weight: 500; white-space: nowrap; box-shadow: 0 3px 10px rgba(0, 0, 0, .12); }

.lz-preview-icon { display: inline-flex; flex: none; width: 12px; height: 12px; }
.lz-preview-icon svg, .lz-preview-icon .lz-icon-mask { width: 100%; height: 100%; }
.lz-preview-collapsed {
  position: absolute; display: flex; align-items: center; justify-content: center; gap: 4px;
  height: 20px; padding: 0 9px; font-size: 9.5px; font-weight: 400; line-height: 1; letter-spacing: .2px;
  white-space: nowrap; box-shadow: 0 4px 12px rgba(0, 0, 0, .16);
}
.lz-preview-collapse-row { display: flex; align-items: center; justify-content: flex-end; gap: 4px; padding: 4px 9px; font-size: 9.5px; font-weight: 400; line-height: 1; letter-spacing: .2px; white-space: nowrap; }
.lz-preview-collapse-row.left { justify-content: flex-start; }
.lz-preview-collapsed svg, .lz-preview-collapse-row svg { width: 5px; height: 8px; flex: none; }
/* Строчные буквы визуально проседают ниже центра — приподнимаем, как в виджете. */
.lz-preview-collapsed span, .lz-preview-collapse-row span { transform: translateY(-0.14em); }

/* ---------- Превью фирменного оформления ---------- */
.lz-pv { position: absolute; width: 150px; }
.lz-pv-box { position: relative; overflow: hidden; border-radius: 10px; background: #fff; color: #11151C;
  box-shadow: 0 8px 20px -8px rgba(10, 14, 22, .35), 0 0 0 1px rgba(17, 21, 28, .08); }
.lz-pv.dark .lz-pv-box { background: #131922; color: #F3F5F8; box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .5), 0 0 0 1px rgba(255, 255, 255, .08); }
.lz-pv-box > :not(.lz-pv-wm) { position: relative; z-index: 1; }
.lz-pv-item { display: flex; align-items: center; gap: 5px; padding: 7px 8px; font-size: 8.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.lz-pv-item + .lz-pv-item { box-shadow: inset 0 1px 0 rgba(17, 21, 28, .08); }
.lz-pv.dark .lz-pv-item + .lz-pv-item { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08); }
.lz-pv-item .lz-preview-icon { color: #6A7280; }
.lz-pv.dark .lz-pv-item .lz-preview-icon { color: #9AA3B2; }
.lz-pv-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.lz-pv-dot { flex: none; width: 5px; height: 5px; border-radius: 50%; background: var(--acc); }
.lz-pv-sep { flex: none; width: 1px; height: 14px; background: rgba(127, 127, 127, .3); }
.lz-pv-collapse { padding: 4px 8px 5px; font-size: 8px; text-align: right; color: #6A7280; box-shadow: inset 0 1px 0 rgba(17, 21, 28, .08); }
.lz-pv.dark .lz-pv-collapse { color: #B4BCC8; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08); }
.lz-pv-chip { display: flex; justify-content: flex-end; align-items: center; gap: 4px; padding: 5px 7px 1px; font-size: 8px; color: #6A7280; }
.lz-pv-chip i { display: grid; place-items: center; width: 12px; height: 12px; border-radius: 50%; background: var(--acc); color: #151A22; font-style: normal; font-size: 7px; }
.lz-pv-wm { position: absolute; right: -8px; bottom: -8px; z-index: 0; width: 56px; height: 56px; color: rgba(17, 21, 28, .05); }
.lz-pv.dark .lz-pv-wm { color: rgba(255, 255, 255, .06); }
.lz-pv-wm svg { width: 100%; height: 100%; }
.lz-pv-cn { position: absolute; z-index: 2; width: 16px; height: 16px; pointer-events: none; --o: -4px; --w: 3px; }
.lz-pv-watermark .lz-pv-cn { --o: -1px; --w: 2.5px; width: 12px; height: 12px; }
.lz-pv-cn.tl { top: var(--o); left: var(--o); border-top: var(--w) solid var(--acc); border-left: var(--w) solid var(--acc); border-top-left-radius: 7px; }
.lz-pv-cn.br { bottom: var(--o); right: var(--o); border-bottom: var(--w) solid var(--acc); border-right: var(--w) solid var(--acc); border-bottom-right-radius: 7px; }
.lz-pv-cn.tr { top: var(--o); right: var(--o); border-top: var(--w) solid var(--sec); border-right: var(--w) solid var(--sec); border-top-right-radius: 7px; }
.lz-pv-cn.bl { bottom: var(--o); left: var(--o); border-bottom: var(--w) solid var(--sec); border-left: var(--w) solid var(--sec); border-bottom-left-radius: 7px; }
.lz-pv-railbar { position: absolute; z-index: 2; top: 5px; bottom: 5px; left: 5px; width: 12px; pointer-events: none; }
.lz-pv.rail-right .lz-pv-railbar { left: auto; right: 5px; transform: scaleX(-1); }
.lz-pv-railbar i { position: absolute; left: 0; }
.lz-pv-railbar .t { top: 0; width: 10px; height: 10px; border-top: 3px solid var(--acc); border-left: 3px solid var(--acc); border-top-left-radius: 6px; }
.lz-pv-railbar .b { bottom: 0; width: 10px; height: 10px; border-bottom: 3px solid var(--sec); border-left: 3px solid var(--sec); border-bottom-left-radius: 6px; }
.lz-pv-railbar .bar { top: 8px; bottom: 8px; width: 3px; background: linear-gradient(var(--acc), var(--sec)); }
.lz-pv-rail.rail-left .lz-pv-item, .lz-pv-rail.rail-left .lz-pv-chip, .lz-pv-rail.rail-left .lz-pv-collapse { padding-left: 22px; }
.lz-pv-rail.rail-right .lz-pv-item, .lz-pv-rail.rail-right .lz-pv-chip, .lz-pv-rail.rail-right .lz-pv-collapse { padding-right: 22px; }
/* Превью новых вариантов оформления — те же приёмы, что в виджете, в масштабе миниатюры */
.lz-pv-frame .lz-pv-box { box-shadow: 0 8px 20px -8px rgba(10, 14, 22, .4), 0 0 0 2px var(--acc); }
.lz-pv-header .lz-pv-box::before { content: ""; display: block; height: 5px; background: var(--acc); }
.lz-pv-side .lz-pv-box::before { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 4px; z-index: 2; background: linear-gradient(var(--acc), var(--sec)); }
.lz-pv-side.rail-right .lz-pv-box::before { left: auto; right: 0; }
.lz-pv-side.rail-left .lz-pv-item, .lz-pv-side.rail-left .lz-pv-collapse, .lz-pv-side.rail-left .lz-pv-chip { padding-left: 12px; }
.lz-pv-side.rail-right .lz-pv-item, .lz-pv-side.rail-right .lz-pv-collapse, .lz-pv-side.rail-right .lz-pv-chip { padding-right: 12px; }
.lz-pv-glow .lz-pv-box { box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 25%, transparent), 0 0 18px -2px var(--acc); }

/* ---------- Подстройка цвета ---------- */
.lz-tune { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.lz-tune-head h5 { margin: 0; font-size: 14px; }
.lz-tune-head p { margin: 4px 0 12px; font-size: 12.5px; color: var(--text-muted); }
.lz-tune-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) 110px; align-items: center; gap: 12px; margin-bottom: 10px; }
.lz-tune-row label { font-size: 13px; font-weight: 500; }
.lz-tune-row output { font-size: 12.5px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.lz-tune-row input[type="range"] { width: 100%; height: 10px; margin: 0; border-radius: 999px; -webkit-appearance: none; appearance: none; cursor: pointer; }
.lz-tune-hue { background: linear-gradient(90deg, #FF4D4D, #FFC940, #3ECF8E, #2CCBFF, #6D4FD8, #FF4FA3, #FF4D4D); }
.lz-tune-light { background: linear-gradient(90deg, #0B1220, #7D8797, #FFFFFF); box-shadow: inset 0 0 0 1px rgba(20, 25, 34, .12); }
.lz-tune-row input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(20, 25, 34, .35), 0 0 0 1px rgba(20, 25, 34, .15); }
.lz-tune-row input[type="range"]::-moz-range-thumb { width: 20px; height: 20px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(20, 25, 34, .35); }
.lz-tune-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
@media (max-width: 700px) { .lz-tune-row { grid-template-columns: 1fr; gap: 6px; } }

/* ---------- Свёрнутая кнопка: анимации с живыми примерами ---------- */
.lz-att-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 900px) { .lz-att-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.lz-att-card { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.lz-att-stage { position: relative; display: grid; place-items: center; width: 100%; height: 86px; border-radius: 12px; background: #E7EEF0; box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .15s ease; }
.lz-att-card:hover .lz-att-stage { box-shadow: inset 0 0 0 1px #C6CDD8; }
.lz-att-card.selected .lz-att-stage { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--accent); }
.lz-att-card:focus-visible { outline: none; }
.lz-att-card:focus-visible .lz-att-stage { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--blue-dark); }
.lz-att-host { transform: scale(.7); }
.lz-att-name { font-size: 12px; line-height: 1.2; text-align: center; color: var(--text); }
.lz-att-card.selected .lz-att-name { font-weight: 600; }
/* Раскладка ответов: миниатюры окна опроса (строит widget.js — buildAnswers), окно 540px под ширину карточки */
.lz-al-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px 10px; }
.lz-al-card { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 0; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; }
.lz-al-host { display: block; width: 100%; height: 118px; overflow: hidden; border-radius: var(--radius-sm); background: var(--track); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .15s ease; }
.lz-al-card:hover .lz-al-host { box-shadow: inset 0 0 0 1px var(--border); }
.lz-al-card.selected .lz-al-host { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--accent); }
.lz-al-card:focus-visible { outline: none; }
.lz-al-card:focus-visible .lz-al-host { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--blue-dark); }
.lz-al-name { font-size: 12px; line-height: 1.25; color: var(--text); }
.lz-al-card.selected .lz-al-name { font-weight: 600; }
.lz-al-note { margin: 10px 0 4px; font-size: 13px; line-height: 1.45; color: var(--text); }
.lz-q-layout { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0 0 10px; font-size: 13px; font-weight: 500; }
.lz-q-layout select { flex: 0 1 260px; min-width: 0; }
.lz-group-row { padding-top: 6px; }
.lz-group-row .opt-label { font-weight: 600; }
.lz-group-tag { flex: none; padding: 3px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-ink); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
/* Строка доверия («Без звонков и спама») */
.lz-trust-block { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
#trustFields { margin-top: 10px; }
.lz-trust-icons { display: flex; flex-wrap: wrap; gap: 6px; }
.lz-trust-icon { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 12px 0 9px; border: 0; border-radius: 999px;
  background: var(--bg); color: var(--text); font: inherit; font-size: 12.5px; cursor: pointer; box-shadow: inset 0 0 0 1px var(--border); }
.lz-trust-icon svg { width: 16px; height: 16px; flex: none; }
.lz-trust-icon.selected { box-shadow: inset 0 0 0 2px var(--accent); font-weight: 600; }
.lz-trust-icon:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 2px; }
.lz-trust-none { width: 16px; text-align: center; color: var(--text-muted); }
.lz-trust-preview { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 12px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--bg); }
.lz-trust-preview-label { font-size: 12px; color: var(--text-muted); }
.lz-trust-line { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-muted); }
.lz-trust-line svg { width: 14px; height: 14px; }
.lz-trust-block-row { display: flex; flex-wrap: wrap; gap: 8px; }
.lz-trust-block-row select { flex: 0 1 240px; min-width: 0; }
.lz-trust-block-row input { flex: 1 1 220px; min-width: 0; }
.lz-att-stage { overflow: hidden; }
.lz-att-host.lz-att-host-center { position: absolute; left: 50%; top: 50%; }
.lz-mini-sub-field { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 12px; }
.lz-mini-sub-field label { margin: 0 !important; font-size: 13px; font-weight: 500; }
.lz-mini-sub-field input { flex: 0 1 280px; min-width: 0; }
.lz-att-every { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.lz-att-every label { margin: 0 !important; font-size: 13px; font-weight: 500; }
.lz-att-every select { width: auto; }
/* Свёрнутая кнопка в превью справа — собрана кодом виджета */
.lz-pv-mini { position: absolute; }
.lz-pv-mini > div { transform: scale(.72); }

/* ---------- Стиль меню: 30 миниатюр ---------- */
.lz-skin-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 1320px) { .lz-skin-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 900px) { .lz-skin-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.lz-skin-card { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 0; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; }
.lz-skin-stage { position: relative; display: block; height: 150px; overflow: hidden; border-radius: 12px; background: #E7EEF0; box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .15s ease; }
.lz-skin-card:hover .lz-skin-stage { box-shadow: inset 0 0 0 1px #C6CDD8; }
.lz-skin-card.selected .lz-skin-stage { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--accent); }
.lz-skin-card:focus-visible { outline: none; }
.lz-skin-card:focus-visible .lz-skin-stage { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--blue-dark); }
.lz-skin-host { position: absolute; left: 50%; top: 50%; width: 300px; transform: translate(-50%, -50%) scale(.46); transform-origin: center; }
.lz-skin-name { font-size: 12px; line-height: 1.25; color: var(--text); }
.lz-skin-name b { color: var(--text-muted); font-weight: 500; margin-right: 2px; }
.lz-skin-card.selected .lz-skin-name { font-weight: 600; }
/* Живое превью справа: меню выбранного стиля в масштабе превью */
.lz-pv-skin { position: absolute; width: 290px; }
.lz-pv-skin > div { transform: scale(.55); transform-origin: bottom right; }

.lz-pv-mark { position: absolute; width: 34px; height: 34px; border-radius: 10px; background: #151A22; box-shadow: 0 8px 18px -8px rgba(10, 14, 22, .5); }
.lz-pv-mark svg { display: block; width: 100%; height: 100%; }

/* ---------- Выбор иконки ---------- */
.lz-icon-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.lz-icon-tile {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; padding: 0; border: 0; border-radius: 10px;
  background: #fff; box-shadow: inset 0 0 0 1px var(--border); color: var(--text); cursor: pointer;
  transition: box-shadow .12s ease, background .12s ease, color .12s ease;
}
.lz-icon-tile:hover { box-shadow: inset 0 0 0 1px #C6CDD8; }
.lz-icon-tile.selected { background: var(--blue-soft); color: var(--blue-dark); box-shadow: inset 0 0 0 1.5px var(--blue-dark); }
.lz-icon-tile svg, .lz-icon-tile .lz-icon-mask { width: 20px; height: 20px; }
.lz-icon-add { font-size: 20px; font-weight: 400; line-height: 1; color: var(--text-muted); box-shadow: inset 0 0 0 1px var(--border); background: transparent; border: 1.5px dashed #C6CDD8; }
.lz-icon-add:hover { color: var(--blue-dark); border-color: var(--blue-dark); }
.lz-icon-mask {
  display: block; background-color: currentColor;
  -webkit-mask-size: contain; mask-size: contain; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: center; mask-position: center;
}
.lz-icon-groups { max-height: 320px; overflow-y: auto; margin-top: 8px; padding-right: 4px; }
.lz-icon-groups .lz-icon-grid { margin-bottom: 4px; }
.lz-icon-more { margin-top: 8px; padding: 0; border: none; background: none; font: inherit; font-size: 12.5px; color: var(--blue-dark); cursor: pointer; }
.lz-icon-more:hover { text-decoration: underline; }

/* ---------- Цветовая палитра ---------- */
.lz-color-picker { display: flex; flex-direction: column; gap: 12px; }
.lz-color-palette { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; }
.lz-color-palette .sw { width: 100%; aspect-ratio: 1; border: 2px solid transparent; border-radius: 9px; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(20, 25, 34, .08); }
.lz-color-palette .sw.selected { border-color: var(--text); }
.lz-color-custom { display: flex; align-items: center; gap: 8px; }
.lz-color-custom input[type=color] { width: 42px; height: 38px; padding: 3px; border: 0; border-radius: var(--radius-sm); background: #fff; box-shadow: inset 0 0 0 1px var(--border); cursor: pointer; }
.lz-color-custom input[type=text] { flex: 1; padding: 9px 12px; border: 0; border-radius: var(--radius-sm); box-shadow: inset 0 0 0 1px var(--border); font-family: var(--mono); font-size: 13px; }

/* ---------- Загрузка картинки к варианту ответа ---------- */
.lz-image-upload { display: flex; align-items: center; gap: 8px; }
.lz-image-thumb { flex: none; width: 40px; height: 40px; border-radius: 9px; object-fit: cover; box-shadow: inset 0 0 0 1px var(--border); }
.lz-image-thumb.empty { background: var(--track); }

/* ---------- Статистика: источники ---------- */
.lz-src-row { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-size: 13px; }
.lz-src-label { flex: none; width: 130px; font-weight: 500; }
.lz-src-bar-wrap { flex: 1; height: 10px; overflow: hidden; border-radius: 999px; background: var(--track); }
.lz-src-bar { height: 100%; border-radius: 999px; }
.lz-src-count { width: 38px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.lz-stat-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; }
.lz-stat-tile { padding: 16px 18px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.lz-stat-tile .num { font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.lz-stat-tile .lbl { margin-top: 2px; font-size: 12px; color: var(--text-muted); }

/* ---------- Дизайн сайта: тёмное меню, знак ЛидЗахват, розовые призывы ---------- */
.lz-sidebar { background: var(--sidebar); color: #E6EAF2; }
.lz-logo { color: #FFFFFF; }
.lz-wordmark { font-weight: 700; letter-spacing: -.01em; }
.lz-wordmark em { font-style: normal; color: var(--accent); }
.lz-logo-dot {
  width: 30px; height: 30px; border-radius: 0; box-shadow: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M8 18v-6a4 4 0 0 1 4-4h6M30 8h6a4 4 0 0 1 4 4v6M40 30v6a4 4 0 0 1-4 4h-6M18 40h-6a4 4 0 0 1-4-4v-6' fill='none' stroke='%232CCBFF' stroke-width='4' stroke-linecap='round'/%3E%3Ccircle cx='24' cy='24' r='10' fill='%23FF4FA3' opacity='.25'/%3E%3Ccircle cx='24' cy='24' r='5.5' fill='%23FF4FA3'/%3E%3C/svg%3E") center / contain no-repeat;
}
.lz-sidebar .lz-nav a { color: #9AA6B8; }
.lz-sidebar .lz-nav a svg { width: 30px; height: 30px; padding: 6px; border-radius: 9px; background: rgba(255, 255, 255, .06); color: #C7D0DD; }
.lz-sidebar .lz-nav a:hover { background: rgba(255, 255, 255, .05); color: #FFFFFF; }
.lz-sidebar .lz-nav a.active { background: rgba(255, 79, 163, .12); color: #FFFFFF; box-shadow: none; }
.lz-sidebar .lz-nav a.active svg { background: var(--accent); color: #FFFFFF; }
.lz-sidebar-footer { border-top-color: rgba(255, 255, 255, .08); }
.lz-sidebar .lz-user { color: #8C97A8; }
.lz-sidebar .lz-logout { color: #9AA6B8; }
.lz-sidebar .lz-logout:hover { background: rgba(255, 79, 163, .12); color: #FFFFFF; }
.lz-page-title { font-weight: 700; }
.lz-btn-primary { background: var(--accent); color: #FFFFFF; box-shadow: 0 8px 18px -10px rgba(255, 79, 163, .8); }
.lz-btn-primary:hover { background: var(--accent-dark); }
.lz-field input:focus, .lz-field select:focus, .lz-field textarea:focus { box-shadow: inset 0 0 0 1.5px var(--accent), 0 0 0 4px rgba(255, 79, 163, .15); }
.lz-ws-nav a.active svg { color: var(--accent); }
.lz-block-item.active .lz-bi-icon { color: var(--accent-ink); }
.lz-group-pill.active { background: var(--accent); color: #FFFFFF; }
.lz-pv-mark { background: #0B1220; }
.lz-pv-mark.logo { background: #FFFFFF; }
.lz-pv-mark img { width: 100%; height: 100%; padding: 4px; object-fit: contain; }
.lz-pv-wm { color: inherit; opacity: .12; }
.lz-pv.dark .lz-pv-wm { opacity: .16; }
.lz-pv-wm img { width: 100%; height: 100%; object-fit: contain; filter: grayscale(1); }

/* ---------- Загрузка картинки с компьютера ---------- */
.lz-upl { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.lz-upl-thumb { flex: none; display: grid; place-items: center; width: 64px; height: 48px; overflow: hidden; border-radius: 10px; background: var(--track); color: var(--text-muted); }
.lz-upl-thumb img { width: 100%; height: 100%; object-fit: contain; background: #FFFFFF; }
.lz-upl-thumb svg { width: 22px; height: 22px; }
.lz-upl.is-loading { opacity: .6; pointer-events: none; }
.lz-upl-compact { flex: none; }
.lz-upl-compact .lz-upl-thumb { width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; }
.lz-upl-compact .lz-upl-thumb img { object-fit: cover; }
.lz-gallery-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.lz-gallery-thumb { flex: none; width: 64px; height: 48px; border-radius: 10px; object-fit: cover; background: var(--track); }
.lz-gallery-row .img-caption { flex: 1; min-width: 0; }
#imagesWrap:not(:empty) { margin-bottom: 6px; }

/* ---------- Ширина окна блока ---------- */
.lz-field label.lz-label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.lz-label-row output { font-variant-numeric: tabular-nums; font-weight: 500; color: var(--text); }
.lz-width-range { max-width: 440px; margin-top: 10px; }
.lz-field .lz-width-range input[type="range"] { display: block; width: 100%; height: auto; margin: 0; padding: 0; border: 0; background: none; box-shadow: none; accent-color: var(--accent); cursor: ew-resize; }
.lz-width-scale { display: flex; justify-content: space-between; margin-top: 2px; font-size: 11.5px; color: var(--text-muted); }

/* ---------- Финальный дизайн-кит (lidzahvat-final-design-kit): знак и вход ---------- */
/* Знак — уголки «рамки захвата», голубые линии скорости и розовая точка. В тёмном меню — версия
   для тёмного фона, на светлой форме входа — для светлого. */
.lz-logo-dot { background: url("/assets/brand/icon-transparent-dark.svg") center / contain no-repeat; }
.lz-login-logo .lz-logo-dot { background-image: url("/assets/brand/icon-transparent-light.svg"); }
.lz-wordmark { font-weight: 700; }
.lz-login-logo .lz-wordmark em { color: #E52F87; }

/* Селекторы усилены: блок «Вход и регистрация» ниже по файлу иначе перебивает эти правила. */
body.lz-auth-page { background: #0B1220 url("/assets/brand/hero-background.webp") center / cover no-repeat; }
.lz-auth-page .lz-auth { box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .65), 0 0 0 1px rgba(44, 203, 255, .2); }
.lz-auth-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lz-auth-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11, 18, 32, 0) 38%, rgba(11, 18, 32, .9) 100%); }
.lz-auth-art .lz-auth-art-text { z-index: 1; bottom: 64px; }
.lz-auth-eyebrow { position: absolute; left: 36px; right: 36px; bottom: 26px; z-index: 1; font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: #7FDDFF; }
.lz-auth-form .lz-btn-primary { height: 48px; font-size: 15px; }

/* ---------- Главная кабинета: показатели, динамика, источники ---------- */
.lz-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 0 0 14px; }
.lz-stat { position: relative; padding: 16px 18px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.lz-stat-label { padding-right: 40px; font-size: 12.5px; color: var(--text-muted); }
.lz-stat-value { margin-top: 6px; font-size: 26px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.lz-stat-note { margin-top: 3px; font-size: 12.5px; color: var(--text-muted); }
.lz-stat-note.up { color: var(--success); }
.lz-stat-note.down { color: var(--danger); }
.lz-stat-icon { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; }
.lz-stat-icon svg { width: 17px; height: 17px; }
.lz-stat-icon.pink { background: var(--accent-soft); color: var(--accent-ink); }
.lz-stat-icon.cyan { background: #DDF6FF; color: #0E7FA6; }
.lz-stat-icon.green { background: var(--success-soft); color: var(--success); }
.lz-stat-icon.violet { background: #EEE9FF; color: #6A4FE0; }
.lz-dash-row { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 14px; margin-bottom: 30px; }
.lz-panel { padding: 18px 20px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); min-width: 0; }
.lz-panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.lz-panel-head h2 { margin: 0; font-size: 15px; font-weight: 600; }
.lz-panel-head span { font-size: 12.5px; color: var(--text-muted); }
.lz-chart svg { display: block; width: 100%; height: 200px; overflow: visible; }
.lz-chart text { font-family: var(--font); font-size: 11px; fill: var(--text-muted); }
.lz-sources { margin: 0; padding: 0; list-style: none; }
.lz-sources li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; column-gap: 10px; row-gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 13.5px; }
.lz-sources li:first-child { border-top: 0; padding-top: 2px; }
.lz-src-icon { grid-row: span 2; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff; }
.lz-src-num { font-weight: 600; font-variant-numeric: tabular-nums; }
.lz-src-bar { grid-column: 2 / 4; height: 4px; border-radius: 2px; background: var(--track); overflow: hidden; }
.lz-src-bar i { display: block; height: 100%; border-radius: inherit; }
.lz-section-title { margin: 0 0 12px; font-size: 18px; font-weight: 600; }
@media (max-width: 1200px) { .lz-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .lz-dash-row { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .lz-stats { grid-template-columns: 1fr; } }

/* ---------- Выбор периода статистики ---------- */
.lz-period { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 0 0 14px; }
.lz-period .lz-seg { overflow-x: auto; }
.lz-period-custom { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--text-muted); }
.lz-period-custom input[type="date"] { height: 34px; padding: 0 10px; border: 0; border-radius: 9px; font: inherit; font-size: 13px; color: var(--text); background: var(--card); box-shadow: inset 0 0 0 1px var(--border); }
.lz-period-custom input[type="date"]:focus { outline: none; box-shadow: inset 0 0 0 1.5px var(--accent), 0 0 0 4px rgba(255, 79, 163, .15); }
.lz-period-label { margin-left: auto; font-size: 13px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.lz-chart rect { transition: opacity .15s ease; }
.lz-chart rect:hover { opacity: .75; }
.lz-src-num small { margin-left: 4px; font-size: 11.5px; font-weight: 400; color: var(--text-muted); }
.lz-sources-empty { display: block !important; color: var(--text-muted); }
#dashStats { margin-bottom: 6px; }
.lz-group-pills + .lz-section-title { margin-top: 4px; }
.lz-leads-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.lz-leads-head h2 { margin: 0; font-size: 15px; font-weight: 600; }
.lz-leads-head span { font-size: 12.5px; color: var(--text-muted); }
.lz-leads-scroll { overflow-x: auto; }
.lz-leads-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 0 0 12px; }
.lz-leads-tools .lz-inline-check { margin: 0; font-size: 13px; }
.lz-badge-dup { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: #FFF4E0; color: #7A4B10; font-size: 11px; font-weight: 500; vertical-align: middle; }
.lz-lead-dup td { background: #FFFBF2; }

/* ---------- Вопросы калькулятора вкладками ---------- */
.lz-q-tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 2px 0 10px; }
.lz-q-tabbtn {
  display: inline-flex; align-items: center; gap: 7px; max-width: 220px; height: 34px; padding: 0 12px 0 5px;
  border: 0; border-radius: 10px; background: #F2F4F8; box-shadow: inset 0 0 0 1px var(--line);
  font: inherit; font-size: 12.5px; color: var(--text-muted); cursor: pointer; transition: background .12s ease, box-shadow .12s ease, color .12s ease;
}
.lz-q-tabbtn b { display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 7px; background: #fff; color: var(--text); font-size: 12px; font-weight: 600; box-shadow: inset 0 0 0 1px var(--line); }
.lz-q-tabbtn span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lz-q-tabbtn:hover { background: #fff; color: var(--text); }
.lz-q-tabbtn.active { background: #fff; color: var(--text); font-weight: 500; box-shadow: inset 0 0 0 1.5px var(--accent), 0 4px 10px -6px rgba(255, 79, 163, .45); }
.lz-q-tabbtn.active b { background: var(--accent); color: #fff; box-shadow: none; }
.lz-q-tabbtn.drop-target { box-shadow: inset 0 0 0 2px var(--blue-dark); }
.lz-q-tabbtn:focus-visible, .lz-q-tabadd:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 2px; }
.lz-q-tabadd { height: 34px; padding: 0 12px; border: 1.5px dashed #C6CDD8; border-radius: 10px; background: transparent; font: inherit; font-size: 12.5px; font-weight: 500; color: var(--text-muted); cursor: pointer; }
.lz-q-tabadd:hover { border-color: var(--accent); color: var(--accent-ink); }
.lz-q-empty { margin: 4px 0 10px; font-size: 13px; color: var(--text-muted); }
.lz-row-move-h { flex-direction: row; }
.lz-question-block[hidden] { display: none; }

/* ---------- Порядок пунктов меню и строк списков ---------- */
.lz-move-btn {
  display: inline-grid; place-items: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 7px;
  background: transparent; color: var(--text-muted); cursor: pointer; transition: background .12s ease, color .12s ease;
}
.lz-move-btn svg { width: 15px; height: 15px; pointer-events: none; }
.lz-move-btn:hover { background: var(--track); color: var(--text); }
.lz-move-btn:disabled { opacity: .3; cursor: default; background: transparent; }
.lz-move-btn:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 1px; }
.lz-bi-name { flex: 1; }
.lz-bi-move { display: inline-flex; flex: none; margin: -4px -4px -4px 0; opacity: 0; transition: opacity .12s ease; }
.lz-block-item:hover .lz-bi-move, .lz-block-item.active .lz-bi-move, .lz-bi-move:focus-within { opacity: 1; }
@media (hover: none) { .lz-bi-move { opacity: 1; } }
.lz-block-empty { margin: 4px 10px 8px; font-size: 12.5px; color: var(--text-muted); }
.lz-row-move { display: inline-flex; flex: none; gap: 1px; }
.lz-question-block .row > .lz-row-move { margin-left: auto; }
/* В строке варианта места мало: стрелки стоят столбиком и занимают одну узкую колонку. */
.lz-option-row > .lz-row-move { flex-direction: column; gap: 0; margin-left: auto; }
.lz-option-row > .lz-row-move .lz-move-btn, .lz-link-side .lz-move-btn { width: 22px; height: 17px; border-radius: 5px; }
.lz-option-row > .lz-row-move .lz-move-btn svg, .lz-link-side .lz-move-btn svg { width: 14px; height: 14px; }
.lz-option-row input[type="text"] { flex-basis: 140px; }
.lz-row-move + .lz-remove { margin-left: 0 !important; }
.lz-link-side { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.lz-link-side .lz-row-move { flex-direction: column; }
.lz-link-row { grid-template-columns: 38px 1fr 30px; }
@keyframes lz-row-flash { from { background-color: var(--accent-soft); } }
.lz-row-moved { animation: lz-row-flash .6s ease; }

/* ---------- Согласие 152-ФЗ ---------- */
.lz-warn { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: #FFF4E0; color: #7A4B10; font-size: 12.5px; line-height: 1.45; }
.lz-consent-preview { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 12px; background: #F6F8FB; box-shadow: inset 0 0 0 1px var(--line); font-size: 12.5px; line-height: 1.45; color: var(--text-muted); }
.lz-consent-check { flex: none; width: 18px; height: 18px; margin-top: 1px; border-radius: 6px; background: #fff; box-shadow: inset 0 0 0 1.5px rgba(20, 25, 34, .22); }
.lz-consent-link { color: var(--accent-ink); font-weight: 500; text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1.5px; pointer-events: none; }

/* ---------- Готовые цветовые шаблоны ---------- */
/* Ровно семь шаблонов в полосе — так их проще сравнивать глазами */
.lz-theme-presets { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 1320px) { .lz-theme-presets { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 900px) { .lz-theme-presets { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.lz-tp { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 0; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; }
.lz-tp-card {
  position: relative; display: flex; flex-direction: column; gap: 6px; padding: 12px 10px 10px; overflow: hidden;
  border-radius: 12px; box-shadow: 0 0 0 1px rgba(20, 25, 34, .10); transition: box-shadow .15s ease, transform .15s ease;
}
.lz-tp:hover .lz-tp-card { transform: translateY(-1px); box-shadow: 0 8px 18px -10px rgba(20, 25, 34, .45), 0 0 0 1px rgba(20, 25, 34, .12); }
.lz-tp.selected .lz-tp-card { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--accent); }
.lz-tp:focus-visible { outline: none; }
.lz-tp:focus-visible .lz-tp-card { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--blue-dark); }
.lz-tp-bar { position: absolute; top: 0; left: 0; right: 0; height: 3px; }
.lz-tp-title { font-size: 12px; font-weight: 700; line-height: 1.1; }
.lz-tp-opt { display: flex; align-items: center; height: 14px; padding: 0 4px; border-radius: 5px; }
.lz-tp-opt i { width: 6px; height: 6px; border-radius: 50%; }
.lz-tp-btn { display: block; padding: 4px 0; border-radius: 6px; font-size: 10.5px; font-weight: 600; line-height: 1.2; text-align: center; }
.lz-tp-name { font-size: 12px; line-height: 1.25; color: var(--text); }
.lz-tp.selected .lz-tp-name { font-weight: 600; }
.lz-contrast-warn { margin: 8px 0 0; padding: 8px 10px; border-radius: 9px; background: var(--danger-soft); color: var(--danger); font-size: 12.5px; line-height: 1.4; }

/* ---------- Свёрнутая кнопка в превью: подпись «развернуть» рядом ---------- */
.lz-pv-mark { overflow: visible; }
.lz-pv-tip { position: absolute; top: 50%; transform: translateY(-50%); padding: 5px 8px; border-radius: 7px; white-space: nowrap; font-size: 10px; line-height: 1; box-shadow: 0 6px 14px -8px rgba(10, 14, 22, .5), 0 0 0 1px rgba(20, 25, 34, .08); }
.lz-pv-tip.left { right: calc(100% + 6px); }
.lz-pv-tip.right { left: calc(100% + 6px); }

/* ---------- Вход и регистрация ---------- */
.lz-auth-page { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px;
  background: radial-gradient(1200px 600px at 85% -10%, rgba(255, 79, 163, .10), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(44, 203, 255, .10), transparent 60%), var(--bg); }
.lz-auth { display: grid; grid-template-columns: 1fr 1fr; width: 100%; max-width: 940px; min-height: 580px; overflow: hidden;
  border-radius: 24px; background: var(--card); box-shadow: 0 40px 80px -40px rgba(11, 18, 32, .35), 0 0 0 1px rgba(11, 18, 32, .05); }
.lz-auth-form { display: flex; flex-direction: column; justify-content: center; padding: 44px 48px; }
.lz-login-logo { display: flex; align-items: center; gap: 10px; font-size: 19px; color: var(--text); }
.lz-auth-title { margin: 28px 0 6px; font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.lz-auth-sub { margin: 0 0 24px; color: var(--text-muted); }
.lz-auth-form .lz-btn-primary { width: 100%; height: 46px; margin-top: 4px; }
.lz-auth-foot { margin: 18px 0 0; font-size: 13px; text-align: center; color: var(--text-muted); }
/* «Глазок» у поля пароля (LZ.passwordToggles в api.js) */
.lz-pass-wrap { position: relative; }
.lz-field .lz-pass-wrap input { padding-right: 44px; }
.lz-pass-eye { position: absolute; top: 50%; right: 6px; display: grid; place-items: center; width: 34px; height: 34px; margin-top: -17px; padding: 0;
  border: 0; border-radius: 9px; background: transparent; color: var(--text-muted); cursor: pointer; }
.lz-pass-eye:hover { color: var(--text); background: var(--bg); }
.lz-pass-eye:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 1px; }
.lz-pass-eye svg { width: 19px; height: 19px; }
/* «Забыли пароль?» — ссылка-кнопка рядом с подписью поля */
.lz-field .lz-label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 6px; }
.lz-field .lz-label-row label { margin-bottom: 0; }
.lz-link-btn { padding: 0; border: 0; background: none; font: inherit; font-size: 12.5px; font-weight: 500; color: var(--accent-ink); cursor: pointer; }
.lz-link-btn:hover { text-decoration: underline; }
.lz-link-btn:focus-visible { outline: 2px solid var(--blue-dark); outline-offset: 2px; border-radius: 4px; }
.lz-auth-art { position: relative; overflow: hidden; background: var(--sidebar); }
.lz-auth-art svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.lz-auth-art-text { position: absolute; left: 36px; right: 36px; bottom: 40px; color: #FFFFFF; }
.lz-auth-art-text b { display: block; font-size: 28px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em; }
.lz-auth-art-text span { display: block; margin-top: 10px; font-size: 14px; color: #AEB8C8; }
@media (max-width: 760px) {
  .lz-auth { grid-template-columns: 1fr; min-height: 0; }
  .lz-auth-art { display: none; }
  .lz-auth-form { padding: 32px 24px; }
}

@media (max-width: 1100px) {
  .lz-workspace-3col { grid-template-columns: 170px minmax(0, 1fr); }
  .lz-workspace-3col .lz-preview-col { grid-column: 2; position: static; }
}

@media (max-width: 800px) {
  .lz-app { flex-direction: column; }
  .lz-sidebar { position: static; width: 100%; height: auto; flex-direction: row; align-items: center; overflow-x: auto; padding: 12px 16px; }
  .lz-logo { padding: 0 10px 0 0; }
  .lz-nav { display: flex; gap: 4px; }
  .lz-sidebar-footer { margin: 0 0 0 auto; padding: 0; border: 0; }
  .lz-user { display: none; }
  .lz-main { padding: 20px 16px 40px; }
  .lz-workspace, .lz-workspace-3col, .lz-content-grid { grid-template-columns: 1fr; }
  .lz-workspace-3col .lz-preview-col { grid-column: auto; }
  .lz-ws-nav, .lz-block-list, .lz-preview-col { position: static; }
  .lz-ws-nav { display: flex; overflow-x: auto; gap: 4px; }
  .lz-link-fields { grid-template-columns: 1fr; }
}
