"use client"; import { motion } from "framer-motion"; import { useState } from "react"; export default function ObservatoryBackground() { const [stars] = useState(() => Array.from({ length: 120 }).map((_, i) => ({ id: i, left: `${Math.random() * 100}%`, top: `${Math.random() * 70}%`, size: Math.random() * 2 + 1, duration: 3 + Math.random() * 4, delay: Math.random() * 5, })) ); const [skyline] = useState(() => { const colors = ['#0b1420ff', '#0d1015ff', '#020408']; const neons = ['#22d3ee', '#fb7185', '#60a5fa', '#ffffff', '#c084fc']; return Array.from({ length: 65 }).map((_, i) => ({ id: i, width: `${1.2 + Math.random() * 2.5}%`, height: `${8 + Math.random() * 30}%`, color: colors[i % colors.length], neon: neons[Math.floor(Math.random() * neons.length)], hasWindow: Math.random() > 0.4, })); }); return (
{stars.map((star) => ( ))}
{skyline.map((b) => (
))}
); }