UI/UX Design Specification — Canonical 1:1 Cosmic Midnight Design System
Document ID: YPG-UX-003 | Index: docs/README.md
Canonical Visual Anchors: docs/UI/your_playgrpound_games_design_1.png & docs/UI/Yapay Zekâ Evrenini Oyna ve Yarat-1.png
Applies To: Web SSR Platform (http://localhost:9033 / https://www.yourplayground.games), Installable PWA, and Universal iOS & Android Phone/Tablet Applications
1. Visual Identity & Anti-Boilerplate Design Philosophy
YourPlayground.games rejects generic SaaS dashboard templates, boxed 3D glowing cube hero widgets, raw developer plumbing dumps in consumer headlines, and intrusive floating modals that obstruct active gameplay. Both the Web Platform and Mobile/Tablet Applications are locked 1:1 to the two canonical reference compositions in docs/UI/:
- Primary Cosmic Panorama Funnel (
your_playgrpound_games_design_1.png): Full-bleed atmospheric sky-island cosmos featuring an explorer and robotic companion, luminous cyan-to-violet-magenta gradient CTAs, 5-stat glass ribbon, 4-stepHow It Worksprogression,Featured Community Games16:9 carousel (Neon Odyssey,Aaru: Lost Realms,Cyber Breaker,Zero Gravity),Play More, Keep Creating!neon ticket banner, andReady to Build Your Game?cliffside moonrise horizon footer. - Companion AI Studio & Remix Variant (
Yapay Zekâ Evrenini Oyna ve Yarat-1.png):AI GAME STUDIO · PLAY · CREATE · SHAREeyebrow,Dream It. Generate It. / Play Your Universe.hero lockup, single-ribbon 4-step workflow (Write a Prompt -> Generate Game -> Watch an Ad -> Play & Share+100% Free Always),AI Generatedcard badges (Neon Odyssey,Skyrealms,Velocity Zero,Forest Whisper), and 5-column platform capability footer bar.
2. Chromatic Architecture & Surface Token System
2.1 Cosmic Midnight Surface Hierarchy & Luminous Gradients
| Semantic Role | Canonical Token | Hex / CSS Value | Perceptual & Spatial Function |
|---|---|---|---|
| Deep Cosmic Midnight Canvas | --bg-cosmic-0 | #080A1A (#080A18 / #07090E) | Primary infinite-depth viewport canvas and vignette blend target |
| Elevated Midnight Surface 1 | --bg-cosmic-1 | #11142B (#0E131F) | Card bases, header bar backdrop, and studio control containers |
| Violet-Tinted Surface 2 | --bg-cosmic-2 | #171B3A (#151D2E) | Hover states, active filter pills, and secondary glass panels |
| Violet Glassmorphism Fill | --surface-glass | rgba(17, 20, 43, 0.68) | Translucent glass cards over panoramic artwork (backdrop-filter: blur(18px) saturate(145%)) |
| Primary CTA Gradient | --grad-cta-primary | linear-gradient(90deg, #2CEEF8 0%, #7C5CFF 52%, #D946EF 100%) | Primary pill CTAs (Play Free, Create Your Game — Free, Create Your Game Now) |
| Hero Display Headline Gradient | --grad-text-universe | linear-gradient(92deg, #2CEEF8 0%, #6384FF 45%, #C850F2 82%, #D946EF 100%) | background-clip: text fill on "Play Your Universe." |
| Luminous Cyan Accent | --accent-cyan | #2CEEF8 / #10F5CC | Active All Games pill, lightning/infinity icons, focus rings (2px solid), HUD player highlights |
| Electric Violet Accent | --accent-violet | #7C5CFF / #8B5CF6 | Active Home navigation pill border glow, step connectors >>, AI Generated badges |
| Solar Magenta / Ticket Gold | --accent-magenta / --accent-gold | #D946EF / #FBBF24 | Gradient terminus, leaderboard trophy icon, and neon ad-ticket rim glow |
| In-Game Hazard Coral | --accent-coral | #FF5E36 | High-contrast arcade enemy/hazard accent inside playable Canvas/Phaser/Three stages |
| Text Hierarchy | --text-strong / --text-body / --text-muted | #F8FAFC / #CBD5E1 / #94A3B8 | WCAG AAA/AA contrast ratios (≥ 15.4:1, ≥ 11.2:1, ≥ 6.1:1 against #080A1A) |
2.2 Violet Glassmorphism & Dual Hairline Border Recipe
Every glass container (5-stat ribbon, 4-step cards, game cards, ticket banner, and modals) uses a two-layer border treatment to achieve crisp edge definition against dark nebulae without heavy opaque boxes:
.ypg-cosmic-glass {
background: linear-gradient(180deg, rgba(25, 30, 64, 0.72) 0%, rgba(12, 15, 34, 0.84) 100%);
backdrop-filter: blur(18px) saturate(145%);
-webkit-backdrop-filter: blur(18px) saturate(145%);
border: 1px solid rgba(139, 92, 246, 0.34);
box-shadow:
inset 0 1px 0 rgba(255, 255, 255, 0.10),
0 18px 44px rgba(3, 5, 16, 0.62);
border-radius: 18px;
}
3. Offline-Safe Typography Scale
To uphold strict CSP privacy and zero external Google Fonts network latency (tokens.css lines 49–53), typography uses deterministic geometric sans and monospace stacks with fluid clamp() scaling:
- Display Stack (
--font-display):'Space Grotesk', 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif - UI & Body Stack (
--font-sans):'Inter', 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif - Telemetry & Code Stack (
--font-mono):'JetBrains Mono', 'Cascadia Code', 'Consolas', ui-monospace, monospace
| Typographic Element | Font Family | Weight | Fluid Size (clamp) | Line Height | Tracking |
|---|---|---|---|---|---|
Hero Eyebrow (AI GAME CREATION PLATFORM) | --font-sans | 600 | 0.75rem – 0.82rem | 1.2 | +0.22em (Uppercase) |
Hero H1 (Dream It. Prompt It. / Play Your Universe.) | --font-display | 800 | clamp(2.35rem, 4.8vw, 4.15rem) | 1.06 | -0.03em |
Section H2 (How It Works, Featured Community Games) | --font-display | 700 | clamp(1.45rem, 2.4vw, 2.05rem) | 1.16 | -0.02em |
Banner Display (Play More, Keep Creating!) | --font-display | 800 (Italic) | clamp(1.35rem, 2.2vw, 1.85rem) | 1.15 | -0.015em |
Card Title (Neon Odyssey, Aaru: Lost Realms) | --font-display | 700 | 1.08rem – 1.20rem | 1.22 | -0.01em |
| Hero Lead Copy | --font-sans | 400 | clamp(0.98rem, 1.25vw, 1.14rem) | 1.58 | 0 |
Stat Value (12+ AI Models, < 25 sec, 100% Free) | --font-display | 700 | 1.02rem – 1.12rem | 1.2 | -0.01em |
| Micro-Subcopy & Badges | --font-sans | 500 | 0.78rem – 0.86rem | 1.35 | +0.01em |
4. Section-by-Section 1:1 Anatomical Specification
flowchart TD
Nav["1. Top Cosmic Navigation Bar (72px height)<br/>Logo Prism + Pill Nav (Home, AI Studio, Explore, Leaderboard, Creators, Docs) + Search + Sign In + Play Free"]
Hero["2. Full-Bleed Seamless Hero Panorama<br/>Left Column: Eyebrow + 2-Line H1 + Lead + Primary/Secondary Pills + 3 Micro-Pillars<br/>Right Bleed: Explorer & Robot + Floating Sky Islands + 'See It in Action (30 sec)' Glass Pill"]
Stats["3. 5-Pillar Stats Glass Ribbon<br/>12+ AI Models | < 25 sec | 100% Free | ZIP Export | Global Leaderboard"]
Steps["4. 4-Step 'How It Works' Horizontal Strip<br/>01 Describe >> 02 Generate >> 03 Play >> 04 Progress"]
Stage["5. Interactive AI Studio Deck & Sandboxed Playable Stage<br/>Prompt Input + 8 Vertex Models + 6 Thinking Levels + 3 Engines + OOPIF Viewport + Virtual Touch Deck"]
Showcase["6. 'Featured Community Games' Filter Pills & 4-Card Carousel<br/>Pills: All Games, Action, Adventure, Arcade, Racing, Strategy, 3D<br/>Cards: Neon Odyssey, Aaru: Lost Realms, Skyrealms, Cyber Breaker, Velocity Zero, Zero Gravity, Forest Whisper"]
Ticket["7. 'Play More, Keep Creating!' Rewarded-Ad Ticket Banner<br/>Glowing Ticket Emblem | Watch a short ad (15-30s) -> Earn play credits -> Continue playing free"]
Horizon["8. 'Ready to Build Your Game?' Cliff-Hero Moonrise Footer CTA + Structured Sitemap Links<br/>Create Your Game Now + Sign In + Non-Overlapping Consent Mode v2 Bar"]
Nav --> Hero --> Stats --> Steps --> Stage --> Showcase --> Ticket --> Horizon
4.1 Top Navigation Bar
- Left Brand Lockup: Glowing cyan-to-violet rounded play-prism emblem paired with
YourPlayground(700white) stacked above. G A M E S(600#94A3B8wide-tracked uppercase). - Center Navigation Cluster: Active item (
Home) enclosed in a translucent violet pill (border: 1px solid rgba(139, 92, 246, 0.55); background: rgba(124, 92, 255, 0.16)) alongsideAI Studio,Explore,Leaderboard,Creators, andDocs(routing cleanly to/,/showcase,/categories, and/faq). - Right Action Cluster: Circular glass search button (
38x38px),Sign Indark glass pill (#ypg-auth-signin-btn— strictly optional), andPlay Freeluminous cyan-to-violet-magenta pill CTA (box-shadow: 0 0 24px rgba(124, 92, 255, 0.45)).
4.2 Full-Bleed Atmospheric Hero Blending
- Zero Boxed Hero Frames: Hero artwork spans
100vwedge-to-edge behind the header and left typography column, blended seamlessly into--bg-cosmic-0(#080A1A) via three composited CSS radial/linear masks:
- Left text-legibility gradient:
linear-gradient(90deg, #080A1A 0%, rgba(8, 10, 26, 0.90) 36%, rgba(8, 10, 26, 0.22) 68%, rgba(8, 10, 26, 0.55) 100%) - Top navbar vignette:
linear-gradient(180deg, rgba(8, 10, 26, 0.82) 0%, transparent 22%) - Bottom seamless section dissolve:
linear-gradient(180deg, transparent 62%, #080A1A 100%)
- Action Row & Trust Micro-Pillars:
Create Your Game — Free(gradient pill with solid play triangle) +Explore Games(glass outline pill with compass icon), floatingSee It in Action · 30 secglass pill anchored over the lower-right vista, and three icon-paired micro-pillars (No Coding · Just your idea,Multi-Model AI · Text → Game → Play,Always Free · Watch ads, keep playing).
4.3 5-Stat Glass Ribbon
Single full-width rounded violet-glass bar (padding: 18px 28px) divided by 1px solid rgba(148, 163, 184, 0.14) vertical hairlines into five equal columns:
12+ AI Models— Gemini 4, Nano Banana 2.1, and more (Gamepad icon)< 25 sec— From idea to playable game (Stopwatch cyan icon)100% Free— Play with ads, no subscription (Infinity violet icon)ZIP Export— Download & publish anywhere (Cloud-download sky icon)Global Leaderboard— Compete, earn, get discovered (Gold trophy icon)
4.4 4-Step How It Works Flow
Four equal-height glass step cards connected horizontally by glowing violet double-chevrons (>>):
01 Describe— Tell your game idea in plain English (Speech-bubble icon)02 Generate— AI creates your game (2D or 3D) (Sparkle-stars icon)03 Play— Play instantly in your browser (Cyan controller icon)04 Progress— Watch short ads to keep playing (Play-screen magenta icon)
4.5 Featured Community Games Carousel & Canonical Card Anatomy
- Header & Filter Pills: Gamepad emblem +
Featured Community Games(Play real games created by the community, all with AI.) aligned left; pill bar aligned right (All Gamesin solid#2CEEF8cyan pill with dark#05080Dtext; inactive outline pills forAction,Adventure,Arcade,Racing,Strategy,3D). - Canonical Showcase Titles: Cards showcase vibrant 16:9 text-free key art for
Neon Odyssey,Aaru: Lost Realms,Skyrealms,Cyber Breaker,Velocity Zero,Zero Gravity, andForest Whisper, each featuring a bottom-gradient scrim, bold title,Genre · Dimensionsubtitle (e.g.,Racing · 3D,Adventure · 3D,Arcade · 2D), optional top-leftAI Generatedglass chip, and a40x40pxcircular glass play button at bottom-right.
4.6 Play More, Keep Creating! Rewarded-Ad Ticket Banner
Full-width violet-rimmed glass callout featuring an angled neon cyan-and-amber glowing play ticket illustration on the left, bold italic Play More, Keep Creating! headline, vertical divider, and 3-stage inline value chain:
Watch a short ad (15–30 sec) → Earn play credits (or extra generation) → Continue playing and creating for free.
4.7 Ready to Build Your Game? Cliff-Hero Moonrise Horizon Footer & Non-Overlapping Consent Bar
- Atmospheric Horizon CTA: Full-bleed twilight mountain range with a caped silhouette on a left promontory facing a warm amber horizon glow and a giant crescent planet rising at right; centered
Ready to Build Your Game?H2, subtitle,Create Your Game Nowgradient pill, andor Sign Ininline link. - Non-Overlapping Consent Bar Invariant:
html { scroll-padding-bottom: 128px; }(tokens.cssline 70) combined with compact bottom-docked positioning ensures#ypg-consent-banner(ypg_consent_v2) never overlaps#ypg-stage-viewportor.ypg-touch-deckon desktop or mobile viewports, and collapses immediately (hidden) onceAccept All,Essential Only, orSave Preferencesis selected.
5. Adaptive Responsive Breakpoints (Phone, Tablet & Desktop)
| Viewport Tier | Width Range | Canonical Verification Target | Grid & Ergonomic Adaptation |
|---|---|---|---|
| Mobile Phone (Portrait) | 320px – 599px | 390x844 (iPhone 14/15/16 Pro) | Hamburger drawer (#ypg-mobile-nav-toggle), stacked single-column hero with top-bleed artwork, 2x2 + full-width 5th stat grid, vertical 4-step stack, horizontal touch-snap game card rail, full-width virtual D-Pad + ACTION/RESET arcade buttons (min-height: 48px touch targets, touch-action: none). |
| Phablet & Compact Tablet | 600px – 899px | 768x1024 (iPad Mini / Portrait Tablet) | 2-column game card grid, 2x2 How It Works grid, side-by-side Studio controls (Engine + Model + Thinking Level), persistent touch-deck toggle. |
| Landscape Tablet & Laptop | 900px – 1279px | 1024x768 / 1280x800 | Inline pill navigation, split-stage Studio workspace (Prompt Inspector left, 16:9 Sandboxed Stage right), 3-up game carousel. |
| Desktop & Widescreen | >= 1280px | 1440x900 (Canonical Reference) | Max container 1280px–1360px centered inside full-bleed 100vw hero/horizon panoramas, 5-column single-row stats ribbon, 4-column How It Works strip, 4-card Featured Community Games carousel with flanking < / > glass chevrons. |
6. Accessibility & Motion Ergonomics (WCAG 2.2 AA)
- Keyboard & Screen-Reader Navigation: First-tab
.ypg-skip-linkjumps straight to#main-content;:focus-visiblerenders a high-luminance2px solid var(--accent-cyan)outline (outline-offset: 2px); modals (#ypg-auth-modal,#ypg-ad-gate-modal) exposerole="dialog",aria-modal="true",aria-labelledby, andEscape-key dismissal; live stage telemetry (#ypg-game-status,#ypg-ad-countdown) announces transitions viaaria-live="polite". - Zero Horizontal Overflow Guarantee:
html, body { overflow-x: clip; max-width: 100%; }prevents horizontal scrollbars at both1440x900and390x844even when full-bleed radial glows or carousels extend to viewport edges. - Reduced Motion Respect: Decorative hover translations and shimmer animations honor
@media (prefers-reduced-motion: reduce)while keeping interactive game canvas loops responsive.