import { useState } from "react" import { AnimatePresence, motion } from "motion/react" import { Bot, Check, Monitor, Smartphone, Sparkles, type LucideIcon } from "lucide-react" import { BrowserFrame, PhoneFrame } from "@/components/ui/device-mockups" import { Section } from "@/components/ui/section" import { SectionHeading } from "@/components/ui/section-heading" import { Typography } from "@/components/ui/typography" /** 3단계 이용 가이드 — 탭 전환식 GIF 시연 (데스크톱/모바일 목업). */ export function HowItWorksDemo() { const [activeKey, setActiveKey] = useState("create") const activeTab = DEMO_TABS.find((tab) => tab.key === activeKey)! return (
{/* 탭 스위치 */}
{DEMO_TABS.map((tab) => ( ))}
{/* 좌: 단계 설명 */}
{activeTab.badge.label}
{activeTab.heading} {activeTab.paragraphs.map((paragraph, idx) => ( {paragraph} ))}
{activeTab.checks.map((check, idx) => (
{check}
))}
{/* 우: 디바이스 목업 + GIF */}
{activeTab.mockup === "browser" ? ( ) : ( )}
) } /** GIF 로드 실패 시(파일 미배치) 배치 안내 폴백을 보여주는 슬롯. */ function GifSlot({ tab }: { tab: DemoTab }) { const [error, setError] = useState(false) if (error) { const phone = tab.mockup === "phone" return (

{tab.fallback.title}

프로젝트 루트의{" "} public{tab.gif} 경로에{" "} {tab.fallback.hint}

) } return ( {tab.gifAlt} setError(true)} referrerPolicy="no-referrer" className="w-full h-full object-cover" /> ) } type DemoTab = { key: "create" | "negotiate" | "result" tabIcon: LucideIcon tabLabel: string badge: { icon: LucideIcon; label: string; className: string } checkClassName: string heading: React.ReactNode paragraphs: React.ReactNode[] checks: string[] mockup: "browser" | "phone" url?: string gif: string gifAlt: string fallback: { icon: LucideIcon iconWrapClassName: string codeClassName: string title: string hint: string } } const DEMO_TABS: DemoTab[] = [ { key: "create", tabIcon: Monitor, tabLabel: "1단계: AI 견적 & 가이드 수립", badge: { icon: Sparkles, label: "구매 관리자 콘솔 (웹)", className: "bg-primary-soft text-primary" }, checkClassName: "text-primary", heading: ( <> 엑셀 등록만으로 끝나는
초정밀 가이드라인 자율 수립 ), paragraphs: [ <> 품목명과 시중 시장 가격을 입력하면, negotium이 인터넷 최저가(LPS) 데이터를 상시 반영해{" "} 시장 바닥값을 쥐고 시작합니다. , <> 시중 최저가와 매입 이력, 목표 마진율을 종합해 — 사내 마진은 지키면서 공급사가 받아들일 수 있는{" "} 최적 목표 단가(Target Price)를 자동으로 잡아줍니다. , ], checks: ["인터넷 최저가(LPS) 시세 상시 반영", "마진을 지키는 최적 목표 단가 자동 완성"], mockup: "browser", url: "https://console.negotium.ai/estimates/new", gif: "/gifs/quote_generation.gif", gifAlt: "견적 생성 가이드라인 수립 시연", fallback: { icon: Monitor, iconWrapClassName: "w-14 h-14 bg-primary-soft rounded-2xl text-primary", codeClassName: "bg-white text-primary", title: "견적 생성 시연 GIF 공간", hint: "실제 기동 GIF를 배치하시면 이 영역에 자동으로 재생됩니다.", }, }, { key: "negotiate", tabIcon: Smartphone, tabLabel: "2단계: AI 자동 밀당 협상", badge: { icon: Bot, label: "협력사 협상 포털 (웹·모바일)", className: "bg-emerald-50 border border-emerald-100 text-positive" }, checkClassName: "text-emerald-500", heading: ( <> 공급사는 설치 없이
웹·모바일 어디서든 협상 ), paragraphs: [ <> 각 파트너사 담당자는 초대 메일로 비대면 협상 모바일 포털에 접속해, 언제든 단가를 조율합니다. , <> 단순 마진 깎기가 아닙니다. 봇은 준비된 협상 카드를 상황에 맞게 꺼내, 파트너사의 자발적인 마진 타협을 부드럽게 이끌어냅니다. , ], checks: ["1:1 비대면 협상 포털 제공", "불필요한 실랑이를 예방하여 파트너십 보호"], mockup: "phone", gif: "/gifs/negotiation.gif", gifAlt: "AI 모바일 자동 협상 시연", fallback: { icon: Smartphone, iconWrapClassName: "w-12 h-12 bg-emerald-50 border border-emerald-100 rounded-full text-emerald-500", codeClassName: "bg-fill text-positive", title: "협상 시연 GIF 공간", hint: "실제 모바일 협상 시뮬레이션 GIF를 배치해 주세요.", }, }, { key: "result", tabIcon: Monitor, tabLabel: "3단계: AI 협상 결과 확인", badge: { icon: Monitor, label: "구매 관리자 콘솔 (웹)", className: "bg-purple-50 border border-purple-100 text-purple-600" }, checkClassName: "text-purple-500", heading: ( <> 자동 분석 및 타결 보고서
대시보드에서 성과 확인 ), paragraphs: [ <> 협상이 끝나면, 파트너사별 최종 타결 단가와 절감액 리포트를 대시보드에서 즉시 확인합니다. , <> 어떤 제안에 단가가 움직였는지 협상 전 과정이 로그로 남고, 공급사별 투찰가를 한눈에 비교해 계약을 검토할 수 있습니다. , ], checks: ["낙찰 결과·절감액 자동 집계", "누적 절감액·협상 통계 대시보드"], mockup: "browser", url: "https://console.negotium.ai/dashboard/reports", gif: "/gifs/negotiation_result.gif", gifAlt: "협상 결과 분석 대시보드 시연", fallback: { icon: Monitor, iconWrapClassName: "w-14 h-14 bg-purple-50 rounded-2xl text-purple-600", codeClassName: "bg-white text-purple-600", title: "협상 결과 확인 시연 GIF 공간", hint: "결과 보고 대시보드 기동 GIF를 배치하시면 이 영역에 자동으로 재생됩니다.", }, }, ]