/* ============================================================
   Академия Наталии Эдис — design system
   Эстетика: тёплый «арт-журнал», управляемый хаос на жёсткой сетке
   ============================================================ */

@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-Regular.otf") format("opentype"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-RegularItalic.otf") format("opentype"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-SemiBold.otf") format("opentype"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-Bold.otf") format("opentype"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-ExtraBold.otf") format("opentype"); font-weight: 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Petrov Sans"; src: url("fonts/petrov/PetrovSans-Trial-Black.otf") format("opentype"); font-weight: 900; font-style: normal; font-display: swap; }

:root {
  /* neutrals */
  --cream: #FFFFFF;
  --cream-2: #EEF1F8;
  --sunken: #F4F6FC;
  --paper: #FFFFFF;
  --ink: #22202B;
  --ink-soft: #4A4654;
  --muted: #6B6675;
  --line: #E7E0D4;

  /* direction accents */
  --c-paint:  #C75B39;  --c-paint-d:  #8E3D24;  --c-paint-t:  #F6E7E0;
  --c-art:    #34538C;  --c-art-d:    #243B66;  --c-art-t:    #E2E8F2;
  --c-craft:  #6B8E4E;  --c-craft-d:  #4C6837;  --c-craft-t:  #EAF0E2;
  --c-food:   #E0A02F;  --c-food-d:   #9C6D16;  --c-food-t:   #FAF0DC;
  --c-style:  #B5547E;  --c-style-d:  #823A59;  --c-style-t:  #F6E5EC;
  --c-active: #2E8B8B;  --c-active-d: #1F6363;  --c-active-t: #DFF0F0;

  /* themable accent (default = ink) */
  --accent: var(--ink);
  --accent-d: #000;
  --accent-t: var(--cream-2);

  --maxw: 1280px;
  --header-h: 78px;
  --pad: clamp(18px, 4vw, 56px);
  --radius: 22px;
  --radius-s: 14px;

  --font-display: "Petrov Sans", system-ui, sans-serif;
  --font-body: "Petrov Sans", system-ui, sans-serif;

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

/* per-page theming */
body.t-paint  { --accent: var(--c-paint);  --accent-d: var(--c-paint-d);  --accent-t: var(--c-paint-t); }
body.t-art    { --accent: var(--c-art);    --accent-d: var(--c-art-d);    --accent-t: var(--c-art-t); }
body.t-craft  { --accent: var(--c-craft);  --accent-d: var(--c-craft-d);  --accent-t: var(--c-craft-t); }
body.t-food   { --accent: var(--c-food);   --accent-d: var(--c-food-d);   --accent-t: var(--c-food-t); }
body.t-style  { --accent: var(--c-style);  --accent-d: var(--c-style-d);  --accent-t: var(--c-style-t); }
body.t-active { --accent: var(--c-active); --accent-d: var(--c-active-d); --accent-t: var(--c-active-t); }

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

html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.65;
  font-weight: 400;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

/* interactive blue dot field (canvas, injected by JS) sits behind all content */
#dotgrid { position: fixed; inset: 0; z-index: 0; pointer-events: none; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; }

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.04; letter-spacing: -.01em; }

.container { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--pad); position: relative; z-index: 1; }
.section { padding-block: clamp(64px, 10vw, 140px); position: relative; z-index: 1; }

/* ---------- eyebrow / sticker tags ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent-d);
}
.eyebrow::before { content: ""; width: 26px; height: 2px; background: var(--accent); display: inline-block; }

.sticker {
  display: inline-block; font-weight: 700; font-size: 13px;
  padding: 7px 14px; border-radius: 999px;
  background: var(--accent); color: #fff;
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(-3deg);
}
.sticker--ghost { background: var(--paper); color: var(--ink); border: 1.5px solid var(--ink); box-shadow: 3px 3px 0 var(--accent); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 16px;
  padding: 15px 26px; border-radius: 999px;
  background: var(--ink); color: var(--cream);
  transition: transform .35s var(--ease), background .3s, box-shadow .35s var(--ease);
  will-change: transform;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(34,32,43,.22); }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-d); }
.btn--ghost { background: transparent; color: var(--ink); border: 1.6px solid var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--cream); }
.btn .arr { transition: transform .35s var(--ease); }
.btn:hover .arr { transform: translateX(5px); }

/* ---------- header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; padding: 14px var(--pad);
  background: color-mix(in oklab, var(--cream) 82%, transparent);
  backdrop-filter: blur(12px) saturate(1.2);
  border-bottom: 1px solid var(--line);
}
.logo { display: inline-flex; align-items: center; line-height: 1; transition: transform .35s var(--ease); }
.logo:hover { transform: scale(1.03) rotate(-1deg); }
.logo img { height: 48px; width: auto; display: block; }
.logo b { color: var(--accent); }
.nav { display: flex; align-items: center; gap: clamp(10px, 2vw, 28px); }
.nav-links a { font-weight: 600; font-size: 15.5px; color: var(--ink-soft); position: relative; padding: 6px 2px; }
.nav-links a::after { content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: var(--accent); transition: width .3s var(--ease); }
.nav-links a:hover::after, .nav-links a[aria-current]::after { width: 100%; }
.nav-links a[aria-current] { color: var(--ink); }
.nav .btn { padding: 11px 20px; font-size: 15px; }
.nav-links { display: flex; align-items: center; gap: clamp(10px,2vw,28px); }
.burger { display: none; flex-direction: column; gap: 5px; width: 48px; height: 48px; align-items: center; justify-content: center; border: 1.6px solid var(--ink); border-radius: 50%; z-index: 71; transition: background .25s; }
.burger span { display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .3s var(--ease), opacity .25s; }
.burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu { position: fixed; inset: 0; z-index: 60; background: var(--cream); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .3s var(--ease), visibility .3s; }
.mobile-menu.is-open { opacity: 1; visibility: visible; }
.mobile-menu__inner { display: flex; flex-direction: column; align-items: center; gap: 20px; text-align: center; padding: 24px; }
.mobile-menu a:not(.btn) { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px, 8vw, 40px); color: var(--ink); }
.mobile-menu a[aria-current] { color: var(--accent); }
.mobile-menu .btn { margin-top: 12px; font-size: 18px; justify-content: center; }
body.menu-open { overflow: hidden; }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav > .btn { display: none; }
  .burger { display: flex; }
  body.menu-open .header { z-index: 70; background: transparent; border-color: transparent; }
}

/* ---------- hero ---------- */
.hero { position: relative; padding-top: clamp(40px, 7vw, 90px); padding-bottom: clamp(40px, 6vw, 80px); overflow: clip; }
.hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(24px, 4vw, 60px); align-items: center; }
@media (max-width: 900px) { .hero__grid { grid-template-columns: 1fr; } }

.hero h1 { font-size: clamp(44px, 8.5vw, 116px); }
.hero h1 .it { font-style: italic; font-weight: 500; }
.hero h1 .hl { color: var(--accent); position: relative; white-space: nowrap; }
.hero__lead { font-size: clamp(18px, 2.2vw, 22px); color: var(--ink-soft); max-width: 30ch; margin-top: 26px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }

/* hero: 6 кружков-направлений — свободно плавают, наведение увеличивает, клик открывает.
   Внешний .dcircle ПЛАВАЕТ (translate-анимация), внутренний .dcircle__face — сам круг
   и масштаб при наведении (чтобы два transform не конфликтовали). */
.hero__art { display: flex; flex-wrap: wrap; align-items: center; align-content: center; justify-content: center;
  gap: clamp(8px, 1.1vw, 16px); }
.dcircle { flex: none; display: grid; place-items: center; will-change: transform; }
.dcircle__face {
  width: clamp(118px, 13vw, 166px); aspect-ratio: 1; border-radius: 50%;
  display: grid; place-items: center; text-align: center; padding: 12px; color: #fff;
  box-shadow: 0 14px 30px rgba(34,32,43,.16); border: 4px solid rgba(255,255,255,.5);
  transition: transform .4s cubic-bezier(.34,1.5,.5,1), box-shadow .4s var(--ease);
  animation: dcircle-pop .7s cubic-bezier(.34,1.56,.64,1) backwards;
}
.dcircle__face span { font-family: var(--font-display); font-weight: 700; line-height: 1.08;
  font-size: clamp(14px, 1.05vw, 18px); letter-spacing: .01em; }
.dcircle:hover, .dcircle:focus-visible { z-index: 5; outline: none; }
.dcircle:hover .dcircle__face, .dcircle:focus-visible .dcircle__face {
  transform: scale(1.14);
  box-shadow: 0 26px 56px color-mix(in oklab, var(--cc) 50%, transparent);
}
.dcircle.c-paint  { --cc: var(--c-paint); }   .dcircle.c-paint  .dcircle__face { background: var(--c-paint); }
.dcircle.c-art    { --cc: var(--c-art); }     .dcircle.c-art    .dcircle__face { background: var(--c-art); }
.dcircle.c-craft  { --cc: var(--c-craft); }   .dcircle.c-craft  .dcircle__face { background: var(--c-craft); }
.dcircle.c-food   { --cc: var(--c-food); }    .dcircle.c-food   .dcircle__face { background: var(--c-food); }
.dcircle.c-style  { --cc: var(--c-style); }   .dcircle.c-style  .dcircle__face { background: var(--c-style); }
.dcircle.c-active { --cc: var(--c-active); }  .dcircle.c-active .dcircle__face { background: var(--c-active); }

/* разные размеры (длинные названия — крупнее, заодно органичнее) */
.dcircle:nth-child(2) .dcircle__face,
.dcircle:nth-child(5) .dcircle__face,
.dcircle:nth-child(6) .dcircle__face { width: clamp(130px, 14.5vw, 184px); }
.dcircle:nth-child(3) .dcircle__face { width: clamp(106px, 11.5vw, 146px); }

/* разные вертикальные смещения — «вразнобой» */
.dcircle:nth-child(1) { margin-top: clamp(6px, 1vw, 14px); }
.dcircle:nth-child(2) { margin-top: clamp(30px, 4.5vw, 60px); }
.dcircle:nth-child(3) { margin-top: 0; }
.dcircle:nth-child(4) { margin-top: clamp(22px, 3.5vw, 46px); }
.dcircle:nth-child(5) { margin-top: clamp(4px, .8vw, 12px); }
.dcircle:nth-child(6) { margin-top: clamp(26px, 4vw, 52px); }

/* плавание: у каждого свой путь, скорость и фаза → хаотично */
.dcircle:nth-child(1) { animation: fl1  8.5s ease-in-out -1.0s infinite; }
.dcircle:nth-child(2) { animation: fl2 11.0s ease-in-out -4.0s infinite; }
.dcircle:nth-child(3) { animation: fl3  9.5s ease-in-out -2.5s infinite; }
.dcircle:nth-child(4) { animation: fl4 12.0s ease-in-out -6.0s infinite; }
.dcircle:nth-child(5) { animation: fl5 10.0s ease-in-out -0.5s infinite; }
.dcircle:nth-child(6) { animation: fl6  9.0s ease-in-out -3.5s infinite; }
@keyframes fl1 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(8px,-15px) } }
@keyframes fl2 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(-11px,-9px) } }
@keyframes fl3 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(7px,13px) } }
@keyframes fl4 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(-8px,14px) } }
@keyframes fl5 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(13px,7px) } }
@keyframes fl6 { 0%,100% { transform: translate(0,0) }      50% { transform: translate(-12px,-12px) } }
@keyframes dcircle-pop { from { opacity: 0; transform: scale(.5); } to { opacity: 1; transform: scale(1); } }

/* word-by-word hero reveal helpers */
.line { display: block; overflow: hidden; }
.word { display: inline-block; }

/* ---------- marquee ---------- */
.marquee { overflow: hidden; border-block: 2px solid var(--ink); background: var(--accent); color: #fff; }
.marquee__track { display: inline-flex; gap: 40px; white-space: nowrap; padding: 14px 20px; will-change: transform; }
.marquee__track span { font-family: var(--font-display); font-style: italic; font-size: clamp(22px, 3vw, 38px); font-weight: 600; }
.marquee__track span::after { content: "✦"; margin-left: 40px; font-style: normal; opacity: .7; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat { padding: 22px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-s); }
.stat:nth-child(odd) { transform: rotate(-1.2deg); }
.stat:nth-child(even) { transform: rotate(1.2deg); }
.stat .num { font-family: var(--font-display); font-weight: 800; font-size: clamp(34px, 4.4vw, 56px); color: var(--accent); line-height: 1; }
.stat .lbl { margin-top: 8px; font-size: 15px; color: var(--muted); font-weight: 600; }

/* ---------- section heading ---------- */
.shead { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 44px; flex-wrap: wrap; }
.shead h2 { font-size: clamp(34px, 5.5vw, 72px); }
.shead p { color: var(--muted); max-width: 42ch; }

/* ---------- directions: horizontal pinned track ---------- */
.htrack { position: relative; }
.htrack__viewport { overflow: hidden; perspective: 1500px; }
.htrack__row { display: flex; align-items: center; gap: 28px; padding-inline: var(--pad); will-change: transform; }
.dcard {
  flex: 0 0 clamp(280px, 34vw, 420px);
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px; position: relative; overflow: hidden;
  --a: var(--ink);
  transform-style: preserve-3d;
  transition: box-shadow .5s var(--ease);
}
.dcard__desc { overflow: hidden; max-height: 0; opacity: 0; will-change: max-height; }
.dcard__desc p { min-height: 0; margin-top: 14px; }
.dcard::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 7px; background: var(--a); }
.dcard__num { font-family: var(--font-display); font-style: italic; font-size: 20px; color: var(--a); opacity: .65; }
.dcard h3 { font-size: clamp(28px, 3vw, 40px); margin-top: 10px; color: var(--a); }
.dcard p { color: var(--ink-soft); margin-top: 12px; min-height: 3.2em; }
.dcard__go { display: inline-flex; align-items: center; gap: 8px; margin-top: 22px; font-weight: 700; color: var(--a); }
.dcard__go .arr { transition: transform .35s var(--ease); }
.dcard:hover { transform: translateY(-8px) rotate(-1deg); box-shadow: 0 30px 60px rgba(34,32,43,.16); }
.dcard:hover .dcard__go .arr { transform: translateX(6px); }
.dcard__deco { position: absolute; right: -30px; bottom: -30px; width: 150px; height: 150px; border-radius: 50%; background: var(--a); opacity: .1; }
.dcard.c-paint{--a:var(--c-paint)} .dcard.c-art{--a:var(--c-art)} .dcard.c-craft{--a:var(--c-craft)}
.dcard.c-food{--a:var(--c-food)} .dcard.c-style{--a:var(--c-style)} .dcard.c-active{--a:var(--c-active)}
.htrack__hint { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; font-weight: 600; margin-top: 20px; padding-inline: var(--pad); }
@media (max-width: 760px) {
  .htrack__viewport { overflow-x: auto; }
  .dcard { transform: none !important; }
  .dcard__desc { max-height: none !important; opacity: 1 !important; }
}

/* simple drag-scroll row (direction pages) */
.hscroll { display: flex; gap: 22px; overflow-x: auto; padding: 8px 4px 24px; scroll-snap-type: x mandatory; cursor: grab; scrollbar-width: thin; }
.hscroll.is-drag { cursor: grabbing; }
.hscroll > * { scroll-snap-align: start; }
.ccard {
  flex: 0 0 clamp(260px, 30vw, 340px); background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-s); padding: 24px; position: relative;
}
.ccard h4 { font-size: 23px; }
.ccard .chip { margin-top: 12px; }
.ccard p { color: var(--ink-soft); margin-top: 12px; font-size: 16px; }

.chip { display: inline-block; font-size: 14px; font-weight: 700; padding: 6px 13px; border-radius: 999px; background: var(--accent-t); color: var(--accent-d); }

.row-ctrl { display: inline-flex; gap: 10px; }
.row-ctrl button { width: 46px; height: 46px; border-radius: 50%; border: 1.6px solid var(--ink); display: grid; place-items: center; transition: background .25s, color .25s, transform .25s var(--ease); }
.row-ctrl button:hover { background: var(--accent); color: #fff; border-color: var(--accent); transform: translateY(-2px); }

/* ---------- direction hero band ---------- */
.dhero { background: var(--accent-t); border-bottom: 2px solid var(--ink); position: relative; overflow: clip; }
.dhero .container { padding-block: clamp(48px, 8vw, 110px); }
.crumb { font-weight: 600; font-size: 14px; color: var(--accent-d); }
.crumb a { opacity: .7; } .crumb a:hover { opacity: 1; }
.dhero h1 { font-size: clamp(52px, 11vw, 150px); color: var(--accent-d); margin: 14px 0 18px; }
.dhero p { font-size: clamp(18px, 2.2vw, 23px); color: var(--ink-soft); max-width: 46ch; }
.dhero__sticker { position: absolute; right: var(--pad); top: 30%; }

/* ---------- teacher block (multi-course) ---------- */
.teacher {
  display: grid; grid-template-columns: 320px 1fr; gap: clamp(24px, 4vw, 60px);
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(22px, 3vw, 40px); margin-bottom: 30px; position: relative;
}
@media (max-width: 820px) { .teacher { grid-template-columns: 1fr; } }
.teacher__side { position: sticky; top: 96px; align-self: start; }
@media (max-width: 820px) { .teacher__side { position: static; } }
.teacher__photo { width: 150px; height: 150px; border-radius: 50%; object-fit: cover; border: 5px solid var(--paper); box-shadow: 0 14px 30px rgba(34,32,43,.16); background: var(--accent-t); transform: rotate(-3deg); }
.teacher__mono { display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 52px; color: #fff; background: var(--accent); }
.teacher__name { font-size: clamp(26px, 2.6vw, 34px); margin: 18px 0 14px; }
.teacher__regalia { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.teacher__regalia li { position: relative; padding-left: 20px; color: var(--ink-soft); font-size: 16px; }
.teacher__regalia li::before { content: ""; position: absolute; left: 0; top: 11px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }

.courses { position: relative; padding-left: 26px; }
.courses::before { content: ""; position: absolute; left: 6px; top: 6px; bottom: 6px; width: 3px; background: var(--accent); border-radius: 3px; opacity: .5; }
.courses__h { font-family: var(--font-body); font-weight: 800; text-transform: uppercase; letter-spacing: .12em; font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.course {
  position: relative; background: var(--sunken); border: 1px solid var(--line); border-radius: var(--radius-s);
  padding: 20px 22px; margin-bottom: 14px;
  transition: transform .4s var(--ease), border-color .3s, box-shadow .4s var(--ease);
}
.course::before { content: ""; position: absolute; left: -26px; top: 26px; width: 16px; height: 3px; background: var(--accent); }
.course:hover { transform: translateX(8px); border-color: var(--accent); box-shadow: -6px 10px 26px rgba(34,32,43,.10); }
.course__top { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.course h5 { font-family: var(--font-display); font-weight: 700; font-size: 22px; }
.course__time { font-weight: 700; font-size: 14px; color: var(--accent-d); white-space: nowrap; }
.course p { color: var(--ink-soft); font-size: 15.5px; margin-top: 8px; }
.course .mini { margin-top: 14px; padding: 9px 16px; font-size: 14px; border-radius: 999px; background: var(--accent); color: #fff; font-weight: 700; display: inline-flex; }
.course .mini:hover { background: var(--accent-d); }

/* ---------- CTA band ---------- */
.cta { background: var(--accent); color: #fff; border-radius: var(--radius); padding: clamp(34px, 5vw, 64px); text-align: center; position: relative; overflow: hidden; }
.cta h2 { font-size: clamp(30px, 4.6vw, 58px); }
.cta .btn { margin-top: 24px; background: #fff; color: var(--accent-d); }
.cta .btn:hover { background: var(--ink); color: #fff; }
.cta__blob { position: absolute; border-radius: 50%; background: rgba(255,255,255,.14); }

/* tiles */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 760px) { .tiles { grid-template-columns: 1fr; } }
.tile { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 28px; }
.tile .ic { width: 46px; height: 46px; border-radius: 12px; background: var(--accent-t); color: var(--accent-d); display: grid; place-items: center; font-size: 22px; margin-bottom: 16px; }
.tile h4 { font-family: var(--font-body); font-weight: 800; font-size: 19px; }
.tile p { color: var(--muted); margin-top: 8px; font-size: 16px; }

/* locations / chips strip */
.chips-wrap { display: flex; flex-wrap: wrap; gap: 12px; }
.chips-wrap .chip { background: var(--paper); border: 1px solid var(--line); color: var(--ink); }

/* ---------- legal pages (политика / согласия) ---------- */
.legal { max-width: 840px; margin: 0 auto; padding: clamp(36px, 6vw, 80px) var(--pad) clamp(48px, 7vw, 96px); position: relative; z-index: 1; }
.legal .crumb { margin-bottom: 18px; }
.legal h1 { font-size: clamp(28px, 5vw, 50px); line-height: 1.08; margin-bottom: 10px; }
.legal__date { color: var(--muted); font-weight: 600; margin-bottom: 32px; }
.legal h2 { font-size: clamp(21px, 2.6vw, 29px); margin: 38px 0 14px; }
.legal h3 { font-size: 19px; margin: 24px 0 10px; }
.legal p { margin-bottom: 14px; line-height: 1.72; color: var(--ink-soft); }
.legal a { color: var(--c-art); text-decoration: underline; text-underline-offset: 2px; }
.legal a:hover { color: var(--c-art-d); }
.legal ul, .legal ol { margin: 0 0 16px 22px; }
.legal li { margin-bottom: 8px; line-height: 1.65; color: var(--ink-soft); }
.legal table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 15px; }
.legal td, .legal th { border: 1px solid var(--line); padding: 10px 14px; text-align: left; vertical-align: top; color: var(--ink-soft); }
.legal strong { color: var(--ink); font-weight: 700; }

/* ---------- cookie banner ---------- */
.cookie { position: fixed; left: clamp(12px, 3vw, 28px); right: clamp(12px, 3vw, 28px); bottom: clamp(12px, 3vw, 28px); z-index: 100; max-width: 560px; margin-inline: auto; background: var(--ink); color: #e9e4da; border-radius: 22px; padding: 22px 24px; box-shadow: 0 24px 60px rgba(20,18,28,.4); display: flex; align-items: center; gap: 18px; flex-wrap: wrap; transform: translateY(140%); opacity: 0; transition: transform .5s var(--ease), opacity .4s; }
.cookie.is-shown { transform: translateY(0); opacity: 1; }
body.menu-open .cookie { opacity: 0 !important; visibility: hidden; pointer-events: none; transform: translateY(140%); }
.cookie__text { flex: 1 1 240px; font-size: 14.5px; line-height: 1.55; }
.cookie__text a { color: #fff; text-decoration: underline; }
.cookie__btn { flex: none; padding: 12px 26px; border-radius: 999px; background: #fff; color: var(--ink); font-weight: 700; font-size: 15px; transition: transform .25s var(--ease), background .2s; }
.cookie__btn:hover { transform: translateY(-2px); background: var(--cream-2); }

/* ---------- footer ---------- */
.footer { background: var(--ink); color: #d8d3c8; margin-top: 60px; position: relative; z-index: 1; }
.footer .container { padding-block: 56px; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 30px; }
@media (max-width: 760px) { .footer .container { grid-template-columns: 1fr; } }
.footer h3 { font-family: var(--font-display); color: var(--cream); font-size: 30px; }
.footer a { color: #d8d3c8; } .footer a:hover { color: #fff; }
.footer .col h5 { text-transform: uppercase; letter-spacing: .12em; font-size: 12px; color: #908a7e; margin-bottom: 14px; }
.footer .col p { margin-bottom: 8px; font-size: 16px; }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.12); font-size: 13px; color: #908a7e; }
.footer__bottom .container { padding-block: 18px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ============================================================
   FULLSCREEN STAGE — homepage directions (diagonal flythrough)
   ============================================================ */
.dirstage { position: relative; }
.dirstage__intro { padding-top: clamp(48px, 8vw, 120px); padding-bottom: 4px; }
.dirstage__intro h2 { font-size: clamp(34px, 5.5vw, 72px); }
.dirstage__intro p { color: var(--muted); max-width: 44ch; margin-top: 10px; }
.dirstage__pin { height: 100vh; position: relative; overflow: hidden; }

.dpanel {
  position: absolute; top: calc(var(--header-h) + 8px); right: clamp(12px, 3vw, 48px); bottom: clamp(16px, 3vh, 40px); left: clamp(12px, 3vw, 48px);
  border-radius: 34px; background: var(--at); border: 1px solid var(--line); overflow: hidden;
  display: flex; align-items: center; padding: clamp(28px, 7vw, 100px);
  will-change: transform, opacity; box-shadow: 0 50px 110px rgba(34,32,43,.14);
}
.dpanel::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 12px; background: var(--a); }
.dpanel__inner { position: relative; z-index: 2; max-width: 820px; }
.dpanel__num { font-family: var(--font-display); font-style: italic; font-weight: 600; font-size: clamp(20px, 2vw, 30px); color: var(--a); opacity: .7; }
.dpanel h3 { font-size: clamp(46px, 9.5vw, 140px); color: var(--a); line-height: .96; margin: 4px 0 20px; }
.dpanel p { font-size: clamp(18px, 2.5vw, 30px); color: var(--ink-soft); max-width: 22ch; }
.dpanel__go { display: inline-flex; align-items: center; gap: 12px; margin-top: clamp(22px, 3.5vw, 46px); font-weight: 700; font-size: clamp(17px, 1.7vw, 23px); color: #fff; background: var(--a); padding: 16px 32px; border-radius: 999px; transition: transform .35s var(--ease); }
.dpanel__go .arr { transition: transform .35s var(--ease); }
.dpanel:hover .dpanel__go { transform: translateY(-2px); }
.dpanel:hover .dpanel__go .arr { transform: translateX(6px); }
.dpanel__blob { position: absolute; right: -6%; bottom: -22%; width: 48%; aspect-ratio: 1; border-radius: 50%; background: var(--a); opacity: .14; z-index: 1; }
.dpanel.c-paint { --a: var(--c-paint); --at: var(--c-paint-t); } .dpanel.c-art { --a: var(--c-art); --at: var(--c-art-t); }
.dpanel.c-craft { --a: var(--c-craft); --at: var(--c-craft-t); } .dpanel.c-food { --a: var(--c-food); --at: var(--c-food-t); }
.dpanel.c-style { --a: var(--c-style); --at: var(--c-style-t); } .dpanel.c-active { --a: var(--c-active); --at: var(--c-active-t); }
.dirstage__hint { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; font-weight: 600; margin-top: 16px; padding-inline: var(--pad); }

/* static fallback (mobile / reduced motion) */
.dirstage__pin.is-static { height: auto; overflow: visible; display: flex; flex-direction: column; gap: 18px; padding: 8px var(--pad) 0; }
.dirstage__pin.is-static .dpanel { position: static; inset: auto; transform: none !important; opacity: 1 !important; min-height: 46vh; }

/* ============================================================
   FULLSCREEN STAGE — direction page teachers + courses
   ============================================================ */
.tstage { position: relative; }
.tstage__pin { height: 100vh; position: relative; overflow: hidden; }
.tcard {
  position: absolute; top: calc(var(--header-h) + 8px); right: clamp(12px, 3vw, 48px); bottom: clamp(16px, 3vh, 40px); left: clamp(12px, 3vw, 48px);
  border-radius: 36px; background: var(--accent-t); border: 1px solid var(--line);
  box-shadow: 0 50px 110px rgba(34,32,43,.16); overflow: hidden;
  padding: clamp(30px, 5vw, 84px); will-change: transform, opacity;
}
.tcard::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 10px; background: var(--accent); }
.tcard__teacher {
  position: absolute; top: 50%; left: clamp(30px, 5vw, 84px); right: clamp(30px, 5vw, 84px);
  margin-inline: auto; width: min(42%, 480px); text-align: center; z-index: 3; will-change: transform;
}
.tcard__teacher .teacher__photo, .tcard__teacher .teacher__mono { width: clamp(150px, 17vw, 230px); height: clamp(150px, 17vw, 230px); margin: 0 auto; }
.tcard__teacher .teacher__mono { font-size: clamp(56px, 7vw, 92px); }
.tcard__teacher .teacher__name { font-size: clamp(28px, 3vw, 46px); margin: 24px 0 18px; }
.tcard__teacher .teacher__regalia { display: inline-flex; flex-direction: column; gap: 9px; text-align: left; }
.tcard__teacher .teacher__regalia li { font-size: clamp(15px, 1.3vw, 18px); }
.tcard__teacher .chips-wrap { margin-top: 18px; justify-content: center; }
.tcard__courses { position: absolute; top: clamp(28px, 5vw, 84px); bottom: clamp(28px, 5vw, 84px); right: clamp(40px, 5vw, 84px); width: min(54%, 720px); z-index: 4; will-change: opacity; }
.tcourse {
  position: absolute; inset: 0; background: transparent; border: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; justify-content: center; will-change: transform, opacity;
}
.tcourse::before { display: none; }
.tcourse:hover { transform: none; box-shadow: none; }
.tcourse .course__top { display: block; }
.tcourse h5 { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 3.4vw, 48px); color: var(--accent-d); line-height: 1.04; }
.tcourse .course__time { display: inline-block; align-self: flex-start; margin-top: 16px; font-size: clamp(14px, 1.3vw, 18px); font-weight: 700; background: var(--accent); color: #fff; padding: 10px 22px; border-radius: 999px; }
.tcourse p { font-size: clamp(15px, 1.45vw, 20px); line-height: 1.55; color: var(--ink-soft); margin-top: 18px; max-width: none; }
.tcourse .mini { align-self: flex-start; margin-top: 24px; font-size: 17px; padding: 14px 30px; }
.tcard__count { position: absolute; right: clamp(24px, 3vw, 52px); bottom: clamp(20px, 3vh, 40px); z-index: 5; font-weight: 700; font-size: 15px; color: var(--accent-d); opacity: .55; }

/* duo teacher (a course led by two mentors) */
.duo-badge { display: inline-block; font-weight: 700; font-size: 13px; letter-spacing: .02em; padding: 7px 16px; border-radius: 999px; background: var(--accent); color: #fff; margin-bottom: 18px; box-shadow: 3px 3px 0 var(--ink); }
.duo-photos { display: flex; gap: 14px; justify-content: center; margin-bottom: 4px; }
.duo-photos .teacher__photo { width: clamp(96px, 11vw, 146px); height: clamp(96px, 11vw, 146px); }
.duo-photos .teacher__photo:nth-child(1) { transform: rotate(-4deg); }
.duo-photos .teacher__photo:nth-child(2) { transform: rotate(4deg); }
.teacher__side--duo .teacher__name { font-size: clamp(20px, 2vw, 28px); }
.tcard__teacher.teacher__side--duo .teacher__name { font-size: clamp(22px, 2.2vw, 30px); }

@media (prefers-reduced-motion: reduce) {
  .dpanel, .tpanel { transform: none !important; opacity: 1 !important; }
}

/* ============================================================
   MOBILE polish
   ============================================================ */
@media (max-width: 760px) {
  .dhero__sticker { display: none; }
  .dhero h1 { font-size: clamp(46px, 16vw, 80px); }
  .teacher { padding: 22px; }
  .teacher__photo, .teacher__mono { width: 120px; height: 120px; }
  .duo-photos .teacher__photo { width: 92px; height: 92px; }
  .works-strip { flex-wrap: nowrap; gap: 9px; overflow-x: auto; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding: 4px 2px 8px; }
  .works-strip::-webkit-scrollbar { display: none; }
  .work-thumb, .work-more { width: clamp(58px, 18vw, 76px); height: clamp(58px, 18vw, 76px); scroll-snap-align: start; }
  .cta { padding: 30px 22px; }
  .hero__cta .btn, .dhero .btn { width: 100%; justify-content: center; }
  .section { padding-block: clamp(48px, 12vw, 80px); }
}

/* ---------- reading progress bar ---------- */
.readbar { position: fixed; top: 0; left: 0; height: 4px; width: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; z-index: 95; }

/* ---------- hover dropdown on active direction link ---------- */
.navdrop-wrap { position: relative; display: inline-flex; align-items: center; }
@keyframes navbounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.nav-bounce { display: inline-block; animation: navbounce 1.5s ease-in-out infinite; }
.navdrop-wrap:hover .nav-bounce { animation-play-state: paused; }
.navdrop { position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%) translateY(8px); min-width: 210px; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 24px 56px rgba(34,32,43,.18); padding: 10px; display: flex; flex-direction: column; gap: 4px; opacity: 0; visibility: hidden; transition: opacity .25s var(--ease), transform .25s var(--ease), visibility .25s; z-index: 60; }
.navdrop::before { content: ""; position: absolute; top: -16px; left: 0; right: 0; height: 16px; }
.navdrop::after { content: ""; position: absolute; top: -7px; left: 50%; width: 13px; height: 13px; background: var(--paper); border-left: 1px solid var(--line); border-top: 1px solid var(--line); transform: translateX(-50%) rotate(45deg); }
.navdrop-wrap:hover .navdrop, .navdrop-wrap.is-open .navdrop { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.navdrop a { padding: 11px 16px; border-radius: 11px; font-size: 15px; font-weight: 600; color: var(--ink-soft); text-align: center; transition: background .2s, color .2s; }
.navdrop a:hover { background: var(--accent-t); color: var(--accent-d); }
.navdrop__cta { background: var(--accent); color: #fff !important; }
.navdrop__cta:hover { background: var(--accent-d) !important; color: #fff !important; }
/* directions list dropdown (on «Направления») */
.dirmenu { min-width: 254px; }
.dirmenu a { display: flex; align-items: center; gap: 12px; text-align: left; }
.dirmenu .dot { width: 11px; height: 11px; border-radius: 50%; flex: none; box-shadow: 0 0 0 3px color-mix(in oklab, currentColor 0%, transparent); }
.navdrop-wrap .caret { font-size: 9px; margin-left: 5px; opacity: .55; display: inline-block; transition: transform .25s var(--ease); }
.navdrop-wrap:hover .caret { transform: rotate(180deg); }

/* ---------- overview card: scannable bullets ---------- */
.cg-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.cg-list li { position: relative; padding-left: 16px; font-size: 14.5px; color: var(--ink-soft); line-height: 1.45; }
.cg-list li::before { content: ""; position: absolute; left: 0; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ---------- stage progress: rail + indicator + skip ---------- */
.tstage__rail { position: absolute; right: 18px; top: 14%; bottom: 14%; width: 4px; border-radius: 4px; background: color-mix(in oklab, var(--accent) 20%, transparent); z-index: 6; }
.tstage__railfill { position: absolute; left: 0; top: 0; width: 100%; height: 100%; background: var(--accent); border-radius: 4px; transform: scaleY(0); transform-origin: top; }
.tstage__ind { position: absolute; left: 50%; top: 22px; transform: translateX(-50%); z-index: 6; font-weight: 700; font-size: 13px; letter-spacing: .03em; color: var(--accent-d); background: var(--paper); border: 1px solid var(--line); padding: 8px 18px; border-radius: 999px; white-space: nowrap; }
.tstage__skip { position: absolute; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 6; font-weight: 700; font-size: 14px; color: var(--accent-d); background: var(--paper); border: 1px solid var(--line); padding: 10px 22px; border-radius: 999px; transition: transform .3s var(--ease), background .25s, color .25s, border-color .25s; }
.tstage__skip:hover { transform: translateX(-50%) translateY(3px); background: var(--accent); color: #fff; border-color: var(--accent); }

/* ---------- calm overview grid (scannable «Все курсы») ---------- */
.coursegrid { padding-block: clamp(48px, 7vw, 100px); position: relative; z-index: 1; }
.cg-filter { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.cg-filter button { font-weight: 700; font-size: 14px; padding: 9px 18px; border-radius: 999px; border: 1.5px solid var(--line); color: var(--ink-soft); transition: background .25s, color .25s, border-color .25s; }
.cg-filter button.is-active, .cg-filter button:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.coursegrid__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.cg-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; gap: 10px; transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.cg-card:hover { transform: translateY(-5px); box-shadow: 0 22px 46px rgba(34,32,43,.1); }
.cg-teacher { font-size: 12.5px; font-weight: 700; color: var(--accent-d); text-transform: uppercase; letter-spacing: .08em; }
.cg-card h4 { font-family: var(--font-display); font-weight: 700; font-size: 25px; color: var(--ink); line-height: 1.1; }
.cg-card .chip { align-self: flex-start; }
.cg-card p { color: var(--ink-soft); font-size: 15px; line-height: 1.55; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.cg-card .cg-book { align-self: flex-start; margin-top: auto; padding: 11px 22px; font-size: 15px; border-radius: 999px; background: var(--accent); color: #fff; font-weight: 700; transition: background .25s; }
.cg-card .cg-book:hover { background: var(--accent-d); }
.cg-card.is-hidden { display: none; }

/* ---------- works gallery (thumbnails + lightbox) ---------- */
.tcourse p.is-clamped { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; max-height: 5.1em; }
.works { margin-top: 18px; }
.works__label { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--accent-d); margin-bottom: 10px; }
.tcard__teacher .works { margin-top: 22px; }
.tcard__teacher .works__label { text-align: center; }
.tcard__teacher .works-strip { justify-content: center; }
.tcard__teacher .work-thumb, .tcard__teacher .work-more { width: clamp(46px, 4.4vw, 62px); height: clamp(46px, 4.4vw, 62px); border-radius: 11px; }
.works-strip { display: flex; gap: 10px; margin-top: 0; flex-wrap: nowrap; }
.work-thumb { flex: none; width: clamp(54px, 5vw, 74px); height: clamp(54px, 5vw, 74px); border-radius: 13px; object-fit: cover; cursor: pointer; border: 3px solid var(--paper); box-shadow: 0 8px 18px rgba(34,32,43,.14); transition: transform .3s var(--ease); background: var(--accent-t); }
.work-thumb:hover { transform: translateY(-5px) scale(1.05); }
.work-more { flex: none; width: clamp(54px, 5vw, 74px); height: clamp(54px, 5vw, 74px); border-radius: 13px; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 700; font-size: 15px; cursor: pointer; border: none; }
.cg-works { display: flex; gap: 8px; }
.cg-works img { width: 46px; height: 46px; border-radius: 10px; object-fit: cover; cursor: pointer; transition: transform .25s var(--ease); }
.cg-works img:hover { transform: scale(1.06); }

.lightbox { position: fixed; inset: 0; z-index: 120; display: flex; align-items: center; justify-content: center; background: rgba(20,18,28,.93); opacity: 0; visibility: hidden; transition: opacity .3s; }
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox__img { max-width: 88vw; max-height: 84vh; border-radius: 16px; box-shadow: 0 30px 90px rgba(0,0,0,.5); object-fit: contain; background: #2a2733; }
.lightbox__close { position: absolute; top: 22px; right: 26px; width: 50px; height: 50px; border-radius: 50%; background: rgba(255,255,255,.16); color: #fff; font-size: 20px; display: grid; place-items: center; cursor: pointer; transition: background .2s; }
.lightbox__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,.16); color: #fff; font-size: 24px; display: grid; place-items: center; cursor: pointer; transition: background .2s; }
.lightbox__nav:hover, .lightbox__close:hover { background: rgba(255,255,255,.32); }
.lightbox__prev { left: 24px; } .lightbox__next { right: 24px; }
.lightbox__count { position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%); color: #fff; font-weight: 700; font-size: 14px; opacity: .8; }
@media (max-width: 700px) { .lightbox__nav { width: 46px; height: 46px; } .lightbox__prev { left: 10px; } .lightbox__next { right: 10px; } }

/* ---------- booking modal + form ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 20px; opacity: 0; visibility: hidden; transition: opacity .3s var(--ease), visibility .3s; }
.modal.is-open { opacity: 1; visibility: visible; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(20,18,28,.55); backdrop-filter: blur(3px); }
.modal__card {
  position: relative; z-index: 1; width: min(560px, 100%); max-width: 100%; max-height: 92vh; overflow-y: auto; overflow-x: hidden;
  background: var(--paper); border-radius: var(--radius); padding: clamp(26px, 4vw, 44px);
  box-shadow: 0 30px 80px rgba(20,18,28,.4); transform: translateY(24px) scale(.97); transition: transform .35s var(--ease);
}
.modal.is-open .modal__card { transform: none; }
.modal__x { position: absolute; top: 16px; right: 16px; width: 42px; height: 42px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; font-size: 18px; color: var(--ink); transition: background .25s, transform .25s var(--ease); }
.modal__x:hover { background: var(--accent); color: #fff; border-color: var(--accent); transform: rotate(90deg); }
.modal__card h3 { font-size: clamp(26px, 3.4vw, 36px); margin: 14px 0 8px; }
.modal__sub { color: var(--muted); margin-bottom: 22px; }
.bform { display: grid; gap: 16px; min-width: 0; }
.bform label { display: grid; gap: 7px; font-weight: 700; font-size: 14px; color: var(--ink-soft); min-width: 0; }
.bform input:not([type=checkbox]), .bform select { width: 100%; min-width: 0; max-width: 100%; height: 52px; padding: 0 16px; font: inherit; font-weight: 500; color: var(--ink); background: var(--sunken); border: 1.5px solid var(--line); border-radius: 12px; transition: border-color .25s, background .25s; }
.bform input:focus, .bform select:focus { outline: none; border-color: var(--accent); background: var(--paper); }
.bform select { appearance: none; -webkit-appearance: none; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%236B6675' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 42px; }

/* contact block in booking modal */
.modal__contact { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); text-align: center; }
.modal__contact-label { display: block; font-size: 14px; font-weight: 700; color: var(--muted); margin-bottom: 14px; }
.modal__contact-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.cbtn { flex: 1 1 0; min-width: 96px; padding: 13px 12px; border-radius: 12px; font-weight: 700; font-size: 14.5px; color: #fff; text-align: center; transition: transform .25s var(--ease), filter .2s; }
.cbtn:hover { transform: translateY(-2px); filter: brightness(1.06); }
.cbtn--max { background: #6E56CF; }
.cbtn--wa { background: #25D366; }
.cbtn--tg { background: #2AABEE; }
.cbtn--vk { background: #0077FF; }
.modal__phone { display: inline-block; margin-top: 16px; font-family: var(--font-display); font-weight: 700; font-size: 24px; color: var(--ink); }
.modal__phone:hover { color: var(--accent-d); }
.bform .consent { display: block; position: relative; padding-left: 30px; font-weight: 500; font-size: 13.5px; line-height: 1.5; color: var(--muted); }
.bform .consent input { position: absolute; left: 0; top: 2px; width: 20px; height: 20px; accent-color: var(--accent); }
.bform .consent a { color: var(--accent-d); text-decoration: underline; }
.bform button[type=submit] { justify-content: center; margin-top: 6px; }
.bform input.hp-field { position: absolute; left: 0; top: 0; width: 1px; height: 1px; min-width: 0; padding: 0; border: 0; opacity: 0; overflow: hidden; clip-path: inset(50%); pointer-events: none; }
.bform__err { background: #fdecec; color: #b3261e; border: 1.5px solid #f6c9c5; border-radius: 12px; padding: 11px 14px; font-size: 13.5px; font-weight: 500; }
.bform__done { text-align: center; padding: 16px 6px; }
.bform__check { width: 76px; height: 76px; margin: 0 auto 20px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-size: 38px; }
.bform__done h3 { margin-bottom: 8px; }
.bform__done p { color: var(--muted); margin-bottom: 22px; }

/* ---------- reveal base (JS toggles) ---------- */
[data-reveal] { opacity: 0; transform: translateY(38px); }
.no-js [data-reveal] { opacity: 1; transform: none; }

/* ---------- mobile scroll-reveal (IntersectionObserver adds .m-in) ---------- */
@media (max-width: 900px) {
  /* единичные элементы (заголовки, абзацы) — мягко всплывают */
  html.m-fx [data-reveal] {
    opacity: 0; transform: translateY(28px);
    transition: opacity .7s cubic-bezier(.22,1,.36,1), transform .7s cubic-bezier(.22,1,.36,1);
  }
  html.m-fx [data-reveal].m-in { opacity: 1; transform: none; }

  /* группы с каскадом (курсы преподавателя, плитки) */
  html.m-fx [data-stagger] > * {
    opacity: 0; transform: translateY(24px);
    transition: opacity .55s ease, transform .6s cubic-bezier(.34,1.4,.5,1);
  }
  html.m-fx [data-stagger].m-in > * { opacity: 1; transform: none; transition-delay: calc(var(--i, 0) * 70ms); }

  /* курсы преподавателя — выезжают слева вдоль линии-таймлайна */
  html.m-fx .courses[data-stagger] > .course { transform: translateX(-28px); }
  html.m-fx .courses[data-stagger].m-in > .course { transform: none; }
  html.m-fx .courses::before { transform: scaleY(0); transform-origin: top; transition: transform .85s cubic-bezier(.22,1,.36,1) .12s; }
  html.m-fx .courses.m-in::before { transform: scaleY(1); }

  /* горизонтальные карточки курсов направления — каскад при появлении ряда */
  html.m-fx [data-hscroll] > * {
    opacity: 0; transform: translateY(26px) scale(.95);
    transition: opacity .6s ease, transform .65s cubic-bezier(.34,1.45,.5,1);
  }
  html.m-fx [data-hscroll].m-in > * { opacity: 1; transform: none; transition-delay: calc(var(--i, 0) * 85ms); }

  /* преподаватель: фото «выпрыгивает», имя и регалии поднимаются следом */
  html.m-fx .teacher .teacher__photo {
    opacity: 0; transform: scale(.6) rotate(-16deg);
    transition: opacity .6s ease, transform .85s cubic-bezier(.34,1.56,.64,1);
  }
  html.m-fx .teacher.m-in .teacher__photo { opacity: 1; transform: rotate(-3deg) scale(1); }
  html.m-fx .teacher .teacher__name {
    opacity: 0; transform: translateY(16px);
    transition: opacity .55s ease .16s, transform .6s cubic-bezier(.22,1,.36,1) .16s;
  }
  html.m-fx .teacher.m-in .teacher__name { opacity: 1; transform: none; }
  html.m-fx .teacher .teacher__regalia li {
    opacity: 0; transform: translateY(12px);
    transition: opacity .5s ease, transform .5s cubic-bezier(.22,1,.36,1);
  }
  html.m-fx .teacher.m-in .teacher__regalia li { opacity: 1; transform: none; transition-delay: calc(.24s + var(--ri, 0) * 55ms); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  html.m-fx [data-reveal], html.m-fx [data-stagger] > *, html.m-fx [data-hscroll] > *,
  html.m-fx .teacher .teacher__photo, html.m-fx .teacher .teacher__name,
  html.m-fx .teacher .teacher__regalia li { opacity: 1 !important; transform: none !important; }
}
