/* The remaining homepage sections follow the accepted neutral/yellow system. */
.home-page .home-section {
  --program-control-radius: 8px;
  padding: 72px 0;
  scroll-margin-top: 104px;
}
.home-page .home-section h2 {
  margin: 0;
  color: var(--site-heading-color);
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: -.015em;
  text-wrap: balance;
}
.home-page .home-section h3 {
  margin: 0 0 8px;
  color: var(--site-heading-color);
  font-size: 20px;
  line-height: 1.3;
  letter-spacing: -.01em;
}
.home-page .home-section p {
  margin: 0;
  color: var(--site-text-color);
  font-size: 17px;
  line-height: 1.6;
  text-wrap: pretty;
}
.home-page .home-split {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  align-items: start;
  gap: 56px;
}
.home-page .home-section-intro p { margin-top: 20px; max-width: 52ch; }
.home-page .home-review-media { min-width: 0; }
.home-page .review-play,
.home-page .photo-open {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 16px;
  background: var(--znayka-soft);
  color: var(--site-heading-color);
  cursor: pointer;
}
.home-page .review-play img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.home-page .review-play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--znayka-accent);
  color: var(--site-heading-color);
  transition: background-color 160ms ease;
}
.home-page .review-play-icon svg { width: 28px; height: 28px; margin: 0; display: block; }
.home-page .home-slider-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.home-page .home-review-media .home-slider-controls { margin-top: 20px; }
.home-page .home-review-count { margin-right: auto; }
.home-page :is(.home-arrow, .home-review-prev, .home-review-next, .home-gallery-prev, .home-gallery-next, .photo-modal-prev, .photo-modal-next) {
  display: inline-grid;
  place-items: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0;
  border: 1px solid var(--znayka-line);
  border-radius: 8px;
  background: var(--znayka-surface);
  color: var(--site-heading-color);
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease;
}
.home-page :is(.home-arrow, .home-review-prev, .home-review-next, .home-gallery-prev, .home-gallery-next, .photo-modal-prev, .photo-modal-next) svg { display: block; width: 24px; height: 24px; }
.home-page :is(.home-arrow, .home-review-prev, .home-review-next, .home-gallery-prev, .home-gallery-next, .photo-modal-prev, .photo-modal-next):is(:disabled, .swiper-button-disabled) {
  opacity: .4;
  cursor: default;
  pointer-events: none;
}
.home-page .home-faq-list { min-width: 0; }
.home-page .faq-item { margin: 0; border: 1px solid var(--znayka-line); border-radius: 12px; background: var(--znayka-surface); }
.home-page .faq-item + .faq-item { margin-top: 12px; }
.home-page .faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 64px;
  padding: 20px 24px;
  border-radius: 12px;
  color: var(--site-heading-color);
  font-family: var(--site-text-font);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.5;
  list-style: none;
  cursor: pointer;
}
.home-page .faq-item summary::-webkit-details-marker { display: none; }
.home-page .faq-plus { display: block; flex: 0 0 24px; width: 24px; height: 24px; transition: transform 160ms ease; }
.home-page .faq-item[open] summary { padding-bottom: 12px; }
.home-page .faq-item[open] .faq-plus { transform: rotate(45deg); }
.home-page .faq-answer { padding: 0 24px 24px; }
.home-page .faq-answer p + p { margin-top: 12px; }
.home-page .faq-answer a,
.home-page .home-map figcaption a,
.home-page .home-video-fallback,
.home-page .home-footer-address-link {
  color: var(--site-heading-color);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.home-page .home-section-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 32px; }
.home-page .home-gallery { overflow: hidden; }
.home-page .home-gallery .home-slider-controls { flex-shrink: 0; }
.home-page .photo-open img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.home-page .home-photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.home-page .gallery-item { min-width: 0; }
.home-page .gallery-item[hidden] { display: none; }
.home-page .gallery-actions { display: flex; justify-content: center; margin-top: 28px; }
.home-page .gallery-more { min-height: var(--home-control-height); border: 1px solid var(--znayka-line); border-radius: var(--home-control-radius); padding: 12px 24px; background: var(--znayka-surface); color: var(--site-heading-color); font: 500 16px/24px var(--site-text-font); cursor: pointer; }
.home-page .gallery-more:focus-visible { outline: 2px solid #3776b4; outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
  .home-page .gallery-more:hover { border-color: var(--znayka-accent); background: var(--znayka-accent); }
}
@media (max-width: 991px) {
  .home-page .home-photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
}
@media (max-width: 639px) {
  .home-page .home-photo-grid { gap: 12px; }
  .home-page .gallery-more { width: 100%; background: var(--znayka-accent); border-color: var(--znayka-accent); }
}
.home-page .home-contacts > .container > h2 { margin-bottom: 32px; }
.home-page .home-contact-grid { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 48px; align-items: start; }
.home-page .home-addresses { margin: 0; font-style: normal; }
.home-page .home-address + .home-address { margin-top: 28px; }
.home-page .home-address h3 { margin-bottom: 6px; }
.home-page .home-contact-phone,
.home-page .home-footer-phone {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  color: var(--site-heading-color);
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
}
.home-page .home-contact-phone { margin-top: 24px; font-size: 22px; }
.home-page .home-contact-phone svg { width: 24px; height: 24px; flex-shrink: 0; }
.home-page .home-map { min-width: 0; margin: 0; }
.home-page .home-map iframe { display: block; width: 100%; height: 400px; border: 0; border-radius: 16px; background: var(--znayka-soft); }
.home-page .home-map figcaption { margin-top: 12px; color: var(--site-text-color); font-size: 14px; line-height: 1.5; }
.home-page .home-footer { padding: 56px 0 28px; background: var(--znayka-surface); }
.home-page .home-footer-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr)); gap: 56px; align-items: start; }
.home-page .home-footer-brand { min-width: 0; }
.home-page .logo-home-footer { display: inline-flex; align-items: center; gap: 20px; color: var(--site-heading-color); text-decoration: none; }
.home-page .logo-home-footer img { display: block; flex: 0 0 82px; width: 82px; height: 84px; object-fit: contain; }
.home-page .logo-home-footer span { font-size: 18px; font-weight: 500; line-height: 1.4; text-transform: none; }
.home-page .home-footer-vk { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin-top: 16px; color: var(--site-text-color); font-size: 15px; line-height: 22px; text-decoration: none; }
.home-page .home-footer-vk img { display: block; width: 28px; height: 28px; }
.home-page .home-footer h2 { margin: 0 0 12px; color: var(--site-heading-color); font-size: 18px; line-height: 1.4; }
.home-page .home-footer-nav ul { display: grid; grid-template-columns: minmax(0,1fr); gap: 0 20px; margin: 0; padding: 0; list-style: none; }
.home-page .home-footer-nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 0; color: var(--site-text-color); font-size: 16px; line-height: 24px; text-decoration: none; }
.home-page .home-footer-contact { display: flex; flex-direction: column; align-items: flex-start; }
.home-page .home-footer-phone { font-size: 19px; white-space: nowrap; }
.home-page .home-footer-phone svg { width: 22px; height: 22px; flex-shrink: 0; }
.home-page .home-footer-hours { display: grid; gap: 8px; max-width: 280px; margin: 16px 0 0; color: var(--site-text-color); font-size: 14px; line-height: 22px; font-variant-numeric: tabular-nums; }
.home-page .home-footer-hours > div { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.home-page .home-footer-hours dt { font-weight: 400; }
.home-page .home-footer-hours dd { margin: 0; white-space: nowrap; }
.home-page .home-footer-address-link { display: inline-flex; align-items: center; min-height: 44px; margin-top: 8px; padding: 8px 0; font-size: 14px; line-height: 22px; }
.home-page .home-footer-bottom { margin-top: 32px; color: var(--znayka-muted); font-size: 14px; line-height: 1.5; }
.home-page .home-footer-bottom small { font-size: inherit; }
.home-page #modalPhoto .modal-dialog { max-width: 1100px; }
.home-page #homeVideoModal .modal-dialog { width: calc(100% - 24px); max-width: 900px; margin-inline: auto; }
.home-page :is(#modalPhoto, #homeVideoModal) .modal-content { padding: 16px; border: 0; border-radius: 16px; background: var(--znayka-surface); }
.home-page .photo-modal-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 44px; margin-bottom: 12px; }
.home-page .photo-modal-toolbar h2 { margin: 0; color: var(--site-heading-color); font-size: 20px; line-height: 1.3; }
.home-page :is(#modalPhoto, #homeVideoModal) .photo-modal-toolbar .btn-close { position: static; flex: 0 0 44px; width: 44px; height: 44px; padding: 0; margin: 0; background-size: 14px; border-radius: 8px; background-color: var(--znayka-soft); }
.home-page .photo-modal-image { display: block; width: 100%; height: min(70vh, 800px); height: min(70dvh, 800px); object-fit: scale-down; border-radius: 12px; background: var(--znayka-soft); }
.home-page .photo-modal-footer { display: flex; align-items: center; gap: 12px; margin-top: 12px; color: var(--site-text-color); font-size: 15px; line-height: 22px; font-variant-numeric: tabular-nums; }
.home-page .photo-modal-footer > :first-child { min-width: 0; margin-right: auto; }
.home-page .photo-modal-footer .home-slider-controls { flex-shrink: 0; }
.home-page .photo-modal-caption { margin: 0; font-size: 15px; line-height: 22px; }
.home-page .photo-modal-count { display: block; margin-top: 4px; color: var(--znayka-muted); font-size: 14px; line-height: 22px; }
.home-page .home-video-frame { min-width: 0; overflow: hidden; border-radius: 12px; background: var(--znayka-soft); }
.home-page .home-video-frame video { display: block; width: 100%; height: auto; max-height: calc(100vh - 192px); max-height: calc(100dvh - 192px); object-fit: contain; background: #202327; }
.home-page .home-video-error { margin: 12px 0 0; color: var(--site-text-color); font-size: 14px; line-height: 1.5; }
.home-page .home-video-error[hidden] { display: none; }
.home-page .home-video-fallback { display: inline-flex; align-items: center; min-height: 44px; margin: 8px 0 0; color: var(--site-heading-color); font-size: 14px; line-height: 1.5; }
.home-page :is(.home-section, .home-footer, #modalPhoto, #homeVideoModal) :is(a,button,summary):focus-visible { outline: 2px solid #3776b4 !important; outline-offset: 3px; }
.home-page :is(.review-play, .photo-open):focus-visible { outline-offset: -3px; }
.home-page :is(.home-section, .home-footer, #modalPhoto, #homeVideoModal) :is(a,button):active { transform: none; }
.home-page :is(.home-section, .home-footer, #modalPhoto, #homeVideoModal) ::selection { background: #ffeb96; color: var(--site-heading-color); }
@media (hover: hover) and (pointer: fine) {
  .home-page :is(.home-arrow, .home-review-prev, .home-review-next, .home-gallery-prev, .home-gallery-next, .photo-modal-prev, .photo-modal-next):not(:disabled):not(.swiper-button-disabled):hover { background: var(--znayka-accent); border-color: var(--znayka-accent); }
  .home-page .review-play:hover .review-play-icon { background: #f2bf00; }
  .home-page .faq-item summary:hover { background: var(--znayka-soft); }
  .home-page .home-footer :is(.home-footer-nav a, .home-footer-vk):hover { text-decoration: underline; text-underline-offset: 4px; }
}
@media (min-width: 992px) and (max-width: 1199px) {
  .home-page .home-split { grid-template-columns: 270px minmax(0,1fr); gap: 36px; }
  .home-page .home-contact-grid { grid-template-columns: 300px minmax(0,1fr); gap: 32px; }
  .home-page .home-footer-grid { gap: 32px; }
  .home-page .home-footer-nav ul { gap: 0 12px; }
}
@media (max-width: 991px) {
  .home-page .home-section { scroll-margin-top: 24px; }
  .home-page .home-split { grid-template-columns: minmax(0,1fr); gap: 28px; }
  .home-page .home-section h2 { font-size: 32px; padding-right: 44px; }
  .home-page .home-section-intro p { padding-right: 44px; }
  .home-page .home-review-media .home-slider-controls { padding-right: 56px; }
  .home-page .faq-item summary { padding-right: 68px; }
  .home-page .faq-answer { padding-right: 68px; }
  .home-page .home-gallery .home-slider-controls { margin-right: 56px; }
    .home-page .home-contact-grid { grid-template-columns: minmax(0,1fr); gap: 32px; }
  .home-page .home-addresses { padding-right: 44px; }
  .home-page .home-contacts .detail-enroll { width: calc(100% - 44px); }
  .home-page .home-map { margin-right: 44px; }
  .home-page .home-map figcaption { padding-right: 0; }
  .home-page .home-footer-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 32px; }
  .home-page .home-footer-brand { grid-column: 1 / -1; }
  .home-page .home-footer-vk { margin-top: 0; margin-left: 24px; vertical-align: middle; }
}
@media (max-width: 767px) {
  .home-page .home-section { padding: 56px 0; }
  .home-page .home-section h2 { font-size: 28px; }
  .home-page .home-section p { font-size: 16px; }
  .home-page .home-section-intro p { margin-top: 16px; }
  .home-page .review-play-icon { width: 56px; height: 56px; }
  .home-page .review-play-icon svg { width: 24px; height: 24px; }
  .home-page .home-review-media .home-slider-controls { margin-top: 16px; }
  .home-page .faq-item summary { gap: 16px; padding: 18px 64px 18px 20px; font-size: 16px; }
  .home-page .faq-answer { padding: 0 64px 20px 20px; }
  .home-page .home-section-heading { flex-wrap: wrap; gap: 16px; margin-bottom: 24px; }
  .home-page .home-section-heading h2 { flex-basis: 100%; }
  .home-page .home-gallery .home-slider-controls { margin-left: auto; }
  .home-page .home-contacts > .container > h2 { margin-bottom: 24px; }
  .home-page .home-contact-phone { font-size: 18px; }
  .home-page .home-map iframe { height: 320px; }
  .home-page .home-footer { padding: 40px 0 24px; }
  .home-page .home-footer-bottom { margin-top: 28px; }
  .home-page #modalPhoto .modal-dialog,
  .home-page #homeVideoModal .modal-dialog { margin: 12px; }
  .home-page :is(#modalPhoto, #homeVideoModal) .modal-content { padding: 12px; }
  .home-page .photo-modal-toolbar { gap: 12px; }
  .home-page .photo-modal-toolbar h2 { font-size: 18px; }
  .home-page .photo-modal-image { height: 60vh; height: 60dvh; }
}
@media (max-width: 599px) {
  .home-page .home-footer-grid { grid-template-columns: minmax(0,1fr); gap: 28px; }
  .home-page .home-footer-brand { grid-column: auto; }
  .home-page .home-footer-vk { display: flex; width: fit-content; margin: 12px 0 0; }
  .home-page .home-footer-nav ul { max-width: 360px; }
  .home-page .home-footer-phone { font-size: 20px; }
}
@media (max-width: 359px) {
  .home-page .faq-item summary { gap: 12px; padding-left: 16px; }
  .home-page .faq-answer { padding-left: 16px; }
  .home-page .logo-home-footer { gap: 16px; }
  .home-page .logo-home-footer span { font-size: 17px; }
  .home-page .home-footer-phone { font-size: 18px; }
  .home-page .photo-modal-toolbar h2 { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-page :is(.home-arrow, .home-review-prev, .home-review-next, .home-gallery-prev, .home-gallery-next, .photo-modal-prev, .photo-modal-next, .review-play-icon, .faq-plus) { transition: none; }
}

/* Keep the complete portrait video frame within the shared preview size. */
.home-page .lower-video-grid .review-play img.review-frame-portrait { object-fit: contain; background: var(--znayka-soft); }
