/* ==========================================================================
   Прикладной ИИ — лендинг Хабр Курсов
   Брейкпоинты: мобилка < 768, планшет 768–1279, десктоп >= 1280
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Токены
   -------------------------------------------------------------------------- */

:root {
  /* Цвета */
  --c-blue: #3670f4;
  --c-blue-hover: #5b8bf7;
  --c-blue-active: #2c5cd0;
  --c-mint: #83ffd8;
  --c-mint-hover: #9dffe2;
  --c-mint-active: #6fe6c2;
  --c-violet-1: #7365ee;
  --c-violet-2: #7883fe;
  --c-violet-3: #848efe;
  --c-violet-4: #939cff;
  --c-gray-100: #f3f5f7;
  --c-gray-200: #dfe4e9;
  --c-text: #000000;
  --c-text-muted: #67717d;
  --c-white: #ffffff;

  /* Радиусы из Figma переставлены местами: в её сниппете первым идёт
     вертикальный, в CSS — горизонтальный (73.91% ширины, 981.78% высоты) */
  --gradient-heading: radial-gradient(
    73.91% 981.78% at 33.67% 62.22%,
    #19217e 18.17%,
    #346ef4 47.04%,
    #939cff 81.51%
  );

  /* Сетка */
  --page-px: 8px;
  --container: 1200px;
  --section-py: 64px;
  --gap-card: 8px;

  /* Радиусы */
  --radius-card: 16px;
  --radius-inner: 12px;
  --radius-pill: 50px;
  --radius-bar: 101px;

  /* Типографика */
  --fs-h1: 32px;
  --lh-h1: 36px;
  --fs-h2: 24px;
  --lh-h2: 28px;
  --fs-h3: 20px;
  --lh-h3: 24px;
  --fs-body: 16px;
  --lh-body: 20px;
  --fs-caption: 12px;
  --lh-caption: 16px;

  --card-pad: 24px;

  /* Слайдер */
  --slide-w: 309px;
  --slide-h: 418px;
  --slide-w-active: 304px;
  --slide-h-active: 448px;
  --slide-gap: 64px;

  /* Стек расписания */
  /* Название и дата занимают две строки, поэтому следующий день начинается
     ниже обоих элементов шапки. */
  --stack-step: 92px;
  --stack-top: 96px;
  /* Следующий день появляется только после того, как целиком показан
     предыдущий: на мобилке карточки расположены друг под другом. */
  --stack-scroll: 780px;
  --stack-hold: 900px;
  --stack-pile: 1250px;
}

@media (min-width: 768px) {
  :root {
    --page-px: 20px;
    --radius-card: 24px;
    --radius-inner: 16px;
    --fs-h1: 48px;
    --lh-h1: 44px;
    --fs-h2: 28px;
    --lh-h2: 28px;
    --fs-h3: 22px;
    --lh-h3: 26px;
    --card-pad: 24px;
    --slide-w-active: 360px;
    --slide-h-active: 495px;
    --stack-step: 84px;
    --stack-top: 100px;
    --stack-scroll: 480px;
    --stack-hold: 800px;
    --stack-pile: 800px;
    --workshop-h: 256px;
  }
}

@media (min-width: 1280px) {
  :root {
    --page-px: 40px;
    --radius-card: 28px;
    --radius-inner: 24px;
    --fs-h1: 72px;
    --lh-h1: 72px;
    --fs-h2: 40px;
    --lh-h2: 44px;
    --fs-h3: 24px;
    --lh-h3: 24px;
    --fs-body: 18px;
    --lh-body: 24px;
    --fs-caption: 14px;
    --lh-caption: 20px;
    --card-pad: 32px;
    --stack-step: 108px;
    --stack-top: 100px;
    --stack-scroll: 520px;
    --stack-hold: 900px;
    --stack-pile: 880px;
    --workshop-h: 272px;
  }
}

/* Компактные телефоны, включая 320 px. */
@media (max-width: 360px) {
  :root {
    --section-py: 56px;
  }
}

/* С 490 px используем tablet-типографику; до 489 px остаются mobile-размеры. */
@media (min-width: 490px) and (max-width: 991px) {
  :root {
    --fs-h1: 48px;
    --lh-h1: 44px;
    --fs-h2: 28px;
    --lh-h2: 28px;
    --fs-h3: 22px;
    --lh-h3: 26px;
  }
}

/* --------------------------------------------------------------------------
   2. База
   -------------------------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  padding-top: 84px;
  background: var(--c-white);
  color: var(--c-text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: 500;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
p,
ul {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--c-blue);
  outline-offset: 2px;
  border-radius: 4px;
}

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

.skip-link {
  position: absolute;
  top: -100px;
  left: 8px;
  z-index: 100;
  padding: 12px 16px;
  background: var(--c-blue);
  color: var(--c-white);
  border-radius: var(--radius-pill);
}

.skip-link:focus {
  top: 8px;
}

/* --------------------------------------------------------------------------
   3. Общие элементы
   -------------------------------------------------------------------------- */

.section {
  padding: var(--section-py) var(--page-px);
}

.section > * {
  max-width: var(--container);
  margin-inline: auto;
}

.section__title {
  font-size: var(--fs-h1);
  line-height: var(--lh-h1);
  font-weight: 600;
  letter-spacing: -2px;
  text-align: center;
}

/* Фон при background-clip: text не выходит за коробку элемента, поэтому
   выносные элементы букв оставались без заливки — добавляем запас по вертикали
   и убираем его из потока отрицательным margin. */
.gradient-text {
  padding-block: 0.15em;
  margin-block: -0.15em;
  background: var(--gradient-heading);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.card {
  background: var(--c-gray-100);
  border-radius: var(--radius-card);
  padding: var(--card-pad);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 90px;
  padding: 12px 20px;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: 600;
  text-align: center;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn--mint {
  background: var(--c-mint);
  color: var(--c-text);
}

.btn--mint:hover {
  background: var(--c-mint-hover);
}

.btn--mint:active {
  background: var(--c-mint-active);
}

.btn--blue {
  background: var(--c-blue);
  color: var(--c-white);
}

.btn--blue:hover {
  background: var(--c-blue-hover);
}

.btn--blue:active {
  background: var(--c-blue-active);
}

.btn--dark {
  height: 60px;
  padding-inline: 30px;
  gap: 10px;
  background: var(--c-text);
  color: var(--c-mint);
  border-radius: var(--radius-pill);
  font-weight: 500;
}

.btn--dark:hover {
  background: #1c1c1c;
}

/* --------------------------------------------------------------------------
   4. Шапка
   -------------------------------------------------------------------------- */

.header {
  position: fixed;
  z-index: 50;
  top: 0;
  left: 0;
  width: 100%;
  padding: 4px var(--page-px) 0;
}

.header__bar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  max-width: var(--container);
  margin-inline: auto;
  padding: 8px;
  background: var(--c-blue);
  border-radius: var(--radius-bar);
}

.header__logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.header__logo-full {
  display: none;
  width: 97px;
  height: 34px;
}

.header__logo-mark {
  width: 48px;
  height: 48px;
}

.header__nav-list {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--c-white);
}

.header__nav-list a {
  transition: color 0.2s ease;
}

.header__nav-list a:hover {
  color: var(--c-mint);
}

.header__cta {
  flex-shrink: 0;
}

.header__toggle {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  background: none;
}

.header__toggle-close {
  display: none;
}

.header__toggle[aria-expanded="true"] .header__toggle-open {
  display: none;
}

.header__toggle[aria-expanded="true"] .header__toggle-close {
  display: block;
}

/* Мобильное меню */
@media (max-width: 767px) {
  .header__nav {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    z-index: 20;
    width: 220px;
    padding: 20px;
    background: var(--c-blue);
    border-radius: var(--radius-inner);
    transform: scale(0.96);
    transform-origin: top right;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }

  .header__nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
  }

  .header__nav-list {
    flex-direction: column;
    justify-content: center;
  }
}

@media (min-width: 768px) {
  body {
    padding-top: 90px;
  }

  .header {
    padding: 10px var(--page-px) 0;
  }

  .header__bar {
    padding-left: 20px;
  }

  .header__logo-full {
    display: block;
  }

  .header__logo-mark,
  .header__toggle {
    display: none;
  }

  .header__nav {
    margin-left: auto;
    margin-right: 48px;
  }

  .header__nav-list {
    font-size: var(--fs-body);
  }
}

/* --------------------------------------------------------------------------
   5. Hero
   -------------------------------------------------------------------------- */

.hero {
  padding-top: 0;
  padding-bottom: 0;
}

.hero__grid {
  display: grid;
  gap: var(--gap-card);
}

.hero__visual {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 453px;
  padding: 24px;
  /* Резервируем место под иллюстрацию с соотношением 2160×1743, чтобы
     текст всегда заканчивался выше изображения, прибитого к нижнему краю. */
  padding-bottom: calc(8px + 80.7%);
  background: var(--c-blue);
  overflow: hidden;
}

.hero__title {
  position: relative;
  z-index: 1;
  color: var(--c-mint);
  font-size: var(--fs-h1);
  line-height: var(--lh-h1);
  font-weight: 600;
  letter-spacing: -2px;
}

.hero__lead {
  position: relative;
  z-index: 1;
  color: var(--c-gray-100);
}

/* Экспорт из Figma уже обрезан по карточке, поэтому прижимаем его к её низу */
.hero__illustration {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: auto;
  z-index: 0;
}

/* В этом диапазоне hero остаётся вертикальным, но новой иллюстрации нужно
   больше места под текстом. */
@media (min-width: 557px) and (max-width: 767px) {
  .hero__visual.is-visible {
    min-height: 620px;
  }
}

@media (max-width: 360px) {
  .hero__visual {
    min-height: 437px;
  }
}

.hero__form-card {
  display: flex;
  flex-direction: column;
  gap: 34px;
  padding: 24px;
}

.hero__pitch {
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
}

@media (min-width: 768px) {
  .hero {
    padding-block: 10px;
  }

  .hero__grid {
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
  }

  .hero__visual,
  .hero__form-card {
    min-height: 596px;
  }
}

/* --------------------------------------------------------------------------
   6. Форма
   -------------------------------------------------------------------------- */

.form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form__row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form__field {
  display: block;
  flex: 1;
}

.form__input {
  width: 100%;
  height: 56px;
  padding: 12px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: var(--c-white);
  color: var(--c-text);
  font: inherit;
  text-align: center;
  transition: border-color 0.2s ease;
}

.form__input::placeholder {
  color: var(--c-text-muted);
}

.form__input:hover {
  border-color: var(--c-gray-200);
}

.form__input:focus {
  border-color: var(--c-blue);
  outline: none;
}

.form__input[aria-invalid="true"] {
  border-color: #e2445c;
}

.form__submit {
  height: 56px;
  border-radius: var(--radius-pill);
}

.form__note,
.checkbox__label {
  color: var(--c-text-muted);
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
}

.form__note {
  text-align: center;
}

.form__note a {
  color: var(--c-blue);
  text-decoration: underline;
}

.form__status {
  margin: 0;
  color: var(--c-text-muted);
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
  text-align: center;
}

.form__status:empty {
  display: none;
}

.form__status--error {
  color: #e2445c;
}

.form__status--success {
  color: #12996b;
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
}

.checkbox__input {
  position: absolute;
  opacity: 0;
  width: 24px;
  height: 24px;
  margin: 0;
  cursor: pointer;
}

.checkbox__control {
  position: relative;
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin: 1px;
  border: 2px solid var(--c-text-muted);
  border-radius: 6px;
  background: var(--c-white);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.checkbox__control::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 6px;
  height: 11px;
  border: solid var(--c-white);
  border-width: 0 2px 2px 0;
  transform: translate(-50%, -50%) rotate(45deg) scale(0);
  transition: transform 0.15s ease;
}

.checkbox__input:checked + .checkbox__control {
  background: var(--c-blue);
  border-color: var(--c-blue);
}

.checkbox__input:checked + .checkbox__control::after {
  transform: translate(-50%, -50%) rotate(45deg) scale(1);
}

.checkbox__input:focus-visible + .checkbox__control {
  outline: 2px solid var(--c-blue);
  outline-offset: 2px;
}

@media (min-width: 768px) {
  .form--inline .form__row {
    flex-direction: row;
  }
}

/* --------------------------------------------------------------------------
   7. Персоны (слайдер)
   -------------------------------------------------------------------------- */

.personas {
  padding-inline: 0;
}

.personas .section__title {
  padding-inline: var(--page-px);
}

.slider {
  position: relative;
  max-width: none;
  margin-top: 48px;
}

.slider__viewport {
  overflow: hidden;
}

/* Высота фиксирована по самой крупной карточке, иначе блок прыгает,
   когда активная карточка меняется */
.slider__track {
  display: flex;
  align-items: center;
  height: calc(var(--slide-h-active) + 40px);
  gap: var(--slide-gap);
  padding-block: 20px;
  transition: transform 0.5s cubic-bezier(0.22, 0.61, 0.36, 1);
  touch-action: pan-y;
}

.slider__track.is-dragging {
  transition: none;
  cursor: grabbing;
}

.slider--instant .slider__track,
.slider--instant .persona {
  transition: none;
}

.persona {
  position: relative;
  flex: 0 0 auto;
  width: min(var(--slide-w), calc(100vw - 24px));
  height: var(--slide-h);
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--c-blue);
  transition: width 0.4s ease, height 0.4s ease;
}

.persona.is-active {
  width: min(var(--slide-w-active), calc(100vw - 24px));
  height: var(--slide-h-active);
}

.persona__media img {
  width: 100%;
  height: auto;
}

.persona__text {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 215px;
  padding: 30px;
  background: var(--c-gray-100);
}

.persona__title {
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  font-weight: 600;
  letter-spacing: -1px;
}

.persona__desc {
  color: var(--c-text-muted);
}

.slider__arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--c-white);
  color: var(--c-blue);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  transform: translateY(-50%);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.slider__arrow svg {
  width: 24px;
  height: 24px;
}

.slider__arrow:hover {
  background: var(--c-blue);
  color: var(--c-white);
}

.slider__arrow--prev {
  left: var(--page-px);
}

.slider__arrow--next {
  right: var(--page-px);
}

.slider__dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 16px;
}

.slider__dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--c-gray-200);
  transition: background-color 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.slider__dot.is-active {
  width: 12px;
  height: 12px;
  background: var(--c-blue);
}

@media (min-width: 768px) {
  .slider__arrow {
    display: flex;
  }

  .slider__dots {
    gap: 4px;
    margin-top: 24px;
  }

  .slider__dot {
    width: 12px;
    height: 12px;
  }

  .slider__dot.is-active {
    width: 16px;
    height: 16px;
  }

  .persona__title {
    letter-spacing: -1px;
  }
}

/* --------------------------------------------------------------------------
   8. Вводный блок
   -------------------------------------------------------------------------- */

.audience__text {
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
  text-align: center;
  max-width: 993px;
}

@media (min-width: 1280px) {
  .audience__text {
    line-height: 44px;
  }
}

/* --------------------------------------------------------------------------
   9. Программа
   -------------------------------------------------------------------------- */

.program__head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin-bottom: 48px;
}

.program__dates {
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
}

.program__grid {
  display: grid;
  gap: var(--gap-card);
}

.feature {
  position: relative;
  min-height: 364px;
  padding: 24px;
  overflow: hidden;
}

.feature__text {
  position: relative;
  z-index: 1;
  color: var(--c-text-muted);
}

/* Иллюстрация не тянется по ширине карточки: в макете у неё свой размер,
   иначе на планшете она вырастает и наезжает на текст */
.feature__img {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 294px;
  max-width: 100%;
  height: auto;
  transform: translateX(-50%);
}

@media (min-width: 768px) {
  .program__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1280px) {
  .program__grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .feature {
    padding: 28px;
  }
}

/* --------------------------------------------------------------------------
   10. Расписание (стек карточек)
   -------------------------------------------------------------------------- */

.schedule__title {
  margin-bottom: 48px;
}

.schedule {
  min-height: 0;
}

.schedule__stack {
  --stack-gap: 108px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  height: auto;
  overflow: visible;
  isolation: isolate;
}

.schedule__slot {
  position: sticky;
  top: calc(var(--i) * var(--stack-gap));
  display: block;
  width: 100%;
  z-index: var(--i);
}

.schedule-day {
  position: relative;
  left: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  margin-inline: auto;
  padding: 20px;
  border-radius: var(--radius-card);
  overflow: hidden;
  transform-origin: center top;
  will-change: transform, width, top, opacity;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transition: none;
  pointer-events: auto;
}

/* Ширина карточек меняется плавно скриптом по мере появления новых дней. */
.schedule-day--1,
.schedule-day--2,
.schedule-day--3,
.schedule-day--4,
.schedule-day--5 {
  width: 100%;
  margin-inline: auto;
  transition: width 0.25s ease;
}

@media (max-width: 767px) {
  .schedule {
    overflow-x: clip;
  }

}

.schedule-day--1 { background: var(--c-violet-4); }
.schedule-day--2 { background: var(--c-violet-3); }
.schedule-day--3 { background: var(--c-violet-2); }
.schedule-day--4 { background: var(--c-violet-1); }
.schedule-day--5 { background: var(--c-blue); }

.schedule-day__head {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.schedule-day__name {
  color: var(--c-mint);
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
}

.schedule-day__date {
  color: #83ffd8;
}

.schedule-day__cards {
  display: grid;
  gap: var(--gap-card);
}

.workshop {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  background: var(--c-white);
  border-radius: var(--radius-card);
}

.workshop__time {
  margin-bottom: 8px;
  color: var(--c-text-muted);
}

.workshop__title {
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  font-weight: 600;
  letter-spacing: -1px;
}

.workshop__desc {
  color: var(--c-text-muted);
}

.workshop__school {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 24px;
  color: var(--c-blue);
  transition: color 0.2s ease;
}

.workshop__school:hover {
  color: var(--c-blue-active);
}

.workshop__logo {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  background: var(--c-text);
  border-radius: 8px;
}

.workshop__logo img {
  width: 29px;
  height: 29px;
}

.workshop__logo img.is-full-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.workshop__logo.has-brand-logo {
  background: transparent;
}

.workshop__toggle {
  position: absolute;
  top: 8px;
  right: 8px;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.9);
}

.workshop__toggle span,
.workshop__toggle span::after {
  display: block;
  width: 16px;
  height: 2px;
  background: var(--c-white);
  content: "";
}

.workshop__toggle span {
  transition: transform 0.2s ease;
}

.workshop__toggle span::after {
  transform: rotate(90deg);
  transition: transform 0.2s ease;
}

.workshop__toggle[aria-expanded="true"] span {
  transform: rotate(45deg);
}

.workshop__details {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  color: var(--c-text-muted);
  transition: max-height 0.35s ease, opacity 0.25s ease;
}

.workshop__details p {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0;
}

.workshop__done-icon {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
}

.workshop__details {
  gap: 8px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
}

.workshop.is-open .workshop__details {
  max-height: 320px;
  opacity: 1;
}

@media (min-width: 768px) {
  .schedule-day {
    gap: 32px;
    padding: 32px;
  }

  .schedule-day__head {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

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

  /* Высота как в макете: одинаковые карточки держат дни одной высоты,
     иначе они открепляются вразнобой и стопка разъезжается при уходе. */
  .workshop {
    position: relative;
    min-height: var(--workshop-h);
    padding: 24px;
  }

  .schedule-day__date {
    font-size: 40px;
    line-height: 44px;
    font-weight: 600;
    letter-spacing: -1px;
  }

  .schedule-day__cards {
    gap: 8px;
  }

  .workshop {
    min-height: 272px;
  }

  .workshop__school {
    padding-top: 48px;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .schedule__stack {
    --stack-gap: 92px;
  }

  .schedule {
    min-height: 0;
  }

}

@media (max-width: 767px) {
  .schedule__stack {
    --stack-gap: 68px;
  }

  .schedule {
    min-height: 0;
  }

}

/* --------------------------------------------------------------------------
   11. CTA-блок
   -------------------------------------------------------------------------- */

.cta {
  position: relative;
  z-index: 10;
  background: var(--c-white);
}

.cta__card {
  display: flex;
  flex-direction: column;
  gap: 30px;
  overflow: hidden;
}

.cta__intro {
  display: flex;
  flex-direction: column;
}

/* Экспорт иллюстрации содержит фон карточки, поэтому заголовок держим поверх */
.cta__title {
  position: relative;
  z-index: 1;
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
}

/* У экспорта сверху 32px запаса вокруг артворка — компенсируем отступом */
.cta__illustration {
  width: 407px;
  max-width: 100%;
  height: auto;
  margin-top: -32px;
}

@media (min-width: 768px) {
  .cta__card {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
  }

  .cta__intro,
  .cta__card .form {
    flex: 1;
  }
}

/* --------------------------------------------------------------------------
   12. Вакансии
   -------------------------------------------------------------------------- */

.jobs {
  display: none;
}

.jobs__list {
  display: flex;
  flex-direction: column;
  gap: var(--gap-card);
  margin-top: 48px;
}

.company {
  display: grid;
}

.company__photo {
  min-height: 307px;
  background: var(--c-text);
  border-radius: var(--radius-card);
}

.company__body {
  display: flex;
  flex-direction: column;
  gap: 30px;
  padding: 20px;
  border-radius: var(--radius-card);
  color: var(--c-white);
  overflow: hidden;
}

.company__body--blue {
  background: var(--c-blue);
}

.company__body--violet {
  background: var(--c-violet-1);
}

.company__head {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.company__name {
  color: var(--c-mint);
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
}

.company__about {
}

.company__vacancies {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.company__subtitle {
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  font-weight: 600;
  letter-spacing: -1px;
}

.company__grid {
  display: grid;
  gap: 10px 40px;
}

.company__grid a {
  transition: color 0.2s ease;
}

.company__grid a:hover {
  color: var(--c-mint);
}

.company__cta {
  align-self: flex-start;
}

@media (min-width: 768px) {
  .company {
    grid-template-columns: 307px 1fr;
  }

  .company__body {
    padding: 32px;
  }

  .company__grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-flow: column;
    grid-template-rows: repeat(5, auto);
  }
}

@media (min-width: 1280px) {
  .company {
    grid-template-columns: 487px 1fr;
  }
}

/* --------------------------------------------------------------------------
   13. FAQ
   -------------------------------------------------------------------------- */

.faq__list {
  display: flex;
  flex-direction: column;
  gap: var(--gap-card);
  margin-top: 32px;
}

.faq__item {
  border-radius: var(--radius-card);
  background: var(--c-gray-100);
}

.faq__item:nth-child(even) {
  background: var(--c-gray-200);
}

.faq__question {
  margin: 0;
  font-size: inherit;
  line-height: inherit;
  font-weight: inherit;
}

.faq__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  padding: 20px 20px 20px 32px;
  border: 0;
  background: none;
  color: inherit;
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  font-weight: 600;
  letter-spacing: -1px;
  text-align: left;
}

.faq__toggle {
  position: relative;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--c-text);
  transition: transform 0.3s ease;
}

.faq__toggle::before,
.faq__toggle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 2px;
  background: #83ffd8;
  transform: translate(-50%, -50%);
}

.faq__toggle::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.faq__trigger[aria-expanded="true"] .faq__toggle {
  transform: rotate(45deg);
}

.faq__answer {
  overflow: hidden;
  color: var(--c-text-muted);
  transition: height 0.3s ease;
}

.faq__answer > p {
  padding: 0 20px 20px 32px;
}

@media (min-width: 768px) {
  .faq__toggle {
    width: 46px;
    height: 46px;
  }

  .faq__toggle::before,
  .faq__toggle::after {
    width: 16px;
  }
}

/* --------------------------------------------------------------------------
   14. Хабр Курсы
   -------------------------------------------------------------------------- */

.about__grid {
  display: grid;
  gap: var(--gap-card);
}

.about__intro {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  overflow: hidden;
  /* место под иллюстрацию: её пропорции 628×473, отсюда 75.3% от ширины */
  padding-bottom: 75.3%;
}

.about__lead {
  color: var(--c-text-muted);
  text-align: center;
}

.about__cta {
  display: flex;
  width: fit-content;
  margin: 48px auto 0;
}

/* Экспорт иллюстрации содержит фон карточки, поэтому текст держим поверх */
.about__intro > .section__title,
.about__lead {
  position: relative;
  z-index: 1;
}

.about__illustration {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: auto;
}

.about__stats {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: var(--radius-card);
  overflow: hidden;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex: 1;
  padding: 24px 40px;
  border-radius: var(--radius-card);
  color: var(--c-white);
  text-align: center;
}

.stat--blue { background: var(--c-blue); }
.stat--violet { background: var(--c-violet-2); }
.stat--lilac { background: var(--c-violet-4); }

.stat__value {
  color: var(--c-mint);
  font-size: 32px;
  line-height: 36px;
  font-weight: 700;
  letter-spacing: -2px;
}

.stat__label {
}

@media (min-width: 768px) {
  .about__grid {
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
  }

  .about__intro {
    height: 596px;
    padding-bottom: var(--card-pad);
  }

  .about__stats {
    height: 596px;
  }

  .stat {
    padding: 40px;
  }

  .stat__value {
    font-size: 40px;
    line-height: 44px;
    letter-spacing: -3px;
  }
}

@media (min-width: 1280px) {
  .stat__value {
    font-size: 72px;
    line-height: 72px;
    letter-spacing: -4px;
  }
}

/* --------------------------------------------------------------------------
   15. Подвал
   -------------------------------------------------------------------------- */

.footer {
  padding: var(--section-py) var(--page-px);
}

.footer > * {
  max-width: var(--container);
  margin-inline: auto;
}

.footer__content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer__title {
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: 600;
  letter-spacing: -1px;
  max-width: 750px;
}

.footer__text {
  max-width: 555px;
  color: var(--c-text-muted);
}

.socials {
  display: flex;
  gap: 10px;
}

.social {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 30px;
  overflow: hidden;
  transition: transform 0.2s ease;
}

.social:hover {
  transform: translateY(-2px);
}

.social img {
  width: 60px;
  height: 60px;
  max-width: none;
}

.social--telegram { background: #2aabee; }
.social--vk { background: var(--c-blue); }
.social--dzen { background: var(--c-text); }
.social--youtube { background: #ff0000; }

.footer__copyright {
  margin-top: 50px;
  color: rgba(0, 0, 0, 0.7);
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
}

/* --------------------------------------------------------------------------
   16. Появление при скролле
   -------------------------------------------------------------------------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
