@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Montserrat:wght@600;700;800&display=swap');

:root {
  --bg: #f7f9fc;
  --surface: #ffffff;
  --surface-alt: #eef4fb;
  --surface-2: #f9fbff;
  --surface-dark: #0f172a;
  --text: #0f172a;
  --text-soft: #475467;
  --text-muted: #667085;
  --white: #ffffff;
  --primary: #0052cc;
  --primary-hover: #003f9e;
  --primary-soft: rgba(0, 82, 204, 0.08);
  --primary-soft-2: rgba(0, 82, 204, 0.14);
  --border: #d9e3f5;
  --border-strong: #c7d5ee;
  --shadow-sm: 0 8px 24px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 18px 48px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 28px 72px rgba(15, 23, 42, 0.12);
  --radius-xs: 10px;
  --radius-sm: 16px;
  --radius-md: 24px;
  --radius-lg: 32px;
  --radius-xl: 40px;
  --radius-pill: 999px;
  --container: 1240px;
  --header-height: 88px;
  --space-1: 8px;
  --space-2: 12px;
  --space-3: 16px;
  --space-4: 20px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 40px;
  --space-8: 48px;
  --space-9: 64px;
  --space-10: 80px;
  --space-11: 100px;
  --space-12: 120px;
  --transition-fast: .2s ease;
  --transition-base: .32s ease;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fbfdff 0%, #f7f9fc 52%, #f4f8fd 100%);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
main { overflow: clip; }

.container {
  width: min(100% - 40px, var(--container));
  margin-inline: auto;
}

.section { padding: var(--space-12) 0; }
.section--compact { padding: var(--space-10) 0; }
.section--soft { background: linear-gradient(180deg, rgba(238,244,251,.64), rgba(255,255,255,.75)); }
.section--topline { border-top: 1px solid rgba(217, 227, 245, .72); }

.grid { display: grid; gap: var(--space-6); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  margin-bottom: 15px;
  border-radius: var(--radius-pill);
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-family: "Montserrat", sans-serif;
  line-height: 1.12;
  letter-spacing: -0.03em;
  overflow-wrap: break-word;
}
h1 { font-size: clamp(2.6rem, 5.4vw, 4.8rem); }
h2 { font-size: clamp(2rem, 3.6vw, 3.4rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.92rem); }
h4 { font-size: 1.12rem; }
p { margin: 0; color: var(--text-soft); overflow-wrap: break-word; }

.btn, .dropdown-card strong, .dropdown-card span {
  overflow-wrap: break-word;
}
.site-nav .nav-list > li > a,
.site-nav .nav-trigger {
  overflow-wrap: normal;
  /* В меню не ломаем слова: лучше единая строка, чем разрезы “по буквам”. */
  white-space: nowrap;
}
.lead { font-size: clamp(1.05rem, 1.6vw, 1.22rem); max-width: 760px; }
.small { font-size: .95rem; color: var(--text-muted); }
.text-center { text-align: center; }

.section-header {
  max-width: 860px;
  margin-bottom: var(--space-8);
}
.section-header.center {
  margin-inline: auto;
  text-align: center;
}
.section-title { margin-top: var(--space-4); }
.section-note { margin-top: var(--space-4); max-width: 720px; }
.section-header.center .section-note { margin-inline: auto; }

.btn-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.mt-16 { margin-top: var(--space-3); }
.mt-20 { margin-top: var(--space-4); }
.mt-24 { margin-top: var(--space-5); }
/* Только кнопки дизайн-системы (.btn--*). Не смешивать с Bootstrap .btn — иначе min-height/pill ломают outline-кнопки и label.btn */
.btn[class*="btn--"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 24px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-weight: 700;
  transition: var(--transition-base);
  cursor: pointer;
}
.btn--primary {
  color: var(--white);
  background: var(--primary);
  box-shadow: var(--shadow-sm);
}
.btn--primary:hover { background: var(--primary-hover); transform: translateY(-2px); }
.btn--secondary {
  background: rgba(255,255,255,.86);
  border-color: var(--border);
  color: var(--text);
}
.btn--secondary:hover { border-color: var(--primary); color: var(--primary); }
.btn--ghost {
  border-color: rgba(255,255,255,.28);
  color: var(--white);
  background: transparent;
}
.btn--ghost:hover { background: rgba(255,255,255,.08); }

.badge-row, .hero-metrics {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.86);
  color: var(--text-soft);
  font-size: .92rem;
  font-weight: 600;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 253, 255, .84);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(217, 227, 245, .88);
}
.btn:focus-visible,
.site-nav a:focus-visible,
.site-nav .nav-trigger:focus-visible,
.nav-toggle:focus-visible,
.lang-switch button:focus-visible {
  outline: 3px solid rgba(0, 82, 204, .32);
  outline-offset: 2px;
}
.header-inner {
  height: var(--header-height);
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.brand img { width: 154px; height: auto; }
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0;
  justify-content: center;
}
.brand-text strong { font-size: 1.8rem; font-weight: 900; }
.brand img {
  /* Фиксируем высоту логотипа, чтобы исключить layout shift при загрузке шрифтов. */
  height: 34px;
  object-fit: contain;
}
.brand-text span { font-size: .84rem; color: var(--text-muted); }

.nav-toggle {
  display: none;
  border: 1px solid var(--border);
  background: #fff;
  width: 50px;
  height: 50px;
  border-radius: var(--radius-sm);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}
.nav-toggle span {
  width: 18px;
  height: 2px;
  background: var(--text);
  display: block;
}

.nav-wrap {
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-nav .nav-list {
  display: flex;
  align-items: center;
  gap: 8px;
}
.site-nav .nav-list > li > a,
.site-nav .nav-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: .95rem;
  color: var(--text-soft);
  border: 0;
  background: transparent;
  cursor: pointer;
  transition: var(--transition-fast);
}
.site-nav .nav-list > li > a:hover,
.site-nav .nav-list > li > a.is-active,
.site-nav .nav-trigger:hover,
.site-nav .nav-trigger.is-active {
  background: var(--primary-soft);
  color: var(--primary);
}
.has-dropdown { position: relative; }
.nav-trigger::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-1px);
}
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  width: min(760px, 88vw);
  padding: 18px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,.98);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  z-index: 60;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  pointer-events: none;
  /* visibility не анимируем: при быстром переключении hover не должно быть “двух открытых” слоёв */
  transition: opacity .08s ease, transform .08s ease;
}
.has-dropdown.is-open .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.dropdown-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.dropdown-card {
  /* Важно: якорь .dropdown-card наследует базовые стили `.site-nav a`
     (display: inline-flex и центрирование), из-за чего strong/span
     укладываются как flex-элементы и начинают визуально наслаиваться.
     Явно фиксируем верстку карточки. */
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  text-align: left;
  min-height: 0;
  gap: 0;

  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: var(--transition-fast);
  background: linear-gradient(180deg, rgba(247,250,254,.85), #fff);
}
.dropdown-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
}
.dropdown-card.is-active {
  border-color: var(--primary);
  background: var(--primary-soft);
}
.dropdown-card strong {
  display: block;
  margin-bottom: 6px;
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  word-break: normal;
}
.dropdown-card span {
  display: block;
  color: var(--text-muted);
  font-size: .9rem;
  line-height: 1.55;
  word-break: normal;
}

/* Language-specific navigation typography
   (единый размер всем языкам не подходит: RU/EN/ZH отличаются по метрикам и плотности). */
[lang="ru"] .site-nav .nav-list > li > a,
[lang="ru"] .site-nav .nav-trigger {
  font-size: 0.98rem;
  padding: 0 12px;
  line-height: 1.12;
}
[lang="ru"] .site-nav .nav-list {
  gap: 6px;
}
[lang="ru"] .dropdown-card strong {
  font-size: 1.06rem;
  line-height: 1.18;
}
[lang="ru"] .dropdown-card span {
  font-size: .92rem;
  line-height: 1.6;
}

[lang="en"] .site-nav .nav-list > li > a,
[lang="en"] .site-nav .nav-trigger {
  font-size: .95rem;
  padding: 0 14px;
  line-height: 1.15;
}
[lang="en"] .dropdown-card strong {
  font-size: 1rem;
  line-height: 1.18;
}
[lang="en"] .dropdown-card span {
  font-size: .9rem;
  line-height: 1.55;
}

[lang="zh"] .site-nav .nav-list > li > a,
[lang="zh"] .site-nav .nav-trigger {
  font-size: .98rem;
  padding: 0 14px;
  line-height: 1.15;
}
[lang="zh"] .dropdown-card strong {
  font-size: .98rem;
  line-height: 1.18;
}
[lang="zh"] .dropdown-card span {
  font-size: .88rem;
  line-height: 1.6;
}
.lang-switch {
  display: inline-flex;
  gap: 6px;
  padding: 6px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.94);
}
.lang-switch button {
  min-width: 48px;
  height: 38px;
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-soft);
  font-weight: 700;
  cursor: pointer;
}
.lang-switch button.is-active {
  background: var(--primary);
  color: var(--white);
}

.hero {
  padding: 36px 0 72px;
}
.page-hero {
  padding: 36px 0 34px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.04fr .96fr;
  gap: 56px;
  align-items: center;
}
.hero-grid > * {
  /* В grid-контейнерах min-width:auto может приводить к горизонтальному переполнению текста.
     Особенно заметно на длинных RU заголовках. */
  min-width: 0;
}
.hero-copy > * + * { margin-top: var(--space-5); }
.hero-copy { min-width: 0; }
.hero-visual {
  position: relative;
}
.figure-panel {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-md);
}
.figure-panel::before {
  content: "";
  position: absolute;
  inset: auto auto -140px -90px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,82,204,.12), rgba(0,82,204,0));
  pointer-events: none;
}
.figure-panel img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid rgba(217,227,245,.9);
  background: #f8fbff;
}
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: var(--space-4);
}
.mini-stat {
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-sm);
}
.mini-stat strong {
  display: block;
  font-size: 1.1rem;
}
.mini-stat span {
  display: block;
  color: var(--text-muted);
  font-size: .9rem;
}

.card {
  height: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.9);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}
.card:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
}
.card__body { padding: 28px; }
.card__icon,
.card__number {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 800;
}
.card__body > * + * { margin-top: 14px; }

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.metric {
  padding: 22px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.92);
  transition: var(--transition-fast);
}
.metric:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
}
.metric strong {
  display: block;
  font-size: 1.55rem;
  margin-bottom: 8px;
}

.band {
  display: grid;
  grid-template-columns: 1.08fr .92fr;
  gap: 28px;
  align-items: center;
  padding: 30px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.94);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}
.band:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
}
.band--accent {
  background: linear-gradient(135deg, rgba(0,82,204,.95), rgba(33,114,235,.88));
  color: var(--white);
  border-color: rgba(0,82,204,.24);
}
.band--accent p,
.band--accent li,
.band--accent .small { color: rgba(255,255,255,.92); }
.band--accent .eyebrow {
  background: rgba(255,255,255,.14);
  color: rgba(255,255,255,.95);
}
.band img {
  border-radius: var(--radius-md);
  border: 1px solid rgba(217,227,245,.9);
  background: #fff;
}
.band-copy > * + * { margin-top: var(--space-3); }

.list-check {
  display: grid;
  gap: 12px;
}
.list-check li {
  position: relative;
  padding-left: 28px;
  color: var(--text-soft);
}
.list-check li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .58em;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--primary);
}
.band--accent .list-check li {
  color: rgba(255,255,255,.96);
}
.band--accent .list-check li::before { background: var(--white); }

.tile-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.tile {
  padding: 24px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(247,250,254,.9));
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}
.tile:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
}
.tile h3, .tile h4 { margin-bottom: 10px; }

.timeline {
  display: grid;
  gap: 16px;
}
.timeline-item {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 16px;
  align-items: start;
  padding: 20px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.94);
}
.timeline-item__num {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-alt);
  color: var(--primary);
  font-weight: 800;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.related-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 22px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.96);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}
.related-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
}
.related-card strong {
  font-family: "Montserrat", sans-serif;
  font-size: 1.06rem;
}
.related-card span {
  color: var(--text-muted);
  font-size: .94rem;
}
.related-card .link-arrow {
  margin-top: auto;
  color: var(--primary);
  font-weight: 700;
}

.contact-slab {
  padding: 32px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, #0f172a, #14233f);
  color: var(--white);
  box-shadow: var(--shadow-lg);
}
.contact-slab p,
.contact-slab .small { color: rgba(255,255,255,.78); }
.contact-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 28px;
  align-items: center;
}
.contact-lines {
  display: grid;
  gap: 14px;
}
.contact-chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius-pill);
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  color: var(--white);
  width: fit-content;
}

.logo-cloud {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}
.pill {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 64px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.96);
  font-weight: 700;
  color: var(--text-soft);
}

.case-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.case-card {
  overflow: hidden;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.96);
  box-shadow: var(--shadow-sm);
}
.case-card img {
  width: 100%;
  aspect-ratio: 1.35 / 1;
  object-fit: cover;
  background: #f7fbff;
}
.case-card__body {
  padding: 20px;
}
.case-card__body > * + * { margin-top: 10px; }

.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.note-box {
  padding: 22px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,.94);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.note-box strong {
  display: block;
  margin-bottom: 10px;
  font-family: "Montserrat", sans-serif;
}

.kicker-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.kicker {
  padding: 18px 20px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.92);
}
.kicker strong {
  display: block;
  font-family: "Montserrat", sans-serif;
  margin-bottom: 8px;
}

.placeholder-shell {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1.5px dashed var(--border-strong);
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(247,250,254,.88));
  min-height: 280px;
  display: grid;
  place-items: center;
  text-align: center;
}
.placeholder-shell__inner {
  max-width: 520px;
}
.placeholder-shell__icon {
  width: 76px;
  height: 76px;
  margin: 0 auto 20px;
  border-radius: var(--radius-md);
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.6rem;
}

.site-footer {
  padding: 48px 0 28px;
  background: var(--surface);
  border-top: 1px solid rgba(217, 227, 245, .92);
  color: var(--text);
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) minmax(0, 1.15fr) auto;
  gap: 24px 32px;
  align-items: center;
  padding-bottom: 32px;
}

.footer-top__brand .brand {
  align-self: center;
}

.footer-top__block {
  display: grid;
  gap: 6px;
  align-content: center;
  justify-items: start;
  min-width: 0;
}

.footer-top__block--support {
  justify-items: start;
}

.footer-caption {
  font-size: .82rem;
  color: var(--text-muted);
  line-height: 1.35;
}

.footer-phone {
  font-family: "Montserrat", sans-serif;
  font-size: clamp(1.05rem, 1.35vw, 1.25rem);
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  transition: var(--transition-fast);
}

.footer-phone:hover,
.footer-phone:focus-visible {
  color: var(--primary);
}

.footer-email {
  font-weight: 700;
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: var(--transition-fast);
}

.footer-email:hover,
.footer-email:focus-visible {
  color: var(--primary);
}

.footer-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--text);
  font-weight: 700;
  font-size: .95rem;
  text-decoration: none;
  transition: var(--transition-base);
  white-space: nowrap;
}

.footer-cta:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.footer-cta:focus-visible {
  outline: 3px solid rgba(0, 82, 204, .32);
  outline-offset: 2px;
}

.footer-mid {
  padding: 32px 0;
  border-top: 1px solid var(--border);
}

/* Меню футера: 1 колонка (узкий мобильный), 2 колонки (широкий мобильный / планшет), 4 на десктопе */
.footer-nav-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px 28px;
  align-items: start;
}

@media (min-width: 480px) {
  .footer-nav-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .footer-nav-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px 32px;
  }
}

.footer-nav-col {
  display: grid;
  gap: 12px;
  align-content: start;
  justify-items: start;
}

.footer-nav-col strong {
  font-family: "Montserrat", sans-serif;
  font-size: .95rem;
  color: var(--text);
  margin-bottom: 2px;
}

.footer-nav-col a {
  color: var(--text-soft);
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  padding: 2px 0;
  border-radius: 6px;
  transition: var(--transition-fast);
}

.footer-nav-col a:hover {
  color: var(--primary);
}

.footer-nav-col a:focus-visible {
  outline: 3px solid rgba(0, 82, 204, .32);
  outline-offset: 2px;
}

.footer-bottom {
  padding-top: 22px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px 32px;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: .92rem;
}

.footer-bottom__left {
  display: grid;
  gap: 6px;
  max-width: 520px;
}

.footer-bottom__left > span:first-child {
  color: var(--text-soft);
  font-weight: 600;
}

.footer-address {
  line-height: 1.45;
}

.footer-bottom__note {
  margin: 0;
  max-width: 420px;
  line-height: 1.45;
  text-align: right;
}

@media (max-width: 900px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }
  .footer-cta {
    grid-column: 1 / -1;
    justify-self: start;
  }
  .footer-bottom__note {
    text-align: left;
  }
}

@media (max-width: 640px) {
  .footer-top {
    grid-template-columns: 1fr;
  }
}

/* Статические HTML в frontend: старая разметка футера */
.footer-grid {
  display: grid;
  grid-template-columns: 1.25fr .75fr .75fr;
  gap: 28px;
  align-items: start;
}
.footer-description {
  margin-top: var(--space-4);
  max-width: 520px;
}
.footer-nav,
.footer-contacts {
  display: grid;
  gap: 10px;
  align-content: start;
  justify-items: start;
}
.footer-contacts {
  gap: 6px;
}
.footer-contacts a {
  padding: 6px 12px;
}
.footer-nav a,
.footer-contacts a {
  color: var(--text-soft);
  font-weight: 600;
  padding: 8px 12px;
  border-radius: var(--radius-pill);
  transition: var(--transition-fast);
  display: inline-flex;
  align-items: center;
  width: fit-content;
}
.footer-nav a:hover,
.footer-contacts a:hover {
  color: var(--primary);
  background: var(--primary-soft);
}
.footer-nav a:focus-visible,
.footer-contacts a:focus-visible {
  outline: 3px solid rgba(0, 82, 204, .32);
  outline-offset: 2px;
}
.footer-nav strong,
.footer-contacts strong {
  font-family: "Montserrat", sans-serif;
}
.footer-contacts a,
.footer-contacts span {
  display: inline;
  width: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  line-height: 1.45;
}
.footer-contacts a {
  color: var(--text);
  font-weight: 600;
}
.footer-contacts a:hover,
.footer-contacts a:focus-visible {
  color: var(--primary);
  background: transparent;
  text-decoration: underline;
  outline: none;
}
.footer-grid + .footer-bottom {
  margin-top: 28px;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Auth / 404 (единый визуальный язык сайта) */
.auth-shell {
  display: grid;
  grid-template-columns: 1.04fr .96fr;
  gap: 56px;
  align-items: center;
}

.auth-panel {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.94);
  box-shadow: var(--shadow-sm);
}

.auth-side {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(217,227,245,.85);
  background: rgba(255,255,255,.86);
}

.field {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.field:first-child {
  margin-top: 0;
}

.field > span {
  font-weight: 700;
  color: var(--text);
  font-size: .95rem;
}

.field input {
  width: 100%;
  height: 52px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: #fff;
  padding: 0 14px;
  outline: none;
  transition: var(--transition-fast);
}

.field input:focus {
  border-color: rgba(0, 82, 204, .55);
  box-shadow: 0 0 0 4px rgba(0, 82, 204, .14);
}

.auth-links {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.auth-links a {
  color: var(--primary);
  font-weight: 700;
  transition: var(--transition-fast);
}

.auth-links a:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

.auth-actions {
  margin-top: 18px;
}

.auth-side img {
  width: 100%;
  margin-top: 16px;
}

.helper-list {
  display: grid;
  gap: 10px;
}

.notfound-wrap {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 56px;
  align-items: center;
}

.error-code {
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 800;
  font-family: "Montserrat", sans-serif;
  color: var(--text);
  line-height: 1;
}

.notfound-panel {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.94);
  box-shadow: var(--shadow-sm);
}

.notfound-illustration {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(217,227,245,.85);
  background: rgba(255,255,255,.86);
}

.notfound-illustration img {
  width: 100%;
  margin-top: 18px;
}

/* Сообщение об ошибке (404 и аналогичные экраны в ЛК) */
.error__section {
  padding: var(--space-8) 0 var(--space-10);
}

.error__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 28rem;
  margin-inline: auto;
}

.error__illustration {
  box-sizing: border-box;
  width: min(300px, 88vw);
  margin: 0 auto var(--space-6);
  padding: 18px 20px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-sm);
  color: var(--primary);
}

.error__illustration svg {
  width: 100%;
  height: auto;
  display: block;
}

.error__content--title {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: clamp(1.2rem, 3.6vw, 1.65rem);
  line-height: 1.3;
  margin: 0 0 var(--space-4);
  color: var(--text);
  text-wrap: balance;
}

.error__content--desc:empty {
  display: none;
}

.error__content--desc:not(:empty) {
  margin: 0 0 var(--space-4);
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.55;
}

.error__content--btn {
  margin-top: var(--space-2);
}

@media (max-width: 1120px) {
  .hero-grid,
  .band,
  .contact-grid,
  .footer-grid,
  .grid-2,
  .two-column,
  .auth-shell,
  .notfound-wrap {
    grid-template-columns: 1fr;
  }
  .grid-3, .tile-grid, .case-gallery, .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .grid-4, .metric-grid, .logo-cloud, .kicker-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .auth-shell { gap: 28px; }
  .auth-panel,
  .auth-side { padding: 22px; }
  .notfound-wrap { gap: 28px; }
  .nav-wrap {
    position: absolute;
    left: 20px;
    right: 20px;
    top: calc(100% + 12px);
    padding: 18px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: rgba(255,255,255,.98);
    box-shadow: var(--shadow-lg);
    display: none;
    align-items: stretch;
    flex-direction: column;
    /* Чтобы при длинном меню не “упиралось” в нижний край viewport:
       скролл должен быть внутри выпадающего меню, а не всей страницы. */
    max-height: calc(100vh - var(--header-height) - 20px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .nav-wrap.is-open { display: flex; }
  .site-nav .nav-list {
    flex-direction: column;
    align-items: stretch;
  }
  .site-nav .nav-list > li {
    width: 100%;
  }
  .site-nav .nav-list > li > a,
  .site-nav .nav-trigger {
    width: 100%;
    justify-content: space-between;
  }
  .nav-dropdown {
    position: static;
    width: 100%;
    margin-top: 0;
    box-shadow: none;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: none;
    pointer-events: none;
    transition: none;
    padding: 0;
  }
  .has-dropdown.is-open .nav-dropdown {
    max-height: none;
    overflow: visible;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    /* Возвращаем реальные отступы карточек dropdown в открытом состоянии. */
    margin-top: var(--space-1);
    padding: 18px;
  }
  .dropdown-grid {
    grid-template-columns: 1fr;
  }
  .hero,
  .page-hero {
    padding: 72px 0 44px;
  }
  .hero-stats, .grid-3, .grid-4, .tile-grid, .case-gallery, .related-grid, .metric-grid, .logo-cloud, .kicker-grid {
    grid-template-columns: 1fr;
  }
  .brand img { width: 140px; }

  /* На mobile dropdown открывается кликом: отключаем hover-движения карточек. */
  .dropdown-card:hover {
    transform: none;
    border-color: var(--border);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { transition: none; transform: none; opacity: 1; }
  .nav-dropdown { transition: none; }
  .card, .tile, .metric, .band, .dropdown-card, .related-card {
    transition: none !important;
  }
  .card:hover, .tile:hover, .metric:hover, .band:hover,
  .dropdown-card:hover, .related-card:hover {
    transform: none !important;
  }
}

@media (max-width: 560px) {
  .container { width: min(100% - 28px, var(--container)); }
  .section { padding: 84px 0; }
  .hero, .page-hero { padding: 58px 0 30px; }
  .field input { height: 48px; }
  .card__body, .contact-slab, .band, .tile, .related-card, .placeholder-shell {
    padding: 22px;
  }
  .timeline-item {
    grid-template-columns: 46px 1fr;
  }
  .timeline-item__num {
    width: 46px;
    height: 46px;
  }
  .footer-bottom { flex-direction: column; }
}

/* =============================================================================
   LK, Bootstrap, сделки (default-theme)
   Логика и селекторы как в individual-theme.css; значения — токены default-design.
   ============================================================================= */

:root {
  /* Совместимость: разметка / инлайн могут ссылаться на --rh-* */
  --rh-radius: var(--radius-md);
  --rh-radius-sm: var(--radius-sm);
  --rh-font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --lk-danger: #c62828;
  --lk-danger-hover: #b71c1c;

  --lk-sidebar-scrollbar-track: rgba(255, 255, 255, 0.06);
  --lk-sidebar-scrollbar-thumb: color-mix(in srgb, var(--primary) 50%, transparent);
  --lk-sidebar-scrollbar-thumb-hover: color-mix(in srgb, var(--border-strong) 65%, var(--primary) 35%);

  /* Палитра --rh-* для компонентов (list, notify, loyalty): перекрывается individual-theme.css */
  --rh-charcoal: var(--text);
  --rh-green-900: var(--primary);
  --rh-green-800: var(--primary-hover);
  --rh-green-700: var(--primary);
  --rh-sand-100: var(--bg);
  --rh-sand-200: var(--surface-alt);
  --rh-sand-300: var(--border-strong);
  --rh-sand-400: var(--border-strong);
  --rh-border: var(--border);
  --rh-shadow: var(--shadow-md);
  --rh-shadow-sm: var(--shadow-sm);
  --rh-link: var(--primary);
  --rh-accent: var(--primary-soft-2);
  --rh-danger: #c62828;
}

@supports not (color: color-mix(in srgb, red, blue)) {
  :root {
    --lk-sidebar-scrollbar-thumb: rgba(0, 82, 204, 0.45);
    --lk-sidebar-scrollbar-thumb-hover: rgba(199, 213, 238, 0.75);
  }
}

/* Кабинет: плоский фон и типографика вместо «маркетингового» градиента body */
html,
body {
  height: 100%;
}

body[data-page="app"],
body[data-page="login"] {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

/*
 * Ссылки в ЛК: акцент --primary. Не трогаем .btn — иначе перебиваем Bootstrap
 * (body[data-page] a сильнее .btn по специфичности, текст кнопок становится «синим»).
 */
body[data-page="app"] a:not(.btn):not(.nav-link):not(.dropdown-item),
body[data-page="login"] a:not(.btn):not(.nav-link):not(.dropdown-item) {
  color: var(--primary);
  text-decoration: none;
}

body[data-page="app"] a:not(.btn):not(.nav-link):not(.dropdown-item):hover,
body[data-page="login"] a:not(.btn):not(.nav-link):not(.dropdown-item):hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

/* Явно возвращаем цвет текста кнопкам (на случай других глобальных правил) */
body[data-page="app"] .btn,
body[data-page="login"] .btn {
  color: var(--bs-btn-color);
}

/*
 * Иначе правило выше сильнее Bootstrap .btn:hover — при hover фон заливается (--bs-btn-hover-bg),
 * а текст остаётся --bs-btn-color (контурный цвет) и сливается с фоном. То же для :active.
 */
body[data-page="app"] .btn:hover:not(:disabled),
body[data-page="login"] .btn:hover:not(:disabled),
body[data-page="app"] .btn:focus-visible:not(:disabled),
body[data-page="login"] .btn:focus-visible:not(:disabled) {
  color: var(--bs-btn-hover-color, var(--bs-btn-color));
}

body[data-page="app"] .btn:active:not(:disabled),
body[data-page="login"] .btn:active:not(:disabled) {
  color: var(--bs-btn-active-color, var(--bs-btn-hover-color, var(--bs-btn-color)));
}

/* Ссылки-кнопки <a class="btn …"> — выше специфичность, чем у глобальных правил для a */
body[data-page="app"] a.btn,
body[data-page="login"] a.btn {
  color: var(--bs-btn-color);
  text-decoration: none;
}
body[data-page="app"] a.btn:hover,
body[data-page="login"] a.btn:hover {
  color: var(--bs-btn-hover-color, var(--bs-btn-color));
}

/*
 * Bootstrap: label.btn (btn-check), .btn-outline-* во flex-сетках не растягиваются
 * по высоте; иконки .bi не сжимаются/не «ломают» высоту ряда.
 */
body[data-page="app"] label.btn,
body[data-page="login"] label.btn,
.lk-main label.btn {
  align-self: center;
  flex: 0 0 auto;
  width: auto;
  max-width: 100%;
}

body[data-page="app"] i.bi,
body[data-page="login"] i.bi,
body[data-page="app"] .bi[class*="bi-"],
body[data-page="login"] .bi[class*="bi-"],
.lk-main i.bi,
.lk-main .bi[class*="bi-"] {
  flex-shrink: 0;
  line-height: 1;
  display: inline-block;
  vertical-align: -0.125em;
}

body[data-page="app"] .btn i.bi,
body[data-page="login"] .btn i.bi,
body[data-page="app"] label.btn .bi,
body[data-page="login"] label.btn .bi,
.lk-main .btn i.bi,
.lk-main label.btn .bi {
  vertical-align: -0.15em;
}

/* Второстепенные ссылки в шапках карточек (как неактивные пункты меню в style.css) */
body[data-page="app"] .rh-card-header a.small:not(.btn),
body[data-page="login"] .rh-card-header a.small:not(.btn) {
  color: var(--text-soft);
}
body[data-page="app"] .rh-card-header a.small:not(.btn):hover,
body[data-page="login"] .rh-card-header a.small:not(.btn):hover {
  color: var(--primary);
}

/* Дашборд: реферальный блок */
body[data-page="app"] .dash-referral-card .dash-referral-stat__value {
  color: var(--text);
}

/* Layout */
.lk-shell {
  min-height: 100%;
  display: flex;
}

.lk-sidebar {
  --lk-sidebar-w: 262px;
  width: var(--lk-sidebar-w);
  background: linear-gradient(180deg, #0b1629 0%, var(--surface-dark) 100%);
  color: #fff;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  transition: width 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

.lk-sidebar-inner {
  box-sizing: border-box;
  width: var(--lk-sidebar-w);
  min-width: var(--lk-sidebar-w);
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.lk-sidebar-inner > nav {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  padding-right: 0.35rem !important;
  scrollbar-width: thin;
  scrollbar-color: var(--lk-sidebar-scrollbar-thumb) var(--lk-sidebar-scrollbar-track);
}

.lk-sidebar-inner > nav::-webkit-scrollbar {
  width: 6px;
}

.lk-sidebar-inner > nav::-webkit-scrollbar-track {
  background: var(--lk-sidebar-scrollbar-track);
  border-radius: 100px;
  margin: 10px 0;
}

.lk-sidebar-inner > nav::-webkit-scrollbar-thumb {
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--primary) 35%, transparent),
    color-mix(in srgb, var(--border-strong) 55%, var(--primary) 45%)
  );
  border-radius: 100px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}

.lk-sidebar-inner > nav::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(
    180deg,
    var(--lk-sidebar-scrollbar-thumb-hover),
    color-mix(in srgb, var(--primary) 55%, var(--border-strong) 45%)
  );
}

@supports not (color: color-mix(in srgb, red, blue)) {
  .lk-sidebar-inner > nav::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(90, 140, 220, 0.55), rgba(0, 82, 204, 0.45));
  }
  .lk-sidebar-inner > nav::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(180, 200, 235, 0.85), rgba(0, 82, 204, 0.55));
  }
}

.lk-brand {
  flex-shrink: 0;
  padding: 16px 16px 10px 16px;
}

.lk-brand .logo {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: var(--radius-xs);
  background: var(--primary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-weight: 700;
  overflow: hidden;
}

.lk-brand .logo .lk-brand-logo__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lk-brand .title {
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 12px;
  opacity: 0.9;
}

.lk-sidebar .nav.flex-column {
  gap: 0.28rem !important;
}

.lk-sidebar .nav-link {
  color: rgba(255, 255, 255, 0.85);
  border-radius: 11px;
  padding: 8px 11px;
  font-size: 0.95rem;
}

.lk-sidebar .nav-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.lk-sidebar .nav-link.active {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.lk-sidebar .nav .nav {
  padding-left: 10px;
}

.lk-sidebar-copyright {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.78rem;
}

.lk-sidebar-copyright a {
  color: rgba(147, 197, 253, 0.95) !important;
  text-decoration: none !important;
}

.lk-sidebar-copyright a:hover {
  color: rgba(255, 255, 255, 0.95);
  text-decoration: underline;
}

.lk-main .nav-pills .nav-link.active,
.lk-main .nav-pills .show > .nav-link,
.lk-content .nav-pills .nav-link.active,
.lk-content .nav-pills .show > .nav-link {
  background-color: var(--primary);
  color: #fff;
}

.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
  background-color: var(--primary);
  color: #fff;
}

.lk-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.lk-topbar {
  background: rgba(251, 253, 255, 0.86);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

@media (min-width: 768px) {
  html.sidebar-collapsed .lk-sidebar,
  body.sidebar-collapsed .lk-sidebar {
    width: 0;
    min-width: 0;
    padding: 0 !important;
    border-right: 0;
    overflow: hidden;
    pointer-events: none;
  }
}

.lk-topbar .lk-sidebar-collapse-toggler {
  border-color: rgba(15, 23, 42, 0.2);
  padding: 0.4rem 0.6rem;
  color: var(--text);
  background: transparent;
}

.lk-sidebar-collapse-icon {
  width: 1.25em;
  height: 1.75em;
  display: inline-block;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
}

.lk-topbar .lk-sidebar-collapse-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%230f172a' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.lk-topbar .lk-sidebar-collapse-toggler:focus {
  box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.25);
}

@media (min-width: 768px) {
  body:not(.sidebar-collapsed) .lk-topbar .lk-sidebar-collapse-toggler--topbar {
    display: none !important;
  }
  body.sidebar-collapsed .lk-topbar .lk-sidebar-collapse-toggler--topbar {
    display: inline-flex !important;
  }
  body.sidebar-collapsed .lk-sidebar-collapse-toggler--brand {
    display: none !important;
  }
}

.lk-sidebar .lk-sidebar-collapse-toggler--brand {
  margin-left: auto;
  border: none !important;
  background: rgba(255, 255, 255, 0);
  color: #fff;
}

.lk-sidebar .lk-sidebar-collapse-toggler--brand:hover {
  background: rgba(255, 255, 255, 0.12);
}

.lk-sidebar .lk-sidebar-collapse-toggler--brand:focus {
  box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.28);
}

.lk-sidebar .lk-sidebar-collapse-toggler--brand .lk-sidebar-collapse-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23ffffff' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.lk-main {
  padding: 22px;
  z-index:1000!important;
}

.rh-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.rh-card .rh-card-header {
  padding: 16px 18px;
}

.rh-card .rh-card-body {
  padding: 18px;
}

.rh-muted {
  color: var(--text-muted);
}

.btn-rh {
  --bs-btn-bg: var(--primary);
  --bs-btn-border-color: var(--primary);
  --bs-btn-hover-bg: var(--primary-hover);
  --bs-btn-hover-border-color: var(--primary-hover);
  --bs-btn-color: #fff;
  --bs-btn-hover-color: #fff;
  --bs-btn-active-bg: var(--primary-hover);
  --bs-btn-active-border-color: var(--primary-hover);
  /* Иначе у :disabled подтягиваются чужие --bs-btn-disabled-* с предков → белый текст на светлом фоне */
  --bs-btn-disabled-color: #fff;
  --bs-btn-disabled-bg: var(--bs-btn-bg);
  --bs-btn-disabled-border-color: var(--bs-btn-border-color);
  border-radius: var(--radius-pill);
  padding: 0.55rem 1rem;
}

.btn-rh-outline {
  --bs-btn-color: var(--primary);
  --bs-btn-border-color: var(--primary);
  --bs-btn-hover-bg: var(--primary);
  --bs-btn-hover-border-color: var(--primary);
  --bs-btn-hover-color: #fff;
  --bs-btn-active-bg: var(--primary);
  --bs-btn-active-border-color: var(--primary);
  --bs-btn-active-color: #fff;
  --bs-btn-disabled-color: var(--primary);
  --bs-btn-disabled-bg: transparent;
  --bs-btn-disabled-border-color: var(--bs-btn-border-color);
  --bs-btn-focus-box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.25);
  border-radius: var(--radius-pill);
  padding: 0.55rem 1rem;
}

.btn-rh-outline:active,
.btn-rh-outline.active {
  background-color: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.btn-rh-outline:active:focus-visible,
.btn-rh-outline.active:focus-visible {
  box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.25);
}

.btn-check:checked + .btn-rh-outline,
.btn-check:focus-visible + .btn-rh-outline {
  background-color: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.btn-check:active + .btn-rh-outline {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #fff;
}

.btn-rh-outline-danger {
  --bs-btn-color: var(--lk-danger);
  --bs-btn-border-color: var(--lk-danger);
  --bs-btn-hover-bg: var(--lk-danger);
  --bs-btn-hover-border-color: var(--lk-danger);
  --bs-btn-hover-color: #fff;
  --bs-btn-active-bg: var(--lk-danger-hover);
  --bs-btn-active-border-color: var(--lk-danger-hover);
  --bs-btn-active-color: #fff;
  --bs-btn-focus-box-shadow: 0 0 0 0.2rem rgba(198, 40, 40, 0.25);
  border-radius: var(--radius-pill);
  padding: 0.55rem 1rem;
}

.btn-rh-outline-danger:active,
.btn-rh-outline-danger.active {
  background-color: var(--lk-danger-hover);
  border-color: var(--lk-danger-hover);
  color: #fff;
}

.btn-rh-outline-danger:active:focus-visible,
.btn-rh-outline-danger.active:focus-visible {
  box-shadow: 0 0 0 0.2rem rgba(198, 40, 40, 0.25);
}

.badge-rh {
  background: var(--primary-soft);
  color: var(--primary);
  border-radius: var(--radius-pill);
  padding: 0.35rem 0.6rem;
}

.form-control,
.form-select {
  border-radius: var(--radius-xs);
  border-color: rgba(15, 23, 42, 0.16);
}

.form-control:focus,
.form-select:focus {
  border-color: rgba(0, 82, 204, 0.55);
  box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.15);
}

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.table-toolbar {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.tabulator {
  border: none !important;
  font-size: 14px;
}

.tabulator .tabulator-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.tabulator .tabulator-row {
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.tabulator .tabulator-row.tabulator-selected {
  background: rgba(0, 82, 204, 0.08) !important;
}

.tabulator .tabulator-footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
}

@media (max-width: 991.98px) {
  .lk-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--lk-sidebar-w, 262px);
    height: 100vh;
    z-index: 1050;
    transform: translateX(-100%);
    transition: transform 0.25s ease-out;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
  }
  body.sidebar-open .lk-sidebar {
    transform: translateX(0);
    z-index: 1100;
  }
  .lk-sidebar .lk-brand {
    padding-right: 3rem;
  }
  .lk-sidebar-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: var(--radius-xs);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    line-height: 1;
  }
  .lk-sidebar-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
  }
  .lk-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1040;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
  }
  body.sidebar-open .lk-sidebar-backdrop {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }
  .lk-topbar .navbar-toggler {
    border-color: rgba(15, 23, 42, 0.2);
    padding: 0.4rem 0.6rem;
    color: var(--text);
  }
  .lk-topbar .navbar-toggler-icon {
    width: 1.25em;
    height: 1.25em;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%230f172a' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
  }
  .lk-topbar .navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 82, 204, 0.25);
  }
  .lk-main {
    padding: 16px;
    z-index:1000!important;
  }
}

/* Переменные для deal-ui и tabulator */
:root {
  --panel: var(--surface);
  --card: var(--surface);
  --card2: color-mix(in srgb, var(--surface-alt) 85%, transparent);
  --muted: var(--text-muted);
  --muted2: color-mix(in srgb, var(--text-soft) 75%, transparent);
  --accent: var(--primary);
  --accent2: var(--primary-hover);
  --radius: var(--radius-md);
  --radius2: var(--radius-sm);
  --gap: 14px;
  --shadow: var(--shadow-sm);
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

@supports not (color: color-mix(in srgb, red, blue)) {
  :root {
    --card2: rgba(238, 244, 251, 0.72);
    --muted2: rgba(71, 84, 103, 0.75);
  }
}

.dealListApp .btn,
.dealCard .btn {
  font-family: var(--sans);
  font-weight: 700;
}

.dealListApp .btn--tiny,
.dealCard .btn--tiny {
  font-size: 13px;
  padding: 0.35rem 0.65rem;
}

.dealListApp .btn--primary,
.dealCard .btn--primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.dealListApp .btn--primary:hover,
.dealListApp .btn--primary:focus-visible,
.dealCard .btn--primary:hover,
.dealCard .btn--primary:focus-visible {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #fff;
}

/* <a class="btn btn--primary"> — глобальное a.btn задаёт color: var(--bs-btn-color); поднимаем специфичность */
body[data-page="app"] .dealListApp a.btn--primary,
body[data-page="login"] .dealListApp a.btn--primary,
body[data-page="app"] .dealCard a.btn--primary,
body[data-page="login"] .dealCard a.btn--primary {
  color: #fff;
  text-decoration: none;
}

body[data-page="app"] .dealListApp a.btn--primary:hover,
body[data-page="app"] .dealListApp a.btn--primary:focus-visible,
body[data-page="login"] .dealListApp a.btn--primary:hover,
body[data-page="login"] .dealListApp a.btn--primary:focus-visible,
body[data-page="app"] .dealCard a.btn--primary:hover,
body[data-page="app"] .dealCard a.btn--primary:focus-visible,
body[data-page="login"] .dealCard a.btn--primary:hover,
body[data-page="login"] .dealCard a.btn--primary:focus-visible {
  color: #fff;
}

.dealListApp .btn--ghost,
.dealCard .btn--ghost {
  background: transparent;
}

.dealBulkIsland {
  font-family: var(--sans);
}

.dealBulkIsland__count {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
}

.dealBulkIsland .select,
.dealBulkIsland .input {
  font-family: var(--sans);
  font-size: 14px;
}

.dealListTableCard .card__header,
.dealCard .card__header {
  font-family: var(--sans);
}

.dealListEmpty,
.dealListEmpty__title {
  font-family: var(--sans);
}

.dealListEmpty__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.dealListEmpty {
  font-size: 14px;
  color: var(--text-muted);
}

.dealListApp .input,
.dealListApp .select,
.dealListApp .textarea,
.dealCard .input,
.dealCard .select,
.dealCard .textarea {
  font-family: var(--sans);
  font-size: 14px;
  border-radius: var(--radius-sm);
  border-color: var(--border);
}

.dealCard .card__title,
.dealCard .dealHeader .dealTitle__input,
.dealCard .dealHeader .dealTitle__value,
.dealCard .detailsSection__title,
.dealCard .kpi__title,
.dealCard .kpi__value,
.dealCard .dealHeader__label,
.dealCard .summaryLine__label {
  font-family: var(--sans);
}

.dealCard .card__subtitle,
.dealCard .dealTitle__sub,
.dealCard .kpi__title,
.dealCard .dealHeader__label {
  font-size: 12px;
}

.dealCard .kpi__value {
  font-size: 16px;
  font-weight: 800;
}

.dealCard .kpi__value--secondary {
  font-size: 13px;
  font-weight: 700;
}

.dealCard .tab {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 14px;
}

.dealListApp .contactsTable.tabulator,
.dealCard .contactsTable.tabulator {
  font-family: var(--sans) !important;
  font-size: 14px !important;
}

.dealListApp .contactsTable.tabulator .tabulator-header .tabulator-col .tabulator-col-title,
.dealCard .contactsTable.tabulator .tabulator-header .tabulator-col .tabulator-col-title {
  font-family: var(--sans);
  font-size: 14px;
}

.dealListApp .contactsTable.tabulator .tabulator-row .tabulator-cell,
.dealCard .contactsTable.tabulator .tabulator-row .tabulator-cell {
  font-size: 14px !important;
}

.dealCard .funnel__stage-text {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
}

.dealCard .detailsRow dt,
.dealCard .detailsRow dd,
.dealCard .badge {
  font-family: var(--sans);
}

.dealCard .badge {
  font-size: 12px;
  font-weight: 700;
}

.dealCard .detailsSection__title {
  font-size: 1rem;
  font-weight: 700;
}

.dealCard .detailsRow dt {
  font-weight: 650;
}


/* =============================================================================
   Компоненты boostodromlk — перенесено из templates/.../style.css и инлайнов
   Токены --rh-* в default-theme сопоставлены дизайн-системе; individual-theme
   переопределяет :root --rh-*.
   ============================================================================= */

/* --- boostodrom_loyalty (было: templates/.default/style.css) --- */
.loyalty-status-badge-wrap {
  display: inline-block;
}

.loyalty-status-badge {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.4);
  color: #fff;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

.loyalty-status-badge--bronze {
  background: linear-gradient(145deg, #c9a227 0%, #8b6914 50%, #6b5210 100%);
}

.loyalty-status-badge--silver {
  background: linear-gradient(145deg, #c0c0c0 0%, #8a8a8a 50%, #5a5a5a 100%);
}

.loyalty-status-badge--gold {
  background: linear-gradient(145deg, #e8c547 0%, #c9a227 50%, #a67c00 100%);
}

.loyalty-status-badge--platinum {
  background: linear-gradient(145deg, #e5e4e2 0%, #a8a8a8 50%, #6b6b6b 100%);
  color: #2c2c2c;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.loyalty-status-badge--vip {
  background: linear-gradient(145deg, #4a0080 0%, #2d0050 50%, #1a0030 100%);
  box-shadow: 0 2px 12px rgba(74, 0, 128, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.loyalty-status-badge:not([class*="--"]) {
  background: linear-gradient(145deg, #6c757d 0%, #495057 100%);
}

.boostodrom-loyalty-statuses .loyalty-status-badge {
  padding: 0.35rem 1rem;
  font-size: 0.95rem;
}

.loyalty-progress-card .rh-card-body {
  border-radius: inherit;
}

.loyalty-progress-track {
  background-color: var(--bs-light, #f8f9fa) !important;
}

.loyalty-progress-fill {
  background: linear-gradient(90deg, var(--rh-green-700, #0d6efd) 0%, var(--rh-green-900, #0a58ca) 100%);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05);
}

.loyalty-progress-badge {
  background: linear-gradient(135deg, var(--rh-green-700, #0d6efd) 0%, var(--rh-green-900, #0a58ca) 100%);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
}

.tracking-wide {
  letter-spacing: 0.05em;
}

/* --- boostodrom_list (было: templates/.default/style.css) --- */
.list-card .rh-card-body {
  padding-top: 0;
}

.list-view {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 1.5rem;
}

.list-item-card {
  overflow: visible;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  display: flex;
  flex-direction: column;
}

.list-item-card:hover {
  box-shadow: var(--rh-shadow, 0 10px 30px rgba(15, 59, 46, 0.12));
}

.list-item-card__link {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
}

.list-item-card__img-wrap {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--rh-sand-200, #eee5dc);
  flex-shrink: 0;
}

.list-item-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.list-item-card__body {
  padding: 1.25rem 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.list-item-card__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
  line-height: 1.35;
  color: var(--rh-charcoal, #1f2321);
}

.list-item-card__date {
  margin-bottom: 0.5rem;
}

.list-item-card__excerpt {
  font-size: 0.95rem;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.9;
  margin: 0 0 0.75rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.list-item-card__more {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--rh-green-700, #1a6a50);
  margin-top: auto;
}

.list-item-card:hover .list-item-card__more {
  text-decoration: underline;
}

.list-item-card__files {
  flex: 0 0 auto;
  padding: 0 1.25rem 1.25rem;
  border-top: 1px solid var(--rh-border, rgba(31, 35, 33, 0.08));
  padding-top: 0.75rem;
  margin-top: -0.25rem;
  min-height: 0;
}

.list-item-card__files-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.8;
  margin-bottom: 0.5rem;
}

.list-item-card__file-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--rh-green-700, #1a6a50);
  text-decoration: none;
  padding: 0.35rem 0;
  margin-right: 1rem;
  margin-bottom: 0.25rem;
}

.list-item-card__file-link:hover {
  text-decoration: underline;
}

.list-item-card__file-icon {
  flex-shrink: 0;
}

.list-item-card__file-link + .list-item-card__file-link {
  margin-left: 0;
}

.list-empty {
  padding: 1rem 0;
}

.list-detail .list-detail__back {
  margin-bottom: 1rem;
}

.list-detail__header {
  margin-bottom: 1.5rem;
}

.list-detail__title {
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
  line-height: 1.3;
  color: var(--rh-charcoal, #1f2321);
}

.list-detail__meta {
  font-size: 0.9rem;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.75;
}

.list-detail__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.list-detail__tag {
  padding: 0.25rem 0.75rem;
  font-size: 0.8rem;
  border-radius: var(--rh-radius-sm, 12px);
  background: var(--rh-sand-200, #eee5dc);
  color: var(--rh-charcoal, #1f2321);
  text-decoration: none;
}

.list-detail__tag:hover {
  background: var(--rh-sand-300, #e2d3c4);
  color: var(--rh-charcoal, #1f2321);
}

.list-detail__picture-wrap {
  margin-bottom: 1.5rem;
  border-radius: var(--rh-radius, 18px);
  overflow: hidden;
  background: var(--rh-sand-200, #eee5dc);
}

.list-detail__picture {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: top;
}

.list-detail-files {
  margin-bottom: 1.5rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--rh-radius, 18px);
  background: var(--rh-sand-100, #f6f2ee);
  border: 1px solid var(--rh-border, rgba(31, 35, 33, 0.08));
}

.list-detail-files__title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 1rem;
  color: var(--rh-charcoal, #1f2321);
}

.list-detail-files__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 0.75rem;
}

.list-detail-files__item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: var(--rh-radius-sm, 12px);
  background: #fff;
  color: var(--rh-charcoal, #1f2321);
  text-decoration: none;
  font-size: 0.95rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.2s, background 0.2s;
}

.list-detail-files__item:hover {
  background: var(--rh-sand-200, #eee5dc);
  box-shadow: var(--rh-shadow-sm, 0 6px 18px rgba(15, 59, 46, 0.08));
}

.list-detail-files__icon {
  flex-shrink: 0;
  color: var(--rh-green-700, #1a6a50);
}

.list-detail-files__icon svg {
  display: block;
}

.list-detail-files__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.list-detail-files__action {
  flex-shrink: 0;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--rh-green-700, #1a6a50);
}

.list-detail__body {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--rh-charcoal, #1f2321);
}

.list-detail__body img {
  max-width: 100%;
  height: auto;
  border-radius: var(--rh-radius-sm, 12px);
}

.list-detail-gallery {
  margin: 2rem 0;
}

.list-detail-gallery__title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--rh-charcoal, #1f2321);
}

.list-detail-gallery__slider {
  position: relative;
  border-radius: var(--rh-radius, 18px);
  overflow: hidden;
  background: var(--rh-sand-200, #eee5dc);
}

.list-detail-gallery__track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.list-detail-gallery__slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  min-height: 280px;
}

.list-detail-gallery__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.list-detail-gallery__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: background 0.2s, box-shadow 0.2s;
}

.list-detail-gallery__nav:hover {
  background: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.list-detail-gallery__nav--prev {
  left: 12px;
}

.list-detail-gallery__nav--next {
  right: 12px;
}

.list-detail-gallery__nav svg {
  width: 20px;
  height: 20px;
  color: var(--rh-charcoal, #1f2321);
}

.list-detail-gallery__dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 1rem;
}

.list-detail-gallery__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--rh-sand-400, #d6c2af);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}

.list-detail-gallery__dot.is-active,
.list-detail-gallery__dot:hover {
  background: var(--rh-green-700, #1a6a50);
}

.list-detail-gallery__dot.is-active {
  transform: scale(1.2);
}

.list-detail-other {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rh-border, rgba(31, 35, 33, 0.12));
}

.list-detail-other__title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--rh-charcoal, #1f2321);
}

.list-other-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 1rem;
}

.list-other-item {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: 1rem;
  border-radius: var(--rh-radius-sm, 12px);
  background: var(--rh-sand-100, #f6f2ee);
  transition: background 0.2s, box-shadow 0.2s;
}

.list-other-item:hover {
  background: var(--rh-sand-200, #eee5dc);
  box-shadow: var(--rh-shadow-sm, 0 6px 18px rgba(15, 59, 46, 0.08));
}

.list-other-item__img-wrap {
  aspect-ratio: 16 / 10;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 0.75rem;
  background: var(--rh-sand-200, #eee5dc);
}

.list-other-item__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.list-other-item__title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
  line-height: 1.35;
}

.list-other-item__date {
  font-size: 0.8rem;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.7;
}

/* --- boostodrom_stroyka_list: галерея и лайтбокс --- */
.stroyka-list-card__photos-badge {
  position: absolute;
  right: 0.75rem;
  bottom: 0.75rem;
  padding: 0.25rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 999px;
  background: rgba(31, 35, 33, 0.72);
  color: #fff;
  line-height: 1.2;
}

.list-item-card__img-wrap {
  position: relative;
}

.stroyka-detail .stroyka-gallery {
  margin-bottom: 1.75rem;
}

.stroyka-gallery__main-wrap {
  border-radius: var(--rh-radius, 18px);
  overflow: hidden;
  background: var(--rh-sand-200, #eee5dc);
}

.stroyka-gallery__main-btn {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  background: transparent;
  cursor: zoom-in;
  line-height: 0;
}

.stroyka-gallery__main-btn:focus-visible {
  outline: 2px solid var(--rh-green-700, #1a6a50);
  outline-offset: 2px;
}

.stroyka-gallery__main-img {
  width: 100%;
  max-height: min(72vh, 640px);
  object-fit: contain;
  display: block;
  background: var(--rh-sand-200, #eee5dc);
}

.stroyka-gallery__thumbs-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.stroyka-gallery__thumbs-track {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  flex: 1;
  min-width: 0;
  padding: 0.15rem 0;
}

.stroyka-gallery__thumb {
  flex: 0 0 auto;
  width: 88px;
  height: 66px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  overflow: hidden;
  background: var(--rh-sand-200, #eee5dc);
  cursor: pointer;
  scroll-snap-align: start;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.stroyka-gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stroyka-gallery__thumb.is-active,
.stroyka-gallery__thumb:hover {
  border-color: var(--rh-green-700, #1a6a50);
}

.stroyka-gallery__thumb:focus-visible {
  outline: 2px solid var(--rh-green-700, #1a6a50);
  outline-offset: 2px;
}

.stroyka-gallery__thumbs-nav {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: var(--rh-sand-100, #f6f2ee);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stroyka-gallery__thumbs-nav svg {
  width: 18px;
  height: 18px;
}

.stroyka-detail__text {
  margin-bottom: 1.5rem;
}

.stroyka-lightbox {
  padding: 0;
  border: none;
  max-width: none;
  max-height: none;
  width: 100%;
  height: 100%;
  background: transparent;
}

.stroyka-lightbox::backdrop {
  background: rgba(15, 20, 18, 0.88);
}

.stroyka-lightbox__inner {
  position: relative;
  width: min(96vw, 1200px);
  height: min(92vh, 900px);
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  top: 50%;
  transform: translateY(-50%);
}

.stroyka-lightbox__viewport {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: zoom-in;
}

.stroyka-lightbox__viewport.is-pannable {
  cursor: grab;
  overflow: auto;
}

.stroyka-lightbox__img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.15s ease-out;
  transform-origin: center center;
}

.stroyka-lightbox__close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 3;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  color: var(--rh-charcoal, #1f2321);
}

.stroyka-lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stroyka-lightbox__nav--prev {
  left: 0.5rem;
}

.stroyka-lightbox__nav--next {
  right: 0.5rem;
}

.stroyka-lightbox__nav svg {
  width: 22px;
  height: 22px;
}

.stroyka-lightbox__counter {
  position: absolute;
  bottom: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  font-size: 0.85rem;
  color: var(--rh-charcoal, #1f2321);
}

body.stroyka-lightbox-open {
  overflow: hidden;
}

@media (prefers-reduced-motion: reduce) {
  .stroyka-gallery__thumbs-track,
  .stroyka-lightbox__img {
    scroll-behavior: auto;
    transition: none;
  }
}

@media (max-width: 575.98px) {
  .stroyka-gallery__thumb {
    width: 72px;
    height: 54px;
  }

  .stroyka-lightbox__nav {
    width: 40px;
    height: 40px;
  }
}

/* --- boostodrom_notify (было: templates/.default/style.css) --- */
.boostodrom-notify {
  display: block;
}

.boostodrom-notify__list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.boostodrom-notify__item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--rh-border, rgba(31, 35, 33, 0.08));
  transition: background 0.2s ease;
}

.boostodrom-notify__item:last-child {
  border-bottom: none;
}

.boostodrom-notify__item--unread {
  background: var(--rh-sand-100, #f6f2ee);
}

.boostodrom-notify__item:hover {
  background: var(--rh-sand-100, #f6f2ee);
}

.boostodrom-notify__content {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  min-width: 0;
  flex: 1;
}

.boostodrom-notify__avatar {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--rh-sand-300, #e2d3c4);
}

.boostodrom-notify__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.boostodrom-notify__body {
  min-width: 0;
  flex: 1;
}

.boostodrom-notify__author {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--rh-charcoal, #1f2321);
  margin: 0 0 0.35rem;
  line-height: 1.3;
}

.boostodrom-notify__text {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.9;
  margin: 0;
}

.boostodrom-notify__text a {
  color: var(--rh-green-700, #1a6a50);
  text-decoration: none;
}

.boostodrom-notify__text a:hover {
  text-decoration: underline;
}

.boostodrom-notify__meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.boostodrom-notify__date {
  font-size: 0.8rem;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.6;
  white-space: nowrap;
}

.boostodrom-notify__delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--rh-border, rgba(31, 35, 33, 0.12));
  border-radius: var(--rh-radius-sm, 12px);
  background: #fff;
  color: var(--rh-charcoal, #1f2321);
  font-size: 0.85rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.boostodrom-notify__delete:hover {
  background: var(--rh-danger, #c62828);
  border-color: var(--rh-danger, #c62828);
  color: #fff;
}

.boostodrom-notify__empty {
  padding: 2rem 1.25rem;
  text-align: center;
  font-size: 0.95rem;
  color: var(--rh-charcoal, #1f2321);
  opacity: 0.75;
}

@media (max-width: 575.98px) {
  .boostodrom-notify__item {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    padding: 0.875rem 1rem;
  }

  .boostodrom-notify__meta {
    justify-content: space-between;
    padding-top: 0.25rem;
    border-top: 1px solid var(--rh-border, rgba(31, 35, 33, 0.08));
  }
}

/* --- boostodrom_favorite detail (было: инлайн) --- */
.favorite-lot-thumb {
  width: 83px;
  height: 62px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
  cursor: pointer;
}

.favorite-lot-no-img {
  font-size: 12px;
}

.favorite-lot-photo-cell {
  position: relative;
  display: inline-block;
  width: 83px;
}

.favorite-lot-photo-cell .favorite-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 28px;
  padding: 0;
  font-size: 18px;
  line-height: 1;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  z-index: 2;
}

.favorite-lot-photo-cell .favorite-slider-prev {
  left: 0;
}

.favorite-lot-photo-cell .favorite-slider-next {
  right: 0;
}

.favorite-lot-photo-cell .favorite-slider-btn:hover {
  background: rgba(0, 0, 0, 0.7);
}

.pdf-spinner.d-none {
  display: none !important;
}

.pdf-spinner:not(.d-none) {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  vertical-align: middle;
  animation: pdf-spinner-rotate 0.75s linear infinite;
}

@keyframes pdf-spinner-rotate {
  to {
    transform: rotate(360deg);
  }
}

/* --- favorite/public: подборка и карточка лота (было: инлайн в index.php / lot.php) --- */
.public-company-card .public-company-logo {
  width: 80px;
  height: 80px;
  object-fit: contain;
  border-radius: var(--rh-radius-sm, 12px);
}

body:has(.public-lot-page) {
  height: auto !important;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: visible;
}

.lk-shell:has(.public-lot-page) {
  min-height: 100%;
  height: auto !important;
}

.lk-content:has(.public-lot-page) {
  flex: 0 1 auto !important;
  height: auto !important;
  min-height: 0;
  overflow: visible !important;
}

.public-lot-page .public-lot-topbar {
  text-align: right;
  padding: 0 1rem;
  position: static;
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--rh-radius);
  padding: 0.75rem 0;
  margin-bottom: 1rem;
}

.public-lot-page .rh-card {
  max-width: 100%;
}

.public-lot-hero {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
  align-items: flex-start;
}

.public-lot-photo-wrap {
  position: relative;
  flex: 65 1 0%;
  min-width: 280px;
  max-height: 520px;
  line-height: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.public-lot-photo-wrap a.public-lot-img-link {
  display: block;
  line-height: 0;
}

.public-lot-photo-wrap img {
  max-width: 100%;
  max-height: 520px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--rh-radius-sm);
  display: block;
  cursor: pointer;
}

.public-lot-hero-right {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 35 1 0%;
  min-width: 240px;
}

.public-lot-photo-wrap .favorite-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 44px;
  padding: 0;
  font-size: 24px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.public-lot-photo-wrap .favorite-slider-btn .favorite-slider-btn-arrow {
  display: block;
  line-height: 1;
  transform: translateY(-0.08em);
}

.public-lot-photo-wrap .favorite-slider-prev {
  left: 8px;
}

.public-lot-photo-wrap .favorite-slider-next {
  right: 8px;
}

.public-lot-photo-wrap .favorite-slider-btn:hover {
  background: rgba(0, 0, 0, 0.7);
}

.public-lot-summary {
  background: var(--rh-green-900);
  color: #fff;
  border-radius: var(--rh-radius-sm);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--rh-shadow-sm);
}

.public-lot-summary .public-lot-summary-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.85;
  margin-bottom: 0.35rem;
}

.public-lot-summary .public-lot-summary-value {
  font-size: 1.25rem;
  font-weight: 700;
}

.public-lot-summary .public-lot-summary-row {
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.public-lot-summary .public-lot-summary-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.public-lot-summary .public-lot-summary-row:first-child {
  padding-top: 0;
}

.public-lot-contact {
  background: var(--rh-sand-200);
  border: 1px solid var(--rh-border);
  border-radius: var(--rh-radius-sm);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--rh-shadow-sm);
}

.public-lot-contact .public-lot-contact-company {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--rh-green-900);
  margin-bottom: 0.75rem;
}

.public-lot-contact .public-lot-contact-manager {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.public-lot-contact .public-lot-contact-manager-photo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--rh-sand-300);
}

.public-lot-contact .public-lot-contact-manager-photo-placeholder {
  flex-shrink: 0;
}

.public-lot-contact .public-lot-contact-manager-fio {
  font-weight: 600;
  color: var(--rh-charcoal);
  margin-bottom: 0.25rem;
}

.public-lot-contact .public-lot-contact-manager-phone {
  font-size: 0.9rem;
}

.public-lot-contact .public-lot-contact-manager-phone a {
  color: var(--rh-green-800);
  text-decoration: none;
}

.public-lot-contact .public-lot-contact-manager-phone a:hover {
  text-decoration: underline;
}

.public-lot-params-wrap {
  max-height: min(50vh, 400px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--rh-border);
  border-radius: var(--rh-radius-sm);
  padding: 0 1rem;
}

.public-lot-params-wrap .table {
  margin-bottom: 0;
}

@media (max-width: 767px) {
  .public-lot-page {
    overflow: visible;
    padding-top: max(0.75rem, env(safe-area-inset-top, 0));
  }

  .public-lot-page .container {
    overflow: visible;
  }

  .public-lot-page .public-lot-topbar {
    position: static;
  }

  .public-lot-page .rh-card {
    overflow: visible;
  }

  .public-lot-photo-wrap {
    max-height: none;
    overflow: visible;
  }

  .public-lot-photo-wrap img {
    max-width: 100%;
    max-height: min(55vh, 400px);
    width: auto;
    height: auto;
    object-fit: contain;
  }

  .public-lot-hero {
    scroll-margin-top: 0;
  }
}

/* Login/registration split layout */
body[data-page="login"] {
  background: #f4f4f4;
  overflow-x: hidden;
}

body[data-page="login"] .auth-entry-shell {
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

body[data-page="login"] .auth-entry-shell__row {
  margin: 0;
  min-height: 100vh;
}

body[data-page="login"] .auth-entry-shell--compact {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: clamp(20px, 4vh, 40px) 12px 16px;
}

body[data-page="login"] .auth-entry-shell__row--compact {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: calc(100dvh - clamp(36px, 6vh, 56px));
  margin: 0;
}

body[data-page="login"] .auth-compact-row {
  min-height: calc(100dvh - clamp(40px, 7vh, 72px));
  align-items: center;
  padding-top: clamp(20px, 4vh, 40px);
}

body[data-page="app"] .login__section--compact-auth {
  min-height: calc(100dvh - 130px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: clamp(20px, 4vh, 40px);
}

body[data-page="app"] .login__section--compact-auth .container {
  width: min(100%, 760px);
}

body[data-page="login"] {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Панель Bitrix из ShowHead() — не показывать на странице входа */
body[data-page="login"] #panel,
body[data-page="login"] .bx-panel,
body[data-page="login"] #bx-panel-top {
  display: none !important;
}

body[data-page="login"] .login-page-shell {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  font-size: 1rem;
  line-height: normal;
}

body[data-page="login"] .login-layout {
  background: #fff;
  width: 100%;
  min-height: 100vh;
  margin: 0;
  --bs-gutter-y: 0;
}

body[data-page="login"] .login-layout__info {
  background: #0f3b2e;
  color: #fff;
}

body[data-page="login"] .login-layout__info-inner {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: clamp(20px, 2.5vw, 28px) clamp(24px, 4vw, 48px) clamp(24px, 4vw, 48px);
}

body[data-page="login"] .login-layout__logo {
  display: block;
  width: auto;
  max-width: min(100%, 240px);
  height: auto;
  margin: 0 0 1.5rem;
}

body[data-page="login"] .login-layout__title {
  margin: 0 0 1.5rem;
  font-size: clamp(1.5rem, 2vw, 2.2rem);
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

body[data-page="login"] .login-layout__text {
  margin: 0 0 1rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.78);
}

body[data-page="login"] .login-layout__benefits {
  list-style: none;
  margin: 0 0 1.35rem;
  padding: 0;
  color: rgba(255, 255, 255, 0.88);
  display: grid;
  gap: 0.55rem;
}

body[data-page="login"] .login-layout__benefits li {
  position: relative;
  margin: 0;
  padding-left: 1.7rem;
  line-height: 1.5;
  font-size: 0.98rem;
}

body[data-page="login"] .login-layout__benefits li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.42rem;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.18);
}

body[data-page="login"] .login-layout__image {
  width: 100%;
  margin-top: auto;
  border-radius: 10px;
  object-fit: cover;
}

body[data-page="login"] .login-layout__form {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-height: 100vh;
  padding: clamp(20px, 2.5vw, 28px) clamp(24px, 4vw, 48px) clamp(16px, 2vw, 24px);
}

body[data-page="login"] .login-layout__form-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  flex-shrink: 0;
  margin: 0 0 clamp(20px, 3vw, 28px);
  padding: 0;
  font-size: clamp(1rem, 1.1vw, 1.1rem);
  line-height: 1.4;
  color: var(--text);
}

body[data-page="login"] .login-layout__form-top a:not(.btn):not(.nav-link):not(.dropdown-item) {
  color: #0f3b2e;
  text-decoration: none;
}

body[data-page="login"] .login-layout__form-top a:not(.btn):not(.nav-link):not(.dropdown-item):hover,
body[data-page="login"] .login-layout__form-top a:not(.btn):not(.nav-link):not(.dropdown-item):focus-visible {
  color: #0f3b2e;
  text-decoration: none;
}

body[data-page="login"] .login-layout__form-top-link::before {
  content: "← ";
}

body[data-page="login"] .login-layout__form-top-phone {
  margin-left: auto;
  white-space: nowrap;
}

body[data-page="login"] .login-layout__form-body {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
}

body[data-page="login"] .login-layout__form .row {
  width: 100%;
}

body[data-page="login"] .login-layout__footer {
  flex-shrink: 0;
  width: 100%;
  margin-top: auto;
  padding-top: 0.75rem;
}

@media (max-width: 991.98px) {
  body[data-page="login"] .login-layout {
    min-height: 100vh;
  }

  body[data-page="login"] .login-layout__info-inner {
    gap: 0.5rem;
  }

  body[data-page="login"] .login-layout__image {
    margin-top: 1rem;
    max-height: 280px;
  }

  body[data-page="login"] .login-layout__benefits li {
    font-size: 0.94rem;
    padding-left: 1.55rem;
  }

  body[data-page="login"] .login-layout__form-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  body[data-page="login"] .login-layout__form-top-phone {
    margin-left: 0;
  }
}

/* --- boostodrom_meetings / appointments --- */
.lk-appointment-list__item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.75rem;
  width: 100%;
  padding: 0.75rem 1rem;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: transparent;
  text-align: left;
  color: var(--text);
  cursor: pointer;
}
.lk-appointment-list__item:hover {
  background: var(--surface-alt);
}
.lk-appointment-list__item--muted {
  opacity: 0.55;
}
.lk-appointment-list__badge {
  font-size: 0.75rem;
  color: var(--lk-danger);
}
.lk-appointment-calendar__weekdays,
.lk-appointment-calendar__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.35rem;
}
.lk-appointment-calendar__weekdays span {
  text-align: center;
  font-size: 0.75rem;
  color: var(--rh-muted, var(--text-muted));
}
.lk-appointment-calendar__cell {
  position: relative;
  min-height: 2.75rem;
  border: 1px solid var(--border);
  border-radius: var(--rh-radius-sm, var(--radius-sm));
  background: var(--surface);
  padding: 0.25rem;
  cursor: pointer;
}
.lk-appointment-calendar__cell--empty {
  border-color: transparent;
  background: transparent;
  cursor: default;
}
.lk-appointment-calendar__cell--has {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 8%, var(--surface));
}
.lk-appointment-calendar__daynum {
  font-size: 0.85rem;
  font-weight: 600;
}
.lk-appointment-calendar__dot {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}
.lk-appointment-slots {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.lk-appointment-slots__btn {
  border: 1px solid var(--border);
  border-radius: var(--rh-radius-sm, var(--radius-sm));
  padding: 0.35rem 0.6rem;
  background: var(--surface);
  font-size: 0.85rem;
}
.lk-appointment-slots__btn.is-active {
  border-color: var(--primary);
  background: var(--primary-soft-2, color-mix(in srgb, var(--primary) 12%, white));
}
.lk-appointment-slots__btn--current.is-active {
  font-weight: 600;
}
.lk-appointment-slots.is-invalid {
  border: 1px solid var(--bs-danger, #dc3545);
  border-radius: var(--rh-radius-sm, var(--radius-sm));
  padding: 0.25rem;
  box-sizing: border-box;
}
/* Поле даты: клик по всей области открывает календарь (WebKit/Blink). */
#appointmentBookModal input[type="date"].form-control {
  position: relative;
}
#appointmentBookModal input[type="date"].form-control::-webkit-calendar-picker-indicator {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  cursor: pointer;
  opacity: 0;
}
.dash-appointment-item {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  color: inherit;
}
.dash-appointment-item:last-child {
  border-bottom: 0;
}
.dash-appointment-item__time {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
}
.dash-appointment-item__label {
  display: block;
}
.lk-appointment-toast-container .toast {
  min-width: 240px;
  max-width: min(100vw - 2rem, 380px);
}
#appointmentBookSubmit.is-busy,
#appointmentDetailActions button.is-busy {
  cursor: wait;
}
#appointmentBookSubmit.is-busy .lk-appointment-btn__spinner,
#appointmentDetailActions button.is-busy .lk-appointment-btn__spinner {
  opacity: 0.9;
}

/* Спиннер на залитой кнопке: не гасить весь блок opacity из .btn:disabled */
#appointmentBookSubmit.btn-rh.is-busy:disabled,
#appointmentDetailActions .btn-rh.is-busy:disabled {
  opacity: 1;
  color: var(--bs-btn-disabled-color);
  background-color: var(--bs-btn-disabled-bg);
  border-color: var(--bs-btn-disabled-border-color);
}

#appointmentBookSubmit.btn-rh.is-busy:disabled .spinner-border,
#appointmentDetailActions .btn-rh.is-busy:disabled .spinner-border {
  color: currentColor;
}

/* --- Mortgage calculator (LK) --- */
.mortgage-lot-card{
  border: 1px solid var(--rh-border, var(--border));
  border-radius: 12px;
  padding: 12px 14px;
  background: var(--surface);
}
.mortgage-lot-card__title{ font-weight: 700; }
.mortgage-lot-card__params{
  color: var(--text-muted);
  font-size: 13px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.mortgage-lot-card__price{ margin-top: 6px; font-size: 18px; font-weight: 800; }

.mortgage-offer-card{
  border: 1px solid var(--rh-border, var(--border));
  border-radius: 12px;
  padding: 12px 14px;
  background: var(--surface);
}
.mortgage-offer-card__top{ display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mortgage-offer-card__bank{ font-weight: 700; }
.mortgage-offer-card__badges{ display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.mortgage-offer-card__badge{
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid color-mix(in srgb, var(--rh-border, var(--border)) 70%, transparent);
}
.mortgage-offer-card__grid{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}
@media (max-width: 575px){
  .mortgage-offer-card__grid{ grid-template-columns: 1fr; }
}

/* Переключатель ₽ / %: активная кнопка контрастная, учитывает individual-theme */
#mortgage-initial-type-amount.active,
#mortgage-initial-type-percent.active{
  background: var(--rh-green-900, var(--primary));
  border-color: var(--rh-green-900, var(--primary));
  color: #fff;
}
#mortgage-initial-type-amount.active:focus,
#mortgage-initial-type-percent.active:focus{
  box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--rh-green-900, var(--primary)) 25%, transparent);
}
