/* The First School — landing (Tilda principles + school theme) */
:root {
  --navy: #0039a6;
  --navy-mid: #002d85;
  --accent-gradient: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  --ink: var(--navy);
  --ink-muted: #4a6280;
  --gold: #e21e2d;
  --gold-hover: #c41926;
  --white: #ffffff;
  --notebook-line: rgba(160, 180, 200, 0.2);
  --notebook-margin: rgba(9, 45, 93, 0.12);
  --paper: #fcfcfa;
  --paper-alt: #f7f6f2;
  --card: #ffffff;
  --section-pad: clamp(4rem, 8vw, 7rem);
  --h2: clamp(1.75rem, 4vw, 2.5rem);
  --radius: 14px;
  --shadow: 0 12px 40px rgba(26, 43, 61, 0.1);
  --font-display: "Literata", Georgia, serif;
  --font-body: "Nunito", system-ui, sans-serif;
  --header-offset: 132px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    linear-gradient(90deg, transparent 0, transparent calc(72px - 1px), var(--notebook-margin) calc(72px - 1px), var(--notebook-margin) 72px, transparent 72px),
    repeating-linear-gradient(transparent, transparent 31px, var(--notebook-line) 31px, var(--notebook-line) 32px);
  background-size: 100% 32px;
  overflow-x: hidden;
}

main {
  position: relative;
  z-index: 2;
}

img,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

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

.notebook-bg a:not(.btn),
.section--alt a:not(.btn),
.section:not(.section--accent) a:not(.btn) {
  color: var(--navy);
}

.section--accent a,
.footer a {
  color: #fff;
}

a:hover {
  text-decoration: underline;
}

.container {
  width: min(1140px, 92vw);
  margin-inline: auto;
}

/* Секции: фон полупрозрачный — декор просвечивает */
.notebook-bg {
  background: transparent;
}

.notebook-bg > .container,
.notebook-bg.hero {
  position: relative;
  z-index: 1;
}

.section--alt {
  background: rgba(247, 246, 242, 0.72);
}

.section--accent {
  background: var(--accent-gradient);
  color: #fff;
}

.section--accent p,
.section--accent li,
.section--accent label,
.section--accent .section-intro,
.section--accent .contact-block__info p {
  color: rgba(255, 255, 255, 0.92);
}

.section--accent .contact-block__info a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.section--accent .form-card {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
}

.section--accent .form-group label {
  color: #fff;
}

.section--accent .form-group input,
.section--accent .form-group select,
.section--accent .form-group textarea {
  background: rgba(255, 255, 255, 0.95);
  color: var(--navy);
  border-color: rgba(255, 255, 255, 0.35);
}

.section--accent .section-header h2,
.section--accent h2 {
  color: #fff;
}

.section--accent .section-tag {
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
}

/* Floating school supplies */
.school-decor {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.school-item {
  position: absolute;
  opacity: 0.24;
  animation: floatItem 4s ease-in-out infinite;
  filter: drop-shadow(0 6px 14px rgba(9, 45, 93, 0.12));
}

.school-item:nth-child(odd) {
  animation-direction: alternate-reverse;
  animation-duration: 3.2s;
}

.school-item:nth-child(3n) {
  animation-duration: 3.8s;
}

.school-item:nth-child(5n) {
  animation-duration: 4.6s;
}

@keyframes floatItem {
  0%,
  100% {
    transform: translateY(0) rotate(var(--rot, 0deg)) scale(var(--scale, 1));
  }
  50% {
    transform: translateY(-28px) rotate(calc(var(--rot, 0deg) + 10deg)) scale(var(--scale, 1));
  }
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--paper);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--notebook-line);
  transition: box-shadow 0.3s, transform 0.3s;
}

.header.is-scrolled {
  box-shadow: var(--shadow);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 0;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
  text-decoration: none;
  line-height: 0;
  flex-shrink: 0;
}

.header .logo img {
  height: 108px;
  width: auto;
  max-width: min(480px, 68vw);
  object-fit: contain;
  object-position: left center;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  align-items: center;
}

.nav a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-muted);
  text-decoration: none;
}

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

/* Buttons — visual hierarchy CTA */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.85rem 1.6rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s, background 0.2s;
}

.btn--primary {
  background: var(--gold);
  box-shadow: none;
}

.btn--primary:hover {
  background: var(--gold-hover);
  transform: translateY(-2px);
  text-decoration: none;
}

.btn--primary,
.btn--light,
.btn--submit,
a.btn--primary,
a.btn--light,
button.btn--primary,
button.btn--submit {
  color: var(--white);
}

.btn--primary:hover,
.btn--light:hover,
.btn--submit:hover,
a.btn--primary:hover,
a.btn--light:hover,
button.btn--primary:hover,
button.btn--submit:hover {
  color: var(--white);
  text-decoration: none;
}

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

.btn--outline:hover,
.btn--outline:focus-visible {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  text-decoration: none;
}

a.btn:hover,
a.btn:focus-visible {
  text-decoration: none;
}

a.btn--outline:hover,
a.btn--outline:focus-visible {
  color: var(--white);
}

.btn--light {
  background: var(--gold);
  box-shadow: none;
}

.btn--light:hover {
  background: var(--gold-hover);
  text-decoration: none;
}

/* Hero */
.hero {
  position: relative;
  z-index: 1;
  padding: calc(6.5rem + var(--header-offset)) 0 var(--section-pad);
  min-height: 90vh;
  display: flex;
  align-items: center;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15;
  margin: 0 0 0.5rem;
  color: var(--ink);
}

.hero__subtitle {
  margin: 0 0 1rem;
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--ink-muted);
}

.hero__lead {
  font-size: 1.2rem;
  color: var(--ink-muted);
  margin-bottom: 1.5rem;
}

.hero__lead-main {
  margin: 0 0 0.85rem;
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.4;
  color: var(--ink);
}

.hero__perks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.hero__perks li {
  margin: 0;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(9, 45, 93, 0.08);
  color: var(--navy);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.3;
}

.hero__lead p {
  margin: 0 0 0.5rem;
  line-height: 1.55;
}

.hero__lead p:last-child {
  margin-bottom: 0;
}

.hero__badge {
  display: inline-block;
  background: var(--gold);
  color: var(--white);
  font-weight: 800;
  font-size: clamp(1.15rem, 3vw, 1.5rem);
  padding: 0.7rem 1.35rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  transform: rotate(-2deg);
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.hero__visual {
  position: relative;
}

.hero__card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  border: 2px solid rgba(120, 145, 165, 0.2);
}

.hero__card-caption {
  margin: 0 0 0.75rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink-muted);
}

.hero__card video {
  border-radius: calc(var(--radius) - 4px);
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  background: var(--ink);
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* Видео — полноэкранное окно */
.video-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.video-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.video-lightbox__backdrop {
  position: absolute;
  inset: 0;
  border: none;
  padding: 0;
  background: rgba(9, 45, 93, 0.82);
  cursor: pointer;
}

.video-lightbox__dialog {
  position: relative;
  z-index: 1;
  width: min(1100px, 96vw);
  background: var(--card);
  border-radius: var(--radius);
  padding: 1.25rem 1.25rem 1.5rem;
  box-shadow: 0 24px 64px rgba(9, 45, 93, 0.35);
  border: 3px solid var(--gold);
  transform: scale(0.92);
  transition: transform 0.35s ease;
}

.video-lightbox.is-open .video-lightbox__dialog {
  transform: scale(1);
}

.video-lightbox__title {
  margin: 0 2.5rem 0.75rem 0;
  font-weight: 700;
  color: var(--navy);
  font-size: 1.1rem;
}

.video-lightbox__close {
  position: absolute;
  top: 0.65rem;
  right: 0.75rem;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}

.video-lightbox__close:hover {
  background: var(--navy-mid);
}

.video-lightbox__dialog video {
  width: 100%;
  max-height: min(72vh, 620px);
  aspect-ratio: 16/9;
  object-fit: contain;
  background: var(--navy);
  border-radius: calc(var(--radius) - 4px);
}

body.is-video-open {
  overflow: hidden;
}

/* Wave divider — single style (Tilda) */
.wave-divider {
  display: block;
  width: 100%;
  height: 56px;
  margin-bottom: -1px;
}

.wave-divider--flip {
  transform: scaleY(-1);
  margin-top: -1px;
  margin-bottom: 0;
}

/* Sections */
.section {
  position: relative;
  z-index: 1;
  padding: var(--section-pad) 0;
}

.section.notebook-bg {
  isolation: isolate;
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3rem;
}

.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(226, 30, 45, 0.1);
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}

.section h2 {
  font-family: var(--font-display);
  font-size: var(--h2);
  margin: 0 0 0.75rem;
  color: var(--ink);
}

.section-intro {
  color: var(--ink-muted);
  margin: 0;
  font-size: 1.1rem;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* Feature cards */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(26, 43, 61, 0.06);
  border: 1px solid var(--notebook-line);
  transition: transform 0.35s, box-shadow 0.35s;
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.feature-card__img {
  aspect-ratio: 4/3;
  object-fit: cover;
  width: 100%;
}

.feature-card__body {
  padding: 1.25rem;
}

.feature-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin: 0 0 0.5rem;
}

.feature-card p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ink-muted);
}

/* Образовательный процесс */
.section-header--process {
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}

#process .section-header h2 {
  color: #fff;
}

#process .section-header .section-intro {
  color: #ffffff !important;
  font-size: clamp(1.2rem, 2.6vw, 1.45rem) !important;
  font-weight: 800 !important;
  line-height: 1.4;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
  background: rgba(0, 0, 0, 0.35) !important;
  display: inline-block !important;
  padding: 0.6rem 1.25rem;
  border-radius: 999px;
  margin-top: 0.5rem;
}

#process .section-header--process + .process-grid {
  margin-top: 0;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  align-items: stretch;
}

.process-swipe-hint {
  display: none;
}

.process-item {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.process-item__img {
  flex: 0 0 auto;
  height: 160px;
  overflow: hidden;
  border-radius: var(--radius) var(--radius) 0 0;
  background: rgba(0, 0, 0, 0.15);
}

.process-item__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
}

#process .process-item:first-child .process-item__img img {
  object-position: center center;
}

.process-item__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.1);
  padding: 1.25rem;
  border-radius: 0 0 var(--radius) var(--radius);
  border-left: 4px solid var(--white);
}

.process-item h3 {
  font-family: var(--font-display);
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
  color: #fff;
  line-height: 1.3;
}

.process-item ul {
  margin: 0;
  padding-left: 1.1rem;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.9rem;
}

.process-item li + li {
  margin-top: 0.35rem;
}

/* Programs carousel */
.programs-wrap {
  position: relative;
}

.programs-track {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 1rem;
  scrollbar-width: thin;
  scrollbar-color: var(--navy) transparent;
}

.program-card {
  flex: 0 0 min(300px, 85vw);
  scroll-snap-align: start;
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--notebook-line);
  transition: transform 0.3s;
}

.program-card:hover {
  transform: scale(1.02);
}

.program-card__img {
  height: 160px;
  object-fit: cover;
  width: 100%;
}

.program-card__body {
  padding: 1.1rem;
}

.program-card__dir {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.35rem;
}

.program-card h3 {
  font-size: 1.05rem;
  margin: 0 0 0.5rem;
}

.program-card p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

/* Partners */
.partners-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 2rem;
  align-items: center;
  justify-items: center;
}

.partners-grid img {
  max-height: 56px;
  width: auto;
  object-fit: contain;
  filter: grayscale(0.2);
  opacity: 0.85;
  transition: opacity 0.3s, filter 0.3s;
}

.partners-grid img:hover {
  opacity: 1;
  filter: none;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.price-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--card);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  text-align: center;
  border: 2px solid var(--notebook-line);
  position: relative;
  transition: border-color 0.3s, transform 0.3s;
  height: 100%;
}

.price-card .btn {
  margin-top: auto;
  width: 100%;
  max-width: 260px;
}

.price-card:hover {
  border-color: var(--gold);
  transform: translateY(-4px);
}

.price-card--border-blue {
  border-color: var(--navy);
  border-width: 3px;
}

.price-card--border-red {
  border-color: var(--gold);
  border-width: 3px;
}

.price-card__amount {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin: 0.5rem 0;
}

.price-card__note {
  font-size: 0.85rem;
  color: var(--ink-muted);
  margin: 1rem 0 1.25rem;
  flex-grow: 1;
}

/* Pansion gallery */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.gallery img {
  border-radius: 10px;
  aspect-ratio: 1;
  object-fit: cover;
  width: 100%;
  transition: transform 0.4s;
}

.gallery img:hover {
  transform: scale(1.05);
  z-index: 2;
  position: relative;
}

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.team-card {
  text-align: center;
  background: var(--card);
  padding: 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--notebook-line);
  transition: box-shadow 0.3s;
}

.team-card:hover {
  box-shadow: var(--shadow);
}

.team-card img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 8%;
  margin: 0 auto 0.75rem;
  border: 3px solid var(--navy);
}

.team-card__name {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 0.35rem 0 0;
  color: var(--ink);
}

.team-card__role {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.4;
  color: #5b7c9d;
  text-transform: none;
}

/* CTA banner */
.cta-banner {
  background: linear-gradient(135deg, rgba(9, 45, 93, 0.88) 0%, rgba(16, 34, 102, 0.88) 100%);
  color: var(--white);
  border-left: 6px solid var(--white);
  text-align: center;
  padding: 3rem 2rem;
  border-radius: var(--radius);
  margin: 2rem 0;
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 30h60M30 0v60' stroke='rgba(255,255,255,0.08)'/%3E%3C/svg%3E");
  opacity: 0.5;
}

.cta-banner h2 {
  color: var(--white);
  position: relative;
  margin-bottom: 0.5rem;
}

.cta-banner p {
  position: relative;
  margin-bottom: 1.5rem;
  font-size: 1.15rem;
}

.cta-banner .btn {
  position: relative;
}

/* Contact block + map (как на лендинге школы) */
.contact-block__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 2rem;
  align-items: stretch;
}

.contact-block__info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-block__info .btn--light {
  align-self: flex-start;
  margin-bottom: 0.5rem;
}

.contact-block__map {
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 360px;
  background: rgba(0, 0, 0, 0.15);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.contact-block__map iframe,
.contact-block__map .leaflet-container {
  width: 100%;
  height: 100%;
  min-height: 360px;
  border: 0;
  display: block;
}

.contact-form-section .section-header h2,
.contact-form-section .section-header .section-intro {
  color: var(--navy);
}

/* Contact form */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 560px;
  margin-inline: auto;
}

.form-card {
  background: var(--card);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 2px solid var(--notebook-line);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 1rem;
  border: 2px solid var(--notebook-line);
  border-radius: 8px;
  background: var(--paper);
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--navy);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.form-success {
  display: none;
  padding: 1rem;
  background: rgba(9, 45, 93, 0.08);
  color: var(--navy);
  border-radius: 8px;
  font-weight: 600;
}

.form-success.is-shown {
  display: block;
}

.contact-form-section .btn--submit {
  width: 100%;
  background: var(--gold);
  border: none;
  box-shadow: none;
}

.contact-form-section .btn--submit:hover {
  background: var(--gold-hover);
}
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 1.25rem;
  font-size: 0.92rem;
  line-height: 1.4;
  cursor: pointer;
}
.form-check input {
  width: auto;
  margin-top: 4px;
  flex-shrink: 0;
}
.form-check a {
  color: var(--navy);
  text-decoration: underline;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Scroll to top */
.scroll-top {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 90;
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 16px;
  background: var(--gold);
  color: var(--white);
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(9, 45, 93, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.3s, visibility 0.3s, transform 0.3s, background 0.2s;
}

.scroll-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-top:hover {
  background: var(--gold-hover);
  color: var(--white);
}

.scroll-top svg {
  width: 22px;
  height: 22px;
}

/* Footer */
.footer {
  background: var(--accent-gradient);
  color: rgba(255, 255, 255, 0.92);
  padding: 3rem 0 1.5rem;
  position: relative;
  z-index: 1;
}

.footer a {
  color: #fff;
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer h3 {
  color: #fff;
  font-size: 1rem;
  margin: 0 0 1rem;
}


.footer__copy {
  text-align: center;
  font-size: 0.85rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.footer__copy a {
  color: inherit;
  text-decoration: underline;
  margin-left: 12px;
}

/* Mobile menu */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
}

/* Medical highlight */
.med-card {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
  background: var(--card);
  padding: 2rem;
  border-radius: var(--radius);
  align-items: center;
  box-shadow: var(--shadow);
}

.med-card img {
  border-radius: 50%;
  width: 180px;
  height: 180px;
  object-fit: cover;
  object-position: center 8%;
}

.pansion-title {
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.med-card__name {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
}

.med-card__role {
  font-weight: 700;
  color: #5b7c9d;
  margin: 0 0 0.75rem;
}

/* Выезжающий блок набора справа */
.enrollment-zone {
  position: fixed;
  right: 0;
  top: calc(var(--header-offset) + 0.5rem);
  z-index: 95;
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  width: 36px;
  min-height: min(320px, 55vh);
  overflow: visible;
}

.enrollment-zone.is-active,
.enrollment-zone.is-hovering {
  width: auto;
  max-width: min(320px, 92vw);
}

.enrollment-slide {
  position: relative;
  display: flex;
  flex-direction: row-reverse;
  align-items: stretch;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  filter: drop-shadow(-6px 4px 20px rgba(9, 45, 93, 0.18));
  pointer-events: auto;
}

.enrollment-slide.is-open,
.enrollment-zone.is-hovering:not(.is-dismissed) .enrollment-slide {
  transform: translateX(0);
}

.enrollment-slide__handle {
  width: 52px;
  min-height: 120px;
  padding: 0;
  border: none;
  background: var(--gold);
  color: var(--white);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s;
}

.enrollment-slide__handle:hover {
  background: var(--gold-hover);
}

.enrollment-slide.is-open .enrollment-slide__handle {
  transform: rotate(180deg);
}

.enrollment-slide__body {
  width: min(260px, 72vw);
  padding: 1.35rem 1.5rem;
  background: var(--gold);
  color: var(--white);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  align-items: flex-start;
  justify-content: center;
}

.enrollment-slide__text {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--white);
}

.enrollment-slide__link {
  font-size: 1rem;
  font-weight: 800;
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.enrollment-slide__link:hover {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
}

/* Responsive */
@media (max-width: 900px) {
  .enrollment-zone {
    top: calc(var(--header-offset) - 2rem);
    z-index: 101;
    width: 31px;
    min-height: min(220px, 38vh);
  }

  .enrollment-zone.is-active,
  .enrollment-zone.is-hovering {
    max-width: min(262px, 89vw);
  }

  .enrollment-slide__handle {
    width: 41px;
    min-height: 84px;
    font-size: 1.4rem;
  }

  .enrollment-slide__body {
    width: min(218px, 74vw);
    padding: 0.85rem 0.9rem;
    gap: 0.6rem;
  }

  .enrollment-slide__text {
    font-size: 0.74rem;
    line-height: 1.28;
  }

  .enrollment-slide__link {
    font-size: 0.84rem;
  }

  body.is-menu-open .enrollment-zone {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

  body.is-menu-open .enrollment-zone .enrollment-slide {
    transform: translateX(100%);
  }

  .enrollment-zone.is-scrolled-away {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

  .enrollment-zone.is-scrolled-away .enrollment-slide {
    transform: translateX(100%);
  }

  .hero {
    min-height: auto;
    padding: calc(4rem + var(--header-offset)) 0 2rem;
    align-items: flex-start;
  }

  .hero__grid {
    grid-template-columns: 1fr;
    gap: 1.15rem;
  }

  .hero h1 {
    font-size: clamp(1.55rem, 7vw, 2rem);
    margin-bottom: 0.35rem;
    line-height: 1.2;
  }

  .hero__subtitle {
    font-size: 1rem;
    margin-bottom: 0.85rem;
  }

  .hero__lead {
    margin-bottom: 1.1rem;
    padding: 0;
    background: none;
    box-shadow: none;
  }

  .hero__lead-main {
    font-size: 1.02rem;
    margin-bottom: 0.7rem;
  }

  .hero__perks {
    gap: 0.4rem;
  }

  .hero__perks li {
    font-size: 0.82rem;
    padding: 0.4rem 0.7rem;
  }

  .hero__badge {
    font-size: clamp(0.95rem, 3.6vw, 1.1rem);
    padding: 0.5rem 0.9rem;
    margin-bottom: 0.65rem;
  }

  .hero__cta {
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
    margin-top: 0.85rem;
  }

  .hero__cta .btn {
    width: 100%;
    padding: 0.7rem 1rem;
    font-size: 0.88rem;
  }

  #watch-video-btn {
    display: none;
  }

  .hero__card {
    padding: 0.65rem;
  }

  .hero__card-caption {
    margin: 0 0 0.5rem;
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--ink-muted);
  }

  .contact-block__grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .contact-block__map {
    min-height: 280px;
    order: 2;
  }

  .contact-block__info {
    order: 1;
  }

  .contact-block__map iframe,
  .contact-block__map .leaflet-container {
    min-height: 280px;
  }

  .process-swipe-hint {
    display: block;
    margin: 0.75rem 0 0;
    font-size: 0.85rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.85);
  }

  .process-grid {
    display: flex;
    gap: 0.85rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 0.25rem 0.5rem 0.85rem;
    margin: 0 -0.5rem;
    scrollbar-width: thin;
  }

  .process-item {
    flex: 0 0 min(82vw, 300px);
    scroll-snap-align: start;
    min-height: 100%;
  }

  .process-item__img {
    height: 170px;
    background: rgba(0, 0, 0, 0.18);
  }

  #process .process-item:first-child .process-item__img img {
    object-fit: contain !important;
    object-position: center center !important;
  }

  .team-card img {
    object-position: center 5%;
  }

  .med-card img {
    object-position: center 5%;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }

  .med-card {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .med-card img {
    margin: 0 auto;
  }

  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--paper-alt);
    padding: 1rem;
    border-bottom: 1px solid var(--notebook-line);
    box-shadow: var(--shadow);
  }

  .nav.is-open {
    display: flex;
  }

  .menu-toggle {
    display: block;
  }
}

@media (max-width: 560px) {
  :root {
    --header-offset: 108px;
  }

  .hero h1 {
    font-size: 1.35rem;
  }

  .hero__subtitle {
    font-size: 0.95rem;
  }

  .hero__lead-main {
    font-size: 0.95rem;
  }

  .hero__cta .btn {
    font-size: 0.84rem;
    padding: 0.62rem 0.85rem;
  }

  .header .logo img {
    height: 88px;
    max-width: min(340px, 78vw);
  }
}

@media (prefers-reduced-motion: reduce) {
  .enrollment-slide {
    transition: none;
  }

  .reveal,
  .school-item {
    animation: none;
    transition: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}


.social-section {
  padding-top: 24px;
  background: #eef3ff;
}
.social-qr-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 320px));
  justify-content: center;
  gap: 28px;
  margin-top: 12px;
}
.social-qr-card {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 28px 24px 24px;
  background: #fff;
  border-radius: 24px;
  border: 2px solid transparent;
  box-shadow: 0 18px 50px rgba(0, 31, 99, .12);
  color: inherit;
  text-decoration: none;
  transition: transform .3s ease, box-shadow .3s ease;
}
.social-qr-card--vk { border-color: #0077ff; }
.social-qr-card--max { border-color: #4f6bff; }
.social-qr-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 56px rgba(0, 31, 99, .18);
}
.social-qr-card img {
  width: min(240px, 100%);
  height: auto;
}
.social-qr-card span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}
.social-qr-card--vk span { background: #0077ff; }
.social-qr-card--max span { background: #4f6bff; }

.pc-consent-root {
  display: none;
  position: relative;
  z-index: 999999;
}
html.pc-show-consent .pc-consent-root {
  display: block;
}
.pc-consent {
  display: block;
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 999999;
  max-width: min(420px, calc(100vw - 32px));
  padding: 14px 16px 12px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 8px 32px rgba(0, 31, 99, .18);
  font-family: inherit;
  font-size: 13px;
  line-height: 1.45;
  color: #222;
  opacity: 1;
  transform: translateY(0);
  transition: opacity .3s ease, transform .3s ease;
}
.pc-consent--hidden {
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
}
.pc-consent__text {
  margin: 0 0 10px;
}
.pc-consent__link {
  color: var(--navy);
  text-decoration: underline;
}
.pc-consent__btn {
  display: inline-block;
  margin: 0;
  padding: 4px 10px;
  border: 1px solid #c8c8c8;
  border-radius: 6px;
  background: #fff;
  color: #222;
  font: inherit;
  font-size: 12px;
  line-height: 1.3;
  cursor: pointer;
}
.pc-consent__btn:hover,
.pc-consent__btn:focus {
  border-color: #999;
  background: #f7f7f7;
}
@media (max-width: 480px) {
  .pc-consent {
    left: 12px;
    right: 12px;
    bottom: 12px;
    max-width: none;
  }
}
@media (max-width: 560px) {
  .social-qr-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .social-qr-card { padding: 16px 10px 14px; }
  .social-qr-card span { min-width: 0; min-height: 36px; padding: 0 12px; font-size: 13px; }
}
