"""Self-contained Three.js MIRROR Core with a CSS-only fallback.""" from __future__ import annotations import html import uuid def render_mirror_core_html( trust: int, corruption: int, status: str = "UNRELIABLE", secret_unlocked: bool = False, ) -> str: """Return a responsive, optional WebGL visual that never blocks gameplay.""" trust = max(0, min(100, int(trust))) corruption = max(0, min(100, int(corruption))) visual_id = f"mirror-core-{uuid.uuid4().hex}" if trust >= 70: primary, secondary = "#55f5ff", "#ff2da6" elif trust < 35: primary, secondary = "#ff3b6b", "#ff2da6" else: primary, secondary = "#ff2da6", "#55f5ff" secret_label = ( '