/**
 * 级伴益生菌 AI 官网 - 诊断页专属样式
 */

.qb-diagnosis-page {
  min-height: 100vh;
  background: var(--qianban-gradient-hero);
  padding-bottom: var(--qianban-space-3xl);
}

.qb-diagnosis-container {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--qianban-space-xl) var(--qianban-space-lg);
}

/* ==================== 头部 ==================== */
.qb-diagnosis-header {
  text-align: center;
  margin-bottom: var(--qianban-space-xl);
}

.qb-diagnosis-header__icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--qianban-space-md);
  border-radius: var(--qianban-radius-lg);
  background: var(--qianban-gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  color: #fff;
  box-shadow: var(--qianban-shadow-lg);
  animation: qianban-float 3s ease-in-out infinite;
}

.qb-diagnosis-header__title {
  font-size: var(--qianban-font-h2);
  color: var(--qianban-color-text);
  margin-bottom: var(--qianban-space-sm);
}

.qb-diagnosis-header__desc {
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text-secondary);
}

/* ==================== 进度条 ==================== */
.qb-progress {
  margin-bottom: var(--qianban-space-xl);
}

.qb-progress__bar {
  height: 8px;
  background: rgba(232,76,136,0.1);
  border-radius: var(--qianban-radius-full);
  overflow: hidden;
}

.qb-progress__fill {
  height: 100%;
  background: var(--qianban-gradient-primary);
  border-radius: var(--qianban-radius-full);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 8px rgba(232,76,136,0.4);
}

.qb-progress__text {
  text-align: center;
  font-size: var(--qianban-font-small);
  color: var(--qianban-color-text-secondary);
  margin-top: var(--qianban-space-sm);
}

/* ==================== 问卷区域 ==================== */
.qb-quiz-area {
  background: #fff;
  border-radius: var(--qianban-radius-lg);
  padding: var(--qianban-space-xl);
  box-shadow: var(--qianban-shadow-md);
  margin-bottom: var(--qianban-space-lg);
  min-height: 320px;
}

.qb-quiz-question {
  animation: qianban-fade-in 0.4s ease;
}

.qb-quiz-question__num {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: rgba(232,76,136,0.1);
  color: var(--qianban-color-primary);
  border-radius: var(--qianban-radius-full);
  font-size: var(--qianban-font-tiny);
  font-weight: 600;
  margin-bottom: var(--qianban-space-md);
}

.qb-quiz-question__title {
  font-size: var(--qianban-font-h3);
  color: var(--qianban-color-text);
  margin-bottom: var(--qianban-space-lg);
  line-height: 1.5;
}

.qb-quiz-options {
  display: flex;
  flex-direction: column;
  gap: var(--qianban-space-sm);
}

.qb-quiz-option {
  display: flex;
  align-items: center;
  gap: var(--qianban-space-md);
  padding: var(--qianban-space-md);
  border: 2px solid #E8E8E8;
  border-radius: var(--qianban-radius-md);
  cursor: pointer;
  transition: var(--qianban-transition-fast);
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text);
  background: #fff;
}

.qb-quiz-option:hover {
  border-color: var(--qianban-color-primary-light);
  background: var(--qianban-color-bg);
}

.qb-quiz-option.qb-selected {
  border-color: var(--qianban-color-primary);
  background: rgba(232,76,136,0.05);
  box-shadow: 0 0 0 3px rgba(232,76,136,0.1);
}

.qb-quiz-option__radio {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #D0D0D0;
  flex-shrink: 0;
  position: relative;
  transition: var(--qianban-transition-fast);
}

.qb-quiz-option.qb-selected .qb-quiz-option__radio {
  border-color: var(--qianban-color-primary);
  background: var(--qianban-color-primary);
}

.qb-quiz-option.qb-selected .qb-quiz-option__radio::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
}

/* 多选 */
.qb-quiz-option--multi .qb-quiz-option__radio {
  border-radius: var(--qianban-radius-sm);
}

.qb-quiz-option.qb-selected.qb-quiz-option--multi .qb-quiz-option__radio::after {
  content: '\f00c';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  font-size: 12px;
  color: #fff;
  background: none;
  border-radius: 0;
  width: auto;
  height: auto;
}

.qb-quiz-option__label {
  flex: 1;
}

.qb-quiz-option__key {
  font-size: var(--qianban-font-tiny);
  color: var(--qianban-color-text-light);
  font-weight: 600;
}

/* ==================== 导航按钮 ==================== */
.qb-quiz-nav {
  display: flex;
  justify-content: space-between;
  gap: var(--qianban-space-md);
}

/* ==================== 加载动画 ==================== */
.qb-diagnosis-loading {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--qianban-space-xl);
}

.qb-diagnosis-loading__inner {
  text-align: center;
}

.qb-diagnosis-loading__animation {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto var(--qianban-space-xl);
  display: flex;
  align-items: center;
  justify-content: center;
}

.qb-diagnosis-loading__ring {
  position: absolute;
  border: 3px solid transparent;
  border-radius: 50%;
  animation: qianban-spin 1.5s linear infinite;
}

.qb-diagnosis-loading__ring:nth-child(1) {
  width: 120px;
  height: 120px;
  border-top-color: var(--qianban-color-primary);
}

.qb-diagnosis-loading__ring--2 {
  width: 90px;
  height: 90px;
  border-right-color: var(--qianban-color-gold);
  animation-duration: 2s;
  animation-direction: reverse;
}

.qb-diagnosis-loading__ring--3 {
  width: 60px;
  height: 60px;
  border-bottom-color: var(--qianban-color-blue);
  animation-duration: 1s;
}

.qb-diagnosis-loading__icon {
  font-size: 32px;
  color: var(--qianban-color-primary);
  z-index: 1;
  animation: qianban-pulse 1.5s ease-in-out infinite;
}

.qb-diagnosis-loading__title {
  font-size: var(--qianban-font-h3);
  color: var(--qianban-color-text);
  margin-bottom: var(--qianban-space-sm);
}

.qb-diagnosis-loading__desc {
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text-secondary);
}

/* ==================== 结果区域 ==================== */
.qb-diagnosis-result {
  max-width: 800px;
  margin: 0 auto;
  padding: var(--qianban-space-xl) var(--qianban-space-lg);
}

.qb-result-card {
  background: #fff;
  border-radius: var(--qianban-radius-lg);
  padding: var(--qianban-space-2xl) var(--qianban-space-xl);
  box-shadow: var(--qianban-shadow-lg);
  margin-bottom: var(--qianban-space-lg);
}

.qb-result-header {
  text-align: center;
  margin-bottom: var(--qianban-space-xl);
}

.qb-result-header__type-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--qianban-space-md);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  color: #fff;
  background: var(--qianban-gradient-primary);
  box-shadow: var(--qianban-shadow-lg);
}

.qb-result-header__label {
  font-size: var(--qianban-font-small);
  color: var(--qianban-color-text-secondary);
  margin-bottom: var(--qianban-space-sm);
}

.qb-result-header__type {
  font-size: var(--qianban-font-h1);
  font-weight: 800;
  color: var(--qianban-color-primary);
  margin-bottom: var(--qianban-space-sm);
}

.qb-result-header__score {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 20px;
  background: rgba(232,76,136,0.08);
  border-radius: var(--qianban-radius-full);
  font-size: var(--qianban-font-body);
  font-weight: 600;
  color: var(--qianban-color-primary);
}

.qb-result-header__level {
  font-size: var(--qianban-font-small);
  color: var(--qianban-color-warning);
  margin-top: var(--qianban-space-sm);
  font-weight: 600;
}

.qb-result-section {
  margin-bottom: var(--qianban-space-xl);
}

.qb-result-section__title {
  font-size: var(--qianban-font-h3);
  color: var(--qianban-color-text);
  margin-bottom: var(--qianban-space-md);
  display: flex;
  align-items: center;
  gap: var(--qianban-space-sm);
}

.qb-result-section__title i {
  color: var(--qianban-color-primary);
}

.qb-result-section__text {
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text);
  line-height: 1.8;
}

.qb-result-issues {
  display: flex;
  flex-direction: column;
  gap: var(--qianban-space-sm);
}

.qb-result-issue {
  display: flex;
  align-items: flex-start;
  gap: var(--qianban-space-sm);
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text);
}

.qb-result-issue i {
  color: var(--qianban-color-warning);
  margin-top: 4px;
  flex-shrink: 0;
}

.qb-result-package {
  background: var(--qianban-gradient-hero);
  border-radius: var(--qianban-radius-md);
  padding: var(--qianban-space-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--qianban-space-md);
  flex-wrap: wrap;
}

.qb-result-package__info {
  flex: 1;
  min-width: 200px;
}

.qb-result-package__name {
  font-size: var(--qianban-font-h3);
  font-weight: 700;
  color: var(--qianban-color-primary);
  margin-bottom: 4px;
}

.qb-result-package__desc {
  font-size: var(--qianban-font-small);
  color: var(--qianban-color-text-secondary);
}

.qb-result-actions {
  display: flex;
  flex-direction: column;
  gap: var(--qianban-space-sm);
}

@media (min-width: 768px) {
  .qb-result-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

/* ==================== 留资表单 ==================== */
.qb-lead-form {
  background: #fff;
  border-radius: var(--qianban-radius-lg);
  padding: var(--qianban-space-xl);
  box-shadow: var(--qianban-shadow-md);
  margin-top: var(--qianban-space-lg);
}

.qb-lead-form__title {
  font-size: var(--qianban-font-h3);
  color: var(--qianban-color-text);
  text-align: center;
  margin-bottom: var(--qianban-space-sm);
}

.qb-lead-form__desc {
  text-align: center;
  font-size: var(--qianban-font-small);
  color: var(--qianban-color-text-secondary);
  margin-bottom: var(--qianban-space-lg);
}

.qb-lead-form__success {
  text-align: center;
  padding: var(--qianban-space-xl);
}

.qb-lead-form__success-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--qianban-space-md);
  border-radius: 50%;
  background: var(--qianban-color-success);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #fff;
}

.qb-lead-form__success-title {
  font-size: var(--qianban-font-h3);
  color: var(--qianban-color-text);
  margin-bottom: var(--qianban-space-sm);
}

.qb-lead-form__success-desc {
  font-size: var(--qianban-font-body);
  color: var(--qianban-color-text-secondary);
}

/* ==================== 报告编号展示 ==================== */
.qb-report-no {
  text-align: center;
  font-size: var(--qianban-font-tiny);
  color: var(--qianban-color-text-light);
  margin-top: var(--qianban-space-md);
}
