"use client"; import { Canvas, useFrame, useThree } from "@react-three/fiber"; import { useRef, useMemo } from "react"; import * as THREE from "three"; import { Float, PerspectiveCamera } from "@react-three/drei"; function DNAParticles() { const points = useMemo(() => { const p = []; const count = 120; // Reduced density for simplicity const radius = 2.5; const height = 20; for (let i = 0; i < count; i++) { const angle = (i / count) * Math.PI * 6; const x = Math.cos(angle) * radius; const y = (i / count) * height - height / 2; const z = Math.sin(angle) * radius; // Simple Monochromatic Strands p.push({ pos: new THREE.Vector3(x, y, z), color: "#ffffff" }); p.push({ pos: new THREE.Vector3(-x, y, -z), color: "#71717a" }); // Zinc-400 equivalent // Minimalist Rungs if (i % 6 === 0) { const rungPoints = 6; for (let j = 1; j < rungPoints; j++) { const t = j / rungPoints; p.push({ pos: new THREE.Vector3(x * (1 - 2 * t), y, z * (1 - 2 * t)), color: "#3f3f46" // Zinc-600 equivalent }); } } } return p; }, []); const groupRef = useRef(null); const { mouse } = useThree(); useFrame(() => { if (groupRef.current) { groupRef.current.rotation.y += 0.0015; // Slower, more professional rotation groupRef.current.rotation.x = THREE.MathUtils.lerp(groupRef.current.rotation.x, mouse.y * 0.1, 0.05); groupRef.current.rotation.z = THREE.MathUtils.lerp(groupRef.current.rotation.z, -mouse.x * 0.05, 0.05); } }); return ( {points.map((p, i) => ( ))} ); } function GridOverlay() { return ( ); } export default function DNAHeroBackground() { return (
); }