/* Форма регистрации — секция (на всю ширину экрана, контент по центру) */
.feedback-form {
  width: 100vw;
  max-width: none;
  position: relative;
  left: 50%;
  margin-left: -50vw;
  padding: 2rem 1rem;
  background: #f5f5f5;
  overflow-x: hidden;
  box-sizing: border-box;
}

/* Переопределение ограничений родительского контейнера */
.article__content-container .feedback-form,
.article__content .feedback-form {
  width: 100vw !important;
  max-width: none !important;
  left: 50% !important;
  margin-left: -50vw !important;
  position: relative !important;
}

/* Предотвращение горизонтального скролла на body */
body {
  overflow-x: hidden;
}

.feedback-form__container {
  max-width: 660px;
  margin: 0 auto;
  width: 100%;
  padding: 0 1rem;
  box-sizing: border-box;
}

.feedback-form__wrapper {
  display: block;
  width: 100%;
}

/* Левая колонка — преимущества */
.feedback-form__features {
  flex: 0 0 314px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #fff;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.feedback-form__logo {
  margin-bottom: 1.5rem;
}

.feedback-form__logo-img {
  display: block;
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.feedback-form__features-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.feedback-form__feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.feedback-form__feature-item:last-child {
  margin-bottom: 0;
}

.feedback-form__feature-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.feedback-form__feature-icon img {
  width: 24px;
  height: 24px;
  display: block;
}

.feedback-form__feature-text {
  font-size: 1rem;
  line-height: 1.5;
  color: #1a1a1a;
}

/* Форма — на всю ширину контейнера */
.feedback-form__form-column {
  width: 100%;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  box-sizing: border-box;
}

.feedback-form__main-title {
  margin: 0 0 1.25rem;
  font-size: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: #0c0c0c;
}

.feedback-form__info-text {
  margin-bottom: 1.5rem;
  padding: 1rem 1rem 1rem 1.25rem;
  background: #f2f2f2;
  border-left: 4px solid #cc0000;
  border-radius: 0 6px 6px 0;
}

.feedback-form__info-text p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: #404040;
}

/* Форма */
.feedback-form__form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.feedback-form__row {
  display: flex;
  gap: 1rem;
}

.feedback-form__row--name .feedback-form__field-group {
  flex: 1;
  min-width: 0;
}

.feedback-form__field-group {
  position: relative;
}

.feedback-form__input {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #d0d0d0;
  border-radius: 8px;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.feedback-form__input::placeholder {
  color: transparent;
}

.feedback-form__input:focus {
  outline: none;
  border-color: #cc0000;
  box-shadow: 0 0 0 2px rgba(204, 0, 0, 0.15);
}

.feedback-form__input:focus-visible {
  outline: 2px solid #cc0000;
  outline-offset: 2px;
}

.feedback-form__input:invalid:not(:placeholder-shown) {
  border-color: #cc0000;
}

/* Float-label: подпись красиво входит в рамку поля (Material Design style) */
.feedback-form__float-label {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #737373;
  pointer-events: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: left center;
  background: #fff;
  padding: 0 0.25rem;
}

.feedback-form__field-group--float .feedback-form__input {
  padding-top: 1rem;
  padding-bottom: 0.5rem;
}

.feedback-form__field-group--float .feedback-form__float-label {
  top: 0.875rem;
  transform: none;
  font-size: 1rem;
}

/* При фокусе или заполнении: label уезжает вверх и входит в рамку на половину */
.feedback-form__field-group--float .feedback-form__input:focus + .feedback-form__float-label,
.feedback-form__field-group--float .feedback-form__input:not(:placeholder-shown) + .feedback-form__float-label {
  top: 0;
  transform: translateY(-50%) scale(0.85);
  color: #cc0000;
  font-size: 0.875rem;
}

/* Кнопка */
.feedback-form__button {
  display: block;
  width: 100%;
  margin-top: 0.25rem;
  padding: 1rem 1.5rem;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  background: #cc0000;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.feedback-form__button:hover {
  background: #a30000;
}

.feedback-form__button:active {
  transform: scale(0.99);
}

.feedback-form__button:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(204, 0, 0, 0.35);
}

.feedback-form__button:focus-visible {
  outline: 3px solid #cc0000;
  outline-offset: 2px;
}

.feedback-form__button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

.feedback-form__main-title {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-weight: 800;
  color: var(--primitive-color-neutral-100, #fff);
  background-color: var(--primitive-color-brand-primary, #c00);
  margin: 0 0 5px 0;
  padding: 16px 24px;
  text-align: center;
  letter-spacing: 0.02em;
  /* text-transform: uppercase; */
  line-height: 1.2;
  border-radius: 8px;
  margin-bottom: 20px;
}

@media (max-width: 768px) {
  .feedback-form__main-title {
    margin-bottom: 1rem;
    font-size: clamp(1.25rem, 5vw, 1.5rem);
    padding: 0.875rem 1rem;
  }
}

/* Адаптивность для всех устройств */

/* Большие планшеты и маленькие десктопы (769px - 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
  .feedback-form__container {
    max-width: 660px;
    padding: 0 1.25rem;
  }
}

/* Планшеты (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
  .feedback-form {
    padding: 1.5rem 1rem;
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .article__content-container .feedback-form,
  .article__content .feedback-form {
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .feedback-form__container {
    max-width: 660px;
    padding: 0 1.25rem;
  }

  .feedback-form__form-column {
    width: 100%;
    max-width: 100%;
    padding: 1.5rem 1.25rem;
  }

  .feedback-form__main-title {
    font-size: 1.375rem;
    padding: 0.875rem 1rem;
    margin-bottom: 1rem;
  }

  .feedback-form__input {
    min-height: 44px;
    padding: 0.75rem 1rem;
    font-size: 16px; /* предотвращает зум при фокусе на iOS */
  }

  .feedback-form__button {
    min-height: 48px;
    padding: 0.875rem 1rem;
    font-size: 1rem;
  }
}

/* Мобильные устройства (до 480px) */
@media (max-width: 480px) {
  .feedback-form {
    padding: 1rem 0.75rem;
    background: #f5f5f5;
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .article__content-container .feedback-form,
  .article__content .feedback-form {
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .feedback-form__container {
    max-width: 100%;
    padding: 0;
  }

  .feedback-form__form-column {
    width: 100%;
    max-width: 100%;
    padding: 1.25rem 1rem;
    border-radius: 10px;
  }

  .feedback-form__main-title {
    font-size: 1.25rem;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    line-height: 1.3;
  }

  .feedback-form__info-text {
    margin-bottom: 1.25rem;
    padding: 0.75rem 0.875rem 0.75rem 1rem;
  }

  .feedback-form__info-text p {
    font-size: 0.875rem;
    line-height: 1.45;
  }

  .feedback-form__form {
    gap: 1.125rem;
  }

  .feedback-form__row {
    flex-direction: column;
    gap: 1.125rem;
  }

  .feedback-form__row--name {
    gap: 1.125rem;
  }

  .feedback-form__input {
    min-height: 48px;
    padding: 1rem 1rem 0.625rem;
    font-size: 16px; /* 16px — без зума при фокусе на iOS */
    -webkit-appearance: none;
    appearance: none;
    border-radius: 8px;
  }

  .feedback-form__field-group--float .feedback-form__input {
    padding-top: 1.25rem;
    padding-bottom: 0.5rem;
  }

  .feedback-form__field-group--float .feedback-form__float-label {
    top: 1rem;
    font-size: 1rem;
  }

  .feedback-form__field-group--float .feedback-form__input:focus + .feedback-form__float-label,
  .feedback-form__field-group--float .feedback-form__input:not(:placeholder-shown) + .feedback-form__float-label {
    font-size: 0.8125rem;
  }

  .feedback-form__button {
    padding: 1rem 1.25rem;
    font-size: 1rem;
    font-weight: 700;
    margin-top: 0.25rem;
    min-height: 52px;
    border-radius: 8px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
}

/* Очень маленькие мобильные (до 360px) */
@media (max-width: 360px) {
  .feedback-form {
    padding: 0.75rem 0.5rem;
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .article__content-container .feedback-form,
  .article__content .feedback-form {
    width: 100%;
    left: 0;
    margin-left: 0;
  }

  .feedback-form__container {
    padding: 0 0.75rem;
  }

  .feedback-form__form-column {
    padding: 1rem 0.875rem;
    border-radius: 8px;
  }

  .feedback-form__main-title {
    font-size: 1.125rem;
    padding: 0.625rem 0.875rem;
    margin-bottom: 0.875rem;
  }

  .feedback-form__info-text {
    padding: 0.625rem 0.75rem 0.625rem 0.875rem;
  }

  .feedback-form__info-text p {
    font-size: 0.8125rem;
  }

  .feedback-form__form {
    gap: 1rem;
  }

  .feedback-form__row--name {
    gap: 1rem;
  }

  .feedback-form__input {
    min-height: 44px;
    padding: 0.875rem 0.875rem 0.5rem;
  }

  .feedback-form__button {
    min-height: 48px;
    padding: 0.875rem 1rem;
    font-size: 0.9375rem;
  }
}

/* Ландшафтная ориентация на мобильных */
@media (max-width: 768px) and (orientation: landscape) {
  .feedback-form__form-column {
    width: 100%;
    max-width: 100%;
  }
}

/* Touch устройства - увеличенные области нажатия */
@media (hover: none) and (pointer: coarse) {
  .feedback-form__input {
    min-height: 44px;
  }

  .feedback-form__button {
    min-height: 48px;
  }
}

/* Высокие экраны (высота больше 900px) */
@media (min-height: 900px) {
  .feedback-form {
    padding: 3rem 1rem;
  }
}

/* Очень широкие экраны (больше 1400px) */
@media (min-width: 1400px) {
  .feedback-form {
    width: 100vw;
    left: 50%;
    margin-left: -50vw;
  }

  .article__content-container .feedback-form,
  .article__content .feedback-form {
    width: 100vw;
    left: 50%;
    margin-left: -50vw;
  }

  .feedback-form__container {
    max-width: 660px;
  }

  .feedback-form__form-column {
    width: 100%;
    max-width: 100%;
  }
}

/* Предотвращение горизонтального скролла */
@media (max-width: 768px) {
  .feedback-form__wrapper {
    width: 100%;
    max-width: 100%;
  }

  .feedback-form__form-column {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
}

/* Оптимизация для печати */
@media print {
  .feedback-form {
    background: #fff;
    padding: 1rem;
  }

  .feedback-form__form-column {
    box-shadow: none;
    border: 1px solid #ddd;
  }

  .feedback-form__button {
    display: none;
  }
}

/* Улучшение производительности на мобильных */
@media (max-width: 768px) {
  .feedback-form__form-column {
    will-change: transform;
    transform: translateZ(0);
  }
}

/* Validation icons */
.feedback-form__field-group::after {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.125rem;
  font-weight: 700;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.feedback-form__field-group.field-valid::after {
  content: '\2713';
  color: #cc0000;
  opacity: 1;
}

.feedback-form__field-group.field-invalid::after {
  content: '\2717';
  color: #cc0000;
  opacity: 1;
}

/* intlTelInput full width */
.feedback-form__field-group .iti {
  display: block;
  width: 100%;
}

.feedback-form__field-group--float .iti input[type="tel"] {
  width: 100%;
  padding-top: 1rem;
  padding-bottom: 0.5rem;
  font-size: 1rem;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #d0d0d0;
  border-radius: 8px;
  box-sizing: border-box;
}

.feedback-form__field-group .iti input[type="tel"]::placeholder {
  color: #999;
}

.feedback-form__field-group--float .iti ~ .feedback-form__float-label {
  top: 0;
  transform: translateY(-50%) scale(0.85);
  color: #555;
  font-size: 0.875rem;
  left: 72px;
}
