/* ==========================================================================
   Студия йоги — стили
   ========================================================================== */

:root {
  --teal: #235652;
  --teal-dark: #1a413e;
  --beige: #E0D3C6;
  --hero-bg: #E4DEDB;
  --cream: #EFE9E3;
  --white: #FFFFFF;
  --black: #000000;
  --mauve: #6E4442;
  --mauve-dark: #593635;
  --rose: #8B6665;
  --btn: #333333;
  --btn-hover: #235652;
  --ink: #232320;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-script: 'Arctika Script', cursive;

  --container-w: 1320px;
  --gap: clamp(1.5rem, 3vw, 2.5rem);
  --radius: 20px;
  --radius-sm: 12px;

  --section-pad: clamp(3rem, 7vw, 6rem);
  --heading-gap: clamp(2rem, 5vw, 3.5rem);
  --heading-size: clamp(1.5rem, 2.3vw, 2.15rem);

  --ease: cubic-bezier(.22,.61,.36,1);
}

@font-face {
  font-family: 'Arctika Script';
  src: url('../assets/fonts/Arctika Script.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
ul { list-style: none; margin: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; }
p { margin: 0; }
button { font-family: inherit; cursor: pointer; }
input { font-family: inherit; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 999;
  background: var(--teal); color: var(--white);
  padding: .75rem 1.25rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}

.container {
  width: 100%;
  max-width: var(--container-w);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
}

/* ---- Typography helpers ---- */
.script { font-family: var(--font-script); font-weight: 400; line-height: 1.25; }

.section-title {
  font-size: var(--heading-size);
  color: var(--teal);
  letter-spacing: -0.01em;
  margin-bottom: var(--heading-gap);
  white-space: nowrap;
}
.section-title--light { color: var(--white); }

.h2-light {
  font-size: var(--heading-size);
  line-height: 1.3;
  font-weight: 700;
  white-space: nowrap;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 1.75em 3.2em;
  min-width: 15rem;
  background: var(--btn);
  color: var(--white);
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  border-radius: 8px;
  letter-spacing: 0.01em;
  transition: background-color .35s var(--ease), transform .35s var(--ease);
  cursor: pointer;
}
.btn:hover, .btn:focus-visible { background-color: var(--btn-hover); transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--dark { background: var(--btn); }
.btn--wide { width: 100%; }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--hero-bg);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(1rem, 2.5vw, 2.5rem);
  padding-block: 1.25rem;
}
.logo {
  font-weight: 800;
  font-size: 1.15rem;
  white-space: nowrap;
}
.main-nav__list {
  display: flex;
  gap: clamp(1rem, 2.2vw, 2rem);
  flex-wrap: wrap;
}
@media (min-width: 861px) {
  .main-nav, .main-nav__list { display: contents; }
}
.main-nav__list a {
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
  padding-bottom: 2px;
}
.main-nav__list a::after {
  content: "";
  position: absolute; left: 0; bottom: -2px;
  width: 0; height: 1.5px;
  background: var(--teal);
  transition: width .3s var(--ease);
}
.main-nav__list a:hover::after, .main-nav__list a:focus-visible::after { width: 100%; }
.header-phone {
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: color .25s var(--ease);
}
.header-phone:hover { color: var(--teal); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px; height: 40px;
  background: none; border: none;
  padding: 0;
}
.nav-toggle span {
  display: block; width: 100%; height: 2px;
  background: var(--ink);
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { background: var(--hero-bg); overflow: hidden; }
.hero__inner {
  display: grid;
  grid-template-columns: 0.72fr 1.58fr;
  grid-template-areas: "text media" "cta media";
  align-items: center;
  align-content: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding-block: clamp(2.5rem, 6vw, 5rem);
}
.hero__text { grid-area: text; align-self: end; }
.hero__cta { grid-area: cta; align-self: start; }
.hero__title {
  font-size: clamp(2.2rem, 3.7vw, 2.85rem);
  color: var(--teal);
  line-height: 0.98;
  letter-spacing: -0.01em;
  margin-bottom: 0.3em;
  white-space: nowrap;
}
.hero__script {
  font-family: var(--font-script);
  color: var(--rose);
  font-size: clamp(1.7rem, 3.2vw, 2.5rem);
  line-height: 1.25;
  width: max-content;
  max-width: 32ch;
  margin-bottom: 0;
}
.hero__media {
  grid-area: media;
  position: relative;
  width: 100%;
  aspect-ratio: 1500 / 795;
}
/* Larger circle, same centre as before (77% / 39.9% of the media box) so the
   composition does not shift — only the diameter grows. */
.hero__ellipse {
  position: absolute;
  left: 54%;
  top: -3.5%;
  width: 46%;
  aspect-ratio: 1 / 1;
}
.hero__figure {
  position: absolute;
  inset: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
/* the energy frame sits on top of the calm one and fades in on hover / touch */
.hero__img--energy {
  opacity: 0;
  transform: scale(1.004);
  filter: drop-shadow(0 0 22px rgba(240, 168, 58, 0));
  transition: opacity 0.6s ease, transform 0.9s ease, filter 0.6s ease;
  will-change: opacity;
}
/* warm halo that blooms out from behind the figure */
.hero__aura {
  position: absolute;
  left: 50%;
  top: 52%;
  width: 78%;
  aspect-ratio: 2 / 1;
  transform: translate(-50%, -50%) scale(0.65);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at center,
    rgba(255, 205, 120, 0.55) 0%,
    rgba(247, 178, 71, 0.32) 38%,
    rgba(226, 154, 52, 0.12) 62%,
    rgba(226, 154, 52, 0) 78%
  );
  filter: blur(clamp(12px, 2vw, 30px));
  transition: opacity 0.7s ease, transform 0.9s cubic-bezier(0.22, 0.8, 0.3, 1);
}

.hero__media.is-energized .hero__img--energy {
  opacity: 1;
  transform: scale(1);
  filter: drop-shadow(0 0 26px rgba(240, 168, 58, 0.42));
  animation: energy-breathe 3.4s ease-in-out 0.6s infinite;
}
.hero__media.is-energized .hero__aura {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  animation: aura-pulse 3.4s ease-in-out 0.6s infinite;
}
/* pointer devices get it straight from :hover, no JS needed */
@media (hover: hover) {
  .hero__figure:hover .hero__img--energy {
    opacity: 1;
    transform: scale(1);
    filter: drop-shadow(0 0 26px rgba(240, 168, 58, 0.42));
    animation: energy-breathe 3.4s ease-in-out 0.6s infinite;
  }
  .hero__figure:hover .hero__aura {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    animation: aura-pulse 3.4s ease-in-out 0.6s infinite;
  }
}

@keyframes energy-breathe {
  0%, 100% { filter: drop-shadow(0 0 26px rgba(240, 168, 58, 0.42)); }
  50%      { filter: drop-shadow(0 0 40px rgba(255, 190, 90, 0.62)); }
}
@keyframes aura-pulse {
  0%, 100% { opacity: 1;    transform: translate(-50%, -50%) scale(1); }
  50%      { opacity: 0.84; transform: translate(-50%, -50%) scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  .hero__img--energy,
  .hero__aura { transition-duration: 0.25s; }
  .hero__media.is-energized .hero__img--energy,
  .hero__media.is-energized .hero__aura,
  .hero__figure:hover .hero__img--energy,
  .hero__figure:hover .hero__aura { animation: none; }
  .hero__media.is-energized .hero__img--energy,
  .hero__figure:hover .hero__img--energy { filter: drop-shadow(0 0 26px rgba(240, 168, 58, 0.45)); }
}

/* ==========================================================================
   Marquee
   ========================================================================== */
.marquee {
  background: var(--white);
  color: var(--teal);
  overflow: hidden;
  white-space: nowrap;
  padding-block: 0.85rem;
  border-block: 1px solid rgba(35,86,82,0.12);
}
.marquee__track {
  display: inline-flex;
  width: max-content;
  animation: marquee 32s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__group {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  padding-right: 0.9em;
  font-size: clamp(0.85rem, 1.4vw, 1rem);
  font-weight: 600;
  letter-spacing: 0.02em;
}
.marquee__dot { color: var(--rose); }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; }
}

/* ==========================================================================
   About / Features
   ========================================================================== */
.about {
  background: var(--teal);
  color: var(--white);
  padding-block: var(--section-pad);
}
.about__top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  margin-bottom: clamp(3.5rem, 8vw, 6rem);
}
.about__img { overflow: hidden; border-radius: var(--radius); }
.about__img img {
  border-radius: var(--radius);
  width: 100%;
  aspect-ratio: 1115 / 743;
  object-fit: cover;
  display: block;
  transition: transform .5s var(--ease);
}
.about__img:hover img { transform: scale(1.06); }
.about__text .script {
  color: var(--beige);
  font-size: clamp(1.9rem, 3.6vw, 2.75rem);
  display: block;
}
.about__text p {
  margin-top: 1.5rem;
  max-width: 46ch;
  opacity: 0.92;
  font-size: 1.05rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1rem, 2vw, 1.75rem);
}
.feature-card__frame {
  display: block;
  overflow: hidden;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
}
.feature-card img {
  width: 100%;
  aspect-ratio: 629 / 419;
  object-fit: cover;
  display: block;
  transition: transform .5s var(--ease);
}
.feature-card:hover img { transform: scale(1.08); }
.feature-card p { font-size: 0.95rem; opacity: 0.92; }

/* ==========================================================================
   Group classes — text | photo row (same grid language as Directions)
   ========================================================================== */
.group-row {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.group-row__content h2 {
  font-size: var(--heading-size);
  color: var(--teal);
  margin-bottom: 1.1rem;
  white-space: nowrap;
}
.group-row__content p { max-width: 44ch; color: var(--ink); opacity: 0.85; }
.group-row__img { overflow: hidden; border-radius: var(--radius); }
.group-row__img img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
  transition: transform .5s var(--ease);
}
.group-row__img:hover img { transform: scale(1.06); }

/* ==========================================================================
   Contained photo / video showcase sections
   ========================================================================== */
.section-gap { padding-block: clamp(1.5rem, 3.5vw, 2.5rem); }
.video-section { background: var(--cream); }
.group-section { background: var(--beige); }

.bleed-photo, .bleed-video {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--radius);
}
.bleed-photo img {
  width: 100%;
  height: clamp(320px, 38vw, 620px);
  object-fit: cover;
  display: block;
}
.bleed-photo::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(115deg, rgba(255,255,255,.92) 0%, rgba(255,255,255,.78) 26%, rgba(255,255,255,.35) 46%, rgba(255,255,255,0) 66%);
  pointer-events: none;
}
.bleed-photo__text {
  position: absolute;
  left: 0;
  top: clamp(1.5rem, 4vw, 3rem);
  max-width: min(90%, 46ch);
}
.bleed-photo__text h2 {
  font-size: var(--heading-size);
  color: var(--ink);
  margin-bottom: 0.75rem;
  white-space: nowrap;
}
.bleed-photo__text p { color: var(--ink); opacity: 0.82; font-size: 1rem; max-width: 28ch; }

.bleed-video__text {
  position: absolute;
  left: clamp(1.5rem, 4vw, 3rem);
  right: clamp(1.5rem, 4vw, 3rem);
  top: clamp(1.5rem, 4vw, 3rem);
  max-width: min(90%, 46ch);
}

.bleed-video__el {
  width: 100%;
  height: clamp(320px, 38vw, 620px);
  object-fit: cover;
  display: block;
}
.bleed-video__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(115deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.28) 32%, rgba(0,0,0,0) 60%);
  pointer-events: none;
}
.bleed-video__text p { color: var(--white); opacity: 0.94; font-size: clamp(0.9rem, 1.1vw, 1.05rem); line-height: 1.6; max-width: 34ch; }

.media-toggle {
  position: absolute;
  right: clamp(1rem, 4vw, 2.5rem);
  bottom: clamp(1rem, 4vw, 2.5rem);
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.4);
  color: var(--white);
  padding: 0.6em 1.1em 0.6em 0.8em;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  transition: background-color .3s var(--ease);
}
.media-toggle:hover { background: rgba(255,255,255,0.28); }
.media-toggle__icon {
  width: 10px; height: 10px;
  display: inline-block;
  position: relative;
}
.media-toggle__icon::before, .media-toggle__icon::after {
  content: ""; position: absolute; top: 0; width: 3px; height: 10px; background: var(--white);
}
.media-toggle__icon::before { left: 0; }
.media-toggle__icon::after { left: 6px; }
.media-toggle[aria-pressed="true"] .media-toggle__icon::before,
.media-toggle[aria-pressed="true"] .media-toggle__icon::after {
  width: 0; height: 0; top: 1px;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 8px solid var(--white);
  background: none;
}
.media-toggle[aria-pressed="true"] .media-toggle__icon::after { left: 0; }

/* ==========================================================================
   Directions
   ========================================================================== */
.directions { padding-block: var(--section-pad); }
.dir-row {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  margin-bottom: clamp(3rem, 7vw, 5.5rem);
}
.dir-row:last-child { margin-bottom: 0; }
.dir-row--reverse .dir-row__img { order: 2; }
.dir-row--reverse .dir-row__content { order: 1; }
.dir-row__img {
  overflow: hidden;
  border-radius: var(--radius);
}
.dir-row__img img {
  width: 100%;
  aspect-ratio: 650 / 372;
  object-fit: cover;
  display: block;
  transition: transform .5s var(--ease);
}
.dir-row__img:hover img { transform: scale(1.06); }
.script--title {
  color: var(--teal);
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  margin-bottom: 1.1rem;
  white-space: nowrap;
}
.dir-row__content p { max-width: 44ch; margin-bottom: 1.75rem; color: var(--ink); opacity: 0.85; }
.dir-row__content .btn { margin-top: 1.75rem; }

.price-list__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.85rem;
  border-bottom: 1px solid rgba(35,86,82,0.28);
  font-size: 1rem;
}
.price-list__row dt { font-weight: 500; }
.price-list__row dd { margin: 0; font-weight: 700; white-space: nowrap; }

/* ==========================================================================
   Individual
   ========================================================================== */
.individual-wrap { background: var(--mauve); padding-block: var(--section-pad); }
.individual__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  gap: clamp(1rem, 2.5vw, 1.75rem);
}
.individual__panel {
  border-radius: var(--radius);
  background: var(--mauve);
  color: var(--white);
  padding: clamp(2.5rem, 5vw, 4.5rem) clamp(1.5rem, 5vw, 4rem) clamp(2.5rem, 5vw, 4.5rem) 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.script--sub {
  color: var(--beige);
  font-size: clamp(1.6rem, 2.8vw, 2.1rem);
  margin-top: 2.25rem;
  margin-bottom: 1rem;
}
.check-list li {
  position: relative;
  padding-left: 1.4em;
  margin-bottom: 0.6em;
  opacity: 0.94;
  font-size: 0.95rem;
}
.check-list li::before {
  content: "";
  position: absolute; left: 0; top: 0.55em;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--beige);
}
.individual__media { position: relative; min-height: 320px; border-radius: var(--radius); overflow: hidden; }
.individual__media img { width: 100%; height: 100%; object-fit: cover; }
/* Same top padding and side gutter as .individual__panel, so the caption's
   first line sits on the grid line as the section heading opposite it. */
.individual__media-caption {
  position: absolute; left: 0; right: 0; top: 0;
  padding: clamp(2.5rem, 5vw, 4.5rem) clamp(1.5rem, 5vw, 4rem) 0;
}
.individual__media-caption p {
  max-width: 34ch;
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
}

/* ==========================================================================
   Philosophy
   ========================================================================== */
.philosophy { background: var(--cream); padding-block: var(--section-pad); }
.philosophy__quote {
  text-align: left;
  font-size: clamp(1.5rem, 2.8vw, 2.1rem);
  font-weight: 600;
  line-height: 1.5;
  max-width: 34ch;
  margin-bottom: var(--heading-gap);
}
.script--quote {
  color: var(--teal);
  font-weight: 400;
  font-size: 1.35em;
  display: inline-block;
  margin-block: 0.1em;
  margin-left: clamp(1rem, 4vw, 3rem);
}
.philosophy__grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
}
.philosophy__col { display: flex; flex-direction: column; gap: 1.75rem; max-width: 34ch; }
.philosophy__col:last-child { margin-left: auto; }
.philosophy__col p { opacity: 0.85; }
.philosophy__img {
  position: relative;
  width: clamp(300px, 30vw, 460px);
  aspect-ratio: 1 / 1;
}
.philosophy__ellipse {
  position: absolute;
  left: 12%;
  top: 9%;
  width: 76%;
  aspect-ratio: 1 / 1;
}
/* Only the figure grows — anchored at the bottom so her head rises clear of
   the circle. height:auto keeps her proportions. */
.philosophy__cutout {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 145%;
  max-width: none; /* beats the global img{max-width:100%} reset */
  height: auto;
  transform: translateX(-50%);
  pointer-events: none; /* its transparent margins overlap the text columns */
}

/* ==========================================================================
   Teachers
   ========================================================================== */
.teachers { background: var(--teal); color: var(--white); padding-block: var(--section-pad); }
.teachers__intro {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: end;
  margin-bottom: var(--heading-gap);
}
.teachers__title {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  line-height: 1.35;
  max-width: 20ch;
}
.teachers__intro p { opacity: 0.85; max-width: 26ch; font-size: 0.95rem; }

.teacher-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1rem, 2vw, 1.75rem);
}
.teacher-card__frame {
  display: block;
  overflow: hidden;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
}
.teacher-card img {
  width: 100%;
  aspect-ratio: 627/417;
  object-fit: cover;
  display: block;
  transition: transform .5s var(--ease);
}
.teacher-card:hover img { transform: scale(1.08); }
.teacher-card__name {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255,255,255,0.4);
}
.teacher-card__arrow { display: inline-block; transition: transform .35s var(--ease); }
.teacher-card__name:hover .teacher-card__arrow,
.teacher-card__name:focus-visible .teacher-card__arrow { transform: rotate(90deg); }

.teacher-card__exp {
  display: block;
  font-size: 0.85rem;
  color: var(--beige);
  opacity: 0;
  max-height: 0;
  transform: translateY(-4px);
  transition: opacity .35s var(--ease), transform .35s var(--ease), max-height .35s var(--ease), margin-top .35s var(--ease);
  margin-top: 0;
}
.teacher-card__name:hover ~ .teacher-card__exp,
.teacher-card__name:focus-visible ~ .teacher-card__exp {
  opacity: 1;
  max-height: 2em;
  transform: translateY(0);
  margin-top: 0.6rem;
}
/* A touch screen has nothing to hover with, so the reveal would hide the
   speciality and experience for good. Show them outright instead. */
@media (hover: none) {
  .teacher-card__exp {
    opacity: 1;
    max-height: 2em;
    transform: none;
    margin-top: 0.6rem;
  }
}

/* ==========================================================================
   Contact
   ========================================================================== */
.contact {
  background: #DED8D1;
  padding-top: var(--section-pad);
  padding-bottom: clamp(1.5rem, 3vw, 2.5rem);
}
.contact__grid {
  display: grid;
  grid-template-columns: 1fr minmax(0, 1.15fr);
  gap: clamp(2.5rem, 6vw, 5rem);
}
.contact__form-wrap h2 { margin-bottom: var(--heading-gap); }
.contact__form-wrap .script--title { color: var(--teal); font-size: clamp(1.9rem, 3.4vw, 2.6rem); }

.form { display: flex; flex-direction: column; gap: 1rem; max-width: 520px; }
.form__row input {
  width: 100%;
  padding: 1.1em 1.2em;
  border: none;
  border-radius: 8px;
  background: var(--white);
  font-size: 0.95rem;
  transition: box-shadow .25s var(--ease);
}
.form__row input::placeholder { color: #9a9188; }
.form__row input:focus-visible { box-shadow: 0 0 0 2px var(--teal); outline: none; }

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.7em;
  font-size: 0.85rem;
  opacity: 0.85;
  cursor: pointer;
  line-height: 1.5;
}
.checkbox input {
  margin-top: 0.2em;
  width: 16px; height: 16px;
  accent-color: var(--teal);
  flex-shrink: 0;
}
.form .btn { margin-top: 0.5rem; }
.form__status {
  min-height: 1.5em;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--teal);
}

.contact__info { position: relative; display: flex; flex-direction: column; }
.contact__info-text { position: relative; z-index: 1; display: flex; flex-direction: column; }
.contact__info h3 { font-size: var(--heading-size); margin-bottom: 1.25rem; white-space: nowrap; }
.contact__info a {
  display: block;
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
  width: fit-content;
  transition: color .25s var(--ease);
}
.contact__info a:hover { color: var(--teal); }
.contact__info-text > p { opacity: 0.85; margin-bottom: 1.5rem; }

/* The figure sits behind the Контакты block as a backdrop. object-fit:contain
   guarantees girl2 keeps her own proportions whatever the column size. */
.contact__circle {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: min(115%, 680px);
  max-width: none;
  z-index: 0;
  pointer-events: none;
}
.contact__ellipse {
  position: absolute;
  width: 54%;
  aspect-ratio: 1 / 1;
  right: 8%;
  top: 50%;
  transform: translateY(-50%);
}
.contact__cutout {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;      /* keeps girl2's own proportions at any column size */
  object-position: center right;
}

/* ==========================================================================
   Sign-up popup
   ========================================================================== */
.modal[hidden] { display: none; }
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: clamp(0.75rem, 3vw, 2rem);
}
.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 65, 62, 0.55);
  opacity: 0;
  transition: opacity .3s var(--ease);
}
.modal__dialog {
  position: relative;
  width: min(100%, 520px);
  max-height: calc(100vh - 1.5rem);
  max-height: calc(100dvh - 1.5rem); /* honours mobile browser chrome where supported */
  overflow-y: auto;
  background: #DED8D1;           /* same ground as the contact form below */
  border-radius: var(--radius);
  padding: clamp(1.75rem, 4vw, 2.75rem);
  opacity: 0;
  transform: translateY(14px) scale(0.985);
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.modal.is-open .modal__backdrop { opacity: 1; }
.modal.is-open .modal__dialog { opacity: 1; transform: none; }

.modal__title { margin-bottom: clamp(1.25rem, 3vw, 1.75rem); white-space: normal; }
.modal__title .script--title { white-space: normal; }

.modal__close {
  position: absolute;
  top: clamp(0.75rem, 2vw, 1.1rem);
  right: clamp(0.75rem, 2vw, 1.1rem);
  width: 40px; height: 40px;
  display: grid;
  place-items: center;
  background: none;
  border: none;
  border-radius: 50%;
  transition: background-color .25s var(--ease);
}
.modal__close:hover { background: rgba(35, 86, 82, 0.1); }
.modal__close span {
  position: absolute;
  width: 17px; height: 1.5px;
  background: var(--ink);
}
.modal__close span:first-child { transform: rotate(45deg); }
.modal__close span:last-child { transform: rotate(-45deg); }

body.has-modal { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .modal__backdrop, .modal__dialog { transition-duration: .01ms; }
  .modal__dialog { transform: none; }
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { background: var(--mauve); color: var(--white); padding-block: 2.5rem; }
.site-footer__inner {
  display: grid;
  grid-template-columns: 1fr repeat(3, auto);
  gap: 1.5rem 2.5rem;
  align-items: start;
  font-size: 0.9rem;
}
.site-footer__logo { font-weight: 800; font-size: 1.05rem; }
.site-footer__col { display: flex; flex-direction: column; }
.site-footer__col a, .site-footer__col p { display: block; margin-bottom: 0.35rem; opacity: 0.92; }
.site-footer__col a { width: fit-content; }
.site-footer__col a:hover { text-decoration: underline; }
.site-footer__muted { opacity: 0.65 !important; }

/* ==========================================================================
   Scroll reveal
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .hero__inner {
    grid-template-columns: 1fr;
    grid-template-areas: "text" "media" "cta";
    text-align: left;
  }
  .hero__text, .hero__cta { align-self: auto; }
  .hero__script { width: auto; max-width: none; }
  .hero__media { width: 100%; max-width: 420px; margin-inline: auto; }
  .hero__cta { justify-self: start; }
  .about__top { grid-template-columns: 1fr; }
  .about__img { order: -1; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .dir-row, .dir-row--reverse { grid-template-columns: 1fr; }
  .dir-row__img, .dir-row--reverse .dir-row__img { order: -1; }
  .dir-row--reverse .dir-row__content { order: 2; }
  .group-row { grid-template-columns: 1fr; }
  .group-row__img { order: -1; }
  .individual__grid { grid-template-columns: 1fr; }
  .individual__panel, .individual__media { min-width: 0; }
  .individual__panel { padding-left: clamp(1.5rem, 5vw, 4rem); }
  .individual__media { min-height: 380px; }
  .philosophy__grid { grid-template-columns: 1fr; text-align: center; }
  .philosophy__col { max-width: 52ch; margin-inline: auto; }
  .philosophy__col:last-child { margin-left: auto; }
  .philosophy__img { order: -1; margin-inline: auto; }
  .teacher-grid { grid-template-columns: repeat(2, 1fr); }
  .teachers__intro { grid-template-columns: 1fr; }
  .contact__grid { grid-template-columns: 1fr; }
  .contact__info { min-height: 420px; }
  .contact__circle { width: min(100%, 360px); }
  .contact__ellipse { width: 66%; right: 2%; bottom: 6%; }
  .site-footer__inner { grid-template-columns: 1fr 1fr; }

  /* Overlay-text-on-photo gets too cramped below this breakpoint (long
     paragraphs would cover most of the image) — stack text below instead.
     The outer wrapper stops clipping so the photo/video becomes its own
     fully rounded card, matching every other photo on the site. */
  .bleed-photo, .bleed-video { display: flex; flex-direction: column; border-radius: 0; overflow: visible; }
  .bleed-photo img, .bleed-video__el { height: clamp(240px, 68vw, 360px); order: 1; border-radius: var(--radius); }
  .bleed-photo::before { display: none; }
  .bleed-photo__text, .bleed-video__text {
    position: static;
    order: 2;
    max-width: 100%;
    padding: 1.5rem clamp(1.25rem, 5vw, 2rem) 0;
  }
  .bleed-video__scrim { display: none; }
  .bleed-video__text p { color: var(--ink); opacity: 0.82; }
  .media-toggle { top: clamp(1rem, 4vw, 1.5rem); bottom: auto; }
}

@media (max-width: 860px) {
  .main-nav {
    position: fixed;
    inset: 0;
    top: 68px;
    background: var(--beige);
    padding: 2rem clamp(1.25rem, 5vw, 3rem);
    transform: translateX(100%);
    transition: transform .4s var(--ease);
    flex: none;
  }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav__list { flex-direction: column; gap: 1.5rem; }
  .main-nav__list a { font-size: 1.25rem; }
  .nav-toggle { display: flex; }
  .header-phone { display: none; }
  .site-header__inner { justify-content: space-between; }
}

@media (max-width: 480px) {
  /* Longest section title + the mauve panel's own padding leaves too
     little room to stay on one line at very narrow widths — let it wrap
     here rather than force the grid track wider than its container. */
  .individual__panel .section-title { white-space: normal; }
}

@media (max-width: 640px) {
  .feature-grid { grid-template-columns: 1fr; }
  .teacher-grid { grid-template-columns: 1fr; max-width: 360px; margin-inline: auto; }
  .site-footer__inner { grid-template-columns: 1fr; }
  .hero__title { font-size: clamp(2.1rem, 11.5vw, 3.4rem); }
  .media-toggle .media-toggle__label { display: none; }
}
