"use client"; import { motion, AnimatePresence } from "framer-motion"; import { X, Download } from "lucide-react"; import { useTranslations } from "next-intl"; import Image from "next/image"; import { ProductViewer } from "./ProductViewer"; import type { Product } from "@/lib/products"; interface ProductModalProps { product: Product; onClose: () => void; } export function ProductModal({ product, onClose }: ProductModalProps) { const t = useTranslations(); return ( e.stopPropagation()} className="bg-white rounded-lg max-w-4xl w-full max-h-[90vh] overflow-y-auto" > {/* Header */}

{t(product.nameKey)}

{/* Content */}
{/* 3D Viewer / Gallery */}
{/* Image Thumbnails */} {product.images.length > 1 && (
{product.images.map((img, idx) => ( {`${t(product.nameKey)} ))}
)}
{/* Details */}

{product.longDescriptionKey ? t(product.longDescriptionKey) : t(product.shortDescriptionKey)}

{/* Specifications */}

Technical Specifications

{product.specs.map((spec, idx) => (
{spec.key}: {spec.value}
))}
{/* CTA Buttons */}
{t("contact.send")} Download Datasheet
); }