/* ==========================================================================
   VITAMIN QUIZ & BENEFIT CALCULATOR MODULE
   Сити-ферма «САВА» (г. Коломна) — Выращено с душой
   ========================================================================== */

/* Promo Banner on Storefront */
.quiz-banner-section {
  padding: 10px 0 32px;
  position: relative;
  z-index: 2;
}

.quiz-banner-card {
  position: relative;
  background: linear-gradient(135deg, #064e3b 0%, #14532d 40%, #1e3a1f 100%);
  border: 1px solid rgba(74, 222, 128, 0.25);
  border-radius: var(--radius-lg, 24px);
  padding: 36px 40px;
  color: #ffffff;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(6, 78, 59, 0.22), 0 0 0 1px rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.quiz-banner-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 42px rgba(6, 78, 59, 0.28), 0 0 0 1px rgba(74, 222, 128, 0.35);
}

.quiz-banner-glow {
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  opacity: 0.35;
}

.quiz-glow-1 {
  background: #22c55e;
  top: -100px;
  right: -60px;
}

.quiz-glow-2 {
  background: #eab308;
  bottom: -120px;
  left: 20%;
  opacity: 0.18;
}

.quiz-banner-content {
  position: relative;
  z-index: 2;
  max-width: 660px;
}

.quiz-banner-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.quiz-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #bbf7d0;
  letter-spacing: 0.02em;
}

.quiz-tag-discount {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fef08a;
  animation: pulse-gold 2s infinite ease-in-out;
}

@keyframes pulse-gold {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.85; transform: scale(1.02); }
}

.quiz-banner-title {
  font-size: 1.85rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 10px 0;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.quiz-banner-title .gradient-text-quiz {
  background: linear-gradient(135deg, #86efac 0%, #fef08a 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.quiz-banner-desc {
  font-size: 0.96rem;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 0 20px 0;
  line-height: 1.55;
}

.quiz-banner-cta-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-quiz-start {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
  color: #ffffff;
  border: none;
  padding: 13px 28px;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(34, 197, 94, 0.35);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-quiz-start:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(34, 197, 94, 0.48);
  background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
}

.btn-quiz-start .btn-arrow {
  transition: transform 0.2s ease;
}

.btn-quiz-start:hover .btn-arrow {
  transform: translateX(4px);
}

.quiz-banner-meta {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.7);
  display: flex;
  align-items: center;
  gap: 6px;
}

.quiz-banner-visual {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quiz-visual-badge-cluster {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz-visual-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(12px);
  padding: 10px 18px;
  border-radius: 16px;
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  transition: transform 0.25s ease;
}

.quiz-visual-pill:hover {
  transform: scale(1.04);
}

.quiz-visual-pill .pill-ico {
  font-size: 1.35rem;
  line-height: 1;
}

/* Header Nav Pill Highlight */
.nav-link-quiz {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: var(--primary, #15803d) !important;
  font-weight: 700;
  border-radius: var(--radius-full, 9999px);
  padding: 4px 10px;
  transition: all var(--transition-fast, 0.2s ease);
  white-space: nowrap !important;
  flex-shrink: 0;
  text-decoration: none;
}

.nav-link-quiz:hover {
  background: #16a34a;
  color: #ffffff !important;
  border-color: #16a34a;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.25);
}

.nav-link-quiz:hover .nav-quiz-badge {
  background: #ffffff;
  color: #d97706;
}

.nav-quiz-icon {
  font-size: 0.95rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.nav-quiz-label {
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.nav-quiz-badge {
  font-size: 0.65rem;
  font-weight: 800;
  background: #f59e0b;
  color: #ffffff;
  padding: 1.5px 5.5px;
  border-radius: 6px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition: all 0.2s ease;
}

/* Mobile Drawer Quiz link */
.drawer-nav-link-quiz {
  background: rgba(34, 197, 94, 0.08) !important;
  border-radius: 12px;
  margin: 4px 0 !important;
  font-weight: 700 !important;
  color: var(--primary) !important;
  display: flex !important;
  align-items: center !important;
}

.drawer-quiz-badge {
  margin-left: auto;
  font-size: 0.7rem;
  font-weight: 800;
  background: #f59e0b;
  color: #fff;
  padding: 2px 7px;
  border-radius: 6px;
}

/* ==========================================================================
   QUIZ MODAL COMPONENT
   ========================================================================== */
.quiz-modal-content {
  max-width: 660px;
  width: 95%;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
  padding: 0;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--border-color, #e2e8f0);
}

.quiz-modal-header {
  padding: 24px 28px 18px;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  border-bottom: 1px solid var(--border-color, #e2e8f0);
  position: relative;
}

.quiz-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.quiz-badge-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #15803d;
  background: #dcfce7;
  padding: 3px 10px;
  border-radius: 8px;
}

.quiz-progress-bar-wrap {
  width: 100%;
  height: 6px;
  background: #e2e8f0;
  border-radius: 9999px;
  overflow: hidden;
  position: relative;
}

.quiz-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #22c55e 0%, #15803d 100%);
  border-radius: 9999px;
  transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.quiz-step-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main, #1e293b);
  margin: 12px 0 4px 0;
  line-height: 1.3;
}

.quiz-step-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted, #64748b);
  margin: 0;
}

/* Modal Body */
.quiz-modal-body {
  padding: 24px 28px;
  max-height: 68vh;
  overflow-y: auto;
  scrollbar-width: thin;
}

.quiz-modal-body::-webkit-scrollbar {
  width: 6px;
}
.quiz-modal-body::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 6px;
}

/* Option Cards */
.quiz-options-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz-option-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 18px;
  background: #ffffff;
  border: 1.5px solid var(--border-color, #e2e8f0);
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  user-select: none;
}

.quiz-option-card:hover {
  border-color: #86efac;
  background: #fafffc;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(22, 163, 74, 0.08);
}

.quiz-option-card.selected {
  border-color: #16a34a !important;
  background: #f0fdf4 !important;
  box-shadow: 0 0 0 1px #16a34a, 0 6px 20px rgba(22, 163, 74, 0.15);
}

.quiz-opt-icon {
  font-size: 1.6rem;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.quiz-opt-info {
  flex: 1;
  min-width: 0;
}

.quiz-opt-title {
  font-size: 0.96rem;
  font-weight: 800;
  color: var(--text-main, #1e293b);
  line-height: 1.3;
}

.quiz-option-card.selected .quiz-opt-title {
  color: #15803d;
}

.quiz-opt-desc {
  font-size: 0.8rem;
  color: var(--text-muted, #64748b);
  margin-top: 3px;
  line-height: 1.4;
}

.quiz-option-card.selected .quiz-opt-desc {
  color: #166534;
}

.quiz-opt-radio {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  margin-top: 3px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  background: #ffffff;
}

.quiz-option-card.selected .quiz-opt-radio {
  border-color: #16a34a;
  background: #16a34a;
}

.quiz-opt-radio-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffffff;
  display: none;
}

.quiz-option-card.selected .quiz-opt-radio-dot {
  display: block;
}

/* Modal Footer Actions */
.quiz-modal-footer {
  padding: 16px 28px 24px;
  background: #ffffff;
  border-top: 1px solid var(--border-color, #e2e8f0);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.btn-quiz-back {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #475569;
  padding: 10px 20px;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-quiz-back:hover {
  background: #e2e8f0;
  color: #1e293b;
}

.btn-quiz-next {
  background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color: #ffffff;
  border: none;
  padding: 11px 26px;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(22, 163, 74, 0.3);
  transition: all 0.22s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-quiz-next:hover:not(:disabled) {
  background: linear-gradient(135deg, #15803d 0%, #14532d 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(22, 163, 74, 0.4);
}

.btn-quiz-next:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

/* ==========================================================================
   QUIZ RESULT: PERSONAL VITAMIN CARD
   ========================================================================== */
.quiz-result-header-card {
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
  border: 1.5px solid #86efac;
  border-radius: 18px;
  padding: 18px 22px;
  margin-bottom: 20px;
}

.quiz-result-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.quiz-user-target-tag {
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #15803d;
  background: #ffffff;
  padding: 3px 10px;
  border-radius: 8px;
  border: 1px solid #bbf7d0;
}

.quiz-discount-pill {
  font-size: 0.78rem;
  font-weight: 800;
  background: #f59e0b;
  color: #ffffff;
  padding: 3px 10px;
  border-radius: 9999px;
  letter-spacing: 0.02em;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.quiz-result-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: #14532d;
  margin: 0 0 6px 0;
}

.quiz-result-desc {
  font-size: 0.85rem;
  color: #166534;
  line-height: 1.45;
  margin: 0;
}

/* Nutrient Calculator Grid */
.quiz-nutrient-box {
  background: #ffffff;
  border: 1.5px solid var(--border-color, #e2e8f0);
  border-radius: 18px;
  padding: 18px 20px;
  margin-bottom: 20px;
}

.quiz-nutrient-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--text-main, #1e293b);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
}

.quiz-nutrient-bars {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.quiz-nutr-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.quiz-nutr-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
}

.quiz-nutr-name {
  font-weight: 700;
  color: var(--text-main, #334155);
}

.quiz-nutr-val {
  font-weight: 800;
  color: #15803d;
}

.quiz-nutr-track {
  width: 100%;
  height: 7px;
  background: #f1f5f9;
  border-radius: 9999px;
  overflow: hidden;
}

.quiz-nutr-fill {
  height: 100%;
  border-radius: 9999px;
  transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.fill-green { background: linear-gradient(90deg, #4ade80, #16a34a); }
.fill-emerald { background: linear-gradient(90deg, #34d399, #059669); }
.fill-gold { background: linear-gradient(90deg, #fde047, #ca8a04); }
.fill-purple { background: linear-gradient(90deg, #c084fc, #9333ea); }

/* Recommended Bundle Cards */
.quiz-bundle-section-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main, #1e293b);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.quiz-bundle-items-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.quiz-bundle-item-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: 14px;
  transition: all 0.2s ease;
}

.quiz-bundle-item-card:hover {
  background: #ffffff;
  border-color: #86efac;
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.06);
}

.quiz-bundle-item-img {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}

.quiz-bundle-item-info {
  flex: 1;
  min-width: 0;
}

.quiz-bundle-item-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.quiz-bundle-item-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--text-main, #1e293b);
  line-height: 1.25;
}

.quiz-item-stock-tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: #15803d;
  background: #dcfce7;
  border: 1px solid #bbf7d0;
  padding: 1px 6px;
  border-radius: 9999px;
  white-space: nowrap;
}

.quiz-bundle-item-reason {
  font-size: 0.74rem;
  color: #15803d;
  font-weight: 600;
  margin-top: 2px;
}

.quiz-bundle-item-pricing {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  flex-shrink: 0;
}

.quiz-item-old-price {
  font-size: 0.72rem;
  color: var(--text-subtle, #94a3b8);
  text-decoration: line-through;
  line-height: 1.1;
}

.quiz-bundle-item-price {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--primary, #15803d);
}

/* Quiz Dynamic Calculation Loading State */
.quiz-calc-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}

.quiz-calc-spinner {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: 16px;
  animation: quiz-pulse-spin 1.2s infinite ease-in-out;
}

@keyframes quiz-pulse-spin {
  0% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.25) rotate(15deg); }
  100% { transform: scale(1) rotate(0deg); }
}

.quiz-calc-text {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary, #15803d);
  margin-bottom: 8px;
}

.quiz-calc-subtext {
  font-size: 0.88rem;
  color: var(--text-muted, #64748b);
  max-width: 380px;
}

/* Pricing and Bundle Checkout Card */
.quiz-checkout-card {
  background: #ffffff;
  border: 2px solid #86efac;
  border-radius: 18px;
  padding: 16px 20px;
  box-shadow: 0 8px 24px rgba(22, 163, 74, 0.1);
  margin-bottom: 6px;
}

.quiz-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 6px;
}

.quiz-old-price {
  font-size: 0.92rem;
  color: #94a3b8;
  text-decoration: line-through;
  margin-right: 8px;
}

.quiz-new-price {
  font-size: 1.45rem;
  font-weight: 800;
  color: #15803d;
}

.quiz-price-discount-badge {
  font-size: 0.76rem;
  font-weight: 800;
  background: #fef08a;
  color: #854d0e;
  border: 1px solid #fde047;
  padding: 2px 8px;
  border-radius: 6px;
}

.quiz-eco-points-note {
  font-size: 0.78rem;
  color: #166534;
  font-weight: 600;
  margin-bottom: 14px;
}

.btn-add-bundle-cart {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color: #ffffff;
  border: none;
  padding: 14px 22px;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(22, 163, 74, 0.35);
  transition: all 0.22s ease;
}

.btn-add-bundle-cart:hover {
  background: linear-gradient(135deg, #15803d 0%, #14532d 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(22, 163, 74, 0.45);
}

.btn-restart-quiz {
  width: 100%;
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 0;
  margin-top: 8px;
  cursor: pointer;
  text-decoration: underline;
  transition: color 0.2s ease;
}

.btn-restart-quiz:hover {
  color: var(--text-main, #1e293b);
}

/* Responsive */
@media (max-width: 768px) {
  .quiz-banner-card {
    flex-direction: column;
    padding: 26px 20px;
    gap: 20px;
  }

  .quiz-banner-visual {
    width: 100%;
  }

  .quiz-visual-badge-cluster {
    flex-direction: row;
    flex-wrap: wrap;
    width: 100%;
  }

  .quiz-visual-pill {
    flex: 1 1 calc(50% - 6px);
    padding: 8px 12px;
    font-size: 0.8rem;
  }

  .quiz-banner-title {
    font-size: 1.5rem;
  }

  .quiz-modal-header {
    padding: 18px 20px 14px;
  }

  .quiz-modal-body {
    padding: 18px 20px;
  }

  .quiz-modal-footer {
    padding: 14px 20px 18px;
  }
}
