/* Reset & base */
:root {
  --font-main: 'Montserrat', sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--font-main); font-size: 16px; font-weight: 400; line-height: 1.5; color: #1a1a1a; background: #fff; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

.page { min-height: 100vh; display: flex; flex-direction: column; }

.container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding-left: 80px;
  padding-right: 80px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 28px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.25;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
}
.btn--primary { background: #1e3a5f; color: #fff; }
.btn--primary:hover { background: #152a47; }
.btn--secondary { background: #5b9bd5; color: #fff; }
.btn--secondary:hover { background: #4a8ac4; }

/* Header */
.header {
  padding-top: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid #e5e5e5;
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.header__logo {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
}
.header__nav {
  display: flex;
  align-items: center;
  gap: 32px;
}
.header__link {
  font-size: 16px;
  font-weight: 400;
  color: #1a1a1a;
}
.header__link:hover { color: #1e3a5f; }
.header__link--active { font-weight: 500; color: #1e3a5f; }
.header__cta { flex-shrink: 0; }

/* Hero */
.hero { padding: 80px 0 100px; }
.hero__inner {
  display: flex;
  align-items: flex-start;
  gap: 80px;
}
.hero__content { flex: 1; min-width: 0; }
.hero__name {
  margin: 0 0 16px;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  color: #1a1a1a;
}
.hero__title {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 500;
  color: #1a1a1a;
}
.hero__degree {
  margin: 0 0 24px;
  font-size: 18px;
  font-weight: 500;
  color: #1a1a1a;
}
.hero__text {
  margin: 0 0 32px;
  font-size: 16px;
  line-height: 1.6;
  color: #333;
  max-width: 560px;
}
.hero__text p { margin: 0 0 12px; }
.hero__text p:last-child { margin-bottom: 0; }
.hero__actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.hero__image-wrap {
  flex-shrink: 0;
  width: 480px;
  max-width: 100%;
  background: #f0f0f0;
  border-radius: 8px;
  overflow: hidden;
}
.hero__image {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: top;
}

/* Section title */
.section-title {
  margin: 0 0 28px;
  font-size: 28px;
  font-weight: 600;
  line-height: 1.3;
  color: #1a1a1a;
}

/* Competencies */
.competencies { padding: 80px 0; background: #fafafa; }
.competencies__inner {
  display: flex;
  align-items: flex-start;
  gap: 60px;
}
.competencies__image-wrap {
  flex-shrink: 0;
  width: 360px;
  max-width: 100%;
  background: #eee;
  border-radius: 8px;
  overflow: hidden;
}
.competencies__image {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: top;
}
.competencies__content { flex: 1; min-width: 0; }
.competencies__list {
  margin: 0 0 40px;
  padding-left: 20px;
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}
.competencies__list li { margin-bottom: 12px; }
.competencies__list strong { font-weight: 600; color: #1a1a1a; }
.competencies__stats {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}
.stat-block {
  display: flex;
  flex-direction: column;
}
.stat-block__number {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.1;
  color: #5b9bd5;
}
.stat-block__label {
  font-size: 16px;
  color: #333;
  margin-top: 8px;
}

/* Experience */
.experience { padding: 80px 0 100px; }
.experience__inner { max-width: 900px; }
.experience__inner .section-title { margin-bottom: 24px; }
.tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
}
.tabs__btn {
  flex: 1;
  padding: 14px 28px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  background: #5b9bd5;
  color: #fff;
  transition: background 0.2s, color 0.2s;
  white-space: normal;
  text-align: center;
  min-width: 0;
}
.tabs__btn--active {
  background: #2C4A70;
  color: #fff;
  font-weight: 600;
}
.tabs__btn:not(.tabs__btn--active):hover {
  background: #4a8ac4;
  color: #fff;
}
.tabs--three .tabs__btn { flex: 1; min-width: 0; }
.path-tab-content { display: block; }
.path-tab-content--hidden { display: none; }
.experience__list {
  border: 1px solid #d8e4ed;
  border-radius: 8px;
  overflow: hidden;
}
.experience__item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  padding: 18px 24px;
  font-size: 15px;
  line-height: 1.5;
  border-bottom: 1px solid #eaeef2;
  background: #fff;
}
.experience__item:last-child { border-bottom: none; }
.experience__text { color: #333; flex: 1; }
.experience__date { color: #64748b; flex-shrink: 0; font-size: 15px; }

/* Consultation (blue block) */
.consultation {
  padding: 80px 0;
  background: #3d6ea5;
}
.consultation__inner { max-width: 560px; margin: 0 auto; }
.consultation__title {
  margin: 0 0 40px;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.25;
  color: #fff;
  text-align: center;
}
.consultation__form { display: flex; flex-direction: column; gap: 20px; }
.consultation__input,
.consultation__textarea {
  width: 100%;
  padding: 16px 20px;
  font-family: inherit;
  font-size: 16px;
  line-height: 1.5;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
}
.consultation__input::placeholder,
.consultation__textarea::placeholder { color: #888; }
.consultation__textarea { resize: vertical; min-height: 120px; }
.btn--submit {
  margin-top: 8px;
  width: 100%;
  max-width: 200px;
  margin-left: auto;
  margin-right: auto;
}
.consultation__success {
  display: none;
  text-align: center;
  color: #fff;
  font-weight: 700;
  font-size: 42px;
  line-height: 1.2;
  padding: 48px 24px;
}
.consultation__success.form-success--visible {
  display: block;
}
.consultation__form.form--hidden {
  display: none !important;
}
.consultation__title.form-success-title-hidden,
.booking-form-box__title.form-success-title-hidden {
  display: none !important;
}

/* Footer */
.footer {
  padding: 60px 0 80px;
  background: #fff;
  border-top: 1px solid #e5e5e5;
}
.footer__inner {
  display: flex;
  justify-content: space-between;
  gap: 60px;
  align-items: flex-start;
}
.footer__about { max-width: 480px; }
.footer__desc {
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.6;
  color: #333;
}
.footer__name {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
}
.footer__contacts-title {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 600;
  color: #1a1a1a;
}
.footer__contact {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.5;
  color: #333;
}
.footer__contact a:hover { color: #1e3a5f; }

/* ========== About page ========== */

/* About hero (two columns + sidebar) */
.about-hero { padding: 80px 0 100px; }
.about-hero__inner {
  display: flex;
  align-items: flex-start;
  gap: 80px;
}
.about-hero__content { flex: 1; min-width: 0; max-width: 560px; }
.about-hero__name {
  margin: 0 0 12px;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  color: #1a1a1a;
}
.about-hero__degree {
  margin: 0 0 24px;
  font-size: 18px;
  font-weight: 400;
  color: #1a1a1a;
}
.about-hero__text {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}
.about-hero__text p { margin: 0 0 12px; }
.about-hero__text p:last-child { margin-bottom: 0; }
.about-hero__right {
  display: flex;
  gap: 24px;
  flex-shrink: 0;
  align-items: flex-start;
  min-width: 0;
}
.about-hero__image-wrap {
  width: 400px;
  max-width: 100%;
  height: 340px;
  flex-shrink: 0;
  background: #f0f0f0;
  border-radius: 8px;
  overflow: hidden;
}
.about-hero__image { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; }

/* About sidebar nav — светлый блок с тонкой рамкой как в макете */
.about-nav {
  width: 240px;
  padding: 24px;
  background: #f8f9fa;
  border: 1px solid #e2e6ea;
  border-radius: 8px;
}
.about-nav__title {
  margin: 0 0 16px;
  font-size: 17px;
  font-weight: 600;
  color: #1a1a1a;
}
.about-nav__list { display: flex; flex-direction: column; gap: 10px; }
.about-nav__link {
  font-size: 15px;
  font-weight: 400;
  color: #333;
  display: block;
}
.about-nav__link:hover { color: #1e3a5f; }

/* About sections */
.about-section { padding: 80px 0; }
.about-section:nth-child(even) { background: #fafafa; }
.about-section__inner { max-width: 900px; }
.about-section--achievements .about-section__inner { max-width: 1162px; }

/* About skills (big number) */
.about-skills__intro {
  margin: 0 0 24px;
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}
.about-skills__number {
  font-size: 64px;
  font-weight: 700;
  color: #5b9bd5;
  vertical-align: middle;
  margin: 0 4px;
}
.about-skills__sub {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 500;
  color: #1a1a1a;
}
.about-skills__list {
  margin: 0;
  padding-left: 20px;
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}
.about-skills__list li { margin-bottom: 8px; }

/* Achievement cards — сетка адаптивная, без фиксированных пикселей */
.achievements {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  width: 100%;
  max-width: 1162px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}
/* Третий блок — иконка слева, текст справа */
.achievement-card--small {
  grid-column: 1 / -1;
  justify-self: center;
  width: 100%;
  max-width: 318px;
  min-height: 132px;
  padding: 16px 18px;
  gap: 12px;
  border-radius: 26px;
  border: 1px solid #e2e6ea;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 97px 1fr;
  grid-template-rows: 1fr;
  align-items: center;
  justify-items: start;
}
.achievement-card--small .achievement-card__icon {
  width: 97px;
  height: 111px;
  margin-bottom: 0;
  border-radius: 0;
  background: transparent;
  grid-column: 1;
  grid-row: 1;
}
.achievement-card--small .achievement-card__icon img {
  width: 97px;
  height: 111px;
  object-fit: contain;
}
.achievement-card--small .achievement-card__text {
  min-width: 0;
  max-width: 100%;
  grid-column: 2;
  grid-row: 1;
  display: flex;
  align-items: center;
  margin: 0;
  font-family: var(--font-main);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: 0;
  text-align: left;
  color: #333;
}
.achievement-card {
  min-width: 0;
  min-height: 194px;
  padding: 24px 28px;
  background: #fff;
  border: 1px solid #e2e6ea;
  box-sizing: border-box;
}
/* Первый блок — иконка слева, текст справа */
.achievements .achievement-card--large:first-child {
  width: 100%;
  min-height: 194px;
  padding: 16px 20px;
  gap: 15px;
  border-radius: 26px;
  border: 1px solid #e2e6ea;
  display: grid;
  grid-template-columns: 172px 1fr;
  grid-template-rows: 1fr;
  align-items: center;
  justify-items: start;
}
.achievements .achievement-card--large:first-child .achievement-card__icon {
  width: 172px;
  height: 172px;
  margin-bottom: 0;
  border-radius: 0;
  background: transparent;
  grid-column: 1;
  grid-row: 1;
}
.achievements .achievement-card--large:first-child .achievement-card__icon img {
  width: 172px;
  height: 172px;
  object-fit: contain;
}
.achievements .achievement-card--large:first-child .achievement-card__text {
  min-width: 0;
  max-width: 100%;
  grid-column: 2;
  grid-row: 1;
  margin: 0;
  font-family: var(--font-main);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: 0;
  vertical-align: middle;
  color: #333;
  align-self: center;
}
/* Второй блок — иконка слева, текст справа */
.achievements .achievement-card--large:nth-child(2) {
  width: 100%;
  min-height: 194px;
  padding: 16px 20px;
  gap: 22px;
  border-radius: 26px;
  border: 1px solid #e2e6ea;
  display: grid;
  grid-template-columns: minmax(140px, 272px) 1fr;
  grid-template-rows: 1fr;
  align-items: center;
  justify-items: start;
}
.achievements .achievement-card--large:nth-child(2) .achievement-card__icon {
  width: 100%;
  max-width: 272px;
  height: 142px;
  margin-bottom: 0;
  border-radius: 0;
  background: transparent;
  grid-column: 1;
  grid-row: 1;
}
.achievements .achievement-card--large:nth-child(2) .achievement-card__icon img {
  width: 100%;
  max-width: 272px;
  height: 142px;
  object-fit: contain;
}
.achievements .achievement-card--large:nth-child(2) .achievement-card__text {
  min-width: 0;
  max-width: 100%;
  grid-column: 2;
  grid-row: 1;
  margin: 0;
  font-family: var(--font-main);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: 0;
  vertical-align: middle;
  color: #333;
  align-self: center;
}
.achievement-card__icon {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 8px;
  background: #f0f0f0;
  margin-bottom: 16px;
}
.achievement-card__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: #333;
  flex: 1;
  overflow-y: auto;
}

/* Carousel — управление только кнопками, без полосы прокрутки */
.carousel {
  display: flex;
  align-items: center;
  gap: 20px;
}
.carousel__arrow {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(0,0,0,0.15);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.2s;
}
.carousel__arrow:hover { background: rgba(0,0,0,0.3); }
.carousel__arrow:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}
.carousel__viewport {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  margin: 0 -4px; /* чтобы крайние слайды не обрезались по краям */
}
.carousel__track {
  display: flex;
  gap: 16px;
  transition: transform 0.35s ease;
  will-change: transform;
  padding: 0 4px;
}
.carousel__track--gallery { gap: 16px; }
.carousel__slide {
  flex-shrink: 0;
}
.carousel__placeholder {
  width: 280px;
  height: 200px;
  background: #e0e0e0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #888;
}
.carousel__placeholder--cert {
  width: 220px;
  height: 300px;
}
.gallery-thumb {
  display: block;
  width: 280px;
  height: 200px;
  padding: 0;
  border: none;
  border-radius: 8px;
  overflow: hidden;
  background: #e8e8e8;
  cursor: pointer;
  flex-shrink: 0;
}
.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gallery-thumb:hover img { opacity: 0.92; }
.certificate-thumb {
  width: 220px;
  height: 300px;
  padding: 0;
  border: none;
  border-radius: 8px;
  overflow: hidden;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.certificate-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.certificate-thumb:hover img { opacity: 0.92; }

/* Лайтбокс — просмотр сертификата поверх экрана */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}
.lightbox[hidden] { display: none; }
.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  cursor: pointer;
}
.lightbox__close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.lightbox__close:hover { background: rgba(255, 255, 255, 0.3); }
.lightbox__content {
  position: relative;
  z-index: 1;
  max-width: 95vw;
  max-height: 95vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox__content {
  max-width: min(95vw, 900px);
}
.lightbox__img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}
.gallery-more { margin-top: 32px; text-align: center; }

/* Footer dark (about page) */
.footer--dark { background: #1e3a5f; border-top: none; }
.footer__desc--light,
.footer__name--light,
.footer__contacts-title--light,
.footer__contact--light { color: rgba(255,255,255,0.95); }
.footer__contact--light a { color: rgba(255,255,255,0.95); }
.footer__contact--light a:hover { color: #fff; }

/* Footer light (gallery page) */
.footer--light {
  background: #e8f0f7;
  border-top: 1px solid #d5e4f0;
}

/* ========== Gallery page ========== */
.gallery-page { padding: 48px 0 80px; flex: 1; }
.gallery-page__inner { max-width: 900px; margin: 0 auto; }
.gallery-page__title {
  margin: 0 0 32px;
  font-size: 28px;
  font-weight: 600;
  color: #1a1a1a;
}

.breadcrumbs {
  margin-bottom: 20px;
  font-size: 14px;
  color: #64748b;
}
.breadcrumbs__link { color: #1e3a5f; }
.breadcrumbs__link:hover { text-decoration: underline; }
.breadcrumbs__sep { margin: 0 6px; }
.breadcrumbs__current { color: #64748b; }

.gallery-toggle {
  display: flex;
  gap: 12px;
  margin-bottom: 40px;
}
.gallery-toggle__btn {
  padding: 16px 32px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.25;
  border: none;
  border-radius: 28px;
  cursor: pointer;
  background: #e8f0f7;
  color: #4a5568;
  transition: background 0.2s, color 0.2s;
}
.gallery-toggle__btn--active {
  background: #1e3a5f;
  color: #fff;
  font-weight: 600;
}
.gallery-toggle__btn:not(.gallery-toggle__btn--active):hover {
  background: #d5e4f0;
  color: #1a1a1a;
}

.gallery-content { display: block; }
.gallery-content--hidden { display: none; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 48px;
}
.gallery-grid__item {
  aspect-ratio: 1;
  min-height: 0;
}
.gallery-grid__item:last-child:nth-child(3n+1) { grid-column: 2; justify-self: center; }
.gallery-grid__thumb {
  width: 100%;
  height: 100%;
  padding: 0;
  border: none;
  border-radius: 8px;
  overflow: hidden;
  background: #e0e0e0;
  cursor: pointer;
  display: block;
}
.gallery-grid__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gallery-grid__thumb:hover img { opacity: 0.92; }
/* По умолчанию показываем только первую страницу (9 фото), остальные скрыты до пагинации */
.js-gallery-grid .gallery-grid__item[data-page]:not([data-page="1"]) { display: none; }
.gallery-grid__placeholder {
  width: 100%;
  height: 100%;
  background: #e0e0e0;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #888;
}
.gallery-grid__placeholder--video { background: #d5d5d5; }

/* Секция видео: три карточки в ряд, на адаптиве — друг под другом, крупнее */
.gallery-video {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}
.video-card__link {
  color: inherit;
  text-decoration: none;
  display: block;
}
.video-card__thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  min-height: 180px;
  background: #d5d5d5;
  border-radius: 0;
  overflow: hidden;
  margin-bottom: 12px;
}
.video-card__thumb img,
.video-card__thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.video-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: #888;
  background: #d5d5d5;
}
.video-card__duration {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 4px 8px;
  font-size: 13px;
  font-weight: 500;
  color: #fff;
  background: rgba(0, 0, 0, 0.65);
  border-radius: 0;
}
.video-card__title {
  margin: 0;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  color: #333;
}
.video-card__title:hover { color: #1e3a5f; }

/* Больше видео */
.gallery-more-videos {
  margin-bottom: 48px;
}
.gallery-more-videos__label {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 500;
  color: #1a1a1a;
}
.gallery-more-videos__links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.gallery-more-videos__item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: #1e3a5f;
  text-decoration: none;
}
.gallery-more-videos__item:hover { text-decoration: underline; }
.gallery-more-videos__icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  display: block;
}

.gallery-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 16px;
  margin-top: 32px;
  flex-wrap: wrap;
  color: #64748b;
}
.gallery-pagination__link {
  color: #1e3a5f;
  padding: 4px 10px;
  border-radius: 6px;
}
.gallery-pagination__link:hover { background: #e8f0f7; }
.gallery-pagination__link--active {
  font-weight: 600;
  color: #1e3a5f;
  background: #e8f0f7;
}
.gallery-pagination__dots { margin-left: 4px; }
.gallery-page__inner--video .gallery-pagination { display: none; }

/* ========== Science page (Наука) ========== */
.science-page { padding: 48px 0 80px; flex: 1; }
.science-page__inner { max-width: 900px; margin: 0 auto; }
.science-page__title {
  margin: 0 0 40px;
  font-size: 28px;
  font-weight: 600;
  color: #1a1a1a;
  text-align: center;
}

.science-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.science-card {
  display: block;
  text-decoration: none;
  color: inherit;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.2s, transform 0.2s;
}
.science-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}
.science-card:last-child {
  grid-column: 1 / -1;
  justify-self: center;
  max-width: calc(50% - 12px);
}

.science-card__image-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  background: #e8e8e8;
  overflow: hidden;
}
.science-card__image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.science-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #999;
  text-align: center;
  padding: 20px;
}
.science-card__overlay {
  display: none; /* убран синий квадрат слева сверху */
}
.science-card__label {
  display: block;
  padding: 16px 20px;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: #1e3a5f;
  text-align: center;
}

/* ========== Monographs page (Монографии) ========== */
.monographs-page { padding: 48px 0 80px; flex: 1; }
.monographs-page__inner { max-width: 900px; margin: 0 auto; }
.monographs-page__title {
  margin: 0 0 40px;
  font-size: 28px;
  font-weight: 600;
  color: #1a1a1a;
  text-align: center;
}

.monographs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.monograph-card {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.monograph-card__cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  background: #e5e5e5;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 20px;
}
.monograph-card__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.monograph-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: #888;
  text-align: center;
  padding: 16px;
}
.monograph-card__btn {
  width: 100%;
  max-width: 200px;
}

/* ========== Literature page (страница книги) ========== */
.literature-page { padding: 48px 0 80px; flex: 1; }
.literature-page__inner { max-width: 900px; margin: 0 auto; }

.literature-book {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 48px;
  align-items: start;
}
.literature-book__cover-wrap {
  position: relative;
  width: 100%;
}
.literature-book__cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  background: #e5e5e5;
  border-radius: 8px;
  overflow: hidden;
}
.literature-book__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.literature-book__cover--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #888;
  text-align: center;
  padding: 20px;
}
.literature-book__info { min-width: 0; }
.literature-book__title {
  margin: 0 0 20px;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
  color: #1a1a1a;
}
.literature-book__meta {
  margin: 0 0 28px;
  font-size: 16px;
  color: #555;
  line-height: 1.5;
}
.literature-book__btn { display: inline-block; }

/* ========== Patents page (Патенты на изобретение) ========== */
.patents-page { padding: 48px 0 80px; flex: 1; }
.patents-page__inner { max-width: 900px; margin: 0 auto; }
.patents-page__title {
  margin: 0 0 40px;
  font-size: 28px;
  font-weight: 600;
  color: #1a1a1a;
  text-align: center;
}

.patents-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  justify-items: center;
}
.patents-item {
  width: 100%;
  max-width: 260px;
  aspect-ratio: 3 / 4;
  background: #e8ebe8;
  border-radius: 4px;
  overflow: hidden;
  border: none;
  padding: 0;
  cursor: pointer;
  display: block;
  font: inherit;
}
.patents-item:hover { opacity: 0.92; }
.patents-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.patents-item__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #888;
  background: #e8ebe8;
}

/* ========== Reviews page (Отзывы) ========== */
.reviews-page { padding: 48px 0 80px; flex: 1; }
.reviews-page__inner { max-width: 1000px; margin: 0 auto; }
.reviews-page__title {
  margin: 0 0 40px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 42px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #1a1a1a;
  text-align: center;
}

.review-slider {
  display: flex;
  align-items: stretch;
  gap: 24px;
  margin-bottom: 20px;
}
.review-slider__arrow {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  align-self: center;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.review-slider__arrow img {
  display: block;
  width: 24px;
  height: 24px;
  object-fit: contain;
}
.review-slider__arrow:hover img { opacity: 0.85; }
.review-slider__arrow:disabled { opacity: 0.4; cursor: not-allowed; }
.review-slider__arrow:disabled:hover img { opacity: 1; }
.review-slider__viewport {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}
.review-slider__track {
  display: flex;
  transition: transform 0.35s ease;
  will-change: transform;
}
.review-slider__track .review-card {
  flex-shrink: 0;
  box-sizing: border-box;
}

.review-card {
  padding: 28px 32px;
  background: #e8f0f7;
  border-radius: 12px;
  position: relative;
  min-height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.review-card__date {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-style: normal;
  font-size: 18px;
  line-height: 100%;
  letter-spacing: 0;
  text-align: center;
  vertical-align: middle;
  color: #64748b;
  margin-bottom: 14px;
}
.review-card__text {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 20px;
  line-height: 1.4;
  letter-spacing: 0;
  text-align: center;
  vertical-align: middle;
  color: #333;
  flex: 1;
}

.review-slider__dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 40px;
}
.review-slider__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c5d9e8;
  border: none;
  cursor: pointer;
  padding: 0;
}
.review-slider__dot--active { background: #1e3a5f; }
.review-slider__dot:hover:not(.review-slider__dot--active) { background: #a8c5dc; }

.reviews-more {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
}
.reviews-more__label {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 32px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #1a1a1a;
}
.reviews-more__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}
.reviews-more__item {
  display: inline-flex;
  align-items: center;
  transition: opacity 0.2s;
}
.reviews-more__item:hover { opacity: 0.85; }
.reviews-more__icon {
  width: 48px;
  height: 48px;
  display: block;
  flex-shrink: 0;
}
.reviews-more__item--prodoctorov .reviews-more__icon {
  width: 191.43px;
  height: 21.17px;
  object-fit: contain;
  object-position: left center;
}

/* ========== Services page (Стоимость услуг) ========== */
.services-page { padding: 48px 0 80px; flex: 1; }
.services-page__inner { max-width: 1000px; margin: 0 auto; }
.services-page__title {
  margin: 0 0 40px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 42px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #1a1a1a;
  text-align: center;
}
.services-page__intro {
  margin: 0 auto 32px;
  max-width: 720px;
  font-size: 16px;
  line-height: 1.5;
  color: #444;
}

.services-table { }
.services-table__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  padding: 20px 0;
  border-bottom: 1px solid #d8e4ed;
  font-size: 16px;
  line-height: 1.5;
  color: #333;
}
.services-table__row:last-child { border-bottom: none; }
.services-table__row--head {
  font-weight: 600;
  color: #1a1a1a;
  padding-top: 0;
  padding-bottom: 16px;
  border-bottom: 1px solid #1a1a1a;
}
.services-table__service { flex: 1; min-width: 0; }
.services-table__price { flex-shrink: 0; font-weight: 500; color: #1a1a1a; }

/* ========== Booking page (Запись на консультацию) ========== */
body.booking-page { background: #e6f0f8; }
body.booking-page .page { background: #e6f0f8; }
.header--booking { background: #e6f0f8; border-bottom-color: #d0e2f0; }
.footer--booking { background: #e6f0f8; border-top: 1px solid #d0e2f0; }

.booking-main {
  padding: 80px 0 60px;
  flex: 1;
}
.booking-main__inner {
  max-width: 560px;
  margin: 0 auto;
}

.booking-form-box {
  width: 100%;
  background: #58a3e7;
  border-radius: 24px;
  padding: 48px 40px 48px;
  box-sizing: border-box;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}
.booking-form-box__title {
  margin: 0 auto 32px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 32px;
  line-height: 1.2;
  color: #fff;
  text-align: center;
  box-sizing: border-box;
}
.booking-form-box__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 100%;
  margin: 0 auto;
}
.booking-form-box__input,
.booking-form-box__textarea {
  width: 100%;
  height: 56px;
  padding: 0 20px;
  font-family: 'Montserrat', sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  color: #111;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 12px;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.booking-form-box__input::placeholder,
.booking-form-box__textarea::placeholder {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-size: 16px;
  color: #9ca3af;
}
.booking-form-box__input::-webkit-input-placeholder,
.booking-form-box__textarea::-webkit-input-placeholder {
  color: #9ca3af;
}
.booking-form-box__input::-moz-placeholder,
.booking-form-box__textarea::-moz-placeholder {
  color: #9ca3af;
  opacity: 1;
}
.booking-form-box__input:focus,
.booking-form-box__textarea:focus {
  outline: none;
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}
.booking-form-box__textarea {
  height: auto;
  min-height: 100px;
  padding-top: 16px;
  padding-bottom: 16px;
  resize: vertical;
  border-radius: 12px;
}
.btn--booking-submit {
  display: block;
  width: 100%;
  max-width: 280px;
  margin: 8px auto 0;
  padding: 16px 28px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  background: #2e5f97;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s;
}
.booking-form-box__success {
  display: none;
  text-align: center;
  color: #fff;
  font-weight: 700;
  font-size: 28px;
  line-height: 1.3;
  padding: 40px 24px;
}
.booking-form-box__success.form-success--visible {
  display: block;
}
.booking-form-box__form.form--hidden {
  display: none !important;
}
.btn--booking-submit:hover { background: #264a7a; }

/* ========== Contacts page (Контакты) ========== */
.contacts-page { padding: 48px 0 80px; flex: 1; }
.contacts-page__inner { max-width: 1200px; margin: 0 auto; }
.contacts-page__title {
  margin: 0 0 8px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 28px;
  color: #1a1a1a;
}
.contacts-page__subtitle {
  margin: 0 0 32px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #333;
}
.contacts-page__lead {
  margin: 0 0 32px;
  font-size: 16px;
  line-height: 1.5;
  color: #444;
}

.contacts-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.contacts-info__heading {
  margin: 0 0 12px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 16px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #1a1a1a;
}
.contacts-info__list,
.contacts-info__schedule {
  margin: 0 0 24px;
  padding-left: 20px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 16px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #333;
}
.contacts-info__list li,
.contacts-info__schedule li { margin-bottom: 4px; }
.contacts-info__item {
  margin: 0 0 12px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 16px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #333;
}
.contacts-info__item a { color: #1e3a5f; }
.contacts-info__item a:hover { text-decoration: underline; }
.contacts-info__note {
  margin: 0 0 24px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 16px;
  line-height: 100%;
  letter-spacing: 0;
  vertical-align: middle;
  color: #555;
}
.contacts-info__heading + .contacts-info__schedule { margin-top: 0; }

.contacts-map-wrap {
  width: 758px;
  max-width: 100%;
}
.contacts-map {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-sizing: border-box;
  background: #e8e8e8;
}
.contacts-map img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  vertical-align: middle;
}
.contacts-map-wrap iframe { display: block; border-radius: 8px; width: 100%; height: 481px; }

/* ========== Адаптив (мобильное меню и верстка по макету) ========== */

/* Ноутбуки и узкие экраны */
@media (max-width: 1280px) {
  .container {
    padding-left: 40px;
    padding-right: 40px;
  }
  .booking-main { padding: 60px 0 60px; }
  .booking-form-box { padding: 44px 36px 44px; }
  .booking-form-box__title { font-size: 30px; margin-bottom: 28px; }
}

.header__burger {
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
}
.header__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #1e3a5f;
  transition: transform 0.2s, opacity 0.2s;
}
.header__menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  background: #e8f0f7;
  padding: 24px 20px 32px;
  overflow-y: auto;
}
.header__menu-inner { max-width: 400px; margin: 0 auto; }
.header__menu .header__logo {
  display: block;
  margin-bottom: 24px;
  font-size: 18px;
}
.header__menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  color: #1e3a5f;
  font-size: 28px;
  line-height: 1;
}
.header__menu-nav {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.header__menu-nav a {
  display: block;
  padding: 16px 0;
  font-size: 18px;
  font-weight: 500;
  color: #1e3a5f;
  border-bottom: 1px solid rgba(30, 58, 95, 0.15);
}
.header__menu-nav a:last-of-type { border-bottom: none; }
.header__menu-nav a.active { font-weight: 600; }
.header__menu-cta {
  margin-top: 24px;
  width: 100%;
  padding: 16px 24px;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
  border-radius: 8px;
  background: #1e3a5f;
  color: #fff;
  border: none;
  cursor: pointer;
  text-decoration: none;
  display: block;
  box-sizing: border-box;
}

@media (max-width: 1024px) {
  .container {
    padding-left: 24px;
    padding-right: 24px;
  }
  .hero__inner { flex-direction: column; gap: 40px; }
  .hero { padding: 48px 0 60px; }
  .hero__name { font-size: 28px; }
  .hero__image-wrap { width: 100%; max-width: 400px; margin: 0 auto; }
  .competencies__inner { flex-direction: column; gap: 32px; }
  .competencies__image-wrap { width: 100%; max-width: 400px; margin: 0 auto; }
  .footer__inner { flex-direction: column; gap: 32px; }
  .consultation { padding: 48px 0; }
  .about-hero__inner { flex-direction: column; gap: 40px; align-items: stretch; }
  .about-hero__content { max-width: 100%; }
  .about-hero__right {
    flex-direction: column;
    align-items: center;
    width: 100%;
    min-width: 0;
  }
  .about-hero__image-wrap {
    width: 100%;
    max-width: 360px;
    height: 306px;
    margin: 0 auto;
  }
  .about-nav { width: 100%; max-width: 400px; margin: 0 auto; box-sizing: border-box; }
  .about-nav__list { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 8px; }
  .achievements { grid-template-columns: 1fr; gap: 20px; }
  .achievements .achievement-card--large:first-child { grid-template-columns: 140px 1fr; }
  .achievements .achievement-card--large:first-child .achievement-card__icon,
  .achievements .achievement-card--large:first-child .achievement-card__icon img { width: 140px; height: 140px; }
  .achievements .achievement-card--large:nth-child(2) { grid-template-columns: minmax(100px, 200px) 1fr; }
  .achievements .achievement-card--large:nth-child(2) .achievement-card__icon { max-width: 200px; }
  .achievements .achievement-card--large:nth-child(2) .achievement-card__icon img { max-width: 100%; height: auto; max-height: 100px; }
  .achievement-card--small { max-width: 100%; grid-template-columns: minmax(80px, 97px) 1fr; align-items: center; }
  .achievement-card--small .achievement-card__icon { max-width: 97px; }
  .achievement-card--small .achievement-card__icon img { width: 100%; height: auto; max-height: 111px; object-fit: contain; }
  .gallery-video { grid-template-columns: 1fr; gap: 32px; }
  .video-card__thumb { min-height: 220px; }
  .contacts-content { grid-template-columns: 1fr; }
  .contacts-map-wrap { width: 100%; }
  .science-grid { grid-template-columns: 1fr; }
  .science-card:last-child { max-width: 100%; }
  .monographs-grid { grid-template-columns: 1fr; }
  .patents-grid { grid-template-columns: repeat(2, 1fr); }
  .reviews-more { flex-direction: column; align-items: center; }
  .gallery-tabs { flex-wrap: wrap; }
  .gallery-content--hidden { display: none !important; }
  .literature-book {
    grid-template-columns: 1fr;
    gap: 32px;
    justify-items: center;
    text-align: center;
  }
  .literature-book__cover-wrap { max-width: 280px; margin: 0 auto; }
  .literature-book__info { text-align: center; }
  .booking-main { padding: 48px 0 60px; }
  .booking-form-box { padding: 40px 32px 44px; border-radius: 20px; }
  .booking-form-box__title { font-size: 28px; margin-bottom: 28px; }
  .booking-form-box__input,
  .booking-form-box__textarea { height: 52px; border-radius: 12px; }
  .booking-form-box__textarea { min-height: 96px; }
}

@media (max-width: 768px) {
  .container {
    padding-left: 16px;
    padding-right: 16px;
  }
  .header__nav,
  .header__cta { display: none !important; }
  .header__burger { display: flex; }
  .header { padding-top: 16px; padding-bottom: 16px; }
  .header__logo { font-size: 16px; max-width: 70%; }
  .hero { padding: 32px 0 48px; }
  .hero__name { font-size: 24px; }
  .hero__title, .hero__degree { font-size: 16px; }
  .hero__actions { flex-direction: column; }
  .hero__actions .btn { width: 100%; max-width: 280px; }
  .competencies { padding: 48px 0; }
  .competencies__title { font-size: 22px; }
  .tabs { flex-wrap: wrap; gap: 10px; }
  .tabs__btn { font-size: 13px; padding: 12px 14px; min-width: 0; flex: 1 1 100%; }
  .tabs--three .tabs__btn { flex: 1 1 calc(50% - 6px); }
  .experience__item { flex-direction: column; gap: 8px; align-items: flex-start; }
  .consultation__title { font-size: 22px; }
  .consultation__form .btn { max-width: 100%; }
  .footer { padding: 32px 0; }
  .footer__inner { gap: 24px; }
  .about-hero__name { font-size: 24px; }
  .about-hero__image-wrap { max-width: 280px; height: 238px; }
  .about-nav { max-width: 100%; }
  .section-title { font-size: 22px; }
  .about-section__title { font-size: 22px; }
  .achievements .achievement-card--large:first-child { grid-template-columns: 100px 1fr; padding: 14px 16px; min-height: 160px; }
  .achievements .achievement-card--large:first-child .achievement-card__icon,
  .achievements .achievement-card--large:first-child .achievement-card__icon img { width: 100px; height: 100px; }
  .achievements .achievement-card--large:nth-child(2) { grid-template-columns: 80px 1fr; padding: 14px 16px; min-height: 160px; }
  .achievements .achievement-card--large:nth-child(2) .achievement-card__icon,
  .achievements .achievement-card--large:nth-child(2) .achievement-card__icon img { max-width: 80px; height: auto; max-height: 80px; }
  .achievement-card--small { grid-template-columns: 70px 1fr; padding: 14px 16px; max-width: 100%; }
  .achievement-card--small .achievement-card__icon,
  .achievement-card--small .achievement-card__icon img { width: 70px; height: 80px; }
  .achievement-card--small .achievement-card__text { font-size: 16px; }
  .science-page__title,
  .reviews-page__title,
  .patents-page__title,
  .monographs-page__title,
  .contacts-page__title,
  .services-page__title { font-size: 22px; }
  .reviews-more__label { font-size: 24px; }
  .review-card { padding: 20px 16px; }
  .review-card__date { font-size: 16px; }
  .review-card__text { font-size: 18px; }
  .patents-grid { grid-template-columns: 1fr; gap: 20px; }
  .patents-item { max-width: 100%; }
  .review-slider__viewport { margin: 0 -16px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .gallery-grid__item:last-child:nth-child(2n+1) { grid-column: 1 / -1; justify-self: center; max-width: 280px; }
  .gallery-grid__item:last-child:nth-child(3n+1) { grid-column: 1; justify-self: stretch; }
  .about-section .carousel__track--gallery .carousel__slide { width: min(280px, calc(100vw - 72px)); }
  .about-section .carousel__track--gallery .gallery-thumb { width: 100%; height: auto; aspect-ratio: 280 / 200; }
  .certificate-thumb { width: min(220px, calc(100vw - 72px)); height: auto; min-height: 260px; aspect-ratio: 220 / 300; }
  .certificate-thumb img { object-fit: contain; }
  .literature-book {
    grid-template-columns: 1fr;
    gap: 24px;
    justify-items: center;
    text-align: center;
  }
  .literature-book__cover-wrap { max-width: 260px; margin: 0 auto; }
  .literature-book__info { text-align: center; }
  .literature-book__title { font-size: 22px; }
  .literature-book__btn { width: 100%; max-width: 280px; }
  .literature-page { padding: 24px 0 48px; }
  .breadcrumbs { font-size: 14px; flex-wrap: wrap; }
  .booking-main { padding: 32px 0 48px; }
  .booking-form-box { padding: 28px 20px 32px; border-radius: 16px; }
  .booking-form-box__title { font-size: 22px; margin-bottom: 24px; }
  .booking-form-box__form { gap: 14px; }
  .booking-form-box__input,
  .booking-form-box__textarea { height: 52px; padding: 0 16px; border-radius: 10px; }
  .booking-form-box__textarea { min-height: 88px; padding-top: 14px; padding-bottom: 14px; }
  .btn--booking-submit { max-width: 100%; margin-top: 4px; padding: 14px; border-radius: 10px; }
  .booking-form-box__success.form-success--visible { font-size: 22px; padding: 32px 16px; }
  .about-section { padding: 48px 0; }
}

@media (max-width: 768px) {
  .header__menu { display: none; }
  .header__menu[aria-hidden="false"] { display: block; }
}

body.menu-open { overflow: hidden; }
.header__burger.is-open span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.header__burger.is-open span:nth-child(2) { opacity: 0; }
.header__burger.is-open span:nth-child(3) { transform: translateY(-4px) rotate(-45deg); }

@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr; gap: 16px; }
  .gallery-grid__item:last-child:nth-child(2n+1),
  .gallery-grid__item:last-child:nth-child(3n+1) { grid-column: 1; justify-self: stretch; max-width: none; }
  .tabs--three .tabs__btn { flex: 1 1 100%; }
  .video-card__thumb { min-height: 200px; }
}
