🤖 퍼널 설계 깨루봇

AI 파일 분석으로 마케팅 퍼널을 자동 설계하세요

0/8 단계 완료

진행 단계

${businessName}

${coreMessage}

🎁 ${specialOffer}

${userAnswers.targetCustomers || '고객'}을 위한 솔루션

🥉 ${userAnswers.lowPriceProductName || '기본 상품'}

${userAnswers.lowPriceProductPrice || '가격 문의'}

${userAnswers.lowPriceProductValue || '기본 서비스 제공'}

인기

🥈 ${userAnswers.mediumPriceProductName || '스탠다드 상품'}

${userAnswers.mediumPriceProductPrice || '가격 문의'}

${userAnswers.mediumPriceProductValue || '표준 서비스 제공'}

💎 ${userAnswers.highPriceProductName || '프리미엄 상품'}

${userAnswers.highPriceProductPrice || '가격 문의'}

${userAnswers.highPriceProductValue || '프리미엄 서비스 제공'}

지금 바로 시작하세요!

`; // 새 창에서 미리보기 const previewWindow = window.open('', 'landingPagePreview', 'width=1200,height=800,scrollbars=yes'); if (previewWindow) { previewWindow.document.write(html); previewWindow.document.close(); setTimeout(() => { if (confirm('생성된 랜딩페이지를 다운로드하시겠습니까?')) { const blob = new Blob([html], { type: 'text/html' }); const url = URL.createObjectURL(blob); const link = document.createElement('a'); link.href = url; link.download = `${businessName}_랜딩페이지.html`; document.body.appendChild(link); link.click(); document.body.removeChild(link); URL.revokeObjectURL(url); } }, 1000); } else { alert('팝업이 차단되었습니다. 팝업 허용 후 다시 시도해주세요.'); } } // 다시 시작하기 function startOver() { if (confirm('정말로 새로 시작하시겠습니까? 현재 입력한 모든 내용이 삭제됩니다.')) { location.reload(); } } // 파일 드래그 앤 드롭 설정 (1단계에서만 사용) function setupFileDropArea() { const dropArea = document.getElementById('fileDropArea'); const fileInput = document.getElementById('fileInput'); if (!dropArea || !fileInput) return; ['dragenter', 'dragover', 'dragleave', 'drop'].forEach(eventName => { dropArea.addEventListener(eventName, preventDefaults, false); }); function preventDefaults(e) { e.preventDefault(); e.stopPropagation(); } ['dragenter', 'dragover'].forEach(eventName => { dropArea.addEventListener(eventName, () => dropArea.classList.add('drag-over'), false); }); ['dragleave', 'drop'].forEach(eventName => { dropArea.addEventListener(eventName, () => dropArea.classList.remove('drag-over'), false); }); dropArea.addEventListener('drop', handleDrop, false); fileInput.addEventListener('change', handleFiles, false); } function handleDrop(e) { const dt = e.dataTransfer; const files = dt.files; handleFiles({ target: { files: files } }); } function handleFiles(e) { const files = Array.from(e.target.files); if (files.length === 0) return; const maxSize = 10 * 1024 * 1024; const validFiles = files.filter(file => { if (file.size > maxSize) { alert(`${file.name} 파일이 10MB를 초과합니다.`); return false; } return true; }); if (validFiles.length === 0) return; uploadedFiles = [...uploadedFiles, ...validFiles]; displayUploadedFiles(); document.getElementById('analyzeBtn').disabled = false; } function displayUploadedFiles() { const fileList = document.getElementById('fileList'); const filesContainer = document.getElementById('uploadedFiles'); if (uploadedFiles.length === 0) { fileList.classList.add('hidden'); return; } fileList.classList.remove('hidden'); filesContainer.innerHTML = uploadedFiles.map((file, index) => `
📄

${file.name}

${Math.round(file.size / 1024)} KB

`).join(''); } function removeFile(index) { uploadedFiles.splice(index, 1); displayUploadedFiles(); if (uploadedFiles.length === 0) { document.getElementById('analyzeBtn').disabled = true; } } function startAIAnalysis() { if (uploadedFiles.length === 0) { alert('분석할 파일을 먼저 업로드해주세요.'); return; } const analyzeBtn = document.getElementById('analyzeBtn'); analyzeBtn.disabled = true; analyzeBtn.innerHTML = '🔄 AI 분석 중... (3초)'; setTimeout(() => { const fileNames = uploadedFiles.map(f => f.name.toLowerCase()).join(' '); analysisData = generateAnalysisResult(fileNames); displayAnalysisResult(analysisData); analyzeBtn.disabled = false; analyzeBtn.innerHTML = '🔍 AI로 자동 분석하기'; }, 3000); } function generateAnalysisResult(fileNames) { let businessField = '온라인 쇼핑몰/이커머스'; let businessName = '스마트비즈'; let targetCustomers = '25-45세 직장인, 온라인 쇼핑을 선호하는 소비자'; let monthlyRevenue = '월 500만원 ~ 1,000만원'; if (fileNames.includes('cafe') || fileNames.includes('카페') || fileNames.includes('coffee')) { businessField = '카페/음식점'; businessName = '아로마카페'; targetCustomers = '20-40대 직장인, 학생, 재택근무족'; monthlyRevenue = '월 1,000만원 ~ 3,000만원'; } else if (fileNames.includes('beauty') || fileNames.includes('뷰티')) { businessField = '미용/뷰티 서비스'; businessName = '글로우뷰티'; targetCustomers = '20-50대 여성, 외모 관리에 관심 많은 고객'; monthlyRevenue = '월 3,000만원 ~ 5,000만원'; } return { businessField, businessName, targetCustomers, monthlyRevenue }; } function displayAnalysisResult(data) { const resultDiv = document.getElementById('analysisResult'); const contentDiv = document.getElementById('analysisContent'); contentDiv.innerHTML = `
🎯 AI 분석 결과

🏢 비즈니스 분야: ${data.businessField}

🏷️ 브랜드명: ${data.businessName}

👥 타겟 고객: ${data.targetCustomers}

💰 예상 매출: ${data.monthlyRevenue}

`; resultDiv.classList.remove('hidden'); } function applyAnalysis() { if (!analysisData) return; document.getElementById('businessField').value = analysisData.businessField; document.getElementById('businessName').value = analysisData.businessName; document.getElementById('targetCustomers').value = analysisData.targetCustomers; document.getElementById('monthlyRevenue').value = analysisData.monthlyRevenue; document.getElementById('analysisResult').classList.add('hidden'); alert('✅ AI 분석 결과가 적용되었습니다!'); } function editAnalysis() { if (!analysisData) return; document.getElementById('businessField').value = analysisData.businessField; document.getElementById('businessName').value = analysisData.businessName; document.getElementById('targetCustomers').value = analysisData.targetCustomers; document.getElementById('monthlyRevenue').value = analysisData.monthlyRevenue; document.getElementById('analysisResult').classList.add('hidden'); alert('📝 AI 분석 결과가 입력 필드에 채워졌습니다. 원하는 내용으로 수정해주세요.'); } // 페이지 초기화 실행 document.addEventListener('DOMContentLoaded', initializePage);