@font-face {
  font-family: 'druk-heavy';
  src: url('/fonts/druktextwidecyr-heavy.otf') format('opentype');
}

@font-face {
  font-family: 'gilroy-extrabold';
  src: url('/fonts/Gilroy-Extrabold.ttf') format('truetype');
}

@font-face {
  font-family: 'gilroy-regular';
  src: url('/fonts/Gilroy-Regular.ttf') format('truetype');
}

/* Переменные и базовая типографика */
:root {
  --step--1: clamp(0.78rem, 0.68rem + 0.4vw, 0.95rem);
  --step-0: clamp(0.95rem, 0.85rem + 0.5vw, 1.125rem);
  --step-1: clamp(1.1rem, 0.95rem + 0.9vw, 1.35rem);
  --step-2: clamp(1.35rem, 1.1rem + 1.4vw, 1.7rem);
  --step-3: clamp(1.7rem, 1.3rem + 2.2vw, 2.2rem);

  --radius: 16px;
  --radius-lg: 22px;
  --gap: clamp(12px, 1.5vw, 20px);
  --gap-lg: clamp(16px, 2vw, 28px);

  --bg: #011516;
  --card: #0c4b4d;
  --muted: #0c4b4db3;
  --ink: #eaf7f6;
  --ink-2: #bfe4df;
  --accent: #63D696;
  --accent-2: #43d3a5;
  --danger: #ff6b6b;

  --shadow: 0 10px 30px rgba(0, 0, 0, .25);
  --outline: 2px solid #7AF0C3;
  --transition: .18s ease;

  --regular: 'gilroy-regular';
  --extra: 'gilroy-extrabold';
  --heavy: 'druk-heavy';

  /* ВАЖНО: цвет плашки анимации */
  --wipe: #63D696;
}

html,
body {
  height: 100%
}

body {
  margin: 0;
  font-family: var(--regular);
  color: var(--ink);
  background-color: var(--bg);
  line-height: 1.5;
  font-size: var(--step-0);
  overflow-x: hidden;
  position: relative;
}







.color {
  color: var(--accent);
  font-family: var(--heavy);
}

.h1 {
  font-family: var(--heavy);
}

.container {
  width: 100vw;
  box-sizing: border-box;
  padding-inline: clamp(30px, 10%, 10%);
  margin-inline: auto;
}

/* HERO */
.hero {
  height: 100vh;
  padding-top: 5%;
}

@media (max-width: 768px) {
  .hero {
    height: unset;
    padding: 20% 0;
  }
}

.bg {
  position: absolute;
  top: 0;
  left: 0;
  height: 130vh;
  width: 100%;
  z-index: -1;
  overflow: hidden;
}

.bg img {
  height: 100%;
  width: auto;
}

.logos {
  display: flex;
  gap: 40px;
  align-items: end;
  margin-bottom: 60px;
}

.logos .left {
  display: inline-grid;
  gap: 20px;
}

@media (max-width: 768px) {
  .logos {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  .logos .left img {
    height: 44px;
  }

  .logos .right img {
    height: 60px;
  }
}

.hero__tag {
  display: inline-grid;
  grid-auto-flow: column;
  letter-spacing: .02em;
  text-transform: uppercase;
  border: 2px solid var(--accent);
  border-radius: 999px;
  padding: 14px 32px;
  color: var(--accent);
  font-size: clamp(10px, 3vw, 16px);
  font-family: var(--extra);
  margin: 0 10px 10px 0;
}

.hero__title {
  font-family: var(--heavy);
  text-transform: uppercase;
}

.hero__title .title {
  font-size: clamp(35px, 8vw, 160px);
}

.hero__title .subtitle {
  font-size: clamp(14px, 3vw, 34px);
}

.hero__subtitle {
  font-size: var(--step-1);
  color: var(--ink-2);
  margin-top: .3rem;
}



/* ===== Анимация: слева → направо, текст проявляется под зелёной плашкой ===== */
.reveal-word {
  position: relative;
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
}

/* Текст скрыт маской и раскрывается слева → направо */
.reveal-word .t {
  position: relative;
  display: inline-block;
  opacity: 1;
  /* без общего фейда */
  clip-path: inset(0 100% 0 0);
  /* справа «срезано» 100% — ничего не видно */
  will-change: clip-path;
}

/* Плашка заезжает слева и уезжает вправо */
.reveal-word .wipe {
  position: absolute;
  inset: 0;
  background: var(--wipe, #49ff49);
  transform: translateX(-100%);
  /* старт — за левым краем */
  z-index: 1;
  will-change: transform;
  pointer-events: none;
}

/* стаггер по словам (левое слово первое) */
.animate .reveal-word {
  --d: calc(var(--i) * 90ms);
}

/* плашка: слева → направо */
.animate .reveal-word .wipe {
  animation: wipe-sweep-ltr 700ms ease-out var(--d) forwards;
}

/* текст: раскрываем маску слева → направо (синхронно с плашкой) */
.animate .reveal-word .t {
  animation: text-reveal-ltr 1500ms ease-out calc(var(--d) + 40ms) forwards;
}

/* кейфреймы */
@keyframes wipe-sweep-ltr {
  0% {
    transform: translateX(-100%);
  }

  /* слева */
  100% {
    transform: translateX(100%);
  }

  /* уехала вправо */
}

@keyframes text-reveal-ltr {
  0% {
    clip-path: inset(0 100% 0 0);
  }

  /* скрыт */
  100% {
    clip-path: inset(0 0 0 0);
  }

  /* полностью видим */
}








/* ===== ABOUT ===== */
#about {
  padding: 10% 0;
  background-color: #0d2d2d;
  border-radius: clamp(60px, 8vw, 120px);
  /* 60 на мобилке, 120 на десктопе */
  overflow: hidden;
  position: relative;
}

#about .container {
  position: relative;
  z-index: 1;
}

.line {
  position: absolute;
  top: 0;
  z-index: 0;
  height: 120%;
  opacity: 0.2;
}

.row-1 {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  /* текст слева, квадрат справа */
  column-gap: 60px;
  align-items: center;
}

.lead {
  font-size: clamp(16px, 4vw, 32px);
  line-height: 1.2;
}

.stamp {
  width: 400px;
  height: 400px;
  border-radius: 60px;
  color: var(--accent);
  display: grid;
  place-items: center;
  box-shadow: inset 0 0 0 2px var(--accent), 0 2px 0 rgba(0, 0, 0, .08);
  text-align: left;
  position: relative;
  overflow: hidden;
}

.stamp img {
  position: absolute;
  top: -2000px;
  right: -600px;
  z-index: 0;
}

.term {
  font-size: 24px;
  line-height: 1;
}

.date {
  font-family: var(--heavy);
  line-height: 1;
  display: flex;
  align-items: start;
}

.number {
  font-size: 80px;
}

.mounth {
  font-size: 34px;
  margin-top: 6px;
}

@media (max-width: 768px) {
  .stamp {
    width: 100%;
    height: 320px;
  }
}

.box {
  margin-top: clamp(18px, 3vw, 28px);
  border-radius: 20px;
  padding: clamp(14px, 2.2vw, 20px);
  outline: 2px dashed var(--dash);
  outline-offset: -8px;
}

.box h2 {
  margin: 0 0 .6em 0;
  font-size: clamp(20px, 1.2rem + .9vw, 34px);
  color: #64e1b8;
}

.stages {
  display: grid;
  gap: clamp(14px, 2vw, 18px);
  grid-template-columns: 1fr 1fr;
}

.stage {
  background: #0c4b4d3b;
  padding: 40px;
  border-radius: 60px;
  color: #0b1c1c;
  box-shadow: inset 0 0px 124px -42px #64e1b8;
  min-height: 260px;
  backdrop-filter: blur(4px);
}

.stage h3 {
  margin: 0 0 .35em 0;
  color: #fff;
  font-weight: 800;
  font-size: clamp(18px, 1rem + .8vw, 28px);
}

.stage p {
  margin: 0;
  color: #eff7f6;
  font-size: clamp(14px, 3vw, 26px);
}

@media (max-width: 860px) {
  .row-1 {
    grid-template-columns: 1fr;
  }

  .stages {
    grid-template-columns: 1fr;
  }
}


/* registration */

#reg {
  padding: 10% 0;
}

.reg__heading {
  text-align: center;
  margin-bottom: 60px;
}

.reg__heading p {
  font-size: clamp(16px, 4vw, 24px);
  line-height: 1.2;
}



/* ===== Аккордеон / кнопки / формы ===== */
.accordion {
  display: grid;
  gap: var(--gap);
}

.acc-item {
  background: #0b3f41;
  border: 1px solid #145457;
  border-radius: var(--radius);
  overflow: clip;
}

.acc-summary {
  width: 100%;
  background: transparent;
  color: var(--ink);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: .75rem;
  padding: clamp(20px, 1.8vw, 40px);
  cursor: pointer;
  border: none;
  font-size: var(--step-0);
}

.acc-summary:hover {
  background: #0f4d50;
}

.acc-summary:focus-visible {
  outline: 2px solid #3bd7af;
  outline-offset: 2px;
  border-radius: calc(var(--radius) - 2px);
}

.acc-summary .chev {
  transition: transform .25s ease;
  will-change: transform;
}

.acc-item.open .acc-summary .chev {
  transform: rotate(-180deg);
}

/* анимированное тело аккордеона */
.acc-body {
  height: 0;
  overflow: hidden;
  padding: 0 clamp(12px, 1.8vw, 18px);
  border-top: 1px solid transparent;
  background: #0a3638;
  transition: height .28s ease;
}

.acc-item.open .acc-body {
  border-top-color: #145457;
}

/* внутренние отступы только когда содержимое видно */
.acc-body>.acc-body-inner {
  padding: clamp(12px, 1.8vw, 18px) 0 clamp(12px, 1.8vw, 18px);
}

@media (prefers-reduced-motion: reduce) {
  .acc-summary .chev {
    transition: none;
  }

  .acc-body {
    transition: none;
  }
}

.topic-row {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr auto;
  align-items: center;
  margin-bottom: 20px;
}

.topic-selected {
  background: #0e4447;
  border: 1px dashed #2a7f83;
  border-radius: var(--radius);
  padding: .75rem;
  min-height: 52px;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  align-content: flex-start;
}

.tag {
  display: inline-grid;
  grid-auto-flow: column;
  align-items: center;
  gap: 20px;
  padding: .35rem .6rem;
  border-radius: 999px;
  border: 1px solid #2a7f83;
  background: #125457;
  font-size: var(--step--1);
  color: #d7f5f1;
}

.tag .x {
  cursor: pointer;
  font-weight: 700;
  opacity: .8;
}

.tag .x:hover {
  opacity: 1;
}

.btn {
  appearance: none;
  border: none;
  border-radius: 999px;
  padding: .75rem 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--transition), background var(--transition), opacity var(--transition);
  user-select: none;
  line-height: 1;
  font-size: var(--step--1);
  justify-self: start;
}

.btn:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.btn-primary {
  color: #06393a;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
  box-shadow: 0 6px 18px rgba(67, 211, 165, .35);
}

.btn-primary:hover {
  transform: translateY(-1px);
}

.btn-ghost {
  color: var(--ink);
  background: #0e4447;
  border: 1px solid #2a7f83;
}

.btn-outline {
  color: var(--card);
  background: transparent;
  border: 2px solid var(--card);
}



/* cards */

#person {
  padding: 5% 0;
  background-color: #0d2d2d;
  border-radius: clamp(60px, 8vw, 120px);
  overflow: hidden;
  position: relative;
}

#person .container {
  width: 100vw;
  box-sizing: border-box;
  padding-inline: clamp(30px, 3%, 3%);
  margin-inline: auto;
  position: relative;
  z-index: 2;
}

a {
  text-decoration: none;
  color: var(--accent);
}

.grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  /* mobile: 1 */
}

@media (min-width: 480px) {
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}


@media (min-width: 768px) {
  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}


@media (min-width: 1200px) {
  .grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}


.person {
  background: #141a22;
  border: 1px solid #242c37;
  border-radius: var(--card-radius);
  padding-bottom: 20px;
  display: grid;
  gap: 20px;
  align-content: start;
  text-align: center;
  box-shadow: 0 2px 16px rgb(0 0 0 / 25%);
  border-radius: 30px;
  overflow: hidden;
}









.person div {
  padding: 0 20px;
  display: grid;
  gap: 10px;
}

.person img {
  width: 100%;
  border-radius: 30px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  margin-bottom: 12px;
}

.person__name {
  font-size: clamp(14px, 3vw, 18px) !important;
}


.person div div:first-child {
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 6px;
}


.person div div:nth-child(2) {
  font-size: 14px;
}

/* social */

#social {
  padding: 10% 0;
}

.social {
    text-align: center;
}
.social img {
  width: 160px;
  height: auto;
}



/* modal */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  background: rgba(0, 15, 15, .55);
  backdrop-filter: blur(3px);
  z-index: 90;
  padding: 24px;
}

.modal.open {
  display: grid;
}

.modal__card {
  width: min(860px, 100%);
  background: #f6fbfa;
  color: #0d2d2d;
  border-radius: 18px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.modal__head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: #ffffff;
  border-bottom: 1px solid #e3efed;
}

.modal__title {
  font-size: clamp(1.1rem, 0.6rem + 1.6vw, 1.6rem);
  font-weight: 800;
  color: #0f4646;
}

.modal__close {
  background: #eef7f5;
  border: 1px solid #d1ece6;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  cursor: pointer;
}

.modal__body {
  padding: clamp(14px, 2vw, 22px);
}

.modal__foot {
  padding: clamp(14px, 2vw, 22px);
  border-top: 1px solid #e3efed;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
  background: #ffffff;
}

.topics-list {
  max-height: min(52vh, 520px);
  overflow: auto;
  border: 1px solid #e1eeec;
  border-radius: 14px;
  background: #ffffff;
}

.topic-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  padding: 14px 16px;
  align-items: flex-start;
  border-bottom: 1px solid #edf5f4;
  cursor: pointer;
}

.topic-item:last-child {
  border-bottom: none;
}

.topic-item:hover {
  background: #f3fbf9;
}

.topic-item input {
  transform: translateY(3px);
}

form .row {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr 1fr;
}

form .row+.row {
  margin-top: var(--gap);
}

label {
  font-size: var(--step--1);
  color: #2e5555;
  display: block;
  margin-bottom: 6px;
}

input,
textarea {
  width: 100%;
  box-sizing: border-box;
  padding: .9rem 1rem;
  border-radius: 12px;
  border: 1px solid #cfe7e3;
  background: #ffffff;
  color: #0b2f2f;
  font-size: var(--step-0);
  outline: none;
  transition: box-shadow var(--transition), border-color var(--transition);
}

textarea {
  min-height: 110px;
  resize: vertical;
}

input:focus,
textarea:focus {
  box-shadow: 0 0 0 4px #dff6f0;
  border-color: #95e2d1;
}

.inline-summary {
  background: #f0faf8;
  border: 1px solid #d8eeea;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: var(--gap);
  color: #103f3f;
  font-size: var(--step--1);
}

.error {
  color: var(--danger);
  font-size: var(--step--1);
  margin-top: 6px;
  display: none;
}

.success {
  display: none;
  background: #e8fff6;
  border: 1px solid #b7f2d6;
  color: #0f5132;
  padding: 14px 16px;
  border-radius: 12px;
  font-weight: 600;
  margin-top: 10px;
}

.show {
  display: block !important;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 720px) {
  /* .topic-row {
    grid-template-columns: 1fr;
  } */

  form .row {
    grid-template-columns: 1fr;
  }

  .acc-summary {
    text-align: left;
  }
}




/* Когда модалка открыта — запрещаем прокрутку фона */
body.no-scroll {
  position: fixed;
  overflow: hidden;
  inset: 0;
  /* фиксируем вьюпорт */
  width: 100%;
  padding-right: var(--sbw, 0px);
  /* компенсация полосы прокрутки, чтобы не прыгала разметка */
}

/* Базовые стили модалки */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  /* по умолчанию скрыта */
  z-index: 1000;
  background: rgba(0, 0, 0, .5);
  padding: clamp(12px, 4vw, 32px);
  /* чтобы панель не прилипала к краям */
}

.modal[aria-hidden="false"] {
  display: grid;
  place-items: center;
}

.privacy {
  margin-top: 40px;
}

.privacy .checkbox input {
  width: 200px;
} 


/* Внутренняя панель модалки (контейнер формы) */
.modal__panel {
  background: #fff;
  border-radius: 16px;
  width: min(700px, 96vw);
  max-height: 92vh;
  /* фоллбек для старых браузеров */
  display: flex;
  /* колонка: шапка/контент/футер */
  flex-direction: column;
  overflow: hidden;
  /* скролл будет у .modal__body */
}

/* Современные мобильные вьюпорты (без “подпрыгивания” адресной строки) */
@supports (max-height: 100dvh) {
  .modal__panel {
    max-height: 96dvh;
  }
}

/* Шапка и футер фиксируем внутри панели, контент — прокручиваемый */
.modal__header,
.modal__footer {
  padding: 16px 20px;
  background: #fff;
}

.modal__body {
  padding: 16px 20px;
  overflow: auto;
  /* <— скролл только у контента модалки */
  flex: 1 1 auto;
  /* растягивается и даёт месту для скролла */
  min-height: 0;
  /* важно для корректного расчёта flex-высоты */
}

/* --- Фикс, чтобы модалка всегда умещалась на экране и скроллилась внутри --- */

/* Заголовок/футер — фикс. высота, тело — скролл */
.modal__head,
.modal__header,
.modal__foot,
.modal__footer {
  flex: 0 0 auto;
}

.modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}


.modal__body {
  overflow: auto;
  flex: 1 1 auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
}

/* Фоллбек: если нет dvh/svh — используем vh */
.modal__card,
.modal__panel {
  max-height: 92vh;
}

@supports (height: 100dvh) {

  .modal__card,
  .modal__panel {
    max-height: 96dvh;
  }
}

@supports (height: 100svh) {

  /* small viewport height — спасает при адресной строке на мобилках */
  .modal__card,
  .modal__panel {
    max-height: 100svh;
  }
}

/* Критично для мобилок: убираем внешний паддинг у .modal, чтобы ничего не резалось по высоте */
@media (max-width: 480px) {
  .modal {
    padding: 0;
    /* внешний отступ съедал полезную высоту */
  }

  .modal__card,
  .modal__panel {
    width: 90vw;
    max-width: 100vw;
    max-height: 94dvh;
    /* на мобилках — во всю динамическую высоту */
    margin: 0;
  }

  /* Чтобы форма «дышала», делаем внутренние отступы у контента, а не у .modal */
  .modal__head,
  .modal__header,
  .modal__body,
  .modal__foot,
  .modal__footer {
    padding-inline: 16px;
    padding-block: 12px;
  }
}

/* Если хочешь оставить небольшие боковые поля на телефоне (без потери высоты) — раскомментируй:
@media (max-width: 480px) {
  .modal__card,
  .modal__panel { margin-inline: 8px; }
}
*/
@media (max-width: 480px) {
  .inline-summary {
    padding: 10px 12px;
    font-size: 14px;
  }
}














/* Блокируем прокрутку, пока идёт интро-анимация */
html.is-locked,
body.is-locked {
  overflow: hidden;
  height: 100%;
}

/* Чуть глушим рывки на мобильных */
html.is-locked {
  overscroll-behavior: none;
  touch-action: none;
}


footer {
  background: black;
  padding: 40px 0;
}

.footer__logos {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer__logos img {
  height: 44px;
  width: auto;
}