/* ==========================================================================
   Курс первой помощи «Первые десять минут»
   Визуальная идея: ламинированный учебный плакат. Плоские пастельные поля,
   толстые скруглённые пиктограммы, крупные цифры только там, где содержание
   действительно последовательность (расписание, алгоритм). Единственное
   насыщенное пятно на странице — фотография отработки СЛР.
   ========================================================================== */

:root {
  /* Пастельная палитра: холодный «клинический» мел + одно тёплое поле */
  --paper:      #E9EDEC;
  --paper-deep: #DDE4E2;
  --card:       #FAFBFA;
  --ink:        #17252B;
  --ink-2:      #4C5D64;
  --ink-3:      #7C8B91;
  --mint:       #C9DED4;
  --mint-soft:  #E1EDE7;
  --rose:       #F2C6C0;
  --rose-soft:  #FAE4E1;
  --sand:       #E6DAC6;
  --sand-soft:  #F2EADC;
  --deep:       #2E5C55;   /* кнопки и ссылки: тёмный, а не яркий */
  --deep-hover: #234842;
  --line:       #C5D0CE;

  --measure: 66ch;
  --radius:   14px;
  --radius-s:  8px;

  --step--1: clamp(0.82rem, 0.79rem + 0.15vw, 0.9rem);
  --step-0:  clamp(1rem, 0.96rem + 0.2vw, 1.12rem);
  --step-1:  clamp(1.2rem, 1.12rem + 0.4vw, 1.45rem);
  --step-2:  clamp(1.5rem, 1.34rem + 0.8vw, 2rem);
  --step-3:  clamp(1.9rem, 1.6rem + 1.5vw, 2.9rem);
  --step-4:  clamp(2.4rem, 1.8rem + 3vw, 4.5rem);
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Golos Text", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: var(--step-0);
  line-height: 1.6;
  font-feature-settings: "ss01";
}

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

h1, h2, h3 { margin: 0; line-height: 1.08; font-weight: 800; letter-spacing: -0.02em; }
p  { margin: 0 0 1em; max-width: var(--measure); }
ul { margin: 0; padding: 0; list-style: none; }

a { color: var(--deep); }

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

/* --- Каркас ------------------------------------------------------------ */

.wrap {
  width: min(100% - 2.5rem, 1180px);
  margin-inline: auto;
}

.section { padding-block: clamp(3rem, 7vw, 6rem); }
.section--tint  { background: var(--paper-deep); }
.section--mint  { background: var(--mint-soft); }
.section--sand  { background: var(--sand-soft); }

.section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.5rem;
  margin-bottom: clamp(1.75rem, 4vw, 3rem);
}

.section__title { font-size: var(--step-3); }

.section__note {
  color: var(--ink-3);
  font-size: var(--step--1);
  max-width: 34ch;
  margin: 0;
}

/* --- Шапка ------------------------------------------------------------- */

.topbar {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand__mark {
  width: 26px;
  height: 26px;
  flex: none;
  background: var(--rose);
  border-radius: 6px;
  position: relative;
}

/* Крест — пастельный, тонкий, не «красный крест» организации */
.brand__mark::before,
.brand__mark::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  background: var(--card);
  border-radius: 1px;
}
.brand__mark::before { width: 12px; height: 3.5px; }
.brand__mark::after  { width: 3.5px; height: 12px; }

.topbar__meta {
  color: var(--ink-2);
  font-size: var(--step--1);
}

/* --- Первый экран ------------------------------------------------------ */

.hero { padding-block: clamp(3rem, 8vw, 6.5rem) clamp(2rem, 5vw, 3.5rem); }

.hero__kicker {
  font-size: var(--step-1);
  font-weight: 500;
  color: var(--ink-2);
  max-width: 30ch;
  margin-bottom: 1.4rem;
}

.hero__title {
  font-size: var(--step-4);
  max-width: 17ch;
  margin-bottom: 1.5rem;
}

.hero__lede {
  font-size: var(--step-1);
  color: var(--ink-2);
  max-width: 46ch;
  line-height: 1.45;
}

.hero__figures {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--line);
}

.figure__value {
  font-size: var(--step-2);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
}

.figure__label {
  font-size: var(--step--1);
  color: var(--ink-3);
  max-width: 22ch;
  margin: 0.45rem 0 0;
}

/* --- Талон: дата, время, место ----------------------------------------- */

.ticket {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.ticket__cell {
  padding: clamp(1.25rem, 3vw, 1.9rem);
  border-top: 1px solid var(--line);
}

.ticket__cell:first-child { border-top: 0; }

.ticket__label {
  font-size: var(--step--1);
  color: var(--ink-3);
  margin: 0 0 0.35rem;
}

.ticket__value {
  font-size: var(--step-1);
  font-weight: 700;
  line-height: 1.25;
}

.ticket__sub {
  margin: 0.35rem 0 0;
  color: var(--ink-2);
  font-size: var(--step--1);
}

@media (min-width: 760px) {
  .ticket__cell { border-top: 0; border-left: 1px solid var(--line); }
  .ticket__cell:first-child { border-left: 0; }
}

/* --- Описание ----------------------------------------------------------- */

.prose { max-width: var(--measure); }
.prose p { font-size: var(--step-0); }

.prose__lead {
  font-size: var(--step-1);
  line-height: 1.5;
  color: var(--ink);
}

.two-col {
  display: grid;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .two-col { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
}

.checklist li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 0.9rem;
  max-width: 48ch;
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.42em;
  width: 13px;
  height: 7px;
  border-left: 3px solid var(--deep);
  border-bottom: 3px solid var(--deep);
  border-radius: 1px;
  transform: rotate(-45deg);
}

/* --- Программа: расписание = настоящая последовательность --------------- */

.day { margin-bottom: clamp(2rem, 4vw, 3rem); }

.day__head {
  display: flex;
  align-items: baseline;
  gap: 0.9rem;
  padding-bottom: 0.8rem;
  border-bottom: 2px solid var(--ink);
  margin-bottom: 1.25rem;
}

.day__num {
  font-size: var(--step-2);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.day__title { font-size: var(--step-1); font-weight: 700; }

.day__hours { margin-left: auto; color: var(--ink-3); font-size: var(--step--1); }

.slot {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.4rem 1.25rem;
  padding-block: 0.9rem;
  border-bottom: 1px solid var(--line);
}

.slot:last-child { border-bottom: 0; }

.slot__time {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--ink-2);
  padding-top: 0.15em;
}

.slot__name { font-weight: 600; }

.slot__desc {
  grid-column: 2;
  margin: 0.25rem 0 0;
  color: var(--ink-2);
  font-size: var(--step--1);
  max-width: 60ch;
}

.slot--break { opacity: 0.6; }

@media (max-width: 560px) {
  .slot { grid-template-columns: 1fr; }
  .slot__desc { grid-column: 1; }
}

/* --- Виды травм --------------------------------------------------------- */

.injuries {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  /* 300px даёт ровно три колонки на широком экране: восемь плиток, где первая
     занимает две, укладываются в три полных ряда без дыр. */
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.injury {
  background: var(--card);
  padding: clamp(1.25rem, 2.5vw, 1.75rem);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.injury--wide { grid-column: span 1; }

@media (min-width: 900px) {
  .injury--wide { grid-column: span 2; }
}

.injury__icon { width: 44px; height: 44px; flex: none; }

.injury__name { font-size: var(--step-1); font-weight: 700; }

.injury__text {
  margin: 0;
  color: var(--ink-2);
  font-size: var(--step--1);
  max-width: 44ch;
}

.injury__skill {
  margin-top: auto;
  padding-top: 0.6rem;
  color: var(--ink-3);
  font-size: var(--step--1);
  border-top: 1px dashed var(--line);
}

/* --- Юридический блок: голос документа ---------------------------------- */

.legal { font-family: "PT Serif", Georgia, "Times New Roman", serif; }

.legal .section__title { font-family: inherit; font-weight: 700; }

.qa {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.25rem);
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.qa__item { max-width: 46ch; }

.qa__q {
  font-size: var(--step-1);
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.25;
}

.qa__a { margin-bottom: 0.6rem; line-height: 1.7; }

.qa__ref {
  font-size: var(--step--1);
  color: var(--ink-3);
  font-style: italic;
  border-left: 2px solid var(--sand);
  padding-left: 0.75rem;
}

/* --- Фотография: единственное насыщенное пятно -------------------------- */

.photo { background: var(--ink); }

.photo__img {
  width: 100%;
  height: clamp(280px, 52vh, 560px);
  object-fit: cover;
  object-position: center 58%;
}

.photo__caption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding-block: 1rem 1.25rem;
  color: #C3D0CE;
  font-size: var(--step--1);
}

.photo__caption p { margin: 0; max-width: 52ch; }
.photo__caption a { color: #9FB6B2; }

/* --- Инструкторы -------------------------------------------------------- */

.people {
  display: grid;
  gap: clamp(1.75rem, 3vw, 2.5rem);
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.person {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 1rem;
  align-content: start;
}

.person__mono {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: var(--step-1);
  letter-spacing: -0.02em;
  color: var(--ink);
}

.person:nth-child(1) .person__mono { background: var(--mint); }
.person:nth-child(2) .person__mono { background: var(--rose); }
.person:nth-child(3) .person__mono { background: var(--sand); }

.person__name { font-size: var(--step-1); font-weight: 700; margin-bottom: 0.15rem; }
.person__role { color: var(--ink-2); font-weight: 600; font-size: var(--step--1); margin-bottom: 0.6rem; }
.person__regalia li {
  position: relative;
  padding-left: 1rem;
  margin-bottom: 0.4rem;
  color: var(--ink-2);
  font-size: var(--step--1);
  max-width: 40ch;
}
.person__regalia li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 2px;
  background: var(--ink-3);
}

/* --- Тарифы ------------------------------------------------------------- */

.plans {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  align-items: start;
}

.plan {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.plan--pick {
  background: var(--mint-soft);
  border-color: var(--deep);
}

.plan__badge {
  align-self: flex-start;
  background: var(--deep);
  color: var(--card);
  font-size: var(--step--1);
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 100px;
}

.plan__name { font-size: var(--step-1); font-weight: 700; }

.plan__price {
  font-size: var(--step-2);
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.plan__price span { font-size: var(--step--1); font-weight: 500; color: var(--ink-3); }

.plan__list li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
  font-size: var(--step--1);
  color: var(--ink-2);
}

.plan__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 10px;
  height: 5px;
  border-left: 2px solid var(--deep);
  border-bottom: 2px solid var(--deep);
  transform: rotate(-45deg);
}

.plan__cta { margin-top: auto; }

/* --- Кнопки ------------------------------------------------------------- */

.btn {
  display: inline-block;
  font: inherit;
  font-weight: 600;
  text-align: center;
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius-s);
  border: 1px solid var(--deep);
  background: var(--deep);
  color: var(--card);
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease;
}

.btn:hover { background: var(--deep-hover); border-color: var(--deep-hover); }

.btn--ghost { background: transparent; color: var(--deep); }
.btn--ghost:hover { background: var(--mint-soft); }

.btn--wide { width: 100%; }

.btn--lg { font-size: var(--step-1); padding: 1.05rem 2.2rem; }

/* --- Финальный призыв --------------------------------------------------- */

.finale {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: clamp(2rem, 4vw, 3rem);
  border-top: 2px solid var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.finale__text { max-width: 44ch; }
.finale__text p { margin: 0.5rem 0 0; color: var(--ink-2); font-size: var(--step--1); }
.finale__title { font-size: var(--step-2); }

/* Липкая панель — только в варианте B эксперимента */
.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  background: var(--card);
  border-top: 1px solid var(--line);
  padding: 0.7rem 0 calc(0.7rem + env(safe-area-inset-bottom, 0px));
  transform: translateY(110%);
  transition: transform 0.25s ease;
}

.sticky-cta.is-visible { transform: translateY(0); }

.sticky-cta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.sticky-cta__text { font-size: var(--step--1); color: var(--ink-2); }
.sticky-cta__text b { color: var(--ink); }

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

.footer {
  background: var(--paper-deep);
  border-top: 1px solid var(--line);
  padding-block: 2rem 2.5rem;
  color: var(--ink-3);
  font-size: var(--step--1);
}

.footer p { max-width: 70ch; margin-bottom: 0.5rem; }

/* --- Модальное окно заявки ---------------------------------------------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(23, 37, 43, 0.55);
  overflow-y: auto;
}

.modal__card {
  background: var(--card);
  border-radius: var(--radius);
  width: min(100%, 460px);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  box-shadow: 0 24px 60px rgba(23, 37, 43, 0.28);
  position: relative;
}

.modal__title { font-size: var(--step-2); margin-bottom: 0.4rem; }

.modal__sub { color: var(--ink-2); font-size: var(--step--1); margin-bottom: 1.5rem; }

.modal__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}

.modal__close:hover { background: var(--paper-deep); }

.field { margin-bottom: 1.1rem; }

.field__label {
  display: block;
  font-size: var(--step--1);
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.field__input {
  width: 100%;
  font: inherit;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  background: var(--paper);
  color: var(--ink);
}

.field__input:focus { border-color: var(--deep); background: var(--card); }

.field__error {
  display: none;
  color: #A2453C;
  font-size: var(--step--1);
  margin-top: 0.3rem;
}

.field.is-invalid .field__input { border-color: #A2453C; }
.field.is-invalid .field__error { display: block; }

.form__note {
  font-size: var(--step--1);
  color: var(--ink-3);
  margin: 1rem 0 0;
}

.form__status {
  margin: 0 0 1rem;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-s);
  background: var(--rose-soft);
  color: #7E3830;
  font-size: var(--step--1);
}

.success { text-align: left; }
.success__title { font-size: var(--step-2); margin-bottom: 0.6rem; }

[hidden] { display: none !important; }

/* --- Доступность и движение --------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

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