Some checks failed
CI / validate (pull_request) Has been cancelled
Right-clicking any inspectable 3D mesh now shows a floating tooltip with its name and description. Uses Three.js Raycaster for hit detection. Also adds initial inspectable objects to the scene: - Nexus Core (central glowing orb) - Portal Alpha, Beta, Gamma (orbiting sentinel cubes) Tooltip auto-positions near cursor and stays within viewport bounds. Dismissed by clicking elsewhere or pressing Escape. Fixes #141 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
106 lines
1.8 KiB
CSS
106 lines
1.8 KiB
CSS
/* === DESIGN SYSTEM — NEXUS === */
|
|
:root {
|
|
--color-bg: #000008;
|
|
--color-primary: #4488ff;
|
|
--color-secondary: #334488;
|
|
--color-text: #ccd6f6;
|
|
--color-text-muted: #4a5568;
|
|
--font-body: 'Courier New', monospace;
|
|
}
|
|
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
background: var(--color-bg);
|
|
color: var(--color-text);
|
|
font-family: var(--font-body);
|
|
overflow: hidden;
|
|
width: 100vw;
|
|
height: 100vh;
|
|
}
|
|
|
|
canvas {
|
|
display: block;
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
}
|
|
|
|
/* === HUD === */
|
|
.hud-controls {
|
|
z-index: 10;
|
|
}
|
|
|
|
/* === AUDIO TOGGLE === */
|
|
#audio-toggle {
|
|
font-size: 14px;
|
|
background-color: var(--color-primary);
|
|
color: var(--color-bg);
|
|
padding: 4px 8px;
|
|
border: none;
|
|
border-radius: 4px;
|
|
font-family: var(--font-body);
|
|
transition: background-color 0.3s ease;
|
|
cursor: pointer;
|
|
}
|
|
|
|
#audio-toggle:hover {
|
|
background-color: var(--color-secondary);
|
|
}
|
|
|
|
#audio-toggle.muted {
|
|
background-color: var(--color-text-muted);
|
|
}
|
|
|
|
/* === DEBUG MODE === */
|
|
#debug-toggle {
|
|
margin-left: 8px;
|
|
}
|
|
|
|
.collision-box {
|
|
outline: 2px solid red;
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
.light-source {
|
|
outline: 2px dashed yellow;
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
/* === OBJECT INSPECTION TOOLTIP === */
|
|
#inspect-tooltip {
|
|
display: none;
|
|
position: fixed;
|
|
z-index: 100;
|
|
background: rgba(0, 0, 20, 0.92);
|
|
border: 1px solid var(--color-primary);
|
|
border-radius: 6px;
|
|
padding: 10px 14px;
|
|
max-width: 240px;
|
|
pointer-events: none;
|
|
box-shadow: 0 0 16px rgba(68, 136, 255, 0.3);
|
|
}
|
|
|
|
#inspect-tooltip.visible {
|
|
display: block;
|
|
}
|
|
|
|
#inspect-tooltip .inspect-name {
|
|
color: var(--color-primary);
|
|
font-size: 13px;
|
|
font-weight: bold;
|
|
margin-bottom: 4px;
|
|
letter-spacing: 0.05em;
|
|
text-transform: uppercase;
|
|
}
|
|
|
|
#inspect-tooltip .inspect-desc {
|
|
color: var(--color-text);
|
|
font-size: 12px;
|
|
line-height: 1.5;
|
|
}
|