/* vkosmose-quiz-landing — стили в токенах донора v-kosmose.com.
   Гамма: текст #303030, ссылки/акцент #003366, кнопка #1B7CEA,
   врезка #FFE4E1, шапка #E5EEFD. Mobile-first. */

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: #303030;
  background: #fff;
  /* Футер прижат к низу вьюпорта даже при коротком контенте */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2 {
  font-family: 'Roboto Condensed', 'Arial Narrow', Arial, sans-serif;
  font-weight: 600;
  color: #303030;
  line-height: 1.25;
}

h1 { font-size: 24px; }
h2 { font-size: 20px; }

a { color: #003366; text-decoration: underline; font-weight: 600; }

/* ---------- Шапка / футер ---------- */

.site-header {
  background: #E5EEFD;
  border-bottom: 1px solid #C9DCF4;
  padding: 12px 16px;
  text-align: center;
}

.site-header__logo { height: 34px; vertical-align: middle; }

.site-footer {
  background: #E5EEFD;
  border-top: 1px solid #C9DCF4;
  margin-top: 32px;
  padding: 14px 16px;
  text-align: center;
  font-size: 13px;
  color: #5A6B7D;
}

/* ---------- Контент ---------- */

.page {
  max-width: 760px;
  width: 100%;
  margin: 0 auto;
  padding: 16px;
  flex: 1 0 auto;
}

.page h1 { margin: 4px 0 8px; }

.lead { margin-bottom: 12px; }

.info-box {
  background: #FFE4E1;
  border-radius: 6px;
  padding: 10px 14px;
  margin-bottom: 14px;
  font-size: 14px;
}

.info-box b { display: block; }

/* ---------- Карточка квиза ---------- */

.quiz-card {
  border: 1px solid #C9DCF4;
  border-radius: 10px;
  padding: 16px;
  background: #fff;
}

.quiz-card__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 24px;
  margin-bottom: 10px;
}

.quiz-back {
  background: none;
  border: none;
  color: #003366;
  font: 600 14px Arial, sans-serif;
  text-decoration: underline;
  cursor: pointer;
  padding: 2px 4px;
}

.quiz-progress {
  margin-left: auto;
  font-size: 13px;
  color: #5A6B7D;
}

.quiz-question h2 { margin-bottom: 4px; }

.quiz-hint { color: #5A6B7D; font-size: 14px; margin-bottom: 12px; }

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

.quiz-option {
  display: block;
  width: 100%;
  text-align: left;
  background: #fff;
  border: 1.5px solid #1B7CEA;
  border-radius: 10px;
  padding: 12px 14px;
  cursor: pointer;
  font-family: Arial, sans-serif;
  transition: background-color .12s ease, color .12s ease;
}

.quiz-option__title { display: block; font-size: 16px; font-weight: 600; color: #003366; }
.quiz-option__sub { display: block; font-size: 13px; color: #5A6B7D; margin-top: 2px; }

.quiz-option:active,
.quiz-option.is-selected { background: #1B7CEA; }
.quiz-option:active .quiz-option__title,
.quiz-option.is-selected .quiz-option__title { color: #fff; }
.quiz-option:active .quiz-option__sub,
.quiz-option.is-selected .quiz-option__sub { color: #DCEAFB; }

@media (hover: hover) {
  .quiz-option:hover { background: #EAF2FD; }
  .quiz-option.is-selected:hover { background: #1B7CEA; }
}

.quiz-note {
  margin-top: 14px;
  font-size: 13px;
  color: #5A6B7D;
  text-align: center;
}

/* ---------- Лоадер ---------- */

.loader { text-align: center; padding: 40px 16px; }

.loader h2 { margin-bottom: 6px; }
.loader p { color: #5A6B7D; font-size: 14px; }

.loader__spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto 16px;
  border: 4px solid #E5EEFD;
  border-top-color: #1B7CEA;
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

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

#form-screen h2 { margin-bottom: 4px; }

.form-echo { font-size: 13px; color: #5A6B7D; margin-bottom: 10px; }

.form-intro { margin-bottom: 14px; }

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

.form-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #303030;
  margin-bottom: 4px;
}

.form-field input[type="text"],
.form-field input[type="email"] {
  width: 100%;
  border: 1px solid #B9CFE4;
  border-radius: 8px;
  padding: 11px 12px;
  font: 16px Arial, sans-serif;
  color: #303030;
}

.form-field input:focus { outline: 2px solid #1B7CEA; outline-offset: -1px; }

.form-field input.is-error { border-color: #D33C2E; }

.form-field__error {
  display: none;
  font-size: 12px;
  color: #D33C2E;
  margin-top: 3px;
}

.form-field__error.is-visible { display: block; }

/* Телефонный инпут (a7-phone из phone.js) */

.a7-phone {
  display: flex;
  position: relative;
  border: 1px solid #B9CFE4;
  border-radius: 8px;
  background: #fff;
}

.phone-mount .a7-phone.is-error,
.a7-phone.is-error { border-color: #D33C2E; }

.a7-phone__country {
  display: flex;
  align-items: center;
  gap: 4px;
  border: none;
  border-right: 1px solid #B9CFE4;
  background: #EAF2FD;
  border-radius: 8px 0 0 8px;
  padding: 0 10px;
  font: 15px Arial, sans-serif;
  color: #303030;
  cursor: pointer;
}

.a7-phone__input {
  flex: 1;
  min-width: 0;
  border: none;
  border-radius: 0 8px 8px 0;
  padding: 11px 12px;
  font: 16px Arial, sans-serif;
  color: #303030;
}

.a7-phone__input:focus { outline: 2px solid #1B7CEA; outline-offset: -1px; }

.a7-phone__dropdown {
  position: absolute;
  z-index: 20;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  max-height: 260px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid #B9CFE4;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0, 51, 102, .15);
}

.a7-phone__item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  border: none;
  background: none;
  padding: 10px 12px;
  font: 15px Arial, sans-serif;
  color: #303030;
  cursor: pointer;
  text-align: left;
}

.a7-phone__item:hover { background: #EAF2FD; }

.a7-phone__item-dial { margin-left: auto; color: #5A6B7D; }

/* Согласие */

.consent {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 13px;
  cursor: pointer;
}

.consent input { margin-top: 2px; width: 16px; height: 16px; accent-color: #1B7CEA; }

/* ---------- Кнопка CTA ---------- */

.cta-btn {
  display: block;
  width: 100%;
  background: #1B7CEA;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 14px 16px;
  font: 700 17px 'Roboto Condensed', 'Arial Narrow', Arial, sans-serif;
  letter-spacing: .4px;
  text-transform: uppercase;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.cta-btn:disabled { opacity: .5; cursor: default; }

.cta-btn--link { margin-top: 16px; }

.form-note {
  font-size: 13px;
  color: #5A6B7D;
  text-align: center;
}

/* ---------- Success ---------- */

.success { text-align: center; padding: 32px 16px; }

.success__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: #1B7CEA;
  color: #fff;
  font-size: 30px;
  line-height: 56px;
}

.success h2 { margin-bottom: 6px; }
.success p { color: #5A6B7D; }

/* ---------- Десктоп ---------- */

@media (min-width: 768px) {
  body { font-size: 16px; }
  h1 { font-size: 30px; }
  h2 { font-size: 24px; }
  .page { padding: 28px 24px; }
  .site-header__logo { height: 42px; }
  .quiz-card { padding: 24px; }
  .cta-btn { width: auto; min-width: 320px; margin-left: auto; margin-right: auto; }
}
