/* ==================== БАЗОВЫЕ СТИЛИ И ПЕРЕМЕННЫЕ ==================== */
:root {
  --teal: #0E6B63;
  --teal-dark: #0A4F49;
  --teal-light: #EAF4F2;
  --accent: #D95D39;
  --coral: #E76F51;
  --ink: #1F2421;
  --muted: #5C6660;
  --bg: #FAF8F5;
  --card: #fff;
  --line: #E4DED6;
  --border: #E5E7EB;
  --text: #1F2937;
  --text-light: #64748B;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

a {
  color: var(--teal);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* ==================== ШАПКА ==================== */
.site-header {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo {
  font-size: 22px;
  font-weight: 800;
  text-decoration: none;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 0px;
}

.logo span {
  color: var(--teal);
}

.main-nav {
  display: flex;
  gap: 18px;
  margin-left: auto;
}

.main-nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 15px;
  font-weight: 500;
}

.main-nav a:hover {
  color: var(--teal);
}

/* ==================== КНОПКИ ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 14px;
  font-size: 17px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}

.btn:active {
  transform: scale(.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 6px 18px rgba(217, 93, 57, .28);
}

.btn-primary:hover {
  box-shadow: 0 8px 22px rgba(217, 93, 57, .38);
}

.btn-outline {
  background: transparent;
  color: var(--teal);
  border: 2px solid var(--teal);
}

.btn-dark {
  background: var(--ink);
  color: #fff;
}

.btn-small {
  min-height: 40px;
  padding: 0 16px;
  font-size: 15px;
  border-radius: 10px;
}

/* ==================== ХЛЕБНЫЕ КРОШКИ ==================== */
.breadcrumbs {
  font-size: 14px;
  color: var(--muted);
  padding: 14px 0;
}

.breadcrumbs a {
  color: var(--muted);
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--teal);
}

.breadcrumbs span {
  margin: 0 6px;
}

/* ==================== HERO СЕКЦИЯ ==================== */
.page-hero {
  padding: 40px 0 32px;
  border-bottom: 1px solid var(--line);
}

.page-hero .container {
  max-width: 1120px;
  margin: 0 auto;
}

.page-hero .overline {
  margin-bottom: 12px;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 700;
}

.page-hero h1 {
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
  color: var(--ink);
  max-width: 100%;
}

.page-hero .lead-text {
  font-size: 18px;
  color: var(--muted);
  line-height: 1.6;
  max-width: 100%;
}

/* ==================== КОНТЕНТ СТАТЬИ ==================== */
.article {
  max-width: 1120px;
  margin: 32px auto 8px;
  padding: 0 20px;
}

.article h2 {
  font-size: clamp(22px, 3vw, 28px);
  margin: 36px 0 12px;
}

.article h3 {
  font-size: 19px;
  margin: 24px 0 8px;
}

.article p {
  margin: 0 0 14px;
  font-size: 16px;
  line-height: 1.7;
}

.article ul,
.article ol {
  margin: 0 0 16px 20px;
  font-size: 16px;
  line-height: 1.7;
}

.article li {
  margin-bottom: 6px;
}

.article table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 15px;
}

.article th,
.article td {
  border: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.article th {
  background: #F1EDE6;
}

.table-responsive {
  overflow-x: auto;
}

/* ==================== СПИСКИ ==================== */
.steps {
  list-style: none;
  counter-reset: step;
  margin: 22px 0;
  padding: 0;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 20px 54px;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.steps li::after {
  content: "";
  position: absolute;
  left: 17px;
  top: 42px;
  bottom: 6px;
  border-left: 2px dashed var(--line);
}

.steps li:last-child::after {
  display: none;
}

.steps b {
  display: block;
  margin-bottom: 2px;
}

.checklist {
  list-style: none;
  margin: 16px 0;
  padding: 0;
}

.checklist li {
  position: relative;
  padding: 0 0 12px 34px;
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 20px;
  height: 20px;
  border: 2px solid var(--teal);
  border-radius: 6px;
}

.checklist li::after {
  content: "✓";
  position: absolute;
  left: 4px;
  top: 2px;
  color: var(--teal);
  font-weight: 700;
  font-size: 14px;
}

/* ==================== CALLOUT (БЛОКИ С ПРЕДУПРЕЖДЕНИЯМИ) ==================== */
.callout {
  border-radius: 14px;
  padding: 16px 18px;
  margin: 22px 0;
  font-size: 15px;
}

.callout b {
  display: block;
  margin-bottom: 4px;
}

.callout-warn {
  background: #FDF0EC;
  border-left: 4px solid var(--accent);
}

.callout-tip {
  background: #EAF4F2;
  border-left: 4px solid var(--teal);
}

/* ==================== DOC-CARD (КАРТОЧКА ДОКУМЕНТА) ==================== */
.doc-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px 20px;
  margin: 22px 0;
}

.doc-card b {
  display: block;
  font-size: 16px;
}

.doc-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

/* ==================== PARTNER (ПАРТНЁРСКИЙ БЛОК) ==================== */
.partner {
  background: #F6F1E7;
  border: 1px dashed var(--line);
  border-radius: 16px;
  padding: 18px 20px;
  margin: 26px 0;
  font-size: 14px;
  color: var(--muted);
}

.partner b {
  color: var(--ink);
  font-size: 16px;
  display: block;
  margin-bottom: 6px;
}

.partner .btn {
  margin-top: 12px;
}

/* ==================== RELATED (ЧИТАЙТЕ ДАЛЕЕ) ==================== */
.related {
  margin: 36px 0;
  padding: 20px 22px;
  background: #F4F0E9;
  border-radius: 16px;
}

.related h3 {
  font-size: 18px;
  margin-bottom: 10px;
}

.related ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.related a {
  font-weight: 600;
  text-decoration: none;
}

.related a:hover {
  text-decoration: underline;
}

/* ==================== LEAD-BOX (БЛОК ЛИД-МАГНИТА) ==================== */
.lead-box {
  padding: 48px 0 64px;
}

.lead-box .container {
  max-width: 820px;
}

.lead-box-inner {
  background: var(--teal);
  color: #fff;
  border-radius: 20px;
  padding: 36px;
}

.lead-box h2 {
  font-size: clamp(22px, 3vw, 30px);
  margin-bottom: 10px;
}

.lead-box > p {
  color: #DDEEEB;
  max-width: 560px;
  margin-bottom: 22px;
}

.lead-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  margin-bottom: 12px;
}

.lead-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.lead-form input {
  min-height: 52px;
  border: none;
  border-radius: 14px;
  padding: 0 16px;
  font-size: 16px;
  min-width: 250px;
}

.lead-success {
  font-weight: 600;
}

.lead-box .microcopy {
  color: #BFDCD8;
  margin-bottom: 0;
}

.lead-box .microcopy a {
  color: #BFDCD8;
}

.lead-box.compact {
  padding: 26px 24px;
  margin: 22px 0;
}

/* ==================== ПОДВАЛ ==================== */
.site-footer {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
}

/* ==================== ДОВЕРИЕ (TRUST BAR) ==================== */
.trust-bar {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.trust-bar li {
  font-size: 14px;
  color: var(--muted);
  padding-left: 20px;
  position: relative;
}

.trust-bar li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* ==================== ГЕРОЙ ГЛАВНОЙ ==================== */
.hero {
  padding: 48px 0 28px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 48px;
  align-items: start;
}

.overline {
  font-size: 14px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 700;
  margin-bottom: 12px;
}

h1 {
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1.15;
  letter-spacing: -.01em;
  max-width: 640px;
  margin-bottom: 16px;
}

.subtitle {
  font-size: 18px;
  color: var(--muted);
  max-width: 560px;
  margin-bottom: 24px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 10px;
}

.microcopy {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 20px;
}

.microcopy a {
  color: var(--muted);
}

/* МАРШРУТ (справа на главной) */
.hero-route {
  padding: 20px;
}

.route-title {
  font-weight: 700;
  margin-bottom: 12px;
}

.route {
  list-style: none;
  border-left: 2px dashed var(--line);
  padding-left: 24px;
}

.route li {
  position: relative;
  padding: 6px 0;
}

.route .num {
  position: absolute;
  left: -42px;
  top: 12px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
}

.route a {
  display: block;
  text-decoration: none;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 12px;
}

.route a:hover {
  background: #F1EDE6;
}

.route b {
  display: block;
  font-size: 16px;
}

.route small {
  color: var(--muted);
  font-size: 14px;
}

/* САМОСЕГМЕНТАЦИЯ */
.segments {
  padding: 40px 0;
  background: #F4F0E9;
}

.segments h2 {
  font-size: clamp(24px, 3.4vw, 32px);
  margin-bottom: 8px;
}

.segments-sub {
  color: var(--muted);
  margin-bottom: 24px;
}

.cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px;
}

.card h3 {
  font-size: 18px;
  margin-bottom: 8px;
}

.card p {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 14px;
}

.card a {
  font-weight: 600;
  text-decoration: none;
}

.card a:hover {
  text-decoration: underline;
}

.card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* ==================== КАТАЛОГ КЛИНИК (/centers/) ==================== */
.clinics-filters {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  margin: 24px 0;
}

.filters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.filter-select,
.search-input {
  width: 100%;
  min-height: 44px;
  padding: 11px 34px 11px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-size: 15px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%235C6660' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
  appearance: none;
  cursor: pointer;
  color: var(--ink);
}

.filter-select:focus,
.search-input:focus {
  outline: none;
  border-color: var(--teal);
}

.search-box {
  position: relative;
}

.search-input {
  padding-left: 40px;
}

.search-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 16px;
}

.toggles-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.toggle-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  user-select: none;
  transition: all .2s;
  color: var(--ink);
}

.toggle-chip input {
  display: none;
}

.toggle-chip.active {
  background: var(--teal-light);
  border-color: var(--teal);
  color: var(--teal-dark);
  font-weight: 600;
}

.sort-select {
  margin-left: auto;
  padding: 8px 30px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%235C6660' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  cursor: pointer;
  color: var(--ink);
}

.counter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0 8px;
}

.counter-text {
  color: var(--muted);
  font-size: 15px;
}

.counter-text strong {
  color: var(--teal);
}

.reset-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-size: 14px;
  cursor: pointer;
  font-weight: 500;
  display: none;
}

.reset-btn.visible {
  display: inline;
}

.clinics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.clinic-card {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  transition: all .25s;
  animation: cardIn .35s ease;
}

@keyframes cardIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.clinic-card:hover {
  border-color: var(--teal);
  box-shadow: 0 10px 28px rgba(14, 124, 107, .13);
  transform: translateY(-3px);
}

.card-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.clinic-name {
  color: var(--teal-dark);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  flex: 1;
}

.fav-btn {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: #cbd5e1;
  line-height: 1;
  padding: 2px;
  transition: color .2s;
}

.fav-btn.active {
  color: var(--coral);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.badge {
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
}

.badge-oms {
  background: #EAF4F2;
  color: var(--teal);
}

.badge-paid {
  background: #FFF4E6;
  color: var(--accent);
}

.badge-bed {
  background: #FDF0EC;
  color: var(--accent);
}

.badge-speech {
  background: #EAF4F2;
  color: var(--teal);
}

.badge-region {
  background: var(--bg);
  color: var(--muted);
}

.badge-off {
  background: #EAF4F2;
  color: var(--teal-dark);
  border: 1px solid var(--teal);
}

.clinic-meta {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 6px;
}

.clinic-meta strong {
  color: var(--ink);
}

.clinic-meta a {
  color: var(--teal);
  text-decoration: none;
}

.clinic-meta a:hover {
  text-decoration: underline;
}

.price-tag {
  margin: 8px 0 4px;
  font-size: 16px;
  font-weight: 700;
}

.price-free {
  color: var(--teal);
}

.price-paid {
  color: var(--accent);
}

.card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: auto;
  padding-top: 16px;
}

.card-actions .btn {
  font-size: 14px;
  min-height: 40px;
  padding: 0 12px;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 56px 24px;
  background: var(--card);
  border-radius: 16px;
  border: 1.5px dashed var(--line);
  color: var(--muted);
}

.load-more-wrap {
  text-align: center;
  padding: 8px 0 40px;
  display: none;
}

.btn-load-more {
  background: var(--teal);
  color: #fff;
  border: none;
  padding: 14px 36px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
}

.btn-load-more:hover {
  background: var(--teal-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(14, 124, 107, .25);
}

.showing-text {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

/* НОРМАТИВНАЯ БАЗА */
.norm-base {
  background: #F8FAFC;
  border: none;
  border-left: 4px solid #0E7C6B;
  border-radius: 10px;
  padding: 26px 30px;
  margin: 32px 0;
}

.norm-base h2 {
  font-size: 1.3rem;
  margin: 0 0 10px;
  color: #1F2937;
}

.norm-base p {
  color: #64748B;
  font-size: 0.95rem;
  margin: 0 0 14px;
}

.norm-base ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.norm-base li {
  padding: 12px 0;
  border-bottom: 1px solid #E5E7EB;
  font-size: 0.95rem;
  color: #1F2937;
}

.norm-base li:last-child {
  border-bottom: none;
  padding-bottom: 4px;
}

.norm-base a {
  color: #0E7C6B;
  font-weight: 600;
  text-decoration: none;
}

.norm-base a:hover {
  text-decoration: underline;
}

.norm-base p:last-of-type {
  margin: 12px 0 0;
  font-style: italic;
  color: #64748B;
  font-size: 0.9rem;
}

/* ЭКСПЕРТНАЯ ПРОВЕРКА */
.expert-review {
  background: #f8fafc;
  border-left: 4px solid #0E7C6B;
  padding: 16px 20px;
  margin: 32px 0;
  border-radius: 8px;
}

/* COOKIE BANNER */
#cookie-banner {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #0F172A;
  color: #CBD5E1;
  padding: 16px 24px;
  z-index: 1000;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* ==================== АДАПТИВНОСТЬ ==================== */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-route {
    display: none;
  }
  
  .main-nav {
    display: none;
  }
  
  .header-row .btn-small {
    margin-left: auto;
  }
}

@media (max-width: 768px) {
  .cards {
    grid-template-columns: 1fr;
  }
  
  .cta-row {
    flex-direction: column;
  }
  
  .cta-row .btn {
    width: 100%;
  }
  
  .lead-form {
    flex-direction: column;
    width: 100%;
  }
  
  .lead-form input {
    min-width: 0;
    width: 100%;
  }
  
  .lead-actions .btn {
    width: 100%;
  }
  
  .filters-grid {
    grid-template-columns: 1fr;
  }
  
  .search-box {
    grid-column: 1 / -1;
  }
  
  .clinics-grid {
    grid-template-columns: 1fr;
  }
  
  .sort-select {
    margin-left: 0;
    width: 100%;
    margin-top: 8px;
  }
  
  .card-actions {
    grid-template-columns: 1fr;
  }
  
  .toggles-row {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 640px) {
  .doc-card {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .doc-card .btn {
    width: 100%;
  }
}

/* ==================== ЧИТАЕМОСТЬ БЛОКА CTA НА ПОДСТРАНИЦАХ ==================== */
.lead-box.compact {
  background: #F4F0E9; /* тёплый бежевый фон — как у блока сегментации */
  border-radius: 16px;
  padding: 6px 32px 28px 32px;
  margin: 32px 0;
}

.lead-box.compact h2 {
  color: var(--ink); /* тёмный заголовок */
  margin-bottom: 16px;
}

.lead-box.compact p {
  color: var(--text); /* читаемый текст вместо muted */
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 20px;
}

.lead-box.compact .microcopy {
  color: var(--text-light); /* чуть светлее основного, но всё ещё читаемо */
  font-size: 14px;
  margin-top: 16px;
  margin-bottom: 0;
}

.lead-box.compact .lead-actions {
  margin: 24px 0 16px 0;
}

/* Адаптивность для мобильных */
@media (max-width: 640px) {
  .lead-box.compact {
    padding: 28px 20px;
    margin: 24px 0;
  }
}

/* ==================== ИКОНКИ-КНОПКИ МЕССЕНДЖЕРОВ В ШАПКЕ ==================== */
.header-messengers {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-left: 12px;
}

.header-messenger-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  text-decoration: none;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.header-messenger-btn img {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Telegram — голубая */
.header-messenger-btn.tg {
  background: rgba(42, 171, 238, 0.12);
  border: 2px solid #2AABEE;
}

.header-messenger-btn.tg:hover {
  background: rgba(42, 171, 238, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(42, 171, 238, 0.25);
}

/* MAX — фиолетовая */
.header-messenger-btn.max {
  background: rgba(124, 58, 237, 0.12);
  border: 2px solid #7C3AED;
}

.header-messenger-btn.max:hover {
  background: rgba(124, 58, 237, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.25);
}

/* ЖЁСТКОЕ ОГРАНИЧЕНИЕ ЛОГОТИПОВ МЕССЕНДЖЕРОВ */
img[src*="logo-telegram"],
img[src*="logo-max"] {
  width: 20px !important;
  height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  display: inline-block !important;
}

.header-messenger-btn {
  width: 36px !important;
  height: 36px !important;
  padding: 6px !important;
}

.header-messenger-btn img {
  width: 20px !important;
  height: 20px !important;
}

/* Мобильная версия */
@media (max-width: 900px) {
  .header-row {
    flex-wrap: wrap;
    gap: 12px;
  }
  
  .header-messengers {
    margin-left: 0;
    order: 3;
    width: 100%;
    justify-content: flex-end;
    padding-top: 8px;
    border-top: 1px solid var(--line);
  }
}

/* ==================== КАЛЬКУЛЯТОР ТСР ==================== */
.calculator {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px 24px;
  margin: 24px 0;
}

.calculator .form-group {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.calculator .form-group:last-of-type {
  border-bottom: none;
  margin-bottom: 16px;
}

.calculator label[for="region"],
.calculator .form-group > label {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 12px;
}

.calculator select {
  width: 100%;
  min-height: 44px;
  padding: 10px 36px 10px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-size: 15px;
  font-family: inherit;
  color: var(--ink);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%235C6660' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
  appearance: none;
  cursor: pointer;
  transition: border-color 0.2s;
}

.calculator select:focus {
  outline: none;
  border-color: var(--teal);
}

/* Чекбоксы и радиокнопки */
.calculator .checkbox-group,
.calculator .radio-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.calculator input[type="checkbox"],
.calculator input[type="radio"] {
  accent-color: var(--teal);
  width: 18px;
  height: 18px;
  margin-right: 10px;
  cursor: pointer;
  vertical-align: middle;
}

.calculator .checkbox-group label,
.calculator .radio-group label {
  display: flex;
  align-items: flex-start;
  font-size: 15px;
  color: var(--ink);
  cursor: pointer;
  line-height: 1.5;
  padding: 10px 14px;
  background: var(--bg);
  border-radius: 10px;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.calculator .checkbox-group label:hover,
.calculator .radio-group label:hover {
  border-color: var(--teal);
  background: var(--teal-light);
}

.calculator .checkbox-group input[type="checkbox"]:checked + span,
.calculator .radio-group input[type="radio"]:checked + span {
  color: var(--teal);
  font-weight: 600;
}

/* Блок результата */
#calculatorResult {
  background: var(--teal-light);
  border-left: 4px solid var(--teal);
  border-radius: 10px;
  padding: 20px 24px;
  margin-top: 24px;
  font-size: 15px;
  color: var(--ink);
}

#calculatorResult p {
  margin: 0;
  line-height: 1.6;
}

/* Адаптивность */
@media (max-width: 640px) {
  .calculator {
    padding: 20px 16px;
  }
  
  .calculator .checkbox-group label,
  .calculator .radio-group label {
    font-size: 14px;
    padding: 8px 12px;
  }
}