/* ── Страница «Как пользоваться сервисом» ── */

.main--how {
  max-width: 760px;
  margin: 0 auto;
  padding: 32px 20px 60px;
}

.how__header {
  text-align: center;
  margin-bottom: 36px;
}

.how__header h1 {
  font-size: 1.8rem;
  color: var(--text-main);
  margin-bottom: 8px;
}

.how__subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
}

.how__list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* ── Карточка-аккордеон ── */

.how__item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.how__item[open] {
  border-color: var(--main-green);
  box-shadow: 0 4px 16px rgba(65, 145, 82, 0.10);
}

.how__item-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  list-style: none;
  user-select: none;
  transition: background-color 0.2s ease;
}

.how__item-header::-webkit-details-marker {
  display: none;
}

.how__item-header:hover {
  background-color: var(--green-light);
}

.how__item-number {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--green-light);
  color: var(--green-dark);
  font-weight: bold;
  font-size: 15px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.how__item[open] .how__item-number {
  background: var(--main-green);
  color: #fff;
}

.how__item-title {
  flex: 1;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.4;
}

.how__item-chevron {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  transition: transform 0.3s ease, color 0.2s ease;
}

.how__item[open] .how__item-chevron {
  transform: rotate(180deg);
  color: var(--main-green);
}

/* ── Контент карточки ── */

.how__item-content {
  padding: 4px 20px 24px;
  line-height: 1.6;
  color: var(--text-main);
  animation: howFadeIn 0.3s ease forwards;
}

@keyframes howFadeIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.how__item-content > p {
  margin: 8px 0;
}

.how__item-content h3 {
  font-size: 1.1rem;
  color: var(--text-main);
  margin: 16px 0 8px;
}

.how__item-content h4 {
  font-size: 1rem;
  color: var(--green-dark);
  margin: 14px 0 6px;
}

.how__item-content ul,
.how__item-content ol {
  padding-left: 22px;
  margin: 8px 0;
}

.how__item-content li {
  margin-bottom: 6px;
}

/* ── Видео ── */

.how__video {
  position: relative;
  width: 100%;
  max-width: 480px;
  aspect-ratio: 16 / 9;
  margin: 4px 0 16px;
  border-radius: 8px;
  overflow: hidden;
}

.how__video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* ── Адаптивность ── */

@media (max-width: 600px) {
  .main--how {
    padding: 20px 12px 40px;
  }

  .how__header h1 {
    font-size: 1.4rem;
  }

  .how__subtitle {
    font-size: 0.95rem;
  }

  .how__item-header {
    padding: 14px 16px;
    gap: 12px;
  }

  .how__item-number {
    width: 28px;
    height: 28px;
    font-size: 14px;
  }

  .how__item-title {
    font-size: 14px;
  }

  .how__item-content {
    padding: 4px 16px 20px;
  }

  .how__item-content h3 {
    font-size: 1rem;
  }

  .how__item-content h4 {
    font-size: 0.95rem;
  }
}
