{
  "version": 3,
  "sources": ["/cdn/shop/t/28/assets/quiz-app.js?t=20260218-phase2-start-q1"],
  "sourcesContent": ["(() => {\n  const root = document.querySelector('[data-evq-root]');\n  if (!root) {\n    return;\n  }\n\n  const normalizePath = (value, fallback) => {\n    const raw = (value || fallback || '').trim();\n    if (!raw) {\n      return '';\n    }\n\n    const withSlash = raw.startsWith('/') ? raw : `/${raw}`;\n    return withSlash.replace(/\\/+$/, '').toLowerCase();\n  };\n\n  const pathname = (window.location.pathname || '').toLowerCase();\n  const initialSearchParams = new URLSearchParams(window.location.search);\n  const TRACK_ENTRY_SOURCE = 'prequiz_landing';\n  const IS_GOOGLE_AUTH_RETURN = initialSearchParams.get('evq_auth') === 'google';\n  const customerPostedParam = (initialSearchParams.get('customer_posted') || '').toLowerCase();\n  const IS_CUSTOMER_POSTED_RETURN = customerPostedParam === 'true' || customerPostedParam === '1';\n  const IS_DEV_PREVIEW = initialSearchParams.get('preview') === '1';\n  const DEV_PREVIEW_PROFILE = initialSearchParams.get('profile') || 'sleep_starter';\n  const configuredAppMode = (root.dataset.appMode || '').trim().toLowerCase();\n  const QUIZ_ENTRY_PATH = normalizePath(root.dataset.quizEntryPath, '/pages/cadence-quiz');\n  const LEGACY_QUIZ_PATH = '/pages/quiz';\n  const RECOMMENDATIONS_PATH = normalizePath(root.dataset.recommendationsPath, '/pages/recommendations');\n  const QUIZ_BASE_PATHS = Array.from(new Set([QUIZ_ENTRY_PATH, LEGACY_QUIZ_PATH].filter(Boolean)));\n  const ALLOWED_BASE_PATHS = Array.from(new Set([...QUIZ_BASE_PATHS, RECOMMENDATIONS_PATH].filter(Boolean)));\n  const matchedBasePath = ALLOWED_BASE_PATHS.find((basePath) => pathname === basePath || pathname.startsWith(`${basePath}/`));\n  const isRecommendationsAppMode = configuredAppMode === 'recommendations';\n  const isRecommendationsPathMatch =\n    pathname === RECOMMENDATIONS_PATH || pathname.startsWith(`${RECOMMENDATIONS_PATH}/`);\n  const isThemeEditor = Boolean(window.Shopify && window.Shopify.designMode);\n  if (!matchedBasePath && !isThemeEditor && !isRecommendationsAppMode) {\n    return;\n  }\n  const isRecommendationsMode = isRecommendationsAppMode || isRecommendationsPathMatch;\n  const quizBasePath =\n    QUIZ_BASE_PATHS.find((basePath) => pathname === basePath || pathname.startsWith(`${basePath}/`)) ||\n    QUIZ_ENTRY_PATH ||\n    LEGACY_QUIZ_PATH ||\n    '/pages/cadence-quiz';\n  const EXTERNAL_RECOMMENDATIONS_ENABLED = String(root.dataset.externalRecommendations || '').toLowerCase() === 'true';\n\n  if (isRecommendationsMode) {\n    if (document.querySelector('[data-evr-v3-layout]')) {\n      document.body.classList.add('evr-v3-page');\n      document.body.classList.add('evr-v2-page');\n    } else {\n      document.body.classList.add('evr-v2-page');\n    }\n  } else {\n    document.body.classList.remove('evr-v2-page');\n    document.body.classList.remove('evr-v3-page');\n    document.body.classList.add('evq-page');\n  }\n\n  function hasExternalRecommendationsLayout() {\n    return Boolean(document.querySelector('[data-evr-layout=\"recommendations\"]'));\n  }\n\n  function hasExternalRecommendationsV2Layout() {\n    return Boolean(document.querySelector('[data-evr-v2-layout]'));\n  }\n\n  function shouldUseExternalRecommendationsLayout() {\n    if (!isRecommendationsMode) {\n      return false;\n    }\n\n    return hasExternalRecommendationsLayout();\n  }\n\n  function shouldUseExternalRecommendationsV2Layout() {\n    return shouldUseExternalRecommendationsLayout() && hasExternalRecommendationsV2Layout();\n  }\n\n  function hasExternalRecommendationsV3Layout() {\n    return Boolean(document.querySelector('[data-evr-v3-layout]'));\n  }\n\n  function shouldUseExternalRecommendationsV3Layout() {\n    return shouldUseExternalRecommendationsLayout() && hasExternalRecommendationsV3Layout();\n  }\n\n  function syncRuntimeHostVisibility() {\n    const shouldCollapse = isRecommendationsMode && shouldUseExternalRecommendationsLayout();\n    root.setAttribute('data-runtime-collapsed', shouldCollapse ? 'true' : 'false');\n  }\n\n  const TOTAL_QUESTIONS = 12;\n  const SOURCE_RULE_COUNT = 33;\n\n  const QUESTION_ROUTE_MAP = [\n    { route: 'q1', step: 1, phase: 'Sleep Baseline', title: 'Current Sleep Quality' },\n    { route: 'q2', step: 2, phase: 'Sleep Baseline', title: 'Sleep Onset Barriers' },\n    { route: 'q3', step: 3, phase: 'Sleep Baseline', title: 'Morning Wake-Up Experience' },\n    { route: 'q4', step: 4, phase: 'Stress & Lifestyle', title: 'Emotional Baseline' },\n    { route: 'q5', step: 5, phase: 'Stress & Lifestyle', title: 'Stress Triggers' },\n    { route: 'q7', step: 6, phase: 'Symptoms & Goals', title: 'Physical & Mental Symptoms' },\n    { route: 'q8', step: 7, phase: 'Symptoms & Goals', title: 'Sleep Goals' },\n    { route: 'q9', step: 8, phase: 'Symptoms & Goals', title: 'Stress Goals' },\n    { route: 'q10', step: 9, phase: 'Current Solutions', title: 'Previous Attempts' },\n    { route: 'q11', step: 10, phase: 'Current Solutions', title: 'Hardest Time of Day' },\n    { route: 'q12', step: 11, phase: 'Demographics', title: 'Demographics & Context' },\n  ];\n\n  const QUIZ_STEPS = [\n    {\n      route: 'q1',\n      type: 'single',\n      phase: 'Phase 1: Sleep Baseline',\n      question: 'What would you most like to improve?',\n      instruction: '',\n      desktopColumns: 1,\n      style: 'slider',\n      options: [\n        { id: 'sleep_easily', emoji: '\uD83D\uDE34', label: 'Sleep is good, reduce stress' },\n        { id: 'wake_during_night', emoji: '\uD83C\uDF19', label: 'Stay asleep all night' },\n        { id: 'hard_to_fall_asleep', emoji: '\u23F0', label: 'Fall asleep faster' },\n        { id: 'rarely_restful', emoji: '\uD83D\uDE35', label: 'Everything needs work' },\n      ],\n    },\n    {\n      route: 'q2',\n      type: 'multi',\n      phase: 'Phase 1: Sleep Baseline',\n      question: 'What keeps you from falling asleep?',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      options: [\n        { id: 'racing_thoughts', emoji: '\uD83E\uDDE0', label: 'Busy mind' },\n        { id: 'worry_anxiety', emoji: '\uD83D\uDE30', label: 'Worry & anxiety' },\n        { id: 'screen_time', emoji: '\uD83D\uDCF1', label: 'Screen time' },\n        { id: 'caffeine', emoji: '\u2615', label: 'Caffeine' },\n        { id: 'physical_tension', emoji: '\uD83D\uDE23', label: 'Physical tension' },\n        { id: 'sleep_environment', emoji: '\uD83D\uDECF\uFE0F', label: 'Bad sleep environment' },\n        { id: 'no_specific_reason', emoji: '\uD83E\uDD37', label: \"Body won't shut down\" },\n        { id: 'none_fall_asleep_easily', emoji: '\u2705', label: 'None of these', exclusive: true },\n      ],\n    },\n    {\n      route: 'q3',\n      type: 'multi',\n      phase: 'Phase 1: Sleep Baseline',\n      question: 'How do you feel when you wake up?',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      style: 'emoji-cards',\n      options: [\n        { id: 'wake_refreshed', emoji: '\u26A1', label: 'Refreshed' },\n        { id: 'wake_tired', emoji: '\uD83D\uDE2A', label: 'Still tired' },\n        { id: 'wake_groggy', emoji: '\uD83E\uDD74', label: 'Groggy & foggy' },\n        { id: 'wake_irritable', emoji: '\uD83D\uDE24', label: 'Irritable' },\n        { id: 'wake_sore', emoji: '\uD83D\uDCAA', label: 'Sore & tense' },\n        { id: 'wake_coffee', emoji: '\u2615', label: 'Need coffee ASAP' },\n        { id: 'wake_inconsistent', emoji: '\uD83D\uDD01', label: 'Varies day to day' },\n      ],\n    },\n    {\n      route: 'q4',\n      type: 'multi',\n      phase: 'Phase 2: Stress & Lifestyle',\n      question: 'During the day, you usually feel...',\n      instruction: 'Select all that apply',\n      desktopColumns: 4,\n      style: 'mood-grid',\n      options: [\n        { id: 'calm_in_control', emoji: '\uD83D\uDE0C', label: 'Calm & in control' },\n        { id: 'stressed_overwhelmed', emoji: '\uD83D\uDE30', label: 'Stressed' },\n        { id: 'down_low_energy', emoji: '\uD83D\uDE14', label: 'Low energy' },\n        { id: 'irritable_short_tempered', emoji: '\uD83D\uDE20', label: 'Irritable' },\n        { id: 'mind_racing', emoji: '\uD83E\uDD2F', label: 'Mind always busy' },\n        { id: 'worried_no_reason', emoji: '\uD83D\uDE1F', label: 'Anxious' },\n        { id: 'mood_swings', emoji: '\uD83D\uDD04', label: 'Mood swings' },\n        { id: 'balanced_overall', emoji: '\uD83D\uDE42', label: 'Balanced' },\n      ],\n    },\n    {\n      route: 'q5',\n      type: 'multi',\n      phase: 'Phase 2: Stress & Lifestyle',\n      question: 'Your daily stress comes from...',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      options: [\n        { id: 'work_demands', emoji: '\uD83D\uDCBC', label: 'Work & deadlines' },\n        { id: 'family_relationships', emoji: '\uD83D\uDC68\u200D\uD83D\uDC69\u200D\uD83D\uDC67', label: 'Family & relationships' },\n        { id: 'financial_pressures', emoji: '\uD83D\uDCB0', label: 'Finances' },\n        { id: 'no_time_for_self', emoji: '\uD83C\uDFC3', label: 'No time for myself' },\n        { id: 'overthinking_future', emoji: '\uD83E\uDD14', label: 'Overthinking' },\n        { id: 'health_concerns', emoji: '\uD83D\uDE37', label: 'Health concerns' },\n        { id: 'overpacked_schedule', emoji: '\uD83D\uDDD3\uFE0F', label: 'Overpacked schedule' },\n        { id: 'digital_overload', emoji: '\uD83D\uDCF1', label: 'Digital overload' },\n        { id: 'not_sure_always_stressed', emoji: '\uD83E\uDD37', label: 'Always stressed' },\n      ],\n    },\n    {\n      route: 'q7',\n      type: 'multi',\n      phase: 'Phase 3: Symptoms & Goals',\n      question: 'Do you notice any of these physical signs?',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      options: [\n        { id: 'symptom_muscle_tension', emoji: '\uD83D\uDCAA', label: 'Muscle cramps or tightness' },\n        { id: 'symptom_on_edge', emoji: '\uD83D\uDC93', label: 'Heart racing or palpitations' },\n        { id: 'symptom_headaches', emoji: '\uD83E\uDD15', label: 'Headaches' },\n        { id: 'symptom_digestive', emoji: '\uD83E\uDD22', label: 'Digestive discomfort' },\n        { id: 'symptom_temperature', emoji: '\uD83E\uDD76', label: 'Cold hands or feet' },\n        { id: 'symptom_none', emoji: '\u2705', label: 'None of these', exclusive: true },\n      ],\n    },\n    {\n      route: 'q8',\n      type: 'multi',\n      phase: 'Phase 3: Symptoms & Goals',\n      question: 'What would waking up feeling amazing look like for you?',\n      instruction: 'Select up to 3',\n      maxSelections: 3,\n      desktopColumns: 2,\n      style: 'aspiration-cards',\n      options: [\n        { id: 'goal_fall_asleep_faster', emoji: '\uD83D\uDECC', label: 'Fall asleep in minutes, not hours' },\n        { id: 'goal_stay_asleep', emoji: '\uD83D\uDE34', label: 'Sleep through the whole night' },\n        { id: 'goal_wake_refreshed', emoji: '\u23F0', label: 'Wake up actually refreshed' },\n        { id: 'goal_reduce_bedtime_anxiety', emoji: '\uD83E\uDDD8', label: 'Lie down without racing thoughts' },\n        { id: 'goal_deeper_sleep', emoji: '\uD83D\uDCA4', label: 'Deep, restorative sleep every night' },\n        { id: 'goal_consistent_sleep', emoji: '\uD83D\uDCC5', label: 'Consistent quality every single night' },\n      ],\n    },\n    {\n      route: 'q9',\n      type: 'multi',\n      phase: 'Phase 3: Symptoms & Goals',\n      question: 'Better stress management looks like...',\n      instruction: 'Select up to 3',\n      maxSelections: 3,\n      desktopColumns: 4,\n      style: 'ranked',\n      options: [\n        { id: 'stress_goal_calm_reactive', emoji: '\uD83D\uDE0C', label: 'Calmer & less reactive' },\n        { id: 'stress_goal_think_clearly', emoji: '\uD83E\uDDE0', label: 'Clear thinking' },\n        { id: 'stress_goal_mood_balance', emoji: '\uD83D\uDE0A', label: 'Better mood' },\n        { id: 'stress_goal_energy', emoji: '\uD83D\uDCAA', label: 'More energy' },\n        { id: 'stress_goal_unwind', emoji: '\uD83E\uDDD8', label: 'Relax after work' },\n        { id: 'stress_goal_schedule', emoji: '\uD83D\uDDD3\uFE0F', label: 'No burnout' },\n        { id: 'stress_goal_sleep', emoji: '\uD83D\uDE34', label: 'Stress-free sleep' },\n        { id: 'stress_goal_feel_self', emoji: '\uD83D\uDE42', label: 'Feel like myself' },\n      ],\n    },\n    {\n      route: 'q10',\n      type: 'multi',\n      phase: 'Phase 4: Current Solutions',\n      question: 'What have you tried before?',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      options: [\n        { id: 'attempt_melatonin', emoji: '\uD83D\uDC8A', label: 'Melatonin' },\n        { id: 'attempt_magnesium', emoji: '\uD83E\uDDF4', label: 'Magnesium' },\n        { id: 'attempt_herbal_sleep_aids', emoji: '\uD83C\uDF75', label: 'Herbal teas' },\n        { id: 'attempt_prescription_sleep_meds', emoji: '\uD83D\uDC8A', label: 'Prescription sleep meds' },\n        { id: 'attempt_anti_anxiety_meds', emoji: '\uD83E\uDDE0', label: 'Anti-anxiety meds' },\n        { id: 'attempt_apps', emoji: '\uD83D\uDCF1', label: 'Sleep apps' },\n        { id: 'attempt_sleep_hygiene', emoji: '\uD83D\uDCD6', label: 'Sleep hygiene' },\n        { id: 'attempt_therapy', emoji: '\uD83E\uDDD8', label: 'Therapy' },\n        { id: 'attempt_exercise_lifestyle', emoji: '\uD83C\uDFC3', label: 'Exercise & lifestyle' },\n        { id: 'attempt_nothing_yet', emoji: '\uD83E\uDD37', label: 'Nothing yet' },\n        { id: 'attempt_tried_a_lot', emoji: '\u2705', label: 'Tried everything' },\n      ],\n    },\n    {\n      route: 'q11',\n      type: 'multi',\n      phase: 'Phase 4: Current Solutions',\n      question: 'When do stress or sleep issues hit you hardest?',\n      instruction: 'Select all that apply',\n      desktopColumns: 3,\n      style: 'timeline',\n      options: [\n        { id: 'time_morning_anxious', emoji: '\uD83C\uDF05', label: 'Morning' },\n        { id: 'time_midday_crash', emoji: '\u2600\uFE0F', label: 'Midday' },\n        { id: 'time_evening_wind_down', emoji: '\uD83C\uDF06', label: 'Evening' },\n        { id: 'time_bedtime_racing', emoji: '\uD83C\uDF19', label: 'Bedtime' },\n        { id: 'time_middle_of_night', emoji: '\uD83C\uDF03', label: 'Middle of the night' },\n        { id: 'time_all_day_stress', emoji: '\uD83D\uDD04', label: 'All day' },\n      ],\n    },\n  ];\n\n  const DEMOGRAPHIC_OPTIONS = {\n    age: [\n      { id: 'age_18_24', label: '18-24' },\n      { id: 'age_25_34', label: '25-34' },\n      { id: 'age_35_44', label: '35-44' },\n      { id: 'age_45_54', label: '45-54' },\n      { id: 'age_55_64', label: '55-64' },\n      { id: 'age_65_plus', label: '65+' },\n      { id: 'age_prefer_not', label: 'Prefer not to say' },\n    ],\n    gender: [\n      { id: 'gender_female', label: 'Female' },\n      { id: 'gender_male', label: 'Male' },\n      { id: 'gender_non_binary', label: 'Non-binary' },\n      { id: 'gender_prefer_not', label: 'Prefer not to say' },\n    ],\n    femaleConditions: [\n      { id: 'pregnant_or_breastfeeding', emoji: '\uD83E\uDD30', label: 'Pregnant or breastfeeding' },\n      { id: 'pms_menstrual_issues', emoji: '\uD83D\uDD34', label: 'PMS or menstrual issues' },\n      { id: 'perimenopause_menopause', emoji: '\uD83D\uDD25', label: 'Perimenopause or menopause' },\n      { id: 'hormonal_birth_control', emoji: '\uD83D\uDC8A', label: 'Hormonal birth control' },\n      { id: 'female_none', emoji: '\u2705', label: 'None of these', exclusive: true },\n    ],\n  };\n\n  const PERSONALIZATION_RULES = [\n    { id: '1A', category: 'sleep_quality', ingredients: ['affron', 'l_theanine'], profile: 'sleep_onset' },\n    { id: '1B', category: 'sleep_quality', ingredients: ['chelamax', 'affron'], profile: 'sleep_maintenance' },\n    { id: '1C', category: 'sleep_quality', ingredients: ['affron', 'chelamax', 'l_theanine'], profile: 'sleep_root' },\n    { id: '2A', category: 'stress_trigger', ingredients: ['affron'], profile: 'work_stress' },\n    { id: '2B', category: 'stress_trigger', ingredients: ['l_theanine'], profile: 'overthinking' },\n    { id: '2C', category: 'stress_trigger', ingredients: ['affron', 'chelamax'], profile: 'family_stress' },\n    { id: '2D', category: 'stress_trigger', ingredients: ['affron'], profile: 'time_starved' },\n    { id: '3A', category: 'symptom', ingredients: ['l_theanine'], profile: 'racing_thoughts' },\n    { id: '3B', category: 'symptom', ingredients: ['chelamax'], profile: 'muscle_tension' },\n    { id: '3C', category: 'symptom', ingredients: ['affron'], profile: 'fight_or_flight' },\n    { id: '3D', category: 'symptom', ingredients: ['chelamax', 'affron'], profile: 'fatigue_stress' },\n    { id: '4A', category: 'goal', ingredients: ['affron'], profile: 'faster_onset' },\n    { id: '4B', category: 'goal', ingredients: ['affron', 'l_theanine'], profile: 'melatonin_switcher' },\n    { id: '4C', category: 'goal', ingredients: ['affron'], profile: 'daytime_calm' },\n    { id: '4D', category: 'goal', ingredients: ['l_theanine'], profile: 'cognitive_clarity' },\n    { id: '5A', category: 'switcher', ingredients: ['affron', 'l_theanine'], profile: 'melatonin_history' },\n    { id: '5B', category: 'switcher', ingredients: ['chelamax', 'affron', 'l_theanine'], profile: 'magnesium_history' },\n    { id: '5C', category: 'switcher', ingredients: ['affron', 'chelamax', 'l_theanine'], profile: 'rx_history' },\n    { id: '5D', category: 'switcher', ingredients: ['affron', 'chelamax', 'l_theanine'], profile: 'first_timer' },\n    { id: '5E', category: 'switcher', ingredients: ['affron', 'chelamax', 'l_theanine'], profile: 'frustrated_switcher' },\n    { id: '6A', category: 'timing', ingredients: ['affron', 'chelamax'], profile: 'evening_wind_down' },\n    { id: '6B', category: 'timing', ingredients: ['l_theanine'], profile: 'bedtime_racing' },\n    { id: '6C', category: 'timing', ingredients: ['affron'], profile: 'middle_night_wake' },\n    { id: '6D', category: 'timing', ingredients: ['affron', 'ashwagandha'], profile: 'all_day_stress' },\n    { id: '7A', category: 'demographic', ingredients: ['chelamax', 'affron'], profile: 'female_pms' },\n    { id: '7B', category: 'demographic', ingredients: ['affron', 'chelamax', 'l_theanine'], profile: 'female_menopause' },\n    { id: '7C', category: 'demographic', ingredients: ['safety_gate'], profile: 'pregnancy_warning' },\n    { id: '7D', category: 'demographic', ingredients: ['affron', 'l_theanine'], profile: 'male_35_44' },\n    { id: '7E', category: 'demographic', ingredients: ['chelamax', 'affron'], profile: 'age_55_plus' },\n    { id: '8A', category: 'bundle', ingredients: ['affron', 'chelamax', 'l_theanine'], bundle: 'sleep_restoration_stack' },\n    { id: '8B', category: 'bundle', ingredients: ['affron', 'chelamax', 'l_theanine'], bundle: 'complete_calm_protocol' },\n    { id: '8C', category: 'bundle', ingredients: ['affron', 'chelamax', 'l_theanine', 'ashwagandha'], bundle: 'stress_recovery_system' },\n    { id: '8D', category: 'bundle', ingredients: ['affron', 'chelamax', 'l_theanine'], bundle: 'sleep_starter_kit' },\n  ];\n\n  const PROFILE_META = {\n    sleep_starter: {\n      label: 'Sleep Starter',\n      bundle: 'sleep_starter_kit',\n      specialist: 'Mia Torres',\n      specialistRole: 'Sleep & Stress Specialist',\n    },\n    sleep_restoration: {\n      label: 'Sleep Restoration',\n      bundle: 'sleep_restoration_stack',\n      specialist: 'Mia Torres',\n      specialistRole: 'Sleep & Stress Specialist',\n    },\n    complete_calm: {\n      label: 'Complete Calm',\n      bundle: 'complete_calm_protocol',\n      specialist: 'James Park',\n      specialistRole: 'Stress Management Specialist',\n    },\n    stress_recovery: {\n      label: 'Stress Recovery',\n      bundle: 'stress_recovery_system',\n      specialist: 'James Park',\n      specialistRole: 'Stress Management Specialist',\n    },\n  };\n\n  const PROFILE_KEY_ALIASES = {\n    sleep_starter: 'sleep_starter',\n    sleepstarter: 'sleep_starter',\n    'sleep starter': 'sleep_starter',\n    sleep_restoration: 'sleep_restoration',\n    sleeprestoration: 'sleep_restoration',\n    'sleep restoration': 'sleep_restoration',\n    complete_calm: 'complete_calm',\n    completecalm: 'complete_calm',\n    'complete calm': 'complete_calm',\n    stress_recovery: 'stress_recovery',\n    stressrecovery: 'stress_recovery',\n    'stress recovery': 'stress_recovery',\n  };\n\n  function parseProfileKey(rawProfile) {\n    if (!rawProfile || typeof rawProfile !== 'string') {\n      return '';\n    }\n\n    const normalized = rawProfile\n      .trim()\n      .toLowerCase()\n      .replace(/\\+/g, ' ')\n      .replace(/[^a-z0-9 ]+/g, ' ')\n      .replace(/\\s+/g, ' ')\n      .trim();\n    const compact = normalized.replace(/\\s+/g, '');\n    const snake = normalized.replace(/\\s+/g, '_');\n\n    return PROFILE_KEY_ALIASES[snake] || PROFILE_KEY_ALIASES[normalized] || PROFILE_KEY_ALIASES[compact] || '';\n  }\n\n  function getSpecialistRoleForName(name) {\n    if (!name) {\n      return '';\n    }\n\n    return name === 'James Park' ? 'Stress Management Specialist' : 'Sleep & Stress Specialist';\n  }\n\n  const INGREDIENT_META = {\n    affron: {\n      label: 'Affron\u00AE Saffron',\n      dose: '28mg',\n      why: 'Supports healthy cortisol balance so your body can shift from alert to rest mode.*',\n    },\n    chelamax: {\n      label: 'Chelamax\u00AE Magnesium',\n      dose: '200mg',\n      why: 'Chelated magnesium with 64% bioaccessibility \u2014 vs ~8% for common oxide forms. Supports muscle and nervous-system relaxation for deeper sleep.*',\n    },\n    l_theanine: {\n      label: 'L-Theanine',\n      dose: '200mg',\n      why: 'Promotes alpha brain waves to quiet a busy mind without next-day grogginess.*',\n    },\n  };\n\n  const TESTIMONIAL_LIBRARY = {\n    onset: [\n      { quote: 'I used to lie awake replaying the day for hours. Now I fall asleep within 20 minutes most nights.', author: 'Susan K., 58', context: 'Sleep Onset Profile' },\n      { quote: \"I\\u2019d been on melatonin three years. Once I switched, I started falling asleep naturally \\u2014 no grogginess the next morning.\", author: 'Patricia M., 62', context: 'Sleep Onset Profile' },\n    ],\n    maintenance: [\n      { quote: 'I stopped waking up at 3 AM every night. By week 4, I was finally sleeping through.', author: 'William R., 63', context: 'Sleep Maintenance Profile' },\n      { quote: 'I took magnesium for years without questioning the form. Switched to bisglycinate and finally started sleeping through.', author: 'Robert K., 67', context: 'Sleep Maintenance Profile' },\n    ],\n    stress: [\n      { quote: \"The biggest shift wasn\\u2019t just sleep. I felt less reactive all day and more in control of my mornings.\", author: 'Barbara N., 57', context: 'Stress Recovery Profile' },\n      { quote: 'My doctor had me on oxide for years. Turns out I was absorbing almost nothing. This changed my energy within a month.', author: 'Linda S., 59', context: 'Stress Recovery Profile' },\n    ],\n    switcher: [\n      { quote: 'Melatonin left me foggy every morning. This formula helped me sleep deeply and wake up clear.', author: 'Diane P., 61', context: 'Switcher Profile' },\n      { quote: \"I wanted off melatonin but was afraid I\\u2019d stop sleeping entirely. This was the bridge I needed.\", author: 'James T., 64', context: 'Switcher Profile' },\n    ],\n    racing_thoughts: [\n      { quote: 'My mind used to race the second I laid down. Within two weeks, the mental chatter got quieter.', author: 'Margaret T., 59', context: 'Busy mind' },\n    ],\n    muscle_tension: [\n      { quote: 'I carried tension in my shoulders and jaw every night. The magnesium bisglycinate made a real difference.', author: 'Thomas M., 64', context: 'Physical tension' },\n      { quote: 'Five years of magnesium oxide did nothing for my shoulders. Two weeks on bisglycinate and I noticed the difference.', author: 'Richard H., 66', context: 'Physical tension' },\n    ],\n    overthinking: [\n      { quote: \"I\\u2019ve been an overthinker my whole life. This helped me stop spiraling before bed.\", author: 'Nancy W., 56', context: 'Overthinking' },\n    ],\n    fatigue: [\n      { quote: 'I was exhausted but wired every night. Now I actually feel tired at the right time.', author: 'Dorothy L., 60', context: 'Fatigue pattern' },\n      { quote: \"I blamed aging for the fatigue. Turns out it was the form of magnesium I was taking \\u2014 not my age.\", author: 'Carol D., 61', context: 'Fatigue pattern' },\n    ],\n    all_day_stress: [\n      { quote: 'Stress used to follow me from morning to midnight. I finally feel like I can unplug in the evening.', author: 'George H., 65', context: 'All-day stress' },\n    ],\n  };\n\n  const SHOP_MORE_CATEGORIES = [\n    {\n      title: 'Deep Sleep',\n      subtitle: 'Nightly recovery support',\n      href: '/collections/all',\n    },\n    {\n      title: 'Anxiety Relief',\n      subtitle: 'Daytime stress regulation',\n      href: '/collections/all',\n    },\n    {\n      title: 'Daily Calm',\n      subtitle: 'Balanced mood and focus',\n      href: '/collections/all',\n    },\n    {\n      title: 'Sleep + Stress Kits',\n      subtitle: 'Stacked protocol bundles',\n      href: '/collections/all',\n    },\n  ];\n\n  const RULE_COPY = {\n    '1A': 'Sleep onset delay mapped to Affron\u00AE + L-Theanine emphasis.',\n    '1B': 'Night waking mapped to Chelamax\u00AE + cortisol-stability support.',\n    '1C': 'Poor restorative sleep mapped to full 3-ingredient protocol.',\n    '2A': 'Work stress trigger mapped to cortisol-regulation messaging.',\n    '2B': 'Overthinking trigger mapped to alpha-wave and worry-loop support.',\n    '2C': 'Family stress trigger mapped to recovery and emotional load support.',\n    '2D': 'No-time trigger mapped to practical PM routine framing.',\n    '3A': 'Racing thoughts symptom mapped to L-Theanine priority.',\n    '3B': 'Muscle tension symptom mapped to Chelamax\u00AE priority.',\n    '3C': 'On-edge symptom mapped to Affron\u00AE stress response support.',\n    '3D': 'Fatigue despite rest mapped to magnesium + stress recovery.',\n    '4A': 'Goal: fall asleep faster mapped to 60-90 min pre-bed timing.',\n    '4B': 'Goal: reduce melatonin reliance mapped to non-groggy positioning.',\n    '4C': 'Goal: daytime calm mapped to overnight stress recovery narrative.',\n    '4D': 'Goal: think clearly mapped to calm-focus positioning.',\n    '5A': 'Melatonin history trigger mapped to anti-grogginess comparison.',\n    '5B': 'Magnesium-only history trigger mapped to full-spectrum rationale.',\n    '5C': 'Rx history trigger mapped to non-habit-forming framing.',\n    '5D': 'First-timer trigger mapped to confidence and starter guidance.',\n    '5E': 'Tried-a-lot trigger mapped to premium-dose differentiation.',\n    '6A': 'Evening struggle trigger mapped to early-evening dosing.',\n    '6B': 'Bedtime racing trigger mapped to 60-90 min bedtime dosing.',\n    '6C': 'Middle-night waking trigger mapped to cortisol-spike education.',\n    '6D': 'All-day stress trigger mapped to PM + AM support framework.',\n    '7A': 'Female + PMS trigger mapped to magnesium-hormonal support.',\n    '7B': 'Female + perimenopause trigger mapped to anxiety/sleep support.',\n    '7C': 'Pregnancy/breastfeeding trigger activates medical safety gate.',\n    '7D': 'Male 35-44 trigger mapped to performance-recovery framing.',\n    '7E': 'Age 55+ trigger mapped to sleep-continuity support.',\n    '8A': 'Bundle map: Sleep Restoration Stack.',\n    '8B': 'Bundle map: Complete Calm Protocol.',\n    '8C': 'Bundle map: Stress Recovery System.',\n    '8D': 'Bundle map: Sleep Starter Kit.',\n  };\n\n  const RULE_USER_COPY = {\n    '1A': 'You described difficulty falling asleep',\n    '1B': 'You experience nighttime wake-ups',\n    '1C': 'You rarely wake up feeling rested',\n    '2A': 'Work demands are a key stressor for you',\n    '2B': 'Overthinking is a key stressor for you',\n    '2C': 'Family and relationship stress affects your recovery',\n    '2D': 'You feel stretched thin with no time for yourself',\n    '3A': 'You experience a busy mind at night',\n    '3B': 'You carry physical tension in your body',\n    '3C': 'You often feel on edge or easily startled',\n    '3D': 'You feel fatigued despite resting',\n    '4A': 'Your goal is to fall asleep faster',\n    '4B': 'You want to move away from melatonin',\n    '4C': 'You want more daytime calm',\n    '4D': 'You want clearer thinking under pressure',\n    '5A': 'You have tried melatonin \u2014 clinical guidelines note it improved sleep onset by only 9 minutes vs placebo',\n    '5B': 'You have tried magnesium \u2014 the form you took may absorb at just 4\\u20138%, leaving most of the dose unused',\n    '5C': 'You have tried prescription sleep aids',\n    '5D': 'This is your first supplement routine',\n    '5E': 'You have tried many approaches \u2014 buying saffron, magnesium, and L-theanine separately costs $80+/month vs $32.97 combined',\n    '6A': 'You struggle most during evening wind-down',\n    '6B': 'A busy mind at bedtime is your trigger',\n    '6C': 'You tend to wake up in the middle of the night',\n    '6D': 'Stress follows you throughout the entire day',\n    '7A': 'Hormonal cycle support is relevant for you',\n    '7B': 'Perimenopause or menopause affects your sleep',\n    '7C': 'Pregnancy or breastfeeding requires medical guidance',\n    '7D': 'Recovery and performance support matched to your profile',\n    '7E': 'Sleep continuity support matched to your age group',\n  };\n\n  const INGREDIENT_TAG_WEIGHTS = {\n    q1: {\n      hard_to_fall_asleep: { affron: 3, l_theanine: 2 },\n      wake_during_night: { chelamax: 3, affron: 1 },\n      rarely_restful: { affron: 2, chelamax: 2, l_theanine: 2 },\n    },\n    q2: {\n      racing_thoughts: { l_theanine: 3 },\n      worry_anxiety: { l_theanine: 2, affron: 2 },\n      screen_time: { l_theanine: 1 },\n      caffeine: { chelamax: 1 },\n      physical_tension: { chelamax: 3 },\n      sleep_environment: { chelamax: 1 },\n      no_specific_reason: { affron: 1 },\n    },\n    q4: {\n      stressed_overwhelmed: { affron: 2 },\n      mind_racing: { l_theanine: 2 },\n      worried_no_reason: { l_theanine: 2, affron: 1 },\n      down_low_energy: { chelamax: 2, affron: 1 },\n      mood_swings: { affron: 1, l_theanine: 1 },\n    },\n    q5: {\n      work_demands: { affron: 2 },\n      family_relationships: { affron: 1, chelamax: 1 },\n      no_time_for_self: { affron: 1 },\n      overthinking_future: { l_theanine: 3 },\n      overpacked_schedule: { affron: 1, chelamax: 1 },\n      digital_overload: { l_theanine: 1 },\n      not_sure_always_stressed: { affron: 2 },\n    },\n    q7: {\n      symptom_muscle_tension: { chelamax: 3 },\n      symptom_on_edge: { affron: 3 },\n      symptom_headaches: { chelamax: 1, affron: 1 },\n      symptom_digestive: { chelamax: 1 },\n      symptom_temperature: { chelamax: 1 },\n    },\n    q8: {\n      goal_fall_asleep_faster: { affron: 2, l_theanine: 1 },\n      goal_stay_asleep: { chelamax: 2, affron: 1 },\n      goal_reduce_bedtime_anxiety: { l_theanine: 2 },\n      goal_deeper_sleep: { chelamax: 1, affron: 1 },\n      goal_consistent_sleep: { chelamax: 1, affron: 1 },\n    },\n    q9: {\n      stress_goal_calm_reactive: { affron: 2 },\n      stress_goal_think_clearly: { l_theanine: 2 },\n      stress_goal_mood_balance: { affron: 1 },\n      stress_goal_unwind: { l_theanine: 1, chelamax: 1 },\n      stress_goal_schedule: { affron: 1 },\n      stress_goal_sleep: { affron: 1, chelamax: 1 },\n    },\n    q10: {\n      attempt_melatonin: { affron: 1, l_theanine: 1 },\n      attempt_magnesium: { affron: 1, l_theanine: 1 },\n      attempt_tried_a_lot: { affron: 1, chelamax: 1, l_theanine: 1 },\n    },\n    q11: {\n      time_evening_wind_down: { affron: 1, chelamax: 1 },\n      time_bedtime_racing: { l_theanine: 2 },\n      time_middle_of_night: { affron: 2, chelamax: 1 },\n      time_all_day_stress: { affron: 3, l_theanine: 1 },\n    },\n  };\n\n  const ROUTE_ORDER = [...QUESTION_ROUTE_MAP.map((step) => step.route), 'results'];\n\n  const stepByRoute = QUIZ_STEPS.reduce((acc, step) => {\n    acc[step.route] = step;\n    return acc;\n  }, {});\n\n  const state = {\n    currentRoute: 'q1',\n    lastRenderedRoute: null,\n    answers: {},\n    lead: {\n      firstName: '',\n      email: '',\n      optIn: true,\n    },\n    purchaseMode: 'subscribe',\n    selectedPlanKey: 'recommended_3',\n    subscribeQuantity: 1,\n    showUpgradePlan: false,\n    summaryExpanded: true,\n    scienceExpanded: false,\n    personalization: null,\n    timer: {\n      startedAt: null,\n      expiresAt: null,\n      intervalId: null,\n      nodes: [],\n      expiredNodes: [],\n      codeNodes: [],\n      shellNodes: [],\n      appliedNodes: [],\n    },\n    variantFallbackId: undefined,\n    cadenceProduct: null,\n    cadenceProductPromise: null,\n    cadenceProductStatus: 'idle',\n    resultsLineItems: [],\n    personalDiscountCode: '',\n    manualDiscountCode: '',\n    manualDiscountPercent: null,\n    cartBusy: false,\n    submitting: false,\n    customer: {\n      loggedIn: String(root.dataset.customerLoggedIn || '') === 'true',\n      id: root.dataset.customerId || '',\n      firstName: root.dataset.customerFirstName || '',\n      email: root.dataset.customerEmail || '',\n      hasProfileType: String(root.dataset.customerHasProfileType || '') === 'true',\n      prefillStateRaw: root.dataset.customerPrefillState || '',\n      prefillState: null,\n      metafields: {\n        profileType: root.dataset.customerProfileType || '',\n        bundleIds: root.dataset.customerBundleIds || '',\n        specialistName: root.dataset.customerSpecialistName || '',\n        lastQuizDate: root.dataset.customerLastQuizDate || '',\n        quizAnswers: root.dataset.customerQuizAnswers || '',\n        // Legacy aliases retained for migration.\n        quizProfile: root.dataset.customerQuizProfile || '',\n        recommendedBundle: root.dataset.customerRecommendedBundle || '',\n        assignedSpecialist: root.dataset.customerAssignedSpecialist || '',\n      },\n    },\n    metafieldSync: {\n      attempted: false,\n      synced: false,\n    },\n    tracking: {\n      sessionId: '',\n      debounceId: null,\n      lastPayloadSignature: '',\n    },\n  };\n  let v2ReportModalEditorCleanupBound = false;\n  let v2ReportModalKeyHandler = null;\n\n  const KLAVIYO_PUBLIC_KEY = root.dataset.klaviyoPublicKey || 'pk_008e3adf663c51d85bbdea9deba8ccb27f';\n  const KLAVIYO_LIST_ID = root.dataset.klaviyoListId || 'RdvieM';\n  const ACCOUNT_URL = root.dataset.accountUrl || '/account';\n  const METAFIELD_SYNC_ENDPOINT = root.dataset.metafieldSyncEndpoint || '/apps/evolance-api/quiz-sync';\n  const QUIZ_TRACK_ENDPOINT = root.dataset.quizTrackEndpoint || '/api/quiz/track';\n  const QUIZ_COMPLETE_ENDPOINT = root.dataset.quizCompleteEndpoint || '/api/quiz/complete';\n  const promoValidationEndpointRaw = String(root.dataset.promoValidationEndpoint || '').trim();\n  const PROMO_VALIDATION_ENDPOINT = /^(off|disabled|none)$/i.test(promoValidationEndpointRaw)\n    ? ''\n    : promoValidationEndpointRaw;\n  const VARIANT_TWO_SUBSCRIBE = parseVariantId(root.dataset.variantTwoSubscribe);\n  const VARIANT_TWO_ONETIME = parseVariantId(root.dataset.variantTwoOnetime);\n  const VARIANT_ONE_SUBSCRIBE = parseVariantId(root.dataset.variantOneSubscribe);\n  const VARIANT_ONE_ONETIME = parseVariantId(root.dataset.variantOneOnetime);\n  const EBOOK_VARIANT_ID = parseVariantId(root.dataset.ebookVariantId) || 47132343468210;\n  const PRODUCT_HANDLE = (root.dataset.productHandle || 'cadence-calm-rest').trim();\n  const SELLING_PLAN_ID = parseVariantId(root.dataset.sellingPlanId) || null;\n\n  let headerCounter = root.querySelector('[data-evq-counter]');\n  let progressFill = root.querySelector('[data-evq-progress-fill]');\n  let progressTrack = root.querySelector('.evq-progress');\n  const content = root.querySelector('[data-evq-content]');\n  const header = root.querySelector('.evq-header');\n  const navWrap = root.querySelector('.evq-nav-wrap');\n  const backButton = root.querySelector('[data-evq-back]');\n  const nextButton = root.querySelector('[data-evq-next]');\n\n  const iconBack =\n    '<svg class=\"evq-icon\" viewBox=\"0 0 24 24\" fill=\"none\" aria-hidden=\"true\"><path d=\"M14.5 6L8.5 12L14.5 18\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>';\n  const iconNext =\n    '<svg class=\"evq-icon\" viewBox=\"0 0 24 24\" fill=\"none\" aria-hidden=\"true\"><path d=\"M9.5 6L15.5 12L9.5 18\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>';\n  const TIMER_STORAGE_KEY = 'evolance_quiz_completed_at';\n  const SESSION_SNAPSHOT_KEY = 'evolance_quiz_session_v2';\n  const PENDING_AUTH_KEY = 'evolance_quiz_pending_auth_v1';\n  const LEGACY_PENDING_AUTH_KEY = 'pending_quiz_result';\n  const QUIZ_TRACK_SESSION_KEY = 'evolance_quiz_track_session_v1';\n  const PENDING_QUIZ_COOKIE_NAME = 'evolance_pending_quiz';\n  const PENDING_QUIZ_COOKIE_DOMAIN = '.evolance.com';\n  const PENDING_QUIZ_COOKIE_MAX_AGE_SECONDS = 60 * 60;\n  const AUTH_SYNC_COMPLETED_KEY = 'evolance_quiz_post_auth_done_v1';\n  const OPTION_LABEL_LOOKUP = buildOptionLabelLookup();\n\n  function getSessionStorage() {\n    try {\n      return window.sessionStorage;\n    } catch (error) {\n      return null;\n    }\n  }\n\n  function getLocalStorage() {\n    try {\n      return window.localStorage;\n    } catch (error) {\n      return null;\n    }\n  }\n\n  function getStoreRootPath() {\n    const rootPath =\n      window.Shopify && window.Shopify.routes && typeof window.Shopify.routes.root === 'string'\n        ? window.Shopify.routes.root\n        : '/';\n    return rootPath.endsWith('/') ? rootPath : `${rootPath}/`;\n  }\n\n  function getPendingQuizCookieDomain() {\n    const hostname = (window.location.hostname || '').toLowerCase();\n    return hostname === 'evolance.com' || hostname.endsWith('.evolance.com') ? PENDING_QUIZ_COOKIE_DOMAIN : '';\n  }\n\n  function setPendingQuizCookie() {\n    const attributes = [`${PENDING_QUIZ_COOKIE_NAME}=true`, 'path=/', `max-age=${PENDING_QUIZ_COOKIE_MAX_AGE_SECONDS}`, 'SameSite=Lax'];\n    if (window.location.protocol === 'https:') {\n      attributes.push('Secure');\n    }\n    const cookieDomain = getPendingQuizCookieDomain();\n    if (cookieDomain) {\n      attributes.push(`domain=${cookieDomain}`);\n    }\n\n    try {\n      document.cookie = attributes.join('; ');\n    } catch (error) {\n      // Ignore cookie write failures.\n    }\n  }\n\n  function clearPendingQuizCookie() {\n    const secureAttr = window.location.protocol === 'https:' ? '; Secure' : '';\n    const expiredAt = 'Thu, 01 Jan 1970 00:00:00 GMT';\n    const cookieDomain = getPendingQuizCookieDomain();\n\n    try {\n      if (cookieDomain) {\n        document.cookie = `${PENDING_QUIZ_COOKIE_NAME}=; domain=${cookieDomain}; path=/; expires=${expiredAt}; SameSite=Lax${secureAttr}`;\n      }\n      document.cookie = `${PENDING_QUIZ_COOKIE_NAME}=; path=/; expires=${expiredAt}; SameSite=Lax${secureAttr}`;\n    } catch (error) {\n      // Ignore cookie clear failures.\n    }\n  }\n\n  function readStorageJson(storage, key) {\n    if (!storage) {\n      return null;\n    }\n\n    try {\n      const raw = storage.getItem(key);\n      if (!raw) {\n        return null;\n      }\n      return JSON.parse(raw);\n    } catch (error) {\n      return null;\n    }\n  }\n\n  function writeStorageJson(storage, key, value) {\n    if (!storage) {\n      return false;\n    }\n\n    try {\n      storage.setItem(key, JSON.stringify(value));\n      return true;\n    } catch (error) {\n      return false;\n    }\n  }\n\n  function clearStorageKey(storage, key) {\n    if (!storage) {\n      return;\n    }\n\n    try {\n      storage.removeItem(key);\n    } catch (error) {\n      // Ignore storage failures.\n    }\n  }\n\n  function generateTrackingSessionId() {\n    const nowToken = Date.now().toString(36);\n    const randomToken = Math.random().toString(36).slice(2, 10);\n    return `evq_${nowToken}_${randomToken}`;\n  }\n\n  function readTrackingSessionId() {\n    const storage = getSessionStorage();\n    if (!storage) {\n      return '';\n    }\n\n    try {\n      const value = String(storage.getItem(QUIZ_TRACK_SESSION_KEY) || '').trim();\n      return value;\n    } catch (error) {\n      return '';\n    }\n  }\n\n  function persistTrackingSessionId(value) {\n    const storage = getSessionStorage();\n    if (!storage) {\n      return;\n    }\n\n    try {\n      storage.setItem(QUIZ_TRACK_SESSION_KEY, value);\n    } catch (error) {\n      // Ignore storage failures.\n    }\n  }\n\n  function ensureTrackingSessionId() {\n    if (state.tracking.sessionId) {\n      return state.tracking.sessionId;\n    }\n\n    const existing = readTrackingSessionId();\n    if (existing) {\n      state.tracking.sessionId = existing;\n      return state.tracking.sessionId;\n    }\n\n    state.tracking.sessionId = generateTrackingSessionId();\n    persistTrackingSessionId(state.tracking.sessionId);\n    return state.tracking.sessionId;\n  }\n\n  function rotateTrackingSessionId() {\n    state.tracking.sessionId = generateTrackingSessionId();\n    state.tracking.lastPayloadSignature = '';\n    if (state.tracking.debounceId) {\n      window.clearTimeout(state.tracking.debounceId);\n      state.tracking.debounceId = null;\n    }\n    persistTrackingSessionId(state.tracking.sessionId);\n  }\n\n  function getQuizTrackEndpoint() {\n    const endpoint = String(QUIZ_TRACK_ENDPOINT || '').trim();\n    return endpoint;\n  }\n\n  function getQuizCompleteEndpoint() {\n    const completeEndpoint = String(QUIZ_COMPLETE_ENDPOINT || '').trim();\n    if (completeEndpoint) {\n      return completeEndpoint;\n    }\n\n    const trackEndpoint = getQuizTrackEndpoint();\n    if (!trackEndpoint) {\n      return '/api/quiz/complete';\n    }\n\n    if (/\\/track\\/?$/i.test(trackEndpoint)) {\n      return trackEndpoint.replace(/\\/track\\/?$/i, '/complete');\n    }\n\n    return '/api/quiz/complete';\n  }\n\n  function resolveQuestionKey(route) {\n    const normalized = String(route || '').trim().toLowerCase();\n    if (/^q(?:1[0-2]|[1-9])$/.test(normalized)) {\n      return normalized;\n    }\n    return '';\n  }\n\n  function getDemographicAnswerIds() {\n    const demographics = getDemographics();\n    const ids = [];\n\n    if (demographics.age) {\n      ids.push(demographics.age);\n    }\n    if (demographics.gender) {\n      ids.push(demographics.gender);\n    }\n    if (Array.isArray(demographics.femaleConditions)) {\n      demographics.femaleConditions.forEach((entry) => {\n        if (entry) {\n          ids.push(entry);\n        }\n      });\n    }\n\n    return Array.from(new Set(ids.map((entry) => String(entry || '').trim()).filter((entry) => entry.length > 0)));\n  }\n\n  function buildTrackPayload(eventType, options = {}) {\n    const route = options.route || state.currentRoute || '';\n    const questionKey = options.questionKey || resolveQuestionKey(route);\n    const answerIds = Array.isArray(options.answerIds)\n      ? Array.from(new Set(options.answerIds.map((entry) => String(entry || '').trim()).filter((entry) => entry.length > 0)))\n      : questionKey === 'q12'\n        ? getDemographicAnswerIds()\n        : questionKey\n          ? getAnswerArray(questionKey)\n          : [];\n\n    const metadata =\n      options.metadata && typeof options.metadata === 'object'\n        ? {\n            entry_source: TRACK_ENTRY_SOURCE,\n            ...options.metadata,\n          }\n        : {\n            entry_source: TRACK_ENTRY_SOURCE,\n          };\n\n    const payload = {\n      session_id: ensureTrackingSessionId(),\n      shop_domain: window.location.hostname || '',\n      customer_id: state.customer.id || undefined,\n      route,\n      question_key: questionKey || undefined,\n      question_index: questionKey ? Number(questionKey.replace('q', '')) : undefined,\n      answer_ids: answerIds,\n      answers: serializeAnswersForStorage(),\n      lead: {\n        email: (state.lead.email || '').trim() || undefined,\n        first_name: (state.lead.firstName || '').trim() || undefined,\n      },\n      personalization: state.personalization || undefined,\n      completed: Boolean(options.completed),\n      event_type: eventType,\n      metadata,\n    };\n\n    return payload;\n  }\n\n  async function sendTrackPayload(payload) {\n    const endpoint = getQuizTrackEndpoint();\n    if (!endpoint) {\n      return false;\n    }\n\n    try {\n      const response = await fetch(endpoint, {\n        method: 'POST',\n        headers: {\n          'Content-Type': 'application/json',\n        },\n        body: JSON.stringify(payload),\n        keepalive: true,\n      });\n      return response.ok;\n    } catch (error) {\n      return false;\n    }\n  }\n\n  function queueTrackEvent(eventType, options = {}) {\n    const payload = buildTrackPayload(eventType, options);\n    const signature = JSON.stringify({\n      event_type: payload.event_type,\n      route: payload.route,\n      question_key: payload.question_key,\n      answer_ids: payload.answer_ids,\n      completed: payload.completed,\n      session_id: payload.session_id,\n      lead_email: payload.lead && payload.lead.email ? payload.lead.email : '',\n    });\n\n    if (signature === state.tracking.lastPayloadSignature && !payload.completed) {\n      return;\n    }\n\n    state.tracking.lastPayloadSignature = signature;\n    if (state.tracking.debounceId) {\n      window.clearTimeout(state.tracking.debounceId);\n    }\n\n    state.tracking.debounceId = window.setTimeout(() => {\n      sendTrackPayload(payload);\n      state.tracking.debounceId = null;\n    }, 140);\n  }\n\n  async function syncQuizCompletion(options = {}) {\n    const endpoint = getQuizCompleteEndpoint();\n    if (!endpoint) {\n      return false;\n    }\n\n    const payload = {\n      session_id: ensureTrackingSessionId(),\n      shop_domain: window.location.hostname || '',\n      lead: {\n        email: (state.lead.email || '').trim() || undefined,\n        first_name: (state.lead.firstName || '').trim() || undefined,\n      },\n      answers: serializeAnswersForStorage(),\n      personalization: options.personalization || state.personalization || undefined,\n      metadata: options.metadata || undefined,\n    };\n\n    try {\n      const response = await fetch(endpoint, {\n        method: 'POST',\n        headers: {\n          'Content-Type': 'application/json',\n        },\n        body: JSON.stringify(payload),\n        keepalive: true,\n      });\n      if (response.ok) {\n        try {\n          const body = await response.json();\n          if (body && body.discount_code && typeof body.discount_code === 'string') {\n            state.personalDiscountCode = body.discount_code.trim().toUpperCase();\n          }\n        } catch (_) {\n          /* response may not be JSON \u2014 ignore */\n        }\n        return true;\n      }\n      return false;\n    } catch (error) {\n      return false;\n    }\n  }\n\n  function sanitizeQuizAnswers(rawAnswers) {\n    const normalized = {};\n\n    QUESTION_ROUTE_MAP.forEach((step) => {\n      if (step.route === 'q12') {\n        return;\n      }\n\n      const source = rawAnswers && rawAnswers[step.route];\n      normalized[step.route] = Array.isArray(source) ? source.filter((entry) => typeof entry === 'string') : [];\n    });\n\n    const sourceQ12 =\n      rawAnswers && rawAnswers.q12 && typeof rawAnswers.q12 === 'object' && !Array.isArray(rawAnswers.q12)\n        ? rawAnswers.q12\n        : {};\n    normalized.q12 = {\n      age: typeof sourceQ12.age === 'string' ? sourceQ12.age : '',\n      gender: typeof sourceQ12.gender === 'string' ? sourceQ12.gender : '',\n      femaleConditions: Array.isArray(sourceQ12.femaleConditions)\n        ? sourceQ12.femaleConditions.filter((entry) => typeof entry === 'string')\n        : [],\n    };\n\n    return normalized;\n  }\n\n  function serializeAnswersForStorage() {\n    return sanitizeQuizAnswers(state.answers);\n  }\n\n  function buildSessionSnapshot(personalization = state.personalization) {\n    return {\n      version: 2,\n      capturedAt: new Date().toISOString(),\n      answers: serializeAnswersForStorage(),\n      lead: {\n        firstName: state.lead.firstName || '',\n        email: state.lead.email || '',\n        optIn: Boolean(state.lead.optIn),\n      },\n      purchaseMode: state.purchaseMode === 'onetime' ? 'onetime' : 'subscribe',\n      selectedPlanKey: typeof state.selectedPlanKey === 'string' ? state.selectedPlanKey : 'recommended_3',\n      subscribeQuantity: Number.isFinite(Number(state.subscribeQuantity)) ? Number(state.subscribeQuantity) : 1,\n      showUpgradePlan: Boolean(state.showUpgradePlan),\n      personalDiscountCode: state.personalDiscountCode || '',\n      personalization: personalization || null,\n    };\n  }\n\n  function persistSessionSnapshot(personalization = state.personalization) {\n    writeStorageJson(getSessionStorage(), SESSION_SNAPSHOT_KEY, buildSessionSnapshot(personalization));\n  }\n\n  function loadSessionSnapshot() {\n    const snapshot = readStorageJson(getSessionStorage(), SESSION_SNAPSHOT_KEY);\n    if (!snapshot || typeof snapshot !== 'object' || !snapshot.answers || typeof snapshot.answers !== 'object') {\n      return null;\n    }\n\n    const personalization = snapshot.personalization;\n    if (personalization !== null && typeof personalization !== 'object') {\n      snapshot.personalization = null;\n    }\n\n    return snapshot;\n  }\n\n  function hydrateStateFromSessionSnapshot() {\n    const snapshot = loadSessionSnapshot();\n    if (!snapshot) {\n      return false;\n    }\n\n    state.answers = sanitizeQuizAnswers(snapshot.answers);\n\n    if (snapshot.lead && typeof snapshot.lead.firstName === 'string') {\n      state.lead.firstName = snapshot.lead.firstName;\n    }\n    if (snapshot.lead && typeof snapshot.lead.email === 'string') {\n      state.lead.email = snapshot.lead.email;\n    }\n    if (snapshot.purchaseMode === 'onetime' || snapshot.purchaseMode === 'subscribe') {\n      state.purchaseMode = snapshot.purchaseMode;\n    }\n    if (typeof snapshot.selectedPlanKey === 'string' && snapshot.selectedPlanKey.trim()) {\n      state.selectedPlanKey = snapshot.selectedPlanKey.trim();\n    }\n    if (typeof snapshot.showUpgradePlan === 'boolean') {\n      state.showUpgradePlan = snapshot.showUpgradePlan;\n    }\n\n    if (typeof snapshot.personalDiscountCode === 'string' && snapshot.personalDiscountCode) {\n      state.personalDiscountCode = snapshot.personalDiscountCode;\n    }\n\n    if (snapshot.personalization && typeof snapshot.personalization === 'object') {\n      state.personalization = snapshot.personalization;\n    } else {\n      state.personalization = null;\n    }\n\n    return true;\n  }\n\n  function clearSessionSnapshot() {\n    clearStorageKey(getSessionStorage(), SESSION_SNAPSHOT_KEY);\n  }\n\n  function buildPendingAuthSnapshot(provider) {\n    return {\n      ...buildSessionSnapshot(state.personalization || getPersonalization()),\n      provider: provider || 'google',\n      pendingAt: new Date().toISOString(),\n      metafieldSyncEndpoint: METAFIELD_SYNC_ENDPOINT || '',\n    };\n  }\n\n  function persistPendingAuthSnapshot(provider) {\n    const snapshot = buildPendingAuthSnapshot(provider);\n    writeStorageJson(getSessionStorage(), PENDING_AUTH_KEY, snapshot);\n    writeStorageJson(getLocalStorage(), LEGACY_PENDING_AUTH_KEY, snapshot);\n    setPendingQuizCookie();\n  }\n\n  function loadPendingAuthSnapshot() {\n    const storages = [getSessionStorage(), getLocalStorage()];\n    const keys = [PENDING_AUTH_KEY, LEGACY_PENDING_AUTH_KEY];\n\n    for (let storageIndex = 0; storageIndex < storages.length; storageIndex += 1) {\n      const storage = storages[storageIndex];\n      for (let keyIndex = 0; keyIndex < keys.length; keyIndex += 1) {\n        const snapshot = readStorageJson(storage, keys[keyIndex]);\n        if (snapshot && typeof snapshot === 'object' && snapshot.answers && typeof snapshot.answers === 'object') {\n          return snapshot;\n        }\n      }\n    }\n\n    return null;\n  }\n\n  function clearPendingAuthSnapshot() {\n    clearStorageKey(getSessionStorage(), PENDING_AUTH_KEY);\n    clearStorageKey(getSessionStorage(), LEGACY_PENDING_AUTH_KEY);\n    clearStorageKey(getLocalStorage(), PENDING_AUTH_KEY);\n    clearStorageKey(getLocalStorage(), LEGACY_PENDING_AUTH_KEY);\n    clearPendingQuizCookie();\n  }\n\n  function hydrateLeadFromCustomer() {\n    if (!state.customer.loggedIn) {\n      return;\n    }\n\n    if (!state.lead.firstName && state.customer.firstName) {\n      state.lead.firstName = state.customer.firstName;\n    }\n    if (!state.lead.email && state.customer.email) {\n      state.lead.email = state.customer.email;\n    }\n  }\n\n  function parseJsonString(rawValue) {\n    if (!rawValue || typeof rawValue !== 'string') {\n      return null;\n    }\n\n    try {\n      const parsed = JSON.parse(rawValue);\n      if (typeof parsed === 'string') {\n        try {\n          return JSON.parse(parsed);\n        } catch (error) {\n          return parsed;\n        }\n      }\n      return parsed;\n    } catch (error) {\n      return null;\n    }\n  }\n\n  function pickFirstValue(...values) {\n    for (let index = 0; index < values.length; index += 1) {\n      const value = values[index];\n      if (value === null || value === undefined) {\n        continue;\n      }\n      if (typeof value === 'string' && value.trim() === '') {\n        continue;\n      }\n      return value;\n    }\n    return '';\n  }\n\n  function getCustomerPrefillState() {\n    if (state.customer.prefillState && typeof state.customer.prefillState === 'object') {\n      return state.customer.prefillState;\n    }\n\n    const parsed = parseJsonString(state.customer.prefillStateRaw || '');\n    if (parsed && typeof parsed === 'object') {\n      state.customer.prefillState = parsed;\n      return parsed;\n    }\n\n    state.customer.prefillState = {};\n    return state.customer.prefillState;\n  }\n\n  function normalizeBundleIds(bundleIds) {\n    const rawList = Array.isArray(bundleIds) ? bundleIds : [];\n    const asStrings = rawList\n      .map((entry) => String(entry || '').trim())\n      .filter((entry) => entry.length > 0);\n    return Array.from(new Set(asStrings));\n  }\n\n  function parseStoredBundle(rawBundle) {\n    if (Array.isArray(rawBundle)) {\n      return {\n        bundleKey: '',\n        variantIds: rawBundle.filter((entry) => Number.isFinite(Number(entry))).map((entry) => Number(entry)),\n      };\n    }\n\n    if (rawBundle && typeof rawBundle === 'object') {\n      const variantIds = Array.isArray(rawBundle.variant_ids)\n        ? rawBundle.variant_ids.filter((entry) => Number.isFinite(Number(entry))).map((entry) => Number(entry))\n        : [];\n      const bundleKey = typeof rawBundle.bundle_key === 'string' ? rawBundle.bundle_key : '';\n      return {\n        bundleKey,\n        variantIds,\n      };\n    }\n\n    if (!rawBundle || typeof rawBundle !== 'string') {\n      return {\n        bundleKey: '',\n        variantIds: [],\n      };\n    }\n\n    const parsed = parseJsonString(rawBundle);\n    if (parsed && parsed !== rawBundle) {\n      return parseStoredBundle(parsed);\n    }\n\n    const normalizedCsv = rawBundle\n      .split(',')\n      .map((entry) => entry.trim())\n      .filter((entry) => entry.length > 0);\n    const csvVariantIds = normalizedCsv.filter((entry) => Number.isFinite(Number(entry))).map((entry) => Number(entry));\n    if (csvVariantIds.length && csvVariantIds.length === normalizedCsv.length) {\n      return {\n        bundleKey: '',\n        variantIds: csvVariantIds,\n      };\n    }\n\n    return {\n      bundleKey: rawBundle.trim(),\n      variantIds: [],\n    };\n  }\n\n  function hydrateStateFromCustomerMetafields() {\n    if (!state.customer.loggedIn) {\n      return false;\n    }\n\n    const prefill = getCustomerPrefillState();\n\n    const rawAnswers = pickFirstValue(prefill.quiz_answers, prefill.quizAnswers, state.customer.metafields.quizAnswers);\n    const parsedAnswers =\n      rawAnswers && typeof rawAnswers === 'object' ? rawAnswers : parseJsonString(String(rawAnswers || ''));\n    if (parsedAnswers && typeof parsedAnswers === 'object') {\n      state.answers = sanitizeQuizAnswers(parsedAnswers);\n    }\n    hydrateLeadFromCustomer();\n\n    const rawProfileType = pickFirstValue(\n      prefill.profile_type,\n      prefill.profileType,\n      state.customer.metafields.profileType,\n      state.customer.metafields.quizProfile\n    );\n    const rawSpecialistName = pickFirstValue(\n      prefill.specialist_name,\n      prefill.specialistName,\n      state.customer.metafields.specialistName,\n      state.customer.metafields.assignedSpecialist\n    );\n    const rawBundleIds = pickFirstValue(\n      prefill.bundle_ids,\n      prefill.bundleIds,\n      state.customer.metafields.bundleIds,\n      state.customer.metafields.recommendedBundle\n    );\n    const rawBundleKey = pickFirstValue(prefill.bundle_key, prefill.bundleKey, '');\n\n    const storedProfileKey = parseProfileKey(typeof rawProfileType === 'string' ? rawProfileType : '');\n    const storedSpecialist = typeof rawSpecialistName === 'string' ? rawSpecialistName.trim() : '';\n    const storedBundle = parseStoredBundle(rawBundleIds);\n\n    if (!storedProfileKey && !hasCollectedQuizData()) {\n      return false;\n    }\n\n    state.personalization = buildPersonalizationEngine({\n      forceProfileKey: storedProfileKey || undefined,\n      forceBundleKey:\n        (typeof rawBundleKey === 'string' && rawBundleKey.trim() ? rawBundleKey.trim() : storedBundle.bundleKey) ||\n        undefined,\n      forceSpecialist: storedSpecialist || undefined,\n      forceVariantIds: storedBundle.variantIds,\n    });\n\n    if (!state.personalization) {\n      return false;\n    }\n\n    persistSessionSnapshot(state.personalization);\n    return true;\n  }\n\n  function hydrateStateFromPendingAuthSnapshot() {\n    const snapshot = loadPendingAuthSnapshot();\n    if (!snapshot) {\n      return false;\n    }\n\n    state.answers = sanitizeQuizAnswers(snapshot.answers);\n    if (snapshot.lead && typeof snapshot.lead.firstName === 'string') {\n      state.lead.firstName = snapshot.lead.firstName;\n    }\n    if (snapshot.lead && typeof snapshot.lead.email === 'string') {\n      state.lead.email = snapshot.lead.email;\n    }\n    if (snapshot.lead && typeof snapshot.lead.optIn === 'boolean') {\n      state.lead.optIn = snapshot.lead.optIn;\n    }\n    if (snapshot.purchaseMode === 'onetime' || snapshot.purchaseMode === 'subscribe') {\n      state.purchaseMode = snapshot.purchaseMode;\n    }\n    if (typeof snapshot.selectedPlanKey === 'string' && snapshot.selectedPlanKey.trim()) {\n      state.selectedPlanKey = snapshot.selectedPlanKey.trim();\n    }\n    if (typeof snapshot.showUpgradePlan === 'boolean') {\n      state.showUpgradePlan = snapshot.showUpgradePlan;\n    }\n    if (typeof snapshot.personalDiscountCode === 'string' && snapshot.personalDiscountCode) {\n      state.personalDiscountCode = snapshot.personalDiscountCode;\n    }\n    if (snapshot.personalization && typeof snapshot.personalization === 'object') {\n      state.personalization = snapshot.personalization;\n    } else {\n      state.personalization = null;\n    }\n\n    hydrateLeadFromCustomer();\n    persistSessionSnapshot(state.personalization);\n    return true;\n  }\n\n  function markPostAuthSyncCompleted() {\n    const storage = getSessionStorage();\n    if (!storage) {\n      return;\n    }\n\n    try {\n      storage.setItem(AUTH_SYNC_COMPLETED_KEY, '1');\n    } catch (error) {\n      // Ignore storage write failures.\n    }\n  }\n\n  function hasPostAuthSyncCompleted() {\n    const storage = getSessionStorage();\n    if (!storage) {\n      return false;\n    }\n\n    try {\n      return storage.getItem(AUTH_SYNC_COMPLETED_KEY) === '1';\n    } catch (error) {\n      return false;\n    }\n  }\n\n  function resetQuizSession() {\n    stopResultsTimer();\n\n    state.answers = {};\n    state.personalization = null;\n    state.lead = {\n      firstName: '',\n      email: '',\n      optIn: true,\n    };\n    state.purchaseMode = 'subscribe';\n    state.selectedPlanKey = 'recommended_3';\n    state.subscribeQuantity = 1;\n    state.showUpgradePlan = false;\n    state.cartBusy = false;\n    state.submitting = false;\n    state.timer.startedAt = null;\n    state.timer.expiresAt = null;\n    state.timer.nodes = [];\n    state.timer.expiredNodes = [];\n    state.timer.codeNodes = [];\n    state.timer.shellNodes = [];\n    state.timer.appliedNodes = [];\n    state.resultsLineItems = [];\n    state.cadenceProductStatus = state.cadenceProduct ? 'ready' : 'idle';\n    state.manualDiscountCode = '';\n    state.manualDiscountPercent = null;\n    state.summaryExpanded = true;\n    state.scienceExpanded = false;\n    state.metafieldSync = {\n      attempted: false,\n      synced: false,\n    };\n\n    clearSessionSnapshot();\n    clearPendingAuthSnapshot();\n    clearStorageKey(getSessionStorage(), AUTH_SYNC_COMPLETED_KEY);\n    clearStorageKey(getSessionStorage(), TIMER_STORAGE_KEY);\n    clearStorageKey(getSessionStorage(), 'evolance_reco_animated');\n    rotateTrackingSessionId();\n  }\n\n  function canonicalizeRoute(rawRoute) {\n    if (isRecommendationsMode) {\n      return 'results';\n    }\n\n    if (!rawRoute) {\n      return 'q1';\n    }\n\n    const trimmed = rawRoute.toLowerCase().trim();\n\n    if (trimmed === 'start' || trimmed === 'landing' || trimmed === 'intro') {\n      return 'q1';\n    }\n\n    if (trimmed === 'email' || trimmed === 'email-gate') {\n      return 'q12';\n    }\n\n    if (trimmed === 'result' || trimmed === 'results') {\n      return isRecommendationsMode ? 'results' : 'q1';\n    }\n\n    const matchedQuestion = trimmed.match(/^q(?:uestion)?-?(\\d{1,2})$/);\n    if (matchedQuestion) {\n      const numeric = Number(matchedQuestion[1]);\n      if (numeric >= 1 && numeric <= TOTAL_QUESTIONS) {\n        return `q${numeric}`;\n      }\n    }\n\n    if (ROUTE_ORDER.includes(trimmed)) {\n      return trimmed;\n    }\n\n    return 'q1';\n  }\n\n  function getRouteFromLocation() {\n    if (isRecommendationsMode) {\n      return 'results';\n    }\n\n    const path = window.location.pathname.toLowerCase();\n    const params = new URLSearchParams(window.location.search);\n    const matchedBasePath = QUIZ_BASE_PATHS.find(\n      (basePath) => path === basePath || path.startsWith(`${basePath}/`)\n    );\n\n    if (matchedBasePath) {\n      const pathRoute = path.startsWith(`${matchedBasePath}/`)\n        ? path.replace(`${matchedBasePath}/`, '').split('/')[0]\n        : '';\n      return canonicalizeRoute(params.get('route') || pathRoute || 'q1');\n    }\n\n    return 'q1';\n  }\n\n  function getPrettyPath(route) {\n    if (isRecommendationsMode) {\n      if (isRecommendationsAppMode && !isRecommendationsPathMatch) {\n        return window.location.pathname || RECOMMENDATIONS_PATH || '/pages/recommendations';\n      }\n      return RECOMMENDATIONS_PATH || window.location.pathname || '/pages/recommendations';\n    }\n\n    if (route === 'q1') {\n      return quizBasePath;\n    }\n\n    return `${quizBasePath}?route=${encodeURIComponent(route)}`;\n  }\n\n  function setRoute(route, options = {}) {\n    let nextRoute = canonicalizeRoute(route);\n    if (nextRoute === 'email') {\n      nextRoute = 'q12';\n    }\n    if (!isRecommendationsMode && nextRoute === 'results') {\n      nextRoute = 'q1';\n    }\n    const replace = Boolean(options.replace);\n    const shouldTrackPageView = options.trackPageView !== false;\n    const isNewSessionEntry = nextRoute === 'q1' && !hasCollectedQuizData() && !state.personalization;\n\n    if (isNewSessionEntry) {\n      resetQuizSession();\n    }\n\n    state.currentRoute = nextRoute;\n\n    const targetPath = getPrettyPath(nextRoute);\n    const historyMethod = replace ? 'replaceState' : 'pushState';\n    const statePayload = { evq: true, route: nextRoute };\n\n    const shouldMutateHistory = !(isThemeEditor && isRecommendationsMode);\n    if (shouldMutateHistory) {\n      try {\n        window.history[historyMethod](statePayload, '', targetPath);\n      } catch (error) {\n        const fallback = `${quizBasePath}?route=${encodeURIComponent(nextRoute)}`;\n        try {\n          window.history[historyMethod](statePayload, '', fallback);\n        } catch (fallbackError) {\n          // Theme editor and embedded previews can block History API updates.\n        }\n      }\n    }\n\n    if (shouldTrackPageView) {\n      queueTrackEvent('PAGE_VIEW', {\n        route: nextRoute,\n        questionKey: resolveQuestionKey(nextRoute) || undefined,\n      });\n    }\n    render();\n  }\n\n  function getRouteIndex(route) {\n    return ROUTE_ORDER.indexOf(route);\n  }\n\n  function getPreviousRoute(route) {\n    const index = getRouteIndex(route);\n    if (index <= 0) {\n      return null;\n    }\n\n    return ROUTE_ORDER[index - 1];\n  }\n\n  function getNextRoute(route) {\n    const index = getRouteIndex(route);\n    if (index < 0 || index >= ROUTE_ORDER.length - 1) {\n      return null;\n    }\n\n    return ROUTE_ORDER[index + 1];\n  }\n\n  function ensureRouteAnswer(route) {\n    if (!state.answers[route]) {\n      state.answers[route] = [];\n    }\n\n    return state.answers[route];\n  }\n\n  function hasCollectedQuizData() {\n    return Object.values(state.answers).some((value) => {\n      if (Array.isArray(value)) {\n        return value.length > 0;\n      }\n\n      if (value && typeof value === 'object') {\n        return Object.values(value).some((entry) => {\n          if (Array.isArray(entry)) {\n            return entry.length > 0;\n          }\n          return Boolean(entry);\n        });\n      }\n\n      return Boolean(value);\n    });\n  }\n\n  function getQuestionProgress(route) {\n    const mapEntry = QUESTION_ROUTE_MAP.find((entry) => entry.route === route);\n    if (mapEntry) {\n      return mapEntry.step;\n    }\n\n    return TOTAL_QUESTIONS;\n  }\n\n  function ensureProgressNodes() {\n    if (!headerCounter || !headerCounter.isConnected) {\n      headerCounter = root.querySelector('[data-evq-counter]');\n    }\n\n    if (!progressFill || !progressFill.isConnected) {\n      progressFill = root.querySelector('[data-evq-progress-fill]');\n    }\n\n    if (!progressTrack || !progressTrack.isConnected) {\n      progressTrack = root.querySelector('.evq-progress');\n    }\n  }\n\n  function setProgressUI(route) {\n    ensureProgressNodes();\n\n    const step = getQuestionProgress(route);\n    const normalizedStep = Math.max(0, Math.min(step, TOTAL_QUESTIONS));\n    const progress = Math.min(100, Math.round((normalizedStep / TOTAL_QUESTIONS) * 100));\n\n    const progressWidth = `${progress}%`;\n    root.style.setProperty('--evq-progress-width', progressWidth);\n    if (progressTrack) {\n      progressTrack.style.setProperty(\n        'background',\n        `linear-gradient(90deg, var(--evq-green, #345248) 0%, var(--evq-green, #345248) ${progressWidth}, var(--evq-track, #dadcde) ${progressWidth}, var(--evq-track, #dadcde) 100%)`,\n        'important'\n      );\n    }\n    if (progressFill) {\n      progressFill.style.setProperty('width', progressWidth, 'important');\n    }\n    if (headerCounter) {\n      headerCounter.textContent = `${normalizedStep} of ${TOTAL_QUESTIONS}`;\n    }\n  }\n\n  function clearElement(node) {\n    while (node.firstChild) {\n      node.removeChild(node.firstChild);\n    }\n  }\n\n  function setTextForNodes(selector, value) {\n    const text = String(value || '');\n    document.querySelectorAll(selector).forEach((node) => {\n      node.textContent = text;\n    });\n  }\n\n  function setHtmlForNodes(selector, html) {\n    const content = String(html || '');\n    document.querySelectorAll(selector).forEach((node) => {\n      node.innerHTML = content;\n    });\n  }\n\n  function toNodeArray(nodesOrNode) {\n    if (!nodesOrNode) {\n      return [];\n    }\n    if (Array.isArray(nodesOrNode)) {\n      return nodesOrNode.filter(Boolean);\n    }\n    if (typeof nodesOrNode.length === 'number' && !nodesOrNode.nodeType) {\n      return Array.from(nodesOrNode).filter(Boolean);\n    }\n    return [nodesOrNode];\n  }\n\n  function setInlineFeedback(nodesOrNode, message, stateType = 'info') {\n    const nodes = toNodeArray(nodesOrNode);\n    const text = String(message || '').trim();\n    const hasText = Boolean(text);\n    const isError = stateType === 'error';\n    nodes.forEach((node) => {\n      node.textContent = text;\n      node.classList.toggle('evr-hidden', !hasText);\n      if (hasText) {\n        node.removeAttribute('hidden');\n        node.setAttribute('data-state', stateType);\n        node.setAttribute('role', isError ? 'alert' : 'status');\n        node.setAttribute('aria-live', isError ? 'assertive' : 'polite');\n        node.setAttribute('aria-atomic', 'true');\n      } else {\n        node.setAttribute('hidden', 'hidden');\n        node.removeAttribute('data-state');\n        node.removeAttribute('role');\n        node.removeAttribute('aria-live');\n        node.removeAttribute('aria-atomic');\n      }\n    });\n  }\n\n  function safeFocus(node, options = { preventScroll: true }) {\n    if (!node || typeof node.focus !== 'function') {\n      return;\n    }\n    try {\n      node.focus(options);\n    } catch (error) {\n      try {\n        node.focus();\n      } catch (fallbackError) {\n        // Ignore focus fallback errors.\n      }\n    }\n  }\n\n  function safeSelect(inputNode) {\n    if (!inputNode || typeof inputNode.select !== 'function') {\n      return;\n    }\n    try {\n      inputNode.select();\n    } catch (error) {\n      // Ignore select failures on non-text-like inputs.\n    }\n  }\n\n  function normalizeV2ProfileKey(rawValue) {\n    const normalized = String(rawValue || '')\n      .trim()\n      .toLowerCase()\n      .replace(/\\+/g, ' ')\n      .replace(/[^a-z0-9_ ]+/g, ' ')\n      .replace(/\\s+/g, '_');\n    if (!normalized) {\n      return '';\n    }\n    if (normalized === 'all' || normalized === 'safety') {\n      return normalized;\n    }\n    return parseProfileKey(normalized) || normalized;\n  }\n\n  function getV2ProfilePriority(personalization) {\n    const priorities = [];\n    if (personalization && personalization.safetyGate) {\n      priorities.push('safety');\n    }\n    priorities.push(normalizeV2ProfileKey(personalization && personalization.profileKey));\n    priorities.push('all');\n    return Array.from(new Set(priorities.filter(Boolean)));\n  }\n\n  function readV2ProfileConfigs() {\n    const configs = [];\n    document.querySelectorAll('[data-evr-v2-profile-config]').forEach((node) => {\n      const raw = String(node.textContent || '').trim();\n      if (!raw) {\n        return;\n      }\n      try {\n        const parsed = JSON.parse(raw);\n        if (parsed && typeof parsed === 'object') {\n          configs.push(parsed);\n        }\n      } catch (error) {\n        // Ignore malformed profile config blocks.\n      }\n    });\n    return configs;\n  }\n\n  function getV2ProfileConfig(configId, personalization) {\n    const normalizedConfigId = String(configId || '').trim().toLowerCase();\n    if (!normalizedConfigId) {\n      return null;\n    }\n\n    const candidates = readV2ProfileConfigs().filter((config) => {\n      return String(config.configId || '')\n        .trim()\n        .toLowerCase() === normalizedConfigId;\n    });\n    if (!candidates.length) {\n      return null;\n    }\n\n    const priorities = getV2ProfilePriority(personalization);\n    for (let index = 0; index < priorities.length; index += 1) {\n      const targetProfile = priorities[index];\n      const match = candidates.find((config) => normalizeV2ProfileKey(config.profileKey) === targetProfile);\n      if (match) {\n        return match;\n      }\n    }\n\n    return candidates[0] || null;\n  }\n\n  function applyV2ProfileLayerVisibility(personalization) {\n    const priorities = getV2ProfilePriority(personalization);\n    const groupedLayers = new Map();\n\n    document.querySelectorAll('[data-evr-v2-profile-key]').forEach((layer) => {\n      let groupName = String(layer.getAttribute('data-evr-v2-profile-group') || '').trim();\n      if (!groupName) {\n        const parentGroup = layer.closest('[data-evr-v2-profile-group]');\n        if (parentGroup) {\n          groupName = String(parentGroup.getAttribute('data-evr-v2-profile-group') || '').trim();\n        }\n      }\n      if (!groupName) {\n        return;\n      }\n\n      if (!groupedLayers.has(groupName)) {\n        groupedLayers.set(groupName, []);\n      }\n\n      groupedLayers.get(groupName).push({\n        layer,\n        key: normalizeV2ProfileKey(layer.getAttribute('data-evr-v2-profile-key')),\n      });\n    });\n\n    groupedLayers.forEach((layers) => {\n      if (!layers.length) {\n        return;\n      }\n\n      let activeKey = '';\n      for (let index = 0; index < priorities.length; index += 1) {\n        const priority = priorities[index];\n        if (layers.some((entry) => entry.key === priority)) {\n          activeKey = priority;\n          break;\n        }\n      }\n\n      if (!activeKey) {\n        activeKey = layers[0].key;\n      }\n\n      layers.forEach((entry) => {\n        const isVisible = entry.key === activeKey;\n        entry.layer.classList.toggle('evr-hidden', !isVisible);\n        if (isVisible) {\n          entry.layer.removeAttribute('hidden');\n        } else {\n          entry.layer.setAttribute('hidden', 'hidden');\n        }\n      });\n    });\n  }\n\n  function hydrateV2ScoreReveal(personalization) {\n    var scoreReveal = document.querySelector('[data-evr-score-reveal]');\n    if (!scoreReveal || !personalization.quizScore) return;\n\n    var scoreValueNode = scoreReveal.querySelector('[data-evr-score-value]');\n    var scoreTierNode = scoreReveal.querySelector('[data-evr-score-tier]');\n    var scoreInterpNode = scoreReveal.querySelector('[data-evr-score-interpretation]');\n\n    if (scoreValueNode) scoreValueNode.textContent = personalization.quizScore;\n    if (scoreTierNode) {\n      scoreTierNode.textContent = personalization.scoreInterpretation.label;\n      scoreTierNode.style.color = personalization.scoreInterpretation.color;\n    }\n    if (scoreInterpNode) {\n      var score = personalization.quizScore;\n      var tier = personalization.scoreInterpretation.tier;\n      var interp = tier === 'severe'\n        ? 'Your sleep and stress patterns are significantly disrupted. The good news: at this level, targeted intervention typically shows the fastest improvement.'\n        : tier === 'moderate'\n        ? 'Your sleep quality is compromised but highly responsive to the right protocol. Many people at this level see meaningful changes within 2-4 weeks.'\n        : tier === 'mild'\n        ? 'Your patterns show mild disruption with room for improvement. A consistent routine can help you build lasting resilience.'\n        : 'Early signs of stress-sleep imbalance detected. Starting now prevents further decline and builds a stronger foundation.';\n      scoreInterpNode.textContent = interp;\n    }\n\n    scoreReveal.classList.remove('evr-hidden');\n    scoreReveal.removeAttribute('hidden');\n  }\n\n  function hydrateV2MechanismSection(personalization) {\n    var signalsContainer = document.querySelector('[data-evr-mechanism-signals]');\n    var bodyContainer = document.querySelector('[data-evr-mechanism-body]');\n    if (!signalsContainer && !bodyContainer) return;\n\n    var appliedRules = personalization.appliedRules || [];\n    var displayRules = appliedRules.filter(function (id) {\n      return id.charAt(0) >= '1' && id.charAt(0) <= '6' && RULE_USER_COPY[id];\n    }).slice(0, 4);\n\n    if (signalsContainer) {\n      signalsContainer.innerHTML = '';\n      displayRules.forEach(function (id) {\n        var chip = document.createElement('span');\n        chip.className = 'evr-v2-mechanism__signal';\n        chip.textContent = RULE_USER_COPY[id];\n        signalsContainer.appendChild(chip);\n      });\n    }\n\n    if (bodyContainer) {\n      var issue = personalization.primaryIssue || { label: 'stress-disrupted sleep' };\n      var profileKey = personalization.profileKey || 'all';\n      var mechanismCopy = {\n        sleep_starter: 'Your pattern suggests difficulty transitioning from wakefulness to sleep. When your nervous system stays activated past bedtime, falling asleep becomes a struggle. The right combination of calming support can help ease this transition.',\n        sleep_restoration: 'Your responses point to fragmented sleep and nighttime awakenings. When cortisol spikes during the night, it pulls you out of deep sleep and disrupts recovery. Supporting overnight nervous-system stability is the key.',\n        complete_calm: 'Your quiz reveals both daytime stress accumulation and nighttime sleep disruption. This dual burden requires comprehensive support across the full day-to-night cycle to break the pattern.',\n        stress_recovery: 'Your answers indicate high daytime stress carrying over into evenings. When your stress load exceeds your recovery capacity, sleep becomes the first casualty. Targeting stress regulation first allows sleep to normalize.',\n        safety: 'Your responses have been noted. Because you indicated pregnancy or breastfeeding, any supplementation should be reviewed with your physician first.',\n      };\n      bodyContainer.innerHTML = '<p>' + escapeHtml(mechanismCopy[profileKey] || mechanismCopy.sleep_restoration) + '</p>';\n    }\n  }\n\n  function hydrateV2PrescriptionSection(personalization) {\n    var ingredientsContainer = document.querySelector('[data-evr-prescription-ingredients]');\n    var headlineNode = document.querySelector('[data-evr-prescription-headline]');\n    var subNode = document.querySelector('[data-evr-prescription-sub]');\n    if (!ingredientsContainer) return;\n\n    var profileLabel = personalization.profileLabel || 'Personalized';\n    if (headlineNode) headlineNode.textContent = 'Your profile matches the ' + profileLabel + ' Protocol';\n    if (subNode) subNode.textContent = 'Based on your ' + ((personalization.appliedRules || []).length) + ' data points, these ingredients were selected for your specific pattern.';\n\n    var ingredients = personalization.ingredientPriority || [];\n    var maxScore = ingredients.length ? ingredients[0].score : 1;\n\n    ingredientsContainer.innerHTML = '';\n    ingredients.forEach(function (ing, idx) {\n      var rawPct = Math.round((ing.score / (maxScore || 1)) * 100);\n      // Spread bars visually: primary 92%, supporting scale down from 72%\n      var pct = idx === 0 ? 92 : Math.max(45, Math.round(72 * rawPct / 100));\n      var reason = getPersonalizedIngredientReason(ing.key, personalization.appliedRules || []);\n      var isPrimary = idx === 0;\n\n      var card = document.createElement('div');\n      card.className = 'evr-v2-prescription__ing-card';\n\n      var head = document.createElement('div');\n      head.className = 'evr-v2-prescription__ing-head';\n\n      var name = document.createElement('h4');\n      name.className = 'evr-v2-prescription__ing-name';\n      name.textContent = (ing.label || ing.key) + ' \\u00B7 ' + (ing.dose || '');\n\n      var match = document.createElement('span');\n      match.className = 'evr-v2-prescription__ing-match';\n      match.textContent = isPrimary ? 'Primary match' : 'Supporting';\n\n      head.appendChild(name);\n      head.appendChild(match);\n\n      var barWrap = document.createElement('div');\n      barWrap.className = 'evr-v2-prescription__ing-bar';\n      var barFill = document.createElement('div');\n      barFill.className = 'evr-v2-prescription__ing-bar-fill';\n      barFill.style.width = pct + '%';\n      barWrap.appendChild(barFill);\n\n      var whyP = document.createElement('p');\n      whyP.className = 'evr-v2-prescription__ing-why';\n      whyP.textContent = ing.why || '';\n\n      card.appendChild(head);\n      card.appendChild(barWrap);\n      card.appendChild(whyP);\n\n      if (reason) {\n        var reasonP = document.createElement('p');\n        reasonP.className = 'evr-v2-prescription__ing-reason';\n        reasonP.textContent = '\\u2192 ' + reason;\n        card.appendChild(reasonP);\n      }\n\n      ingredientsContainer.appendChild(card);\n    });\n  }\n\n  function hydrateV2SocialProofSection(personalization) {\n    var container = document.querySelector('[data-evr-v2-social-testimonials]');\n    if (!container) return;\n\n    var testimonials = personalization.testimonials || [];\n    if (!testimonials.length) return;\n\n    container.innerHTML = '';\n    testimonials.slice(0, 3).forEach(function (t) {\n      var card = document.createElement('div');\n      card.className = 'evr-v2-social-proof__card';\n\n      var quote = document.createElement('p');\n      quote.className = 'evr-v2-social-proof__quote';\n      quote.textContent = t.quote;\n\n      var author = document.createElement('p');\n      author.className = 'evr-v2-social-proof__author';\n      author.textContent = '\\u2014 ' + (t.author || 'Verified Customer');\n\n      var context = document.createElement('p');\n      context.className = 'evr-v2-social-proof__context';\n      context.textContent = t.context || '';\n\n      card.appendChild(quote);\n      card.appendChild(author);\n      if (t.context) card.appendChild(context);\n      container.appendChild(card);\n    });\n\n    var toggleBtn = document.querySelector('[data-evr-social-toggle]');\n    if (toggleBtn && testimonials.length > 1) {\n      toggleBtn.addEventListener('click', function () {\n        container.classList.add('is-expanded');\n        toggleBtn.classList.add('is-expanded');\n      });\n    } else if (toggleBtn) {\n      toggleBtn.style.display = 'none';\n    }\n  }\n\n  /* \u2500\u2500 V3 Titan Hydration Functions \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 */\n\n  var V3_PROFILE_HEADLINES = {\n    sleep_restoration: 'Your body knows how to sleep through the night. It may just need the right form of magnesium.',\n    complete_calm: 'Your stress isn\\u2019t just ruining your day \\u2014 it\\u2019s stealing your sleep. Here\\u2019s what breaks the cycle.',\n    stress_recovery: 'One formula. Three clinical-dose ingredients. Zero morning fog.',\n    sleep_starter: 'The 64% absorption difference your current supplement is missing.',\n    safety: 'Please consult your physician before starting any supplement routine.',\n    all: 'Your body knows how to sleep. It may just need the right support.',\n  };\n\n  function hydrateV3Diagnosis(p) {\n    var headlineNode = document.querySelector('[data-evr-v3-diagnosis-headline]');\n    if (headlineNode) {\n      var profileKey = normalizeV2ProfileKey(p.profileKey);\n      headlineNode.textContent = V3_PROFILE_HEADLINES[profileKey] || V3_PROFILE_HEADLINES.all;\n    }\n\n    var scoreReveal = document.querySelector('[data-evr-v3-score-reveal]');\n    if (!scoreReveal || !p.quizScore) return;\n\n    var scoreValueNode = scoreReveal.querySelector('[data-evr-v3-score-value]');\n    var scoreTierNode = scoreReveal.querySelector('[data-evr-v3-score-tier]');\n    var scoreInterpNode = scoreReveal.querySelector('[data-evr-v3-score-interpretation]');\n\n    if (scoreValueNode) scoreValueNode.textContent = p.quizScore;\n    if (scoreTierNode) {\n      scoreTierNode.textContent = p.scoreInterpretation.label;\n      scoreTierNode.style.color = p.scoreInterpretation.color;\n    }\n    if (scoreInterpNode) {\n      var tier = p.scoreInterpretation.tier;\n      var interp = tier === 'severe'\n        ? 'Your sleep and stress patterns are significantly disrupted. The good news: at this level, targeted intervention typically shows the fastest improvement.'\n        : tier === 'moderate'\n        ? 'Your sleep quality is compromised but highly responsive to the right protocol. Many people at this level see meaningful changes within 2\\u20134 weeks.'\n        : tier === 'mild'\n        ? 'Your patterns show mild disruption with room for improvement. A consistent routine can help you build lasting resilience.'\n        : 'Early signs of stress-sleep imbalance detected. Starting now prevents further decline and builds a stronger foundation.';\n      scoreInterpNode.textContent = interp;\n    }\n\n    scoreReveal.classList.remove('evr-hidden');\n    scoreReveal.removeAttribute('hidden');\n  }\n\n  function hydrateV3Findings(p) {\n    var container = document.querySelector('[data-evr-v3-findings]');\n    if (!container) return;\n\n    var primaryLabel = (p.primaryIssue && p.primaryIssue.label) || 'sleep difficulties';\n    var symptoms = getAnswerLabels('q7', 3);\n    var q2 = getAnswerArray('q2');\n    var q4 = getAnswerArray('q4');\n    var q5 = getAnswerArray('q5');\n    var q11 = getAnswerArray('q11');\n\n    var lines = [];\n\n    var CONCERN_OPENERS = {\n      'all-day stress': 'Living with all-day stress is exhausting \\u2014 it affects your energy, your mood, and your sleep.',\n      'a busy mind at night': 'A busy mind at bedtime can feel like a cycle you can\\u2019t break \\u2014 many people describe it as a mind that won\\u2019t shut off.',\n      'nighttime awakenings': 'Waking up in the middle of the night and not being able to fall back asleep is deeply frustrating \\u2014 especially when it becomes the norm.',\n      'sleep onset delay': 'Lying awake waiting for sleep to come is one of the most draining struggles \\u2014 the harder you try, the worse it gets.',\n      'stress-related tension': 'When stress lives in your body as tension, it\\u2019s hard to truly relax, even when you\\u2019re exhausted.',\n      'stress-disrupted sleep': 'When stress and sleep problems feed each other, it can feel like there\\u2019s no way out of the cycle.',\n    };\n    lines.push(CONCERN_OPENERS[primaryLabel] || CONCERN_OPENERS['stress-disrupted sleep']);\n\n    var blockerLines = [];\n    if (q2.indexOf('racing_thoughts') !== -1) blockerLines.push('a mind that won\\u2019t quiet down');\n    if (q2.indexOf('worry_anxiety') !== -1) blockerLines.push('worry that follows you to bed');\n    if (q2.indexOf('physical_tension') !== -1) blockerLines.push('physical tension you can\\u2019t shake');\n    if (q2.indexOf('screen_time') !== -1) blockerLines.push('screen time that pushes back your wind-down');\n    if (blockerLines.length) {\n      lines.push('At bedtime, you\\u2019re dealing with ' + blockerLines.join(', ') + '. That\\u2019s a lot working against you.');\n    }\n\n    if (symptoms.length && symptoms[0] !== 'None of these') {\n      var symptomStr = symptoms.map(function (s) { return s.toLowerCase(); }).join(', ');\n      lines.push('Your body is also signaling through ' + symptomStr + ' \\u2014 these often go hand in hand.');\n    }\n\n    var stressorLines = [];\n    if (q5.indexOf('work_demands') !== -1) stressorLines.push('work pressure');\n    if (q5.indexOf('family_relationships') !== -1) stressorLines.push('family demands');\n    if (q5.indexOf('financial_pressures') !== -1) stressorLines.push('financial stress');\n    if (q5.indexOf('overthinking_future') !== -1) stressorLines.push('overthinking');\n    if (q5.indexOf('no_time_for_self') !== -1) stressorLines.push('no time for yourself');\n    if (stressorLines.length >= 2) {\n      lines.push('Between ' + stressorLines.slice(0, 2).join(' and ') + ', your nervous system rarely gets a real break.');\n    }\n\n    if (q4.indexOf('down_low_energy') !== -1 && q4.indexOf('stressed_overwhelmed') !== -1) {\n      lines.push('Feeling both drained and overwhelmed during the day is a sign the cycle has been running for a while.');\n    } else if (q4.indexOf('down_low_energy') !== -1) {\n      lines.push('Low energy during the day often traces back to what\\u2019s happening at night.');\n    } else if (q4.indexOf('stressed_overwhelmed') !== -1) {\n      lines.push('Feeling overwhelmed during the day makes everything harder \\u2014 you\\u2019re not alone in this.');\n    }\n\n    if (q11.indexOf('time_all_day_stress') !== -1) {\n      lines.push('The fact that stress follows you from morning to night tells us this isn\\u2019t just a sleep issue \\u2014 it\\u2019s a full-day pattern.');\n    }\n\n    lines.push('Without the right support, this pattern typically compounds \\u2014 not resolves on its own.');\n    lines.push('The good news: your answers reveal a clear pattern, and clear patterns mean targeted solutions.');\n\n    clearElement(container);\n    lines.forEach(function (line, idx) {\n      var p = document.createElement('p');\n      p.className = idx === lines.length - 1 ? 'evr-v3-findings__bridge' : 'evr-v3-findings__concern';\n      p.textContent = line;\n      container.appendChild(p);\n    });\n  }\n\n  function hydrateV3Mechanism(p) {\n    var mechanismRoot = document.querySelector('[data-evr-v3-mechanism]');\n    if (!mechanismRoot) return;\n\n    var signalsContainer = mechanismRoot.querySelector('[data-evr-v3-mechanism-signals]');\n    if (signalsContainer) {\n      var appliedRules = p.appliedRules || [];\n      var displayRules = appliedRules.filter(function (id) {\n        return id.charAt(0) >= '1' && id.charAt(0) <= '6' && RULE_USER_COPY[id];\n      }).slice(0, 4);\n\n      signalsContainer.innerHTML = '';\n      displayRules.forEach(function (id) {\n        var chip = document.createElement('span');\n        chip.className = 'evr-v3-mechanism__signal';\n        chip.textContent = RULE_USER_COPY[id];\n        signalsContainer.appendChild(chip);\n      });\n    }\n\n    var q10 = getAnswerArray('q10');\n    var hasMelatonin = q10.indexOf('attempt_melatonin') !== -1;\n    var hasMagnesium = q10.indexOf('attempt_magnesium') !== -1;\n\n    var melPanel = mechanismRoot.querySelector('[data-evr-v3-mechanism-melatonin]');\n    var magPanel = mechanismRoot.querySelector('[data-evr-v3-mechanism-magnesium]');\n    var stackPanel = mechanismRoot.querySelector('[data-evr-v3-mechanism-stack]');\n\n    if (melPanel && hasMelatonin) { melPanel.classList.remove('evr-hidden'); melPanel.removeAttribute('hidden'); }\n    if (magPanel && hasMagnesium) { magPanel.classList.remove('evr-hidden'); magPanel.removeAttribute('hidden'); }\n    if (stackPanel && hasMelatonin && hasMagnesium) { stackPanel.classList.remove('evr-hidden'); stackPanel.removeAttribute('hidden'); }\n  }\n\n  function hydrateV3Strengths(p) {\n    var container = document.querySelector('[data-evr-v3-strengths]');\n    if (!container) return;\n\n    var positives = [];\n    var q3 = getAnswerArray('q3');\n    var q4 = getAnswerArray('q4');\n    var q10 = getAnswerArray('q10');\n    var q2 = getAnswerArray('q2');\n\n    if (q3.indexOf('wake_refreshed') !== -1) positives.push('You sometimes wake up feeling refreshed \\u2014 a sign your body can recover');\n    if (q4.indexOf('calm_in_control') !== -1 || q4.indexOf('balanced_overall') !== -1) positives.push('You experience moments of calm during the day \\u2014 a good foundation');\n    if (q10.indexOf('attempt_exercise_lifestyle') !== -1) positives.push('You\\u2019ve tried exercise & lifestyle changes \\u2014 showing real commitment');\n    if (q10.indexOf('attempt_sleep_hygiene') !== -1) positives.push('You\\u2019ve worked on sleep hygiene \\u2014 smart approach to foundations first');\n    if (q10.indexOf('attempt_therapy') !== -1) positives.push('You\\u2019ve explored therapy \\u2014 that takes courage and shows self-awareness');\n    if (q2.indexOf('caffeine') === -1) positives.push('Your evening routine doesn\\u2019t include caffeine \\u2014 that\\u2019s a plus for sleep quality');\n\n    if (!positives.length) positives.push('You took this quiz \\u2014 that\\u2019s the first step toward better sleep');\n\n    var items = positives.slice(0, 4);\n    clearElement(container);\n    items.forEach(function (text) {\n      var item = document.createElement('div');\n      item.className = 'evr-v3-strengths__item';\n      var icon = document.createElement('span');\n      icon.className = 'evr-v3-strengths__icon';\n      icon.textContent = '\\u2713';\n      var textEl = document.createElement('p');\n      textEl.className = 'evr-v3-strengths__text';\n      textEl.textContent = text;\n      item.appendChild(icon);\n      item.appendChild(textEl);\n      container.appendChild(item);\n    });\n  }\n\n  function hydrateV3Prescription(p) {\n    var container = document.querySelector('[data-evr-v3-prescription-ingredients]');\n    var headlineNode = document.querySelector('[data-evr-v3-prescription-headline]');\n    var subNode = document.querySelector('[data-evr-v3-prescription-sub]');\n    if (!container) return;\n\n    var profileLabel = p.profileLabel || 'Personalized';\n    if (headlineNode) headlineNode.textContent = 'Your profile matches the ' + profileLabel + ' Protocol';\n    if (subNode) {\n      var primaryLabel = (p.primaryIssue && p.primaryIssue.label) || '';\n      var q10 = getAnswerArray('q10');\n      var triedParts = [];\n      if (q10.indexOf('attempt_melatonin') !== -1) triedParts.push('melatonin');\n      if (q10.indexOf('attempt_magnesium') !== -1) triedParts.push('magnesium');\n      var subParts = [];\n      if (primaryLabel) subParts.push('Because you reported ' + primaryLabel);\n      if (triedParts.length) subParts.push('have been taking ' + triedParts.join(' and '));\n      var subText = subParts.length\n        ? subParts.join(' and ') + ', your primary ingredient match is calibrated to your specific pattern.'\n        : 'Based on your ' + ((p.appliedRules || []).length) + ' data points, these ingredients were selected for your specific pattern.';\n      subNode.textContent = subText;\n    }\n\n    var ingredients = p.ingredientPriority || [];\n    var maxScore = ingredients.length ? ingredients[0].score : 1;\n\n    clearElement(container);\n    ingredients.forEach(function (ing, idx) {\n      var rawPct = Math.round((ing.score / (maxScore || 1)) * 100);\n      var pct = idx === 0 ? 92 : Math.max(45, Math.round(72 * rawPct / 100));\n      var reason = getPersonalizedIngredientReason(ing.key, p.appliedRules || []);\n      var isPrimary = idx === 0;\n\n      var card = document.createElement('div');\n      card.className = 'evr-v3-prescription__ing-card';\n\n      var head = document.createElement('div');\n      head.className = 'evr-v3-prescription__ing-head';\n      var name = document.createElement('h4');\n      name.className = 'evr-v3-prescription__ing-name';\n      name.textContent = (ing.label || ing.key) + ' \\u00B7 ' + (ing.dose || '');\n      var match = document.createElement('span');\n      match.className = 'evr-v3-prescription__ing-match';\n      match.textContent = isPrimary ? 'Primary match' : 'Supporting';\n      head.appendChild(name);\n      head.appendChild(match);\n\n      var barWrap = document.createElement('div');\n      barWrap.className = 'evr-v3-prescription__ing-bar';\n      var barFill = document.createElement('div');\n      barFill.className = 'evr-v3-prescription__ing-bar-fill';\n      barFill.style.width = pct + '%';\n      barWrap.appendChild(barFill);\n\n      var whyP = document.createElement('p');\n      whyP.className = 'evr-v3-prescription__ing-why';\n      whyP.textContent = ing.why || '';\n\n      card.appendChild(head);\n      card.appendChild(barWrap);\n      card.appendChild(whyP);\n\n      if (reason) {\n        var reasonP = document.createElement('p');\n        reasonP.className = 'evr-v3-prescription__ing-reason';\n        reasonP.textContent = '\\u2192 ' + reason;\n        card.appendChild(reasonP);\n      }\n\n      container.appendChild(card);\n    });\n  }\n\n  function hydrateV3Proof(p) {\n    var container = document.querySelector('[data-evr-v3-proof-testimonials]');\n    if (!container) return;\n\n    var testimonials = p.testimonials || [];\n    if (!testimonials.length) return;\n\n    clearElement(container);\n    testimonials.slice(0, 4).forEach(function (t) {\n      var card = document.createElement('div');\n      card.className = 'evr-v3-proof__card';\n\n      var quote = document.createElement('p');\n      quote.className = 'evr-v3-proof__quote';\n      quote.textContent = t.quote;\n\n      var author = document.createElement('p');\n      author.className = 'evr-v3-proof__author';\n      author.textContent = '\\u2014 ' + (t.author || 'Verified Customer');\n\n      card.appendChild(quote);\n      card.appendChild(author);\n\n      if (t.context) {\n        var context = document.createElement('p');\n        context.className = 'evr-v3-proof__context';\n        context.textContent = t.context;\n        card.appendChild(context);\n      }\n\n      container.appendChild(card);\n    });\n  }\n\n  function hydrateV3Journey(p) {\n    var timelineContainer = document.querySelector('[data-evr-v3-journey-timeline]');\n    var tipsContainer = document.querySelector('[data-evr-v3-journey-tips]');\n\n    if (timelineContainer && Array.isArray(p.timeline) && p.timeline.length) {\n      clearElement(timelineContainer);\n\n      var urgencyNote = document.createElement('p');\n      urgencyNote.className = 'evr-v3-timeline__urgency';\n      var tier = p.scoreInterpretation ? p.scoreInterpretation.tier : 'moderate';\n      urgencyNote.textContent = tier === 'severe'\n        ? 'Your score of ' + (p.quizScore || '--') + ' indicates your nervous system is under significant load. Starting now means results compound faster \\u2014 most people at this level see the quickest improvement.'\n        : tier === 'moderate'\n        ? 'Your score of ' + (p.quizScore || '--') + ' shows a pattern that responds well to targeted intervention. Consistency from day one accelerates the timeline below.'\n        : 'Your score of ' + (p.quizScore || '--') + ' suggests early-stage disruption. Starting now prevents the pattern from deepening.';\n      timelineContainer.appendChild(urgencyNote);\n\n      p.timeline.forEach(function (step, idx) {\n        var isLast = idx === p.timeline.length - 1;\n\n        var stepEl = document.createElement('div');\n        stepEl.className = 'evr-v3-timeline__step';\n\n        var rail = document.createElement('div');\n        rail.className = 'evr-v3-timeline__rail';\n        var dot = document.createElement('span');\n        dot.className = 'evr-v3-timeline__dot';\n        rail.appendChild(dot);\n        if (!isLast) {\n          var line = document.createElement('span');\n          line.className = 'evr-v3-timeline__line';\n          rail.appendChild(line);\n        }\n\n        var content = document.createElement('div');\n        content.className = 'evr-v3-timeline__content';\n        var label = document.createElement('span');\n        label.className = 'evr-v3-timeline__label';\n        label.textContent = step.label;\n        var title = document.createElement('h5');\n        title.className = 'evr-v3-timeline__step-title';\n        title.textContent = step.title;\n        var body = document.createElement('p');\n        body.className = 'evr-v3-timeline__body';\n        body.textContent = step.body;\n        content.appendChild(label);\n        content.appendChild(title);\n        content.appendChild(body);\n\n        stepEl.appendChild(rail);\n        stepEl.appendChild(content);\n        timelineContainer.appendChild(stepEl);\n      });\n    }\n\n    if (tipsContainer) {\n      var TIPS = [\n        { q: 'q2', id: 'screen_time', title: 'Create a screen-free window', body: 'Try 45\\u201360 minutes of no screens before bed. Blue light suppresses melatonin, making it harder to feel sleepy.', bridge: 'Calm+Rest pairs well with this habit \\u2014 its L-Theanine promotes relaxation during your wind-down window.' },\n        { q: 'q2', id: 'caffeine', title: 'Watch your caffeine cutoff', body: 'Caffeine has a 6-hour half-life. Try setting a hard cutoff at 2 PM to give your body time to wind down.', bridge: 'Calm+Rest contains magnesium bisglycinate, which supports muscle relaxation and healthy sleep patterns.' },\n        { q: 'q2', id: 'sleep_environment', title: 'Optimize your sleep space', body: 'Keep your room cool (65\\u201368\\u00B0F), dark, and quiet. Even small light sources can disrupt deep sleep cycles.', bridge: '' },\n        { q: 'q2', id: 'racing_thoughts', title: 'Try a pre-bed brain dump', body: 'Write down every thought before bed. Externalizing your mental loop quiets the mind faster than trying to ignore it.', bridge: 'Calm+Rest\\u2019s L-Theanine promotes alpha-wave activity, supporting mental calm alongside your journaling practice.' },\n        { q: 'q5', id: 'overthinking_future', title: 'Try a thought dump', body: 'Before bed, write down tomorrow\\u2019s worries on paper. Externalizing thoughts helps quiet the mind.', bridge: 'Calm+Rest\\u2019s L-Theanine promotes alpha-wave activity, supporting mental calm alongside your journaling practice.' },\n        { q: 'q5', id: 'digital_overload', title: 'Set digital boundaries', body: 'Try a \\u2018no notifications\\u2019 window in the evening. Even 1 hour of digital silence can lower your cortisol levels.', bridge: '' },\n        { q: 'q11', id: 'time_morning_anxious', title: 'Anchor your morning', body: 'Start with 2 minutes of slow breathing before checking your phone. A calm start sets the tone for the whole day.', bridge: '' },\n        { q: 'q11', id: 'time_midday_crash', title: 'Beat the midday dip', body: 'A 10-minute walk + natural sunlight at lunch resets your circadian rhythm and boosts afternoon energy.', bridge: '' },\n        { q: 'q5', id: 'no_time_for_self', title: 'Protect 15 minutes daily', body: 'Block 15 minutes in your calendar just for you. Self-care isn\\u2019t selfish \\u2014 it\\u2019s the foundation everything else runs on.', bridge: '' },\n        { q: 'q7', id: 'symptom_muscle_tension', title: 'Release tension before bed', body: 'Progressive muscle relaxation \\u2014 tensing then releasing each muscle group for 5 seconds \\u2014 signals your body to shift into rest mode.', bridge: 'Calm+Rest\\u2019s Chelamax magnesium supports muscle and nervous-system relaxation.*' },\n      ];\n\n      var matched = [];\n      for (var i = 0; i < TIPS.length && matched.length < 3; i += 1) {\n        var tip = TIPS[i];\n        if (getAnswerArray(tip.q).indexOf(tip.id) !== -1) {\n          matched.push(tip);\n        }\n      }\n\n      if (matched.length < 2) {\n        matched.push({ title: 'Consistency is your superpower', body: 'Same bedtime \\u00B130 min, even on weekends, trains your circadian rhythm. It\\u2019s the simplest change with the biggest payoff.', bridge: '' });\n      }\n\n      clearElement(tipsContainer);\n      matched.forEach(function (tip, idx) {\n        var tipEl = document.createElement('div');\n        tipEl.className = 'evr-v3-tip';\n\n        var num = document.createElement('span');\n        num.className = 'evr-v3-tip__num';\n        num.textContent = idx + 1;\n\n        var body = document.createElement('div');\n        body.className = 'evr-v3-tip__body';\n        var title = document.createElement('h5');\n        title.className = 'evr-v3-tip__title';\n        title.textContent = tip.title;\n        var text = document.createElement('p');\n        text.className = 'evr-v3-tip__text';\n        text.textContent = tip.body;\n        body.appendChild(title);\n        body.appendChild(text);\n\n        if (tip.bridge) {\n          var bridge = document.createElement('p');\n          bridge.className = 'evr-v3-tip__bridge';\n          bridge.textContent = tip.bridge;\n          body.appendChild(bridge);\n        }\n\n        tipEl.appendChild(num);\n        tipEl.appendChild(body);\n        tipsContainer.appendChild(tipEl);\n      });\n    }\n  }\n\n  /* \u2500\u2500 End V3 Titan Hydration Functions \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 */\n\n  /* \u2500\u2500 V4 Diagnostic Card + Mechanism Bridge + Report Popup \u2500\u2500\u2500\u2500\u2500\u2500\u2500 */\n\n  function hasV4Layout() {\n    return Boolean(document.querySelector('[data-evr-v4-layout]'));\n  }\n  function shouldUseV4Layout() {\n    return shouldUseExternalRecommendationsLayout() && hasV4Layout();\n  }\n\n  /* \u2500\u2500 V4: Diagnostic Card \u2500\u2500 */\n  function hydrateV4DiagnosticCard(p) {\n    /* Score ring */\n    var scoreWrap = document.querySelector('[data-evr-v4-score]');\n    if (scoreWrap && p.quizScore) {\n      var ring = scoreWrap.querySelector('[data-evr-v4-score-ring]');\n      var numNode = scoreWrap.querySelector('[data-evr-v4-score-value]');\n      var tierNode = scoreWrap.querySelector('[data-evr-v4-score-tier]');\n      var tier = p.scoreInterpretation ? p.scoreInterpretation.tier : '';\n\n      /* Tier label \u2014 use the label from getScoreInterpretation directly */\n      if (tierNode) {\n        tierNode.textContent = p.scoreInterpretation.label || '';\n      }\n\n      /* Personalized interpretation \u2014 mirrors quiz answers */\n      var interpNode = document.querySelector('[data-evr-v4-interpretation]');\n      if (interpNode) {\n        var primaryLabel = (p.primaryIssue && p.primaryIssue.label) || '';\n        var q10 = getAnswerArray('q10');\n        var triedParts = [];\n        if (q10.indexOf('attempt_melatonin') !== -1) triedParts.push('melatonin');\n        if (q10.indexOf('attempt_magnesium') !== -1) triedParts.push('magnesium');\n\n        var parts = [];\n        if (primaryLabel) parts.push('Your answers point to ' + primaryLabel + ' as the core pattern');\n        if (triedParts.length) parts.push('you\\u2019ve tried ' + triedParts.join(' and ') + ' without lasting results');\n\n        var interpText = parts.length\n          ? parts.join(', and ') + '. This pattern is specific \\u2014 and specific patterns respond well to targeted support.'\n          : 'Your responses reveal a clear stress-sleep pattern. Clear patterns mean targeted solutions.';\n\n        interpNode.textContent = interpText;\n        interpNode.removeAttribute('hidden');\n      }\n\n      /* Ring wrap glow \u2014 tier-colored drop-shadow */\n      var ringWrap = document.querySelector('[data-evr-v4-ring-wrap]');\n      if (ringWrap) {\n        var glowColors = {\n          severe: 'rgba(200,85,61,.4)',\n          moderate: 'rgba(232,168,56,.35)',\n          mild: 'rgba(52,166,108,.35)',\n        };\n        var glowColor = glowColors[tier] || glowColors.mild;\n        ringWrap.style.filter = 'drop-shadow(0 0 36px ' + glowColor + ')';\n      }\n\n      /* Background radial glow \u2014 tier-colored */\n      var glowEl = document.querySelector('[data-evr-v4-glow]');\n      if (glowEl && tier) glowEl.setAttribute('data-tier', tier);\n\n      /* Gradient colors per tier */\n      var gradStart = document.querySelector('[data-evr-v4-grad-start]');\n      var gradEnd = document.querySelector('[data-evr-v4-grad-end]');\n      var tierGradients = {\n        severe: ['#c8553d', '#a33c28'],\n        moderate: ['#e8a838', '#c88a20'],\n        mild: ['#34a66c', '#2a8a58'],\n      };\n      var grad = tierGradients[tier] || tierGradients.mild;\n      if (gradStart) gradStart.setAttribute('stop-color', grad[0]);\n      if (gradEnd) gradEnd.setAttribute('stop-color', grad[1]);\n\n      /* Animate ring fill */\n      if (ring) {\n        var circumference = 326.73;\n        var pct = Math.min(100, Math.max(0, p.quizScore));\n        var offset = circumference - (circumference * pct / 100);\n        requestAnimationFrame(function () {\n          ring.style.strokeDashoffset = offset;\n        });\n      }\n\n      /* Animated counter: 0 \u2192 score */\n      if (numNode) {\n        var targetScore = parseInt(p.quizScore, 10);\n        var duration = 1400;\n        var startTime = null;\n        numNode.textContent = '0';\n        function animateCounter(ts) {\n          if (!startTime) startTime = ts;\n          var elapsed = ts - startTime;\n          var progress = Math.min(elapsed / duration, 1);\n          var eased = 1 - Math.pow(1 - progress, 3);\n          numNode.textContent = Math.round(eased * targetScore);\n          if (progress < 1) requestAnimationFrame(animateCounter);\n        }\n        requestAnimationFrame(animateCounter);\n      }\n\n      scoreWrap.removeAttribute('hidden');\n    }\n\n    /* Profile badge */\n    var badgeWrap = document.querySelector('[data-evr-v4-profile-badge]');\n    if (badgeWrap && p.profileLabel) {\n      var badgeLabel = badgeWrap.querySelector('[data-evr-v4-badge-label]');\n      if (badgeLabel) badgeLabel.textContent = p.profileLabel + ' Profile';\n      badgeWrap.removeAttribute('hidden');\n    }\n\n    /* Signal chips */\n    var signalsContainer = document.querySelector('[data-evr-v4-signals]');\n    if (signalsContainer) {\n      var appliedRules = p.appliedRules || [];\n      var chipRules = appliedRules.filter(function (id) {\n        return id.charAt(0) >= '1' && id.charAt(0) <= '6' && RULE_USER_COPY[id];\n      }).slice(0, 3);\n\n      signalsContainer.innerHTML = '';\n      chipRules.forEach(function (id) {\n        var chip = document.createElement('span');\n        chip.className = 'evr-v4-signal-chip';\n        chip.textContent = RULE_USER_COPY[id];\n        signalsContainer.appendChild(chip);\n      });\n    }\n  }\n\n  /* \u2500\u2500 V4: Mechanism Bridge \u2500\u2500 */\n  function hydrateV4MechanismBridge(p) {\n    var q10 = getAnswerArray('q10');\n    var hasMelatonin = q10.indexOf('attempt_melatonin') !== -1;\n\n    var melPanel = document.querySelector('[data-evr-v4-bridge-melatonin]');\n    if (melPanel && hasMelatonin) {\n      melPanel.classList.remove('evr-hidden');\n      melPanel.removeAttribute('hidden');\n    }\n\n    /* Single strongest testimonial */\n    var proofWrap = document.querySelector('[data-evr-v4-bridge-proof]');\n    if (proofWrap && p.testimonials && p.testimonials.length) {\n      var best = p.testimonials[0];\n      var quoteNode = proofWrap.querySelector('[data-evr-v4-bridge-quote]');\n      var authorNode = proofWrap.querySelector('[data-evr-v4-bridge-author]');\n      if (quoteNode) quoteNode.textContent = best.quote;\n      if (authorNode) authorNode.textContent = '\\u2014 ' + (best.author || 'Verified Customer');\n      proofWrap.removeAttribute('hidden');\n    }\n  }\n\n  /* \u2500\u2500 V4: Coupon Banner inside Purchase \u2500\u2500 */\n  function hydrateV4CouponBanner() {\n    var banner = document.querySelector('[data-evr-v4-coupon-banner]');\n    if (!banner) return;\n\n    var code = state.promoCode || '';\n    if (!code) return;\n\n    var codeNode = banner.querySelector('[data-evr-v4-coupon-code]');\n    var clockNode = banner.querySelector('[data-evr-v4-coupon-clock]');\n    if (codeNode) codeNode.textContent = code;\n\n    /* Register clock node for existing timer system */\n    if (clockNode) {\n      state.timer.nodes.push(clockNode);\n    }\n\n    banner.classList.remove('evr-hidden');\n    banner.removeAttribute('hidden');\n  }\n\n  /* \u2500\u2500 V4: Purchase Section Enhancements (RF2, RF3, RF8) \u2500\u2500 */\n  function hydrateV4PurchaseEnhancements(p) {\n    /* RF2: Price anchor */\n    var anchorEl = document.querySelector('[data-evr-v4-price-anchor]');\n    if (anchorEl) {\n      anchorEl.removeAttribute('hidden');\n    }\n\n    /* RF3: Daily cost reframe \u2014 append to per-day nodes */\n    document.querySelectorAll('[data-evr-plan-per-day]').forEach(function (node) {\n      if (node.dataset.evrReframed) return;\n      node.dataset.evrReframed = '1';\n      var observer = new MutationObserver(function () {\n        var text = node.textContent.trim();\n        if (text && text !== '$0.00/day' && !text.includes('\\u2014')) {\n          node.textContent = text + ' \\u2014 less than a coffee';\n          observer.disconnect();\n        }\n      });\n      observer.observe(node, { childList: true, characterData: true, subtree: true });\n    });\n\n    /* RF8: Product label */\n    var productLabel = document.querySelector('[data-evr-v4-product-label]');\n    if (productLabel && p.profileLabel) {\n      productLabel.textContent = 'Matched to your ' + p.profileLabel + ' profile';\n      productLabel.removeAttribute('hidden');\n    }\n  }\n\n  /* \u2500\u2500 V4: Report Popup \u2014 hydrate all blocks inside the modal \u2500\u2500 */\n  function hydrateV4Report(p) {\n    /* Findings */\n    var findingsBody = document.querySelector('[data-evr-v4-rpt-findings-body]');\n    if (findingsBody) {\n      /* Reuse v3 findings logic */\n      var primaryLabel = (p.primaryIssue && p.primaryIssue.label) || 'sleep difficulties';\n      var symptoms = getAnswerLabels('q7', 3);\n      var q2 = getAnswerArray('q2');\n      var q5 = getAnswerArray('q5');\n      var q11 = getAnswerArray('q11');\n      var q4 = getAnswerArray('q4');\n      var lines = [];\n\n      var CONCERN_OPENERS = {\n        'all-day stress': 'Living with all-day stress is exhausting \\u2014 it affects your energy, your mood, and your sleep.',\n        'a busy mind at night': 'A busy mind at bedtime can feel like a cycle you can\\u2019t break.',\n        'nighttime awakenings': 'Waking up in the middle of the night and not being able to fall back asleep is deeply frustrating.',\n        'sleep onset delay': 'Lying awake waiting for sleep to come is one of the most draining struggles.',\n        'stress-related tension': 'When stress lives in your body as tension, it\\u2019s hard to truly relax.',\n        'stress-disrupted sleep': 'When stress and sleep problems feed each other, it can feel like there\\u2019s no way out.',\n      };\n      lines.push(CONCERN_OPENERS[primaryLabel] || CONCERN_OPENERS['stress-disrupted sleep']);\n\n      var blockerLines = [];\n      if (q2.indexOf('racing_thoughts') !== -1) blockerLines.push('a mind that won\\u2019t quiet down');\n      if (q2.indexOf('worry_anxiety') !== -1) blockerLines.push('worry that follows you to bed');\n      if (q2.indexOf('physical_tension') !== -1) blockerLines.push('physical tension you can\\u2019t shake');\n      if (blockerLines.length) lines.push('At bedtime, you\\u2019re dealing with ' + blockerLines.join(', ') + '.');\n\n      if (symptoms.length && symptoms[0] !== 'None of these') {\n        lines.push('Your body is also signaling through ' + symptoms.map(function (s) { return s.toLowerCase(); }).join(', ') + '.');\n      }\n\n      var stressorLines = [];\n      if (q5.indexOf('work_demands') !== -1) stressorLines.push('work pressure');\n      if (q5.indexOf('family_relationships') !== -1) stressorLines.push('family demands');\n      if (q5.indexOf('overthinking_future') !== -1) stressorLines.push('overthinking');\n      if (stressorLines.length >= 2) lines.push('Between ' + stressorLines.slice(0, 2).join(' and ') + ', your nervous system rarely gets a real break.');\n\n      lines.push('The good news: your answers reveal a clear pattern, and clear patterns mean targeted solutions.');\n\n      clearElement(findingsBody);\n      lines.forEach(function (line) {\n        var el = document.createElement('p');\n        el.textContent = line;\n        findingsBody.appendChild(el);\n      });\n    }\n\n    /* Mechanism signals */\n    var mechSignals = document.querySelector('[data-evr-v4-rpt-mechanism-signals]');\n    if (mechSignals) {\n      var appliedRules = p.appliedRules || [];\n      var displayRules = appliedRules.filter(function (id) {\n        return id.charAt(0) >= '1' && id.charAt(0) <= '6' && RULE_USER_COPY[id];\n      }).slice(0, 4);\n      mechSignals.innerHTML = '';\n      displayRules.forEach(function (id) {\n        var chip = document.createElement('span');\n        chip.className = 'evr-v4-signal-chip';\n        chip.textContent = RULE_USER_COPY[id];\n        mechSignals.appendChild(chip);\n      });\n    }\n\n    /* Mechanism conditionals */\n    var q10 = getAnswerArray('q10');\n    var hasMelatonin = q10.indexOf('attempt_melatonin') !== -1;\n    var hasMagnesium = q10.indexOf('attempt_magnesium') !== -1;\n\n    var rptMel = document.querySelector('[data-evr-v4-rpt-melatonin]');\n    var rptMag = document.querySelector('[data-evr-v4-rpt-magnesium]');\n    var rptStack = document.querySelector('[data-evr-v4-rpt-stack]');\n    if (rptMel && hasMelatonin) { rptMel.classList.remove('evr-hidden'); rptMel.removeAttribute('hidden'); }\n    if (rptMag && hasMagnesium) { rptMag.classList.remove('evr-hidden'); rptMag.removeAttribute('hidden'); }\n    if (rptStack && hasMelatonin && hasMagnesium) { rptStack.classList.remove('evr-hidden'); rptStack.removeAttribute('hidden'); }\n\n    /* Strengths */\n    var strengthsList = document.querySelector('[data-evr-v4-rpt-strengths]');\n    if (strengthsList) {\n      var positives = [];\n      var q3 = getAnswerArray('q3');\n      var q4rpt = getAnswerArray('q4');\n      var q10rpt = getAnswerArray('q10');\n      var q2rpt = getAnswerArray('q2');\n      if (q3.indexOf('wake_refreshed') !== -1) positives.push('You sometimes wake refreshed \\u2014 your body can recover');\n      if (q4rpt.indexOf('calm_in_control') !== -1 || q4rpt.indexOf('balanced_overall') !== -1) positives.push('You experience moments of calm during the day');\n      if (q10rpt.indexOf('attempt_exercise_lifestyle') !== -1) positives.push('You\\u2019ve tried exercise & lifestyle changes');\n      if (q10rpt.indexOf('attempt_sleep_hygiene') !== -1) positives.push('You\\u2019ve worked on sleep hygiene');\n      if (q2rpt.indexOf('caffeine') === -1) positives.push('No evening caffeine \\u2014 a plus for sleep quality');\n      if (!positives.length) positives.push('You took this quiz \\u2014 the first step toward better sleep');\n\n      clearElement(strengthsList);\n      positives.slice(0, 4).forEach(function (text) {\n        var item = document.createElement('div');\n        item.className = 'evr-v3-strengths__item';\n        var icon = document.createElement('span');\n        icon.className = 'evr-v3-strengths__icon';\n        icon.textContent = '\\u2713';\n        var textEl = document.createElement('p');\n        textEl.className = 'evr-v3-strengths__text';\n        textEl.textContent = text;\n        item.appendChild(icon);\n        item.appendChild(textEl);\n        strengthsList.appendChild(item);\n      });\n    }\n\n    /* Prescription */\n    var rxBadge = document.querySelector('[data-evr-v4-rpt-rx-badge]');\n    var rxHeadline = document.querySelector('[data-evr-v4-rpt-rx-headline]');\n    var rxSub = document.querySelector('[data-evr-v4-rpt-rx-sub]');\n    var rxIngs = document.querySelector('[data-evr-v4-rpt-rx-ingredients]');\n    if (rxBadge && p.profileLabel) rxBadge.textContent = p.profileLabel;\n    if (rxHeadline) rxHeadline.textContent = 'Your profile matches the ' + (p.profileLabel || 'Personalized') + ' Protocol';\n    if (rxSub) {\n      var primaryLbl = (p.primaryIssue && p.primaryIssue.label) || '';\n      rxSub.textContent = primaryLbl\n        ? 'Because you reported ' + primaryLbl + ', your ingredient match is calibrated to your specific pattern.'\n        : 'Based on your data points, these ingredients were selected for your specific pattern.';\n    }\n    if (rxIngs) {\n      var ingredients = p.ingredientPriority || [];\n      var maxScore = ingredients.length ? ingredients[0].score : 1;\n      clearElement(rxIngs);\n      ingredients.forEach(function (ing, idx) {\n        var pct = idx === 0 ? 92 : Math.max(45, Math.round(72 * Math.round((ing.score / (maxScore || 1)) * 100) / 100));\n        var reason = getPersonalizedIngredientReason(ing.key, p.appliedRules || []);\n        var card = document.createElement('div');\n        card.className = 'evr-v3-prescription__ing-card';\n        var head = document.createElement('div');\n        head.className = 'evr-v3-prescription__ing-head';\n        var name = document.createElement('h4');\n        name.className = 'evr-v3-prescription__ing-name';\n        name.textContent = (ing.label || ing.key) + ' \\u00B7 ' + (ing.dose || '');\n        var match = document.createElement('span');\n        match.className = 'evr-v3-prescription__ing-match';\n        match.textContent = idx === 0 ? 'Primary match' : 'Supporting';\n        head.appendChild(name); head.appendChild(match);\n        var barWrap = document.createElement('div');\n        barWrap.className = 'evr-v3-prescription__ing-bar';\n        var barFill = document.createElement('div');\n        barFill.className = 'evr-v3-prescription__ing-bar-fill';\n        barFill.style.width = pct + '%';\n        barWrap.appendChild(barFill);\n        var whyP = document.createElement('p');\n        whyP.className = 'evr-v3-prescription__ing-why';\n        whyP.textContent = ing.why || '';\n        card.appendChild(head); card.appendChild(barWrap); card.appendChild(whyP);\n        if (reason) {\n          var reasonP = document.createElement('p');\n          reasonP.className = 'evr-v3-prescription__ing-reason';\n          reasonP.textContent = '\\u2192 ' + reason;\n          card.appendChild(reasonP);\n        }\n        rxIngs.appendChild(card);\n      });\n    }\n\n    /* Proof / testimonials \u2014 rich cards with stars + verified badge */\n    var proofContainer = document.querySelector('[data-evr-v4-rpt-testimonials]');\n    var proofLabel = document.querySelector('[data-evr-v4-rpt-profile-label]');\n    if (proofLabel && p.profileLabel) proofLabel.textContent = p.profileLabel;\n    if (proofContainer && p.testimonials && p.testimonials.length) {\n      clearElement(proofContainer);\n      p.testimonials.slice(0, 4).forEach(function (t) {\n        var card = document.createElement('div');\n        card.className = 'evr-v4-review-card';\n\n        /* Stars */\n        var starsRow = document.createElement('div');\n        starsRow.className = 'evr-v4-review-card__stars';\n        for (var s = 0; s < 5; s++) {\n          var star = document.createElement('span');\n          star.className = 'evr-v4-review-card__star';\n          star.textContent = '\\u2605';\n          starsRow.appendChild(star);\n        }\n        card.appendChild(starsRow);\n\n        /* Quote */\n        var quote = document.createElement('p');\n        quote.className = 'evr-v4-review-card__quote';\n        quote.textContent = t.quote;\n        card.appendChild(quote);\n\n        /* Footer: author + verified */\n        var footer = document.createElement('div');\n        footer.className = 'evr-v4-review-card__footer';\n        var author = document.createElement('span');\n        author.className = 'evr-v4-review-card__author';\n        author.textContent = t.author || 'Verified Customer';\n        var badge = document.createElement('span');\n        badge.className = 'evr-v4-review-card__badge';\n        badge.innerHTML = '<svg width=\"12\" height=\"12\" viewBox=\"0 0 24 24\" fill=\"#22c55e\"><path d=\"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z\"/></svg> Verified';\n        footer.appendChild(author);\n        footer.appendChild(badge);\n        card.appendChild(footer);\n\n        proofContainer.appendChild(card);\n      });\n    }\n\n    /* Journey / timeline \u2014 same DOM structure as v3 (rail + dot + line + content) */\n    var timelineContainer = document.querySelector('[data-evr-v4-rpt-timeline]');\n    if (timelineContainer && Array.isArray(p.timeline) && p.timeline.length) {\n      clearElement(timelineContainer);\n      p.timeline.forEach(function (step, idx) {\n        var isLast = idx === p.timeline.length - 1;\n\n        var stepEl = document.createElement('div');\n        stepEl.className = 'evr-v3-timeline__step';\n\n        var rail = document.createElement('div');\n        rail.className = 'evr-v3-timeline__rail';\n        var dot = document.createElement('span');\n        dot.className = 'evr-v3-timeline__dot';\n        rail.appendChild(dot);\n        if (!isLast) {\n          var line = document.createElement('span');\n          line.className = 'evr-v3-timeline__line';\n          rail.appendChild(line);\n        }\n\n        var content = document.createElement('div');\n        content.className = 'evr-v3-timeline__content';\n        var label = document.createElement('span');\n        label.className = 'evr-v3-timeline__label';\n        label.textContent = step.label || ('Week ' + ((idx + 1) * 2));\n        var titleEl = document.createElement('h5');\n        titleEl.className = 'evr-v3-timeline__step-title';\n        titleEl.textContent = step.title;\n        var bodyEl = document.createElement('p');\n        bodyEl.className = 'evr-v3-timeline__body';\n        bodyEl.textContent = step.body;\n        content.appendChild(label);\n        content.appendChild(titleEl);\n        content.appendChild(bodyEl);\n\n        stepEl.appendChild(rail);\n        stepEl.appendChild(content);\n        timelineContainer.appendChild(stepEl);\n      });\n    }\n\n    /* Tips */\n    var tipsContainer = document.querySelector('[data-evr-v4-rpt-tips]');\n    if (tipsContainer) {\n      var TIPS = [\n        { q: 'q2', id: 'screen_time', title: 'Screen-free window', body: 'Try 45\\u201360 min without screens before bed.' },\n        { q: 'q2', id: 'racing_thoughts', title: 'Pre-bed brain dump', body: 'Write down tomorrow\\u2019s tasks before bed to clear your mind.' },\n        { q: 'q2', id: 'caffeine', title: 'Caffeine cutoff', body: 'Stop caffeine by 2 PM for better sleep onset.' },\n        { q: 'q5', id: 'overthinking_future', title: 'Thought dump', body: '5 minutes of free writing before bed can significantly quiet a racing mind.' },\n        { q: 'q11', id: 'time_morning_anxious', title: 'Anchor your morning', body: '2 minutes of deep breathing before checking your phone sets a calmer tone.' },\n      ];\n      var matched = [];\n      for (var i = 0; i < TIPS.length && matched.length < 3; i++) {\n        if (getAnswerArray(TIPS[i].q).indexOf(TIPS[i].id) !== -1) matched.push(TIPS[i]);\n      }\n      if (matched.length < 2) matched.push({ title: 'Consistency is key', body: 'Same bedtime \\u00B130 min, even on weekends, trains your circadian rhythm.' });\n\n      clearElement(tipsContainer);\n      matched.forEach(function (tip, idx) {\n        var el = document.createElement('div');\n        el.className = 'evr-v3-tip';\n        var num = document.createElement('span');\n        num.className = 'evr-v3-tip__num';\n        num.textContent = idx + 1;\n        var body = document.createElement('div');\n        body.className = 'evr-v3-tip__body';\n        var title = document.createElement('h5');\n        title.className = 'evr-v3-tip__title';\n        title.textContent = tip.title;\n        var text = document.createElement('p');\n        text.className = 'evr-v3-tip__text';\n        text.textContent = tip.body;\n        body.appendChild(title); body.appendChild(text);\n        el.appendChild(num); el.appendChild(body);\n        tipsContainer.appendChild(el);\n      });\n    }\n  }\n\n  /* \u2500\u2500 V4: Report Popup open/close \u2500\u2500 */\n  function initV4ReportPopup() {\n    var overlay = document.querySelector('[data-evr-v4-report-overlay]');\n    if (!overlay) return;\n\n    /* Open */\n    document.querySelectorAll('[data-evr-v4-open-report]').forEach(function (btn) {\n      btn.addEventListener('click', function () {\n        overlay.removeAttribute('hidden');\n        requestAnimationFrame(function () {\n          overlay.classList.add('is-open');\n        });\n        document.body.style.overflow = 'hidden';\n      });\n    });\n\n    /* Close */\n    var closeBtns = overlay.querySelectorAll('[data-evr-v4-close-report]');\n    closeBtns.forEach(function (btn) {\n      btn.addEventListener('click', closeV4Report);\n    });\n    overlay.addEventListener('click', function (e) {\n      if (e.target === overlay) closeV4Report();\n    });\n\n    /* CTA inside popup \u2192 scroll to purchase */\n    var popupPurchaseBtn = overlay.querySelector('[data-evr-v4-report-purchase]');\n    if (popupPurchaseBtn) {\n      popupPurchaseBtn.addEventListener('click', function () {\n        closeV4Report();\n        setTimeout(function () {\n          var purchaseSection = document.querySelector('.evr-v3-section--purchase');\n          if (purchaseSection) purchaseSection.scrollIntoView({ behavior: 'smooth', block: 'start' });\n        }, 350);\n      });\n    }\n\n    function closeV4Report() {\n      overlay.classList.remove('is-open');\n      document.body.style.overflow = '';\n      setTimeout(function () {\n        overlay.setAttribute('hidden', '');\n      }, 300);\n    }\n  }\n\n  /* \u2500\u2500 V4: Scroll-to-purchase from Diagnostic Card \u2500\u2500 */\n  function initV4ScrollToPurchase() {\n    document.querySelectorAll('[data-evr-v4-scroll-purchase]').forEach(function (btn) {\n      btn.addEventListener('click', function () {\n        var purchaseSection = document.querySelector('.evr-v3-section--purchase');\n        if (purchaseSection) purchaseSection.scrollIntoView({ behavior: 'smooth', block: 'start' });\n      });\n    });\n  }\n\n  /* \u2500\u2500 End V4 Functions \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 */\n\n  function applyV2ProfileOverrides(personalization) {\n    const fallbackBundle = (personalization.bundleKey || '').replaceAll('_', ' ');\n    const fallbackHeadline = personalization.dynamicHeadline || 'Your personalized protocol is ready';\n    const fallbackSubheadline = personalization.dynamicSubheadline || '';\n    setTextForNodes('[data-evr-profile-label]', personalization.profileLabel || '');\n    setTextForNodes('[data-evr-dynamic-headline]', fallbackHeadline);\n    setTextForNodes('[data-evr-dynamic-subheadline]', fallbackSubheadline);\n    setTextForNodes('[data-evr-bundle-label]', fallbackBundle);\n\n    const routineConfig = getV2ProfileConfig('core_routine', personalization);\n    if (routineConfig) {\n      if (routineConfig.badge) {\n        setTextForNodes('[data-evr-profile-label]', routineConfig.badge);\n      }\n      if (routineConfig.headline) {\n        setTextForNodes('[data-evr-dynamic-headline]', routineConfig.headline);\n      }\n      if (routineConfig.subheadline) {\n        setTextForNodes('[data-evr-dynamic-subheadline]', routineConfig.subheadline);\n      }\n      if (routineConfig.bundleLabel) {\n        setTextForNodes('[data-evr-bundle-prefix]', routineConfig.bundleLabel);\n      }\n      if (routineConfig.bundleValue) {\n        setTextForNodes('[data-evr-bundle-label]', routineConfig.bundleValue);\n      }\n\n      document.querySelectorAll('[data-evr-products]').forEach((node) => {\n        if (routineConfig.productBadge) {\n          node.dataset.cardBadge = String(routineConfig.productBadge);\n        }\n        if (routineConfig.productHeadline) {\n          node.dataset.cardHeadline = String(routineConfig.productHeadline);\n        }\n      });\n    }\n\n    const rdConfig = getV2ProfileConfig('rd_video', personalization);\n    if (rdConfig) {\n      if (rdConfig.heading) {\n        setTextForNodes('[data-evr-v2-rd-heading]', rdConfig.heading);\n      }\n      if (rdConfig.subheading) {\n        setTextForNodes('[data-evr-v2-rd-subheading]', rdConfig.subheading);\n        setTextForNodes('[data-evr-v2-rd-caption]', rdConfig.subheading);\n      }\n      if (rdConfig.ctaText) {\n        setTextForNodes('[data-evr-v2-rd-open]', rdConfig.ctaText);\n      }\n    }\n\n    var reportFirstName = escapeHtml((state.lead.firstName || '').trim());\n    var reportTitle = personalization.safetyGate\n      ? 'Safety Review'\n      : (reportFirstName ? reportFirstName + '\\u2019s Sleep & Stress Report' : 'Your Sleep & Stress Report');\n    setTextForNodes('[data-evr-v2-report-title]', reportTitle);\n    setHtmlForNodes('[data-evr-v2-report-body]', renderPersonalizedReport(personalization));\n\n    applyV2ProfileLayerVisibility(personalization);\n  }\n\n  function buildV2ResultLine(personalization) {\n    return 'Personalized to help support your wellness goals.';\n  }\n\n  /* \u2500\u2500 Personalized Nutrition Report renderer \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 */\n\n  function getStressBurdenLevel(score) {\n    if (score <= 5) return { label: 'Low', segments: 1 };\n    if (score <= 10) return { label: 'Moderate', segments: 2 };\n    if (score <= 18) return { label: 'High', segments: 3 };\n    return { label: 'Very High', segments: 4 };\n  }\n\n  function getPersonalizedIngredientReason(ingredientKey, appliedRules) {\n    for (let i = 0; i < PERSONALIZATION_RULES.length; i += 1) {\n      const rule = PERSONALIZATION_RULES[i];\n      if (appliedRules.includes(rule.id) && rule.ingredients.includes(ingredientKey)) {\n        return RULE_USER_COPY[rule.id] || '';\n      }\n    }\n    return '';\n  }\n\n  function getAnswerLabels(route, limit) {\n    const ids = getAnswerArray(route);\n    const labels = ids.map(function (id) { return OPTION_LABEL_LOOKUP[id] || id; });\n    return limit ? labels.slice(0, limit) : labels;\n  }\n\n  function renderReportHeader(p) {\n    var firstName = escapeHtml((state.lead.firstName || '').trim());\n    var profileLabel = escapeHtml(p.profileLabel || 'Personalized');\n    var heading = firstName\n      ? firstName + ', here\\u2019s your ' + profileLabel + ' plan'\n      : 'Your ' + profileLabel + ' plan is ready';\n    var sub = escapeHtml(p.dynamicSubheadline || '');\n\n    return (\n      '<div class=\"evr-v2-report-header\">' +\n        '<span class=\"evr-v2-report-badge\">' + profileLabel + '</span>' +\n        '<h3 class=\"evr-v2-report-header__title\">' + heading + '</h3>' +\n        (sub ? '<p class=\"evr-v2-report-header__sub\">' + sub + '</p>' : '') +\n      '</div>'\n    );\n  }\n\n  function renderReportSnapshot(p) {\n    var sleepLabel = getAnswerLabels('q1', 1)[0] || 'General sleep support';\n    var symptoms = getAnswerLabels('q7', 4);\n    var sleepGoals = getAnswerLabels('q8', 3);\n    var stressGoals = getAnswerLabels('q9', 3);\n    var burden = getStressBurdenLevel(p.stressBurden);\n    var ruleCount = (p.appliedRules || []).length;\n\n    var symptomsHtml = symptoms.length\n      ? symptoms.map(function (s) { return '<span class=\"evr-v2-report-chip\">' + escapeHtml(s) + '</span>'; }).join('')\n      : '';\n\n    var meterSegments = '';\n    for (var i = 1; i <= 4; i += 1) {\n      var active = i <= burden.segments ? ' evr-v2-report-meter__seg--active evr-v2-report-meter__seg--l' + burden.segments : '';\n      meterSegments += '<span class=\"evr-v2-report-meter__seg' + active + '\"></span>';\n    }\n\n    var goalsHtml = '';\n    var allGoals = sleepGoals.concat(stressGoals);\n    if (allGoals.length) {\n      goalsHtml = '<div class=\"evr-v2-report-goals\">' +\n        '<p class=\"evr-v2-report-goals__label\">Your goals</p>' +\n        '<div class=\"evr-v2-report-chips\">' +\n          allGoals.map(function (g) { return '<span class=\"evr-v2-report-chip\">' + escapeHtml(g) + '</span>'; }).join('') +\n        '</div>' +\n      '</div>';\n    }\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title evr-v2-report-section__title--center\">Your Sleep &amp; Stress Snapshot</h4>' +\n        '<div class=\"evr-v2-report-snapshot\">' +\n          '<div class=\"evr-v2-report-snapshot__col evr-v2-report-snapshot__col--center\">' +\n            '<p class=\"evr-v2-report-snapshot__label\">Sleep pattern</p>' +\n            '<p class=\"evr-v2-report-snapshot__value\">' + escapeHtml(sleepLabel) + '</p>' +\n            (symptomsHtml ? '<div class=\"evr-v2-report-chips\" style=\"margin-top:10px\">' + symptomsHtml + '</div>' : '') +\n          '</div>' +\n          '<div class=\"evr-v2-report-snapshot__col evr-v2-report-snapshot__col--center\">' +\n            '<p class=\"evr-v2-report-snapshot__label\">Stress load</p>' +\n            '<p class=\"evr-v2-report-snapshot__value evr-v2-report-meter__label--l' + burden.segments + '\">' + escapeHtml(burden.label) + '</p>' +\n            '<div class=\"evr-v2-report-meter\">' + meterSegments + '</div>' +\n          '</div>' +\n          (goalsHtml ? goalsHtml : '') +\n        '</div>' +\n        '<p class=\"evr-v2-report-datapoints\">We matched <strong>' + ruleCount + ' data point' + (ruleCount !== 1 ? 's' : '') + '</strong> from your answers to build this plan.</p>' +\n      '</div>'\n    );\n  }\n\n  function renderReportConcerns(p) {\n    var primaryLabel = (p.primaryIssue && p.primaryIssue.label) || 'sleep difficulties';\n    var symptoms = getAnswerLabels('q7', 3);\n    var q2 = getAnswerArray('q2');\n    var q4 = getAnswerArray('q4');\n    var q5 = getAnswerArray('q5');\n    var q11 = getAnswerArray('q11');\n\n    var lines = [];\n\n    // Primary issue \u2014 main empathy opener\n    var CONCERN_OPENERS = {\n      'all-day stress': 'Living with all-day stress is exhausting \\u2014 it affects your energy, your mood, and your sleep.',\n      'a busy mind at night': 'A busy mind at bedtime can feel like a cycle you can\\u2019t break \\u2014 many people describe it as a mind that won\\u2019t shut off.',\n      'nighttime awakenings': 'Waking up in the middle of the night and not being able to fall back asleep is deeply frustrating \\u2014 especially when it becomes the norm.',\n      'sleep onset delay': 'Lying awake waiting for sleep to come is one of the most draining struggles \\u2014 the harder you try, the worse it gets.',\n      'stress-related tension': 'When stress lives in your body as tension, it\\u2019s hard to truly relax, even when you\\u2019re exhausted.',\n      'stress-disrupted sleep': 'When stress and sleep problems feed each other, it can feel like there\\u2019s no way out of the cycle.',\n    };\n    lines.push(CONCERN_OPENERS[primaryLabel] || CONCERN_OPENERS['stress-disrupted sleep']);\n\n    // Sleep blockers (q2)\n    var blockerLines = [];\n    if (q2.indexOf('racing_thoughts') !== -1) blockerLines.push('a mind that won\\u2019t quiet down');\n    if (q2.indexOf('worry_anxiety') !== -1) blockerLines.push('worry that follows you to bed');\n    if (q2.indexOf('physical_tension') !== -1) blockerLines.push('physical tension you can\\u2019t shake');\n    if (q2.indexOf('screen_time') !== -1) blockerLines.push('screen time that pushes back your wind-down');\n    if (blockerLines.length) {\n      lines.push('At bedtime, you\\u2019re dealing with ' + escapeHtml(blockerLines.join(', ')) + '. That\\u2019s a lot working against you.');\n    }\n\n    // Symptoms (q7)\n    if (symptoms.length && symptoms[0] !== 'None of these') {\n      var symptomStr = symptoms.map(function (s) { return s.toLowerCase(); }).join(', ');\n      lines.push('Your body is also signaling through ' + escapeHtml(symptomStr) + ' \\u2014 these often go hand in hand.');\n    }\n\n    // Stress sources (q5) \u2014 top 2\n    var stressorLines = [];\n    if (q5.indexOf('work_demands') !== -1) stressorLines.push('work pressure');\n    if (q5.indexOf('family_relationships') !== -1) stressorLines.push('family demands');\n    if (q5.indexOf('financial_pressures') !== -1) stressorLines.push('financial stress');\n    if (q5.indexOf('overthinking_future') !== -1) stressorLines.push('overthinking');\n    if (q5.indexOf('no_time_for_self') !== -1) stressorLines.push('no time for yourself');\n    if (stressorLines.length >= 2) {\n      lines.push('Between ' + escapeHtml(stressorLines.slice(0, 2).join(' and ')) + ', your nervous system rarely gets a real break.');\n    }\n\n    // Daytime mood (q4)\n    if (q4.indexOf('down_low_energy') !== -1 && q4.indexOf('stressed_overwhelmed') !== -1) {\n      lines.push('Feeling both drained and overwhelmed during the day is a sign the cycle has been running for a while.');\n    } else if (q4.indexOf('down_low_energy') !== -1) {\n      lines.push('Low energy during the day often traces back to what\\u2019s happening at night.');\n    } else if (q4.indexOf('stressed_overwhelmed') !== -1) {\n      lines.push('Feeling overwhelmed during the day makes everything harder \\u2014 you\\u2019re not alone in this.');\n    }\n\n    // All-day stress (q11)\n    if (q11.indexOf('time_all_day_stress') !== -1) {\n      lines.push('The fact that stress follows you from morning to night tells us this isn\\u2019t just a sleep issue \\u2014 it\\u2019s a full-day pattern.');\n    }\n\n    // Closing \u2192 bridge to positives\n    lines.push('The good news: your answers reveal a clear pattern, and clear patterns mean targeted solutions. You\\u2019re not starting from zero \\u2014 here\\u2019s what\\u2019s already working in your favor:');\n\n    var html = lines.map(function (line) {\n      return '<p class=\"evr-v2-report-concern__text\">' + line + '</p>';\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section evr-v2-report-concerns\">' +\n        '<h4 class=\"evr-v2-report-section__title\">Here\\u2019s What We Found</h4>' +\n        html +\n      '</div>'\n    );\n  }\n\n  function renderReportPositives(p) {\n    var positives = [];\n    var q3 = getAnswerArray('q3');\n    var q4 = getAnswerArray('q4');\n    var q10 = getAnswerArray('q10');\n    var q2 = getAnswerArray('q2');\n\n    if (q3.indexOf('wake_refreshed') !== -1) positives.push('You sometimes wake up feeling refreshed \\u2014 a sign your body can recover');\n    if (q4.indexOf('calm_in_control') !== -1 || q4.indexOf('balanced_overall') !== -1) positives.push('You experience moments of calm during the day \\u2014 a good foundation');\n    if (q10.indexOf('attempt_exercise_lifestyle') !== -1) positives.push('You\\u2019ve tried exercise & lifestyle changes \\u2014 showing real commitment');\n    if (q10.indexOf('attempt_sleep_hygiene') !== -1) positives.push('You\\u2019ve worked on sleep hygiene \\u2014 smart approach to foundations first');\n    if (q10.indexOf('attempt_therapy') !== -1) positives.push('You\\u2019ve explored therapy \\u2014 that takes courage and shows self-awareness');\n    if (q2.indexOf('caffeine') === -1) positives.push('Your evening routine doesn\\u2019t include caffeine \\u2014 that\\u2019s a plus for sleep quality');\n\n    if (!positives.length) positives.push('You took this quiz \\u2014 that\\u2019s the first step toward better sleep');\n\n    var items = positives.slice(0, 4);\n    var html = items.map(function (text) {\n      return '<div class=\"evr-v2-report-positive\">' +\n        '<span class=\"evr-v2-report-positive__icon\">\\u2713</span>' +\n        '<p class=\"evr-v2-report-positive__text\">' + escapeHtml(text) + '</p>' +\n      '</div>';\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title\">What You\\u2019re Already Doing Right</h4>' +\n        '<div class=\"evr-v2-report-positives\">' + html + '</div>' +\n      '</div>'\n    );\n  }\n\n  function renderReportIngredients(p) {\n    var ingredients = p.ingredientPriority || [];\n    if (!ingredients.length) return '';\n\n    var maxScore = ingredients[0].score || 1;\n    var cardsHtml = ingredients.map(function (ing, idx) {\n      var pct = Math.round((ing.score / maxScore) * 100);\n      var reason = getPersonalizedIngredientReason(ing.key, p.appliedRules || []);\n      var isPrimary = idx === 0;\n      var badgeClass = isPrimary ? 'evr-v2-report-match-badge--primary' : '';\n      var badgeText = isPrimary ? 'Primary match' : 'Supporting';\n      var cardClass = isPrimary ? ' evr-v2-report-ingredient--primary' : '';\n\n      return (\n        '<div class=\"evr-v2-report-ingredient' + cardClass + '\">' +\n          '<div class=\"evr-v2-report-ingredient__head\">' +\n            '<span class=\"evr-v2-report-match-badge ' + badgeClass + '\">' + badgeText + '</span>' +\n            '<h5 class=\"evr-v2-report-ingredient__name\">' + escapeHtml(ing.label) + ' \u00B7 ' + escapeHtml(ing.dose) + '</h5>' +\n          '</div>' +\n          '<div style=\"height:10px;border-radius:5px;background:#e8eaec;overflow:hidden;margin-top:4px\">' +\n            '<div style=\"display:block!important;height:100%;width:' + pct + '%;background:linear-gradient(90deg,#2d8a5e,#5cc88a);border-radius:5px;min-height:10px\">\\u200B</div>' +\n          '</div>' +\n          '<p class=\"evr-v2-report-ingredient__bar-label\">Match strength: ' + pct + '%</p>' +\n          '<p class=\"evr-v2-report-ingredient__why\">' + escapeHtml(ing.why) + '</p>' +\n          (reason ? '<p class=\"evr-v2-report-ingredient__reason\">\\u2192 ' + escapeHtml(reason) + '</p>' : '') +\n        '</div>'\n      );\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title\">Your Ingredient Match</h4>' +\n        '<p class=\"evr-v2-report-section__sub\">Our Wellness Team matched these ingredients based on your ' + (p.appliedRules || []).length + ' data points:</p>' +\n        '<div class=\"evr-v2-report-ingredients\">' + cardsHtml + '</div>' +\n      '</div>'\n    );\n  }\n\n  function renderReportMelatoninEducation() {\n    if (getAnswerArray('q10').indexOf('attempt_melatonin') === -1) return '';\n\n    return (\n      '<div class=\"evr-v2-report-section evr-v2-report-melatonin\">' +\n        '<h4 class=\"evr-v2-report-section__title\">You Tried Melatonin \\u2014 Here\\u2019s Why This Is Different</h4>' +\n        '<div class=\"evr-v2-report-melatonin__grid\">' +\n          '<div class=\"evr-v2-report-melatonin__col\">' +\n            '<p class=\"evr-v2-report-melatonin__label evr-v2-report-melatonin__label--old\">Melatonin</p>' +\n            '<ul class=\"evr-v2-report-melatonin__list\">' +\n              '<li>Signals your brain it\\u2019s time for sleep</li>' +\n              '<li>Doesn\\u2019t address stress or a busy mind</li>' +\n              '<li>Can cause morning grogginess</li>' +\n              '<li>Your body may reduce its own production over time</li>' +\n            '</ul>' +\n          '</div>' +\n          '<div class=\"evr-v2-report-melatonin__col\">' +\n            '<p class=\"evr-v2-report-melatonin__label evr-v2-report-melatonin__label--new\">Calm+Rest</p>' +\n            '<ul class=\"evr-v2-report-melatonin__list\">' +\n              '<li>Affron saffron supports mood balance and calm</li>' +\n              '<li>L-Theanine promotes relaxation and quiets mental chatter</li>' +\n              '<li>Magnesium bisglycinate supports muscle relaxation</li>' +\n              '<li>Works with your body\\u2019s natural sleep process, not around it</li>' +\n            '</ul>' +\n          '</div>' +\n        '</div>' +\n        '<p class=\"evr-v2-report-melatonin__note\">Melatonin tells your brain <em>when</em> to sleep. Affron saffron, L-Theanine, and magnesium bisglycinate help your body <em>get ready</em> for sleep \\u2014 by supporting the calm your nervous system needs first.</p>' +\n      '</div>'\n    );\n  }\n\n  function renderReportTips() {\n    var TIPS = [\n      { q: 'q2', id: 'screen_time', title: 'Create a screen-free window', body: 'Try 45\\u201360 minutes of no screens before bed. Blue light suppresses melatonin, making it harder to feel sleepy.', bridge: 'Calm+Rest pairs well with this habit \\u2014 its L-Theanine promotes relaxation during your wind-down window.' },\n      { q: 'q2', id: 'caffeine', title: 'Watch your caffeine cutoff', body: 'Caffeine has a 6-hour half-life. Try setting a hard cutoff at 2 PM to give your body time to wind down.', bridge: 'Calm+Rest contains magnesium bisglycinate, which supports muscle relaxation and healthy sleep patterns.' },\n      { q: 'q2', id: 'sleep_environment', title: 'Optimize your sleep space', body: 'Keep your room cool (65\\u201368\\u00B0F), dark, and quiet. Even small light sources can disrupt deep sleep cycles.', bridge: '' },\n      { q: 'q2', id: 'racing_thoughts', title: 'Try a pre-bed brain dump', body: 'Write down every thought before bed. Externalizing your mental loop quiets the mind faster than trying to ignore it.', bridge: 'Calm+Rest\\u2019s L-Theanine promotes alpha-wave activity, supporting mental calm alongside your journaling practice.' },\n      { q: 'q5', id: 'overthinking_future', title: 'Try a thought dump', body: 'Before bed, write down tomorrow\\u2019s worries on paper. Externalizing thoughts helps quiet the mind.', bridge: 'Calm+Rest\\u2019s L-Theanine promotes alpha-wave activity, supporting mental calm alongside your journaling practice.' },\n      { q: 'q5', id: 'digital_overload', title: 'Set digital boundaries', body: 'Try a \\u2018no notifications\\u2019 window in the evening. Even 1 hour of digital silence can lower your cortisol levels.', bridge: '' },\n      { q: 'q11', id: 'time_morning_anxious', title: 'Anchor your morning', body: 'Start with 2 minutes of slow breathing before checking your phone. A calm start sets the tone for the whole day.', bridge: '' },\n      { q: 'q11', id: 'time_midday_crash', title: 'Beat the midday dip', body: 'A 10-minute walk + natural sunlight at lunch resets your circadian rhythm and boosts afternoon energy.', bridge: '' },\n      { q: 'q5', id: 'no_time_for_self', title: 'Protect 15 minutes daily', body: 'Block 15 minutes in your calendar just for you. Self-care isn\\u2019t selfish \\u2014 it\\u2019s the foundation everything else runs on.', bridge: '' },\n      { q: 'q7', id: 'symptom_muscle_tension', title: 'Release tension before bed', body: 'Progressive muscle relaxation \\u2014 tensing then releasing each muscle group for 5 seconds \\u2014 signals your body to shift into rest mode.', bridge: 'Calm+Rest\\u2019s Chelamax magnesium supports muscle and nervous-system relaxation.*' },\n    ];\n\n    var matched = [];\n    for (var i = 0; i < TIPS.length && matched.length < 3; i += 1) {\n      var tip = TIPS[i];\n      if (getAnswerArray(tip.q).indexOf(tip.id) !== -1) {\n        matched.push(tip);\n      }\n    }\n\n    if (matched.length < 2) {\n      matched.push({ title: 'Consistency is your superpower', body: 'Same bedtime \\u00B130 min, even on weekends, trains your circadian rhythm. It\\u2019s the simplest change with the biggest payoff.' });\n    }\n\n    var html = matched.map(function (tip, idx) {\n      return (\n        '<div class=\"evr-v2-report-tip\">' +\n          '<span class=\"evr-v2-report-tip__num\">' + (idx + 1) + '</span>' +\n          '<div class=\"evr-v2-report-tip__body\">' +\n            '<h5 class=\"evr-v2-report-tip__title\">' + escapeHtml(tip.title) + '</h5>' +\n            '<p class=\"evr-v2-report-tip__text\">' + escapeHtml(tip.body) + '</p>' +\n            (tip.bridge ? '<p class=\"evr-v2-report-tip__bridge\">' + escapeHtml(tip.bridge) + '</p>' : '') +\n          '</div>' +\n        '</div>'\n      );\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title\">Your Wellness Tips</h4>' +\n        '<p class=\"evr-v2-report-section__sub\">Small changes that complement your supplement routine:</p>' +\n        '<div class=\"evr-v2-report-tips\">' + html + '</div>' +\n      '</div>'\n    );\n  }\n\n  function renderReportTimeline(p) {\n    var timeline = p.timeline || [];\n    if (!timeline.length) return '';\n\n    var stepsHtml = timeline.map(function (step, idx) {\n      var isLast = idx === timeline.length - 1;\n      return (\n        '<div class=\"evr-v2-report-timeline__step\">' +\n          '<div class=\"evr-v2-report-timeline__rail\">' +\n            '<span class=\"evr-v2-report-timeline__dot\"></span>' +\n            (!isLast ? '<span class=\"evr-v2-report-timeline__line\"></span>' : '') +\n          '</div>' +\n          '<div class=\"evr-v2-report-timeline__content\">' +\n            '<span class=\"evr-v2-report-timeline__label\">' + escapeHtml(step.label) + '</span>' +\n            '<h5 class=\"evr-v2-report-timeline__title\">' + escapeHtml(step.title) + '</h5>' +\n            '<p class=\"evr-v2-report-timeline__body\">' + escapeHtml(step.body) + '</p>' +\n          '</div>' +\n        '</div>'\n      );\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title\">Your Progress Timeline</h4>' +\n        '<div class=\"evr-v2-report-timeline\">' + stepsHtml + '</div>' +\n      '</div>'\n    );\n  }\n\n  function renderReportTestimonials(p) {\n    var testimonials = p.testimonials || [];\n    if (!testimonials.length) return '';\n\n    var html = testimonials.map(function (t) {\n      return (\n        '<blockquote class=\"evr-v2-report-testimonial\">' +\n          '<p class=\"evr-v2-report-testimonial__quote\">\\u201C' + escapeHtml(t.quote) + '\\u201D</p>' +\n          '<footer class=\"evr-v2-report-testimonial__author\">' +\n            escapeHtml(t.author) +\n            (t.context ? ' \u00B7 <span class=\"evr-v2-report-testimonial__ctx\">' + escapeHtml(t.context) + '</span>' : '') +\n          '</footer>' +\n        '</blockquote>'\n      );\n    }).join('');\n\n    return (\n      '<div class=\"evr-v2-report-section\">' +\n        '<h4 class=\"evr-v2-report-section__title\">From People Like You</h4>' +\n        html +\n        '<p class=\"evr-v2-report-testimonial__disclaimer\">Individual results may vary.</p>' +\n      '</div>'\n    );\n  }\n\n  function renderReportCta(p) {\n    var profileLabel = escapeHtml(p.profileLabel || 'Personalized');\n\n    return (\n      '<div class=\"evr-v2-report-cta\">' +\n        '<button type=\"button\" class=\"evr-v2-report-cta__btn\" data-evr-v2-report-start-cta>' +\n          'Start Your ' + profileLabel + ' Routine' +\n        '</button>' +\n        '<p class=\"evr-v2-report-cta__sub\">Curated by the Evolance Wellness Team based on your quiz results.</p>' +\n      '</div>'\n    );\n  }\n\n  function renderReportDisclaimer() {\n    return (\n      '<p class=\"evr-v2-report-disclaimer\">' +\n        'These statements have not been evaluated by the Food and Drug Administration. ' +\n        'This product is not intended to diagnose, treat, cure, or prevent any disease.' +\n      '</p>'\n    );\n  }\n\n  function renderReportFooter() {\n    return (\n      '<p class=\"evr-v2-report-footer\">' +\n        'You can retake the quiz anytime to update your results.' +\n      '</p>'\n    );\n  }\n\n  function renderSafetyReport(p) {\n    return (\n      '<div class=\"evr-v2-report-header evr-v2-report-header--safety\">' +\n        '<span class=\"evr-v2-report-badge evr-v2-report-badge--safety\">Safety Review</span>' +\n        '<h3 class=\"evr-v2-report-header__title\">Please consult your physician first</h3>' +\n        '<p class=\"evr-v2-report-header__sub\">You indicated pregnancy or breastfeeding in your quiz. Your safety is our priority.</p>' +\n      '</div>' +\n      '<div class=\"evr-v2-report-section\">' +\n        '<p>We recommend sharing your quiz results with your healthcare provider before starting any supplement routine. ' +\n        'This report is for informational purposes only and does not replace medical advice.</p>' +\n        '<p style=\"margin-top:12px\">Checkout has been paused for your safety. Once you have medical clearance, you can return to complete your order.</p>' +\n      '</div>' +\n      '<div class=\"evr-v2-report-cta\">' +\n        '<button type=\"button\" class=\"evr-v2-report-cta__btn evr-v2-report-cta__btn--secondary\" data-evr-v2-report-start-cta>' +\n          'Contact a Specialist' +\n        '</button>' +\n      '</div>' +\n      renderReportDisclaimer()\n    );\n  }\n\n  function renderPersonalizedReport(p) {\n    if (p.safetyGate) {\n      return renderSafetyReport(p);\n    }\n    return (\n      renderReportHeader(p) +\n      renderReportSnapshot(p) +\n      renderReportConcerns(p) +\n      renderReportPositives(p) +\n      renderReportIngredients(p) +\n      '<p class=\"evr-v2-report-soft-cta\"><button type=\"button\" class=\"evr-v2-report-soft-cta__link\" data-evr-v2-report-start-cta>Ready to start? See your recommended routine \\u2192</button></p>' +\n      renderReportMelatoninEducation() +\n      renderReportTips() +\n      renderReportTimeline(p) +\n      renderReportTestimonials(p) +\n      renderReportCta(p) +\n      renderReportDisclaimer() +\n      renderReportFooter()\n    );\n  }\n\n  function buildV2FocusChips(personalization) {\n    const profileKey = normalizeV2ProfileKey(personalization && personalization.profileKey);\n    const map = {\n      sleep_starter: ['Sleep onset', 'Night calm', 'Mood stability', 'Morning reset'],\n      sleep_restoration: ['Stay asleep', 'Fewer wakeups', 'Stress regulation', 'Morning energy'],\n      complete_calm: ['Stress relief', 'Sleep quality', 'Cramp support', 'Mood support'],\n      stress_recovery: ['All-day stress', 'Evening unwind', 'Sleep continuity', 'Mood balance'],\n      safety: ['Safety first', 'Physician review', 'Profile guidance', 'No checkout'],\n      all: ['Sleep continuity', 'Stress support', 'Mood balance', 'Morning recovery'],\n    };\n    const fallback = map[profileKey] || map.all;\n    return fallback.slice(0, 4);\n  }\n\n  function renderV2Chips(containerSelector, chips) {\n    document.querySelectorAll(containerSelector).forEach((container) => {\n      clearElement(container);\n      chips.forEach((chip) => {\n        const node = document.createElement('span');\n        node.className = 'evr-v2-chip';\n        node.textContent = chip;\n        container.appendChild(node);\n      });\n    });\n  }\n\n  function applyV2FocusSummary(personalization) {\n    const resultLine = buildV2ResultLine(personalization);\n    const chips = buildV2FocusChips(personalization);\n    setTextForNodes('[data-evr-result-line]', resultLine);\n    setTextForNodes('[data-evr-routine-result]', resultLine);\n    renderV2Chips('[data-evr-hero-chips]', chips);\n    renderV2Chips('[data-evr-result-chips]', chips);\n  }\n\n  function forceCloseV2ReportModal() {\n    const modal = document.querySelector('[data-evr-v2-report-modal]');\n    if (modal) {\n      modal.setAttribute('hidden', 'hidden');\n      modal.setAttribute('aria-hidden', 'true');\n    }\n    document.body.classList.remove('evr-v2-modal-open');\n    document.querySelectorAll('[data-evr-v2-report-open]').forEach((button) => {\n      button.setAttribute('aria-expanded', 'false');\n    });\n  }\n\n  function bindV2ReportModalEditorCleanup() {\n    if (!isThemeEditor || v2ReportModalEditorCleanupBound) {\n      return;\n    }\n\n    ['shopify:section:select', 'shopify:block:select', 'shopify:section:load', 'shopify:section:unload', 'shopify:section:reorder', 'shopify:block:deselect', 'shopify:section:deselect'].forEach((eventName) => {\n      document.addEventListener(eventName, forceCloseV2ReportModal);\n    });\n    v2ReportModalEditorCleanupBound = true;\n  }\n\n  function bindV2ReportModal() {\n    const modal = document.querySelector('[data-evr-v2-report-modal]');\n    if (!modal) {\n      if (v2ReportModalKeyHandler) {\n        document.removeEventListener('keydown', v2ReportModalKeyHandler);\n        v2ReportModalKeyHandler = null;\n      }\n      document.body.classList.remove('evr-v2-modal-open');\n      return;\n    }\n    const dialog = modal.querySelector('[data-evr-v2-report-dialog]');\n    let lastFocusedTrigger = null;\n\n    const getFocusableNodes = () => {\n      if (!dialog) {\n        return [];\n      }\n      return Array.from(\n        dialog.querySelectorAll(\n          'a[href], button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex=\"-1\"])'\n        )\n      ).filter((node) => {\n        return node.offsetParent !== null && !node.hasAttribute('hidden');\n      });\n    };\n\n    const closeModal = () => {\n      modal.setAttribute('hidden', 'hidden');\n      modal.setAttribute('aria-hidden', 'true');\n      document.body.classList.remove('evr-v2-modal-open');\n      document.querySelectorAll('[data-evr-v2-report-open]').forEach((button) => {\n        button.setAttribute('aria-expanded', 'false');\n      });\n      if (lastFocusedTrigger && typeof lastFocusedTrigger.focus === 'function') {\n        safeFocus(lastFocusedTrigger);\n      }\n      lastFocusedTrigger = null;\n    };\n\n    if (isThemeEditor) {\n      if (v2ReportModalKeyHandler) {\n        document.removeEventListener('keydown', v2ReportModalKeyHandler);\n        v2ReportModalKeyHandler = null;\n      }\n      forceCloseV2ReportModal();\n      bindV2ReportModalEditorCleanup();\n\n      document.querySelectorAll('[data-evr-v2-report-open]').forEach((button) => {\n        button.setAttribute('aria-expanded', 'false');\n        button.onclick = (event) => {\n          event.preventDefault();\n          event.stopPropagation();\n          forceCloseV2ReportModal();\n        };\n      });\n\n      return;\n    }\n\n    const openModal = () => {\n      modal.removeAttribute('hidden');\n      modal.setAttribute('aria-hidden', 'false');\n      document.body.classList.add('evr-v2-modal-open');\n      document.querySelectorAll('[data-evr-v2-report-open]').forEach((button) => {\n        button.setAttribute('aria-expanded', 'true');\n      });\n      if (dialog) {\n        safeFocus(dialog);\n      }\n    };\n\n    document.querySelectorAll('[data-evr-v2-report-open]').forEach((button) => {\n      button.setAttribute('aria-expanded', 'false');\n      button.onclick = (event) => {\n        event.preventDefault();\n        lastFocusedTrigger = button;\n        openModal();\n      };\n    });\n\n    modal.querySelectorAll('[data-evr-v2-report-close]').forEach((button) => {\n      button.onclick = (event) => {\n        event.preventDefault();\n        closeModal();\n      };\n    });\n\n    modal.addEventListener('click', (event) => {\n      var ctaBtn = event.target.closest('[data-evr-v2-report-start-cta]');\n      if (ctaBtn) {\n        event.preventDefault();\n        closeModal();\n        var personalization = getPersonalization();\n        var scrollSelector = personalization && personalization.safetyGate\n          ? '.evr-v2-section--contact'\n          : '.evr-v2-section--core';\n        var scrollTarget = document.querySelector(scrollSelector);\n        if (scrollTarget) {\n          scrollTarget.scrollIntoView({ behavior: 'smooth', block: 'start' });\n        }\n      }\n    });\n\n    modal.onclick = (event) => {\n      if (event.target === modal) {\n        closeModal();\n      }\n    };\n\n    if (v2ReportModalKeyHandler) {\n      document.removeEventListener('keydown', v2ReportModalKeyHandler);\n    }\n    v2ReportModalKeyHandler = (event) => {\n      if (modal.hasAttribute('hidden')) {\n        return;\n      }\n      if (event.key === 'Escape') {\n        event.preventDefault();\n        closeModal();\n        return;\n      }\n      if (event.key === 'Tab') {\n        const focusableNodes = getFocusableNodes();\n        if (!focusableNodes.length) {\n          if (dialog) {\n            event.preventDefault();\n            safeFocus(dialog);\n          }\n          return;\n        }\n        const first = focusableNodes[0];\n        const last = focusableNodes[focusableNodes.length - 1];\n        const activeElement = document.activeElement;\n        if (event.shiftKey && activeElement === first) {\n          event.preventDefault();\n          safeFocus(last);\n        } else if (!event.shiftKey && activeElement === last) {\n          event.preventDefault();\n          safeFocus(first);\n        }\n      }\n    };\n    document.addEventListener('keydown', v2ReportModalKeyHandler);\n  }\n\n  function syncExternalSafetySections(isVisible) {\n    document.querySelectorAll('[data-evr-safety-section]').forEach((node) => {\n      node.classList.toggle('evr-hidden', !isVisible);\n      if (isVisible) {\n        node.removeAttribute('hidden');\n      } else {\n        node.setAttribute('hidden', 'hidden');\n      }\n    });\n  }\n\n  function createOptionButton(option, selectedIds, dimmedIds) {\n    const button = document.createElement('button');\n    button.type = 'button';\n    button.className = 'evq-option';\n    button.dataset.optionId = option.id;\n\n    if (selectedIds.includes(option.id)) {\n      button.classList.add('is-selected');\n    }\n\n    if (dimmedIds.includes(option.id)) {\n      button.classList.add('is-dimmed');\n    }\n\n    const emoji = document.createElement('span');\n    emoji.className = 'evq-option__emoji';\n    emoji.textContent = option.emoji || '\u2022';\n\n    const text = document.createElement('span');\n    text.className = 'evq-option__text';\n    text.textContent = option.label;\n\n    button.appendChild(emoji);\n    button.appendChild(text);\n\n    return button;\n  }\n\n  function handleOptionToggle(step, optionId) {\n    const selected = ensureRouteAnswer(step.route);\n    const option = step.options.find((entry) => entry.id === optionId);\n\n    if (!option) {\n      return;\n    }\n\n    const nextSelected = new Set(selected);\n\n    if (step.type === 'single') {\n      if (nextSelected.has(optionId)) {\n        nextSelected.delete(optionId);\n      } else {\n        nextSelected.clear();\n        nextSelected.add(optionId);\n      }\n\n      state.answers[step.route] = Array.from(nextSelected);\n      if (step.route !== 'q1') {\n        queueTrackEvent('ANSWER_SELECTED', {\n          route: step.route,\n          questionKey: step.route,\n          answerIds: state.answers[step.route],\n        });\n      }\n      render();\n      return;\n    }\n\n    if (option.exclusive) {\n      if (nextSelected.has(optionId)) {\n        nextSelected.delete(optionId);\n      } else {\n        nextSelected.clear();\n        nextSelected.add(optionId);\n      }\n\n      state.answers[step.route] = Array.from(nextSelected);\n      if (step.route !== 'q1') {\n        queueTrackEvent('ANSWER_SELECTED', {\n          route: step.route,\n          questionKey: step.route,\n          answerIds: state.answers[step.route],\n        });\n      }\n      render();\n      return;\n    }\n\n    if (nextSelected.has(optionId)) {\n      nextSelected.delete(optionId);\n    } else {\n      step.options.forEach((entry) => {\n        if (entry.exclusive) {\n          nextSelected.delete(entry.id);\n        }\n      });\n\n      if (step.maxSelections && nextSelected.size >= step.maxSelections) {\n        render();\n        return;\n      }\n\n      nextSelected.add(optionId);\n    }\n\n    state.answers[step.route] = Array.from(nextSelected);\n    if (step.route !== 'q1') {\n      queueTrackEvent('ANSWER_SELECTED', {\n        route: step.route,\n        questionKey: step.route,\n        answerIds: state.answers[step.route],\n      });\n    }\n    render();\n  }\n\n  function renderQuestionStep(step) {\n    const selected = ensureRouteAnswer(step.route);\n    const section = document.createElement('section');\n\n    const mapEntry = QUESTION_ROUTE_MAP.find((entry) => entry.route === step.route);\n    const kicker = document.createElement('p');\n    kicker.className = 'evq-kicker';\n    kicker.textContent = `${mapEntry.phase} \u2022 Question ${mapEntry.step}`;\n\n    const question = document.createElement('h2');\n    question.className = 'evq-question';\n    question.textContent = step.question;\n\n    section.appendChild(kicker);\n    section.appendChild(question);\n\n    if (step.instruction) {\n      const instruction = document.createElement('p');\n      instruction.className = 'evq-instruction';\n      instruction.textContent = step.instruction;\n      section.appendChild(instruction);\n    }\n\n    const style = step.style || 'grid';\n\n    if (style === 'slider') {\n      renderSliderOptions(section, step, selected);\n    } else if (style === 'body-map') {\n      renderBodyMapOptions(section, step, selected);\n    } else if (style === 'timeline') {\n      renderTimelineOptions(section, step, selected);\n    } else {\n      // grid, emoji-cards, mood-grid, ranked \u2014 all use evq-options grid with style variant\n      const options = document.createElement('div');\n      options.className = 'evq-options';\n      options.dataset.desktopCols = String(step.desktopColumns || 3);\n      options.dataset.style = style;\n\n      const dimmedIds = [];\n      if (step.maxSelections && selected.length >= step.maxSelections) {\n        step.options.forEach((option) => {\n          if (!selected.includes(option.id)) {\n            dimmedIds.push(option.id);\n          }\n        });\n      }\n\n      step.options.forEach((option) => {\n        const optionButton = style === 'aspiration-cards'\n          ? createAspirationCardButton(option, selected, dimmedIds)\n          : style === 'emoji-cards' || style === 'mood-grid'\n          ? createEmojiCardButton(option, selected, dimmedIds)\n          : style === 'ranked'\n            ? createRankedButton(option, selected, dimmedIds)\n            : createOptionButton(option, selected, dimmedIds);\n\n        optionButton.addEventListener('click', () => {\n          handleOptionToggle(step, option.id);\n        });\n\n        options.appendChild(optionButton);\n      });\n\n      section.appendChild(options);\n    }\n\n    content.appendChild(section);\n  }\n\n  /* \u2500\u2500 Emoji Card Button (Q3, Q4) \u2500\u2500 */\n  function createEmojiCardButton(option, selectedIds, dimmedIds) {\n    const button = document.createElement('button');\n    button.type = 'button';\n    button.className = 'evq-option evq-emoji-card';\n    button.dataset.optionId = option.id;\n\n    if (selectedIds.includes(option.id)) button.classList.add('is-selected');\n    if (dimmedIds.includes(option.id)) button.classList.add('is-dimmed');\n\n    const emoji = document.createElement('span');\n    emoji.className = 'evq-emoji-card__icon';\n    emoji.textContent = option.emoji || '\u2022';\n\n    const text = document.createElement('span');\n    text.className = 'evq-emoji-card__label';\n    text.textContent = option.label;\n\n    button.appendChild(emoji);\n    button.appendChild(text);\n    return button;\n  }\n\n  /* \u2500\u2500 Ranked Button (Q8, Q9) \u2014 shows priority number badge \u2500\u2500 */\n  /* \u2500\u2500 Aspiration Card Button (Q8 \u2014 visual aspiration gap) \u2500\u2500 */\n  function createAspirationCardButton(option, selectedIds, dimmedIds) {\n    var button = document.createElement('button');\n    button.type = 'button';\n    button.className = 'evq-option evq-aspiration-card';\n    button.dataset.optionId = option.id;\n\n    if (selectedIds.includes(option.id)) button.classList.add('is-selected');\n    if (dimmedIds.includes(option.id)) button.classList.add('is-dimmed');\n\n    var emoji = document.createElement('span');\n    emoji.className = 'evq-aspiration-card__icon';\n    emoji.textContent = option.emoji || '';\n\n    var label = document.createElement('span');\n    label.className = 'evq-aspiration-card__label';\n    label.textContent = option.label;\n\n    button.appendChild(emoji);\n    button.appendChild(label);\n    return button;\n  }\n\n  function createRankedButton(option, selectedIds, dimmedIds) {\n    const button = document.createElement('button');\n    button.type = 'button';\n    button.className = 'evq-option evq-ranked';\n    button.dataset.optionId = option.id;\n\n    if (selectedIds.includes(option.id)) button.classList.add('is-selected');\n    if (dimmedIds.includes(option.id)) button.classList.add('is-dimmed');\n\n    const rank = selectedIds.indexOf(option.id);\n    const badge = document.createElement('span');\n    badge.className = 'evq-ranked__badge';\n    badge.textContent = rank >= 0 ? String(rank + 1) : '';\n\n    const emoji = document.createElement('span');\n    emoji.className = 'evq-option__emoji';\n    emoji.textContent = option.emoji || '\u2022';\n\n    const text = document.createElement('span');\n    text.className = 'evq-option__text';\n    text.textContent = option.label;\n\n    button.appendChild(badge);\n    button.appendChild(emoji);\n    button.appendChild(text);\n    return button;\n  }\n\n  /* \u2500\u2500 Slider (Q1) \u2014 visual scale with clickable stops \u2500\u2500 */\n  function renderSliderOptions(section, step, selected) {\n    const wrapper = document.createElement('div');\n    wrapper.className = 'evq-slider';\n\n    const selectedIndex = selected.length > 0\n      ? step.options.findIndex((o) => o.id === selected[0])\n      : -1;\n\n    // Track with fill + dots\n    const track = document.createElement('div');\n    track.className = 'evq-slider__track';\n\n    const fill = document.createElement('div');\n    fill.className = 'evq-slider__fill';\n    fill.style.width = selectedIndex >= 0\n      ? `${(selectedIndex / (step.options.length - 1)) * 100}%`\n      : '0%';\n    track.appendChild(fill);\n\n    step.options.forEach((option, i) => {\n      const stop = document.createElement('button');\n      stop.type = 'button';\n      stop.className = 'evq-slider__stop';\n      if (selected.includes(option.id)) stop.classList.add('is-selected');\n      if (selectedIndex >= 0 && i <= selectedIndex) stop.classList.add('is-filled');\n      stop.style.left = `${(i / (step.options.length - 1)) * 100}%`;\n\n      const dot = document.createElement('span');\n      dot.className = 'evq-slider__dot';\n      stop.appendChild(dot);\n\n      stop.addEventListener('click', () => {\n        handleOptionToggle(step, option.id);\n      });\n\n      track.appendChild(stop);\n    });\n\n    wrapper.appendChild(track);\n\n    // Labels below track, aligned to stops\n    const labels = document.createElement('div');\n    labels.className = 'evq-slider__labels';\n\n    step.options.forEach((option) => {\n      const label = document.createElement('button');\n      label.type = 'button';\n      label.className = 'evq-slider__label';\n      if (selected.includes(option.id)) label.classList.add('is-selected');\n\n      const emoji = document.createElement('span');\n      emoji.className = 'evq-slider__emoji';\n      emoji.textContent = option.emoji || '';\n\n      const text = document.createElement('span');\n      text.className = 'evq-slider__text';\n      text.textContent = option.label;\n\n      label.appendChild(emoji);\n      label.appendChild(text);\n\n      label.addEventListener('click', () => {\n        handleOptionToggle(step, option.id);\n      });\n\n      labels.appendChild(label);\n    });\n\n    wrapper.appendChild(labels);\n    section.appendChild(wrapper);\n  }\n\n  /* \u2500\u2500 Body Map (Q7) \u2014 silhouette with zone highlights + connector lines \u2500\u2500 */\n  function renderBodyMapOptions(section, step, selected) {\n    const wrapper = document.createElement('div');\n    wrapper.className = 'evq-bodymap';\n\n    // \u2500\u2500\u2500 Desktop: SVG figure with interactive zones \u2500\u2500\u2500\n    const figure = document.createElement('div');\n    figure.className = 'evq-bodymap__figure';\n\n    // Zone definitions: SVG zone id \u2192 body part paths\n    const zoneMap = {\n      symptom_headaches: 'head',\n      symptom_muscle_tension: 'shoulders',\n      symptom_on_edge: 'chest',\n      symptom_digestive: 'stomach',\n      symptom_temperature: 'legs',\n    };\n\n    // Build zone selected state\n    const activeZones = new Set();\n    selected.forEach((id) => { if (zoneMap[id]) activeZones.add(zoneMap[id]); });\n\n    const zoneColor = 'rgba(180, 210, 255, 0.5)';\n    const baseColor = 'currentColor';\n\n    figure.innerHTML = '<svg viewBox=\"0 0 600 440\" class=\"evq-bodymap__svg\">' +\n      '<defs>' +\n        '<filter id=\"glow\"><feGaussianBlur stdDeviation=\"6\" result=\"blur\"/>' +\n        '<feMerge><feMergeNode in=\"blur\"/><feMergeNode in=\"SourceGraphic\"/></feMerge></filter>' +\n      '</defs>' +\n      // Head\n      `<ellipse data-zone=\"head\" cx=\"300\" cy=\"40\" rx=\"26\" ry=\"32\" fill=\"${activeZones.has('head') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('head') ? '0.6' : '0.15'}\" ${activeZones.has('head') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Neck\n      `<rect x=\"290\" y=\"70\" width=\"20\" height=\"16\" rx=\"8\" fill=\"${baseColor}\" opacity=\"0.10\"/>` +\n      // Shoulders + upper torso\n      `<path data-zone=\"shoulders\" d=\"M268 86 Q260 86 258 96 L256 120 L344 120 L342 96 Q340 86 332 86 Z\" fill=\"${activeZones.has('shoulders') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('shoulders') ? '0.5' : '0.10'}\" ${activeZones.has('shoulders') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Chest\n      `<rect data-zone=\"chest\" x=\"256\" y=\"118\" width=\"88\" height=\"36\" rx=\"4\" fill=\"${activeZones.has('chest') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('chest') ? '0.5' : '0.08'}\" ${activeZones.has('chest') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Stomach\n      `<rect data-zone=\"stomach\" x=\"258\" y=\"152\" width=\"84\" height=\"36\" rx=\"6\" fill=\"${activeZones.has('stomach') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('stomach') ? '0.5' : '0.07'}\" ${activeZones.has('stomach') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Left arm\n      `<path d=\"M258 92 Q242 94 236 108 L224 160 Q220 172 228 176 L232 176 Q240 176 242 164 L256 116\" fill=\"${baseColor}\" opacity=\"0.06\"/>` +\n      // Right arm\n      `<path d=\"M342 92 Q358 94 364 108 L376 160 Q380 172 372 176 L368 176 Q360 176 358 164 L344 116\" fill=\"${baseColor}\" opacity=\"0.06\"/>` +\n      // Left leg\n      `<path data-zone=\"legs\" d=\"M272 186 Q268 188 266 198 L260 310 Q258 326 268 328 L276 328 Q284 326 282 310 L288 198 Q288 188 286 186\" fill=\"${activeZones.has('legs') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('legs') ? '0.45' : '0.06'}\" ${activeZones.has('legs') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Right leg\n      `<path data-zone=\"legs\" d=\"M314 186 Q312 188 312 198 L318 310 Q320 326 324 328 L332 328 Q340 326 340 310 L334 198 Q332 188 328 186\" fill=\"${activeZones.has('legs') ? zoneColor : baseColor}\" opacity=\"${activeZones.has('legs') ? '0.45' : '0.06'}\" ${activeZones.has('legs') ? 'filter=\"url(#glow)\"' : ''}/>` +\n      // Connector lines: pin edge \u2192 zone center (dashed)\n      '<g class=\"evq-bodymap__connectors\" stroke=\"rgba(180,210,255,0.4)\" stroke-width=\"1.5\" stroke-dasharray=\"4 3\" fill=\"none\">' +\n        // Racing thoughts (left of head) \u2192 head\n        '<line x1=\"160\" y1=\"38\" x2=\"275\" y2=\"38\"/>' +\n        // Headaches (right of head) \u2192 head\n        '<line x1=\"440\" y1=\"38\" x2=\"326\" y2=\"38\"/>' +\n        // Numb (center above neck) \u2192 head center\n        '<line x1=\"300\" y1=\"75\" x2=\"300\" y2=\"60\"/>' +\n        // Muscle tension (far left) \u2192 left shoulder\n        '<line x1=\"140\" y1=\"100\" x2=\"258\" y2=\"100\"/>' +\n        // Chronic fatigue (far right) \u2192 right shoulder\n        '<line x1=\"460\" y1=\"100\" x2=\"342\" y2=\"100\"/>' +\n        // Heart racing \u2192 chest center\n        '<line x1=\"300\" y1=\"148\" x2=\"300\" y2=\"136\"/>' +\n        // Digestive \u2192 stomach center\n        '<line x1=\"300\" y1=\"188\" x2=\"300\" y2=\"170\"/>' +\n        // Temperature \u2192 legs\n        '<line x1=\"300\" y1=\"300\" x2=\"300\" y2=\"280\"/>' +\n      '</g>' +\n      '</svg>';\n\n    // Pin positions (% of the 600x440 viewbox, mapped to figure container)\n    const hotspots = {\n      symptom_headaches: { x: 50, y: 5, side: 'center' },\n      symptom_muscle_tension: { x: 14, y: 21, side: 'left' },\n      symptom_on_edge: { x: 50, y: 31, side: 'center' },\n      symptom_digestive: { x: 50, y: 42, side: 'center' },\n      symptom_temperature: { x: 50, y: 68, side: 'center' },\n    };\n\n    step.options.forEach((option) => {\n      const hs = hotspots[option.id];\n      if (!hs) return;\n\n      const pin = document.createElement('button');\n      pin.type = 'button';\n      pin.className = 'evq-bodymap__pin';\n      if (hs.side === 'left') pin.classList.add('evq-bodymap__pin--left');\n      else if (hs.side === 'right') pin.classList.add('evq-bodymap__pin--right');\n      if (selected.includes(option.id)) pin.classList.add('is-selected');\n\n      pin.style.left = `${hs.x}%`;\n      pin.style.top = `${hs.y}%`;\n\n      const emoji = document.createElement('span');\n      emoji.className = 'evq-bodymap__pin-emoji';\n      emoji.textContent = option.emoji;\n\n      const label = document.createElement('span');\n      label.className = 'evq-bodymap__pin-label';\n      label.textContent = option.label;\n\n      pin.appendChild(emoji);\n      pin.appendChild(label);\n\n      pin.addEventListener('click', () => {\n        handleOptionToggle(step, option.id);\n      });\n\n      figure.appendChild(pin);\n    });\n\n    // \"None of these\" button always visible under the figure\n    const noneOption = step.options.find((o) => o.exclusive);\n    if (noneOption) {\n      const noneBtn = document.createElement('button');\n      noneBtn.type = 'button';\n      noneBtn.className = 'evq-bodymap__none';\n      if (selected.includes(noneOption.id)) noneBtn.classList.add('is-selected');\n      noneBtn.innerHTML = `<span>${noneOption.emoji}</span> <span>${noneOption.label}</span>`;\n      noneBtn.addEventListener('click', () => {\n        handleOptionToggle(step, noneOption.id);\n      });\n      figure.appendChild(noneBtn);\n    }\n\n    wrapper.appendChild(figure);\n\n    // \u2500\u2500\u2500 Mobile: chip list \u2500\u2500\u2500\n    const chips = document.createElement('div');\n    chips.className = 'evq-bodymap__chips';\n\n    step.options.forEach((option) => {\n      const chip = document.createElement('button');\n      chip.type = 'button';\n      chip.className = 'evq-bodymap__chip';\n      if (selected.includes(option.id)) chip.classList.add('is-selected');\n\n      chip.innerHTML = `<span class=\"evq-bodymap__chip-emoji\">${option.emoji}</span><span>${option.label}</span>`;\n\n      chip.addEventListener('click', () => {\n        handleOptionToggle(step, option.id);\n      });\n\n      chips.appendChild(chip);\n    });\n\n    wrapper.appendChild(chips);\n    section.appendChild(wrapper);\n  }\n\n  /* \u2500\u2500 Timeline (Q11) \u2014 horizontal day timeline \u2500\u2500 */\n  function renderTimelineOptions(section, step, selected) {\n    const wrapper = document.createElement('div');\n    wrapper.className = 'evq-timeline';\n\n    const track = document.createElement('div');\n    track.className = 'evq-timeline__track';\n\n    step.options.forEach((option, i) => {\n      const node = document.createElement('button');\n      node.type = 'button';\n      node.className = 'evq-timeline__node';\n      if (selected.includes(option.id)) node.classList.add('is-selected');\n\n      const dot = document.createElement('span');\n      dot.className = 'evq-timeline__dot';\n\n      const emoji = document.createElement('span');\n      emoji.className = 'evq-timeline__emoji';\n      emoji.textContent = option.emoji;\n\n      const label = document.createElement('span');\n      label.className = 'evq-timeline__label';\n      label.textContent = option.label;\n\n      node.appendChild(dot);\n      node.appendChild(emoji);\n      node.appendChild(label);\n\n      node.addEventListener('click', () => {\n        handleOptionToggle(step, option.id);\n      });\n\n      track.appendChild(node);\n\n      // Add connector line between nodes (except after last)\n      if (i < step.options.length - 1) {\n        const connector = document.createElement('span');\n        connector.className = 'evq-timeline__connector';\n        track.appendChild(connector);\n      }\n    });\n\n    wrapper.appendChild(track);\n    section.appendChild(wrapper);\n  }\n\n  function getDemographics() {\n    if (!state.answers.q12 || Array.isArray(state.answers.q12)) {\n      state.answers.q12 = {\n        age: '',\n        gender: '',\n        femaleConditions: [],\n      };\n    }\n\n    return state.answers.q12;\n  }\n\n  function renderDemographicOptions(wrapper, currentValue, options, onSelect) {\n    const list = document.createElement('div');\n    list.className = 'evq-options';\n    list.dataset.desktopCols = '4';\n\n    options.forEach((option) => {\n      const button = createOptionButton(\n        { id: option.id, label: option.label, emoji: option.emoji || '\u2022' },\n        currentValue ? [currentValue] : [],\n        []\n      );\n\n      button.addEventListener('click', () => onSelect(option.id));\n      list.appendChild(button);\n    });\n\n    wrapper.appendChild(list);\n  }\n\n  function renderDemographicsStep() {\n    const demographics = getDemographics();\n\n    const section = document.createElement('section');\n    const kicker = document.createElement('p');\n    kicker.className = 'evq-kicker';\n    kicker.textContent = 'Phase 5: Demographics \u2022 Question 12';\n\n    const title = document.createElement('h2');\n    title.className = 'evq-question';\n    title.textContent = 'Almost there! A few details for your report.';\n\n    section.appendChild(kicker);\n    section.appendChild(title);\n\n    const container = document.createElement('div');\n    container.className = 'evq-demographics';\n\n    const nameGroup = document.createElement('fieldset');\n    nameGroup.className = 'evq-group';\n    const nameLabel = document.createElement('p');\n    nameLabel.className = 'evq-group__label';\n    nameLabel.textContent = \"What's your first name?\";\n    nameGroup.appendChild(nameLabel);\n    const nameField = document.createElement('div');\n    nameField.className = 'evq-field';\n    const nameInput = document.createElement('input');\n    nameInput.type = 'text';\n    nameInput.placeholder = 'Your name';\n    nameInput.maxLength = 60;\n    nameInput.autocomplete = 'given-name';\n    nameInput.value = state.lead.firstName || '';\n    nameInput.addEventListener('input', (event) => {\n      state.lead.firstName = event.target.value.trim();\n      syncNavState();\n    });\n    nameField.appendChild(nameInput);\n    nameGroup.appendChild(nameField);\n    container.appendChild(nameGroup);\n\n    const ageGroup = document.createElement('fieldset');\n    ageGroup.className = 'evq-group';\n    const ageLabel = document.createElement('p');\n    ageLabel.className = 'evq-group__label';\n    ageLabel.textContent = \"What's your age range?\";\n    ageGroup.appendChild(ageLabel);\n\n    renderDemographicOptions(ageGroup, demographics.age, DEMOGRAPHIC_OPTIONS.age, (selectedAge) => {\n      demographics.age = selectedAge;\n      queueTrackEvent('DEMOGRAPHIC_UPDATED', {\n        route: 'q12',\n        questionKey: 'q12',\n        answerIds: getDemographicAnswerIds(),\n      });\n      render();\n    });\n\n    const genderGroup = document.createElement('fieldset');\n    genderGroup.className = 'evq-group';\n    const genderLabel = document.createElement('p');\n    genderLabel.className = 'evq-group__label';\n    genderLabel.textContent = \"What's your gender?\";\n    genderGroup.appendChild(genderLabel);\n\n    renderDemographicOptions(genderGroup, demographics.gender, DEMOGRAPHIC_OPTIONS.gender, (selectedGender) => {\n      demographics.gender = selectedGender;\n      if (selectedGender !== 'gender_female') {\n        demographics.femaleConditions = [];\n      }\n      queueTrackEvent('DEMOGRAPHIC_UPDATED', {\n        route: 'q12',\n        questionKey: 'q12',\n        answerIds: getDemographicAnswerIds(),\n      });\n      render();\n    });\n\n    container.appendChild(ageGroup);\n    container.appendChild(genderGroup);\n\n    if (demographics.gender === 'gender_female') {\n      const conditionGroup = document.createElement('fieldset');\n      conditionGroup.className = 'evq-group';\n      const conditionLabel = document.createElement('p');\n      conditionLabel.className = 'evq-group__label';\n      conditionLabel.textContent = 'Do any of these apply to you?';\n\n      conditionGroup.appendChild(conditionLabel);\n\n      const list = document.createElement('div');\n      list.className = 'evq-options';\n      list.dataset.desktopCols = '3';\n\n      DEMOGRAPHIC_OPTIONS.femaleConditions.forEach((option) => {\n        const selectedIds = demographics.femaleConditions || [];\n        const button = createOptionButton(option, selectedIds, []);\n        button.addEventListener('click', () => {\n          const nextSelected = new Set(demographics.femaleConditions || []);\n\n          if (option.exclusive) {\n            if (nextSelected.has(option.id)) {\n              nextSelected.delete(option.id);\n            } else {\n              nextSelected.clear();\n              nextSelected.add(option.id);\n            }\n          } else {\n            nextSelected.delete('female_none');\n            if (nextSelected.has(option.id)) {\n              nextSelected.delete(option.id);\n            } else {\n              nextSelected.add(option.id);\n            }\n          }\n\n          demographics.femaleConditions = Array.from(nextSelected);\n          queueTrackEvent('DEMOGRAPHIC_UPDATED', {\n            route: 'q12',\n            questionKey: 'q12',\n            answerIds: getDemographicAnswerIds(),\n          });\n          render();\n        });\n\n        list.appendChild(button);\n      });\n\n      conditionGroup.appendChild(list);\n      container.appendChild(conditionGroup);\n    }\n\n    section.appendChild(container);\n    content.appendChild(section);\n  }\n\n  function renderEmailStep() {\n    hydrateLeadFromCustomer();\n\n    const section = document.createElement('section');\n    const card = document.createElement('div');\n    card.className = 'evq-email';\n\n    const title = document.createElement('h2');\n    title.textContent = 'Your Personalized Sleep & Stress Results Are Ready';\n\n    const description = document.createElement('p');\n    description.textContent = 'Where should we send your personalized Sleep & Stress plan?';\n\n    const socialWrap = document.createElement('div');\n    socialWrap.className = 'evq-social';\n\n    const googleButton = document.createElement('button');\n    googleButton.type = 'button';\n    googleButton.className = 'evq-social__btn';\n    googleButton.innerHTML = `\n      <svg viewBox=\"0 0 20 20\" aria-hidden=\"true\">\n        <path d=\"M18.171 8.368h-.671v-.035H10v3.333h4.709c-.687 1.94-2.533 3.334-4.709 3.334A5 5 0 0 1 5 10a5 5 0 0 1 5-5c1.275 0 2.434.481 3.317 1.266l2.357-2.357A8.287 8.287 0 0 0 10 1.667a8.333 8.333 0 0 0 0 16.666A8.333 8.333 0 0 0 18.333 10c0-.559-.057-1.104-.162-1.632Z\" fill=\"#FFC107\"></path>\n        <path d=\"m2.628 6.121 2.737 2.009A5.007 5.007 0 0 1 10 5c1.275 0 2.434.481 3.317 1.266l2.357-2.357A8.288 8.288 0 0 0 10 1.667 8.332 8.332 0 0 0 2.628 6.12Z\" fill=\"#FF3D00\"></path>\n        <path d=\"M10 18.333c2.152 0 4.109-.824 5.587-2.163l-2.58-2.183A4.983 4.983 0 0 1 10 15a4.998 4.998 0 0 1-4.701-3.31l-2.717 2.093A8.323 8.323 0 0 0 10 18.333Z\" fill=\"#4CAF50\"></path>\n        <path d=\"M18.171 8.368H17.5v-.035H10v3.333h4.709a5.019 5.019 0 0 1-1.704 2.322l2.58 2.182C15.403 16.336 18.333 14.167 18.333 10c0-.559-.057-1.104-.162-1.632Z\" fill=\"#1976D2\"></path>\n      </svg>\n      <span>Continue with Google</span>\n    `;\n    googleButton.addEventListener('click', () => {\n      handleGoogleContinue();\n    });\n    socialWrap.appendChild(googleButton);\n\n    const divider = document.createElement('div');\n    divider.className = 'evq-email__divider';\n    divider.innerHTML = '<span>or continue with email</span>';\n\n    const firstNameField = document.createElement('div');\n    firstNameField.className = 'evq-field';\n\n    const firstNameLabel = document.createElement('label');\n    firstNameLabel.setAttribute('for', 'evq-first-name');\n    firstNameLabel.textContent = 'First Name';\n\n    const firstNameInput = document.createElement('input');\n    firstNameInput.id = 'evq-first-name';\n    firstNameInput.type = 'text';\n    firstNameInput.placeholder = 'Your name';\n    firstNameInput.value = state.lead.firstName;\n    firstNameInput.addEventListener('input', (event) => {\n      state.lead.firstName = event.target.value;\n      syncNavState();\n    });\n\n    firstNameField.appendChild(firstNameLabel);\n    firstNameField.appendChild(firstNameInput);\n\n    const emailField = document.createElement('div');\n    emailField.className = 'evq-field';\n\n    const emailLabel = document.createElement('label');\n    emailLabel.setAttribute('for', 'evq-email');\n    emailLabel.textContent = 'Email';\n\n    const emailInput = document.createElement('input');\n    emailInput.id = 'evq-email';\n    emailInput.type = 'email';\n    emailInput.placeholder = 'email@example.com';\n    emailInput.value = state.lead.email;\n    emailInput.addEventListener('input', (event) => {\n      state.lead.email = event.target.value;\n      syncNavState();\n    });\n\n    emailField.appendChild(emailLabel);\n    emailField.appendChild(emailInput);\n\n    const optIn = document.createElement('label');\n    optIn.className = 'evq-optin';\n\n    const optInBox = document.createElement('input');\n    optInBox.type = 'checkbox';\n    optInBox.checked = state.lead.optIn;\n    optInBox.addEventListener('change', (event) => {\n      state.lead.optIn = event.target.checked;\n    });\n\n    const optInText = document.createElement('span');\n    optInText.textContent = 'By submitting, you consent to receive marketing communications from Evolance Wellness. You can unsubscribe anytime.';\n\n    optIn.appendChild(optInBox);\n    optIn.appendChild(optInText);\n\n    card.appendChild(title);\n    card.appendChild(description);\n    card.appendChild(socialWrap);\n    card.appendChild(divider);\n    card.appendChild(firstNameField);\n    card.appendChild(emailField);\n    card.appendChild(optIn);\n\n    section.appendChild(card);\n    content.appendChild(section);\n  }\n\n  function parseVariantId(rawValue) {\n    if (!rawValue) {\n      return null;\n    }\n\n    const parsed = Number(rawValue);\n    return Number.isFinite(parsed) && parsed > 0 ? parsed : null;\n  }\n\n  function escapeHtml(value) {\n    return String(value || '')\n      .replaceAll('&', '&amp;')\n      .replaceAll('<', '&lt;')\n      .replaceAll('>', '&gt;')\n      .replaceAll('\"', '&quot;')\n      .replaceAll(\"'\", '&#39;');\n  }\n\n  function parseDiscountValueFromCode(code) {\n    /* Extract the discount dollar amount from the code prefix.\n       Format: SLEEP10-XXXXXXXX \u2192 $10, WELCOME5-XXXXXXXX \u2192 $5.\n       Match the FIRST run of digits in the code (the prefix amount),\n       not digits inside the random suffix. */\n    const prefixMatch = String(code || '').match(/^[A-Z]*?(\\d{1,3})/i);\n    const parsed = prefixMatch ? Number(prefixMatch[1]) : 10;\n    if (!Number.isFinite(parsed) || parsed <= 0) {\n      return 10;\n    }\n    return Math.round(parsed);\n  }\n\n  function getActiveDiscountMeta() {\n    if (Number.isFinite(state.manualDiscountPercent) && state.manualDiscountPercent > 0) {\n      return {\n        type: 'percent',\n        value: Math.min(95, Math.round(state.manualDiscountPercent)),\n      };\n    }\n\n    const code = getActiveDiscountCode();\n    if (!code) {\n      return { type: 'fixed', value: 0 };\n    }\n\n    const codeValue = parseDiscountValueFromCode(code);\n    return {\n      type: 'fixed',\n      value: Math.max(0, codeValue * 100),\n    };\n  }\n\n  function getActiveDiscountPercent() {\n    const meta = getActiveDiscountMeta();\n    return meta.type === 'percent' ? meta.value : 0;\n  }\n\n  function getDiscountCentsForAmount(totalCents) {\n    const normalizedTotal = Math.max(0, Math.round(Number(totalCents) || 0));\n    if (!normalizedTotal) {\n      return 0;\n    }\n\n    const meta = getActiveDiscountMeta();\n    if (meta.type === 'percent') {\n      return Math.max(0, Math.round((normalizedTotal * meta.value) / 100));\n    }\n\n    return Math.min(normalizedTotal, Math.max(0, Math.round(meta.value)));\n  }\n\n  function formatCurrencyCents(cents, currencyCode = 'USD') {\n    const numeric = Number(cents);\n    if (!Number.isFinite(numeric)) {\n      return '\u2014';\n    }\n\n    const activeCurrency =\n      currencyCode ||\n      (window.Shopify && window.Shopify.currency && window.Shopify.currency.active) ||\n      'USD';\n\n    try {\n      return new Intl.NumberFormat('en-US', {\n        style: 'currency',\n        currency: activeCurrency,\n        minimumFractionDigits: 2,\n        maximumFractionDigits: 2,\n      }).format(numeric / 100);\n    } catch (error) {\n      return `$${(numeric / 100).toFixed(2)}`;\n    }\n  }\n\n  function parsePriceToCents(rawValue) {\n    const parsed = Number(rawValue);\n    if (!Number.isFinite(parsed)) {\n      return 0;\n    }\n\n    if (parsed > 1000) {\n      return Math.round(parsed);\n    }\n\n    return Math.round(parsed * 100);\n  }\n\n  function normalizeCartItems(rawItems) {\n    const deduped = new Map();\n    (Array.isArray(rawItems) ? rawItems : []).forEach((item) => {\n      const variantId = Number(item && item.id);\n      const quantity = Math.max(1, Math.floor(Number(item && item.quantity) || 1));\n      if (!Number.isFinite(variantId) || variantId <= 0) {\n        return;\n      }\n\n      const existing = deduped.get(variantId) || 0;\n      deduped.set(variantId, existing + quantity);\n    });\n\n    return Array.from(deduped.entries()).map(([id, quantity]) => ({ id, quantity }));\n  }\n\n  function buildDefaultBundleLineItems(profileKey, fallbackVariantId, options = {}) {\n    const mode = options.mode === 'onetime' ? 'onetime' : 'subscribe';\n    const recommendedVariantIds = Array.isArray(options.recommendedVariantIds)\n      ? options.recommendedVariantIds\n          .map((entry) => Number(entry))\n          .filter((entry) => Number.isFinite(entry) && entry > 0)\n      : [];\n    const isSubscribe = mode === 'subscribe';\n    const needsExtraBottle = profileKey === 'complete_calm' || profileKey === 'stress_recovery';\n\n    let primaryVariantId = isSubscribe ? VARIANT_TWO_SUBSCRIBE : VARIANT_TWO_ONETIME;\n    let secondaryVariantId = isSubscribe ? VARIANT_ONE_SUBSCRIBE : VARIANT_ONE_ONETIME;\n\n    if (!primaryVariantId && recommendedVariantIds.length > 0) {\n      primaryVariantId = recommendedVariantIds[0];\n    }\n\n    if (!secondaryVariantId && recommendedVariantIds.length > 1) {\n      secondaryVariantId = recommendedVariantIds[1];\n    }\n\n    if (!primaryVariantId && Number.isFinite(Number(fallbackVariantId))) {\n      primaryVariantId = Number(fallbackVariantId);\n    }\n\n    if (!secondaryVariantId && Number.isFinite(Number(fallbackVariantId))) {\n      secondaryVariantId = Number(fallbackVariantId);\n    }\n\n    const items = [];\n    if (primaryVariantId) {\n      items.push({ id: Number(primaryVariantId), quantity: 2 });\n    }\n    if (needsExtraBottle && secondaryVariantId) {\n      items.push({ id: Number(secondaryVariantId), quantity: 1 });\n    }\n\n    if (!items.length && recommendedVariantIds.length) {\n      items.push({ id: recommendedVariantIds[0], quantity: 1 });\n    }\n\n    return normalizeCartItems(items);\n  }\n\n  function getLineItemSignature(items) {\n    return normalizeCartItems(items)\n      .map((item) => item.id)\n      .join('|');\n  }\n\n  function getCurrentResultLineItems(personalization, fallbackVariantId) {\n    const baseline = buildDefaultBundleLineItems(personalization.profileKey, fallbackVariantId, {\n      mode: state.purchaseMode,\n      recommendedVariantIds: personalization.recommendedVariantIds || [],\n    });\n\n    if (!state.resultsLineItems.length) {\n      state.resultsLineItems = baseline;\n      return state.resultsLineItems;\n    }\n\n    const currentSignature = getLineItemSignature(state.resultsLineItems);\n    const baselineSignature = getLineItemSignature(baseline);\n    if (currentSignature !== baselineSignature) {\n      state.resultsLineItems = baseline;\n    }\n\n    return state.resultsLineItems;\n  }\n\n  async function loadCadenceProduct() {\n    if (state.cadenceProduct) {\n      state.cadenceProductStatus = 'ready';\n      return state.cadenceProduct;\n    }\n\n    if (state.cadenceProductPromise) {\n      return state.cadenceProductPromise;\n    }\n\n    state.cadenceProductStatus = 'loading';\n    state.cadenceProductPromise = fetch('/products/' + encodeURIComponent(PRODUCT_HANDLE) + '.js')\n      .then((response) => {\n        if (!response.ok) {\n          throw new Error('product_fetch_failed');\n        }\n        return response.json();\n      })\n      .then((payload) => {\n        state.cadenceProduct = payload && typeof payload === 'object' ? payload : null;\n        state.cadenceProductStatus = state.cadenceProduct ? 'ready' : 'error';\n        return state.cadenceProduct;\n      })\n      .catch(() => {\n        state.cadenceProduct = null;\n        state.cadenceProductStatus = 'error';\n        return null;\n      })\n      .finally(() => {\n        state.cadenceProductPromise = null;\n      });\n\n    return state.cadenceProductPromise;\n  }\n\n  function buildOptionLabelLookup() {\n    const lookup = {};\n\n    QUIZ_STEPS.forEach((step) => {\n      step.options.forEach((option) => {\n        lookup[option.id] = option.label;\n      });\n    });\n\n    DEMOGRAPHIC_OPTIONS.age.forEach((option) => {\n      lookup[option.id] = option.label;\n    });\n    DEMOGRAPHIC_OPTIONS.gender.forEach((option) => {\n      lookup[option.id] = option.label;\n    });\n    DEMOGRAPHIC_OPTIONS.femaleConditions.forEach((option) => {\n      lookup[option.id] = option.label;\n    });\n\n    return lookup;\n  }\n\n  function getAnswerArray(route) {\n    const value = state.answers[route];\n    if (!value || !Array.isArray(value)) {\n      return [];\n    }\n\n    return value;\n  }\n\n  function hasAnswer(route, answerId) {\n    return getAnswerArray(route).includes(answerId);\n  }\n\n  function countMatches(route, answerIds) {\n    const selected = getAnswerArray(route);\n    return answerIds.reduce((count, id) => (selected.includes(id) ? count + 1 : count), 0);\n  }\n\n  function addIngredientScore(scores, ingredient, value) {\n    scores[ingredient] = (scores[ingredient] || 0) + value;\n  }\n\n  function scoreIngredients() {\n    const scores = {\n      affron: 0,\n      chelamax: 0,\n      l_theanine: 0,\n    };\n\n    Object.keys(INGREDIENT_TAG_WEIGHTS).forEach((routeKey) => {\n      const routeWeights = INGREDIENT_TAG_WEIGHTS[routeKey];\n      getAnswerArray(routeKey).forEach((answerId) => {\n        const answerWeights = routeWeights[answerId];\n        if (!answerWeights) {\n          return;\n        }\n\n        Object.keys(answerWeights).forEach((ingredient) => {\n          addIngredientScore(scores, ingredient, answerWeights[ingredient]);\n        });\n      });\n    });\n\n    if (!scores.affron && !scores.chelamax && !scores.l_theanine) {\n      scores.affron = 1;\n      scores.chelamax = 1;\n      scores.l_theanine = 1;\n    }\n\n    return scores;\n  }\n\n  function computeStressBurden() {\n    let burden = 0;\n\n    burden += countMatches('q4', [\n      'stressed_overwhelmed',\n      'mind_racing',\n      'worried_no_reason',\n      'down_low_energy',\n      'mood_swings',\n      'irritable_short_tempered',\n    ]);\n    burden += countMatches('q5', [\n      'work_demands',\n      'family_relationships',\n      'financial_pressures',\n      'no_time_for_self',\n      'overthinking_future',\n      'health_concerns',\n      'overpacked_schedule',\n      'digital_overload',\n      'not_sure_always_stressed',\n    ]);\n    burden += countMatches('q7', [\n      'symptom_muscle_tension',\n      'symptom_on_edge',\n      'symptom_headaches',\n      'symptom_digestive',\n      'symptom_temperature',\n    ]);\n    burden += countMatches('q11', [\n      'time_morning_anxious',\n      'time_midday_crash',\n      'time_evening_wind_down',\n      'time_bedtime_racing',\n      'time_middle_of_night',\n      'time_all_day_stress',\n    ]);\n\n    if (hasAnswer('q11', 'time_all_day_stress')) {\n      burden += 3;\n    }\n    if (hasAnswer('q10', 'attempt_tried_a_lot')) {\n      burden += 2;\n    }\n\n    return burden;\n  }\n\n  function computeQuizScore() {\n    var score = 68;\n\n    if (hasAnswer('q1', 'rarely_restful')) score -= 12;\n    else if (hasAnswer('q1', 'hard_to_fall_asleep')) score -= 8;\n    else if (hasAnswer('q1', 'wake_during_night')) score -= 6;\n\n    var negativeWake = countMatches('q3', [\n      'wake_tired', 'wake_groggy', 'wake_irritable',\n      'wake_sore', 'wake_coffee', 'wake_inconsistent',\n    ]);\n    score -= Math.min(negativeWake * 2, 8);\n\n    var negativeEmotional = countMatches('q4', [\n      'stressed_overwhelmed', 'mind_racing', 'worried_no_reason',\n      'down_low_energy', 'mood_swings', 'irritable_short_tempered',\n    ]);\n    score -= Math.min(Math.round(negativeEmotional * 1.5), 6);\n\n    var symptomCount = countMatches('q7', [\n      'symptom_muscle_tension', 'symptom_on_edge',\n      'symptom_headaches', 'symptom_digestive',\n      'symptom_temperature',\n    ]);\n    score -= Math.min(symptomCount, 4);\n\n    if (hasAnswer('q10', 'attempt_tried_a_lot')) score -= 3;\n    if (hasAnswer('q11', 'time_all_day_stress')) score -= 3;\n\n    var attemptCount = countMatches('q10', [\n      'attempt_melatonin', 'attempt_magnesium', 'attempt_herbal_sleep_aids',\n      'attempt_prescription_sleep_meds', 'attempt_anti_anxiety_meds',\n      'attempt_apps', 'attempt_sleep_hygiene', 'attempt_therapy',\n      'attempt_exercise_lifestyle',\n    ]);\n    if (attemptCount >= 3) score -= 2;\n    if (attemptCount >= 5) score -= 2;\n\n    return Math.max(40, Math.min(68, Math.round(score)));\n  }\n\n  function getScoreInterpretation(score) {\n    if (score <= 48) return { tier: 'severe', label: 'Disrupted \\u2014 but fastest to improve', color: '#c0392b' };\n    if (score <= 55) return { tier: 'moderate', label: 'Compromised \\u2014 highly responsive to support', color: '#e67e22' };\n    if (score <= 62) return { tier: 'mild', label: 'Declining \\u2014 act now before it deepens', color: '#f1c40f' };\n    return { tier: 'emerging', label: 'Early signs \\u2014 the right time to intervene', color: '#27ae60' };\n  }\n\n  function detectPrimaryIssue() {\n    if (hasAnswer('q11', 'time_all_day_stress')) {\n      return { key: 'all_day_stress', label: 'all-day stress' };\n    }\n\n    if (hasAnswer('q2', 'racing_thoughts')) {\n      return { key: 'racing_thoughts', label: 'a busy mind at night' };\n    }\n\n    if (hasAnswer('q1', 'wake_during_night') || hasAnswer('q11', 'time_middle_of_night')) {\n      return { key: 'sleep_maintenance', label: 'nighttime awakenings' };\n    }\n\n    if (hasAnswer('q1', 'hard_to_fall_asleep') || hasAnswer('q8', 'goal_fall_asleep_faster')) {\n      return { key: 'sleep_onset', label: 'sleep onset delay' };\n    }\n\n    if (hasAnswer('q7', 'symptom_muscle_tension')) {\n      return { key: 'muscle_tension', label: 'stress-related tension' };\n    }\n\n    return { key: 'general_stress_sleep', label: 'stress-disrupted sleep' };\n  }\n\n  function determineProfile(stressBurden) {\n    const isHighStress = hasAnswer('q11', 'time_all_day_stress') || stressBurden >= 11;\n    const isStarter = hasAnswer('q10', 'attempt_nothing_yet');\n    const isMaintenance = hasAnswer('q1', 'wake_during_night');\n    const hasOnsetSignal =\n      hasAnswer('q1', 'hard_to_fall_asleep') ||\n      hasAnswer('q1', 'rarely_restful') ||\n      hasAnswer('q8', 'goal_fall_asleep_faster');\n    const hasStressSignal =\n      stressBurden >= 6 ||\n      hasAnswer('q5', 'work_demands') ||\n      hasAnswer('q5', 'overthinking_future') ||\n      hasAnswer('q2', 'racing_thoughts');\n\n    const hasSupplementHistory =\n      hasAnswer('q10', 'attempt_magnesium') || hasAnswer('q10', 'attempt_melatonin');\n\n    const prioritizedProfiles = [\n      ['stress_recovery', isHighStress],\n      ['sleep_starter', isStarter],\n      ['sleep_restoration', isMaintenance],\n      ['complete_calm', hasOnsetSignal && hasStressSignal],\n      ['complete_calm', hasAnswer('q1', 'sleep_easily') && hasStressSignal && hasSupplementHistory],\n    ];\n\n    for (let index = 0; index < prioritizedProfiles.length; index += 1) {\n      const [profileKey, isMatched] = prioritizedProfiles[index];\n      if (isMatched) {\n        return profileKey;\n      }\n    }\n\n    return 'sleep_restoration';\n  }\n\n  function evaluateRuleIds(profile) {\n    const demographics = getDemographics();\n    const active = [];\n\n    if (hasAnswer('q1', 'hard_to_fall_asleep')) active.push('1A');\n    if (hasAnswer('q1', 'wake_during_night')) active.push('1B');\n    if (hasAnswer('q1', 'rarely_restful')) active.push('1C');\n\n    if (hasAnswer('q5', 'work_demands')) active.push('2A');\n    if (hasAnswer('q5', 'overthinking_future')) active.push('2B');\n    if (hasAnswer('q5', 'family_relationships')) active.push('2C');\n    if (hasAnswer('q5', 'no_time_for_self')) active.push('2D');\n\n    if (hasAnswer('q2', 'racing_thoughts')) active.push('3A');\n    if (hasAnswer('q7', 'symptom_muscle_tension')) active.push('3B');\n    if (hasAnswer('q7', 'symptom_on_edge')) active.push('3C');\n    if (hasAnswer('q4', 'down_low_energy')) active.push('3D');\n\n    if (hasAnswer('q8', 'goal_fall_asleep_faster')) active.push('4A');\n    if (hasAnswer('q8', 'goal_reduce_bedtime_anxiety')) active.push('4B');\n    if (hasAnswer('q9', 'stress_goal_calm_reactive')) active.push('4C');\n    if (hasAnswer('q9', 'stress_goal_think_clearly')) active.push('4D');\n\n    if (hasAnswer('q10', 'attempt_melatonin')) active.push('5A');\n    if (hasAnswer('q10', 'attempt_magnesium')) active.push('5B');\n    if (hasAnswer('q10', 'attempt_prescription_sleep_meds')) active.push('5C');\n    if (hasAnswer('q10', 'attempt_nothing_yet')) active.push('5D');\n    if (hasAnswer('q10', 'attempt_tried_a_lot')) active.push('5E');\n\n    if (hasAnswer('q11', 'time_evening_wind_down')) active.push('6A');\n    if (hasAnswer('q11', 'time_bedtime_racing')) active.push('6B');\n    if (hasAnswer('q11', 'time_middle_of_night')) active.push('6C');\n    if (hasAnswer('q11', 'time_all_day_stress')) active.push('6D');\n\n    if (demographics.gender === 'gender_female' && (demographics.femaleConditions || []).includes('pms_menstrual_issues')) {\n      active.push('7A');\n    }\n    if (\n      demographics.gender === 'gender_female' &&\n      (demographics.femaleConditions || []).includes('perimenopause_menopause')\n    ) {\n      active.push('7B');\n    }\n    if (\n      demographics.gender === 'gender_female' &&\n      (demographics.femaleConditions || []).includes('pregnant_or_breastfeeding')\n    ) {\n      active.push('7C');\n    }\n    if (demographics.gender === 'gender_male' && demographics.age === 'age_35_44') {\n      active.push('7D');\n    }\n    if (demographics.age === 'age_55_64' || demographics.age === 'age_65_plus') {\n      active.push('7E');\n    }\n\n    if (profile === 'sleep_restoration') active.push('8A');\n    if (profile === 'complete_calm') active.push('8B');\n    if (profile === 'stress_recovery') active.push('8C');\n    if (profile === 'sleep_starter') active.push('8D');\n\n    return Array.from(new Set(active));\n  }\n\n  function getTimelineForProfile(profile, stressBurden) {\n    stressBurden = stressBurden || 0;\n\n    // Severity tiers: low (0-5), moderate (6-10), high (11+)\n    var severity = stressBurden <= 5 ? 'low' : stressBurden <= 10 ? 'moderate' : 'high';\n\n    // Symptom-specific detail lines\n    var q7 = getAnswerArray('q7');\n    var details = [];\n    if (q7.indexOf('symptom_muscle_tension') !== -1) details.push('physical tension eases, especially in the evening');\n    if (q7.indexOf('symptom_on_edge') !== -1) details.push('the on-edge feeling becomes less frequent');\n    if (q7.indexOf('symptom_headaches') !== -1) details.push('tension headaches may become less common');\n    if (q7.indexOf('symptom_digestive') !== -1) details.push('stress-related digestive discomfort may ease');\n    if (hasAnswer('q2', 'racing_thoughts')) details.push('mental chatter at bedtime begins to quiet');\n    if (hasAnswer('q4', 'down_low_energy')) details.push('morning energy starts to return');\n\n    // Build a symptom detail sentence for milestone 2\n    var symptomDetail = details.length\n      ? ' Specifically, ' + details.slice(0, 2).join(' and ') + '.'\n      : '';\n\n    // Severity-adjusted labels\n    var LABELS = {\n      low:      { l1: 'Week 1',   l2: 'Week 2\\u20133', l3: 'Month 1+' },\n      moderate: { l1: 'Week 1\\u20132', l2: 'Week 3\\u20134', l3: 'Month 2+' },\n      high:     { l1: 'Week 1\\u20132', l2: 'Week 3\\u20135', l3: 'Month 2\\u20133' },\n    };\n    var labels = LABELS[severity];\n\n    // Profile-specific content with severity + symptom injection\n    var TIMELINES = {\n      stress_recovery: {\n        low: [\n          { id: 'step1', label: labels.l1, title: 'Nervous System Settles', body: 'Evenings may feel less wired. You may notice a calmer wind-down and less emotional carryover from the day.' },\n          { id: 'step2', label: labels.l2, title: 'Stress Resilience Builds', body: 'Daytime reactivity may ease and recovery after stressful moments can feel faster.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'New Calm Baseline', body: 'Many people notice sustained calm and sleep consistency. Steadier mornings and more consistent energy can follow.' },\n        ],\n        moderate: [\n          { id: 'step1', label: labels.l1, title: 'Initial Decompression', body: 'Your body begins adjusting. Evenings may start to feel less wired, though it can take a few days to notice.' },\n          { id: 'step2', label: labels.l2, title: 'Stress Response Shifts', body: 'Daytime reactivity and evening tension may gradually ease. Sleep quality can become more stable.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Deeper Resilience', body: 'The compounding effect can take hold \\u2014 calmer days, more consistent sleep, and steadier mornings.' },\n        ],\n        high: [\n          { id: 'step1', label: labels.l1, title: 'Your Body Starts Adjusting', body: 'With high stress load, the first change is subtle \\u2014 evenings may begin to feel slightly less overwhelming.' },\n          { id: 'step2', label: labels.l2, title: 'Gradual Stress Relief', body: 'The shift may become noticeable. Stress spikes can feel shorter and sleep may start to deepen.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Compound Recovery', body: 'Real change takes time with your stress level, but the ingredients build up steadily. Many people notice more stable energy and sleep by this point.' },\n        ],\n      },\n      sleep_restoration: {\n        low: [\n          { id: 'step1', label: labels.l1, title: 'Back-To-Sleep Easier', body: 'If you wake at night, returning to sleep may get faster and less frustrating.' },\n          { id: 'step2', label: labels.l2, title: 'Fewer Night Awakenings', body: 'Sleep continuity may improve and total awakenings can decline.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Consistent Through-Night Sleep', body: 'Sleep architecture may stabilize with better overnight recovery and clearer mornings.' },\n        ],\n        moderate: [\n          { id: 'step1', label: labels.l1, title: 'Sleep Disruptions Ease', body: 'Night awakenings may still happen, but falling back asleep can get easier.' },\n          { id: 'step2', label: labels.l2, title: 'Sleep Continuity Builds', body: 'The duration of unbroken sleep may stretch longer. You can start waking less frequently.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Restorative Sleep Returns', body: 'Through-night sleep can become more reliable. Morning grogginess may fade as deep sleep improves.' },\n        ],\n        high: [\n          { id: 'step1', label: labels.l1, title: 'The Foundation Phase', body: 'Your body has a lot to recalibrate. Early on, the shift is about easing back to sleep faster when you do wake.' },\n          { id: 'step2', label: labels.l2, title: 'Sleep Patterns Shift', body: 'Awakenings may become less jarring and less frequent. You may notice longer stretches of unbroken sleep.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Sleep Stability Builds', body: 'With your stress level, deeper improvements take patience. By now, sleep continuity and morning clarity may be noticeably better.' },\n        ],\n      },\n      sleep_starter: {\n        low: [\n          { id: 'step1', label: labels.l1, title: 'Foundational Calm', body: 'You can establish a reliable PM routine with reduced bedtime friction.' },\n          { id: 'step2', label: labels.l2, title: 'Sleep Rhythm Stabilizes', body: 'Sleep and wake timing may start to normalize with fewer off-nights.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Sustainable Sleep Habit', body: 'Sleep quality can remain steady with less dependence on reactive fixes.' },\n        ],\n        moderate: [\n          { id: 'step1', label: labels.l1, title: 'Building the Routine', body: 'Your body may start responding to the new PM ritual. Bedtime can feel less like a battle.' },\n          { id: 'step2', label: labels.l2, title: 'Pattern Recognition', body: 'Your body begins expecting sleep at the right time. Onset may shorten and quality can improve.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'New Sleep Identity', body: 'Good sleep can become your default, not something you chase.' },\n        ],\n        high: [\n          { id: 'step1', label: labels.l1, title: 'First Steps Under Stress', body: 'Starting from scratch with high stress means patience. The first win is simply a calmer evening.' },\n          { id: 'step2', label: labels.l2, title: 'Routine Takes Hold', body: 'Your body may start to trust the pattern. Sleep onset can shorten and nighttime anxiety may ease.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Foundation Solidifies', body: 'The habit can become self-reinforcing. Sleep quality and stress management may start working together instead of against each other.' },\n        ],\n      },\n      complete_calm: {\n        low: [\n          { id: 'step1', label: labels.l1, title: 'Faster Wind-Down', body: 'Bedtime pressure may decrease and falling asleep can feel easier.' },\n          { id: 'step2', label: labels.l2, title: 'Stress + Sleep Align', body: 'Mental chatter and stress carryover may reduce while sleep depth can improve.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Calm Performance Baseline', body: 'Many people notice durable calm-focus in the day and more reliable sleep onset at night.' },\n        ],\n        moderate: [\n          { id: 'step1', label: labels.l1, title: 'Evening Calm Begins', body: 'The transition from day to night may get smoother. A busy mind at bedtime can start to ease.' },\n          { id: 'step2', label: labels.l2, title: 'Dual Improvement', body: 'Both stress resilience and sleep quality may start improving in tandem.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'Balanced Days & Nights', body: 'Calmer days can feed better sleep, and better sleep can feed calmer days. The cycle may begin to reverse.' },\n        ],\n        high: [\n          { id: 'step1', label: labels.l1, title: 'Breaking the Cycle', body: 'Stress and sleep are deeply linked for you. The first shift may be a slightly calmer transition to bed.' },\n          { id: 'step2', label: labels.l2, title: 'The Tide Turns', body: 'Sleep onset may improve and daytime stress can start to feel more manageable.' + symptomDetail },\n          { id: 'step3', label: labels.l3, title: 'New Equilibrium', body: 'With your level of combined stress and sleep disruption, real change takes consistency. By now, both may be noticeably better.' },\n        ],\n      },\n    };\n\n    var profileTimeline = TIMELINES[profile] || TIMELINES.complete_calm;\n    return profileTimeline[severity] || profileTimeline.moderate;\n  }\n\n  function getRecommendedTestimonials(profile, appliedRules) {\n    const result = [];\n    appliedRules = appliedRules || [];\n\n    // Rule-based matching (most specific first)\n    if (appliedRules.indexOf('3A') !== -1 && TESTIMONIAL_LIBRARY.racing_thoughts) {\n      result.push(...TESTIMONIAL_LIBRARY.racing_thoughts);\n    }\n    if (appliedRules.indexOf('3B') !== -1 && TESTIMONIAL_LIBRARY.muscle_tension) {\n      result.push(...TESTIMONIAL_LIBRARY.muscle_tension);\n    }\n    if (appliedRules.indexOf('2B') !== -1 && TESTIMONIAL_LIBRARY.overthinking) {\n      result.push(...TESTIMONIAL_LIBRARY.overthinking);\n    }\n    if (appliedRules.indexOf('3D') !== -1 && TESTIMONIAL_LIBRARY.fatigue) {\n      result.push(...TESTIMONIAL_LIBRARY.fatigue);\n    }\n    if (appliedRules.indexOf('6D') !== -1 && TESTIMONIAL_LIBRARY.all_day_stress) {\n      result.push(...TESTIMONIAL_LIBRARY.all_day_stress);\n    }\n\n    // Profile-based fallback\n    if (profile === 'stress_recovery' || profile === 'complete_calm') {\n      result.push(...TESTIMONIAL_LIBRARY.stress);\n    }\n    if (profile === 'sleep_restoration') {\n      result.push(...TESTIMONIAL_LIBRARY.maintenance);\n    }\n    if (profile === 'sleep_starter') {\n      result.push(...TESTIMONIAL_LIBRARY.onset);\n    }\n    if (hasAnswer('q10', 'attempt_melatonin')) {\n      result.push(...TESTIMONIAL_LIBRARY.switcher);\n    }\n    if (hasAnswer('q1', 'hard_to_fall_asleep') || hasAnswer('q8', 'goal_fall_asleep_faster')) {\n      result.push(...TESTIMONIAL_LIBRARY.onset);\n    }\n    if (hasAnswer('q1', 'wake_during_night')) {\n      result.push(...TESTIMONIAL_LIBRARY.maintenance);\n    }\n\n    if (result.length === 0) {\n      result.push(...TESTIMONIAL_LIBRARY.onset);\n    }\n\n    const deduped = [];\n    const seen = new Set();\n    result.forEach((entry) => {\n      const key = `${entry.author}|${entry.quote}`;\n      if (seen.has(key)) {\n        return;\n      }\n      seen.add(key);\n      deduped.push(entry);\n    });\n\n    // Ensure at least 2 testimonials by backfilling from other categories\n    if (deduped.length < 2) {\n      var backfill = [].concat(\n        TESTIMONIAL_LIBRARY.racing_thoughts || [],\n        TESTIMONIAL_LIBRARY.stress || [],\n        TESTIMONIAL_LIBRARY.maintenance || [],\n        TESTIMONIAL_LIBRARY.switcher || []\n      );\n      for (var b = 0; b < backfill.length && deduped.length < 2; b++) {\n        var bKey = backfill[b].author + '|' + backfill[b].quote;\n        if (!seen.has(bKey)) {\n          seen.add(bKey);\n          deduped.push(backfill[b]);\n        }\n      }\n    }\n\n    return deduped.slice(0, 3);\n  }\n\n  function getTopSelectedLabel(route, fallback) {\n    const selected = getAnswerArray(route);\n    if (!selected.length) {\n      return fallback;\n    }\n\n    return OPTION_LABEL_LOOKUP[selected[0]] || fallback;\n  }\n\n  function getConfiguredBundleVariantIds(profileKey, mode = 'subscribe') {\n    const isSubscribe = mode === 'subscribe';\n    const primaryVariantId = isSubscribe ? VARIANT_TWO_SUBSCRIBE : VARIANT_TWO_ONETIME;\n    const secondaryVariantId = isSubscribe ? VARIANT_ONE_SUBSCRIBE : VARIANT_ONE_ONETIME;\n    const needsExtraBottle = profileKey === 'complete_calm' || profileKey === 'stress_recovery';\n    const ids = [];\n\n    if (primaryVariantId) {\n      ids.push(Number(primaryVariantId));\n    }\n    if (needsExtraBottle && secondaryVariantId) {\n      ids.push(Number(secondaryVariantId));\n    }\n\n    return Array.from(new Set(ids.filter((id) => Number.isFinite(id) && id > 0)));\n  }\n\n  function buildPersonalizationEngine(options = {}) {\n    const ingredientScores = scoreIngredients();\n    const stressBurden = computeStressBurden();\n    const quizScore = computeQuizScore();\n    const scoreInterpretation = getScoreInterpretation(quizScore);\n    const primaryIssue = detectPrimaryIssue();\n    const computedProfileKey = determineProfile(stressBurden);\n    const forcedProfileKey =\n      options.forceProfileKey && PROFILE_META[options.forceProfileKey] ? options.forceProfileKey : '';\n    const profileKey = forcedProfileKey || computedProfileKey;\n    const profileMeta = PROFILE_META[profileKey] || PROFILE_META.sleep_restoration;\n    const appliedRules = evaluateRuleIds(profileKey);\n    const safetyGate = appliedRules.includes('7C');\n    const bundleKey = options.forceBundleKey && typeof options.forceBundleKey === 'string'\n      ? options.forceBundleKey\n      : profileMeta.bundle;\n    const specialist = options.forceSpecialist && typeof options.forceSpecialist === 'string'\n      ? options.forceSpecialist\n      : profileMeta.specialist;\n    const specialistRole = getSpecialistRoleForName(specialist) || profileMeta.specialistRole;\n\n    const sortedIngredients = Object.entries(ingredientScores)\n      .sort((a, b) => b[1] - a[1])\n      .map(([key, score]) => ({\n        key,\n        score,\n        ...INGREDIENT_META[key],\n      }));\n\n    const firstName = (state.lead.firstName || '').trim();\n    const mainStressor = getTopSelectedLabel('q5', 'daily pressure');\n    const mainSymptom = getTopSelectedLabel('q7', primaryIssue.label);\n    const timeline = getTimelineForProfile(profileKey, stressBurden);\n    const testimonials = getRecommendedTestimonials(profileKey, appliedRules);\n\n    const PROFILE_HEADLINES = {\n      sleep_restoration: 'your body may just need the right form of magnesium',\n      complete_calm: 'sleep support that works with your body \\u2014 not against it',\n      stress_recovery: 'three clinical-dose ingredients, zero morning fog',\n      sleep_starter: 'clinical doses, no guesswork',\n    };\n    const profileHook = PROFILE_HEADLINES[profileKey] || `your plan for ${primaryIssue.label}`;\n    const dynamicHeadline = firstName\n      ? `${firstName}, ${profileHook}`\n      : `Your personalized protocol: ${profileHook}`;\n    const dynamicSubheadline = `Based on your answers, ${mainStressor.toLowerCase()} plus ${mainSymptom.toLowerCase()} is the main pattern affecting your rest.`;\n\n    const appliedRuleNotes = appliedRules.map((id) => ({\n      id,\n      note: RULE_COPY[id] || 'Mapped from personalization rules.',\n    }));\n    const forcedVariantIds = Array.isArray(options.forceVariantIds)\n      ? options.forceVariantIds.filter((id) => Number.isFinite(Number(id))).map((id) => Number(id))\n      : [];\n    const recommendedVariantIds = forcedVariantIds.length\n      ? Array.from(new Set(forcedVariantIds))\n      : getConfiguredBundleVariantIds(profileKey, 'subscribe');\n\n    return {\n      profileKey,\n      profileLabel: profileMeta.label,\n      bundleKey,\n      specialist,\n      specialistRole,\n      stressBurden,\n      quizScore,\n      scoreInterpretation,\n      primaryIssue,\n      ingredientScores,\n      ingredientPriority: sortedIngredients,\n      appliedRules,\n      appliedRuleNotes,\n      dynamicHeadline,\n      dynamicSubheadline,\n      safetyGate,\n      timeline,\n      testimonials,\n      recommendedVariantIds,\n    };\n  }\n\n  function getPersonalization() {\n    if (state.personalization) {\n      return state.personalization;\n    }\n\n    state.personalization = buildPersonalizationEngine();\n    return state.personalization;\n  }\n\n  function inferProfilePreview() {\n    return getPersonalization();\n  }\n\n  function buildMapCheck(personalization = getPersonalization()) {\n    const catalogRuleIds = PERSONALIZATION_RULES.map((rule) => rule.id);\n    const bundles = Array.from(new Set(PERSONALIZATION_RULES.filter((rule) => rule.bundle).map((rule) => rule.bundle)));\n    const ingredientSet = Array.from(\n      new Set(\n        PERSONALIZATION_RULES.flatMap((rule) => rule.ingredients).filter((ingredient) => ingredient !== 'safety_gate')\n      )\n    );\n\n    return {\n      sourceRuleCount: SOURCE_RULE_COUNT,\n      mappedRuleCount: catalogRuleIds.length,\n      countMismatch: catalogRuleIds.length !== SOURCE_RULE_COUNT,\n      ingredientsCovered: ingredientSet,\n      bundlesCovered: bundles,\n      appliedRuleCount: personalization.appliedRules.length,\n      appliedRules: personalization.appliedRules,\n    };\n  }\n\n  function getAllSelectedAnswerIds() {\n    const ids = [];\n\n    QUESTION_ROUTE_MAP.forEach((step) => {\n      if (step.route === 'q12') {\n        return;\n      }\n      ids.push(...getAnswerArray(step.route));\n    });\n\n    const demographics = getDemographics();\n    if (demographics.age) ids.push(demographics.age);\n    if (demographics.gender) ids.push(demographics.gender);\n    if (Array.isArray(demographics.femaleConditions)) {\n      ids.push(...demographics.femaleConditions);\n    }\n\n    return ids.filter((entry) => typeof entry === 'string');\n  }\n\n  function buildKlaviyoProperties(personalization) {\n    const demographics = getDemographics();\n\n    return {\n      first_name: state.lead.firstName,\n      evolance_quiz_q1: getAnswerArray('q1'),\n      evolance_quiz_q2: getAnswerArray('q2'),\n      evolance_quiz_q3: getAnswerArray('q3'),\n      evolance_quiz_q4: getAnswerArray('q4'),\n      evolance_quiz_q5: getAnswerArray('q5'),\n      evolance_quiz_q7: getAnswerArray('q7'),\n      evolance_quiz_q8: getAnswerArray('q8'),\n      evolance_quiz_q9: getAnswerArray('q9'),\n      evolance_quiz_q10: getAnswerArray('q10'),\n      evolance_quiz_q11: getAnswerArray('q11'),\n      evolance_quiz_q12_age: demographics.age || '',\n      evolance_quiz_q12_gender: demographics.gender || '',\n      evolance_quiz_q12_female_conditions: demographics.femaleConditions || [],\n      evolance_recommended_bundle: personalization.bundleKey,\n      evolance_recommended_bundle_variant_ids: personalization.recommendedVariantIds || [],\n      evolance_profile: personalization.profileLabel,\n      evolance_primary_issue: personalization.primaryIssue.label,\n      evolance_applied_rules: personalization.appliedRules,\n      evolance_quiz_answer_ids: getAllSelectedAnswerIds(),\n      evolance_opt_in: Boolean(state.lead.optIn),\n      quiz_completed_at: new Date().toISOString(),\n    };\n  }\n\n  async function postKlaviyoClientSubscription(properties) {\n    if (!KLAVIYO_PUBLIC_KEY || !KLAVIYO_LIST_ID || !state.lead.email) {\n      return false;\n    }\n\n    const payload = {\n      data: {\n        type: 'subscription',\n        attributes: {\n          custom_source: 'Evolance Quiz',\n          profile: {\n            data: {\n              type: 'profile',\n              attributes: {\n                email: state.lead.email,\n                first_name: state.lead.firstName,\n                properties,\n              },\n            },\n          },\n        },\n        relationships: {\n          list: {\n            data: {\n              type: 'list',\n              id: KLAVIYO_LIST_ID,\n            },\n          },\n        },\n      },\n    };\n\n    const response = await fetch(\n      `https://a.klaviyo.com/client/subscriptions/?company_id=${encodeURIComponent(KLAVIYO_PUBLIC_KEY)}`,\n      {\n        method: 'POST',\n        headers: {\n          'Content-Type': 'application/json',\n          revision: '2025-01-15',\n        },\n        body: JSON.stringify(payload),\n      }\n    );\n\n    return response.ok;\n  }\n\n  async function postKlaviyoLegacySubscription(properties) {\n    if (!KLAVIYO_PUBLIC_KEY || !KLAVIYO_LIST_ID || !state.lead.email) {\n      return false;\n    }\n\n    const response = await fetch(`https://a.klaviyo.com/api/v2/list/${encodeURIComponent(KLAVIYO_LIST_ID)}/subscribe`, {\n      method: 'POST',\n      headers: {\n        'Content-Type': 'application/json',\n      },\n      body: JSON.stringify({\n        api_key: KLAVIYO_PUBLIC_KEY,\n        profiles: [\n          {\n            email: state.lead.email,\n            ...properties,\n          },\n        ],\n      }),\n    });\n\n    return response.ok;\n  }\n\n  async function syncLeadCapture() {\n    hydrateLeadFromCustomer();\n    if (!state.lead.email) {\n      return false;\n    }\n\n    const personalization = getPersonalization();\n    const properties = buildKlaviyoProperties(personalization);\n\n    let synced = false;\n\n    try {\n      synced = await postKlaviyoClientSubscription(properties);\n    } catch (error) {\n      synced = false;\n    }\n\n    if (!synced) {\n      try {\n        synced = await postKlaviyoLegacySubscription(properties);\n      } catch (error) {\n        synced = false;\n      }\n    }\n\n    if (window._learnq && typeof window._learnq.push === 'function') {\n      window._learnq.push([\n        'identify',\n        {\n          $email: state.lead.email,\n          $first_name: state.lead.firstName,\n          ...properties,\n        },\n      ]);\n\n      window._learnq.push([\n        'track',\n        'Evolance Quiz Completed',\n        {\n          list_id: KLAVIYO_LIST_ID,\n          evolance_recommended_bundle: personalization.bundleKey,\n        },\n      ]);\n    }\n\n    return synced;\n  }\n\n  function buildCustomerMetafieldPayload(personalization) {\n    const answers = serializeAnswersForStorage();\n    const quizDate = new Date().toISOString().slice(0, 10);\n    const bundleIds = normalizeBundleIds(personalization.recommendedVariantIds || []);\n    const metafields = {\n      profile_type: personalization.profileKey,\n      bundle_ids: bundleIds,\n      specialist_name: personalization.specialist,\n      last_quiz_date: quizDate,\n    };\n\n    return {\n      customer_id: state.customer.id || null,\n      answers,\n      personalization,\n      namespace: 'evolance',\n      metafields,\n      metafields_list: [\n        {\n          namespace: 'evolance',\n          key: 'profile_type',\n          type: 'single_line_text_field',\n          value: metafields.profile_type,\n        },\n        {\n          namespace: 'evolance',\n          key: 'bundle_ids',\n          type: 'list.single_line_text_field',\n          value: JSON.stringify(metafields.bundle_ids),\n        },\n        {\n          namespace: 'evolance',\n          key: 'specialist_name',\n          type: 'single_line_text_field',\n          value: metafields.specialist_name,\n        },\n        {\n          namespace: 'evolance',\n          key: 'last_quiz_date',\n          type: 'date',\n          value: metafields.last_quiz_date,\n        },\n      ],\n    };\n  }\n\n  async function syncCustomerMetafields(personalization = getPersonalization()) {\n    const pendingSnapshot = loadPendingAuthSnapshot();\n    const endpointFromPending =\n      pendingSnapshot && typeof pendingSnapshot.metafieldSyncEndpoint === 'string'\n        ? pendingSnapshot.metafieldSyncEndpoint\n        : '';\n    const endpointValue = (METAFIELD_SYNC_ENDPOINT || endpointFromPending || '').trim();\n\n    if (!state.customer.loggedIn || !endpointValue) {\n      return false;\n    }\n\n    state.metafieldSync.attempted = true;\n\n    const endpointUrl = new URL(endpointValue, window.location.origin).toString();\n    const response = await fetch(endpointUrl, {\n      method: 'POST',\n      credentials: 'same-origin',\n      headers: {\n        'Content-Type': 'application/json',\n      },\n      body: JSON.stringify(buildCustomerMetafieldPayload(personalization)),\n    });\n\n    if (!response.ok) {\n      state.metafieldSync.synced = false;\n      return false;\n    }\n\n    const bundleIds = normalizeBundleIds(personalization.recommendedVariantIds || []);\n    state.customer.metafields.profileType = personalization.profileKey;\n    state.customer.metafields.bundleIds = JSON.stringify(bundleIds);\n    state.customer.metafields.specialistName = personalization.specialist;\n    state.customer.metafields.lastQuizDate = new Date().toISOString().slice(0, 10);\n    state.customer.metafields.quizProfile = personalization.profileLabel;\n    state.customer.metafields.recommendedBundle = state.customer.metafields.bundleIds;\n    state.customer.metafields.assignedSpecialist = personalization.specialist;\n    state.metafieldSync.synced = true;\n    return true;\n  }\n\n  function getRecommendationsUrl() {\n    return RECOMMENDATIONS_PATH || '/pages/recommendations';\n  }\n\n  function buildAccountLoginUrl(options = {}) {\n    const returnPath = getRecommendationsUrl();\n    const loginPath = `${getStoreRootPath()}customer_authentication/login`;\n    const loginUrl = new URL(loginPath, window.location.origin);\n    loginUrl.searchParams.set('return_to', returnPath);\n\n    if (options.identityProvider) {\n      loginUrl.searchParams.set('identity_provider', options.identityProvider);\n    }\n    if (options.source) {\n      loginUrl.searchParams.set('source', options.source);\n    }\n    if (options.loginHint) {\n      loginUrl.searchParams.set('login_hint', options.loginHint);\n    }\n\n    return loginUrl.toString();\n  }\n\n  function getEmailLoginUrl() {\n    const email = (state.lead.email || '').trim();\n    return buildAccountLoginUrl({\n      source: 'evolance_quiz_email',\n      loginHint: email && email.includes('@') ? email : '',\n    });\n  }\n\n  function getRecommendationsDataEndpoint() {\n    const rawEndpoint = (METAFIELD_SYNC_ENDPOINT || '/apps/evolance-api/quiz-sync').trim();\n\n    try {\n      const url = new URL(rawEndpoint, window.location.origin);\n      const normalizedPath = url.pathname.replace(/\\/+$/, '');\n      const basePath = normalizedPath.replace(/\\/quiz-sync$/i, '');\n      return `${basePath || '/apps/evolance-api'}/recommendations`;\n    } catch (error) {\n      return '/apps/evolance-api/recommendations';\n    }\n  }\n\n  async function loadRecommendationsFromProxy() {\n    if (!isRecommendationsMode || !state.customer.loggedIn) {\n      return false;\n    }\n\n    try {\n      const response = await fetch(getRecommendationsDataEndpoint(), {\n        method: 'GET',\n        credentials: 'same-origin',\n        headers: {\n          Accept: 'application/json',\n        },\n      });\n\n      if (!response.ok) {\n        return false;\n      }\n\n      const payload = await response.json().catch(() => null);\n      if (!payload || payload.ok !== true) {\n        return false;\n      }\n\n      const customer = payload.customer && typeof payload.customer === 'object' ? payload.customer : {};\n      const metafields = payload.metafields && typeof payload.metafields === 'object' ? payload.metafields : {};\n      const bundleIds = Array.isArray(metafields.bundle_ids)\n        ? metafields.bundle_ids\n        : typeof metafields.bundle_ids === 'string' && metafields.bundle_ids.trim()\n          ? [metafields.bundle_ids.trim()]\n          : [];\n      const quizAnswersRaw =\n        typeof metafields.quiz_answers === 'string'\n          ? metafields.quiz_answers\n          : metafields.quiz_answers && typeof metafields.quiz_answers === 'object'\n            ? JSON.stringify(metafields.quiz_answers)\n            : '';\n\n      if (typeof customer.first_name === 'string' && customer.first_name.trim()) {\n        state.customer.firstName = customer.first_name.trim();\n      }\n      if (typeof customer.email === 'string' && customer.email.trim()) {\n        state.customer.email = customer.email.trim();\n      }\n\n      if (typeof metafields.profile_type === 'string') {\n        state.customer.metafields.profileType = metafields.profile_type;\n        state.customer.metafields.quizProfile = metafields.profile_type;\n      }\n      if (bundleIds.length) {\n        const serializedBundleIds = JSON.stringify(bundleIds);\n        state.customer.metafields.bundleIds = serializedBundleIds;\n        state.customer.metafields.recommendedBundle = serializedBundleIds;\n      }\n      if (typeof metafields.specialist_name === 'string') {\n        state.customer.metafields.specialistName = metafields.specialist_name;\n        state.customer.metafields.assignedSpecialist = metafields.specialist_name;\n      }\n      if (typeof metafields.last_quiz_date === 'string') {\n        state.customer.metafields.lastQuizDate = metafields.last_quiz_date;\n      }\n      if (quizAnswersRaw) {\n        state.customer.metafields.quizAnswers = quizAnswersRaw;\n      }\n\n      state.customer.prefillState = {\n        profile_type: state.customer.metafields.profileType || '',\n        bundle_ids: state.customer.metafields.bundleIds || '',\n        specialist_name: state.customer.metafields.specialistName || '',\n        last_quiz_date: state.customer.metafields.lastQuizDate || '',\n        quiz_answers: state.customer.metafields.quizAnswers || '',\n      };\n\n      hydrateLeadFromCustomer();\n      return true;\n    } catch (error) {\n      return false;\n    }\n  }\n\n  function getGoogleAuthUrl() {\n    const email = (state.lead.email || '').trim();\n    return buildAccountLoginUrl({\n      identityProvider: 'google',\n      source: 'evolance_quiz_google',\n      loginHint: email && email.includes('@') ? email : '',\n    });\n  }\n\n  async function handleGoogleContinue() {\n    if (state.submitting) {\n      return;\n    }\n\n    queueTrackEvent('AUTH_STARTED', {\n      route: 'email',\n      metadata: {\n        provider: 'google',\n      },\n    });\n\n    state.submitting = true;\n    syncNavState();\n\n    try {\n      const personalization = getPersonalization();\n      persistSessionSnapshot(personalization);\n      persistPendingAuthSnapshot('google');\n      await syncQuizCompletion({\n        personalization,\n        metadata: {\n          provider: 'google',\n        },\n      });\n      if (state.lead.email && state.lead.email.includes('@')) {\n        await syncLeadCapture();\n      }\n    } finally {\n      state.submitting = false;\n      syncNavState();\n    }\n\n    window.location.href = getGoogleAuthUrl();\n  }\n\n  async function syncAuthenticatedResults() {\n    if (!state.customer.loggedIn) {\n      return false;\n    }\n\n    if (!state.personalization) {\n      const hydrated =\n        hydrateStateFromPendingAuthSnapshot() ||\n        hydrateStateFromSessionSnapshot() ||\n        hydrateStateFromCustomerMetafields();\n\n      if (!hydrated && !hasCollectedQuizData()) {\n        return false;\n      }\n\n      if (!state.personalization && hasCollectedQuizData()) {\n        state.personalization = buildPersonalizationEngine();\n      }\n    }\n\n    if (!state.personalization) {\n      return false;\n    }\n\n    const personalization = getPersonalization();\n    persistSessionSnapshot(personalization);\n    await syncLeadCapture();\n    try {\n      await syncCustomerMetafields(personalization);\n    } catch (error) {\n      // Ignore sync transport failures; rendering should continue.\n    }\n\n    /* Re-sync with backend now that we have the customer email.\n       Pre-auth call may have generated a discount code but without email,\n       so Klaviyo sync was skipped. The backend is idempotent for discount\n       codes (won't duplicate) but will now run Klaviyo sync with the email. */\n    try {\n      await syncQuizCompletion({\n        personalization,\n        metadata: { flow: 'post_auth_sync' },\n      });\n      if (state.personalDiscountCode) {\n        persistSessionSnapshot(personalization);\n      }\n    } catch (_) {\n      // Non-critical \u2014 continue without sync.\n    }\n\n    return true;\n  }\n\n  function getCountdownSnapshot() {\n    if (!state.timer.expiresAt) {\n      return {\n        expired: false,\n        minutes: 60,\n        seconds: 0,\n      };\n    }\n\n    const remainingMs = state.timer.expiresAt - Date.now();\n    if (remainingMs <= 0) {\n      return {\n        expired: true,\n        minutes: 0,\n        seconds: 0,\n      };\n    }\n\n    const totalSeconds = Math.floor(remainingMs / 1000);\n    return {\n      expired: false,\n      minutes: Math.floor(totalSeconds / 60),\n      seconds: totalSeconds % 60,\n    };\n  }\n\n  function normalizeDiscountCode(rawValue) {\n    const normalized = String(rawValue || '')\n      .trim()\n      .toUpperCase()\n      .replace(/[^A-Z0-9_-]/g, '');\n\n    return normalized;\n  }\n\n  function isDiscountCodeInputValid(rawValue) {\n    const trimmed = String(rawValue || '').trim();\n    if (!trimmed) {\n      return true;\n    }\n\n    return /^[A-Z0-9_-]{2,32}$/i.test(trimmed);\n  }\n\n  function setManualDiscountCode(rawValue, options = {}) {\n    const normalized = normalizeDiscountCode(rawValue);\n    const parsedPercent = Number(options.discountPercent);\n    state.manualDiscountCode = normalized;\n    state.manualDiscountPercent =\n      Number.isFinite(parsedPercent) && parsedPercent > 0 && parsedPercent < 100 ? parsedPercent : null;\n  }\n\n  function getActiveDiscountCode() {\n    if (state.manualDiscountCode) {\n      return state.manualDiscountCode;\n    }\n    return state.personalDiscountCode || '';\n  }\n\n  function parsePromoAllowlistCodes(rawValue) {\n    const values = new Set();\n    const emptySentinel = '__EMPTY__';\n    String(rawValue || '')\n      .split(',')\n      .map((entry) => normalizeDiscountCode(entry))\n      .forEach((entry) => {\n        if (entry && entry !== emptySentinel) {\n          values.add(entry);\n        }\n      });\n    return values;\n  }\n\n  async function validateDiscountCode(rawValue, options = {}) {\n    const normalized = normalizeDiscountCode(rawValue);\n    const fallbackInvalidMessage =\n      String(options.invalidText || 'Enter a valid code using letters, numbers, dash, or underscore.').trim() ||\n      'Enter a valid code using letters, numbers, dash, or underscore.';\n    const fallbackUnavailableMessage =\n      String(options.unavailableText || 'We could not validate this code right now. Please try again.').trim() ||\n      fallbackInvalidMessage;\n    const allowlist = options.allowlist instanceof Set ? options.allowlist : new Set();\n\n    if (!normalized) {\n      return {\n        valid: false,\n        normalizedCode: '',\n        message: fallbackInvalidMessage,\n        discountPercent: null,\n      };\n    }\n\n    if (PROMO_VALIDATION_ENDPOINT) {\n      try {\n        const endpointUrl = new URL(PROMO_VALIDATION_ENDPOINT, window.location.origin).toString();\n        const response = await fetch(endpointUrl, {\n          method: 'POST',\n          credentials: 'same-origin',\n          headers: {\n            'Content-Type': 'application/json',\n          },\n          body: JSON.stringify({\n            code: normalized,\n            context: 'recommendations',\n          }),\n        });\n\n        if (response.ok) {\n          const payload = await response.json();\n          if (payload && typeof payload === 'object') {\n            const valid = Boolean(payload.valid);\n            const normalizedCode = normalizeDiscountCode(payload.normalizedCode || normalized);\n            const message = String(payload.message || '').trim();\n            const parsedPercent = Number(payload.discountPercent);\n            const discountPercent =\n              Number.isFinite(parsedPercent) && parsedPercent > 0 && parsedPercent < 100 ? parsedPercent : null;\n            if (valid && normalizedCode) {\n              return {\n                valid: true,\n                normalizedCode,\n                message,\n                discountPercent,\n              };\n            }\n            return {\n              valid: false,\n              normalizedCode: '',\n              message: message || fallbackInvalidMessage,\n              discountPercent: null,\n            };\n          }\n        }\n      } catch (error) {\n        // Ignore endpoint transport failures and continue with local fallback.\n      }\n    }\n\n    if (allowlist.has(normalized)) {\n      return {\n        valid: true,\n        normalizedCode: normalized,\n        message: '',\n        discountPercent: null,\n      };\n    }\n\n    return {\n      valid: false,\n      normalizedCode: '',\n      message: PROMO_VALIDATION_ENDPOINT ? fallbackUnavailableMessage : fallbackInvalidMessage,\n      discountPercent: null,\n    };\n  }\n\n  function renderTimerNodes() {\n    const snapshot = getCountdownSnapshot();\n    const clock = `${String(snapshot.minutes).padStart(2, '0')}:${String(snapshot.seconds).padStart(2, '0')}`;\n    const isExpiredText = snapshot.expired ? 'Expired' : 'Active';\n    const code = getActiveDiscountCode();\n    const showAppliedState = snapshot.expired;\n\n    const mins = String(snapshot.minutes).padStart(2, '0');\n    const secs = String(snapshot.seconds).padStart(2, '0');\n    state.timer.nodes.forEach((node) => {\n      const minEl = node.querySelector('[data-evr-timer-min]');\n      const secEl = node.querySelector('[data-evr-timer-sec]');\n      if (minEl && secEl) {\n        minEl.textContent = mins;\n        secEl.textContent = secs;\n      } else {\n        node.textContent = clock;\n      }\n    });\n    state.timer.expiredNodes.forEach((node) => {\n      node.textContent = isExpiredText;\n    });\n    state.timer.codeNodes.forEach((node) => {\n      node.textContent = code;\n    });\n    state.timer.shellNodes.forEach((node) => {\n      node.classList.toggle('evr-hidden', showAppliedState);\n      if (showAppliedState) {\n        node.setAttribute('hidden', 'hidden');\n      } else {\n        node.removeAttribute('hidden');\n      }\n    });\n    state.timer.appliedNodes.forEach((node) => {\n      node.classList.toggle('evr-hidden', !showAppliedState);\n      if (showAppliedState) {\n        node.removeAttribute('hidden');\n      } else {\n        node.setAttribute('hidden', 'hidden');\n      }\n    });\n\n    if (state.currentRoute === 'results') {\n      syncNavState();\n    }\n  }\n\n  function stopResultsTimer() {\n    if (state.timer.intervalId) {\n      window.clearInterval(state.timer.intervalId);\n      state.timer.intervalId = null;\n    }\n  }\n\n  function startResultsTimer() {\n    let persistedStart = null;\n    try {\n      persistedStart = window.sessionStorage.getItem(TIMER_STORAGE_KEY);\n    } catch (error) {\n      persistedStart = null;\n    }\n    const nowIso = new Date().toISOString();\n    const startedAt = persistedStart || nowIso;\n\n    if (!persistedStart) {\n      try {\n        window.sessionStorage.setItem(TIMER_STORAGE_KEY, nowIso);\n      } catch (error) {\n        // Ignore storage write failures.\n      }\n    }\n\n    state.timer.startedAt = startedAt;\n    state.timer.expiresAt = new Date(startedAt).getTime() + 60 * 60 * 1000;\n\n    stopResultsTimer();\n    renderTimerNodes();\n\n    state.timer.intervalId = window.setInterval(() => {\n      renderTimerNodes();\n    }, 1000);\n  }\n\n  async function loadFallbackVariantId() {\n    if (state.variantFallbackId !== undefined) {\n      return state.variantFallbackId;\n    }\n\n    try {\n      const payload = await loadCadenceProduct();\n      if (!payload || !Array.isArray(payload.variants) || !payload.variants.length) {\n        state.variantFallbackId = null;\n        return state.variantFallbackId;\n      }\n\n      const firstVariant = payload && payload.variants && payload.variants[0];\n      state.variantFallbackId = firstVariant && firstVariant.id ? Number(firstVariant.id) : null;\n      return state.variantFallbackId;\n    } catch (error) {\n      state.variantFallbackId = null;\n      return state.variantFallbackId;\n    }\n  }\n\n  function resolveCartItems(profileKey, fallbackVariantId, options = {}) {\n    return buildDefaultBundleLineItems(profileKey, fallbackVariantId, {\n      mode: options.mode || state.purchaseMode,\n      recommendedVariantIds: options.recommendedVariantIds || [],\n    });\n  }\n\n  async function handleCartRedirection(personalization, options = {}) {\n    const code = getActiveDiscountCode();\n    const discountUrl = code\n      ? `/discount/${encodeURIComponent(code)}?redirect=/checkout`\n      : '/checkout';\n    const fallbackVariantId = await loadFallbackVariantId();\n    const requestedItems = normalizeCartItems(options.items);\n    const stateItems = normalizeCartItems(state.resultsLineItems);\n    const cartItems =\n      requestedItems.length > 0\n        ? requestedItems\n        : stateItems.length > 0\n          ? stateItems\n          : resolveCartItems(personalization.profileKey, fallbackVariantId, {\n              recommendedVariantIds: personalization.recommendedVariantIds || [],\n            });\n\n    /* Attach selling_plan to product items in subscribe mode (per-plan Seal selling plan IDs) */\n    if (state.purchaseMode === 'subscribe') {\n      let planSellingPlanId = SELLING_PLAN_ID;\n      /* Resolve per-plan selling plan ID from the active plan card DOM node */\n      /* Plan cards live in sibling section (reco-v2-core), not inside quiz-app root */\n      const activePlanCard = document.querySelector(\n        `[data-evr-plan-card][data-plan-key=\"${CSS.escape(state.selectedPlanKey || '')}\"]`\n      );\n      if (activePlanCard) {\n        const cardSpId = activePlanCard.getAttribute('data-plan-selling-plan-id');\n        if (cardSpId) planSellingPlanId = Number(cardSpId);\n      }\n      if (planSellingPlanId) {\n        cartItems.forEach((item) => {\n          if (item.id !== EBOOK_VARIANT_ID) {\n            item.selling_plan = planSellingPlanId;\n          }\n        });\n      }\n    }\n\n    /* Auto-add free eBook with every purchase (matches mv5-bundles behavior) */\n    if (EBOOK_VARIANT_ID && !cartItems.some((item) => item.id === EBOOK_VARIANT_ID)) {\n      cartItems.push({ id: EBOOK_VARIANT_ID, quantity: 1 });\n    }\n\n    state.cartBusy = true;\n    syncNavState();\n\n    try {\n      if (cartItems.length) {\n        await fetch('/cart/clear.js', {\n          method: 'POST',\n          headers: { 'Content-Type': 'application/json' },\n        });\n        await fetch('/cart/add.js', {\n          method: 'POST',\n          headers: {\n            'Content-Type': 'application/json',\n          },\n          body: JSON.stringify({ items: cartItems }),\n        });\n      }\n      /* Apply discount code to cart session (works with Shopify's new checkout) */\n      if (code) {\n        await fetch('/cart/update.js', {\n          method: 'POST',\n          headers: { 'Content-Type': 'application/json' },\n          body: JSON.stringify({ discount: code }),\n        });\n      }\n    } catch (error) {\n      // Ignore and continue to checkout redirect.\n    } finally {\n      state.cartBusy = false;\n      syncNavState();\n    }\n\n    window.location.href = '/checkout';\n  }\n\n  function renderExternalRecommendationsStep() {\n    const personalization = inferProfilePreview();\n    const isV3Layout = shouldUseExternalRecommendationsV3Layout();\n    const isV2Layout = !isV3Layout && shouldUseExternalRecommendationsV2Layout();\n    persistSessionSnapshot(personalization);\n\n    state.timer.nodes = [];\n    state.timer.expiredNodes = [];\n    state.timer.codeNodes = [];\n    state.timer.shellNodes = [];\n    state.timer.appliedNodes = [];\n\n    const timerClockNodes = Array.from(document.querySelectorAll('[data-evr-timer-clock]'));\n    const timerStateNodes = Array.from(document.querySelectorAll('[data-evr-timer-state]'));\n    const timerCodeNodes = Array.from(document.querySelectorAll('[data-evr-timer-code]'));\n    const timerShellNodes = Array.from(document.querySelectorAll('[data-evr-timer-shell]'));\n    const timerAppliedNodes = Array.from(document.querySelectorAll('[data-evr-timer-applied]'));\n    const summaryCodeNodes = Array.from(document.querySelectorAll('[data-evr-summary-code]'));\n    state.timer.nodes.push(...timerClockNodes);\n    state.timer.expiredNodes.push(...timerStateNodes);\n    state.timer.codeNodes.push(...timerCodeNodes, ...summaryCodeNodes);\n    state.timer.shellNodes.push(...timerShellNodes);\n    state.timer.appliedNodes.push(...timerAppliedNodes);\n\n    const firstName = (state.lead.firstName || state.customer.firstName || '').trim();\n    document.querySelectorAll('[data-evr-first-name]').forEach((node) => {\n      const fallback = String(node.getAttribute('data-fallback') || 'there').trim() || 'there';\n      node.textContent = firstName || fallback;\n    });\n\n    setTextForNodes('[data-evr-specialist-name]', personalization.specialist || '');\n    setTextForNodes('[data-evr-specialist-role]', personalization.specialistRole || '');\n    setTextForNodes(\n      '[data-evr-primary-issue]',\n      (personalization.primaryIssue && personalization.primaryIssue.label) || ''\n    );\n    setTextForNodes(\n      '[data-evr-top-ingredients]',\n      personalization.ingredientPriority.slice(0, 2).map((item) => item.label).join(' + ')\n    );\n    applyV2ProfileOverrides(personalization);\n    syncExternalSafetySections(Boolean(personalization.safetyGate));\n\n    var isV4Layout = shouldUseV4Layout();\n\n    if (isV4Layout) {\n      document.body.classList.add('evr-v4-active');\n      hydrateV4DiagnosticCard(personalization);\n      hydrateV4MechanismBridge(personalization);\n      hydrateV4CouponBanner();\n      hydrateV4PurchaseEnhancements(personalization);\n      hydrateV4Report(personalization);\n      initV4ReportPopup();\n      initV4ScrollToPurchase();\n    } else if (isV3Layout) {\n      hydrateV3Diagnosis(personalization);\n      hydrateV3Findings(personalization);\n      hydrateV3Mechanism(personalization);\n      hydrateV3Strengths(personalization);\n      hydrateV3Prescription(personalization);\n      hydrateV3Proof(personalization);\n      hydrateV3Journey(personalization);\n    } else {\n      hydrateV2ScoreReveal(personalization);\n      hydrateV2MechanismSection(personalization);\n      hydrateV2PrescriptionSection(personalization);\n      hydrateV2SocialProofSection(personalization);\n      applyV2FocusSummary(personalization);\n    }\n\n    const timelineStepsContainer = document.querySelector('[data-evr-timeline-steps]');\n    const timelineTitleNode = document.querySelector('[data-evr-timeline-title]');\n    const timelineBodyNode = document.querySelector('[data-evr-timeline-body]');\n    if (timelineStepsContainer && Array.isArray(personalization.timeline) && personalization.timeline.length) {\n      clearElement(timelineStepsContainer);\n\n      const setActiveTimeline = (timelineId) => {\n        timelineStepsContainer.querySelectorAll('[data-timeline-id]').forEach((button) => {\n          const isActive = button.dataset.timelineId === timelineId;\n          button.classList.toggle('is-active', isActive);\n        });\n\n        const activeStep =\n          personalization.timeline.find((step) => step.id === timelineId) || personalization.timeline[0];\n        if (timelineTitleNode) {\n          timelineTitleNode.textContent = activeStep.title;\n        }\n        if (timelineBodyNode) {\n          timelineBodyNode.textContent = activeStep.body;\n        }\n      };\n\n      personalization.timeline.forEach((step, index) => {\n        const stepButton = document.createElement('button');\n        stepButton.type = 'button';\n        stepButton.className = `evq-results__timeline-step ${index === 0 ? 'is-active' : ''}`;\n        stepButton.dataset.timelineId = step.id;\n        stepButton.textContent = step.label;\n        stepButton.addEventListener('click', () => setActiveTimeline(step.id));\n        timelineStepsContainer.appendChild(stepButton);\n      });\n\n      setActiveTimeline(personalization.timeline[0].id);\n    }\n\n    const testimonialsContainer = document.querySelector('[data-evr-testimonials]');\n    if (testimonialsContainer) {\n      clearElement(testimonialsContainer);\n\n      personalization.testimonials.forEach((entry) => {\n        const block = document.createElement('blockquote');\n        block.className = 'evq-results__testimonial';\n        block.innerHTML = `<p>\"${escapeHtml(entry.quote)}\"</p><footer>${escapeHtml(entry.author)} \u00B7 ${escapeHtml(\n          entry.context\n        )}</footer>`;\n        testimonialsContainer.appendChild(block);\n      });\n    }\n\n    const isSafetyMode = Boolean(personalization.safetyGate);\n    const planRootNode = document.querySelector('[data-evr-plan-root]');\n    const purchaseTypeButtons = Array.from(document.querySelectorAll('[data-evr-purchase-type]'));\n    const planCards = Array.from(document.querySelectorAll('[data-evr-plan-card]'));\n    const purchaseNoteNodes = Array.from(document.querySelectorAll('[data-evr-purchase-note]'));\n    const activeShippingNoteNodes = Array.from(document.querySelectorAll('[data-evr-active-shipping-note]'));\n    const upgradeToggleButtons = Array.from(document.querySelectorAll('[data-evr-upgrade-toggle]'));\n    const offerCopyNodes = Array.from(document.querySelectorAll('[data-evr-offer-copy]'));\n\n    const parsePlanCents = (rawValue) => {\n      const value = String(rawValue == null ? '' : rawValue).trim();\n      if (!value) {\n        return 0;\n      }\n\n      if (/^-?\\d+$/.test(value)) {\n        const parsedInteger = Number(value);\n        return Number.isFinite(parsedInteger) ? Math.round(parsedInteger) : 0;\n      }\n\n      return parsePriceToCents(value);\n    };\n\n    const subscribeDiscountPercentRaw = Number(\n      planRootNode && planRootNode.getAttribute('data-subscribe-discount-percent')\n    );\n    const subscribeDiscountPercent =\n      Number.isFinite(subscribeDiscountPercentRaw) && subscribeDiscountPercentRaw > 0\n        ? Math.min(95, Math.round(subscribeDiscountPercentRaw))\n        : 20;\n    const subscribeShippingLabel =\n      String((planRootNode && planRootNode.getAttribute('data-subscribe-shipping-label')) || '').trim() || 'FREE';\n\n    function parsePlanCard(cardNode) {\n      const quantity = Math.max(1, Math.floor(Number(cardNode.getAttribute('data-plan-quantity') || '1') || 1));\n      const days = Math.max(\n        1,\n        Math.floor(Number(cardNode.getAttribute('data-plan-days') || String(quantity * 30)) || quantity * 30)\n      );\n      const onetimeTotalCents = Math.max(\n        0,\n        parsePlanCents(cardNode.getAttribute('data-plan-onetime-total-cents') || '0')\n      );\n      const compareCents = Math.max(\n        onetimeTotalCents,\n        parsePlanCents(cardNode.getAttribute('data-plan-compare-cents') || '0')\n      );\n      const baseTotalCentsRaw = parsePlanCents(cardNode.getAttribute('data-plan-base-total-cents') || '0');\n      const baseTotalCents = baseTotalCentsRaw > 0 ? baseTotalCentsRaw : onetimeTotalCents;\n      const planSubscribeDiscountRaw = Number(cardNode.getAttribute('data-plan-subscribe-discount-percent') || '');\n      const planSubscribeDiscountPercent =\n        Number.isFinite(planSubscribeDiscountRaw) && planSubscribeDiscountRaw > 0\n          ? Math.min(95, Math.round(planSubscribeDiscountRaw))\n          : 0;\n      const planSellingPlanId = String(cardNode.getAttribute('data-plan-selling-plan-id') || '').trim();\n      return {\n        key: String(cardNode.getAttribute('data-plan-key') || '').trim(),\n        title: String(cardNode.getAttribute('data-plan-title') || '').trim(),\n        subtitle: String(cardNode.getAttribute('data-plan-subtitle') || '').trim(),\n        quantity,\n        days,\n        onetimeTotalCents,\n        compareCents,\n        baseTotalCents,\n        planSubscribeDiscountPercent,\n        sellingPlanId: planSellingPlanId ? Number(planSellingPlanId) : null,\n        onetimeShippingLabel:\n          String(cardNode.getAttribute('data-plan-onetime-shipping-label') || '').trim() || 'FREE',\n        subscribeShippingLabel: String(cardNode.getAttribute('data-plan-subscribe-shipping-label') || '').trim(),\n        hiddenByDefault: String(cardNode.getAttribute('data-plan-hidden') || '').toLowerCase() === 'true',\n        isDefault: String(cardNode.getAttribute('data-plan-default') || '').toLowerCase() === 'true',\n      };\n    }\n\n    const plans = planCards\n      .map((cardNode) => ({\n        cardNode,\n        plan: parsePlanCard(cardNode),\n      }))\n      .filter((entry) => entry.plan.key);\n\n    const getRecommendedPlanKeyForPersonalization = () => {\n      const profileKey = normalizeV2ProfileKey(personalization && personalization.profileKey);\n      const stressBurdenRaw = Number(personalization && personalization.stressBurden);\n      const stressBurden = Number.isFinite(stressBurdenRaw) ? stressBurdenRaw : 0;\n\n      if (profileKey === 'stress_recovery' || stressBurden >= 11) {\n        return 'best_value_6';\n      }\n      if (profileKey === 'complete_calm' && stressBurden >= 8) {\n        return 'best_value_6';\n      }\n      /* Titan Decoy Effect: 3-bottle is always the recommended middle option.\n         Sleep starter with low stress still gets 3-pack as default \u2014\n         1-bottle is available but not pre-selected. */\n      return 'recommended_3';\n    };\n\n    const profileRecommendedPlanKey = getRecommendedPlanKeyForPersonalization();\n    const defaultPlanEntry = plans.find((entry) => entry.plan.isDefault) || plans[0] || null;\n    const recommendedPlanEntry =\n      plans.find((entry) => entry.plan.key === profileRecommendedPlanKey) || defaultPlanEntry || plans[0] || null;\n    const recommendedPlanKey = recommendedPlanEntry ? recommendedPlanEntry.plan.key : '';\n    const planSelectionInitialized =\n      planRootNode && planRootNode.getAttribute('data-evr-plan-selection-initialized') === 'true';\n    const shouldAutoApplyRecommendedPlan = !planSelectionInitialized;\n    if (shouldAutoApplyRecommendedPlan && recommendedPlanKey) {\n      state.selectedPlanKey = recommendedPlanKey;\n    }\n    if (!plans.some((entry) => entry.plan.key === state.selectedPlanKey) && recommendedPlanEntry) {\n      state.selectedPlanKey = recommendedPlanEntry.plan.key;\n    }\n    if (planRootNode && !planSelectionInitialized) {\n      planRootNode.setAttribute('data-evr-plan-selection-initialized', 'true');\n    }\n    if (state.purchaseMode !== 'onetime' && state.purchaseMode !== 'subscribe') {\n      state.purchaseMode = 'subscribe';\n    }\n\n    const getActivePlanEntry = () => {\n      const current = plans.find((entry) => entry.plan.key === state.selectedPlanKey);\n      return current || recommendedPlanEntry || defaultPlanEntry;\n    };\n\n    const isCompactPlanOptionsViewport = () => window.matchMedia('(max-width: 767px)').matches;\n\n    const isPlanCompressionEnabled = () =>\n      upgradeToggleButtons.length > 0 && plans.length > 1;\n\n    const isMobilePlanCompressionEnabled = () => isPlanCompressionEnabled();\n\n    const formatPlanSelectionLabel = (plan) => {\n      if (!plan) {\n        return '\u2014';\n      }\n      const qty = Math.max(1, Number(plan.quantity) || 1);\n      const unit = qty === 1 ? 'bottle' : 'bottles';\n      const subtitle = plan.subtitle || `${qty * 30} days`;\n      return `${qty} ${unit} \u00B7 ${subtitle}`;\n    };\n\n    const getVariantIdForMode = (mode, fallbackVariantId) => {\n      const candidates =\n        mode === 'subscribe'\n          ? [VARIANT_ONE_SUBSCRIBE, VARIANT_TWO_SUBSCRIBE, fallbackVariantId]\n          : [VARIANT_ONE_ONETIME, VARIANT_TWO_ONETIME, fallbackVariantId];\n\n      for (let index = 0; index < candidates.length; index += 1) {\n        const parsed = Number(candidates[index]);\n        if (Number.isFinite(parsed) && parsed > 0) {\n          return parsed;\n        }\n      }\n      return null;\n    };\n\n    const PLAN_VARIANT_KEYWORDS = {\n      starter_1: '1 bottle',\n      recommended_3: '3 bottle',\n      best_value_6: '6 bottle',\n    };\n\n    const resolveVariantForPlan = (planKey) => {\n      const product = state.cadenceProduct;\n      if (!product || !Array.isArray(product.variants)) return null;\n      const keyword = PLAN_VARIANT_KEYWORDS[planKey];\n      if (!keyword) return null;\n      return product.variants.find((v) => (v.title || '').toLowerCase().includes(keyword)) || null;\n    };\n\n    const getLineItemsForPlan = (plan, mode, fallbackVariantId) => {\n      if (!plan) {\n        return [];\n      }\n      /* Try to resolve variant from product data by plan key */\n      const matchedVariant = resolveVariantForPlan(plan.key);\n      let variantId = matchedVariant ? matchedVariant.id : null;\n      /* Fallback to legacy VARIANT_ONE/TWO system */\n      if (!variantId) {\n        variantId = getVariantIdForMode(mode, fallbackVariantId);\n      }\n      if (!variantId) {\n        return [];\n      }\n      return normalizeCartItems([{ id: Number(variantId), quantity: plan.quantity }]);\n    };\n\n    const getPlanPricing = (plan, mode) => {\n      if (!plan) {\n        return {\n          subtotalCents: 0,\n          modeTotalCents: 0,\n          baseSavingsCents: 0,\n          bundleSavingsCents: 0,\n          subscribeSavingsCents: 0,\n          subscribeDiscountPct: 0,\n          promoDiscountCents: 0,\n          finalTotalCents: 0,\n          shippingLabel: 'FREE',\n        };\n      }\n\n      const normalizedMode = mode === 'subscribe' ? 'subscribe' : 'onetime';\n      const subtotalCents = plan.baseTotalCents || plan.compareCents;\n      const effectiveSubscribePercent = plan.planSubscribeDiscountPercent || subscribeDiscountPercent;\n\n      if (normalizedMode === 'subscribe') {\n        /* Subscribe: selling plan discount applied per-unit then multiplied (matches Shopify checkout rounding) */\n        const unitPriceCents = Math.round(subtotalCents / plan.quantity);\n        const discountedUnitCents = Math.round(unitPriceCents * (100 - effectiveSubscribePercent) / 100);\n        const modeTotalCents = Math.max(0, discountedUnitCents * plan.quantity);\n        const subscribeSavingsCents = Math.max(0, subtotalCents - modeTotalCents);\n        const baseSavingsCents = Math.max(0, subtotalCents - modeTotalCents);\n        const promoDiscountCents = getDiscountCentsForAmount(modeTotalCents);\n        return {\n          subtotalCents,\n          modeTotalCents,\n          baseSavingsCents,\n          bundleSavingsCents: 0,\n          subscribeSavingsCents,\n          subscribeDiscountPct: effectiveSubscribePercent,\n          promoDiscountCents,\n          finalTotalCents: Math.max(0, modeTotalCents - promoDiscountCents),\n          shippingLabel: plan.subscribeShippingLabel || subscribeShippingLabel,\n        };\n      }\n\n      /* One-time: bundle discount only (automatic discount in Shopify checkout) */\n      const bundleSavingsCents = Math.max(0, subtotalCents - plan.onetimeTotalCents);\n      const modeTotalCents = plan.onetimeTotalCents;\n      const baseSavingsCents = Math.max(0, subtotalCents - modeTotalCents);\n      const promoDiscountCents = getDiscountCentsForAmount(modeTotalCents);\n      return {\n        subtotalCents,\n        modeTotalCents,\n        baseSavingsCents,\n        bundleSavingsCents,\n        subscribeSavingsCents: 0,\n        subscribeDiscountPct: 0,\n        promoDiscountCents,\n        finalTotalCents: Math.max(0, modeTotalCents - promoDiscountCents),\n        shippingLabel: plan.onetimeShippingLabel,\n      };\n    };\n\n    const syncPurchaseModeUi = () => {\n      const isSubscribeMode = state.purchaseMode === 'subscribe';\n      const modeLocked = isSafetyMode || state.cartBusy;\n      purchaseTypeButtons.forEach((button) => {\n        const buttonMode = button.getAttribute('data-evr-purchase-type') === 'subscribe' ? 'subscribe' : 'onetime';\n        const isActive = buttonMode === state.purchaseMode;\n        button.classList.toggle('is-active', isActive);\n        button.setAttribute('aria-pressed', isActive ? 'true' : 'false');\n        button.disabled = modeLocked;\n        button.setAttribute('aria-disabled', modeLocked ? 'true' : 'false');\n      });\n      purchaseNoteNodes.forEach((node) => {\n        const subscribeNote =\n          String(node.getAttribute('data-subscribe-note') || '').trim() ||\n          `Subscribe & Save ${subscribeDiscountPercent}% \\u00B7 Cancel anytime \\u00B7 Pause anytime`;\n        const onetimeNote =\n          String(node.getAttribute('data-onetime-note') || '').trim() || 'One-time purchase \\u00B7 No recurring charges';\n        node.textContent = isSubscribeMode ? subscribeNote : onetimeNote;\n        node.classList.toggle('evr-v2-purchase-note--onetime', !isSubscribeMode);\n      });\n      var perksNode = document.querySelector('[data-evr-subscribe-perks]');\n      if (perksNode) {\n        if (isSubscribeMode) {\n          perksNode.classList.remove('evr-hidden');\n          perksNode.removeAttribute('hidden');\n        } else {\n          perksNode.classList.add('evr-hidden');\n          perksNode.setAttribute('hidden', '');\n        }\n      }\n      var onetimeCallout = document.querySelector('[data-evr-onetime-callout]');\n      if (onetimeCallout) {\n        if (!isSubscribeMode) {\n          onetimeCallout.classList.remove('evr-hidden');\n          onetimeCallout.removeAttribute('hidden');\n        } else {\n          onetimeCallout.classList.add('evr-hidden');\n          onetimeCallout.setAttribute('hidden', '');\n        }\n      }\n    };\n\n    const syncPlanSelectionUi = () => {\n      const activeEntry = getActivePlanEntry();\n      if (activeEntry && activeEntry.plan.hiddenByDefault) {\n        state.showUpgradePlan = true;\n      }\n      const mobileCollapsed = isMobilePlanCompressionEnabled() && !state.showUpgradePlan;\n      let recommendedBadgeOwnerAssigned = false;\n\n      plans.forEach((entry) => {\n        const isActive = entry.plan.key === state.selectedPlanKey;\n        const matchesRecommendedKey = Boolean(recommendedPlanKey && entry.plan.key === recommendedPlanKey);\n        const isRecommendedPlan = matchesRecommendedKey && !recommendedBadgeOwnerAssigned;\n        if (isRecommendedPlan) {\n          recommendedBadgeOwnerAssigned = true;\n        }\n        const isBestValuePlan = entry.cardNode.classList.contains('evr-v2-plan-option--best-value');\n        const shouldShowByPlanState = !entry.plan.hiddenByDefault || state.showUpgradePlan || isActive;\n        const shouldHideForMobileCompression = mobileCollapsed && !isActive && shouldShowByPlanState;\n        entry.cardNode.classList.toggle('evr-v2-plan-option--recommended', isRecommendedPlan);\n        entry.cardNode.classList.toggle('is-active', isActive);\n        entry.cardNode.classList.toggle('evr-v2-plan-option--mobile-collapsed', shouldHideForMobileCompression);\n        entry.cardNode.setAttribute('aria-pressed', isActive ? 'true' : 'false');\n        entry.cardNode.hidden = !shouldShowByPlanState;\n\n        /* Flag logic: badges only visible in subscribe mode.\n           recommended plan = Most Popular, 6-pack = Best Value (if not recommended) */\n        const isSubscribeMode = state.purchaseMode === 'subscribe';\n        const badgeNodes = Array.from(entry.cardNode.querySelectorAll('[data-evr-plan-badge-kind]'));\n        let winnerKind = null;\n        if (isSubscribeMode) {\n          if (isRecommendedPlan) {\n            winnerKind = 'recommended';\n          } else if (isBestValuePlan && recommendedPlanKey !== 'best_value_6') {\n            winnerKind = 'value';\n          }\n        }\n        badgeNodes.forEach(function (badgeNode) {\n          var kind = String(badgeNode.getAttribute('data-evr-plan-badge-kind') || '').trim().toLowerCase();\n          badgeNode.hidden = kind !== winnerKind;\n        });\n        const badgeGroup = entry.cardNode.querySelector('[data-evr-plan-badges]');\n        if (badgeGroup) {\n          badgeGroup.hidden = !winnerKind;\n        }\n      });\n\n      /* v3 box image swap based on selected plan quantity */\n      const boxImage = document.querySelector('[data-evr-box-image]');\n      if (boxImage && activeEntry) {\n        const qty = activeEntry.plan.quantity;\n        const newSrc = boxImage.getAttribute('data-src-' + qty);\n        if (newSrc && boxImage.src !== newSrc) {\n          boxImage.style.opacity = '0';\n          setTimeout(function () {\n            boxImage.src = newSrc;\n            boxImage.style.opacity = '1';\n          }, 150);\n        }\n      }\n    };\n\n    const syncUpgradeToggleUi = () => {\n      const mobileCompressionEnabled = isMobilePlanCompressionEnabled();\n      if (!mobileCompressionEnabled) {\n        state.showUpgradePlan = false;\n      }\n      upgradeToggleButtons.forEach((button) => {\n        const collapsedLabel = String(button.getAttribute('data-collapsed-label') || 'More options').trim() || 'More options';\n        const shouldHide = !mobileCompressionEnabled || state.showUpgradePlan;\n        button.classList.toggle('is-hidden', shouldHide);\n        button.hidden = shouldHide;\n        button.setAttribute('aria-expanded', state.showUpgradePlan ? 'true' : 'false');\n        button.textContent = collapsedLabel;\n      });\n      var altPlans = document.querySelector('[data-evr-alt-plans]');\n      if (altPlans) {\n        altPlans.hidden = !state.showUpgradePlan;\n      }\n    };\n\n    const syncPlanCardPricingUi = (currencyCode) => {\n      const mode = state.purchaseMode === 'subscribe' ? 'subscribe' : 'onetime';\n      plans.forEach((entry) => {\n        const cardNode = entry.cardNode;\n        const plan = entry.plan;\n        const pricing = getPlanPricing(plan, mode);\n        /* Card prices show mode total (before promo). Promo discount only in summary panel. */\n        const cardTotalCents = pricing.modeTotalCents;\n        const unitCents = Math.max(0, Math.round(cardTotalCents / Math.max(1, plan.quantity)));\n        const unitNode = cardNode.querySelector('[data-evr-plan-unit]');\n        const totalNode = cardNode.querySelector('[data-evr-plan-total]');\n        const wasNode = cardNode.querySelector('[data-evr-plan-was]');\n        const compareNode = cardNode.querySelector('[data-evr-plan-compare]');\n        const perDayNode = cardNode.querySelector('[data-evr-plan-per-day]');\n        const savingsNode = cardNode.querySelector('[data-evr-plan-savings]');\n        const shippingChipNode = cardNode.querySelector('[data-evr-plan-shipping-chip]');\n        const dailyCents = Math.max(0, Math.round(cardTotalCents / Math.max(1, plan.days)));\n\n        if (unitNode) {\n          unitNode.innerHTML = `\n            <span class=\"evr-v2-plan-unit-lead\">Per bottle</span>\n            <strong class=\"evr-v2-plan-unit-price\">${formatCurrencyCents(unitCents, currencyCode)}</strong>\n            <span class=\"evr-v2-plan-unit-suffix\">today</span>\n          `;\n        }\n        if (totalNode) {\n          totalNode.textContent = formatCurrencyCents(cardTotalCents, currencyCode);\n        }\n        if (wasNode) {\n          wasNode.textContent = `Was ${formatCurrencyCents(pricing.modeTotalCents, currencyCode)}`;\n        }\n        if (compareNode) {\n          var compareAtPerBottleCents = 7997;\n          var compareAtTotal = compareAtPerBottleCents * plan.quantity;\n          compareNode.textContent = formatCurrencyCents(compareAtTotal, currencyCode);\n        }\n        if (perDayNode) {\n          perDayNode.textContent = `${formatCurrencyCents(dailyCents, currencyCode)}/day`;\n        }\n        if (savingsNode) {\n          var compareAtPerBottleCents = 7997;\n          var compareAtTotalCents = compareAtPerBottleCents * plan.quantity;\n          var saveCents = Math.max(0, compareAtTotalCents - cardTotalCents);\n          if (saveCents > 0) {\n            savingsNode.textContent = `You save ${formatCurrencyCents(saveCents, currencyCode)}`;\n            savingsNode.classList.remove('evr-hidden');\n            savingsNode.removeAttribute('hidden');\n          } else {\n            savingsNode.classList.add('evr-hidden');\n            savingsNode.setAttribute('hidden', '');\n          }\n        }\n        if (shippingChipNode) {\n          const shippingLabelText = String(pricing.shippingLabel || '').trim();\n          const isFreeShipping = shippingLabelText.toUpperCase().indexOf('FREE') !== -1;\n          shippingChipNode.textContent = isFreeShipping ? 'Free shipping' : shippingLabelText || 'Shipping extra';\n          shippingChipNode.classList.toggle('is-paid', !isFreeShipping);\n        }\n      });\n    };\n\n    syncPurchaseModeUi();\n    syncPlanSelectionUi();\n    syncUpgradeToggleUi();\n\n    purchaseTypeButtons.forEach((button) => {\n      button.onclick = () => {\n        if (isSafetyMode || state.cartBusy) {\n          return;\n        }\n        const mode = button.getAttribute('data-evr-purchase-type') === 'subscribe' ? 'subscribe' : 'onetime';\n        if (mode === state.purchaseMode) {\n          return;\n        }\n        state.purchaseMode = mode;\n        render();\n      };\n    });\n\n    planCards.forEach((cardNode) => {\n      const selectPlan = () => {\n        if (isSafetyMode || state.cartBusy) {\n          return;\n        }\n        const planKey = String(cardNode.getAttribute('data-plan-key') || '').trim();\n        if (!planKey || planKey === state.selectedPlanKey) {\n          return;\n        }\n        state.selectedPlanKey = planKey;\n        render();\n      };\n      cardNode.onclick = selectPlan;\n      cardNode.onkeydown = (event) => {\n        if (event.key === 'Enter' || event.key === ' ') {\n          event.preventDefault();\n          selectPlan();\n        }\n      };\n    });\n\n    upgradeToggleButtons.forEach((button) => {\n      button.onclick = () => {\n        if (!isMobilePlanCompressionEnabled()) {\n          return;\n        }\n        state.showUpgradePlan = true;\n        button.setAttribute('aria-expanded', 'true');\n        button.hidden = true;\n        render();\n      };\n    });\n\n    const productListNode = document.querySelector('[data-evr-products]');\n    const productFeedbackNodes = Array.from(document.querySelectorAll('[data-evr-products-feedback]'));\n    const loadingText =\n      String((productListNode && productListNode.dataset.loadingText) || '').trim() ||\n      'Building your personalized box...';\n    const emptyText =\n      String((productListNode && productListNode.dataset.emptyText) || '').trim() ||\n      'We could not map products for this profile yet. Please revisit the quiz and try again.';\n    const errorText =\n      String((productListNode && productListNode.dataset.errorText) || '').trim() ||\n      'We could not load product data right now. Please refresh and try again.';\n    const productBenefitText =\n      String((productListNode && productListNode.dataset.cardBenefit) || '').trim() ||\n      'Supports stress-disrupted sleep while improving sleep and stress resilience.';\n    const summarySubtotalNodes = Array.from(document.querySelectorAll('[data-evr-summary-subtotal]'));\n    const summarySavingsNodes = Array.from(document.querySelectorAll('[data-evr-summary-savings]'));\n    const summaryDiscountNodes = Array.from(document.querySelectorAll('[data-evr-summary-discount]'));\n    const summaryDiscountInlineNodes = Array.from(document.querySelectorAll('[data-evr-summary-discount-inline]'));\n    const summaryTotalNodes = Array.from(document.querySelectorAll('[data-evr-summary-total]'));\n    const summaryShippingNodes = Array.from(document.querySelectorAll('[data-evr-summary-shipping]'));\n    const summarySubscribeRows = Array.from(document.querySelectorAll('[data-evr-summary-subscribe-row]'));\n    const summarySubscribeSavingNodes = Array.from(document.querySelectorAll('[data-evr-summary-subscribe-saving]'));\n    const summarySubscribeLabelNodes = Array.from(document.querySelectorAll('[data-evr-summary-subscribe-label]'));\n    const summaryBundleRows = Array.from(document.querySelectorAll('[data-evr-summary-bundle-row]'));\n    const summaryBundleSavingNodes = Array.from(document.querySelectorAll('[data-evr-summary-bundle-saving]'));\n    const summaryBundleLabelNodes = Array.from(document.querySelectorAll('[data-evr-summary-bundle-label]'));\n    const summaryPromoRows = Array.from(document.querySelectorAll('[data-evr-summary-promo-row]'));\n    const selectedPlanNodes = Array.from(document.querySelectorAll('[data-evr-selected-plan]'));\n    const selectedModeNodes = Array.from(document.querySelectorAll('[data-evr-selected-mode]'));\n    const summaryPanelNodes = Array.from(document.querySelectorAll('[data-evr-summary-panel]'));\n    const summaryToggleButtons = Array.from(document.querySelectorAll('[data-evr-summary-toggle]'));\n    const checkoutButtons = Array.from(document.querySelectorAll('[data-evr-checkout]'));\n    const scienceToggleButtons = Array.from(document.querySelectorAll('[data-evr-science-toggle]'));\n    const promoFeedbackNodes = Array.from(document.querySelectorAll('[data-evr-promo-feedback]'));\n    const promoInvalidText =\n      String((promoFeedbackNodes[0] && promoFeedbackNodes[0].getAttribute('data-invalid-text')) || '').trim() ||\n      'Enter a valid code using letters, numbers, dash, or underscore.';\n    const promoAppliedText =\n      String((promoFeedbackNodes[0] && promoFeedbackNodes[0].getAttribute('data-applied-text')) || '').trim() ||\n      'Promo code applied.';\n    const promoValidatingText =\n      String((promoFeedbackNodes[0] && promoFeedbackNodes[0].getAttribute('data-validating-text')) || '').trim() ||\n      'Validating code...';\n    const promoUnavailableText =\n      String((promoFeedbackNodes[0] && promoFeedbackNodes[0].getAttribute('data-unavailable-text')) || '').trim() ||\n      'We could not validate this code right now. Please try again.';\n    const promoAllowlistRaw = String(\n      (promoFeedbackNodes[0] && promoFeedbackNodes[0].getAttribute('data-allowlist-codes')) || ''\n    );\n    const promoAllowlistCodes = new Set();\n    parsePromoAllowlistCodes(promoAllowlistRaw).forEach((entry) => {\n      promoAllowlistCodes.add(entry);\n    });\n    /* Personal code is always valid if present */\n    if (state.personalDiscountCode) {\n      promoAllowlistCodes.add(normalizeDiscountCode(state.personalDiscountCode));\n    }\n\n    const promoInputs = Array.from(document.querySelectorAll('[data-evr-code-input]'));\n    const promoChangeButtons = Array.from(document.querySelectorAll('[data-evr-code-change]'));\n    const promoApplyButtons = Array.from(document.querySelectorAll('[data-evr-code-apply]'));\n    const promoActionButtons = [...promoChangeButtons, ...promoApplyButtons];\n\n    promoInputs.forEach((input) => {\n      input.value = getActiveDiscountCode();\n      input.disabled = true;\n    });\n\n    const setPromoActionDisabledState = (isDisabled, isBusy = false) => {\n      promoActionButtons.forEach((button) => {\n        button.disabled = isDisabled;\n        button.setAttribute('aria-busy', isBusy ? 'true' : 'false');\n      });\n    };\n\n    const applyPromoInputValue = async (inputNode) => {\n      if (!inputNode || isSafetyMode) {\n        return;\n      }\n      const rawInput = String(inputNode.value || '').trim();\n      if (!isDiscountCodeInputValid(rawInput)) {\n        setInlineFeedback(promoFeedbackNodes, promoInvalidText, 'error');\n        safeFocus(inputNode);\n        safeSelect(inputNode);\n        return;\n      }\n\n      setPromoActionDisabledState(true, true);\n      setInlineFeedback(promoFeedbackNodes, promoValidatingText, 'info');\n      const validationResult = await validateDiscountCode(rawInput, {\n        allowlist: promoAllowlistCodes,\n        invalidText: promoInvalidText,\n        unavailableText: promoUnavailableText,\n      });\n      setPromoActionDisabledState(false, false);\n\n      if (!validationResult.valid) {\n        setInlineFeedback(promoFeedbackNodes, validationResult.message || promoInvalidText, 'error');\n        inputNode.disabled = false;\n        safeFocus(inputNode);\n        safeSelect(inputNode);\n        return;\n      }\n\n      setManualDiscountCode(validationResult.normalizedCode, {\n        discountPercent: validationResult.discountPercent,\n      });\n      inputNode.value = getActiveDiscountCode();\n      inputNode.disabled = true;\n      const controls = inputNode.closest('.evr-promo-row__controls, .evr-v2-promo-controls');\n      if (controls) {\n        const changeButton = controls.querySelector('[data-evr-code-change]');\n        const applyButton = controls.querySelector('[data-evr-code-apply]');\n        if (changeButton) {\n          changeButton.classList.remove('evr-hidden');\n        }\n        if (applyButton) {\n          applyButton.classList.add('evr-hidden');\n        }\n      }\n      setInlineFeedback(\n        promoFeedbackNodes,\n        validationResult.message || (rawInput ? promoAppliedText : ''),\n        rawInput ? 'success' : 'info'\n      );\n      render();\n    };\n\n    promoChangeButtons.forEach((changeButton) => {\n      changeButton.onclick = () => {\n        if (isSafetyMode) {\n          return;\n        }\n        const controls = changeButton.closest('.evr-promo-row__controls, .evr-v2-promo-controls');\n        if (!controls) {\n          return;\n        }\n        const input = controls.querySelector('[data-evr-code-input]');\n        const applyButton = controls.querySelector('[data-evr-code-apply]');\n        if (!input) {\n          return;\n        }\n\n        input.disabled = false;\n        safeFocus(input);\n        safeSelect(input);\n        setInlineFeedback(promoFeedbackNodes, '', 'info');\n        changeButton.classList.add('evr-hidden');\n        if (applyButton) {\n          applyButton.classList.remove('evr-hidden');\n        }\n      };\n    });\n\n    promoApplyButtons.forEach((applyButton) => {\n      applyButton.onclick = async () => {\n        if (isSafetyMode) {\n          return;\n        }\n        const controls = applyButton.closest('.evr-promo-row__controls, .evr-v2-promo-controls');\n        if (!controls) {\n          return;\n        }\n        await applyPromoInputValue(controls.querySelector('[data-evr-code-input]'));\n      };\n    });\n\n    promoInputs.forEach((input) => {\n      input.onkeydown = (event) => {\n        if (isSafetyMode) {\n          return;\n        }\n        if (event.key === 'Enter') {\n          event.preventDefault();\n          void applyPromoInputValue(input);\n        }\n      };\n    });\n\n    if (isSafetyMode) {\n      setPromoActionDisabledState(true, false);\n      setInlineFeedback(promoFeedbackNodes, '', 'info');\n    } else {\n      setPromoActionDisabledState(false, false);\n    }\n\n    const syncSummaryPanelUi = () => {\n      summaryPanelNodes.forEach((panel) => {\n        panel.hidden = false;\n        panel.classList.remove('is-collapsed');\n      });\n      summaryToggleButtons.forEach((button) => {\n        button.hidden = true;\n        button.setAttribute('aria-expanded', 'true');\n      });\n    };\n    syncSummaryPanelUi();\n\n    const syncScienceAccordionUi = () => {\n      const visibleScienceItems = Array.from(document.querySelectorAll('.evr-v2-science-list .evr-v2-science-item')).filter(\n        (item) => !item.classList.contains('evr-hidden') && !item.hasAttribute('hidden')\n      );\n      const hasOverflow = visibleScienceItems.length > 3;\n      if (!hasOverflow) {\n        state.scienceExpanded = false;\n      }\n      visibleScienceItems.forEach((item, index) => {\n        const shouldTruncate = hasOverflow && !state.scienceExpanded && index >= 3;\n        item.classList.toggle('evr-v2-science-item--truncated', shouldTruncate);\n      });\n      scienceToggleButtons.forEach((button) => {\n        button.hidden = !hasOverflow;\n        button.textContent = state.scienceExpanded ? 'Show less' : 'View all';\n        button.setAttribute('aria-expanded', state.scienceExpanded ? 'true' : 'false');\n      });\n    };\n\n    scienceToggleButtons.forEach((button) => {\n      button.onclick = () => {\n        state.scienceExpanded = !state.scienceExpanded;\n        syncScienceAccordionUi();\n      };\n    });\n    syncScienceAccordionUi();\n\n    const getVariantForItem = (product, item) => {\n      if (!product || !Array.isArray(product.variants)) {\n        return null;\n      }\n\n      const variantId = Number(item && item.id);\n      if (!Number.isFinite(variantId) || variantId <= 0) {\n        return product.variants[0] || null;\n      }\n\n      return product.variants.find((variant) => Number(variant.id) === variantId) || product.variants[0] || null;\n    };\n\n    const renderProductsAndSummary = (product) => {\n      const currency = (product && product.currency) || 'USD';\n      const discountCode = getActiveDiscountCode();\n      const discountMeta = getActiveDiscountMeta();\n      const checkoutMode = state.purchaseMode === 'subscribe' ? 'subscribe' : 'onetime';\n      const hasProductData = Boolean(product && Array.isArray(product.variants) && product.variants.length);\n      if (!hasProductData && state.cadenceProductStatus === 'idle') {\n        state.cadenceProductStatus = 'loading';\n      }\n\n      const activePlanEntry = getActivePlanEntry();\n      const activePlan = activePlanEntry ? activePlanEntry.plan : null;\n      const lineItems = hasProductData\n        ? activePlan\n          ? getLineItemsForPlan(activePlan, checkoutMode, state.variantFallbackId)\n          : getCurrentResultLineItems(personalization, state.variantFallbackId)\n        : [];\n      state.resultsLineItems = normalizeCartItems(lineItems);\n      syncPurchaseModeUi();\n      syncPlanSelectionUi();\n      syncUpgradeToggleUi();\n      syncPlanCardPricingUi(currency);\n      if (planRootNode) {\n        planRootNode.setAttribute('data-purchase-mode', checkoutMode);\n      }\n      const activePlanDiscountPct = (activePlan && activePlan.planSubscribeDiscountPercent) || subscribeDiscountPercent;\n      const modeLabel = checkoutMode === 'subscribe' ? `AutoShip & Save ${activePlanDiscountPct}%` : 'One-time';\n      selectedPlanNodes.forEach((node) => {\n        node.textContent = formatPlanSelectionLabel(activePlan);\n      });\n      selectedModeNodes.forEach((node) => {\n        node.textContent = modeLabel;\n      });\n\n      offerCopyNodes.forEach((node) => {\n        if (!node) {\n          return;\n        }\n        if (!discountCode) {\n          node.textContent = '';\n          return;\n        }\n        const discountLabel =\n          discountMeta.type === 'percent'\n            ? `${discountMeta.value}% off today`\n            : `${formatCurrencyCents(discountMeta.value, currency)} off today`;\n        node.textContent =\n          `${discountCode} applied \\u00B7 ${discountLabel} \\u00B7 Stays in this checkout`;\n      });\n\n      summaryCodeNodes.forEach((node) => {\n        node.textContent = discountCode;\n      });\n      promoInputs.forEach((input) => {\n        if (input.disabled) {\n          input.value = discountCode;\n        }\n      });\n\n      if (productListNode) {\n        const isLoadingState = !hasProductData && state.cadenceProductStatus !== 'error';\n        productListNode.setAttribute('aria-busy', isLoadingState ? 'true' : 'false');\n        clearElement(productListNode);\n      }\n\n      if (!hasProductData) {\n        const pendingText = state.cadenceProductStatus === 'error' ? errorText : loadingText;\n        if (productListNode) {\n          const empty = document.createElement('p');\n          empty.className = 'evq-results__body';\n          empty.textContent = pendingText;\n          productListNode.appendChild(empty);\n        }\n        setInlineFeedback(productFeedbackNodes, pendingText, state.cadenceProductStatus === 'error' ? 'error' : 'info');\n      } else if (!state.resultsLineItems.length) {\n        if (productListNode) {\n          const empty = document.createElement('p');\n          empty.className = 'evq-results__body';\n          empty.textContent = emptyText;\n          productListNode.appendChild(empty);\n        }\n        setInlineFeedback(productFeedbackNodes, emptyText, 'warning');\n      } else {\n        setInlineFeedback(productFeedbackNodes, '', 'info');\n      }\n\n      const activePricing = getPlanPricing(activePlan, checkoutMode);\n      let subtotalCents = activePricing.subtotalCents;\n      let savingsCents = activePricing.baseSavingsCents;\n      let bundleSavingsCents = activePricing.bundleSavingsCents;\n      let subscribeSavingsCents = activePricing.subscribeSavingsCents;\n      let discountCents = activePricing.promoDiscountCents;\n      let totalCents = activePricing.finalTotalCents;\n      let modeTotalCents = activePricing.modeTotalCents;\n      let shippingLabel = activePricing.shippingLabel;\n      if (hasProductData && state.resultsLineItems.length) {\n        state.resultsLineItems.forEach((lineItem) => {\n          const variant = getVariantForItem(product, lineItem);\n          const productTitle = (product && product.title) || 'Cadence Calm+Rest';\n          const protocolBadge = String(productListNode && productListNode.dataset.cardBadge ? productListNode.dataset.cardBadge : 'AutoShip & Save up to 40%');\n          const protocolHeadline = String(productListNode && productListNode.dataset.cardHeadline ? productListNode.dataset.cardHeadline : 'Stop Borrowing Calm. Start Building It.');\n          const variantTitle =\n            (activePlan && `${activePlan.title} - ${checkoutMode === 'subscribe' ? 'Subscribe' : 'One-time'}`) ||\n            (variant && variant.title && variant.title !== 'Default Title' ? variant.title : 'Cadence Calm+Rest');\n          const imageUrl =\n            (variant && variant.featured_image && variant.featured_image.src) ||\n            (product && product.featured_image) ||\n            (product && Array.isArray(product.images) && product.images[0]) ||\n            '';\n          const unitPriceCents = parsePriceToCents((variant && variant.price) || (product && product.price) || 0);\n          const lineSubtotalCents = activePlan ? subtotalCents : unitPriceCents * lineItem.quantity;\n          const lineTotalCents = activePlan\n            ? modeTotalCents\n            : Math.max(0, lineSubtotalCents - getDiscountCentsForAmount(lineSubtotalCents));\n          if (!activePlan) {\n            subtotalCents += lineSubtotalCents;\n            discountCents = getDiscountCentsForAmount(subtotalCents);\n            totalCents = Math.max(0, subtotalCents - discountCents);\n            savingsCents = Math.max(0, subtotalCents - totalCents);\n            modeTotalCents = subtotalCents;\n            shippingLabel = 'FREE';\n          }\n\n          if (!productListNode) {\n            return;\n          }\n\n          const card = document.createElement('article');\n          card.className = 'evq-results__product-card';\n          card.innerHTML = `\n            <div class=\"evq-results__product-media\">\n              ${\n                imageUrl\n                  ? `<img src=\"${escapeHtml(imageUrl)}\" alt=\"${escapeHtml(productTitle)}\" loading=\"lazy\" />`\n                  : '<div class=\"evq-results__product-media-placeholder\">Cadence</div>'\n              }\n            </div>\n            <div class=\"evq-results__product-content\">\n              <p class=\"evr-product-badge\">${escapeHtml(protocolBadge)}</p>\n              <h4 class=\"evr-product-headline\">${escapeHtml(protocolHeadline)}</h4>\n              <p class=\"evq-results__product-kicker\">${escapeHtml(variantTitle)}</p>\n              <p class=\"evq-results__product-benefit\">${escapeHtml(productBenefitText)}</p>\n              <div class=\"evr-v2-ingredient-evidence\">\n                <p class=\"evr-v2-ingredient-line\">Chelamax + Saffron + L-Theanine</p>\n                <p class=\"evr-v2-ingredient-subline\">64% absorption vs 8% oxide</p>\n                <button type=\"button\" class=\"evr-v2-inline-link\" data-evr-v2-report-open>Research & reviews</button>\n              </div>\n              <div class=\"evq-results__product-footer\">\n                <div class=\"evq-results__price\">\n                  <span class=\"evq-results__price-original\">${formatCurrencyCents(lineSubtotalCents, currency)}</span>\n                  <span class=\"evq-results__price-discounted\">${formatCurrencyCents(lineTotalCents, currency)}</span>\n                </div>\n                <div class=\"evq-results__qty evq-results__qty--static\">\n                  <span>Qty ${lineItem.quantity}</span>\n                </div>\n              </div>\n            </div>\n          `;\n          productListNode.appendChild(card);\n        });\n      }\n\n      summarySubtotalNodes.forEach((node) => {\n        node.textContent = formatCurrencyCents(subtotalCents, currency);\n      });\n      summarySavingsNodes.forEach((node) => {\n        node.textContent = formatCurrencyCents(savingsCents, currency);\n      });\n      /* Broken-down savings rows */\n      summarySubscribeRows.forEach((row) => {\n        row.style.display = subscribeSavingsCents > 0 ? '' : 'none';\n      });\n      summarySubscribeSavingNodes.forEach((node) => {\n        node.textContent = `-${formatCurrencyCents(subscribeSavingsCents, currency)}`;\n      });\n      summarySubscribeLabelNodes.forEach((node) => {\n        const pct = (activePlan && activePlan.planSubscribeDiscountPercent) || subscribeDiscountPercent;\n        node.textContent = `AutoShip & Save (${pct}%)`;\n      });\n      summaryBundleRows.forEach((row) => {\n        row.style.display = bundleSavingsCents > 0 ? '' : 'none';\n      });\n      summaryBundleSavingNodes.forEach((node) => {\n        node.textContent = `-${formatCurrencyCents(bundleSavingsCents, currency)}`;\n      });\n      summaryBundleLabelNodes.forEach((node) => {\n        const qty = activePlan ? activePlan.quantity : 1;\n        const pct = subtotalCents > 0 ? Math.round((bundleSavingsCents / subtotalCents) * 100) : 0;\n        if (qty > 1 && pct > 0) {\n          node.textContent = `Buy ${qty} Savings (${pct}%)`;\n        } else if (pct > 0) {\n          node.textContent = `Savings (${pct}%)`;\n        } else {\n          node.textContent = 'Savings';\n        }\n      });\n      summaryPromoRows.forEach((row) => {\n        row.style.display = discountCents > 0 ? '' : 'none';\n      });\n      summaryDiscountNodes.forEach((node) => {\n        node.textContent = `-${formatCurrencyCents(discountCents, currency)}`;\n      });\n      summaryDiscountInlineNodes.forEach((node) => {\n        node.textContent = `-${formatCurrencyCents(discountCents, currency)}`;\n      });\n      summaryTotalNodes.forEach((node) => {\n        node.textContent = formatCurrencyCents(totalCents, currency);\n      });\n      summaryShippingNodes.forEach((node) => {\n        node.textContent = shippingLabel;\n      });\n      activeShippingNoteNodes.forEach((node) => {\n        const shippingLabelText = String(shippingLabel || '').trim();\n        const isFreeShipping = shippingLabelText.toUpperCase().indexOf('FREE') !== -1;\n        if (isFreeShipping) {\n          node.textContent = 'Free shipping on this order';\n          return;\n        }\n        node.textContent = shippingLabelText || 'Shipping calculated at checkout';\n      });\n\n      const hasLineItems = state.resultsLineItems.length > 0;\n      const isUnavailable = !hasProductData || !hasLineItems;\n      const syncActionButtonState = (button, items, options = {}) => {\n        const fallbackLabel = options.fallbackLabel || 'Add routine to cart';\n        const defaultLabel =\n          String(button.getAttribute('data-default-label') || button.textContent || fallbackLabel).trim() ||\n          fallbackLabel;\n        const busyLabel =\n          String(button.getAttribute('data-busy-label') || 'Preparing checkout...').trim() || 'Preparing checkout...';\n\n        if (personalization.safetyGate) {\n          button.disabled = true;\n          button.setAttribute('aria-disabled', 'true');\n          button.setAttribute('aria-busy', 'false');\n          button.setAttribute('aria-label', 'Consult your doctor first');\n          button.textContent = 'CONSULT YOUR DOCTOR FIRST';\n          button.onclick = null;\n          return;\n        }\n\n        if (state.cartBusy) {\n          button.disabled = true;\n          button.setAttribute('aria-disabled', 'true');\n          button.setAttribute('aria-busy', 'true');\n          button.setAttribute('aria-label', busyLabel);\n          button.textContent = busyLabel;\n          button.onclick = null;\n          return;\n        }\n\n        if (!hasProductData || !Array.isArray(items) || !items.length) {\n          button.disabled = true;\n          button.setAttribute('aria-disabled', 'true');\n          button.setAttribute('aria-busy', 'false');\n          button.setAttribute('aria-label', hasProductData ? 'Unavailable' : busyLabel);\n          button.textContent = hasProductData ? 'UNAVAILABLE' : busyLabel;\n          button.onclick = null;\n          return;\n        }\n\n        button.disabled = false;\n        button.setAttribute('aria-disabled', 'false');\n        button.setAttribute('aria-busy', 'false');\n        button.setAttribute('aria-label', defaultLabel);\n        button.textContent = defaultLabel;\n        button.onclick = async () => {\n          if (state.cartBusy) {\n            return;\n          }\n          button.disabled = true;\n          button.setAttribute('aria-disabled', 'true');\n          button.setAttribute('aria-busy', 'true');\n          button.textContent = busyLabel;\n          try {\n            await handleCartRedirection(personalization, {\n              items,\n            });\n          } finally {\n            if (state.currentRoute === 'results') {\n              render();\n            }\n          }\n        };\n      };\n\n      checkoutButtons.forEach((button) => {\n        syncActionButtonState(button, state.resultsLineItems, { fallbackLabel: 'Add routine to cart' });\n      });\n\n      if (isUnavailable) {\n        state.resultsLineItems = [];\n      }\n    };\n\n    if (!state.cadenceProduct && !state.cadenceProductPromise) {\n      state.cadenceProductStatus = 'loading';\n    }\n    renderProductsAndSummary(state.cadenceProduct);\n\n    loadCadenceProduct().then((product) => {\n      if (state.currentRoute !== 'results') {\n        return;\n      }\n      const firstVariant = product && Array.isArray(product.variants) ? product.variants[0] : null;\n      if (state.variantFallbackId === undefined) {\n        state.variantFallbackId = firstVariant && firstVariant.id ? Number(firstVariant.id) : null;\n      }\n      renderProductsAndSummary(product);\n    });\n\n    startResultsTimer();\n\n    /* v3: Sticky promo bar \u2014 IntersectionObserver */\n    var stickyPromo = document.querySelector('[data-evr-sticky-promo]');\n    var heroOffer = document.querySelector('.evr-v2-hero-offer');\n    if (stickyPromo && heroOffer) {\n      stickyPromo.removeAttribute('hidden');\n      /* measure actual height so hidden state fully hides the bar */\n      var promoH = stickyPromo.offsetHeight;\n      if (promoH) {\n        document.documentElement.style.setProperty('--evr-v2-sticky-promo-h', promoH + 'px');\n      }\n      var stickyObserver = new IntersectionObserver(function (entries) {\n        var entry = entries[0];\n        /* Guard: never show bar while page is at top (observer fires immediately on setup) */\n        stickyPromo.classList.toggle('is-visible', !entry.isIntersecting && window.scrollY > 0);\n      }, { threshold: 0 });\n      stickyObserver.observe(heroOffer);\n    }\n\n    /* Hide mobile bar on scroll down, show on scroll up */\n    var mobileBar = document.querySelector('.evr-v2-mobile-bar');\n    if (mobileBar) {\n      var lastScrollY = window.scrollY;\n      var scrollTicking = false;\n      window.addEventListener('scroll', function () {\n        if (!scrollTicking) {\n          requestAnimationFrame(function () {\n            var currentY = window.scrollY;\n            if (currentY > lastScrollY && currentY > 200) {\n              mobileBar.classList.add('is-hidden');\n            } else {\n              mobileBar.classList.remove('is-hidden');\n            }\n            lastScrollY = currentY;\n            scrollTicking = false;\n          });\n          scrollTicking = true;\n        }\n      }, { passive: true });\n    }\n\n    if (isV2Layout) {\n      if (isThemeEditor) {\n        forceCloseV2ReportModal();\n        bindV2ReportModalEditorCleanup();\n      }\n      bindV2ReportModal();\n    }\n\n    /* Signal that personalization data has been applied \u2014 reveal content, hide loader */\n    var revealPage = function() {\n      document.body.classList.add('evr-v2-loaded');\n      document.body.classList.add('evr-v3-loaded');\n    };\n    if (window.__evrLoadingDone) {\n      window.__evrLoadingDone.then(revealPage);\n    } else {\n      revealPage();\n    }\n  }\n\n  function renderResultsStep() {\n    const personalization = inferProfilePreview();\n    persistSessionSnapshot(personalization);\n\n    state.timer.nodes = [];\n    state.timer.expiredNodes = [];\n    state.timer.codeNodes = [];\n\n    const section = document.createElement('section');\n    section.className = 'evq-results evq-results--dashboard';\n\n    const timerCard = document.createElement('article');\n    timerCard.className = 'evq-results__card evq-results__timer-card';\n    timerCard.innerHTML = `\n      <div class=\"evq-results__timer-row\">\n        <p class=\"evq-results__timer-label\">Your quiz bonus expires in</p>\n        <p class=\"evq-results__timer-value\" data-evq-timer-clock>60:00</p>\n      </div>\n      <div class=\"evq-results__timer-meta\">\n        <span>Status: <strong data-evq-timer-state>Active</strong></span>\n        <span>Code: <strong data-evq-timer-code>${escapeHtml(getActiveDiscountCode() || '\u2014')}</strong></span>\n      </div>\n    `;\n    const timerClock = timerCard.querySelector('[data-evq-timer-clock]');\n    const timerState = timerCard.querySelector('[data-evq-timer-state]');\n    const timerCode = timerCard.querySelector('[data-evq-timer-code]');\n    if (timerClock) state.timer.nodes.push(timerClock);\n    if (timerState) state.timer.expiredNodes.push(timerState);\n    if (timerCode) state.timer.codeNodes.push(timerCode);\n\n    const firstName = (state.lead.firstName || state.customer.firstName || '').trim();\n    const greetingCard = document.createElement('article');\n    greetingCard.className = 'evq-results__card evq-results__greeting-card';\n    greetingCard.innerHTML = `\n      <h2 class=\"evq-results__greeting\">${firstName ? `Hi ${escapeHtml(firstName)},` : 'Hi there,'} Meet your Evolance Routine.</h2>\n      <p class=\"evq-results__body\">Your protocol is based on 33 personalization rules and calibrated to your current profile.</p>\n    `;\n\n    const dashboard = document.createElement('div');\n    dashboard.className = 'evq-results__dashboard';\n\n    const mainColumn = document.createElement('div');\n    mainColumn.className = 'evq-results__main';\n\n    const sidebar = document.createElement('aside');\n    sidebar.className = 'evq-results__sidebar';\n\n    const bundleLabel = (personalization.bundleKey || '').replaceAll('_', ' ');\n    const routineCard = document.createElement('article');\n    routineCard.className = 'evq-results__card';\n    routineCard.innerHTML = `\n      <p class=\"evq-results__badge\">${escapeHtml(personalization.profileLabel)}</p>\n      <h3 class=\"evq-results__title\">${escapeHtml(personalization.dynamicHeadline)}</h3>\n      <p class=\"evq-results__body\">${escapeHtml(personalization.dynamicSubheadline)}</p>\n      <p class=\"evq-results__bundle\">Recommended Routine: <strong>${escapeHtml(bundleLabel)}</strong></p>\n    `;\n\n    const productCard = document.createElement('article');\n    productCard.className = 'evq-results__card';\n    productCard.innerHTML = `\n      <h3 class=\"evq-results__subtitle\">Your Personalized Box</h3>\n      <p class=\"evq-results__body\">This protocol is built from your stored bundle IDs and profile signals.</p>\n      <div class=\"evq-results__products\" data-evq-results-products></div>\n    `;\n    const productListNode = productCard.querySelector('[data-evq-results-products]');\n\n    const expertCard = document.createElement('article');\n    expertCard.className = 'evq-results__card evq-results__card--specialist';\n    expertCard.innerHTML = `\n      <h3 class=\"evq-results__subtitle\">Personal Wellness Concierge</h3>\n      <p class=\"evq-results__body\"><strong>${escapeHtml(personalization.specialist)}</strong>, ${escapeHtml(\n      personalization.specialistRole\n    )}</p>\n      <p class=\"evq-results__body\">\n        We are prioritizing ${escapeHtml(personalization.primaryIssue.label)} with a protocol focused on\n        ${escapeHtml(personalization.ingredientPriority.slice(0, 2).map((item) => item.label).join(' + '))}.\n      </p>\n      <div class=\"evq-results__concierge-video\">\n        <span>Video message placeholder</span>\n      </div>\n      <label class=\"evq-results__concierge-label\" for=\"evq-concierge-question\">Have a question? Send message</label>\n      <div class=\"evq-results__concierge-row\">\n        <input id=\"evq-concierge-question\" type=\"text\" placeholder=\"Type your question for the concierge team\" />\n        <button type=\"button\" disabled>Send</button>\n      </div>\n    `;\n\n    const timelineCard = document.createElement('article');\n    timelineCard.className = 'evq-results__card';\n    timelineCard.innerHTML = `\n      <h3 class=\"evq-results__subtitle\">Timeline to Results</h3>\n      <div class=\"evq-results__timeline\" data-evq-timeline-steps></div>\n      <div class=\"evq-results__timeline-detail\" data-evq-timeline-detail></div>\n    `;\n\n    const timelineStepsContainer = timelineCard.querySelector('[data-evq-timeline-steps]');\n    const timelineDetail = timelineCard.querySelector('[data-evq-timeline-detail]');\n\n    const setActiveTimeline = (timelineId) => {\n      timelineStepsContainer.querySelectorAll('[data-timeline-id]').forEach((button) => {\n        const isActive = button.dataset.timelineId === timelineId;\n        button.classList.toggle('is-active', isActive);\n      });\n\n      const activeStep = personalization.timeline.find((step) => step.id === timelineId) || personalization.timeline[0];\n      timelineDetail.innerHTML = `\n        <h4>${escapeHtml(activeStep.title)}</h4>\n        <p>${escapeHtml(activeStep.body)}</p>\n      `;\n    };\n\n    personalization.timeline.forEach((step, index) => {\n      const stepButton = document.createElement('button');\n      stepButton.type = 'button';\n      stepButton.className = `evq-results__timeline-step ${index === 0 ? 'is-active' : ''}`;\n      stepButton.dataset.timelineId = step.id;\n      stepButton.textContent = step.label;\n      stepButton.addEventListener('click', () => setActiveTimeline(step.id));\n      timelineStepsContainer.appendChild(stepButton);\n    });\n    setActiveTimeline(personalization.timeline[0].id);\n\n    const testimonialCard = document.createElement('article');\n    testimonialCard.className = 'evq-results__card';\n    testimonialCard.innerHTML = '<h3 class=\"evq-results__subtitle\">Profile-Matched Testimonials</h3>';\n\n    personalization.testimonials.forEach((entry) => {\n      const block = document.createElement('blockquote');\n      block.className = 'evq-results__testimonial';\n      block.innerHTML = `<p>\"${escapeHtml(entry.quote)}\"</p><footer>${escapeHtml(entry.author)} \u00B7 ${escapeHtml(\n        entry.context\n      )}</footer>`;\n      testimonialCard.appendChild(block);\n    });\n\n    const shopMoreCard = document.createElement('article');\n    shopMoreCard.className = 'evq-results__card';\n    shopMoreCard.innerHTML = '<h3 class=\"evq-results__subtitle\">Shop More</h3>';\n    const shopMoreGrid = document.createElement('div');\n    shopMoreGrid.className = 'evq-results__shop-grid';\n    SHOP_MORE_CATEGORIES.forEach((category) => {\n      const link = document.createElement('a');\n      link.className = 'evq-results__shop-link';\n      link.href = category.href;\n      link.innerHTML = `<strong>${escapeHtml(category.title)}</strong><span>${escapeHtml(category.subtitle)}</span>`;\n      shopMoreGrid.appendChild(link);\n    });\n    shopMoreCard.appendChild(shopMoreGrid);\n\n    const summaryCard = document.createElement('article');\n    summaryCard.className = 'evq-results__card evq-results__summary';\n    summaryCard.innerHTML = `\n      <h3 class=\"evq-results__subtitle\">Summary</h3>\n      <p class=\"evq-results__body\">Choose your delivery mode and proceed to secure checkout.</p>\n      <div class=\"evq-results__mode\" data-evq-mode-group>\n        <button type=\"button\" class=\"evq-results__mode-btn ${state.purchaseMode === 'subscribe' ? 'is-active' : ''}\" data-mode=\"subscribe\">\n          Subscribe & Save 20%\n        </button>\n        <button type=\"button\" class=\"evq-results__mode-btn ${state.purchaseMode === 'onetime' ? 'is-active' : ''}\" data-mode=\"onetime\">\n          One-time Purchase\n        </button>\n      </div>\n      <dl class=\"evq-results__summary-table\">\n        <div><dt>Subtotal</dt><dd data-evq-summary-subtotal>$0.00</dd></div>\n        <div><dt><span><span data-evq-summary-code>${escapeHtml(getActiveDiscountCode())}</span> Discount</span></dt><dd data-evq-summary-discount>$0.00</dd></div>\n        <div class=\"is-total\"><dt>Total</dt><dd data-evq-summary-total>$0.00</dd></div>\n      </dl>\n      <button type=\"button\" class=\"evq-results__checkout-btn\" data-evq-sidebar-checkout>CHECK OUT</button>\n    `;\n\n    const summarySubtotalNode = summaryCard.querySelector('[data-evq-summary-subtotal]');\n    const summaryDiscountNode = summaryCard.querySelector('[data-evq-summary-discount]');\n    const summaryTotalNode = summaryCard.querySelector('[data-evq-summary-total]');\n    const summaryCodeNode = summaryCard.querySelector('[data-evq-summary-code]');\n    const checkoutButton = summaryCard.querySelector('[data-evq-sidebar-checkout]');\n\n    if (summaryCodeNode) {\n      state.timer.codeNodes.push(summaryCodeNode);\n    }\n\n    summaryCard.querySelectorAll('[data-mode]').forEach((button) => {\n      button.addEventListener('click', () => {\n        const mode = button.dataset.mode === 'onetime' ? 'onetime' : 'subscribe';\n        if (mode === state.purchaseMode) {\n          return;\n        }\n        state.purchaseMode = mode;\n        state.resultsLineItems = [];\n        render();\n      });\n    });\n\n    if (checkoutButton) {\n      if (personalization.safetyGate) {\n        checkoutButton.disabled = true;\n        checkoutButton.textContent = 'CONSULT YOUR DOCTOR FIRST';\n      } else {\n        checkoutButton.addEventListener('click', async () => {\n          if (state.cartBusy) {\n            return;\n          }\n          await handleCartRedirection(personalization, {\n            items: state.resultsLineItems,\n          });\n        });\n      }\n    }\n\n    let safetyCard = null;\n    if (personalization.safetyGate) {\n      safetyCard = document.createElement('article');\n      safetyCard.className = 'evq-results__card evq-results__warning';\n      safetyCard.innerHTML = `\n        <h3 class=\"evq-results__subtitle\">Important: Pregnancy & Breastfeeding Notice</h3>\n        <p class=\"evq-results__body\">\n          You indicated pregnancy/breastfeeding in Q12. Please consult your physician before taking supplements.\n          Cart checkout is intentionally blocked until medical consultation.\n        </p>\n      `;\n    }\n\n    mainColumn.appendChild(routineCard);\n    mainColumn.appendChild(productCard);\n    mainColumn.appendChild(expertCard);\n    mainColumn.appendChild(timelineCard);\n    mainColumn.appendChild(testimonialCard);\n    mainColumn.appendChild(shopMoreCard);\n    if (safetyCard) {\n      mainColumn.appendChild(safetyCard);\n    }\n\n    sidebar.appendChild(summaryCard);\n    dashboard.appendChild(mainColumn);\n    dashboard.appendChild(sidebar);\n\n    section.appendChild(timerCard);\n    section.appendChild(greetingCard);\n    section.appendChild(dashboard);\n    content.appendChild(section);\n\n    const getVariantForItem = (product, item) => {\n      if (!product || !Array.isArray(product.variants)) {\n        return null;\n      }\n\n      const variantId = Number(item && item.id);\n      if (!Number.isFinite(variantId) || variantId <= 0) {\n        return product.variants[0] || null;\n      }\n\n      return product.variants.find((variant) => Number(variant.id) === variantId) || product.variants[0] || null;\n    };\n\n    const renderProductsAndSummary = (product) => {\n      const currency = (product && product.currency) || 'USD';\n      const discountCode = getActiveDiscountCode();\n      const discountPercent = getActiveDiscountPercent();\n      const lineItems = getCurrentResultLineItems(personalization, state.variantFallbackId);\n      state.resultsLineItems = normalizeCartItems(lineItems);\n\n      if (summaryCodeNode) {\n        summaryCodeNode.textContent = discountCode;\n      }\n\n      clearElement(productListNode);\n\n      if (!state.resultsLineItems.length) {\n        const empty = document.createElement('p');\n        empty.className = 'evq-results__body';\n        empty.textContent = 'Product configuration is loading. Please wait a moment.';\n        productListNode.appendChild(empty);\n      }\n\n      let subtotalCents = 0;\n\n      state.resultsLineItems.forEach((lineItem, index) => {\n        const variant = getVariantForItem(product, lineItem);\n        const productTitle = (product && product.title) || 'Cadence Calm+Rest';\n        const variantTitle =\n          variant && variant.title && variant.title !== 'Default Title'\n            ? variant.title\n            : state.purchaseMode === 'subscribe'\n              ? 'Subscribe & Save 20%'\n              : 'One-time Purchase';\n        const imageUrl =\n          (variant && variant.featured_image && variant.featured_image.src) ||\n          (product && product.featured_image) ||\n          (product && Array.isArray(product.images) && product.images[0]) ||\n          '';\n        const unitPriceCents = parsePriceToCents((variant && variant.price) || (product && product.price) || 0);\n        const discountedUnitCents = Math.max(0, unitPriceCents - Math.round((unitPriceCents * discountPercent) / 100));\n        const lineSubtotalCents = unitPriceCents * lineItem.quantity;\n        const lineTotalCents = discountedUnitCents * lineItem.quantity;\n        subtotalCents += lineSubtotalCents;\n\n        const card = document.createElement('article');\n        card.className = 'evq-results__product-card';\n        card.innerHTML = `\n          <div class=\"evq-results__product-media\">\n            ${\n              imageUrl\n                ? `<img src=\"${escapeHtml(imageUrl)}\" alt=\"${escapeHtml(productTitle)}\" loading=\"lazy\" />`\n                : '<div class=\"evq-results__product-media-placeholder\">Cadence</div>'\n            }\n          </div>\n          <div class=\"evq-results__product-content\">\n            <p class=\"evq-results__product-kicker\">${escapeHtml(variantTitle)}</p>\n            <h4 class=\"evq-results__product-title\">${escapeHtml(productTitle)}</h4>\n            <p class=\"evq-results__product-benefit\">Supports ${escapeHtml(\n              personalization.primaryIssue.label\n            )} while improving sleep and stress resilience.</p>\n            <details class=\"evq-results__accordion\">\n              <summary>Clinical Research & Reviews</summary>\n              <div>\n                <p>Powered by clinically-dosed Affron\u00AE, Chelamax\u00AE, and L-Theanine with verified customer outcomes.</p>\n                <p>Rated 4.8 stars across verified reviews for mood, sleep depth, and stress recovery support.</p>\n              </div>\n            </details>\n            <div class=\"evq-results__product-footer\">\n              <div class=\"evq-results__price\">\n                <span class=\"evq-results__price-original\">${formatCurrencyCents(lineSubtotalCents, currency)}</span>\n                <span class=\"evq-results__price-discounted\">${formatCurrencyCents(lineTotalCents, currency)}</span>\n              </div>\n              <div class=\"evq-results__qty\" data-evq-qty-index=\"${index}\">\n                <button type=\"button\" data-qty-action=\"minus\" aria-label=\"Decrease quantity\">\u2212</button>\n                <input type=\"number\" min=\"1\" max=\"6\" step=\"1\" value=\"${lineItem.quantity}\" inputmode=\"numeric\" />\n                <button type=\"button\" data-qty-action=\"plus\" aria-label=\"Increase quantity\">+</button>\n              </div>\n            </div>\n          </div>\n        `;\n        productListNode.appendChild(card);\n      });\n\n      const discountCents = Math.round((subtotalCents * discountPercent) / 100);\n      const totalCents = Math.max(0, subtotalCents - discountCents);\n      if (summarySubtotalNode) {\n        summarySubtotalNode.textContent = formatCurrencyCents(subtotalCents, currency);\n      }\n      if (summaryDiscountNode) {\n        summaryDiscountNode.textContent = `-${formatCurrencyCents(discountCents, currency)}`;\n      }\n      if (summaryTotalNode) {\n        summaryTotalNode.textContent = formatCurrencyCents(totalCents, currency);\n      }\n\n      productListNode.querySelectorAll('[data-evq-qty-index]').forEach((qtyWrap) => {\n        const index = Number(qtyWrap.getAttribute('data-evq-qty-index'));\n        const input = qtyWrap.querySelector('input');\n        const minus = qtyWrap.querySelector('[data-qty-action=\"minus\"]');\n        const plus = qtyWrap.querySelector('[data-qty-action=\"plus\"]');\n\n        const applyQuantity = (nextValue) => {\n          const currentItems = [...state.resultsLineItems];\n          if (!currentItems[index]) {\n            return;\n          }\n          const quantity = Math.max(1, Math.min(6, Math.floor(Number(nextValue) || 1)));\n          currentItems[index] = {\n            ...currentItems[index],\n            quantity,\n          };\n          state.resultsLineItems = normalizeCartItems(currentItems);\n          renderProductsAndSummary(product);\n        };\n\n        if (minus) {\n          minus.addEventListener('click', () => {\n            applyQuantity((state.resultsLineItems[index] && state.resultsLineItems[index].quantity) - 1);\n          });\n        }\n        if (plus) {\n          plus.addEventListener('click', () => {\n            applyQuantity((state.resultsLineItems[index] && state.resultsLineItems[index].quantity) + 1);\n          });\n        }\n        if (input) {\n          input.addEventListener('change', () => {\n            applyQuantity(input.value);\n          });\n        }\n      });\n    };\n\n    renderProductsAndSummary(state.cadenceProduct);\n\n    loadCadenceProduct().then((product) => {\n      if (state.currentRoute !== 'results') {\n        return;\n      }\n      const firstVariant = product && Array.isArray(product.variants) ? product.variants[0] : null;\n      if (state.variantFallbackId === undefined) {\n        state.variantFallbackId = firstVariant && firstVariant.id ? Number(firstVariant.id) : null;\n      }\n      renderProductsAndSummary(product);\n    });\n\n    startResultsTimer();\n  }\n\n  function syncRouteChrome(route) {\n    const shouldHideQuizChrome = isRecommendationsMode;\n\n    root.dataset.evqRoute = route;\n    if (header) {\n      header.classList.toggle('evq-hidden', shouldHideQuizChrome);\n    }\n    if (navWrap) {\n      navWrap.classList.toggle('evq-hidden', shouldHideQuizChrome);\n    }\n    content.classList.toggle('evq-main--start', false);\n  }\n\n  function isValidCurrentStep() {\n    const route = state.currentRoute;\n\n    if (route === 'q12') {\n      if (!(state.lead.firstName || '').trim()) {\n        return false;\n      }\n\n      const demographics = getDemographics();\n\n      if (!demographics.age || !demographics.gender) {\n        return false;\n      }\n\n      if (demographics.gender === 'gender_female') {\n        return (demographics.femaleConditions || []).length > 0;\n      }\n\n      return true;\n    }\n\n    if (route === 'results') {\n      return true;\n    }\n\n    return ensureRouteAnswer(route).length > 0;\n  }\n\n  function syncNavState() {\n    if (!backButton || !nextButton) {\n      return;\n    }\n\n    const route = state.currentRoute;\n    const personalization = route === 'results' ? state.personalization || getPersonalization() : null;\n    const timerExpired = route === 'results' ? getCountdownSnapshot().expired : false;\n    const shouldHideBackButton = route === 'q1';\n    backButton.classList.toggle('evq-hidden', shouldHideBackButton);\n\n    if (!shouldHideBackButton) {\n      backButton.innerHTML = iconBack;\n      backButton.setAttribute('aria-label', 'Go to previous question');\n    }\n\n    nextButton.innerHTML = `CONTINUE ${iconNext}`;\n\n    if (route === 'q12') {\n      nextButton.innerHTML = `UNLOCK MY RESULTS ${iconNext}`;\n    }\n\n    if (route === 'results') {\n      if (personalization && personalization.safetyGate) {\n        nextButton.innerHTML = 'CONSULT YOUR DOCTOR FIRST';\n      } else {\n        const activeCode = getActiveDiscountCode();\n        const ctaLabel = activeCode ? `OPEN CART + ${escapeHtml(activeCode)}` : 'OPEN CART';\n        nextButton.innerHTML = `${ctaLabel} ${iconNext}`;\n      }\n    }\n\n    const resultsBlocked = route === 'results' && personalization && personalization.safetyGate;\n    nextButton.disabled = !isValidCurrentStep() || state.submitting || state.cartBusy || resultsBlocked;\n  }\n\n  function ensureResultsStateHydrated() {\n    if (state.personalization) {\n      return true;\n    }\n\n    if (hasCollectedQuizData()) {\n      state.personalization = buildPersonalizationEngine();\n      persistSessionSnapshot(state.personalization);\n      return true;\n    }\n\n    const hydratedSession = hydrateStateFromSessionSnapshot();\n    if (hydratedSession) {\n      if (!state.personalization && hasCollectedQuizData()) {\n        state.personalization = buildPersonalizationEngine();\n      }\n      if (state.personalization) {\n        persistSessionSnapshot(state.personalization);\n        return true;\n      }\n    }\n\n    const hydratedPending = hydrateStateFromPendingAuthSnapshot();\n    if (hydratedPending) {\n      if (!state.personalization && hasCollectedQuizData()) {\n        state.personalization = buildPersonalizationEngine();\n      }\n      if (state.personalization) {\n        persistSessionSnapshot(state.personalization);\n        return true;\n      }\n    }\n\n    const hydratedCustomer = hydrateStateFromCustomerMetafields();\n    if (hydratedCustomer && state.personalization) {\n      persistSessionSnapshot(state.personalization);\n      return true;\n    }\n\n    return false;\n  }\n\n  function render() {\n    const route = state.currentRoute;\n    syncRuntimeHostVisibility();\n    if (!isRecommendationsMode && route === 'results') {\n      setRoute('q1', { replace: true });\n      return;\n    }\n    const shouldAnimateStepTransition = state.lastRenderedRoute !== null && state.lastRenderedRoute !== route;\n    if (route === 'results' && !ensureResultsStateHydrated()) {\n      if (isThemeEditor || IS_DEV_PREVIEW) {\n        state.personalization = buildPersonalizationEngine({ forceProfileKey: IS_DEV_PREVIEW ? DEV_PREVIEW_PROFILE : undefined });\n      } else if (isRecommendationsMode) {\n        window.location.href = quizBasePath || '/pages/cadence-quiz';\n      } else {\n        setRoute('q1', { replace: true });\n      }\n      if (!state.personalization) {\n        return;\n      }\n    }\n    if (isRecommendationsMode && route !== 'results') {\n      setRoute('results', { replace: true });\n      return;\n    }\n    syncRouteChrome(route);\n    content.classList.toggle('evq-main--route-transition', shouldAnimateStepTransition);\n\n    clearElement(content);\n    setProgressUI(route);\n\n    if (route !== 'results') {\n      stopResultsTimer();\n      state.personalization = null;\n      state.resultsLineItems = [];\n      clearSessionSnapshot();\n    }\n\n    if (stepByRoute[route]) {\n      renderQuestionStep(stepByRoute[route]);\n    } else if (route === 'q12') {\n      renderDemographicsStep();\n    } else {\n      if (shouldUseExternalRecommendationsLayout()) {\n        renderExternalRecommendationsStep();\n      } else {\n        renderResultsStep();\n      }\n    }\n\n    syncNavState();\n    state.lastRenderedRoute = route;\n  }\n\n  async function handleContinue() {\n    const route = state.currentRoute;\n\n    if (!isValidCurrentStep()) {\n      syncNavState();\n      return;\n    }\n\n    if (route === 'results') {\n      const personalization = getPersonalization();\n      if (personalization.safetyGate) {\n        return;\n      }\n\n      await handleCartRedirection(personalization);\n      return;\n    }\n\n    if (route === 'q12') {\n      state.submitting = true;\n      syncNavState();\n\n      try {\n        const finalPersonalization = getPersonalization();\n        persistSessionSnapshot(finalPersonalization);\n\n        queueTrackEvent('QUIZ_COMPLETED', {\n          route: 'q12',\n          questionKey: 'q12',\n          answerIds: getDemographicAnswerIds(),\n          completed: true,\n        });\n\n        if (state.customer.loggedIn) {\n          await syncAuthenticatedResults();\n          await syncQuizCompletion({\n            personalization: finalPersonalization,\n            metadata: { flow: 'authenticated_q12' },\n          });\n        } else {\n          await syncQuizCompletion({\n            personalization: finalPersonalization,\n            metadata: { flow: 'direct_auth_required' },\n          });\n          persistPendingAuthSnapshot('q12');\n        }\n      } finally {\n        state.submitting = false;\n      }\n\n      if (state.customer.loggedIn) {\n        window.location.href = RECOMMENDATIONS_PATH || '/pages/recommendations';\n      } else {\n        window.location.href = buildAccountLoginUrl({ source: 'evolance_quiz' });\n      }\n\n      return;\n    }\n\n    const next = getNextRoute(route);\n    if (!next) {\n      return;\n    }\n\n    if (route === 'q1') {\n      queueTrackEvent('ANSWER_SELECTED', {\n        route: 'q1',\n        questionKey: 'q1',\n        answerIds: getAnswerArray('q1'),\n        metadata: {\n          question_completed: true,\n        },\n      });\n\n      setRoute(next, { trackPageView: false });\n      return;\n    }\n\n    setRoute(next);\n  }\n\n  function handleBack() {\n    const route = state.currentRoute;\n    if (route === 'q1') {\n      return;\n    }\n    const previous = getPreviousRoute(route);\n\n    if (!previous) {\n      window.location.href = isRecommendationsMode ? ACCOUNT_URL : '/';\n      return;\n    }\n\n    setRoute(previous);\n  }\n\n  function isGoogleAuthReturn() {\n    return IS_GOOGLE_AUTH_RETURN;\n  }\n\n  async function runRecommendationsPostAuthSync() {\n    if (!isRecommendationsMode || !state.customer.loggedIn) {\n      return;\n    }\n\n    const hasPending = Boolean(loadPendingAuthSnapshot());\n    const shouldSync = isGoogleAuthReturn() || IS_CUSTOMER_POSTED_RETURN || hasPending;\n    if (!shouldSync) {\n      return;\n    }\n\n    if (!IS_CUSTOMER_POSTED_RETURN && hasPostAuthSyncCompleted()) {\n      return;\n    }\n\n    if (!state.personalization) {\n      const hydrated =\n        hydrateStateFromPendingAuthSnapshot() ||\n        hydrateStateFromSessionSnapshot() ||\n        hydrateStateFromCustomerMetafields();\n\n      if (!hydrated && hasCollectedQuizData()) {\n        state.personalization = buildPersonalizationEngine();\n      }\n    }\n\n    state.submitting = true;\n    syncNavState();\n\n    try {\n      const synced = await syncAuthenticatedResults();\n      if (!synced) {\n        return;\n      }\n\n      markPostAuthSyncCompleted();\n      clearPendingAuthSnapshot();\n      if ((isGoogleAuthReturn() || IS_CUSTOMER_POSTED_RETURN) && !isThemeEditor) {\n        const cleanUrl = RECOMMENDATIONS_PATH || '/pages/recommendations';\n        window.history.replaceState({ evq: true, route: 'results' }, '', cleanUrl);\n      }\n    } finally {\n      state.submitting = false;\n      syncNavState();\n    }\n  }\n\n  if (backButton) {\n    backButton.addEventListener('click', handleBack);\n  }\n  if (nextButton) {\n    nextButton.addEventListener('click', () => {\n      handleContinue();\n    });\n  }\n\n  window.addEventListener('popstate', () => {\n    state.currentRoute = getRouteFromLocation();\n    render();\n  });\n\n  async function initializeQuizApp() {\n    syncRuntimeHostVisibility();\n    if (isRecommendationsMode && !state.customer.loggedIn && !isThemeEditor && !IS_DEV_PREVIEW) {\n      window.location.href = quizBasePath || '/pages/cadence-quiz';\n      return;\n    }\n\n    if (IS_DEV_PREVIEW && isRecommendationsMode) {\n      state.customer.loggedIn = true;\n      state.customer.firstName = 'Preview';\n      state.customer.email = 'preview@dev.local';\n      state.customer.hasProfileType = true;\n      state.customer.metafields.profileType = DEV_PREVIEW_PROFILE;\n      state.customer.metafields.quizProfile = DEV_PREVIEW_PROFILE;\n      state.customer.metafields.bundleIds = '[\"' + PRODUCT_HANDLE + '\"]';\n      state.customer.metafields.recommendedBundle = '[\"' + PRODUCT_HANDLE + '\"]';\n      state.customer.prefillState = {\n        profile_type: DEV_PREVIEW_PROFILE,\n        bundle_ids: '[\"' + PRODUCT_HANDLE + '\"]',\n        specialist_name: 'Xeniya',\n        last_quiz_date: new Date().toISOString().slice(0, 10),\n        quiz_answers: '',\n      };\n      console.info('[EVQ] Dev preview mode \u2014 profile:', DEV_PREVIEW_PROFILE);\n    }\n\n    ensureTrackingSessionId();\n    hydrateLeadFromCustomer();\n    window.EVOLANCE_QUIZ_ROUTE_MAP = QUESTION_ROUTE_MAP;\n\n    if (isRecommendationsMode && !IS_DEV_PREVIEW) {\n      /* Safety timeout: reveal page after 8s even if async calls hang */\n      var loadingFallbackTimer = setTimeout(function () {\n        document.body.classList.add('evr-v2-loaded');\n        document.body.classList.add('evr-v3-loaded');\n      }, 8000);\n\n      await runRecommendationsPostAuthSync();\n      await loadRecommendationsFromProxy();\n      syncRuntimeHostVisibility();\n\n      clearTimeout(loadingFallbackTimer);\n    }\n\n    setRoute(getRouteFromLocation(), { replace: true, trackPageView: false });\n  }\n\n  initializeQuizApp();\n})();\n"],
  "mappings": "CAAC,IAAM,CACL,MAAM,KAAO,SAAS,cAAc,iBAAiB,EACrD,GAAI,CAAC,KACH,OAGF,MAAM,cAAgB,CAAC,MAAO,WAAa,CACzC,MAAM,KAAO,OAAS,UAAY,IAAI,KAAK,EAC3C,OAAK,KAIa,IAAI,WAAW,GAAG,EAAI,IAAM,IAAI,GAAG,IACpC,QAAQ,OAAQ,EAAE,EAAE,YAAY,EAJxC,EAKX,EAEM,UAAY,OAAO,SAAS,UAAY,IAAI,YAAY,EACxD,oBAAsB,IAAI,gBAAgB,OAAO,SAAS,MAAM,EAChE,mBAAqB,kBACrB,sBAAwB,oBAAoB,IAAI,UAAU,IAAM,SAChE,qBAAuB,oBAAoB,IAAI,iBAAiB,GAAK,IAAI,YAAY,EACrF,0BAA4B,sBAAwB,QAAU,sBAAwB,IACtF,eAAiB,oBAAoB,IAAI,SAAS,IAAM,IACxD,oBAAsB,oBAAoB,IAAI,SAAS,GAAK,gBAC5D,mBAAqB,KAAK,QAAQ,SAAW,IAAI,KAAK,EAAE,YAAY,EACpE,gBAAkB,cAAc,KAAK,QAAQ,cAAe,qBAAqB,EACjF,iBAAmB,cACnB,qBAAuB,cAAc,KAAK,QAAQ,oBAAqB,wBAAwB,EAC/F,gBAAkB,MAAM,KAAK,IAAI,IAAI,CAAC,gBAAiB,gBAAgB,EAAE,OAAO,OA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