/* ================================================
   Quiz 2 — Dynamic Branching Quiz
   Mobile-first responsive
   Brand: #0800dd (purple), #ffc200 (yellow)
   ================================================ */

/* --- Section wrapper --- */
.quiz2 {
  padding: 10px 0 40px;
}

.quiz2 .container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ================================================
   1. Quiz Intro
   ================================================ */
.quiz2__intro {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
  padding: 12px 20px 28px;
}

.quiz2__intro-title,
.quiz2__title {
  font-size: 28px;
  font-weight: 700;
  color: #0800dd;
  line-height: 1.25;
  margin-bottom: 12px;
}

.quiz2__intro-subtitle,
.quiz2__subtitle {
  font-size: 17px;
  color: #555;
  line-height: 1.55;
  margin-bottom: 12px;
}

.quiz2__social-proof {
  font-size: 13px;
  color: #999;
  margin-top: 16px;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  text-align: center;
}

.quiz2__social-proof span {
  white-space: nowrap;
}

.quiz2__social-proof-dot,
.quiz2__sp-sep {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #ccc;
  display: inline-block;
  flex-shrink: 0;
}

.quiz2__start-btn,
.quiz2__start {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 48px;
  border-radius: 28px;
  background: #ffc200;
  color: #000;
  font-family: 'TT', sans-serif;
  font-size: 17px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background .2s, transform .15s, box-shadow .2s;
  box-shadow: 0 4px 16px rgba(255, 194, 0, .3);
}

.quiz2__start-btn:hover,
.quiz2__start:hover {
  background: #e6af00;
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(255, 194, 0, .4);
}

.quiz2__start-btn:active,
.quiz2__start:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(255, 194, 0, .25);
}

/* ================================================
   2. Quiz Body
   ================================================ */
.quiz2__body {
  display: block;
  max-width: 900px;
  margin: 0 auto;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 4px 32px rgba(0, 0, 0, .08);
  position: relative;
  overflow: hidden;
}

.quiz2__body.active {
  display: block;
}

/* --- Header (back + step label) --- */
.quiz2__header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 20px 0;
}

.quiz2__back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f5f5f5;
  border: none;
  cursor: pointer;
  transition: background .2s;
  flex-shrink: 0;
  color: #555;
}

.quiz2__back:hover {
  background: #eaeaea;
  color: #222;
}

.quiz2__back svg {
  width: 18px;
  height: 18px;
}

.quiz2__step-label {
  font-size: 14px;
  color: #999;
  font-weight: 500;
}

/* --- Content area --- */
.quiz2__content {
  padding: 24px 20px 20px;
  position: relative;
  min-height: 280px;
}

/* ================================================
   3. Questions & Options
   ================================================ */
.quiz2__question {
  font-size: 20px;
  font-weight: 700;
  color: #222;
  line-height: 1.35;
  margin-bottom: 20px;
}

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

.quiz2__option {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 2px solid #e8e8e8;
  border-radius: 14px;
  cursor: pointer;
  transition: border-color .2s, background .2s, box-shadow .2s;
  font-size: 16px;
  color: #222;
  background: #fff;
  user-select: none;
  -webkit-user-select: none;
}

@media (hover: hover) {
  .quiz2__option:hover {
    border-color: #0800dd;
    background: rgba(8, 0, 221, .03);
  }
}

.quiz2__option--selected {
  border-color: #0800dd;
  background: rgba(8, 0, 221, .06);
  box-shadow: 0 0 0 1px rgba(8, 0, 221, .15);
}

.quiz2__option--selected .quiz2__option-text {
  font-weight: 600;
}

.quiz2__option-img {
  width: 60px;
  height: 60px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: #f5f5f5;
}

.quiz2__option--gif .quiz2__option-img {
  border-radius: 10px;
  border: 1px solid #eee;
}

.quiz2__option-text {
  flex: 1;
  line-height: 1.4;
  font-weight: 700;
}
.quiz2__option-text span {
  display: inline-block;
  font-weight: 400;
}

.quiz2__option-text span {
  font-weight: 400;
}

.quiz2__option-text small {
  display: block;
  font-size: 13px;
  color: #888;
  margin-top: 2px;
  font-weight: 400;
}

/* --- Hidden radio/checkbox inside option --- */
.quiz2__option input[type="radio"],
.quiz2__option input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}

/* ================================================
   4. Expert Toast (mobile) — slide up from bottom
   ================================================ */
.quiz2__expert {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 12px 16px;
  pointer-events: none;
  display: flex;
  justify-content: center;
}

.quiz2__expert-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  background: rgba(30, 30, 40, .88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 14px;
  max-width: 400px;
  width: 100%;
  transform: translateY(100%);
  opacity: 0;
  transition: transform .35s cubic-bezier(.22, .61, .36, 1), opacity .35s ease;
  pointer-events: auto;
}

.quiz2__expert-inner.visible {
  transform: translateY(0);
  opacity: 1;
}

.quiz2__expert-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, .25);
}

.quiz2__expert-text {
  font-size: 14px;
  color: #fff;
  line-height: 1.4;
}

.quiz2__expert-name {
  font-weight: 600;
  font-size: 13px;
  color: rgba(255, 255, 255, .7);
  margin-bottom: 2px;
}

/* ================================================
   5. Progress Bar
   ================================================ */
.quiz2__progress {
  height: 7px;
  background: #f0f0f0;
  width: 100%;
}

.quiz2__progress-bar {
  height: 100%;
  width: 0;
  transition: width .3s ease;
  background-color: #0600b8;
  background-image: repeating-linear-gradient(
    45deg,
    rgba(255, 255, 255, .45),
    rgba(255, 255, 255, .45) 5px,
    transparent 5px,
    transparent 10px
  );
  background-size: 14px 14px;
  animation: quiz2-stripe 0.5s linear infinite;
}

@keyframes quiz2-stripe {
  0% { background-position: 0 0; }
  100% { background-position: 14px 0; }
}

/* ================================================
   6. Styled Checkboxes (pool / multi-select)
   ================================================ */
.quiz2__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border: 2px solid #e8e8e8;
  border-radius: 14px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  user-select: none;
  -webkit-user-select: none;
}

.quiz2__checkbox:hover {
  border-color: #0800dd;
  background: rgba(8, 0, 221, .03);
}

.quiz2__checkbox--checked {
  border-color: #0800dd;
  background: rgba(8, 0, 221, .06);
}

.quiz2__checkbox-box {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background .2s, border-color .2s;
  margin-top: 1px;
}

.quiz2__checkbox--checked .quiz2__checkbox-box {
  background: #0800dd;
  border-color: #0800dd;
}

.quiz2__checkbox-box svg {
  width: 14px;
  height: 14px;
  opacity: 0;
  transition: opacity .15s;
  color: #fff;
}

.quiz2__checkbox--checked .quiz2__checkbox-box svg {
  opacity: 1;
}

.quiz2__checkbox-label {
  flex: 1;
  font-size: 16px;
  color: #222;
  line-height: 1.4;
}

.quiz2__checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}

/* ================================================
   7. Contact Form (final step)
   ================================================ */
.quiz2__summary {
  background: #f8f7f4;
  border-radius: 12px;
  padding: 20px 20px 12px;
  margin-bottom: 12px;
  font-size: 16px;
  color: #555;
  line-height: 1.8;
}

.quiz2__summary strong {
  color: #222;
  font-weight: 600;
}

.quiz2__summary p,
.quiz2__summary li,
.quiz2__summary div {
  margin-bottom: 6px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(0, 0, 0, .06);
}

.quiz2__summary p:last-child,
.quiz2__summary li:last-child,
.quiz2__summary div:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.quiz2__scheme {
  margin-bottom: 20px;
  border-radius: 14px;
  overflow: hidden;
  background: #fafafa;
  border: 1px solid #eee;
  padding: 16px;
  text-align: center;
  width: 100%;
  min-height: 200px;
  margin: 16px 0;
}

.quiz2__scheme svg {
  width: 100%;
  height: auto;
  display: block;
  max-width: 500px;
}

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

.quiz2__input {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid #e0e0e0;
  border-radius: 14px;
  font-family: 'TT', sans-serif;
  font-size: 17px;
  color: #222;
  background: #faf9f6;
  transition: border-color .2s, background .2s;
  box-sizing: border-box;
}

.quiz2__input:focus {
  outline: none;
  border-color: #0800dd;
  background: #fff;
}

.quiz2__input::placeholder {
  color: #aaa;
}

.quiz2__input--error {
  border-color: #e74c3c;
}

.quiz2__consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: #888;
  line-height: 1.45;
}

.quiz2__consent input[type="checkbox"] {
  margin-top: 2px;
  accent-color: #0800dd;
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.quiz2__consent a {
  color: #0800dd;
  text-decoration: none;
}

.quiz2__consent a:hover {
  text-decoration: underline;
}

/* --- Photo Upload (compact link-style) --- */
.quiz2__upload {
  border: none;
  border-radius: 0;
  padding: 8px 0;
  text-align: left;
  cursor: pointer;
  transition: color .2s;
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.quiz2__upload::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 16px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21.44 11.05l-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  flex-shrink: 0;
}

.quiz2__upload:hover {
  border-color: transparent;
  background: transparent;
}

.quiz2__upload-icon {
  display: none;
}

.quiz2__upload-text {
  font-size: 14px;
  color: #888;
  line-height: 1.4;
}

.quiz2__upload-text strong {
  color: #888;
  font-weight: 500;
}

.quiz2__upload:hover .quiz2__upload-text,
.quiz2__upload:hover .quiz2__upload-text strong {
  color: #0800dd;
}

.quiz2__upload-hint {
  font-size: 12px;
  color: #bbb;
  margin-top: 2px;
}

.quiz2__upload,
.quiz2__upload *,
.quiz2__upload-btn,
.quiz2__upload-btn * {
  cursor: pointer;
}

.quiz2__upload input[type="file"] {
  display: none;
}

/* Thumbnails / Upload previews */
.quiz2__thumbnails,
.quiz2__upload-previews {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.quiz2__thumb,
.quiz2__upload-preview {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  border: 2px solid #eee;
}

.quiz2__thumb img,
.quiz2__upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.quiz2__thumb-remove,
.quiz2__upload-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(0, 0, 0, .55);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  border: none;
  transition: background .2s;
}

.quiz2__thumb-remove:hover,
.quiz2__upload-remove:hover {
  background: rgba(220, 50, 50, .8);
}

/* --- Submit Button --- */
.quiz2__submit {
  width: 100%;
  padding: 18px 36px;
  border-radius: 28px;
  background: #ffc200;
  color: #000;
  font-family: 'TT', sans-serif;
  font-size: 17px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background .2s, transform .15s, box-shadow .2s;
  box-shadow: 0 4px 16px rgba(255, 194, 0, .25);
  position: relative;
  overflow: hidden;
}

.quiz2__submit:hover:not(:disabled) {
  background: #e6af00;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255, 194, 0, .35);
}

.quiz2__submit:active:not(:disabled) {
  transform: translateY(0);
}

.quiz2__submit:not(:disabled) {
  animation: submit-pulse 2s ease-in-out infinite;
}

@keyframes submit-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 120, 0, 0.6); }
  50% { box-shadow: 0 0 0 12px rgba(255, 100, 0, 0); }
}

.quiz2__submit:disabled {
  background: #ffc200;
  color: #000;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(255, 194, 0, .25);
  transform: none;
}

/* Loading state */
.quiz2__submit--loading {
  color: transparent;
  pointer-events: none;
}

.quiz2__submit--loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  margin: -11px 0 0 -11px;
  border: 3px solid rgba(0, 0, 0, .2);
  border-top-color: #000;
  border-radius: 50%;
  animation: quiz2-spin .6s linear infinite;
}

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

/* ================================================
   8. Success Screen
   ================================================ */
.quiz2__success {
  display: none;
  text-align: center;
  padding: 16px 12px;
}

.quiz2__success.active {
  display: block;
  animation: quiz2-fadeIn .4s ease;
}

.quiz2__success-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0800dd 0%, #6300db 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: quiz2-checkPop .5s cubic-bezier(.22, .61, .36, 1) .15s both;
}

.quiz2__success-icon svg {
  width: 22px;
  height: 22px;
  color: #fff;
}

@keyframes quiz2-checkPop {
  0% { transform: scale(0); opacity: 0; }
  60% { transform: scale(1.15); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes quiz2-fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.quiz2__success-title {
  font-size: 20px;
  font-weight: 700;
  color: #0800dd;
  margin: 8px 0;
}

.quiz2__success-text {
  font-size: 14px;
  color: #555;
  line-height: 1.5;
  margin-bottom: 16px;
}

.quiz2__success-pdf,
.quiz2__pdf-link {
  display: inline-block;
  background: #22c55e;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 14px 32px;
  border-radius: 25px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  position: relative;
  font-family: 'TT', sans-serif;
  animation: pdf-pulse 2s ease-in-out infinite;
  transition: background .2s, transform .15s;
  margin-top: 20px;
}

.quiz2__success-pdf:hover,
.quiz2__pdf-link:hover {
  background: #16a34a;
  transform: translateY(-1px);
}

@keyframes pdf-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7); }
  50% { box-shadow: 0 0 0 14px rgba(22, 163, 74, 0); }
}

.quiz2__success-pdf svg,
.quiz2__pdf-link svg {
  width: 18px;
  height: 18px;
}

/* ================================================
   9. Slide Animations
   ================================================ */
.quiz2__slide-left {
  transform: translateX(-100%);
  opacity: 0;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  pointer-events: none;
}

.quiz2__slide-right {
  transform: translateX(100%);
  opacity: 0;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  pointer-events: none;
}

.quiz2__slide-active {
  transform: translateX(0);
  opacity: 1;
  position: relative;
  pointer-events: auto;
  transition: transform .3s ease, opacity .3s ease;
}

.quiz2__slide-left,
.quiz2__slide-right {
  transition: transform .3s ease, opacity .3s ease;
}

/* --- Slide animation classes used by JS --- */
.quiz2__slide-out-left {
  transform: translateX(-30%);
  opacity: 0;
  transition: transform .15s ease, opacity .15s ease;
}

.quiz2__slide-out-right {
  transform: translateX(30%);
  opacity: 0;
  transition: transform .15s ease, opacity .15s ease;
}

.quiz2__slide-in-right {
  transform: translateX(30%);
  opacity: 0;
  animation: quiz2-slideInRight .3s ease forwards;
}

.quiz2__slide-in-left {
  transform: translateX(-30%);
  opacity: 0;
  animation: quiz2-slideInLeft .3s ease forwards;
}

@keyframes quiz2-slideInRight {
  from { transform: translateX(30%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes quiz2-slideInLeft {
  from { transform: translateX(-30%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ================================================
   9a. Toast (mobile expert hint — slide up from bottom)
   ================================================ */
.quiz2__toast {
  position: fixed;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  background: rgba(30, 30, 40, .88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 14px;
  max-width: 400px;
  width: calc(100% - 32px);
  pointer-events: none;
  opacity: 0;
  transition: transform .35s cubic-bezier(.22, .61, .36, 1), opacity .35s ease;
}

.quiz2__toast--visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.quiz2__toast-avatar {
  flex-shrink: 0;
}

.quiz2__toast-avatar img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, .25);
}

.quiz2__toast-text {
  font-size: 14px;
  color: #fff;
  line-height: 1.4;
}

/* ================================================
   9b. Step 1 Grid & Card Options
   ================================================ */
/* Mobile: step 1 cards same size as regular options (icon left, text right) */
.quiz2__options--grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz2__option--card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
  text-align: left;
  padding: 14px 16px;
  min-height: auto;
}

.quiz2__option--card .quiz2__option-text {
  font-size: 16px;
  font-weight: 600;
  text-align: left;
  line-height: 1.3;
}

.quiz2__option--card .quiz2__option-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.quiz2__option--card .quiz2__option-icon svg {
  width: 24px;
  height: 24px;
}

/* Icons in regular option rows (steps 2-6) */
.quiz2__option:not(.quiz2__option--card) .quiz2__option-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.quiz2__option:not(.quiz2__option--card) .quiz2__option-icon svg {
  width: 24px;
  height: 24px;
}

/* "Другое" link below cards */
.quiz2__other-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 12px;
  padding: 12px 16px;
  background: none;
  border: none;
  color: #0800dd;
  font-family: 'TT', sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  text-align: center;
  transition: color .2s, background .2s;
  border-radius: 10px;
}

.quiz2__other-link .quiz2__option-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.quiz2__other-link .quiz2__option-icon svg {
  width: 20px;
  height: 20px;
}

.quiz2__other-link:hover {
  background: rgba(8, 0, 221, .04);
  color: #0600aa;
}

/* ================================================
   9c. Next Button (for checkboxes / multi-select)
   ================================================ */
.quiz2__next-btn {
  display: block;
  width: 100%;
  margin-top: 16px;
  padding: 16px 36px;
  border-radius: 28px;
  background: #ffc200;
  color: #000;
  font-family: 'TT', sans-serif;
  font-size: 17px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background .2s, transform .15s, box-shadow .2s;
  box-shadow: 0 4px 16px rgba(255, 194, 0, .25);
}

.quiz2__next-btn:hover {
  background: #e6af00;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255, 194, 0, .35);
}

.quiz2__next-btn:active {
  transform: translateY(0);
}

/* ================================================
   9d. Option Hint (expandable under checked checkbox)
   ================================================ */
.quiz2__option-hint {
  width: 100%;
  font-size: 13px;
  color: #666;
  line-height: 1.5;
  margin-top: 6px;
  padding: 8px 0 0;
  border-top: 1px solid rgba(8, 0, 221, .1);
  animation: quiz2-fadeIn .25s ease;
}

/* ================================================
   9e. Upload Area (step 7 photo upload)
   ================================================ */
.quiz2__upload-area {
  margin-top: 10px;
}

.quiz2__upload-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  border-radius: 20px;
  background: #fff;
  color: #0800dd;
  border: 2px solid #0800dd;
  font-family: 'TT', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, color .2s;
}

.quiz2__upload-btn:hover {
  background: #0800dd;
  color: #fff;
}

.quiz2__upload-label {
  font-size: 15px;
  color: #888;
  line-height: 1.5;
  margin-bottom: 8px;
}

.quiz2__upload-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid rgba(255, 255, 255, .4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: quiz2-spin .6s linear infinite;
}

/* ================================================
   9f. Form Elements (step 7)
   ================================================ */
.quiz2__form-title {
  font-size: 17px;
  font-weight: 700;
  color: #222;
  line-height: 1.4;
  margin-bottom: 4px;
}

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

.quiz2__form-note {
  font-size: 13px;
  color: #888;
  text-align: center;
  margin-top: 8px;
  line-height: 1.5;
}

.quiz2__form-error {
  font-size: 14px;
  color: #e74c3c;
  text-align: center;
  margin-top: 8px;
  line-height: 1.5;
}

.quiz2__input-name,
.quiz2__input-phone {
  /* Inherits from .quiz2__input */
}

.quiz2__phone-error {
  color: #e53e3e;
  font-size: 13px;
  margin-top: 4px;
  display: none;
}

.quiz2__phone-error.visible {
  display: block;
}

/* ================================================
   9g. Expert Inline (step 7 — always visible)
   ================================================ */
.quiz2__expert-inline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 16px;
  background: #f8f8ff;
  border-radius: 14px;
  border: 1px solid #eee;
}

.quiz2__expert-inline p {
  font-size: 15px;
  color: #666;
  line-height: 1.5;
  margin: 0;
}

.quiz2__expert-inline-img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid #e0dff8;
}

/* ================================================
   9h. Button Spinner (inside submit button)
   ================================================ */
.quiz2__btn-spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(0, 0, 0, .2);
  border-top-color: #000;
  border-radius: 50%;
  animation: quiz2-spin .6s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}

/* ================================================
   9i. Summary (step 7)
   ================================================ */
.quiz2__summary-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: #0800dd;
  margin-bottom: 14px;
  line-height: 1.3;
}

.quiz2__summary-title .quiz2__pdf-icon {
  flex-shrink: 0;
}

.quiz2__summary-title:hover {
  text-decoration: underline;
}

.quiz2__summary-text {
  font-size: 16px;
  color: #555;
  line-height: 1.8;
}

/* ================================================
   10. Desktop Layout (768px+)
   ================================================ */
@media (min-width: 768px) {

  .quiz2 {
    padding: 28px 0 64px;
  }

  .quiz2__intro {
    padding: 24px 24px 40px;
  }

  .quiz2__intro-title,
  .quiz2__title {
    font-size: 32px;
  }

  .quiz2__intro-subtitle,
  .quiz2__subtitle {
    font-size: 18px;
  }

  /* --- Quiz Body: CSS Grid for header / content+expert / progress --- */
  .quiz2__body,
  .quiz2__body.active {
    border-radius: 20px;
    max-width: 800px;
    margin: 0 auto;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 220px;
    grid-template-rows: auto 1fr auto;
    box-shadow: 0 8px 40px rgba(0, 0, 0, .07);
  }

  .quiz2__header {
    grid-column: 1 / -1;
    padding: 28px 40px 0;
  }

  .quiz2__content {
    grid-column: 1;
    grid-row: 2;
    padding: 28px 36px 32px;
    display: block;
    min-height: 400px;
  }

  .quiz2__content-main {
    width: 100%;
  }

  .quiz2__question {
    font-size: 22px;
    font-weight: 700;
    color: #222;
    margin-bottom: 20px;
  }

  /* --- Steps 2-6: options as vertical list (single column) --- */
  .quiz2__options {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .quiz2__option {
    padding: 14px 18px;
    border-radius: 14px;
    transition: border-color .2s, background .2s, box-shadow .2s, transform .2s;
  }

  .quiz2__option:hover {
    border-color: #0800dd;
    background: rgba(8, 0, 221, .03);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(8, 0, 221, .08);
  }

  .quiz2__checkbox {
    padding: 14px 18px;
  }

  /* --- Step 1: 4-column grid for cards --- */
  .quiz2__options:has(.quiz2__option--card) {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
  }

  .quiz2__option--card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px 12px;
    min-height: 100px;
    border-radius: 14px;
    transition: border-color .2s, background .2s, box-shadow .2s, transform .2s;
  }

  .quiz2__option--card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(8, 0, 221, .1);
    border-color: #0800dd;
    background: rgba(8, 0, 221, .03);
  }

  .quiz2__option--card .quiz2__option-icon {
    width: 36px;
    height: 36px;
  }
  .quiz2__option--card .quiz2__option-icon svg {
    width: 36px;
    height: 36px;
  }

  .quiz2__option--card .quiz2__option-text {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
    text-align: center;
  }

  /* --- "Другое" link under grid --- */
  .quiz2__other-link {
    margin-top: 16px;
    font-size: 14px;
    color: #0800dd;
    justify-content: center;
  }

  /* --- Expert Panel (desktop — sidebar via grid) --- */
  .quiz2__expert {
    position: static;
    bottom: auto;
    left: auto;
    right: auto;
    z-index: auto;
    grid-column: 2;
    grid-row: 2;
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    width: auto;
    padding: 28px 20px 32px;
    pointer-events: auto;
    background: transparent;
    border-left: 2px solid #e8e6e1;
    border-radius: 0;
  }

  .quiz2__expert-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0;
    padding: 0;
    background: transparent;
    border-radius: 0;
    border: none;
    transform: none;
    opacity: 1;
    pointer-events: auto;
    max-width: none;
    width: auto;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .quiz2__expert-inner.visible {
    transform: none;
    opacity: 1;
  }

  .quiz2__expert-avatar {
    width: 72px;
    height: 72px;
    margin-bottom: 10px;
    border: 3px solid #e0dff8;
  }

  .quiz2__expert-name {
    font-size: 15px;
    font-weight: 600;
    color: #222;
    margin-bottom: 2px;
  }

  .quiz2__expert-title {
    font-size: 13px;
    color: #888;
    margin-bottom: 14px;
    display: block;
  }

  .quiz2__expert-text {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    transition: opacity .25s ease;
    text-align: center;
  }

  /* --- When expert is hidden, content spans full width --- */
  .quiz2__body--wide,
  .quiz2__body--wide.active {
    grid-template-columns: 1fr;
  }

  .quiz2__body--wide .quiz2__content {
    grid-column: 1 / -1;
    padding: 32px 40px 36px;
  }

  /* --- Progress bar spans full width --- */
  .quiz2__progress {
    grid-column: 1 / -1;
    grid-row: 3;
    border-radius: 0 0 20px 20px;
    overflow: hidden;
  }

  /* --- Step 7: form layout --- */
  .quiz2__summary {
    background: #f8f7f4;
    border-radius: 14px;
    padding: 20px 24px 10px;
    margin-bottom: 8px;
  }

  .quiz2__summary p,
  .quiz2__summary li,
  .quiz2__summary div {
    border-bottom: none;
    padding-bottom: 3px;
    margin-bottom: 3px;
  }

  .quiz2__summary-title {
    font-size: 22px;
    margin-bottom: 10px;
  }

  .quiz2__summary-text {
    font-size: 15px;
    line-height: 1.5;
  }

  .quiz2__lead-magnet {
    padding: 24px;
    border-radius: 14px;
    margin: 20px 0;
  }

  .quiz2__scheme {
    max-height: 280px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
  }

  .quiz2__scheme svg {
    max-width: 400px;
    max-height: 240px;
    margin: 0 auto;
  }

  .quiz2__form {
    gap: 14px;
  }

  .quiz2__form-title {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 4px;
  }

  /* Form fields side-by-side on desktop */
  .quiz2__fields {
    flex-direction: row;
    gap: 12px;
  }

  .quiz2__fields .quiz2__input {
    flex: 1;
  }

  .quiz2__form-row {
    display: flex;
    gap: 12px;
  }

  .quiz2__form-row .quiz2__input {
    flex: 1;
  }

  .quiz2__submit {
    width: 100%;
    max-width: 360px;
    margin: 4px auto 0;
    display: block;
  }

  .quiz2__expert-inline {
    margin-top: 20px;
    padding: 18px;
    border-radius: 14px;
    background: #f8f7f4;
    border: 1px solid #eee;
  }

  .quiz2__success {
    padding: 40px;
  }

  .quiz2__success-icon {
    width: 56px;
    height: 56px;
    margin-bottom: 16px;
  }

  .quiz2__success-icon svg {
    width: 28px;
    height: 28px;
  }

  .quiz2__success-title {
    font-size: 24px;
  }

  .quiz2__success-text {
    font-size: 16px;
    max-width: 480px;
    margin: 0 auto 20px;
  }

  /* Toast hidden on desktop (expert panel used instead) */
  .quiz2__toast {
    display: none !important;
  }

  /* Step 1 grid: fallback (no :has support) */
  .quiz2__options--grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
  }
}

/* ================================================
   11. Large Desktop (1024px+)
   ================================================ */
@media (min-width: 1024px) {

  .quiz2__intro-title,
  .quiz2__title {
    font-size: 36px;
  }

  .quiz2__body,
  .quiz2__body.active {
    max-width: 860px;
    grid-template-columns: 1fr 240px;
  }

  .quiz2__body--wide,
  .quiz2__body--wide.active {
    grid-template-columns: 1fr;
  }

  .quiz2__question {
    font-size: 24px;
  }

  .quiz2__content {
    padding: 32px 44px 36px;
  }

  .quiz2__header {
    padding: 32px 44px 0;
  }

  .quiz2__expert {
    padding: 32px 24px;
  }

  .quiz2__expert-avatar {
    width: 80px;
    height: 80px;
  }
}

/* ================================================
   12. Small Mobile (max-width: 480px)
   ================================================ */
@media (max-width: 480px) {

  .quiz2__intro {
    padding: 24px 12px 16px;
  }

  .quiz2__intro-title,
  .quiz2__title {
    font-size: 24px;
    margin-bottom: 8px;
  }

  .quiz2__intro-subtitle,
  .quiz2__subtitle {
    font-size: 16px;
    margin-bottom: 4px;
  }

  .quiz2__start-btn,
  .quiz2__start {
    width: 100%;
    padding: 16px 24px;
  }

  .quiz2__header {
    padding: 12px 16px 0;
  }

  .quiz2__content {
    padding: 16px 16px 16px;
  }

  .quiz2__question {
    font-size: 18px;
  }

  .quiz2__option {
    padding: 12px 14px;
    font-size: 15px;
    gap: 12px;
  }

  .quiz2__option-img {
    width: 48px;
    height: 48px;
    border-radius: 8px;
  }

  .quiz2__checkbox {
    padding: 12px 14px;
  }

  .quiz2__checkbox-label {
    font-size: 15px;
  }

  .quiz2__summary {
    padding: 16px 14px 10px;
    margin-bottom: 12px;
    font-size: 16px;
  }

  .quiz2__scheme {
    width: 100%;
    min-height: 200px;
    margin: 16px 0;
  }

  .quiz2__scheme svg {
    width: 100%;
    height: auto;
    display: block;
    max-width: none;
  }

  .quiz2__input {
    padding: 14px 16px;
    font-size: 16px;
  }

  .quiz2__upload {
    padding: 6px 0;
  }

  .quiz2__thumb,
  .quiz2__upload-preview {
    width: 56px;
    height: 56px;
  }

  .quiz2__success {
    padding: 16px 12px;
  }

  .quiz2__success-icon {
    width: 44px;
    height: 44px;
  }

  .quiz2__success-title {
    font-size: 20px;
    margin: 8px 0;
  }

  .quiz2__success-text {
    font-size: 14px;
    margin-bottom: 16px;
  }

  .quiz2__options--grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .quiz2__option--card {
    flex-direction: row;
    padding: 12px 14px;
    min-height: auto;
    gap: 12px;
  }

  .quiz2__option--card .quiz2__option-icon {
    width: 24px;
    height: 24px;
  }
  .quiz2__option--card .quiz2__option-icon svg {
    width: 24px;
    height: 24px;
  }

  .quiz2__option--card .quiz2__option-text {
    font-size: 15px;
    text-align: left;
  }

  .quiz2__other-link {
    font-size: 14px;
    padding: 10px 12px;
  }

  .quiz2__next-btn {
    padding: 14px 24px;
    font-size: 16px;
  }

  .quiz2__form-title {
    font-size: 16px;
  }

  .quiz2__expert-inline {
    padding: 12px;
    gap: 10px;
  }

  .quiz2__lead-magnet {
    padding: 16px;
    margin: 16px 0;
  }

  .quiz2__lead-magnet-header {
    font-size: 14px;
  }
}

/* ================================================
   13. Expert title (hidden on mobile, shown on desktop)
   ================================================ */
.quiz2__expert-title {
  display: none;
}

/* ================================================
   14. Utility: hide on mobile / desktop
   ================================================ */
.quiz2__mobile-only {
  display: block;
}

.quiz2__desktop-only {
  display: none;
}

@media (min-width: 768px) {
  .quiz2__mobile-only {
    display: none;
  }

  .quiz2__desktop-only {
    display: block;
  }
}

/* ================================================
   14a. Lead Magnet Block
   ================================================ */
.quiz2__lead-magnet {
  background: #f8f7f4;
  border: 1px solid #e8e6e1;
  border-radius: 16px;
  padding: 20px;
  margin: 20px 0;
}

.quiz2__lead-magnet-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 15px;
  font-weight: 600;
  color: #222;
}

.quiz2__pdf-icon {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
}

.quiz2__pdf-icon svg {
  width: 32px;
  height: 32px;
}

.quiz2__lead-magnet .quiz2__scheme {
  margin: 0;
  width: 100%;
}

.quiz2__lead-magnet .quiz2__scheme svg {
  width: 100%;
  height: auto;
  min-height: 150px;
  max-width: none;
}

/* ================================================
   15. Content main wrapper (needed for desktop flex)
   ================================================ */
.quiz2__content-main {
  width: 100%;
}

/* ================================================
   16. Unified Summary block (step 7) — Правка 10
   ================================================ */
.quiz2__summary-left {
  margin-bottom: 12px;
}

.quiz2__summary-right {
  margin-bottom: 0;
}

.quiz2__summary-right .quiz2__scheme {
  margin: 0;
  border: none;
  background: transparent;
  padding: 0;
}

@media (min-width: 768px) {
  .quiz2__summary {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: flex-start;
  }

  .quiz2__summary-title {
    flex: 0 0 100%;
    margin-bottom: 8px;
    font-size: 16px;
  }

  .quiz2__summary-left {
    flex: 1;
    margin-bottom: 0;
  }

  .quiz2__summary-right {
    flex: 0 0 280px;
    max-width: 300px;
    align-self: flex-start;
  }
}
