/* ivanov.doctor — v1.0 */
:root {
  --ink: #14181c;
  --muted: #5c666e;
  --deep: #0f3238;
  --teal: #2a6f77;
  --gold: #c9a34e;
  --gold-soft: #e3c99b;
  --bg: #ffffff;
  --bg-warm: #f7f5f0;
  --maxw: 1140px;
  --serif: 'Prata', 'Georgia', serif;
  --sans: 'Montserrat', 'Segoe UI', sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-weight: 300;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
}
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
h1, h2, h3, .serif { font-family: var(--serif); font-weight: 400; }
a { color: var(--teal); text-decoration: none; }
a:hover { color: var(--deep); }
img { max-width: 100%; height: auto; display: block; }

/* NAV */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #eee;
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px; max-width: var(--maxw); margin: 0 auto;
}
.logo { font-family: var(--serif); font-size: 20px; line-height: 1.15; color: var(--ink); }
.logo span { display: block; }
.logo .last { color: var(--teal); }
.nav-links { display: flex; gap: 26px; list-style: none; flex-wrap: wrap; }
.nav-links a {
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink); font-weight: 400; padding-bottom: 3px;
  border-bottom: 1px solid transparent;
}
.nav-links a:hover { border-bottom-color: var(--gold); color: var(--deep); }
.burger { display: none; background: none; border: none; font-size: 26px; cursor: pointer; color: var(--deep); }

/* HERO */
.hero { background: linear-gradient(180deg, #fdfcfa 0%, #f4f1ea 100%); overflow: hidden; }
.hero-inner {
  display: grid; grid-template-columns: 1.25fr 1fr; gap: 40px;
  align-items: center; min-height: 520px; padding: 48px 0 0;
}
.hero h1.brandline { white-space: nowrap; font-size: clamp(40px, 7vw, 76px); }
.fullname { font-size: clamp(19px, 2.2vw, 24px); color: var(--deep); margin-top: 14px; letter-spacing: .02em; }
.hero h1 { font-size: clamp(38px, 5.5vw, 62px); line-height: 1.08; color: var(--deep); }
.hero .titles {
  margin: 18px 0 6px; font-size: 15px; letter-spacing: .06em;
  color: var(--gold); font-weight: 500; text-transform: uppercase;
}
.hero .lead { margin: 14px 0 30px; max-width: 46ch; color: var(--muted); font-size: 17px; }
.hero-photo-wrap { align-self: end; position: relative; }
.hero-photo {
  width: min(400px, 100%); margin: 0 auto;
  -webkit-mask-image: linear-gradient(180deg, #000 82%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 82%, transparent 100%);
  filter: saturate(.92) contrast(1.02);
}
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 14px 30px; font-family: var(--sans);
  font-size: 13px; letter-spacing: .1em; text-transform: uppercase; font-weight: 500;
  border: 1px solid var(--deep); color: var(--deep); background: transparent;
  cursor: pointer; transition: all .2s ease;
}
.btn:hover { background: var(--deep); color: #fff; }
.btn.primary { background: var(--deep); color: #fff; }
.btn.primary:hover { background: var(--teal); border-color: var(--teal); }

/* STATS */
.stats { background: var(--deep); color: #fff; }
.stats-inner {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  padding: 38px 24px; max-width: var(--maxw); margin: 0 auto; text-align: center;
}
.stat .num { font-family: var(--serif); font-size: 40px; color: var(--gold-soft); line-height: 1.1; }
.stat .label { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; opacity: .85; margin-top: 6px; }

/* SECTIONS */
section.block { padding: 84px 0; }
section.block.warm { background: var(--bg-warm); }
.eyebrow {
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); font-weight: 500; margin-bottom: 12px;
}
.block h2 { font-size: clamp(28px, 3.6vw, 40px); color: var(--deep); margin-bottom: 18px; line-height: 1.2; }
.block .intro { max-width: 62ch; color: var(--muted); margin-bottom: 42px; }

/* BOOKS */
.books { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.book { display: flex; flex-direction: column; }
.cover {
  aspect-ratio: 5 / 7.2; padding: 22px 18px; display: flex; flex-direction: column;
  justify-content: space-between; color: #fff; box-shadow: 0 14px 30px rgba(15,50,56,.22);
  transition: transform .25s ease, box-shadow .25s ease;
}
.book:hover .cover { transform: translateY(-6px); box-shadow: 0 22px 40px rgba(15,50,56,.3); }
.cover .ctitle { font-family: var(--serif); font-size: 19px; line-height: 1.3; }
.cover .csub { font-size: 11px; letter-spacing: .06em; opacity: .8; margin-top: 8px; }
.cover .cauthor { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; opacity: .9; }
.cover-1 { background: linear-gradient(160deg, #3d2340 0%, #1a1026 100%); }
.cover-2 { background: linear-gradient(160deg, #0f3238 0%, #071c20 100%); }
.cover-3 { background: linear-gradient(160deg, #59452a 0%, #2b2013 100%); }
.cover-4 { background: linear-gradient(160deg, #2c4a63 0%, #12222f 100%); }
.book .meta { margin-top: 16px; font-size: 13px; color: var(--muted); }
.book .meta b { color: var(--ink); font-weight: 500; }
.book .meta a { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }

/* SPLIT (Академия / Ассоциация) */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.card {
  background: #fff; border: 1px solid #e9e5dc; padding: 44px 40px;
  display: flex; flex-direction: column; gap: 14px;
}
.card h3 { font-size: 24px; color: var(--deep); line-height: 1.25; }
.card p { color: var(--muted); font-size: 15px; }
.card .btn { align-self: flex-start; margin-top: auto; }
.card .btn + .btn { margin-top: 10px; }
/* Эмблема организации в карточке */
.card-logo { display: block; margin: 0 0 18px; align-self: flex-start; }
.card-logo img { display: block; width: 210px; height: auto; }
.card-logo img.logo-anr { width: 250px; }
/* Эмблема организации над заголовком раздела */
.section-logo { display: block; margin: 6px 0 14px; }
.section-logo img { display: block; width: 232px; height: auto; }
#association .section-logo img { width: 300px; }
@media (max-width: 700px) { .card-logo img { width: 175px; } .card-logo img.logo-anr { width: 205px; } .section-logo img { width: 190px; } #association .section-logo img { width: 240px; } }
.card ul { margin: 0 0 6px 18px; color: var(--muted); font-size: 15px; }

/* PATIENTS */
.patients-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; margin-bottom: 20px; }
.pcard { background: var(--bg-warm); padding: 34px 30px; border-top: 3px solid var(--gold); }
.pcard h3 { font-size: 19px; color: var(--deep); margin-bottom: 10px; }
.pcard p { font-size: 14.5px; color: var(--muted); margin-bottom: 14px; }
.pcard a.plink { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; font-weight: 500; }

/* FORM */
.form-wrap { max-width: 680px; }
.field { margin-bottom: 22px; }
.field label { display: block; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 8px; color: var(--deep); font-weight: 500; }
.field input, .field textarea {
  width: 100%; padding: 13px 14px; border: 1px solid #d8d3c8; background: #fff;
  font-family: var(--sans); font-size: 15px; color: var(--ink); outline: none;
  transition: border-color .2s;
}
.field input:focus, .field textarea:focus { border-color: var(--teal); }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--muted); margin-bottom: 26px; }
.consent input { margin-top: 3px; }
.form-note { font-size: 13px; color: var(--muted); margin-top: 14px; }
#form-status { margin-top: 16px; font-size: 15px; display: none; }
#form-status.ok { display: block; color: #1e6e42; }
#form-status.err { display: block; color: #a33; }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* FOOTER */
footer { background: var(--deep); color: #cfd8d8; padding: 56px 0 30px; font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; margin-bottom: 34px; }
footer .logo { color: #fff; font-size: 22px; }
footer .logo .last { color: var(--gold-soft); }
footer h4 { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-soft); margin-bottom: 12px; font-weight: 500; }
footer ul { list-style: none; }
footer li { margin-bottom: 8px; }
footer a { color: #cfd8d8; }
footer a:hover { color: #fff; }
.copy { border-top: 1px solid rgba(255,255,255,.15); padding-top: 22px; font-size: 12.5px; opacity: .7; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* BIOGRAPHY PAGE */
.bio-hero { background: var(--bg-warm); padding: 70px 0 50px; }
.bio-hero h1 { font-size: clamp(32px, 4.5vw, 50px); color: var(--deep); line-height: 1.15; }
.bio-hero .titles { color: var(--gold); text-transform: uppercase; letter-spacing: .08em; font-size: 14px; margin-top: 14px; font-weight: 500; }
.bio-body { padding: 60px 0 90px; }
.bio-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 60px; align-items: start; }
.bio-article h2 { font-size: 27px; color: var(--deep); margin: 44px 0 16px; line-height: 1.3; }
.bio-article h2:first-child { margin-top: 0; }
.bio-article p { margin-bottom: 16px; color: #333a40; }
.bio-article p b { font-weight: 500; }
.bio-aside { position: sticky; top: 90px; }
.bio-aside img { border: 1px solid #e5e0d5; }
.bio-aside .fact { padding: 18px 0; border-bottom: 1px solid #e8e4da; font-size: 14px; }
.bio-aside .fact b { display: block; font-weight: 500; color: var(--deep); }
.bio-aside .fact span { color: var(--muted); }

@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; padding-top: 40px; min-height: auto; }
  .hero-photo-wrap { order: -1; }
  .hero-photo { width: min(300px, 80%); }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .books { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .patients-grid { grid-template-columns: repeat(2, 1fr); }
  .bio-grid { grid-template-columns: 1fr; }
  .bio-aside { position: static; max-width: 340px; }
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; flex-direction: column; gap: 0; padding: 10px 24px 18px;
    border-bottom: 1px solid #eee;
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 9px 0; }
  .burger { display: block; }
}
@media (max-width: 560px) {
  .books { grid-template-columns: 1fr; }
  .patients-grid { grid-template-columns: 1fr; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .stat .num { font-size: 30px; }
  section.block { padding: 60px 0; }
}

/* DIPLOMAS */
.diploma-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin: 26px 0 10px; }
.diploma { margin: 0; }
.diploma a { display: block; border: 1px solid #e6e2d8; padding: 10px; background: var(--bg-warm); transition: box-shadow .2s; }
.diploma a:hover { box-shadow: 0 6px 24px rgba(15,50,56,.14); }
.diploma img { display: block; width: 100%; height: 150px; object-fit: cover; object-position: top; }
.diploma .dcap { font-size: 12.5px; color: var(--muted); margin-top: 10px; line-height: 1.55; }
.diploma .dcap b { color: var(--deep); font-size: 13.5px; }
.dnote { font-size: 13px; color: var(--teal); margin-bottom: 26px; }

/* ACCREDITATION TABLE */
table.accred { width: 100%; border-collapse: collapse; margin: 18px 0 30px; font-size: 15px; }
table.accred th { text-align: left; padding: 10px 12px; background: var(--deep); color: #fff; font-weight: 600; font-size: 13.5px; }
table.accred td { padding: 10px 12px; border-bottom: 1px solid #e9e5db; color: var(--muted); }
table.accred tr td:first-child { color: var(--ink); font-weight: 500; }
@media (max-width: 700px) {
  .diploma-grid { grid-template-columns: 1fr; }
  .diploma img { height: auto; }
  table.accred { font-size: 13.5px; }
  table.accred th, table.accred td { padding: 8px 8px; }
}

/* PUBLICATIONS */
.pub-list { list-style: none; margin: 30px 0 0; padding: 0; }
.pub { display: grid; grid-template-columns: 74px 1fr; gap: 20px; padding: 22px 0; border-bottom: 1px solid #e9e5db; }
.pub:first-child { border-top: 1px solid #e9e5db; }
.pub-year { font-family: 'Prata', Georgia, serif; font-size: 21px; color: var(--gold); line-height: 1.2; }
.pub-title { font-size: 16.5px; color: var(--ink); line-height: 1.5; margin: 0 0 5px; font-weight: 500; }
.pub-badge { display: inline-block; background: var(--deep); color: var(--gold-soft); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; padding: 3px 8px; margin-left: 8px; vertical-align: middle; white-space: nowrap; }
.pub-en { font-size: 13.5px; color: #8b949b; font-style: italic; line-height: 1.5; margin: 0 0 6px; }
.pub-ref { font-size: 14px; color: var(--muted); margin: 0 0 4px; }
.pub-doi { font-size: 12.5px; color: var(--teal); text-decoration: none; border-bottom: 1px dotted var(--teal); }
.pub-doi:hover { color: var(--deep); }
.pub-profiles { margin-top: 34px; padding-top: 22px; border-top: 2px solid var(--gold); font-size: 15px; color: var(--muted); }
.pub-profiles a { color: var(--teal); }
@media (max-width: 620px) {
  .pub { grid-template-columns: 1fr; gap: 6px; padding: 18px 0; }
  .pub-year { font-size: 17px; }
  .pub-title { font-size: 15.5px; }
  .pub-badge { margin-left: 0; margin-top: 4px; }
}

/* PAGE HEAD (для внутренних страниц) */
.page-head { background: var(--bg-warm); padding: 120px 0 42px; border-bottom: 1px solid #e9e5db; }
.page-head h1 { font-family: 'Prata', Georgia, serif; font-size: clamp(34px, 5vw, 52px); color: var(--deep); margin: 6px 0 10px; font-weight: 400; }
.page-sub { color: var(--muted); font-size: 16px; }

/* SCIENCE STATS */
.sci-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-top: 34px; }
.ss { text-align: center; padding: 20px 10px; background: var(--bg-warm); border-top: 2px solid var(--gold); }
.ss b { display: block; font-family: 'Prata', Georgia, serif; font-size: 30px; color: var(--deep); line-height: 1.1; }
.ss span { display: block; font-size: 12px; color: var(--muted); margin-top: 6px; letter-spacing: .03em; }

/* RINC PUBLICATION LIST */
.rp-wrap { margin-top: 44px; }
.rp-year { margin-bottom: 40px; }
.rp-y { font-family: 'Prata', Georgia, serif; font-size: 27px; color: var(--deep); margin: 0 0 4px; padding-bottom: 10px; border-bottom: 2px solid var(--gold); display: flex; align-items: baseline; gap: 12px; font-weight: 400; }
.rp-y span { font-family: 'Montserrat', sans-serif; font-size: 12px; color: var(--muted); letter-spacing: .05em; }
.rp-list { margin: 0; padding: 0 0 0 26px; }
.rp { padding: 16px 0 15px; border-bottom: 1px solid #eeeae0; }
.rp::marker { color: var(--gold); font-size: 13px; }
.rp-title { font-size: 15.5px; color: var(--ink); line-height: 1.5; margin: 0 0 5px; font-weight: 500; }
.rp-kind { display: inline-block; font-size: 10px; letter-spacing: .06em; text-transform: uppercase; padding: 2px 7px; margin-left: 7px; vertical-align: 2px; white-space: nowrap; border: 1px solid; }
.k-art  { color: var(--teal); border-color: #cfe0e2; background: #f2f8f8; }
.k-book { color: #8a6a1e; border-color: #e6d9b4; background: #fbf6e8; }
.k-proc { color: #7b7b7b; border-color: #e2e2e2; background: #f7f7f7; }
.k-diss { color: #7a3d8f; border-color: #e0cde6; background: #f9f3fb; }
.rp-cit { display: inline-block; font-size: 11px; color: #b5892a; margin-left: 8px; letter-spacing: .04em; white-space: nowrap; }
.rp-auth { font-size: 13.5px; color: #6f7c82; margin: 0 0 3px; }
.rp-auth b { color: var(--deep); font-weight: 600; }
.rp-src { font-size: 13px; color: var(--muted); margin: 0; font-style: italic; }
.rp-link { font-style: normal; font-size: 11.5px; color: var(--teal); margin-left: 8px; white-space: nowrap; }
@media (max-width: 760px) {
  .sci-stats { grid-template-columns: repeat(2, 1fr); }
  .sci-stats .ss:last-child { grid-column: 1 / -1; }
  .page-head { padding: 100px 0 32px; }
  .rp-list { padding-left: 20px; }
  .rp-title { font-size: 15px; }
  .rp-kind { margin-left: 0; display: inline-block; margin-top: 4px; }
}

/* chapters inside book */
.rp-bookgrp .rp-det { margin-top: 10px; }
.rp-det summary { cursor: pointer; font-size: 12.5px; color: var(--teal); letter-spacing: .03em; padding: 4px 0; outline: none; }
.rp-det summary:hover { color: var(--deep); }
.rp-det[open] summary { color: var(--muted); margin-bottom: 6px; }
.rp-chlist { margin: 4px 0 6px; padding-left: 22px; }
.rp-c { padding: 5px 0; border-bottom: 1px dotted #edeae2; font-size: 14px; color: #5d6b71; }
.rp-c::marker { color: #cfc9b8; font-size: 11px; }
.rp-ct { color: var(--ink); }
.rp-pg { font-size: 12px; color: var(--muted); margin-left: 8px; font-style: italic; }
.k-mono { color: #6a4a8a; border-color: #d8c9e6; background: #f7f3fb; }
.k-ch { color: #7b7b7b; border-color: #e2e2e2; background: #f7f7f7; }

/* редакционная деятельность */
.pub-edboard { margin: 14px auto 0; max-width: 860px; text-align: center; font-size: 14px;
  line-height: 1.7; color: var(--muted); padding: 14px 18px; background: var(--bg-warm);
  border: 1px solid #e9e5db; border-radius: 4px; }
.pub-edboard b { color: var(--ink); font-weight: 600; }
.pub-edboard a { color: var(--teal); border-bottom: 1px solid rgba(0,105,105,.3); }
.pub-edboard a:hover { border-bottom-color: var(--teal); }


/* ---- публикации: строка авторов и метаданные (единый стиль с главной) ---- */
.pub-auth { font-size: 13.5px; color: #6f7c82; line-height: 1.5; margin: 0 0 4px; }
.pub-auth b { color: var(--deep); font-weight: 600; }
.pub-meta { margin: 5px 0 0; font-size: 12.5px; line-height: 1.6; }
.pub-sep { color: #cfc9b8; margin: 0 2px; }
.pub-cit { color: #b5892a; letter-spacing: .02em; }
.pub-note { margin-top: 22px; font-size: 14px; color: var(--muted); line-height: 1.7; }
.pub-note a { color: var(--teal); }
/* нумерация статей на странице публикаций */
.pub-list { counter-reset: pubnum; }
.pub { counter-increment: pubnum; }

/* ---- подраздел пособий в блоке книг ---- */
.subhead { margin: 52px 0 10px; font-size: 26px; color: var(--deep); font-weight: 400; }
.pub-list.guides { margin-top: 18px; }

/* Главы в коллективных руководствах — карточки с обложками */
.chapter-books { margin-top: 26px; }
.chapter-books .cover-img { display: block; }
.book-title { font-family: 'Prata', Georgia, serif; font-size: 16px; color: var(--deep); line-height: 1.35; margin: 15px 0 6px; font-weight: 400; }
.book .chapters { margin-top: 10px; padding-top: 9px; border-top: 1px solid #e9e5db; font-size: 12.5px; }
.book .chapters b { display: block; color: var(--ink); font-size: 10.5px; letter-spacing: .07em; text-transform: uppercase; font-weight: 500; margin-bottom: 5px; }
.book .chapters a { display: block; font-size: 12.5px; letter-spacing: 0; text-transform: none; line-height: 1.45; margin-bottom: 4px; color: var(--teal); }
.book .chapters .ch-plain { display: block; line-height: 1.45; color: var(--muted); }
/* на телефоне держим 2 колонки — иначе обложки во всю ширину */
@media (max-width: 560px) {
  .chapter-books { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .chapter-books .book-title { font-size: 14px; margin-top: 11px; }
  .chapter-books .meta { font-size: 12px; }
  .chapter-books .chapters, .chapter-books .chapters a { font-size: 11.5px; }
}

/* ---- ссылки на источники под абзацем биографии ---- */
.src-links { display:inline-block; margin-top:8px; font-size:13.5px; color:var(--muted); }
.src-links a { color:var(--teal); }
.fact span a { color:var(--teal); }

/* ---- реальные обложки книг (фото) ---- */
.cover-img { aspect-ratio: 5 / 7.2; padding: 0; overflow: hidden; box-shadow: 0 14px 30px rgba(15,50,56,.22); transition: transform .25s ease, box-shadow .25s ease; border-radius: 3px; }
.cover-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.book:hover .cover-img { transform: translateY(-6px); box-shadow: 0 22px 40px rgba(15,50,56,.3); }

/* COOKIE NOTICE */
.cookie-notice { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 24px); width: min(680px, calc(100vw - 32px)); background: var(--deep); color: #e8e4da; padding: 16px 22px; border-radius: 10px; box-shadow: 0 18px 44px rgba(15,50,56,.4); display: flex; align-items: center; gap: 18px; z-index: 200; opacity: 0; transition: opacity .3s ease, transform .3s ease; }
.cookie-notice.is-visible { opacity: 1; transform: translate(-50%, 0); }
.cookie-notice p { margin: 0; font-size: 13px; line-height: 1.55; }
.cookie-notice a { color: var(--gold-soft); text-decoration: underline; }
.cookie-notice a:hover { color: #fff; }
.cookie-accept { flex-shrink: 0; font-family: var(--sans); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; padding: 10px 22px; background: var(--gold); color: var(--deep); border: none; border-radius: 6px; cursor: pointer; transition: background .2s ease; }
.cookie-accept:hover { background: var(--gold-soft); }
@media (max-width: 560px) { .cookie-notice { flex-direction: column; align-items: stretch; text-align: center; gap: 12px; bottom: 12px; } }

/* CITY RADIO GROUP */
.city-group { border: none; padding: 0; margin: 0 0 18px; }
.city-group legend { font-family: var(--sans); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.city-group .city-opt { display: inline-flex; align-items: center; gap: 8px; margin-right: 22px; cursor: pointer; font-size: 15px; color: var(--ink); }
.city-group .city-opt input { accent-color: var(--teal); width: 17px; height: 17px; cursor: pointer; }
@media (max-width: 560px) { .city-group .city-opt { display: flex; margin: 0 0 10px; } }

/* APPOINTMENT + SOCIAL GRID */
.appt-grid { display: grid; grid-template-columns: minmax(0, 680px) 300px; gap: 48px; align-items: start; }
.social-side h3 { margin-bottom: 8px; }
.social-side > p { color: var(--muted); font-size: 14.5px; margin-bottom: 18px; }
.soc-link { display: flex; align-items: center; gap: 13px; padding: 12px 14px; margin-bottom: 10px; border: 1px solid #e4ded2; border-radius: 10px; background: #ffffff; text-decoration: none; transition: border-color .2s, transform .2s; }
.soc-link:hover { border-color: var(--gold); transform: translateY(-1px); }
.soc-badge { flex: 0 0 40px; height: 40px; border-radius: 9px; background: var(--teal); color: var(--gold-soft); display: flex; align-items: center; justify-content: center; font-family: var(--sans); font-weight: 700; font-size: 14px; letter-spacing: .02em; }
.soc-text { display: flex; flex-direction: column; line-height: 1.25; }
.soc-text b { color: var(--ink); font-size: 15px; font-weight: 600; }
.soc-text small { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
@media (max-width: 900px) { .appt-grid { grid-template-columns: 1fr; gap: 34px; } .social-side { max-width: 480px; } }

/* BRAND SOCIAL BADGES */
.soc-badge svg { width: 20px; height: 20px; display: block; }
.soc-badge { color: #fff; }
.soc-badge.vk { background: #0077FF; }
.soc-badge.tg { background: #229ED9; }
.soc-badge.li { background: #0A66C2; }
.soc-badge.rg { background: #00CCBB; }

/* REVIEW PORTAL LINKS */
.rev-link { display: flex; align-items: center; gap: 11px; padding: 8px 0; text-decoration: none; }
.rev-link + .rev-link { border-top: 1px solid #eee7da; }
.rev-icon { flex: 0 0 34px; height: 34px; border-radius: 8px; background: #fff; border: 1px solid #e4ded2; display: flex; align-items: center; justify-content: center; }
.rev-icon img { width: 24px; height: 24px; display: block; border-radius: 4px; }
.rev-link .soc-text b { font-size: 14.5px; }
.rev-link:hover .soc-text b { color: var(--teal); }

/* ENDOTUBE BRAND LINKS */
.rev-icon.brand { border: none; color: #fff; }
.rev-icon.brand svg { width: 18px; height: 18px; }
.rev-icon.yt { background: #FF0000; }
.rev-icon.vkc { background: #0077FF; }
.rev-icon.tgc { background: #229ED9; }

/* FORMAT NOTE */
.fmt-note { font-style: normal; font-size: 12px; color: #8a8578; letter-spacing: .02em; }

/* DIRECT CONTACT BADGE */
.soc-badge.mail { background: #1a3b3c; }

/* NAV SOCIAL ICONS (без подписей, в шапке) */
.nav-links { margin-left: auto; }
.nav-socials { display: flex; align-items: center; gap: 9px; margin-left: 22px; }
.nav-soc-ic {
  width: 28px; height: 28px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; flex: 0 0 auto;
  transition: transform .18s ease, opacity .18s ease;
}
.nav-soc-ic svg { width: 14px; height: 14px; display: block; }
.nav-soc-ic:hover { transform: translateY(-2px); opacity: .88; }
.nav-soc-ic.vk { background: #0077FF; }
.nav-soc-ic.tg { background: #229ED9; }
.nav-soc-ic.yt { background: #FF0000; }
.nav-soc-ic.li { background: #0A66C2; }
.nav-soc-ic.rg { background: #00A3A3; }
@media (max-width: 960px) {
  .nav-socials { order: 3; margin-left: 14px; gap: 7px; }
  .burger { order: 4; margin-left: 14px; }
  .nav-soc-ic { width: 26px; height: 26px; }
  .nav-soc-ic svg { width: 13px; height: 13px; }
}
@media (max-width: 420px) {
  .nav-socials { gap: 6px; margin-left: 8px; }
  .nav-soc-ic { width: 24px; height: 24px; }
  .nav-soc-ic svg { width: 12px; height: 12px; }
}

/* NAV CTA (только мобильная шапка) */
.nav-cta { display: none; }
@media (max-width: 960px) {
  .nav-cta {
    display: inline-block; order: 3;
    background: var(--deep); color: #fff;
    font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
    padding: 8px 13px; border-radius: 999px; white-space: nowrap;
    margin-left: 10px;
  }
  .nav-cta:hover { background: var(--teal); color: #fff; }
  .nav-socials { order: 2; margin-left: auto; }
  .burger { order: 4; }
}
@media (max-width: 420px) {
  .nav-cta { font-size: 9px; padding: 7px 9px; margin-left: 6px; letter-spacing: .06em; }
  .nav-socials { gap: 5px; margin-left: 8px; }
  .nav-soc-ic { width: 24px; height: 24px; }
  .nav-soc-ic svg { width: 12px; height: 12px; }
}

/* NAV ICONS GRAYSCALE */
.nav-socials .nav-soc-ic { background: #b9bdb9; }
.nav-socials .nav-soc-ic:hover { opacity: 1; transform: translateY(-2px); }
.nav-socials .nav-soc-ic.vk:hover { background: #0077FF; }
.nav-socials .nav-soc-ic.tg:hover { background: #229ED9; }

/* FOOTER MOBILE FIX */
@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}

/* LONG WORDS WRAP (нейроиммуноэндокринология и т.п.) */
h1, h2, h3 { overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; }

/* ANCHOR OFFSET под sticky-шапку */
section[id], div[id] { scroll-margin-top: 88px; }
