This is a submission for the
Code
You can explore the full React architecture, state management lifecycle, and component scripts in my repository here:
[View GitHub Repository]
How I Built It
The application is architected entirely using React 19 and bundled via Vite for optimized fast-refresh compilation.
State & Lifecycle Management: Built using robust React core hooks (useState,useEffect,useRef). I utilized refs to cleanly synchronize the independent 1-second countdown interval with the 6-second cosmic prompt rotation cadence.
Resilient Fallback Design: To prevent the user experience from degrading due to live browser network restrictions or client-side CORS barriers on public hosts, I engineered a structural fail-safe array containing 16 unique, pre-composed light/shadow riddles. If a backend request encounters an origin block, the application gracefully flags the catch-block and continuously serves random variations to guarantee 100% gameplay uptime.
UI Design System: Designed with a custom inline layout mimicking a modern dark-mode terminal framework. It utilizes stark blue-slate variations (#0F172A,#1E293B) combined with glowing neon indicators to create a highly responsive, atmospheric aesthetic.
Prize Category
Best Google AI Usage
This project is configured directly with the official @google/genai SDK and utilizes the Gemini 2.5-Flash model. In local runtime environments, the system completely bypasses hardcoded text arrays to execute live zero-shot prompt requests, treating Gemini as a dynamic "Celestial Narrator" that generates completely unique, poetic statements about light or dark alignments on the fly.
SOCIAL SHARE CARD GENERATOR