SuperShipped // Item 13

SNIPPET VIEW

Live Render

HTML CODE

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Nexus Search | Next Gen Discovery</title>
    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap" rel="stylesheet">
    <style>
        :root {
            --bg-color: #ffffff;
            --text-primary: #121212;
            --accent-red: #ff4d4d;
            --accent-blue: #2d7ff9;
            --accent-green: #00c853;
            --accent-yellow: #ffc107;
        }

        body, html {
            margin: 0;
            padding: 0;
            width: 100%;
            height: 100%;
            background-color: var(--bg-color);
            font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
            overflow: hidden;
            display: flex;
            justify-content: center;
            align-items: center;
        }

        #container {
            position: relative;
            width: 1000px;
            height: 600px;
            display: flex;
            flex-direction: column;
            justify-content: center;
            pointer-events: none;
            z-index: 10;
        }

        .text-layer {
            color: var(--text-primary);
            line-height: 0.95;
            padding-left: 50px;
        }

        .line {
            display: flex;
            align-items: center;
            font-size: 115px;
            font-weight: 700;
            letter-spacing: -4px;
            white-space: nowrap;
            text-transform: capitalize;
        }

        /* Startup Search Bar Style */
        .search-pill {
            display: inline-flex;
            align-items: center;
            border: 3px solid var(--text-primary);
            border-radius: 100px;
            height: 85px;
            width: 240px;
            margin-right: 30px;
            background: transparent;
            position: relative;
            overflow: hidden;
        }

        .search-pill::after {
            content: '';
            position: absolute;
            left: 35px;
            width: 15px;
            height: 15px;
            border: 3px solid var(--text-primary);
            border-radius: 50%;
        }
        
        .search-pill::before {
            content: '';
            position: absolute;
            left: 50px;
            top: 50px;
            width: 8px;
            height: 3px;
            background: var(--text-primary);
            transform: rotate(45deg);
        }

        #canvas-container {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: 1;
        }

        canvas {
            display: block;
        }
    </style>
</head>
<body>

    <div id="canvas-container"></div>

    <div id="container">
        <div class="text-layer">
            <div class="line">Nexus Search</div>
            <div class="line">
                <div class="search-pill"></div>
                Redefined
            </div>
            <div class="line">Neural</div>
            <div class="line">Discovery</div>
        </div>
    </div>

    <script src="https://cdnjs.cloudflare.com/ajax/libs/three.js/0.160.0/three.min.js"></script>

    <script>
        // WebGL Setup
        const container = document.getElementById('canvas-container');
        const scene = new THREE.Scene();
        const camera = new THREE.PerspectiveCamera(40, window.innerWidth / window.innerHeight, 0.1, 1000);
        const renderer = new THREE.WebGLRenderer({ antialias: true, alpha: true });
        
        renderer.setSize(window.innerWidth, window.innerHeight);
        renderer.setPixelRatio(Math.min(window.devicePixelRatio, 2));
        container.appendChild(renderer.domElement);

        // Lighting - High contrast for a startup feel
        const ambientLight = new THREE.AmbientLight(0xffffff, 0.8);
        scene.add(ambientLight);
        
        const directionalLight = new THREE.DirectionalLight(0xffffff, 2);
        directionalLight.position.set(2, 4, 5);
        scene.add(directionalLight);

        // Materials
        const materials = [
            new THREE.MeshStandardMaterial({ color: 0xff4d4d, roughness: 0.3, metalness: 0.2 }), // Red
            new THREE.MeshStandardMaterial({ color: 0x2d7ff9, roughness: 0.3, metalness: 0.2 }), // Blue
            new THREE.MeshStandardMaterial({ color: 0x00c853, roughness: 0.3, metalness: 0.2 }), // Green
            new THREE.MeshStandardMaterial({ color: 0xffc107, roughness: 0.3, metalness: 0.2 })  // Yellow
        ];

        // Geometries
        const geos = [
            new THREE.IcosahedronGeometry(0.55, 0), // Sharp Red Hex-sphere
            new THREE.BoxGeometry(0.7, 1.2, 0.5),   // Blue Pillar
            new THREE.TorusGeometry(0.4, 0.2, 16, 32), // Green Ring (Neural link)
            new THREE.CapsuleGeometry(0.4, 0.9, 10, 20) // Yellow Core
        ];

        const meshes = [];
        const xPositions = [-0.4, 1.0, 2.5, 4.3]; // Adjusted for the longer words

        geos.forEach((geo, i) => {
            const mesh = new THREE.Mesh(geo, materials[i]);
            mesh.position.set(xPositions[i], -1.3, 0);
            scene.add(mesh);
            meshes.push(mesh);
        });

        // Specific rotations
        meshes[2].rotation.x = Math.PI / 2; // Flip ring
        meshes[3].rotation.z = Math.PI / 2; // Flip capsule

        camera.position.z = 8;
        camera.position.x = 1.5; // Offset camera to align with right-leaning text

        // Animation
        const clock = new THREE.Clock();

        function animate() {
            const elapsedTime = clock.getElapsedTime();
            
            meshes.forEach((mesh, i) => {
                // Individualized rotation speeds
                mesh.rotation.y += 0.01 * (i + 1);
                mesh.rotation.x += 0.005;
                
                // Floating movement
                mesh.position.y = -1.3 + Math.sin(elapsedTime + i) * 0.1;
            });

            renderer.render(scene, camera);
            requestAnimationFrame(animate);
        }

        // Handle Resize
        window.addEventListener('resize', () => {
            camera.aspect = window.innerWidth / window.innerHeight;
            camera.updateProjectionMatrix();
            renderer.setSize(window.innerWidth, window.innerHeight);
        });

        animate();
    </script>
</body>
</html>

AI PROMPT

Create a "Nexus Search | Next Gen Discovery" component. Use Three.js for 3D WebGL rendering, Inter font. Use WebGL for GPU-accelerated rendering. Color palette: #ffffff, #121212, #ff4d4d, #2d7ff9, #00c853, #ffc107. Layout: Flexbox. Interactivity: continuous animation loop, responsive resize handling.