:root {
  --primary: #2f3ec4;
  --primary-dark: #232f9e;
  --primary-light: #eef0fc;
  --accent: #ffc531;
  --accent-dark: #e6a800;
  --ink: #10163a;
  --ink-soft: #4c527a;
  --muted: #8a90b4;
  --bg: #f6f8fd;
  --white: #ffffff;
  --green: #16a34a;
  --red: #dc2626;
  --radius: 18px;
  --shadow: 0 10px 40px rgba(23, 32, 90, 0.10);
  --shadow-sm: 0 4px 16px rgba(23, 32, 90, 0.08);
  --font: 'Manrope', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 114px; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.nav-open { overflow: hidden; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 15px; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.center { text-align: center; margin-top: 36px; }
.accent { color: var(--primary); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 13px 26px; border-radius: 999px;
  font-size: 15px; font-weight: 700; line-height: 1.2;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn--primary {
  background: linear-gradient(135deg, #4353e0, var(--primary-dark));
  color: #fff;
  box-shadow: 0 8px 24px rgba(47, 62, 196, .35);
}
.btn--primary:hover { box-shadow: 0 12px 32px rgba(47, 62, 196, .45); transform: translateY(-2px); }
.btn--primary:disabled { opacity: .45; box-shadow: none; cursor: not-allowed; transform: none; }
.btn--ghost { background: var(--primary-light); color: var(--primary); }
.btn--ghost:hover { background: #e2e6fa; }
.btn--outline { background: transparent; color: var(--primary); box-shadow: inset 0 0 0 2px #ccd2f2; }
.btn--outline:hover { box-shadow: inset 0 0 0 2px var(--primary); }
.btn--white { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }
.btn--white:hover { transform: translateY(-2px); }
.btn--lg { padding: 16px 32px; font-size: 16px; }
.btn--sm { padding: 9px 18px; font-size: 14px; }

.topbar {
  position: relative;
  z-index: 4;
  background: var(--ink);
  color: #c9cdea;
  font-size: 13px;
  font-weight: 500;
}
.topbar__inner { display: flex; align-items: center; gap: 22px; min-height: 38px; flex-wrap: nowrap; }
.topbar__item { display: inline-flex; align-items: center; gap: 6px; }
.topbar__item svg { opacity: .7; flex: none; }
.topbar__right { margin-left: auto; display: flex; align-items: center; gap: 22px; }
.topbar__phone { color: #fff; font-weight: 800; letter-spacing: .2px; }
a.topbar__item:hover { color: #fff; }

.site-head {
  position: sticky;
  top: 0;
  z-index: 100;
  overflow: visible;
  background: var(--ink);
}
.header {
  position: relative;
  z-index: 3;
  overflow: visible;
  background: #fff;
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.nav-backdrop {
  display: none;
}
.header.is-scrolled { border-bottom-color: #e6e9f6; box-shadow: 0 4px 24px rgba(23,32,90,.06); }
.header__inner { display: flex; align-items: center; gap: 28px; height: 76px; }

.brand { display: flex; align-items: center; gap: 11px; }
.brand__logo { width: 42px; height: 42px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__text b { font-size: 19px; font-weight: 800; color: var(--primary-dark); letter-spacing: -.3px; }
.brand__text small { font-size: 10.5px; font-weight: 700; color: var(--accent-dark); text-transform: uppercase; letter-spacing: 1.6px; }
.brand--light .brand__text b { color: #fff; }

.nav { display: flex; gap: 26px; margin-left: 8px; }
.nav a { font-size: 15px; font-weight: 600; color: var(--ink-soft); transition: color .15s; }
.nav a:hover { color: var(--primary); }
.nav__book { display: none; }

.header__actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.header__call {
  display: none; width: 44px; height: 44px; border-radius: 50%;
  background: var(--primary-light); color: var(--primary);
  align-items: center; justify-content: center;
}

.burger { display: none; flex-direction: column; gap: 5px; padding: 8px; }
.burger span { width: 22px; height: 2.5px; border-radius: 2px; background: var(--ink); transition: .25s; }
.burger.is-open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 480px at 85% -10%, #dfe4fb 0%, transparent 60%),
    radial-gradient(700px 420px at -10% 110%, #fdf3d8 0%, transparent 55%),
    var(--bg);
}
.hero__inner {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px;
  align-items: center; padding: 64px 24px 72px;
}
.hero__badge {
  display: inline-flex; align-items: center; gap: 7px;
  background: #fff; border-radius: 999px; padding: 8px 16px;
  font-size: 13.5px; font-weight: 600; color: var(--ink-soft);
  box-shadow: var(--shadow-sm); margin-bottom: 22px;
}
.hero__stars { color: var(--accent-dark); letter-spacing: 2px; font-size: 12px; }
.hero h1 {
  font-size: clamp(30px, 4.2vw, 50px);
  font-weight: 800; line-height: 1.12; letter-spacing: -1.2px;
  margin-bottom: 18px;
}
.hero__sub { font-size: 17px; color: var(--ink-soft); max-width: 520px; margin-bottom: 30px; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 44px; }

.hero__stats { display: flex; gap: 34px; list-style: none; flex-wrap: wrap; }
.hero__stats li { display: flex; flex-direction: column; }
.hero__stats b { font-size: 27px; font-weight: 800; color: var(--primary-dark); letter-spacing: -.5px; }
.hero__stats b::after { content: '+'; color: var(--accent-dark); }
.hero__stats span { font-size: 13px; color: var(--muted); font-weight: 600; }

.hero__media { position: relative; }
.hero__img-wrap {
  border-radius: 32px; overflow: hidden;
  box-shadow: var(--shadow);
  background: linear-gradient(160deg, #e8ebfb, #f7f8fe);
}
.hero__img { width: 100%; height: 520px; object-fit: cover; object-position: center; }

/* ---------- strip ---------- */
.strip { background: linear-gradient(120deg, #3949d6, var(--primary-dark)); }
.strip__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 28px 0;
  color: #fff;
}
.strip__copy {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}
.strip__icon {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, .14);
  color: #fff;
}
.strip__text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.strip__text b { font-size: 19px; font-weight: 800; letter-spacing: -.3px; line-height: 1.25; }
.strip__text span { color: #d5daff; font-size: 14.5px; line-height: 1.45; }
.strip__inner .btn { flex: none; }

/* ---------- sections ---------- */
.section { padding: 84px 0; }
.section--tint { background: #fff; }
.section__head { max-width: 640px; margin-bottom: 44px; }
.section__label {
  display: inline-block; font-size: 12.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 2px; color: var(--primary);
  background: var(--primary-light); border-radius: 999px; padding: 6px 14px;
  margin-bottom: 14px;
}
.section__head h2 { font-size: clamp(26px, 3vw, 36px); font-weight: 800; letter-spacing: -.8px; line-height: 1.15; margin-bottom: 12px; }
.section__head p { color: var(--ink-soft); font-size: 16px; }

/* ---------- directions ---------- */
.dir-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.dir-card {
  background: #fff; border-radius: var(--radius); padding: 22px;
  display: flex; flex-direction: column; gap: 12px; text-align: left;
  border: 1px solid #e9ecf8;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.section--tint .dir-card { background: var(--bg); }
.dir-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); border-color: #ccd2f2; }
.dir-card.is-hidden { display: none; }
.dir-card__icon {
  width: 46px; height: 46px; border-radius: 13px;
  background: var(--primary-light); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
}
.dir-card b { font-size: 15.5px; font-weight: 800; line-height: 1.25; }
.dir-card span { font-size: 13px; color: var(--muted); font-weight: 600; margin-top: auto; }

/* ---------- doctors ---------- */
.doc-filters { display: flex; gap: 14px; margin-bottom: 30px; flex-wrap: wrap; }
.doc-search {
  flex: 1; min-width: 260px; display: flex; align-items: center; gap: 10px;
  background: var(--bg); border-radius: 14px; padding: 0 16px;
  border: 1.5px solid #e4e8f6; color: var(--muted);
  transition: border-color .15s;
}
.doc-search:focus-within { border-color: var(--primary); }
.doc-search input { flex: 1; border: none; outline: none; background: none; padding: 14px 0; color: var(--ink); }
.doc-select {
  min-width: 220px; border: 1.5px solid #e4e8f6; border-radius: 14px;
  background: var(--bg); padding: 13px 16px; outline: none; color: var(--ink);
  font-weight: 600; cursor: pointer;
}
.doc-select:focus { border-color: var(--primary); }

.doc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.doc-card {
  background: var(--bg); border-radius: var(--radius); overflow: hidden;
  border: 1px solid #e9ecf8; display: flex; flex-direction: column;
  transition: transform .18s, box-shadow .18s;
}
.doc-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); }
.doc-card__photo { position: relative; aspect-ratio: 4 / 4.4; background: linear-gradient(160deg, #e3e7fa, #f4f6fd); overflow: hidden; }
.doc-card__photo img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.doc-card__initials {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 44px; font-weight: 800; color: #b8c0ea;
}
.doc-card__body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.doc-card__body b { font-size: 15.5px; font-weight: 800; line-height: 1.25; }
.doc-card__body span { font-size: 13px; color: var(--ink-soft); font-weight: 600; margin-bottom: 12px; }
.doc-card__body .btn { margin-top: auto; }

.doc-empty { grid-column: 1 / -1; text-align: center; color: var(--muted); padding: 40px 0; font-weight: 600; }

/* ---------- steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 40px; }
.step {
  background: #fff; border: 1px solid #e9ecf8; border-radius: var(--radius);
  padding: 26px 22px; position: relative;
}
.step__num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, #4353e0, var(--primary-dark));
  color: #fff; font-weight: 800; font-size: 17px; margin-bottom: 16px;
}
.step b { display: block; font-size: 16.5px; font-weight: 800; margin-bottom: 6px; }
.step p { font-size: 14px; color: var(--ink-soft); }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.about__text h2 { font-size: clamp(26px, 3vw, 34px); font-weight: 800; letter-spacing: -.8px; line-height: 1.18; margin-bottom: 16px; }
.about__text > p { color: var(--ink-soft); margin-bottom: 24px; }
.about__list { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.about__list li { display: flex; gap: 12px; align-items: flex-start; font-weight: 600; font-size: 15px; }
.about__list svg { flex: none; color: var(--green); margin-top: 2px; }

.about__news { display: flex; flex-direction: column; gap: 16px; }
.news-card {
  display: grid; grid-template-columns: 150px 1fr; overflow: hidden;
  background: var(--bg); border: 1px solid #e9ecf8; border-radius: var(--radius);
  transition: transform .18s, box-shadow .18s;
}
.news-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); }
.news-card img { width: 100%; height: 100%; object-fit: cover; min-height: 110px; }
.news-card__body { padding: 16px 18px; }
.news-card__body b { font-size: 15px; font-weight: 800; display: block; margin-bottom: 4px; }
.news-card__body p { font-size: 13.5px; color: var(--ink-soft); }

/* ---------- reviews ---------- */
.reviews { display: grid; grid-template-columns: 260px 1fr; gap: 32px; align-items: start; }
.reviews__summary {
  background: linear-gradient(150deg, #3949d6, var(--primary-dark));
  color: #fff; border-radius: var(--radius); padding: 32px;
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  position: sticky; top: 100px;
}
.reviews__score { font-size: 54px; font-weight: 800; line-height: 1; }
.reviews__stars { color: var(--accent); font-size: 18px; letter-spacing: 3px; }
.reviews__summary p { color: #ccd3ff; font-size: 14px; margin-bottom: 10px; }
.reviews__summary .btn--outline { color: #fff; box-shadow: inset 0 0 0 2px rgba(255,255,255,.4); }
.reviews__summary .btn--outline:hover { box-shadow: inset 0 0 0 2px #fff; }

.reviews__list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.review {
  background: #fff; border: 1px solid #e9ecf8; border-radius: var(--radius);
  padding: 24px; display: flex; flex-direction: column; gap: 12px;
}
.review__stars { color: var(--accent-dark); letter-spacing: 2px; font-size: 13px; }
.review p { font-size: 14.5px; color: var(--ink-soft); flex: 1; }
.review footer { font-size: 13px; font-weight: 700; color: var(--muted); }

/* ---------- contacts ---------- */
.contacts { display: grid; grid-template-columns: 1fr 1.2fr; gap: 32px; align-items: stretch; }
.contacts__info { display: flex; flex-direction: column; gap: 14px; }
.contact-card {
  background: var(--bg); border: 1px solid #e9ecf8; border-radius: var(--radius);
  padding: 20px 24px; display: flex; flex-direction: column; gap: 4px;
}
.contact-card b { font-size: 15px; font-weight: 800; margin-bottom: 4px; }
.contact-card a { color: var(--primary); font-weight: 700; font-size: 15px; }
.contact-card a:hover { text-decoration: underline; }
.contact-card span { font-size: 14px; color: var(--ink-soft); font-weight: 600; }
.contacts__actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 6px; }
.contacts__map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); min-height: 380px; }
.contacts__map iframe { width: 100%; height: 100%; border: 0; }

/* ---------- footer ---------- */
.footer { background: var(--ink); color: #b9bedd; }
.footer__inner {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px;
  padding: 56px 24px 40px;
}
.footer__brand p { font-size: 14px; margin-top: 16px; max-width: 300px; }
.footer__col { display: flex; flex-direction: column; gap: 10px; font-size: 14.5px; }
.footer__col b { color: #fff; font-size: 15px; margin-bottom: 6px; }
.footer__col a:hover { color: #fff; }
.footer__bottom {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 20px 24px 28px; font-size: 13px; color: #7c82ab;
  border-top: 1px solid rgba(255,255,255,.08);
}

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ============================================================
   Booking modal
   ============================================================ */
.modal { position: fixed; inset: 0; z-index: 200; display: none; }
.modal.is-open { display: block; }
.modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(13, 18, 48, .55);
  backdrop-filter: blur(4px);
  animation: fadeIn .2s ease;
}
.modal__dialog {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: min(680px, calc(100vw - 32px));
  max-height: min(760px, calc(100dvh - 32px));
  background: #fff; border-radius: 24px;
  display: flex; flex-direction: column;
  box-shadow: 0 30px 80px rgba(13, 18, 48, .35);
  animation: popIn .25s cubic-bezier(.2, .9, .3, 1.2);
  overflow: hidden;
}
@keyframes fadeIn { from { opacity: 0; } }
@keyframes popIn { from { opacity: 0; transform: translate(-50%, -46%) scale(.96); } }

.modal__close {
  position: absolute; top: 16px; right: 16px; z-index: 5;
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); background: var(--bg);
  transition: background .15s, color .15s;
}
.modal__close:hover { background: #e8ebf8; color: var(--ink); }

.modal__head { padding: 26px 64px 16px 28px; }
.modal__head h3 { font-size: 21px; font-weight: 800; letter-spacing: -.4px; margin-bottom: 14px; }

.bk-progress { display: flex; gap: 8px; }
.bk-progress__dot {
  height: 5px; flex: 1; border-radius: 3px; background: #e5e8f6;
  transition: background .25s;
}
.bk-progress__dot.is-active { background: var(--primary); }

.bk-step { padding: 8px 28px 20px; overflow-y: auto; flex: 1; }

.bk-label {
  display: block; font-size: 12.5px; font-weight: 800; color: var(--muted);
  text-transform: uppercase; letter-spacing: 1.2px; margin: 14px 0 10px;
}

.bk-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.bk-chip {
  padding: 8px 15px; border-radius: 999px; font-size: 13.5px; font-weight: 700;
  background: var(--bg); color: var(--ink-soft);
  border: 1.5px solid transparent;
  transition: all .15s;
}
.bk-chip:hover { border-color: #ccd2f2; }
.bk-chip.is-active { background: var(--primary); color: #fff; }

.bk-doctors { display: flex; flex-direction: column; gap: 8px; max-height: 300px; overflow-y: auto; padding-right: 4px; }
.bk-doc {
  display: flex; align-items: center; gap: 14px; text-align: left;
  padding: 10px 14px; border-radius: 14px;
  border: 1.5px solid #e9ecf8; background: #fff;
  transition: all .15s;
}
.bk-doc:hover { border-color: #ccd2f2; background: var(--bg); }
.bk-doc.is-active { border-color: var(--primary); background: var(--primary-light); }
.bk-doc__avatar {
  width: 48px; height: 48px; border-radius: 50%; flex: none; overflow: hidden;
  background: #dfe3f7; display: flex; align-items: center; justify-content: center;
  font-weight: 800; color: #99a2d8; font-size: 16px;
}
.bk-doc__avatar img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.bk-doc__info b { display: block; font-size: 14.5px; line-height: 1.25; }
.bk-doc__info span { font-size: 12.5px; color: var(--muted); font-weight: 600; }

.bk-doctor-mini {
  display: flex; align-items: center; gap: 13px;
  background: var(--primary-light); border-radius: 14px; padding: 12px 16px;
  margin-top: 6px;
}
.bk-doctor-mini .bk-doc__avatar { width: 44px; height: 44px; }

.bk-dates { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.bk-date {
  flex: none; width: 74px; padding: 10px 6px; border-radius: 14px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  border: 1.5px solid #e9ecf8; background: #fff;
  transition: all .15s;
}
.bk-date small { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.bk-date b { font-size: 17px; font-weight: 800; }
.bk-date span { font-size: 11px; color: var(--muted); font-weight: 600; }
.bk-date:hover:not(:disabled) { border-color: #ccd2f2; }
.bk-date.is-active { border-color: var(--primary); background: var(--primary-light); }
.bk-date.is-active small, .bk-date.is-active b { color: var(--primary-dark); }
.bk-date:disabled { opacity: .38; cursor: not-allowed; }

.bk-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; min-height: 60px; }
.bk-slot {
  padding: 11px 6px; border-radius: 12px; font-size: 14.5px; font-weight: 700;
  border: 1.5px solid #e9ecf8; background: #fff; color: var(--ink);
  transition: all .15s;
}
.bk-slot:hover { border-color: #ccd2f2; }
.bk-slot.is-active { border-color: var(--primary); background: var(--primary); color: #fff; }
.bk-hint { grid-column: 1 / -1; font-size: 13.5px; color: var(--muted); font-weight: 600; }
.bk-step > .bk-hint { margin-top: 12px; }

.bk-field { margin-top: 16px; }
.bk-field label { display: block; font-size: 13.5px; font-weight: 700; color: var(--ink-soft); margin-bottom: 7px; }
.bk-field input, .bk-field textarea {
  width: 100%; border: 1.5px solid #e4e8f6; border-radius: 13px;
  padding: 13px 16px; outline: none; background: var(--bg);
  transition: border-color .15s; resize: vertical;
}
.bk-field input:focus, .bk-field textarea:focus { border-color: var(--primary); background: #fff; }
.bk-field input.is-invalid { border-color: var(--red); }

.bk-summary {
  margin-top: 8px; background: var(--bg); border-radius: 16px; padding: 6px 20px;
}
.bk-summary__row {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 12px 0; border-bottom: 1px solid #e7eaf6; font-size: 14.5px;
}
.bk-summary__row:last-child { border-bottom: none; }
.bk-summary__row span { color: var(--muted); font-weight: 600; flex: none; }
.bk-summary__row b { text-align: right; }

.bk-success { text-align: center; padding: 30px 40px 40px !important; }
.bk-success__icon {
  width: 76px; height: 76px; border-radius: 50%; margin: 0 auto 18px;
  background: #e5f7ec; color: var(--green);
  display: flex; align-items: center; justify-content: center;
}
.bk-success h3 { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.bk-success p { color: var(--ink-soft); font-size: 15px; }
.bk-code { margin: 14px 0 24px; font-size: 15px; }
.bk-code b { color: var(--primary); font-size: 18px; letter-spacing: 1px; }

.bk-error {
  margin: 0 28px 10px; padding: 12px 16px; border-radius: 12px;
  background: #fdecec; color: var(--red); font-size: 14px; font-weight: 700;
}

.modal__foot {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 16px 28px 24px; border-top: 1px solid #edf0f9;
}
.modal__foot .btn--primary { margin-left: auto; }

.bk-loader { grid-column: 1 / -1; display: flex; justify-content: center; padding: 18px; }
.bk-loader::after {
  content: ''; width: 26px; height: 26px; border-radius: 50%;
  border: 3px solid #dde2f5; border-top-color: var(--primary);
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1060px) {
  .dir-grid { grid-template-columns: repeat(3, 1fr); }
  .doc-grid { grid-template-columns: repeat(3, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .reviews__list { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 880px) {
  html { scroll-padding-top: 102px; }

  .topbar { font-size: 12.5px; }
  .topbar__inner { justify-content: center; min-height: 34px; padding-top: 0; padding-bottom: 0; }
  .topbar__item--hours,
  .topbar__right { display: none; }
  .topbar__item--address {
    display: inline-flex;
    color: #fff;
    font-weight: 700;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .header__inner { height: 64px; gap: 10px; }
  .brand__logo { width: 36px; height: 36px; }
  .brand__text b { font-size: 16px; }
  .brand__text small { font-size: 9px; letter-spacing: 1.2px; }

  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 2;
    flex-direction: column;
    gap: 0;
    margin: 0;
    padding: 8px 0 18px;
    background: #fff;
    box-shadow: 0 18px 40px rgba(23, 32, 90, .16);
    border-top: 1px solid #eef0f8;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .nav.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }
  .nav a {
    padding: 14px 22px;
    font-size: 16px;
    border-bottom: 1px solid #f0f2fa;
  }
  .nav a:last-of-type { border-bottom: none; }
  .nav__book {
    display: flex;
    margin: 14px 18px 4px;
    width: calc(100% - 36px);
  }
  .nav-backdrop {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 100dvh;
    z-index: 1;
    background: rgba(13, 18, 48, .4);
  }
  .nav-backdrop[hidden] { display: none; }

  .burger {
    display: flex;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
  }
  .header__cta {
    padding: 10px 16px;
    font-size: 13.5px;
  }
  .header__call { display: none; }

  .hero__inner { grid-template-columns: 1fr; padding: 28px 24px 40px; gap: 28px; }
  .hero__sub { max-width: none; font-size: 15.5px; margin-bottom: 22px; }
  .hero h1 { margin-bottom: 12px; }
  .hero__actions { margin-bottom: 28px; gap: 10px; }
  .hero__actions .btn { width: 100%; }
  .hero__img { height: 280px; }
  .hero__img-wrap { border-radius: 22px; }
  .hero__stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 12px;
    width: 100%;
  }
  .hero__stats b { font-size: 24px; }

  .strip { padding: 4px 0; }
  .strip__inner {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 20px 0 22px;
  }
  .strip__copy { align-items: flex-start; gap: 12px; }
  .strip__icon { width: 42px; height: 42px; border-radius: 12px; }
  .strip__text b { font-size: 17.5px; }
  .strip__text span { font-size: 13.5px; }
  .strip__inner .btn { width: 100%; }

  .about { grid-template-columns: 1fr; gap: 28px; }
  .reviews { grid-template-columns: 1fr; }
  .reviews__summary {
    position: static;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 18px;
    padding: 22px;
  }
  .reviews__score { font-size: 42px; }
  .reviews__summary p { margin: 0; }
  .contacts { grid-template-columns: 1fr; }
  .contacts__map { min-height: 260px; }
  .contacts__actions .btn { flex: 1; }

  .doc-filters { flex-direction: column; }
  .doc-search { min-width: 0; width: 100%; }
  .doc-select { width: 100%; min-width: 0; }

  .footer__inner { grid-template-columns: 1fr 1fr; gap: 32px; padding: 40px 18px 28px; }
  .section { padding: 52px 0; }
  .section__head { margin-bottom: 28px; }
}

@media (max-width: 620px) {
  .container { padding: 0 16px; }
  .dir-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .dir-card { padding: 14px; gap: 10px; border-radius: 14px; }
  .dir-card__icon { width: 40px; height: 40px; border-radius: 11px; }
  .dir-card b { font-size: 13.5px; }
  .dir-card span { font-size: 11.5px; }

  .doc-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .doc-card { border-radius: 14px; }
  .doc-card__body { padding: 12px 12px 14px; }
  .doc-card__body b { font-size: 13px; }
  .doc-card__body span { font-size: 12px; margin-bottom: 10px; }
  .doc-card__body .btn { width: 100%; padding: 10px 8px; font-size: 13px; }

  .steps { grid-template-columns: 1fr; gap: 10px; }
  .step { padding: 18px 16px; }
  .reviews__list { grid-template-columns: 1fr; }

  .news-card { grid-template-columns: 1fr; }
  .news-card img { height: 160px; min-height: 0; }

  .hero__img { height: 220px; }
  .hero__inner { padding: 22px 16px 32px; }
  .hero__badge { margin-bottom: 16px; }

  .footer__inner { grid-template-columns: 1fr; gap: 24px; }
  .footer__bottom { padding: 16px 16px 24px; }

  .contact-card { padding: 16px 16px; }
  .contacts__actions { flex-direction: column; }
  .contacts__actions .btn { width: 100%; }

  .btn--lg { padding: 14px 20px; font-size: 15px; }

  .modal__dialog {
    top: auto; bottom: 0; left: 0; transform: none;
    width: 100%; max-height: min(92dvh, calc(100dvh - 12px));
    border-radius: 22px 22px 0 0;
    animation: slideUp .28s ease;
  }
  .modal__head { padding: 20px 56px 12px 18px; }
  .modal__head h3 { font-size: 18px; }
  .bk-step { padding: 6px 16px 16px; }
  .bk-doctors { max-height: 38vh; }
  .bk-chips { gap: 6px; }
  .bk-chip { padding: 7px 12px; font-size: 13px; }
  .modal__foot { padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); }
  .modal__foot .btn { flex: 1; margin-left: 0; }
  .bk-error { margin: 0 16px 10px; }
  .bk-success { padding: 24px 20px 32px !important; }
}

@media (max-width: 380px) {
  .brand__text small { display: none; }
  .header__cta { padding: 10px 12px; font-size: 12.5px; }
}
@keyframes slideUp { from { transform: translateY(40px); opacity: 0; } }
