Skip to content

Self-improving AI Employees for everyone

feat(theme): full handoff fidelity — decorative ornaments + sound events + reduced-motion (Waves 15-19)

trohitg06bd6d8247bd
diff --git a/CLAUDE.md b/CLAUDE.md
index eea82942..e6a2355c 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -11,7 +11,7 @@ This is a React Flow-based workflow automation platform implementing n8n-inspire
|----------|-------------|
| **[Frontend Architecture](./docs-internal/frontend_architecture.md)** | Current frontend stack (React 19 + Vite + Tailwind v4 + shadcn/ui + Radix + RHF/zod + TanStack Query + Zustand). Tokens, primitives, forms, credentials exemplar, ownership boundary, `uiHints` catalogue. |
| **[UI Migration Plan](./docs-internal/ui_migration_plan.md)** | antd → shadcn/ui migration plan + completion log. Waves 1–10 done. Full frontend is schema-driven (backend SSOT); remaining DIY widget registry (ex-Phase 6) is the one deferred item. |
-| **[Theme System](./docs-internal/theme_system.md)** | 10-way visual theme system — 5 utopian (light, dark, renaissance, greek, edo, steampunk, atomic) + 5 dystopian (cyber, wasteland, rot, plague, surveillance) — driven by `<html data-theme>` + per-theme CSS files in `client/src/themes/`. Token taxonomy (surface / fg / border / accent / typography / motion), shadcn HSL-triplet bridge, action role tokens, decorative-layer wrappers (`.app-frame` / `.canvas-host` / `.modal-frame`), per-theme WebAudio sound packs (10 packs via `--sound-pack` token + `useSound()` hook), migration recipe, anti-patterns. Read this before adding a new theme or migrating a component to the new contract. |
+| **[Theme System](./docs-internal/theme_system.md)** | 10-way visual theme system — 5 utopian (light, dark, renaissance, greek, edo, steampunk, atomic) + 5 dystopian (cyber, wasteland, rot, plague, surveillance) — driven by `<html data-theme>` + per-theme CSS files in `client/src/themes/` (3,749 LOC across 13 files). Token taxonomy (surface / fg / border / accent / typography / motion), shadcn HSL-triplet bridge, action role tokens, decorative-layer wrappers (`.app-frame` / `.canvas-host` / `.modal-frame`), per-component decorative ornaments (panel textures + canvas decorations + node pseudo-element overlays + 6 keyframes: `cyber-flicker` / `cyber-roll` / `cyber-blink` / `cyber-glitch` / `ren-flicker` / `surv-blink`), 9-event WebAudio sound system (10 packs via `--sound-pack` token + `useSound()` hook + global hover delegate + sonner toast monkey-patch + `withSound()` HOC), `@media (prefers-reduced-motion: reduce)` accessibility, 30 ms throttle on `type` / `hover`, migration recipe, anti-patterns. Read this before adding a new theme or migrating a component to the new contract. |
| **[Schema Source of Truth RFC](./docs-internal/schema_source_of_truth_rfc.md)** | Backend is SSOT for node schemas, visual metadata, handlers, palette metadata, icons. Plugin pattern: one `BaseNode` subclass in `server/nodes/<group>/<name>.py`. Wire format: `asset:<key>` / `<lib>:<brand>` / URL / emoji. Endpoint: `/api/schemas/nodes/{type}/spec.json`. 124 pytest invariants lock the contract. |
| **[Plugin System (Wave 11)](./docs-internal/plugin_system.md)** | Class-based plugin-first architecture. `BaseNode` / `ActionNode` / `TriggerNode` / `ToolNode` + `@Operation` decorator. Pydantic `Params`/`Output`. Declarative `Routing` DSL + `Connection` facade (Nango pattern). 18 `Credential` subclasses live in each node folder's `_credentials.py` (or inline for single-use). `TaskQueue` constants route to Temporal worker pools. 111 plugins live across 9 queues; handler bodies fully inlined (`services/handlers/` shrank 12.8K → 1.1K LOC across 16 → 4 files; only cross-cutting orchestration remains: `tools.py` AI-tool dispatch + agent delegation, `google_auth.py`, `triggers.py`). **Wave 11.H added "self-contained plugin folders"** — five generic registries (`ws_handler_registry`, `event_waiter.{register_filter_builder,register_trigger_precheck}`, `status_broadcaster.register_service_refresh`, `node_output_schemas.register_output_schema`) so rich plugins like telegram own their entire surface area without core-services edits. |
| **[Nodes Cookbook](./server/nodes/README.md)** | 5-minute recipe + folder map + shared helpers (`_base.py` / `_inline.py` per domain) + shared credentials + **self-contained plugin folder pattern (telegram reference)** + contract invariants + common pitfalls. Lives next to the plugin files. |
diff --git a/client/src/Dashboard.tsx b/client/src/Dashboard.tsx
index dac0ddee..a2525f9b 100644
--- a/client/src/Dashboard.tsx
+++ b/client/src/Dashboard.tsx
@@ -37,7 +37,7 @@ import ErrorBoundary from './components/ui/ErrorBoundary';
import ConsolePanel from './components/ui/ConsolePanel';
import StatusBar from './components/ui/StatusBar';
import CommandPaletteHost from './components/ui/CommandPaletteHost';
-import { useSoundSync } from './hooks/useSound';
+import { useSoundSync, withSound } from './hooks/useSound';
import { useAppTheme } from './hooks/useAppTheme';
import { useWorkflowManagement } from './hooks/useWorkflowManagement';
import { useWorkflowsQuery, WORKFLOWS_QUERY_KEY } from './hooks/useWorkflowsQuery';
@@ -1071,7 +1071,8 @@ const DashboardContent: React.FC = () => {
switch (event.key.toLowerCase()) {
case 's':
event.preventDefault();
- handleSave();
+ // Match the toolbar Save button — fire the per-theme save sound.
+ withSound('save', handleSave)();
break;
case 'c':
event.preventDefault();
@@ -1122,12 +1123,16 @@ const DashboardContent: React.FC = () => {
<TopToolbar
workflowName={currentWorkflow?.name || 'Untitled Workflow'}
onWorkflowNameChange={handleWorkflowNameChange}
- onSave={handleSave}
+ // `withSound('save'|'run', ...)` fires the per-theme audio
+ // cue BEFORE the async dispatch so feedback is instant
+ // regardless of save/deploy latency. No-op when sound is
+ // disabled or the active pack is `none`.
+ onSave={withSound('save', handleSave)}
onNew={handleNew}
onOpen={handleOpen}
- onRun={handleRun}
+ onRun={withSound('run', handleRun)}
isRunning={isExecuting}
- onDeploy={handleDeploy}
+ onDeploy={withSound('run', handleDeploy)}
onCancelDeployment={handleCancelDeployment}
isDeploying={isCurrentWorkflowActive}
hasUnsavedChanges={hasUnsavedChanges}
@@ -1178,12 +1183,15 @@ const DashboardContent: React.FC = () => {
display: 'flex',
position: 'relative',
}}>
- {/* `canvas-host` activates per-theme canvas decorations
- (cyber grid backplane, atomic starburst, rot candlelight
- pools, surveillance crosshair brackets). Decorative
- pseudo-elements declare pointer-events: none. */}
+ {/* `canvas-host` + `canvas` activate per-theme canvas
+ decorations (cyber grid backplane, atomic starburst, rot
+ candlelight pools, surveillance crosshair brackets,
+ renaissance fleur-de-lis + marginalia, greek temple key
+ pattern). The `canvas` co-class is the handoff selector
+ used by every per-theme CSS file. Decorative pseudo-
+ elements declare pointer-events: none. */}
<div
- className="canvas-host"
+ className="canvas-host canvas"
style={{
flex: 1,
backgroundColor: theme.colors.backgroundAlt,
@@ -1276,10 +1284,10 @@ const DashboardContent: React.FC = () => {
open={commandPaletteOpen}
onOpenChange={setCommandPaletteOpen}
handlers={{
- save: handleSave,
+ save: withSound('save', handleSave),
newWorkflow: handleNew,
open: handleOpen,
- run: handleDeploy,
+ run: withSound('run', handleDeploy),
stop: handleCancelDeployment,
isDeploying: isCurrentWorkflowActive,
exportFile: handleExportFile,
diff --git a/client/src/components/AIAgentNode.tsx b/client/src/components/AIAgentNode.tsx
index 4f6a61ea..d5424a8c 100644
--- a/client/src/components/AIAgentNode.tsx
+++ b/client/src/components/AIAgentNode.tsx
@@ -117,7 +117,11 @@ const AIAgentNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnecta
const hasLeftLabels = hasMainInput || leftInputs.length > 0;
return (
+ // `node` + `node-agent` + `selected` co-classes are the design-handoff
+ // structural hooks for per-theme decorations (Renaissance wax seal,
+ // Cyber neon underglow + corner LED blink, etc.).
<div
+ className={`node node-agent ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
padding: theme.spacing.lg,
diff --git a/client/src/components/GenericNode.tsx b/client/src/components/GenericNode.tsx
index 23813d01..a37e4662 100644
--- a/client/src/components/GenericNode.tsx
+++ b/client/src/components/GenericNode.tsx
@@ -114,7 +114,10 @@ const GenericNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnecta
};
return (
+ // `node` + `selected` co-classes activate per-theme generic-node
+ // decorations (wax seal on Renaissance, neon LED on Cyber, etc.).
<div
+ className={`node ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
padding: '12px 32px 12px 16px',
diff --git a/client/src/components/SquareNode.tsx b/client/src/components/SquareNode.tsx
index 47fa4d09..c7055a5f 100644
--- a/client/src/components/SquareNode.tsx
+++ b/client/src/components/SquareNode.tsx
@@ -259,7 +259,13 @@ const SquareNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectab
const nodeColor = definition?.defaults?.color || '#1A73E8';
return (
+ // `sq-node` + `selected` co-classes are the design-handoff structural
+ // hooks for per-theme square-node decorations (rivets on Steampunk
+ // sq-node-box::before/::after, hanko seal on Edo, REC LED + surv-blink
+ // on Surveillance, tombstone shape on Rot, gold-foil emblem on
+ // Renaissance, neon underglow on Cyber, etc.).
<div
+ className={`sq-node ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
display: 'flex',
@@ -272,6 +278,7 @@ const SquareNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectab
>
{/* Main Square Node */}
<div
+ className="sq-node-box"
style={{
position: 'relative',
width: theme.nodeSize.square,
@@ -355,12 +362,14 @@ const SquareNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectab
: '0 1px 4px rgba(0,0,0,0.1)'
}}
title="Edit Service Parameters"
+ className="sq-node-gear"
>
⚙️
</button>
{/* Configuration/Execution Status Indicator */}
<div
+ className="sq-node-pip"
style={{
position: 'absolute',
top: '-4px',
@@ -392,6 +401,7 @@ const SquareNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectab
type="target"
position={Position.Left}
isConnectable={isConnectable}
+ className="sq-node-handle in"
style={{
position: 'absolute',
left: '-6px',
@@ -416,6 +426,7 @@ const SquareNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectab
type="source"
position={Position.Right}
isConnectable={isConnectable}
+ className="sq-node-handle out"
style={{
position: 'absolute',
right: '-6px',
diff --git a/client/src/components/StartNode.tsx b/client/src/components/StartNode.tsx
index 448a2556..edc911b8 100644
--- a/client/src/components/StartNode.tsx
+++ b/client/src/components/StartNode.tsx
@@ -33,7 +33,9 @@ const StartNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnectabl
const nodeColor = theme.dracula.cyan; // Cyan color for start node (neutral "begin" color)
return (
+ // `node` + `selected` co-classes activate per-theme node decorations.
<div
+ className={`node ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
display: 'flex',
diff --git a/client/src/components/TeamMonitorNode.tsx b/client/src/components/TeamMonitorNode.tsx
index 8a04f2e2..25a08473 100644
--- a/client/src/components/TeamMonitorNode.tsx
+++ b/client/src/components/TeamMonitorNode.tsx
@@ -124,6 +124,7 @@ const TeamMonitorNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConn
return (
<div
+ className={`node ${selected ? 'selected' : ''}`}
onClick={handleClick}
style={{
width: 200,
diff --git a/client/src/components/ToolkitNode.tsx b/client/src/components/ToolkitNode.tsx
index 57e968ac..c74bf465 100644
--- a/client/src/components/ToolkitNode.tsx
+++ b/client/src/components/ToolkitNode.tsx
@@ -79,6 +79,7 @@ const ToolkitNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnecta
return (
<div
+ className={`node ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
display: 'flex',
diff --git a/client/src/components/TriggerNode.tsx b/client/src/components/TriggerNode.tsx
index 31d76716..61dd015f 100644
--- a/client/src/components/TriggerNode.tsx
+++ b/client/src/components/TriggerNode.tsx
@@ -122,7 +122,10 @@ const TriggerNode: React.FC<NodeProps<NodeData>> = ({ id, type, data, isConnecta
const nodeColor = definition?.defaults?.color || '#f59e0b';
return (
+ // `node` + `node-trigger` + `selected` co-classes activate per-theme
+ // trigger-node decorations.
<div
+ className={`node node-trigger ${selected ? 'selected' : ''}`}
style={{
position: 'relative',
display: 'flex',
diff --git a/client/src/components/ui/CollapsibleSection.tsx b/client/src/components/ui/CollapsibleSection.tsx
index 283d08fe..2aa7e6b5 100644
--- a/client/src/components/ui/CollapsibleSection.tsx
+++ b/client/src/components/ui/CollapsibleSection.tsx
@@ -25,9 +25,10 @@ const CollapsibleSection: React.FC<CollapsibleSectionProps> = ({
<Collapsible open={open} onOpenChange={() => onToggle()}>
{/* bg-bg-app + border-default for the outer card; bg-bg-elevated
on the trigger so the head sits above the body — matches the
- handoff `.cat` / `.cat-head` two-tier surface. */}
- <div className="overflow-hidden rounded-lg border border-border-default bg-bg-app">
- <CollapsibleTrigger className="flex w-full cursor-pointer items-center justify-between gap-2 border-none bg-bg-elevated px-4 py-3 text-base text-fg-default transition-colors hover:bg-bg-hover">
+ handoff `.cat` / `.cat-head` two-tier surface. `cat` /
+ `cat-head` co-classes activate per-theme decorations. */}
+ <div className={cn('cat overflow-hidden rounded-lg border border-border-default bg-bg-app', isCollapsed && 'collapsed')}>
+ <CollapsibleTrigger className="cat-head flex w-full cursor-pointer items-center justify-between gap-2 border-none bg-bg-elevated px-4 py-3 text-base text-fg-default transition-colors hover:bg-bg-hover">
{typeof title === 'string' ? (
<span className="font-display font-medium">{title}</span>
) : (
@@ -41,7 +42,7 @@ const CollapsibleSection: React.FC<CollapsibleSectionProps> = ({
/>
</CollapsibleTrigger>
- <CollapsibleContent className={cn('transition-[padding]', open && 'p-3')}>
+ <CollapsibleContent className={cn('cat-body transition-[padding]', open && 'p-3')}>
{children}
</CollapsibleContent>
</div>
diff --git a/client/src/components/ui/ComponentItem.tsx b/client/src/components/ui/ComponentItem.tsx
index ea36eb26..cf280cf0 100644
--- a/client/src/components/ui/ComponentItem.tsx
+++ b/client/src/components/ui/ComponentItem.tsx
@@ -33,7 +33,11 @@ const ComponentItem: React.FC<ComponentItemProps> = ({ definition: localDefiniti
}}
onDragEnd={() => setIsDragging(false)}
className={cn(
- 'group relative flex-row items-center gap-3 px-3 py-2 cursor-grab select-none',
+ // `comp` + `row` are handoff structural hooks: comp activates
+ // per-theme component-card decorations (left accent bar on Cyber,
+ // boomerang corners on Atomic, gold border on Renaissance hover);
+ // row enables the global hover-sound delegate.
+ 'comp row group relative flex-row items-center gap-3 px-3 py-2 cursor-grab select-none',
'border-border-default bg-bg-app transition-all duration-150 ease-out',
'hover:-translate-y-0.5 hover:bg-bg-hover hover:ring-2 hover:ring-foreground/15 hover:shadow-md',
isDragging && 'opacity-50',
diff --git a/client/src/components/ui/ComponentPalette.tsx b/client/src/components/ui/ComponentPalette.tsx
index 1b12e1ea..96802c4f 100644
--- a/client/src/components/ui/ComponentPalette.tsx
+++ b/client/src/components/ui/ComponentPalette.tsx
@@ -107,8 +107,9 @@ const ComponentPalette: React.FC<ComponentPaletteProps> = ({
);
return (
- // Palette shell: bg-bg-panel mirrors the sidebar (`.palette` token).
- <div className="flex h-full w-full flex-col overflow-hidden border-l border-border-default bg-bg-panel">
+ // Palette shell: `palette` co-class activates per-theme decorations
+ // (panel textures, neon side-glow on Cyber, marble grain on Greek).
+ <div className="palette flex h-full w-full flex-col overflow-hidden border-l border-border-default bg-bg-panel">
{/* Header Section — bg-bg-app drops one elevation step. */}
<div className="border-b border-border-default bg-bg-app p-4">
<div className="mb-3 flex items-center justify-between">
diff --git a/client/src/components/ui/ConsolePanel.tsx b/client/src/components/ui/ConsolePanel.tsx
index db1a4350..cf3be142 100644
--- a/client/src/components/ui/ConsolePanel.tsx
+++ b/client/src/components/ui/ConsolePanel.tsx
@@ -362,8 +362,11 @@ const ConsolePanel: React.FC<ConsolePanelProps> = ({
// ------------------------------ Render ------------------------------
return (
+ // `chat` co-class is the design-handoff structural hook for per-theme
+ // panel decorations (parchment vellum on Renaissance, neon cyan
+ // top-glow on Cyber, washi noise on Edo, etc.).
<div
- className="relative"
+ className="chat relative"
onWheel={e => {
// Prevent scroll from propagating to the canvas/page when the cursor
// is over the panel header, resize handle, or non-scrollable areas.
@@ -483,10 +486,15 @@ const ConsolePanel: React.FC<ConsolePanelProps> = ({
<div
key={`${msg.timestamp}-${index}`}
className={cn(
- 'max-w-[80%] px-3 py-2 break-words',
+ // `chat-msg` + `chat-msg-user` / `chat-msg-bot`
+ // co-classes activate per-theme bubble decorations
+ // (Renaissance: gold-foil user / vellum bot with
+ // ✦ marker; Cyber: > USER:: / < NODE:: prefixes
+ // with neon glow; etc.).
+ 'chat-msg max-w-[80%] px-3 py-2 break-words',
isUser
- ? 'mr-0 ml-auto rounded-l-xl rounded-tr-xl rounded-br-sm bg-node-agent-soft'
- : 'mr-auto ml-0 rounded-r-xl rounded-tl-xl rounded-bl-sm border border-border-default bg-bg-elevated'
+ ? 'chat-msg-user mr-0 ml-auto rounded-l-xl rounded-tr-xl rounded-br-sm bg-node-agent-soft'
+ : 'chat-msg-bot mr-auto ml-0 rounded-r-xl rounded-tl-xl rounded-bl-sm border border-border-default bg-bg-elevated'
)}
>
{isUser ? (
diff --git a/client/src/components/ui/Modal.tsx b/client/src/components/ui/Modal.tsx
index 0b402b25..c54d13a4 100644
--- a/client/src/components/ui/Modal.tsx
+++ b/client/src/components/ui/Modal.tsx
@@ -90,11 +90,12 @@ const Modal: React.FC<ModalProps> = ({
// defined by the active theme (parchment under Renaissance,
// void under Cyber).
//
- // `modal-frame` is the decorative-layer hook — per-theme
- // CSS targets this class for nailed-up borders (Plague),
- // gilded corners (Renaissance), neon scanlines (Cyber),
- // double-rule frames (Greek), etc.
- 'modal-frame',
+ // `modal` + `modal-frame` are the design-handoff structural
+ // hooks — per-theme CSS targets these classes for nailed-up
+ // borders (Plague), gilded corners (Renaissance), neon
+ // scanlines (Cyber), double-rule frames (Greek), parchment
+ // textures (Renaissance) on the modal content.
+ 'modal modal-frame',
'fixed top-1/2 left-1/2 z-50 flex -translate-x-1/2 -translate-y-1/2 flex-col overflow-hidden rounded-lg border border-border-default bg-bg-app shadow-2xl outline-none',
'data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 duration-100',
className
@@ -112,7 +113,7 @@ const Modal: React.FC<ModalProps> = ({
// + text-transform are theme-driven so titles read as Cinzel
// uppercase under Renaissance and Major Mono Display under
// Cyber, while staying clean sans-serif under light/dark.
- <div className="relative flex w-full items-center border-b border-border-default bg-bg-panel px-5 py-3">
+ <div className="modal-head relative flex w-full items-center border-b border-border-default bg-bg-panel px-5 py-3">
<DialogTitle className="absolute left-5 flex items-center gap-2 font-display text-base font-semibold tracking-[var(--type-tracking-display)] text-fg-default [text-transform:var(--type-uppercase)]">
<Settings className="h-4 w-4 opacity-70" />
{title}
diff --git a/client/src/components/ui/StatusBar.tsx b/client/src/components/ui/StatusBar.tsx
index 8233645b..017cc98d 100644
--- a/client/src/components/ui/StatusBar.tsx
+++ b/client/src/components/ui/StatusBar.tsx
@@ -62,7 +62,10 @@ export const StatusBar: React.FC<StatusBarProps> = ({ workflowName, nodeCount })
// under Cyber, system mono under light/dark.
<div
className={cn(
- 'flex h-6 items-center gap-3 border-t border-border-default bg-bg-panel px-3.5',
+ // `statusbar` is the handoff structural hook for per-theme
+ // decorations (gauge readouts on Steampunk, REC blink on
+ // Surveillance, illuminated footer on Renaissance).
+ 'statusbar flex h-6 items-center gap-3 border-t border-border-default bg-bg-panel px-3.5',
'font-mono text-[11px] tracking-[0.04em] text-fg-muted',
'[text-transform:var(--type-uppercase)]',
)}
@@ -70,9 +73,11 @@ export const StatusBar: React.FC<StatusBarProps> = ({ workflowName, nodeCount })
aria-label="Status bar"
>
<span className={cn('flex items-center gap-1.5 font-medium', wsTone)}>
+ {/* `pip` is the handoff hook for the per-theme blinking dot
+ (Surveillance fires `surv-blink`, Cyber fires `cyber-blink`). */}
<span
className={cn(
- 'inline-block h-1.5 w-1.5 rounded-full',
+ 'pip inline-block h-1.5 w-1.5 rounded-full',
isReady ? 'bg-success animate-pulse' : isConnected ? 'bg-warning' : 'bg-destructive',
)}
/>
diff --git a/client/src/components/ui/TopToolbar.tsx b/client/src/components/ui/TopToolbar.tsx
index 94ed62f2..7db1a3ef 100644
--- a/client/src/components/ui/TopToolbar.tsx
+++ b/client/src/components/ui/TopToolbar.tsx
@@ -159,7 +159,11 @@ const TopToolbar: React.FC<TopToolbarProps> = ({
// resolve to the existing colours under light/dark (no visual
// change) but pick up the parchment / void surfaces under
// renaissance / cyber automatically.
- <div className="flex h-12 items-center justify-between gap-3 border-b border-border-default bg-bg-panel px-3">
+ // `toolbar` is the design-handoff structural class — per-theme CSS
+ // attaches panel textures (vellum on Renaissance, scanlines on Cyber,
+ // marble veins on Greek, riveted leather on Steampunk, etc.) +
+ // border treatments via `:root[data-theme="..."] .toolbar`.
+ <div className="toolbar flex h-12 items-center justify-between gap-3 border-b border-border-default bg-bg-panel px-3">
{/* ---------- Left Section ---------- */}
<div className="flex items-center gap-1.5">
<Button
diff --git a/client/src/components/ui/WorkflowSidebar.tsx b/client/src/components/ui/WorkflowSidebar.tsx
index 6abb57ec..937c5d9c 100644
--- a/client/src/components/ui/WorkflowSidebar.tsx
+++ b/client/src/components/ui/WorkflowSidebar.tsx
@@ -45,10 +45,12 @@ const WorkflowCard: React.FC<WorkflowCardProps> = ({
// 3px accent left edge — matches handoff `.wf-card.selected`.
<Card
onClick={onSelect}
+ // `wf-card` + `row` co-classes are the handoff structural hooks for
+ // per-theme card decorations + the global hover-sound delegate.
className={cn(
- 'group relative mb-2 cursor-pointer border-border-default bg-bg-app p-3 transition-colors',
+ 'wf-card row group relative mb-2 cursor-pointer border-border-default bg-bg-app p-3 transition-colors',
isSelected
- ? 'border-accent border-l-[3px] bg-bg-active'
+ ? 'selected border-accent border-l-[3px] bg-bg-active'
: 'hover:bg-bg-hover'
)}
>
@@ -114,7 +116,9 @@ const WorkflowSidebar: React.FC<WorkflowSidebarProps> = ({
}) => {
return (
// Sidebar shell: bg-bg-panel matches the handoff `.sidebar` token.
- <div className="flex h-full w-[280px] flex-col overflow-hidden border-r border-border-default bg-bg-panel">
+ // `sidebar` co-class activates per-theme decorations (panel textures,
+ // border treatments) declared under `:root[data-theme="..."] .sidebar`.
+ <div className="sidebar flex h-full w-[280px] flex-col overflow-hidden border-r border-border-default bg-bg-panel">
{/* Header — bg-bg-app drops one elevation step below the panel
chrome, giving the heading area a subtle "page" backdrop
that's distinct from the card list. */}
diff --git a/client/src/components/ui/action-button.tsx b/client/src/components/ui/action-button.tsx
index fc1e5c5f..b3e42c76 100644
--- a/client/src/components/ui/action-button.tsx
+++ b/client/src/components/ui/action-button.tsx
@@ -21,9 +21,13 @@ import { Sounds } from '@/lib/sound';
export const actionButtonVariants = cva(
// Base: 32px tall pill with icon-text gap, semibold, focus ring, smooth hover.
- // Disabled state uses shadcn-idiomatic `disabled:opacity-50` so we don't
- // do per-token opacity arithmetic at the call site.
- 'inline-flex h-8 items-center gap-1.5 rounded-md border px-3.5 text-[13px] font-semibold transition-all outline-none select-none disabled:cursor-not-allowed disabled:opacity-50 focus-visible:ring-2 focus-visible:ring-ring/40',
+ // `action-btn` + `btn` co-classes are the design-handoff structural
+ // hooks for per-theme decorations (gold-foil on Renaissance, neon
+ // outline on Cyber, hard 4px shadow on Atomic) and the global hover
+ // sound delegate. Disabled state uses shadcn-idiomatic
+ // `disabled:opacity-50` so we don't do per-token opacity arithmetic
+ // at the call site.
+ 'action-btn btn inline-flex h-8 items-center gap-1.5 rounded-md border px-3.5 text-[13px] font-semibold transition-all outline-none select-none disabled:cursor-not-allowed disabled:opacity-50 focus-visible:ring-2 focus-visible:ring-ring/40',
{
variants: {
intent: {
diff --git a/client/src/components/ui/button.tsx b/client/src/components/ui/button.tsx
index 6138844d..d0c66cec 100644
--- a/client/src/components/ui/button.tsx
+++ b/client/src/components/ui/button.tsx
@@ -3,9 +3,16 @@ import { cva, type VariantProps } from "class-variance-authority"
import { Slot } from "radix-ui"
import { cn } from "@/lib/utils"
+import { Sounds } from "@/lib/sound"
+// `btn` co-class is the design-handoff structural hook — every shadcn
+// Button gets it so per-theme CSS rules (`.btn`, `.btn-primary`, etc.)
+// activate (gold-foil on Renaissance, neon outline on Cyber, riveted
+// brass on Steampunk, boomerang shadow on Atomic, etc.). It also
+// powers the global hover-sound delegate which selects on `.btn, .row,
+// .action-btn, .menu-pop-item, .wf-card, .comp, .cmdk-item`.
const buttonVariants = cva(
- "group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
+ "btn group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
{
variants: {
variant: {
@@ -46,6 +53,7 @@ function Button({
variant = "default",
size = "default",
asChild = false,
+ onClick,
...props
}: React.ComponentProps<"button"> &
VariantProps<typeof buttonVariants> & {
@@ -53,12 +61,27 @@ function Button({
}) {
const Comp = asChild ? Slot.Root : "button"
+ // Fire the per-theme `click` sound BEFORE the user-supplied handler
+ // so audio feedback is instant — mirrors the ActionButton pattern.
+ // No-op when the engine is disabled or the active pack is `none`.
+ // Disabled buttons never reach here (the `disabled` prop filters
+ // pointer events at the DOM level).
+ const handleClick = onClick
+ ? (event: React.MouseEvent<HTMLButtonElement>) => {
+ Sounds.play('click');
+ onClick(event);
+ }
+ : (_event: React.MouseEvent<HTMLButtonElement>) => {
+ Sounds.play('click');
+ };
+
return (
<Comp
data-slot="button"
data-variant={variant}
data-size={size}
className={cn(buttonVariants({ variant, size, className }))}
+ onClick={handleClick}
{...props}
/>
)
diff --git a/client/src/components/ui/dropdown-menu.tsx b/client/src/components/ui/dropdown-menu.tsx
index 1ecb7520..21a01a00 100644
--- a/client/src/components/ui/dropdown-menu.tsx
+++ b/client/src/components/ui/dropdown-menu.tsx
@@ -4,6 +4,7 @@ import * as React from "react"
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui"
import { cn } from "@/lib/utils"
+import { Sounds } from "@/lib/sound"
import { CheckIcon, ChevronRightIcon } from "lucide-react"
function DropdownMenu({
@@ -43,7 +44,11 @@ function DropdownMenuContent({
data-slot="dropdown-menu-content"
sideOffset={sideOffset}
align={align}
- className={cn("z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:overflow-hidden data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95", className )}
+ // `menu-pop` co-class is the design-handoff structural hook
+ // for per-theme dropdown decorations (parchment + gilded
+ // border on Renaissance, neon outline + > prefix on Cyber,
+ // etc.).
+ className={cn("menu-pop z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:overflow-hidden data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95", className )}
{...props}
/>
</DropdownMenuPrimitive.Portal>
@@ -62,18 +67,35 @@ function DropdownMenuItem({
className,
inset,
variant = "default",
+ onSelect,
...props
}: React.ComponentProps<typeof DropdownMenuPrimitive.Item> & {
inset?: boolean
variant?: "default" | "destructive"
}) {
+ // Fire the per-theme `click` sound when the item is selected (Radix
+ // calls onSelect for both pointer + keyboard activation, which
+ // matches the upstream's `.menu-pop-item` click trigger).
+ const handleSelect = onSelect
+ ? (event: Event) => {
+ Sounds.play('click');
+ onSelect(event);
+ }
+ : (_event: Event) => {
+ Sounds.play('click');
+ };
+
return (
<DropdownMenuPrimitive.Item
data-slot="dropdown-menu-item"
data-inset={inset}
data-variant={variant}
+ onSelect={handleSelect}
+ // `menu-pop-item` co-class powers per-theme item decorations
+ // (Renaissance ink-spread hover + ✦ marker; Cyber `> ` prefix +
+ // neon glow; etc.) and the W18 hover-sound delegate.
className={cn(
- "group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive",
+ "menu-pop-item group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive",
className
)}
{...props}
diff --git a/client/src/components/ui/input.tsx b/client/src/components/ui/input.tsx
index d763cd9a..7d72b33f 100644
--- a/client/src/components/ui/input.tsx
+++ b/client/src/components/ui/input.tsx
@@ -1,14 +1,31 @@
import * as React from "react"
import { cn } from "@/lib/utils"
+import { Sounds } from "@/lib/sound"
+
+function Input({ className, type, onChange, ...props }: React.ComponentProps<"input">) {
+ // Fire the per-theme `type` sound on every keystroke. The engine
+ // throttles `type` internally (W19 30 ms last-fire window) so rapid
+ // typing into a long input doesn't queue dozens of OscillatorNodes.
+ // No-op when sound is disabled.
+ const handleChange = onChange
+ ? (event: React.ChangeEvent<HTMLInputElement>) => {
+ Sounds.play('type');
+ onChange(event);
+ }
+ : undefined;
-function Input({ className, type, ...props }: React.ComponentProps<"input">) {
return (
<input
type={type}
data-slot="input"
+ onChange={handleChange}
+ // `input` co-class is the design-handoff structural hook —
+ // per-theme CSS attaches ruled-line backgrounds (Renaissance),
+ // terminal prompt prefix (Cyber), washi underline (Edo), etc.
+ // Also targeted by the W18 `type` sound delegate.
className={cn(
- "h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
+ "input h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
className
)}
{...props}
diff --git a/client/src/components/ui/select.tsx b/client/src/components/ui/select.tsx
index 45e2e7eb..a83bcb84 100644
--- a/client/src/components/ui/select.tsx
+++ b/client/src/components/ui/select.tsx
@@ -4,6 +4,7 @@ import * as React from "react"
import { Select as SelectPrimitive } from "radix-ui"
import { cn } from "@/lib/utils"
+import { Sounds } from "@/lib/sound"
import { ChevronDownIcon, CheckIcon, ChevronUpIcon } from "lucide-react"
function Select({
@@ -106,8 +107,21 @@ function SelectLabel({
function SelectItem({
className,
children,
+ onClick,
...props
}: React.ComponentProps<typeof SelectPrimitive.Item>) {
+ // Radix Select doesn't surface an `onSelect` per-item; clicks +
+ // keyboard activation both surface as DOM clicks on the Item, so we
+ // wrap onClick. Falls through to the original handler if any.
+ const handleClick = onClick
+ ? (event: React.MouseEvent<HTMLDivElement>) => {
+ Sounds.play('click');
+ onClick(event);
+ }
+ : (_event: React.MouseEvent<HTMLDivElement>) => {
+ Sounds.play('click');
+ };
+
return (
<SelectPrimitive.Item
data-slot="select-item"
@@ -115,6 +129,7 @@ function SelectItem({
"relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
className
)}
+ onClick={handleClick}
{...props}
>
<span className="pointer-events-none absolute right-2 flex size-4 items-center justify-center">
diff --git a/client/src/components/ui/textarea.tsx b/client/src/components/ui/textarea.tsx
index 04d27f7d..4f0c18e8 100644
--- a/client/src/components/ui/textarea.tsx
+++ b/client/src/components/ui/textarea.tsx
@@ -1,13 +1,26 @@
import * as React from "react"
import { cn } from "@/lib/utils"
+import { Sounds } from "@/lib/sound"
+
+function Textarea({ className, onChange, ...props }: React.ComponentProps<"textarea">) {
+ // Fire the per-theme `type` sound on every keystroke (throttled by
+ // the W19 last-fire window inside the engine).
+ const handleChange = onChange
+ ? (event: React.ChangeEvent<HTMLTextAreaElement>) => {
+ Sounds.play('type');
+ onChange(event);
+ }
+ : undefined;
-function Textarea({ className, ...props }: React.ComponentProps<"textarea">) {
return (
<textarea
data-slot="textarea"
+ onChange={handleChange}
+ // `input` co-class shares per-theme decorations + W18 type delegate
+ // with the Input primitive.
className={cn(
- "flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
+ "input flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
className
)}
{...props}
diff --git a/client/src/hooks/useSound.ts b/client/src/hooks/useSound.ts
index d0ca3008..d583ba20 100644
--- a/client/src/hooks/useSound.ts
+++ b/client/src/hooks/useSound.ts
@@ -6,18 +6,27 @@
* - reads `--sound-pack` from `:root` after every theme change and
* calls `Sounds.setPack(...)` so the active pack tracks the active
* theme without per-component wiring
+ * - installs a global mouseenter / touchstart delegate that fires
+ * `play('hover')` for any element matching the design-handoff hover
+ * selector list (`.btn`, `.action-btn`, `.row`, `.menu-pop-item`,
+ * `.wf-card`, `.comp`, `.cmdk-item`, `[data-sound-hover]`).
*
* `useSound()` is the lightweight handle every event handler uses:
*
* const play = useSound();
* <button onClick={() => { play('click'); onSave(); }} />
*
+ * `withSound()` is the convenience wrap to spice an existing handler:
+ *
+ * <Button onClick={withSound('click', onSave)} />
+ *
* Adding a new sound event: extend `SoundEvent` in lib/sound.ts, add
* an entry per pack, and fire `play('<event>')` from the relevant
* handler. No additional wiring here.
*/
import { useEffect } from 'react';
+import { toast } from 'sonner';
import { useTheme } from '../contexts/ThemeContext';
import { useAppStore } from '../store/useAppStore';
import { Sounds, type SoundPackName, type SoundEvent } from '../lib/sound';
@@ -27,6 +36,12 @@ const VALID_PACKS: ReadonlySet<SoundPackName> = new Set([
'terminal', 'scrap', 'crypt', 'bell', 'telex',
]);
+/** Selector for the global hover delegate. Mirrors the upstream
+ * `app/sound.js` auto-capture list, modulo class additions from W15
+ * (`.action-btn`, `.wf-card`, `.comp`, `.cmdk-item`). */
+const HOVER_SELECTOR =
+ '.btn, .action-btn, .row, .menu-pop-item, .wf-card, .comp, .cmdk-item, [data-sound-hover]';
+
function readSoundPack(): SoundPackName {
if (typeof document === 'undefined') return 'none';
const raw = getComputedStyle(document.documentElement)
@@ -36,11 +51,44 @@ function readSoundPack(): SoundPackName {
return VALID_PACKS.has(raw as SoundPackName) ? (raw as SoundPackName) : 'none';
}
+/**
+ * One-shot monkey-patch of `toast.success` / `toast.error` so every
+ * call site fires the matching per-theme sound automatically. Sonner
+ * exports `toast` as a singleton object with mutable methods, so
+ * patching once at module load is safe. Guarded by a flag so React
+ * 18+ Strict-Mode double-invocation of useSoundSync doesn't double-
+ * wrap the methods.
+ */
+let toastPatched = false;
+function patchToast(): void {
+ if (toastPatched) return;
+ toastPatched = true;
+ const originalSuccess = toast.success;
+ const originalError = toast.error;
+ // `toast.success` / `toast.error` accept (message, options) and
+ // return the toast id. We preserve the return type by deferring to
+ // the original after firing the sound.
+ toast.success = ((...args: Parameters<typeof originalSuccess>) => {
+ Sounds.play('success');
+ return originalSuccess.apply(toast, args);
+ }) as typeof originalSuccess;
+ toast.error = ((...args: Parameters<typeof originalError>) => {
+ Sounds.play('error');
+ return originalError.apply(toast, args);
+ }) as typeof originalError;
+}
+
/** Mount once at the Dashboard root. */
export function useSoundSync(): void {
const { theme } = useTheme();
const enabled = useAppStore((s) => s.soundEnabled);
+ // Patch sonner's `toast.success` / `toast.error` so every call fires
+ // the matching sound. Idempotent — safe under React Strict Mode.
+ useEffect(() => {
+ patchToast();
+ }, []);
+
useEffect(() => {
Sounds.setEnabled(enabled);
}, [enabled]);
@@ -48,9 +96,57 @@ export function useSoundSync(): void {
useEffect(() => {
Sounds.setPack(readSoundPack());
}, [theme]);
+
+ // Global hover delegate. Capture-phase listener so it picks up
+ // mouseenter on any matching surface without each component wiring
+ // its own onMouseEnter handler. touchstart mirrors the same selector
+ // list for mobile / hybrid devices.
+ useEffect(() => {
+ const handleHover = (event: Event) => {
+ const target = event.target as Element | null;
+ if (!target || typeof target.closest !== 'function') return;
+ if (target.closest(HOVER_SELECTOR)) {
+ Sounds.play('hover');
+ }
+ };
+ // mouseenter doesn't bubble, so we use the capture-phase approach
+ // via mouseover (which does bubble) plus a relatedTarget filter so
+ // a single hover only fires once per crossing-into-element.
+ const handleMouseOver = (event: MouseEvent) => {
+ const target = event.target as Element | null;
+ const related = event.relatedTarget as Element | null;
+ if (!target || typeof target.closest !== 'function') return;
+ const matched = target.closest(HOVER_SELECTOR);
+ if (!matched) return;
+ // Only fire on enter — if the previous mouse position was already
+ // inside the same matched element, skip.
+ if (related && matched.contains(related)) return;
+ Sounds.play('hover');
+ };
+ document.addEventListener('mouseover', handleMouseOver, true);
+ document.addEventListener('touchstart', handleHover, { capture: true, passive: true });
+ return () => {
+ document.removeEventListener('mouseover', handleMouseOver, true);
+ document.removeEventListener('touchstart', handleHover, true);
+ };
+ }, []);
}
/** Play handle. Returns the same `Sounds.play` reference each render. */
export function useSound(): (event: SoundEvent) => void {
return Sounds.play;
}
+
+/** Wrap an existing onClick / onChange handler so the matching sound
+ * fires before the underlying handler runs. Sound events are non-
+ * blocking (fire-and-forget OscillatorNode). When the engine is
+ * disabled or the active pack is `none`, this is a no-op. */
+export function withSound<E extends ((...args: any[]) => any) | undefined>(
+ event: SoundEvent,
+ handler: E,
+): (...args: E extends (...args: infer P) => any ? P : never[]) => void {
+ return ((...args: any[]) => {
+ Sounds.play(event);
+ handler?.(...args);
+ }) as any;
+}
diff --git a/client/src/lib/sound.ts b/client/src/lib/sound.ts
index da5f2149..57070038 100644
--- a/client/src/lib/sound.ts
+++ b/client/src/lib/sound.ts
@@ -79,6 +79,23 @@ let enabled = false;
let activePackName: SoundPackName = 'none';
let activePack: EventTable = {};
+/**
+ * Per-event last-fire timestamps for throttling. Currently only `type`
+ * is throttled — rapid typing into a long input shouldn't queue dozens
+ * of OscillatorNodes per second. Other events (click, hover, success,
+ * etc.) are user-paced and don't need throttling.
+ *
+ * Uses `performance.now()` for monotonic timing. The 30 ms window
+ * matches the upstream `app/sound.js` reference engine's documented
+ * hover debounce; we apply the same to `type` since each oscillator
+ * costs ~25 ms decay on the parchment / marble packs.
+ */
+const lastFireMs: Partial<Record<SoundEvent, number>> = {};
+const THROTTLE_MS: Partial<Record<SoundEvent, number>> = {
+ type: 30,
+ hover: 30,
+};
+
function play(cfg: OscConfig | undefined): void {
if (!cfg || !enabled) return;
const ac = ensureCtx();
@@ -272,6 +289,13 @@ export const Sounds = {
return activePackName;
},
play(event: SoundEvent): void {
+ const throttle = THROTTLE_MS[event];
+ if (throttle !== undefined) {
+ const now = typeof performance !== 'undefined' ? performance.now() : Date.now();
+ const last = lastFireMs[event] ?? 0;
+ if (now - last < throttle) return;
+ lastFireMs[event] = now;
+ }
play(activePack[event]);
},
};
diff --git a/client/src/themes/atomic.css b/client/src/themes/atomic.css
index 9898451b..01677dbc 100644
--- a/client/src/themes/atomic.css
+++ b/client/src/themes/atomic.css
@@ -128,3 +128,96 @@
background: rgba(232, 90, 38, 0.4);
color: #2a3a4a;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─────────────── */
+
+:root[data-theme="atomic"] .toolbar, :root[data-theme="atomic"] .sidebar,
+:root[data-theme="atomic"] .palette, :root[data-theme="atomic"] .chat { background: var(--bg-panel); }
+:root[data-theme="atomic"] .toolbar { border-bottom: 4px solid var(--slate); }
+:root[data-theme="atomic"] .sidebar { border-right: 4px solid var(--slate); }
+:root[data-theme="atomic"] .palette { border-left: 4px solid var(--slate); }
+:root[data-theme="atomic"] .chat { border-top: 4px solid var(--slate); }
+
+/* Canvas — atomic starburst pattern */
+:root[data-theme="atomic"] .canvas {
+ background:
+ radial-gradient(circle at 12% 15%, hsl(var(--accent)) 0%, transparent 0.8%),
+ radial-gradient(circle at 88% 12%, var(--turquoise) 0%, transparent 0.6%),
+ radial-gradient(circle at 18% 88%, var(--mustard) 0%, transparent 0.7%),
+ radial-gradient(circle at 82% 90%, hsl(var(--accent)) 0%, transparent 0.5%),
+ radial-gradient(circle at 50% 50%, var(--turquoise) 0%, transparent 0.4%),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><g stroke='%232a3a4a' stroke-width='0.6' fill='none' opacity='0.18'><path d='M40 80 L120 80 M80 40 L80 120 M50 50 L110 110 M110 50 L50 110'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* Typography */
+:root[data-theme="atomic"] body { font-family: var(--font-body); color: var(--fg-default); }
+:root[data-theme="atomic"] h1, :root[data-theme="atomic"] h2, :root[data-theme="atomic"] h3,
+:root[data-theme="atomic"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.06em; text-transform: uppercase; color: var(--slate);
+}
+
+/* Square node — boomerang card */
+:root[data-theme="atomic"] .sq-node-box {
+ background: var(--bg-elevated);
+ border: 3px solid var(--slate); border-radius: 14px 2px 14px 2px;
+ box-shadow: 4px 4px 0 var(--slate);
+ color: hsl(var(--accent));
+}
+:root[data-theme="atomic"] .sq-node.selected .sq-node-box {
+ background: hsl(var(--accent)); color: var(--bg-elevated);
+ box-shadow: 4px 4px 0 var(--slate), 0 0 0 4px hsl(var(--warning-soft));
+}
+:root[data-theme="atomic"] .sq-node-pip { border: 1.5px solid var(--slate); }
+:root[data-theme="atomic"] .sq-node-gear { background: var(--turquoise); color: var(--bg-elevated); border: 1px solid var(--slate); }
+:root[data-theme="atomic"] .sq-node-handle { border: 2px solid var(--slate); background: var(--mustard); }
+:root[data-theme="atomic"] .sq-node-handle.out { background: hsl(var(--accent)); }
+:root[data-theme="atomic"] .sq-node-label { font-family: var(--font-display); letter-spacing: 0.08em; font-size: 11px; }
+
+/* Actions — chunky stamps */
+:root[data-theme="atomic"] .action-btn {
+ font-family: var(--font-display); letter-spacing: 0.08em; text-transform: uppercase;
+ border-radius: 0; border-width: 3px; box-shadow: 3px 3px 0 var(--slate);
+}
+:root[data-theme="atomic"] .action-btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--slate); }
+:root[data-theme="atomic"] .action-run { background: hsl(var(--success)); color: var(--bg-elevated); border-color: var(--slate); }
+:root[data-theme="atomic"] .action-deploy { background: var(--turquoise); color: var(--bg-elevated); border-color: var(--slate); }
+:root[data-theme="atomic"] .action-save { background: hsl(var(--accent)); color: var(--bg-elevated); border-color: var(--slate); }
+
+/* Cards — boomerang corners */
+:root[data-theme="atomic"] .wf-card,
+:root[data-theme="atomic"] .cat,
+:root[data-theme="atomic"] .comp,
+:root[data-theme="atomic"] .settings-section,
+:root[data-theme="atomic"] .cred-card {
+ background: var(--bg-elevated); border: 2px solid var(--slate); border-radius: 12px 2px 12px 2px;
+ box-shadow: 3px 3px 0 var(--slate);
+}
+:root[data-theme="atomic"] .wf-card.selected { background: hsl(var(--warning-soft)); border-color: hsl(var(--accent)); }
+:root[data-theme="atomic"] .cat-tile { background: var(--mustard); border: 1.5px solid var(--slate); border-radius: 8px 0 8px 0; color: var(--slate); }
+:root[data-theme="atomic"] .comp-ico { background: var(--turquoise); color: var(--bg-elevated); border-radius: 6px 0 6px 0; border: 1.5px solid var(--slate); }
+:root[data-theme="atomic"] .cat-name, :root[data-theme="atomic"] .comp-name { font-family: var(--font-display); font-size: 12px; }
+
+/* Chat */
+:root[data-theme="atomic"] .chat-msg { border-radius: 14px 4px 14px 4px; border-width: 2px; }
+:root[data-theme="atomic"] .chat-msg-user { background: var(--mustard); color: var(--slate); border-color: var(--slate); }
+:root[data-theme="atomic"] .chat-msg-bot { background: var(--turquoise); color: var(--bg-elevated); border-color: var(--slate); }
+
+/* Status bar */
+:root[data-theme="atomic"] .statusbar {
+ background: var(--slate); color: var(--bg-elevated); border-top: 4px solid hsl(var(--accent));
+ font-family: var(--font-mono); letter-spacing: 0.06em;
+}
+:root[data-theme="atomic"] .statusbar .pip { background: hsl(var(--success)); }
+
+/* Modal */
+:root[data-theme="atomic"] .modal {
+ background: var(--bg-elevated); border: 4px solid var(--slate); border-radius: 24px 4px 24px 4px;
+ box-shadow: 8px 8px 0 var(--slate);
+}
+:root[data-theme="atomic"] .modal-head { border-bottom: 3px solid var(--slate); background: hsl(var(--accent)); color: var(--bg-elevated); }
+:root[data-theme="atomic"] .modal-title { font-family: var(--font-display); color: var(--bg-elevated); letter-spacing: 0.10em; }
+
+/* CMDK */
+:root[data-theme="atomic"] .cmdk { background: var(--bg-elevated); border: 4px solid var(--slate); border-radius: 24px 4px 24px 4px; box-shadow: 8px 8px 0 var(--slate); }
+:root[data-theme="atomic"] .cmdk-item.active { background: hsl(var(--accent)); color: var(--bg-elevated); }
diff --git a/client/src/themes/base.css b/client/src/themes/base.css
index f68e08e0..1377f136 100644
--- a/client/src/themes/base.css
+++ b/client/src/themes/base.css
@@ -43,3 +43,42 @@
--cursor-default: auto;
--cursor-pointer: pointer;
}
+
+/* ============================================================================
+ * Reduced-motion override — respects the user's OS-level
+ * `prefers-reduced-motion: reduce` setting (DevTools rendering panel
+ * also surfaces this).
+ *
+ * Targets every theme's per-component animation: cyber-flicker /
+ * cyber-roll / cyber-blink / cyber-glitch (Cyber), surv-blink
+ * (Surveillance), ren-flicker (Renaissance), plus any `transition`
+ * on canvas-host pseudo-elements that synthesise motion.
+ *
+ * Sounds are not motion — left enabled regardless. Settings → Audio
+ * → Sound effects is the user-facing audio toggle.
+ * ============================================================================ */
+
+@media (prefers-reduced-motion: reduce) {
+ /* Cyber */
+ :root[data-theme="cyber"] .app-frame,
+ :root[data-theme="cyber"] .app-frame::before,
+ :root[data-theme="cyber"] .app-frame::after,
+ :root[data-theme="cyber"] .canvas::after,
+ :root[data-theme="cyber"] .canvas-host::after,
+ :root[data-theme="cyber"] .node::before,
+ :root[data-theme="cyber"] .sq-node.selected .sq-node-box,
+ :root[data-theme="cyber"] .row:hover::after,
+ :root[data-theme="cyber"] .statusbar .pip,
+ :root[data-theme="cyber"] .cmdk-item.active::after,
+ :root[data-theme="cyber"] .v-display:hover,
+ /* Surveillance */
+ :root[data-theme="surveillance"] .sq-node-box::before,
+ :root[data-theme="surveillance"] .statusbar .pip,
+ /* Renaissance */
+ :root[data-theme="renaissance"] .canvas .ornament,
+ /* Generic Tailwind animate-pulse used by node execution pip */
+ .animate-pulse {
+ animation: none !important;
+ transition: none !important;
+ }
+}
diff --git a/client/src/themes/cyber.css b/client/src/themes/cyber.css
index 33f9dce6..997e17db 100644
--- a/client/src/themes/cyber.css
+++ b/client/src/themes/cyber.css
@@ -162,3 +162,660 @@
background: #f51eb6;
box-shadow: 0 0 6px #f51eb6;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+/* CRT flicker on whole frame */
+@keyframes cyber-flicker {
+ 0%, 92%, 100% { opacity: 1; }
+ 93% { opacity: 0.88; }
+ 94% { opacity: 1; }
+ 96% { opacity: 0.94; }
+ 97% { opacity: 1; }
+}
+
+/* Rolling scanline */
+@keyframes cyber-roll {
+ 0% { transform: translateY(-100%); }
+ 100% { transform: translateY(100vh); }
+}
+
+/* Blinking elements (LED, status pip, cmdk arrow) */
+@keyframes cyber-blink {
+ 0%, 49% { opacity: 1; }
+ 50%, 100% { opacity: 0.4; }
+}
+
+/* Glitch on hover */
+@keyframes cyber-glitch {
+ 0%, 100% { transform: translateX(0); text-shadow: 0 0 4px var(--neon-magenta), 0 0 12px var(--neon-magenta), 1px 0 0 var(--neon-cyan); }
+ 20% { transform: translateX(-2px); text-shadow: 2px 0 var(--neon-cyan), -2px 0 var(--neon-magenta); }
+ 40% { transform: translateX(2px); text-shadow: -2px 0 var(--neon-cyan), 2px 0 var(--neon-magenta); }
+ 60% { transform: translateX(-1px); }
+ 80% { transform: translateX(1px); }
+}
+
+/* ─── SCANLINES OVERLAY across the whole app ─── */
+:root[data-theme="cyber"] .app-frame {
+ box-shadow:
+ inset 0 0 0 1px var(--neon-magenta),
+ inset 0 0 0 4px var(--bg-app),
+ inset 0 0 0 5px var(--neon-cyan),
+ 0 0 80px rgba(245, 30, 182, 0.4);
+ position: relative;
+ animation: cyber-flicker 5s linear infinite;
+}
+:root[data-theme="cyber"] .app-frame::after {
+ content: '';
+ position: absolute; inset: 0;
+ background: repeating-linear-gradient(0deg, transparent 0 2px, rgba(0,0,0,0.25) 2px 3px);
+ pointer-events: none;
+ z-index: 1000;
+ mix-blend-mode: multiply;
+}
+:root[data-theme="cyber"] .app-frame::before {
+ content: ''; position: absolute; left: 0; right: 0; height: 80px;
+ background: linear-gradient(180deg, transparent, rgba(245, 30, 182, 0.15), transparent);
+ pointer-events: none; z-index: 1001;
+ animation: cyber-roll 8s linear infinite;
+}
+
+/* ─── PANELS with circuit-board border lights ─── */
+:root[data-theme="cyber"] .toolbar,
+:root[data-theme="cyber"] .sidebar,
+:root[data-theme="cyber"] .palette,
+:root[data-theme="cyber"] .chat {
+ background:
+ linear-gradient(180deg, rgba(245, 30, 182, 0.04), transparent 60px),
+ var(--bg-panel);
+ position: relative;
+}
+:root[data-theme="cyber"] .toolbar { border-bottom: 1px solid var(--neon-magenta); box-shadow: 0 1px 12px rgba(245, 30, 182, 0.5); }
+:root[data-theme="cyber"] .sidebar { border-right: 1px solid var(--neon-magenta); box-shadow: 1px 0 12px rgba(245, 30, 182, 0.3); }
+:root[data-theme="cyber"] .palette { border-left: 1px solid var(--neon-cyan); box-shadow: -1px 0 12px rgba(29, 217, 229, 0.3); }
+:root[data-theme="cyber"] .chat { border-top: 1px solid var(--neon-cyan); box-shadow: 0 -1px 12px rgba(29, 217, 229, 0.3); }
+
+/* ─── CANVAS — magnetic-tape grid with horizon ─── */
+:root[data-theme="cyber"] .canvas {
+ background:
+ radial-gradient(ellipse at 50% 100%, rgba(245, 30, 182, 0.25), transparent 60%),
+ linear-gradient(180deg, transparent 0%, transparent 50%, rgba(29, 217, 229, 0.04) 50%, rgba(29, 217, 229, 0.08) 100%),
+ linear-gradient(rgba(245, 30, 182, 0.08) 1px, transparent 1px),
+ linear-gradient(90deg, rgba(29, 217, 229, 0.08) 1px, transparent 1px),
+ var(--bg-canvas);
+ background-size: auto, auto, 24px 24px, 24px 24px, auto;
+ position: relative;
+}
+
+/* Perspective grid floor */
+:root[data-theme="cyber"] .canvas::before {
+ content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 50%;
+ background:
+ linear-gradient(180deg, transparent, rgba(245, 30, 182, 0.10) 80%),
+ repeating-linear-gradient(180deg, transparent 0 20px, rgba(29, 217, 229, 0.4) 20px 21px);
+ transform: perspective(300px) rotateX(60deg);
+ transform-origin: bottom;
+ pointer-events: none;
+ opacity: 0.4;
+}
+
+/* Floating "SIGNAL LOST" status text */
+:root[data-theme="cyber"] .canvas::after {
+ content: '◆ SIGNAL ◆ NIGHT_MARKET.7 ◆ 03:47:22';
+ position: absolute; top: 12px; right: 16px;
+ font-family: var(--font-mono);
+ font-size: 10px;
+ color: var(--neon-cyan);
+ letter-spacing: 0.2em;
+ text-shadow: 0 0 4px var(--neon-cyan);
+ pointer-events: none;
+ animation: cyber-blink 1.6s steps(2) infinite;
+}
+
+/* ─── BUTTONS — neon outline ─── */
+:root[data-theme="cyber"] .btn {
+ background: transparent;
+ border: 1px solid var(--neon-cyan);
+ color: var(--neon-cyan);
+ font-family: var(--font-body);
+ letter-spacing: 0.14em;
+ text-transform: uppercase;
+ font-size: 11px; font-weight: 600;
+ padding: 7px 14px;
+ text-shadow: 0 0 4px currentColor;
+ box-shadow: 0 0 8px rgba(29, 217, 229, 0.3), inset 0 0 8px rgba(29, 217, 229, 0.1);
+ position: relative;
+ transition: none;
+}
+:root[data-theme="cyber"] .btn::before {
+ content: '> '; opacity: 0; transition: opacity var(--dur-fast);
+}
+:root[data-theme="cyber"] .btn:hover {
+ color: var(--neon-magenta);
+ border-color: var(--neon-magenta);
+ background: rgba(245, 30, 182, 0.10);
+ box-shadow: 0 0 16px var(--neon-magenta), inset 0 0 12px rgba(245, 30, 182, 0.2);
+}
+:root[data-theme="cyber"] .btn:hover::before { opacity: 1; }
+
+/* ─── INPUTS — terminal entry ─── */
+:root[data-theme="cyber"] .input {
+ background: rgba(0,0,0,0.4);
+ border: 1px solid var(--border-default);
+ color: var(--neon-cyan);
+ font-family: var(--font-mono);
+ font-size: 12px;
+ caret-color: var(--neon-magenta);
+ text-shadow: 0 0 3px var(--neon-cyan);
+ padding: 7px 10px 7px 22px;
+}
+:root[data-theme="cyber"] .input:focus {
+ outline: none;
+ border-color: var(--neon-magenta);
+ box-shadow: 0 0 0 1px var(--neon-magenta), 0 0 16px rgba(245, 30, 182, 0.5);
+}
+:root[data-theme="cyber"] .input::placeholder { color: var(--fg-faint); }
+
+/* prompt prefix */
+:root[data-theme="cyber"] .input { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M2 2 L6 6 L2 10' fill='none' stroke='%23f51eb6' stroke-width='1.5'/></svg>"); background-repeat: no-repeat; background-position: 7px center; background-size: 10px; }
+
+/* ─── ROWS — scan-bracket on hover ─── */
+:root[data-theme="cyber"] .row {
+ font-family: var(--font-mono);
+ font-size: 12px;
+ color: var(--fg-muted);
+ padding: 6px 10px;
+ position: relative;
+ border-left: 2px solid transparent;
+ transition: color var(--dur-fast) steps(2), border-color var(--dur-fast), background var(--dur-fast);
+}
+:root[data-theme="cyber"] .row:hover {
+ color: var(--neon-magenta);
+ background: var(--bg-hover);
+ border-left-color: var(--neon-magenta);
+ text-shadow: 0 0 4px var(--neon-magenta);
+}
+:root[data-theme="cyber"] .row:hover::after {
+ content: ' ◀'; color: var(--neon-magenta);
+ position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
+ animation: cyber-blink 0.6s steps(2) infinite;
+}
+
+/* ─── NODES — chrome terminals with neon underglow ─── */
+:root[data-theme="cyber"] .node {
+ background: linear-gradient(180deg, var(--bg-elevated), var(--bg-panel));
+ border: 1px solid var(--neon-cyan);
+ font-family: var(--font-display);
+ font-size: 10px;
+ letter-spacing: 0.16em;
+ text-transform: uppercase;
+ color: var(--neon-cyan);
+ padding: 10px 14px;
+ text-shadow: 0 0 4px currentColor;
+ box-shadow:
+ 0 0 0 1px var(--bg-app),
+ 0 0 16px rgba(29, 217, 229, 0.4),
+ inset 0 0 12px rgba(29, 217, 229, 0.1);
+ position: relative;
+ clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
+ transition: none;
+}
+:root[data-theme="cyber"] .node-trigger { border-color: var(--neon-green); color: var(--neon-green); box-shadow: 0 0 0 1px var(--bg-app), 0 0 16px rgba(38, 217, 122, 0.5), inset 0 0 12px rgba(38, 217, 122, 0.1); }
+:root[data-theme="cyber"] .node-agent { border-color: var(--neon-magenta); color: var(--neon-magenta); box-shadow: 0 0 0 1px var(--bg-app), 0 0 16px rgba(245, 30, 182, 0.6), inset 0 0 12px rgba(245, 30, 182, 0.15); }
+:root[data-theme="cyber"] .node-output { border-color: var(--neon-yellow); color: var(--neon-yellow); box-shadow: 0 0 0 1px var(--bg-app), 0 0 16px rgba(255, 208, 40, 0.4), inset 0 0 12px rgba(255, 208, 40, 0.1); }
+
+/* corner LED */
+:root[data-theme="cyber"] .node::before {
+ content: ''; position: absolute; top: 4px; left: 4px;
+ width: 4px; height: 4px;
+ background: currentColor;
+ box-shadow: 0 0 6px currentColor;
+ animation: cyber-blink 1.4s steps(2) infinite;
+}
+:root[data-theme="cyber"] .node:hover {
+ box-shadow:
+ 0 0 0 1px var(--bg-app),
+ 0 0 24px currentColor,
+ inset 0 0 16px rgba(255, 255, 255, 0.1);
+}
+
+/* edges glow */
+:root[data-theme="cyber"] .edge path {
+ stroke: var(--neon-magenta) !important;
+ filter: drop-shadow(0 0 4px var(--neon-magenta));
+}
+
+/* ─── SQUARE NODES — terminal modules ─── */
+:root[data-theme="cyber"] .sq-node-box {
+ background: linear-gradient(180deg, rgba(245,30,182,0.10), rgba(0,0,0,0.6));
+ border: 1px solid var(--neon-magenta);
+ border-radius: 0;
+ box-shadow:
+ inset 0 0 0 1px rgba(0,0,0,0.6),
+ 0 0 12px rgba(245,30,182,0.4);
+ color: var(--neon-magenta);
+ text-shadow: 0 0 4px currentColor;
+}
+:root[data-theme="cyber"] .sq-node.selected .sq-node-box {
+ border-color: var(--neon-cyan);
+ color: var(--neon-cyan);
+ box-shadow:
+ inset 0 0 0 1px rgba(0,0,0,0.6),
+ 0 0 0 1px var(--neon-cyan),
+ 0 0 20px var(--neon-cyan);
+ animation: cyber-blink 1.6s steps(2) infinite;
+}
+:root[data-theme="cyber"] .sq-node-pip {
+ border-radius: 0;
+ width: 8px; height: 8px;
+ box-shadow: 0 0 6px currentColor;
+}
+:root[data-theme="cyber"] .sq-node-gear {
+ background: var(--bg-app);
+ border: 1px solid var(--neon-cyan);
+ color: var(--neon-cyan);
+ border-radius: 0;
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .sq-node-handle {
+ border-radius: 0;
+ background: var(--neon-magenta);
+ border-color: var(--neon-magenta);
+ box-shadow: 0 0 4px var(--neon-magenta);
+}
+:root[data-theme="cyber"] .sq-node-handle.out { background: var(--neon-cyan); border-color: var(--neon-cyan); box-shadow: 0 0 4px var(--neon-cyan); }
+:root[data-theme="cyber"] .sq-node-label {
+ font-family: var(--font-mono);
+ text-transform: uppercase;
+ letter-spacing: 0.14em;
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+ font-size: 10px;
+}
+
+/* ─── CATEGORIES — system blocks ─── */
+:root[data-theme="cyber"] .cat {
+ background: rgba(0,0,0,0.4);
+ border: 1px solid var(--border-default);
+ border-radius: 0;
+}
+:root[data-theme="cyber"] .cat-head {
+ border-bottom: 1px solid var(--neon-magenta);
+ background: rgba(245,30,182,0.06);
+}
+:root[data-theme="cyber"] .cat-tile {
+ background: rgba(0,0,0,0.5);
+ border: 1px solid var(--cat-color, var(--neon-magenta));
+ color: var(--cat-color, var(--neon-magenta));
+ border-radius: 0;
+ box-shadow: 0 0 6px currentColor;
+}
+:root[data-theme="cyber"] .cat-name {
+ font-family: var(--font-display);
+ letter-spacing: 0.18em;
+ text-transform: uppercase;
+ color: var(--neon-magenta);
+ text-shadow: 0 0 4px currentColor;
+}
+:root[data-theme="cyber"] .cat-count {
+ background: var(--bg-app);
+ border: 1px solid var(--neon-cyan);
+ color: var(--neon-cyan);
+ border-radius: 0;
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .cat-chev {
+ color: var(--neon-magenta);
+ text-shadow: 0 0 4px currentColor;
+}
+
+/* ─── COMP ITEMS ─── */
+:root[data-theme="cyber"] .comp {
+ background: rgba(0,0,0,0.5);
+ border: 1px solid var(--border-default);
+ border-radius: 0;
+ position: relative;
+}
+:root[data-theme="cyber"] .comp::before {
+ content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
+ background: var(--cat-color, var(--neon-magenta));
+ opacity: 0.6;
+}
+:root[data-theme="cyber"] .comp:hover {
+ border-color: var(--cat-color, var(--neon-magenta));
+ background: rgba(245,30,182,0.08);
+ box-shadow: 0 0 12px rgba(245,30,182,0.3);
+}
+:root[data-theme="cyber"] .comp-ico {
+ background: rgba(0,0,0,0.6);
+ border: 1px solid var(--cat-color, var(--neon-magenta));
+ color: var(--cat-color, var(--neon-magenta));
+ border-radius: 0;
+ box-shadow: 0 0 6px currentColor;
+}
+:root[data-theme="cyber"] .comp-name {
+ font-family: var(--font-display);
+ letter-spacing: 0.10em;
+ text-transform: uppercase;
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .comp-desc {
+ font-family: var(--font-mono);
+ color: var(--fg-muted);
+}
+:root[data-theme="cyber"] .comp-grip { color: var(--neon-magenta); }
+
+/* ─── MENU POP ─── */
+:root[data-theme="cyber"] .menu-pop {
+ background: rgba(10,4,32,0.98);
+ border: 1px solid var(--neon-magenta);
+ border-radius: 0;
+ box-shadow:
+ inset 0 0 0 1px var(--bg-app),
+ inset 0 0 0 2px var(--neon-cyan),
+ 0 0 30px rgba(245,30,182,0.4);
+}
+:root[data-theme="cyber"] .menu-pop-item {
+ font-family: var(--font-mono);
+ font-size: 12px;
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .menu-pop-item::before { content: '> '; opacity: 0.5; }
+:root[data-theme="cyber"] .menu-pop-item:hover {
+ background: var(--bg-active);
+ color: var(--neon-magenta);
+}
+
+/* ─── SETTINGS SECTIONS ─── */
+:root[data-theme="cyber"] .settings-section {
+ background: rgba(0,0,0,0.4);
+ border: 1px solid var(--neon-magenta);
+ border-radius: 0;
+ position: relative;
+}
+:root[data-theme="cyber"] .settings-section::before {
+ content: ''; position: absolute; left: 0; top: 0; right: 0; height: 2px;
+ background: var(--neon-magenta);
+ box-shadow: 0 0 8px var(--neon-magenta);
+}
+:root[data-theme="cyber"] .settings-section h3 {
+ color: var(--neon-cyan);
+ font-family: var(--font-display);
+ letter-spacing: 0.16em;
+ text-transform: uppercase;
+ text-shadow: 0 0 4px currentColor;
+ border-bottom: 1px solid var(--border-default);
+ padding-bottom: 8px;
+}
+:root[data-theme="cyber"] .settings-section h3::before { content: '◆ '; color: var(--neon-magenta); }
+:root[data-theme="cyber"] .settings-summary {
+ background: rgba(0,0,0,0.6);
+ border: 1px solid var(--neon-cyan);
+ font-family: var(--font-mono);
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+ border-radius: 0;
+}
+
+/* ─── CRED CARDS ─── */
+:root[data-theme="cyber"] .cred-card {
+ background: rgba(0,0,0,0.5);
+ border: 1px solid var(--cred-color, var(--neon-magenta));
+ border-radius: 0;
+ box-shadow: 0 0 12px color-mix(in srgb, var(--cred-color, var(--neon-magenta)) 25%, transparent);
+}
+:root[data-theme="cyber"] .cred-card-head {
+ background: rgba(245,30,182,0.08);
+ border-bottom: 1px solid var(--cred-color, var(--neon-magenta));
+}
+:root[data-theme="cyber"] .cred-card .name {
+ font-family: var(--font-display);
+ letter-spacing: 0.18em;
+ text-transform: uppercase;
+ color: var(--cred-color, var(--neon-magenta));
+ text-shadow: 0 0 4px currentColor;
+}
+:root[data-theme="cyber"] .cred-tag {
+ font-family: var(--font-mono);
+ letter-spacing: 0.10em;
+ text-transform: uppercase;
+ border-radius: 0;
+ text-shadow: 0 0 3px currentColor;
+ font-size: 9px;
+}
+
+/* Credential rows — connection traces */
+:root[data-theme="cyber"] .cred-row {
+ background: rgba(0, 0, 0, 0.4);
+ border: 1px solid var(--border-default);
+ border-radius: 0;
+ position: relative;
+}
+:root[data-theme="cyber"] .cred-row::before {
+ content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
+ background: var(--neon-magenta);
+ box-shadow: 0 0 6px var(--neon-magenta);
+}
+:root[data-theme="cyber"] .cred-row .name {
+ font-family: var(--font-display);
+ letter-spacing: 0.16em;
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+ font-size: 11px;
+}
+:root[data-theme="cyber"] .cred-row .badge {
+ font-family: var(--font-mono);
+ font-size: 9px;
+ letter-spacing: 0.1em;
+ text-transform: uppercase;
+ border-radius: 0;
+ text-shadow: 0 0 3px currentColor;
+}
+
+/* ─── PARAMETER PANEL COLS ─── */
+:root[data-theme="cyber"] .param-col {
+ background: rgba(0,0,0,0.4);
+ border-right: 1px solid var(--neon-magenta);
+}
+:root[data-theme="cyber"] .param-col-head {
+ background: rgba(245,30,182,0.10);
+ border-bottom: 1px solid var(--neon-magenta);
+ font-family: var(--font-display);
+ color: var(--neon-cyan);
+ letter-spacing: 0.16em;
+ text-transform: uppercase;
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .json-block {
+ background: rgba(0,0,0,0.7);
+ border: 1px solid var(--border-default);
+ font-family: var(--font-mono);
+ color: var(--neon-green);
+ text-shadow: 0 0 3px currentColor;
+ border-radius: 0;
+}
+:root[data-theme="cyber"] .json-key { color: var(--neon-cyan); text-shadow: 0 0 3px currentColor; }
+:root[data-theme="cyber"] .json-str { color: var(--neon-green); }
+:root[data-theme="cyber"] .json-num { color: var(--neon-yellow); text-shadow: 0 0 3px currentColor; }
+
+/* ─── CHAT TABS ─── */
+:root[data-theme="cyber"] .chat-tab {
+ font-family: var(--font-display);
+ letter-spacing: 0.14em;
+ text-transform: uppercase;
+ font-size: 10px;
+ border-radius: 0;
+ color: var(--fg-muted);
+}
+:root[data-theme="cyber"] .chat-tab.active {
+ background: var(--neon-magenta);
+ color: var(--bg-app);
+ text-shadow: none;
+ box-shadow: 0 0 8px var(--neon-magenta);
+}
+
+/* ─── CHAT MESSAGES — DM transmission ─── */
+:root[data-theme="cyber"] .chat-msg {
+ font-family: var(--font-mono);
+ font-size: 12px;
+ border-radius: 0;
+ position: relative;
+}
+:root[data-theme="cyber"] .chat-msg-user {
+ background: rgba(245, 30, 182, 0.15);
+ color: var(--neon-magenta);
+ border: 1px solid var(--neon-magenta);
+ text-shadow: 0 0 3px currentColor;
+ box-shadow: 0 0 8px rgba(245, 30, 182, 0.3);
+}
+:root[data-theme="cyber"] .chat-msg-user::before { content: '> USER:: '; opacity: 0.6; }
+:root[data-theme="cyber"] .chat-msg-bot {
+ background: rgba(29, 217, 229, 0.08);
+ color: var(--neon-cyan);
+ border: 1px solid var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .chat-msg-bot::before { content: '< NODE:: '; opacity: 0.6; }
+
+/* ─── THEME SWITCHER ─── */
+:root[data-theme="cyber"] .theme-switcher {
+ background: rgba(10, 4, 32, 0.95);
+ border: 1px solid var(--neon-magenta);
+ box-shadow: 0 0 16px rgba(245, 30, 182, 0.5);
+}
+:root[data-theme="cyber"] .theme-switcher button {
+ font-family: var(--font-display);
+ text-shadow: 0 0 4px currentColor;
+}
+
+/* ─── EMPTY STATE ─── */
+:root[data-theme="cyber"] .empty-state .glyph {
+ font-family: var(--font-display);
+ font-size: 64px;
+ color: var(--neon-magenta);
+ text-shadow: 0 0 16px var(--neon-magenta);
+}
+
+/* ─── STATUS BAR — system console ─── */
+:root[data-theme="cyber"] .statusbar {
+ background: rgba(5, 0, 16, 0.95);
+ border-top: 1px solid var(--neon-magenta);
+ box-shadow: 0 -1px 12px rgba(245, 30, 182, 0.3);
+ font-family: var(--font-mono);
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+ letter-spacing: 0.08em;
+}
+:root[data-theme="cyber"] .statusbar .pip {
+ background: var(--neon-green);
+ box-shadow: 0 0 8px var(--neon-green);
+ animation: cyber-blink 1.4s steps(2) infinite;
+ border-radius: 0;
+}
+
+/* ─── MODAL — terminal popup ─── */
+:root[data-theme="cyber"] .modal {
+ background:
+ linear-gradient(180deg, rgba(245, 30, 182, 0.06), transparent 60px),
+ var(--bg-panel);
+ border: 1px solid var(--neon-magenta);
+ border-radius: 0;
+ box-shadow:
+ inset 0 0 0 1px var(--bg-app),
+ inset 0 0 0 2px var(--neon-cyan),
+ 0 0 60px rgba(245, 30, 182, 0.5),
+ 0 30px 80px rgba(0, 0, 0, 0.8);
+ position: relative;
+}
+:root[data-theme="cyber"] .modal::before {
+ content: ''; position: absolute; inset: 0;
+ background: repeating-linear-gradient(0deg, transparent 0 2px, rgba(0,0,0,0.2) 2px 3px);
+ pointer-events: none; mix-blend-mode: multiply;
+}
+:root[data-theme="cyber"] .modal-head {
+ border-bottom: 1px solid var(--neon-magenta);
+ background: linear-gradient(180deg, rgba(245, 30, 182, 0.12), transparent);
+ padding: 14px 18px;
+}
+:root[data-theme="cyber"] .modal-title {
+ color: var(--neon-magenta);
+ text-shadow: 0 0 4px currentColor;
+ font-family: var(--font-display);
+}
+:root[data-theme="cyber"] .modal-title::before { content: '◆ '; }
+:root[data-theme="cyber"] .modal-foot {
+ border-top: 1px solid var(--border-default);
+}
+:root[data-theme="cyber"] .field label {
+ color: var(--neon-cyan);
+ text-shadow: 0 0 3px currentColor;
+}
+:root[data-theme="cyber"] .field label::before { content: '> '; opacity: 0.6; }
+
+/* ─── COMMAND PALETTE — root terminal ─── */
+:root[data-theme="cyber"] .cmdk {
+ background: rgba(10, 4, 32, 0.98);
+ border: 1px solid var(--neon-magenta);
+ border-radius: 0;
+ box-shadow:
+ inset 0 0 0 2px var(--bg-app),
+ inset 0 0 0 3px var(--neon-cyan),
+ 0 0 60px rgba(245, 30, 182, 0.6);
+}
+:root[data-theme="cyber"] .cmdk input {
+ font-family: var(--font-mono);
+ font-size: 14px;
+ background: transparent;
+ color: var(--neon-magenta);
+ border-bottom: 1px solid var(--neon-magenta);
+ padding-left: 30px;
+ background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M2 2 L6 6 L2 10' fill='none' stroke='%23f51eb6' stroke-width='1.5'/></svg>");
+ background-repeat: no-repeat;
+ background-position: 14px center;
+ background-size: 12px;
+ text-shadow: 0 0 4px currentColor;
+ caret-color: var(--neon-magenta);
+}
+:root[data-theme="cyber"] .cmdk input::placeholder { color: var(--fg-faint); }
+:root[data-theme="cyber"] .cmdk-item {
+ font-family: var(--font-mono);
+ font-size: 12px;
+ border-radius: 0;
+ color: var(--fg-muted);
+ border-left: 2px solid transparent;
+ padding-left: 8px;
+}
+:root[data-theme="cyber"] .cmdk-item.active {
+ background: var(--bg-active);
+ color: var(--neon-magenta);
+ border-left-color: var(--neon-magenta);
+ text-shadow: 0 0 4px currentColor;
+}
+:root[data-theme="cyber"] .cmdk-item.active::after {
+ content: ' ◀'; margin-left: auto;
+ color: var(--neon-magenta);
+ animation: cyber-blink 0.6s steps(2) infinite;
+}
+:root[data-theme="cyber"] .cmdk-item kbd {
+ background: rgba(0,0,0,0.4);
+ border: 1px solid var(--neon-cyan);
+ color: var(--neon-cyan);
+ font-family: var(--font-mono);
+ border-radius: 0;
+ text-shadow: 0 0 3px currentColor;
+}
+
+/* Headings — neon glow + glitch on hover */
+:root[data-theme="cyber"] .v-display {
+ font-family: var(--font-display);
+ letter-spacing: var(--type-tracking-display);
+ text-transform: uppercase;
+ color: var(--neon-magenta);
+ text-shadow:
+ 0 0 4px var(--neon-magenta),
+ 0 0 12px var(--neon-magenta),
+ 1px 0 0 var(--neon-cyan);
+}
+:root[data-theme="cyber"] .v-display:hover { animation: cyber-glitch 0.4s steps(8); }
diff --git a/client/src/themes/edo.css b/client/src/themes/edo.css
index afb5b78d..ff85ed66 100644
--- a/client/src/themes/edo.css
+++ b/client/src/themes/edo.css
@@ -132,3 +132,93 @@
background: rgba(180, 30, 30, 0.30);
color: #1a1410;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─────────────── */
+
+:root[data-theme="edo"] .toolbar,
+:root[data-theme="edo"] .sidebar,
+:root[data-theme="edo"] .palette,
+:root[data-theme="edo"] .chat {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='300'><filter id='w'><feTurbulence baseFrequency='0.95' numOctaves='1'/><feColorMatrix values='0 0 0 0 0.65 0 0 0 0 0.55 0 0 0 0 0.35 0 0 0 0.05 0'/></filter><rect width='300' height='300' filter='url(%23w)'/></svg>"),
+ var(--bg-panel);
+}
+:root[data-theme="edo"] .toolbar { border-bottom: 1px solid var(--sumi); }
+:root[data-theme="edo"] .sidebar { border-right: 1px solid var(--sumi); }
+:root[data-theme="edo"] .palette { border-left: 1px solid var(--sumi); }
+:root[data-theme="edo"] .chat { border-top: 1px solid var(--sumi); }
+
+/* Canvas — empty rice paper with one ink-wash mountain */
+:root[data-theme="edo"] .canvas {
+ background:
+ radial-gradient(ellipse 600px 200px at 80% 90%, rgba(26,20,16,0.10), transparent 60%),
+ var(--bg-canvas);
+}
+
+/* Typography — light, generous, asymmetric */
+:root[data-theme="edo"] body { font-family: var(--font-body); color: var(--fg-default); }
+:root[data-theme="edo"] h1, :root[data-theme="edo"] h2, :root[data-theme="edo"] h3,
+:root[data-theme="edo"] .v-display { font-family: var(--font-display); font-weight: 400; letter-spacing: 0.04em; }
+
+/* Square node — hanko seal + ink calligraphy */
+:root[data-theme="edo"] .sq-node-box {
+ background: var(--bg-elevated);
+ border: 1px solid var(--sumi); border-radius: 0;
+ box-shadow: none;
+ color: var(--sumi);
+ position: relative;
+}
+:root[data-theme="edo"] .sq-node.selected .sq-node-box {
+ border: 2px solid hsl(var(--accent));
+ background: var(--bg-elevated);
+}
+:root[data-theme="edo"] .sq-node.selected .sq-node-box::before {
+ content: ''; position: absolute; top: 4px; right: 4px; width: 14px; height: 14px;
+ background: hsl(var(--accent)); transform: rotate(8deg);
+}
+:root[data-theme="edo"] .sq-node-pip { border-radius: 0; }
+:root[data-theme="edo"] .sq-node-gear { background: hsl(var(--accent)); color: white; border-radius: 0; border: none; }
+:root[data-theme="edo"] .sq-node-handle { border-radius: 0; }
+:root[data-theme="edo"] .sq-node-label { font-family: var(--font-display); font-weight: 500; font-size: 11px; letter-spacing: 0.04em; }
+
+/* Actions — minimal */
+:root[data-theme="edo"] .action-btn {
+ border-radius: 0; font-family: var(--font-display); font-size: 12px; letter-spacing: 0.06em; font-weight: 500;
+ border-width: 1px;
+}
+:root[data-theme="edo"] .action-run { background: transparent; color: var(--bamboo); border-color: var(--bamboo); }
+:root[data-theme="edo"] .action-deploy { background: transparent; color: hsl(var(--accent)); border-color: hsl(var(--accent)); }
+:root[data-theme="edo"] .action-save { background: hsl(var(--accent)); color: var(--fg-on-accent); border-color: hsl(var(--accent)); }
+
+/* Cards / panels — minimal lines */
+:root[data-theme="edo"] .wf-card,
+:root[data-theme="edo"] .cat,
+:root[data-theme="edo"] .comp,
+:root[data-theme="edo"] .settings-section,
+:root[data-theme="edo"] .cred-card {
+ border-radius: 0; background: var(--bg-elevated); border: 1px solid var(--border-default);
+}
+:root[data-theme="edo"] .wf-card.selected { border-left: 3px solid hsl(var(--accent)); }
+:root[data-theme="edo"] .cat-tile { background: transparent; border: 1px solid var(--sumi); color: var(--sumi); border-radius: 0; }
+:root[data-theme="edo"] .comp-ico { background: transparent; border: 1px solid var(--border-default); color: var(--sumi); border-radius: 0; }
+
+/* Chat */
+:root[data-theme="edo"] .chat-msg { border-radius: 0; }
+:root[data-theme="edo"] .chat-msg-user { background: transparent; border: 1px solid hsl(var(--accent)); }
+:root[data-theme="edo"] .chat-msg-bot { background: var(--bg-elevated); border-left: 3px solid var(--sumi); border-top: none; border-right: none; border-bottom: none; }
+
+/* Status bar */
+:root[data-theme="edo"] .statusbar {
+ background: var(--bg-panel); border-top: 1px solid var(--sumi);
+ font-family: var(--font-mono); color: var(--fg-muted);
+}
+:root[data-theme="edo"] .statusbar .pip { background: var(--bamboo); border-radius: 0; }
+
+/* Modal */
+:root[data-theme="edo"] .modal { background: var(--bg-elevated); border: 1px solid var(--sumi); border-radius: 0; }
+:root[data-theme="edo"] .modal-head { border-bottom: 1px solid var(--sumi); }
+:root[data-theme="edo"] .modal-title { font-family: var(--font-display); color: hsl(var(--accent)); }
+
+/* CMDK */
+:root[data-theme="edo"] .cmdk { background: var(--bg-elevated); border: 1px solid var(--sumi); border-radius: 0; }
+:root[data-theme="edo"] .cmdk-item.active { background: var(--bg-active); border-left: 3px solid hsl(var(--accent)); }
diff --git a/client/src/themes/greek.css b/client/src/themes/greek.css
index 286409ff..e3396507 100644
--- a/client/src/themes/greek.css
+++ b/client/src/themes/greek.css
@@ -165,3 +165,104 @@
background: rgba(40, 75, 130, 0.4);
color: #2a2415;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─────────────── */
+
+:root[data-theme="greek"] .toolbar { border-bottom: 3px solid var(--border-strong); position: relative; }
+:root[data-theme="greek"] .toolbar::after {
+ content: ''; position: absolute; left: 0; right: 0; bottom: -8px; height: 5px;
+ background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='5' viewBox='0 0 40 5'><path d='M0 0 H40 V5 H0 Z M2 1 H6 V3 H4 V2 H8 V4 H2 Z M12 1 H16 V3 H14 V2 H18 V4 H12 Z M22 1 H26 V3 H24 V2 H28 V4 H22 Z M32 1 H36 V3 H34 V2 H38 V4 H32 Z' fill='%234a3818'/></svg>") repeat-x;
+ pointer-events: none;
+}
+:root[data-theme="greek"] .sidebar { border-right: 3px solid var(--border-strong); }
+:root[data-theme="greek"] .palette { border-left: 3px solid var(--border-strong); }
+:root[data-theme="greek"] .chat { border-top: 3px solid var(--border-strong); }
+
+/* Typography */
+:root[data-theme="greek"] body { font-family: var(--font-body); color: var(--fg-default); font-size: 14px; line-height: 1.5; }
+:root[data-theme="greek"] h1, :root[data-theme="greek"] h2, :root[data-theme="greek"] h3,
+:root[data-theme="greek"] .v-display {
+ font-family: var(--font-display);
+ letter-spacing: 0.18em;
+ text-transform: uppercase;
+ color: var(--fg-default);
+}
+
+/* Square node — temple stelae */
+:root[data-theme="greek"] .sq-node-box {
+ background: linear-gradient(180deg, var(--bg-elevated), var(--marble-vein));
+ border: 2px solid var(--border-strong);
+ border-radius: 0;
+ box-shadow: 0 3px 0 var(--border-strong), inset 0 0 0 1px var(--gold);
+ color: hsl(var(--accent));
+}
+:root[data-theme="greek"] .sq-node.selected .sq-node-box {
+ border-color: hsl(var(--accent)); box-shadow: 0 0 0 3px hsl(var(--info-soft)), 0 3px 0 var(--border-strong), inset 0 0 0 1px var(--gold);
+}
+:root[data-theme="greek"] .sq-node-pip { border-radius: 0; box-shadow: 0 0 0 1px var(--border-strong); }
+:root[data-theme="greek"] .sq-node-gear { background: var(--gold); color: var(--border-strong); border: 1px solid var(--border-strong); border-radius: 0; }
+:root[data-theme="greek"] .sq-node-handle { border-radius: 0; }
+:root[data-theme="greek"] .sq-node-handle.out { background: var(--oxblood); }
+:root[data-theme="greek"] .sq-node-label {
+ font-family: var(--font-display); letter-spacing: 0.14em; font-size: 10px; color: var(--fg-default);
+ text-transform: uppercase;
+}
+
+/* Toolbar actions — stamped */
+:root[data-theme="greek"] .action-btn {
+ border-radius: 0; font-family: var(--font-display); letter-spacing: 0.12em; text-transform: uppercase; font-size: 11px;
+ border-width: 2px;
+}
+:root[data-theme="greek"] .action-run { background: hsl(var(--success-soft)); color: hsl(var(--success)); border-color: hsl(var(--success)); }
+:root[data-theme="greek"] .action-deploy { background: hsl(var(--info-soft)); color: hsl(var(--accent)); border-color: hsl(var(--accent)); }
+:root[data-theme="greek"] .action-save { background: hsl(var(--warning-soft)); color: var(--oxblood); border-color: var(--gold); }
+
+/* Panels */
+:root[data-theme="greek"] .palette h2,
+:root[data-theme="greek"] .sidebar-head h3 {
+ font-family: var(--font-display); letter-spacing: 0.20em; color: var(--fg-default);
+ border-bottom: 2px solid var(--border-strong); padding-bottom: 6px;
+}
+
+/* Workflow cards */
+:root[data-theme="greek"] .wf-card { background: var(--bg-elevated); border: 2px solid var(--border-default); border-radius: 0; }
+:root[data-theme="greek"] .wf-card.selected { border-color: hsl(var(--accent)); background: hsl(var(--info-soft)); }
+:root[data-theme="greek"] .wf-card-name { font-family: var(--font-display); letter-spacing: 0.10em; }
+
+/* Palette categories */
+:root[data-theme="greek"] .cat { background: var(--bg-elevated); border: 2px solid var(--border-default); border-radius: 0; }
+:root[data-theme="greek"] .cat-tile { background: var(--gold); border: 1px solid var(--border-strong); border-radius: 0; color: var(--border-strong); }
+:root[data-theme="greek"] .cat-name { font-family: var(--font-display); letter-spacing: 0.16em; color: hsl(var(--accent)); }
+:root[data-theme="greek"] .cat-count { background: var(--bg-active); border: 1px solid var(--border-default); border-radius: 0; }
+
+/* Comp items */
+:root[data-theme="greek"] .comp { background: var(--bg-panel); border: 1px solid var(--border-default); border-radius: 0; }
+:root[data-theme="greek"] .comp:hover { border-color: hsl(var(--accent)); }
+:root[data-theme="greek"] .comp-ico { background: var(--bg-elevated); border: 1px solid var(--border-default); color: hsl(var(--accent)); border-radius: 0; }
+:root[data-theme="greek"] .comp-name { font-family: var(--font-display); font-size: 12px; letter-spacing: 0.10em; }
+
+/* Chat */
+:root[data-theme="greek"] .chat-msg { border-radius: 0; }
+:root[data-theme="greek"] .chat-msg-user { background: hsl(var(--info-soft)); border: 2px solid hsl(var(--accent)); }
+:root[data-theme="greek"] .chat-msg-bot { background: var(--bg-elevated); border: 2px solid var(--border-default); }
+
+/* Status bar */
+:root[data-theme="greek"] .statusbar {
+ background: var(--bg-panel); border-top: 2px solid var(--border-strong);
+ font-family: var(--font-mono); color: var(--fg-muted); letter-spacing: 0.06em;
+}
+:root[data-theme="greek"] .statusbar .pip { background: hsl(var(--success)); border-radius: 0; }
+
+/* Modal — temple inscription */
+:root[data-theme="greek"] .modal {
+ background: var(--bg-elevated); border: 4px double var(--border-strong); border-radius: 0;
+ box-shadow: 0 30px 80px rgba(60, 50, 30, 0.4);
+}
+:root[data-theme="greek"] .modal-head { border-bottom: 3px solid var(--border-strong); }
+:root[data-theme="greek"] .modal-title { font-family: var(--font-display); letter-spacing: 0.18em; color: hsl(var(--accent)); }
+
+/* Command palette */
+:root[data-theme="greek"] .cmdk { background: var(--bg-elevated); border: 4px double var(--border-strong); border-radius: 0; }
+:root[data-theme="greek"] .cmdk input { font-family: var(--font-display); letter-spacing: 0.12em; }
+:root[data-theme="greek"] .cmdk-item.active { background: hsl(var(--info-soft)); color: hsl(var(--accent)); }
+:root[data-theme="greek"] .cmdk-item.active::before { content: '◆ '; color: var(--gold); }
diff --git a/client/src/themes/plague.css b/client/src/themes/plague.css
index 837e9a81..36cafa60 100644
--- a/client/src/themes/plague.css
+++ b/client/src/themes/plague.css
@@ -132,3 +132,92 @@
background: rgba(120, 60, 40, 0.45);
color: #efeacf;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+:root[data-theme="plague"] .toolbar,
+:root[data-theme="plague"] .sidebar,
+:root[data-theme="plague"] .palette,
+:root[data-theme="plague"] .chat { background: var(--bg-panel); }
+:root[data-theme="plague"] .toolbar { border-bottom: 3px solid var(--crow); }
+:root[data-theme="plague"] .sidebar { border-right: 3px solid var(--crow); }
+:root[data-theme="plague"] .palette { border-left: 3px solid var(--crow); }
+:root[data-theme="plague"] .chat { border-top: 3px solid var(--crow); }
+
+/* CANVAS — broadsheet with red X marks */
+:root[data-theme="plague"] .canvas {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><g stroke='%23783c28' stroke-width='1.6' fill='none' opacity='0.10' stroke-linecap='square'><path d='M40 40 L60 60 M60 40 L40 60'/><path d='M180 80 L200 100 M200 80 L180 100'/><path d='M80 180 L100 200 M100 180 L80 200'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* TYPOGRAPHY — proclamation */
+:root[data-theme="plague"] body { font-family: var(--font-body); color: var(--fg-default); }
+:root[data-theme="plague"] h1, :root[data-theme="plague"] h2, :root[data-theme="plague"] h3,
+:root[data-theme="plague"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.04em; text-transform: uppercase; color: hsl(var(--accent));
+}
+
+/* SQUARE NODE — quarantine notice nailed up */
+:root[data-theme="plague"] .sq-node-box {
+ background: var(--linen);
+ border: 2px solid var(--crow); border-radius: 0;
+ box-shadow: 3px 3px 0 var(--crow);
+ color: var(--crow);
+ position: relative;
+}
+:root[data-theme="plague"] .sq-node-box::after {
+ content: ''; position: absolute; top: -3px; left: 50%; width: 6px; height: 6px;
+ background: var(--crow); transform: translateX(-50%);
+}
+:root[data-theme="plague"] .sq-node.selected .sq-node-box { border-color: hsl(var(--accent)); background: hsl(var(--danger-soft)); }
+:root[data-theme="plague"] .sq-node-gear { background: hsl(var(--accent)); color: var(--linen); border: none; border-radius: 0; }
+:root[data-theme="plague"] .sq-node-handle { border-radius: 0; }
+:root[data-theme="plague"] .sq-node-handle.out { background: hsl(var(--accent)); }
+:root[data-theme="plague"] .sq-node-label { font-family: var(--font-display); letter-spacing: 0.06em; color: hsl(var(--accent)); font-weight: 400; }
+
+/* ACTIONS — official stamps */
+:root[data-theme="plague"] .action-btn {
+ font-family: var(--font-display); font-size: 12px; letter-spacing: 0.10em; text-transform: uppercase;
+ border-radius: 0; border-width: 2px; font-weight: 400;
+}
+:root[data-theme="plague"] .action-run { background: hsl(var(--success-soft)); color: hsl(var(--success)); border-color: hsl(var(--success)); }
+:root[data-theme="plague"] .action-deploy { background: hsl(var(--danger-soft)); color: hsl(var(--accent)); border-color: hsl(var(--accent)); }
+:root[data-theme="plague"] .action-save { background: hsl(var(--warning-soft)); color: var(--bile); border-color: var(--bile); }
+
+/* CARDS */
+:root[data-theme="plague"] .wf-card,
+:root[data-theme="plague"] .cat,
+:root[data-theme="plague"] .comp,
+:root[data-theme="plague"] .settings-section,
+:root[data-theme="plague"] .cred-card {
+ background: var(--linen); border: 1px solid var(--crow); border-radius: 0; box-shadow: 2px 2px 0 var(--border-default);
+}
+:root[data-theme="plague"] .wf-card.selected { background: hsl(var(--danger-soft)); border: 2px solid hsl(var(--accent)); }
+:root[data-theme="plague"] .cat-tile { background: var(--crow); color: var(--linen); border-radius: 0; }
+:root[data-theme="plague"] .cat-name { font-family: var(--font-display); }
+:root[data-theme="plague"] .comp-ico { background: var(--bg-panel); color: hsl(var(--accent)); border: 1px solid var(--crow); border-radius: 0; }
+
+/* CHAT */
+:root[data-theme="plague"] .chat-msg-user { background: hsl(var(--danger-soft)); border: 1px solid hsl(var(--accent)); border-radius: 0; }
+:root[data-theme="plague"] .chat-msg-bot { background: var(--linen); border: 1px solid var(--crow); border-radius: 0; }
+
+/* STATUS BAR */
+:root[data-theme="plague"] .statusbar {
+ background: var(--crow); color: var(--linen); border-top: 3px solid hsl(var(--accent));
+ font-family: var(--font-mono); letter-spacing: 0.08em;
+}
+:root[data-theme="plague"] .statusbar .pip { background: var(--bile); border-radius: 0; }
+
+/* MODAL */
+:root[data-theme="plague"] .modal {
+ background: var(--linen); border: 4px double var(--crow); border-radius: 0;
+ box-shadow: 8px 8px 0 hsl(var(--accent));
+}
+:root[data-theme="plague"] .modal-head { border-bottom: 3px double var(--crow); }
+:root[data-theme="plague"] .modal-title { font-family: var(--font-display); color: hsl(var(--accent)); }
+
+/* CMDK */
+:root[data-theme="plague"] .cmdk { background: var(--linen); border: 4px double var(--crow); border-radius: 0; }
+:root[data-theme="plague"] .cmdk-item.active { background: hsl(var(--danger-soft)); color: hsl(var(--accent)); }
+:root[data-theme="plague"] .cmdk-item.active::before { content: '† '; color: hsl(var(--accent)); }
diff --git a/client/src/themes/renaissance.css b/client/src/themes/renaissance.css
index f512eec1..85c8842c 100644
--- a/client/src/themes/renaissance.css
+++ b/client/src/themes/renaissance.css
@@ -169,3 +169,487 @@
background: rgba(212, 160, 48, 0.5);
color: #3a2008;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+/* Floating illuminated initial as ambient ornament */
+@keyframes ren-flicker {
+ 0%, 100% { opacity: 0.5; }
+ 50% { opacity: 0.8; }
+}
+
+/* ─── ILLUMINATED FRAME with gilded corners ─── */
+:root[data-theme="renaissance"] .app-frame {
+ box-shadow: var(--ornament-frame), 0 0 60px rgba(90, 50, 18, 0.3) inset;
+ position: relative;
+}
+:root[data-theme="renaissance"] .app-frame::before,
+:root[data-theme="renaissance"] .app-frame::after {
+ content: ''; position: absolute; width: 36px; height: 36px;
+ background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 36 36'><path d='M2 2 L34 2 L34 6 L6 6 L6 34 L2 34 Z' fill='%23d4a030' stroke='%235a3a14' stroke-width='1'/><circle cx='6' cy='6' r='3' fill='%238a1410' stroke='%235a3a14' stroke-width='0.8'/><path d='M10 2 L14 2 M18 2 L22 2 M26 2 L30 2 M2 10 L2 14 M2 18 L2 22 M2 26 L2 30' stroke='%235a3a14' stroke-width='0.6'/></svg>") no-repeat;
+ pointer-events: none; z-index: 100;
+}
+:root[data-theme="renaissance"] .app-frame::before { top: 0; left: 0; }
+:root[data-theme="renaissance"] .app-frame::after { top: 0; right: 0; transform: scaleX(-1); }
+
+/* ─── PANELS get a vellum lining ─── */
+:root[data-theme="renaissance"] .toolbar,
+:root[data-theme="renaissance"] .sidebar,
+:root[data-theme="renaissance"] .palette,
+:root[data-theme="renaissance"] .chat {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.36 0 0 0 0 0.23 0 0 0 0 0.05 0 0 0 0.06 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>"),
+ var(--bg-panel);
+}
+:root[data-theme="renaissance"] .toolbar { border-bottom: 2px double var(--border-strong); }
+:root[data-theme="renaissance"] .sidebar { border-right: 2px double var(--border-strong); }
+:root[data-theme="renaissance"] .palette { border-left: 2px double var(--border-strong); }
+:root[data-theme="renaissance"] .chat { border-top: 2px double var(--border-strong); }
+
+/* ─── CANVAS — workshop floor with fleur-de-lis pattern + vignette ─── */
+:root[data-theme="renaissance"] .canvas {
+ background:
+ radial-gradient(ellipse at center, transparent 30%, rgba(90, 50, 18, 0.25) 100%),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'><g fill='none' stroke='%238a5e1c' stroke-width='0.4' opacity='0.35'><path d='M40 22 Q35 32, 30 32 Q26 32, 28 28 Q32 26, 40 28 Q48 26, 52 28 Q54 32, 50 32 Q45 32, 40 22 Z'/><path d='M40 28 L40 40 M36 36 L44 36'/><circle cx='40' cy='42' r='2'/></g></svg>"),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence baseFrequency='0.95' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.36 0 0 0 0 0.23 0 0 0 0 0.05 0 0 0 0.08 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>"),
+ var(--bg-canvas);
+}
+
+/* Marginalia — handwritten marginal note in canvas */
+:root[data-theme="renaissance"] .canvas::before {
+ content: '" Ars longa, vita brevis "';
+ position: absolute; bottom: 12px; right: 16px;
+ font-family: var(--font-mono);
+ font-style: italic;
+ font-size: 13px;
+ color: var(--border-default);
+ opacity: 0.7;
+ transform: rotate(-2deg);
+ pointer-events: none;
+ z-index: 0;
+}
+:root[data-theme="renaissance"] .canvas::after {
+ content: ''; position: absolute; top: 12px; left: 16px;
+ width: 64px; height: 64px;
+ background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'><g fill='none' stroke='%238a5e1c' stroke-width='1' opacity='0.5'><circle cx='32' cy='32' r='28'/><circle cx='32' cy='32' r='22'/><path d='M32 4 L32 60 M4 32 L60 32 M11 11 L53 53 M53 11 L11 53'/><circle cx='32' cy='32' r='3' fill='%23d4a030'/></g></svg>") no-repeat center / contain;
+ pointer-events: none;
+ z-index: 0;
+}
+/* Make sure nodes/edges sit above marginalia */
+:root[data-theme="renaissance"] .canvas .node,
+:root[data-theme="renaissance"] .canvas .edge { z-index: 2; }
+
+/* Floating illuminated initial as ambient ornament */
+:root[data-theme="renaissance"] .canvas .ornament {
+ position: absolute;
+ font-family: var(--font-display);
+ color: var(--gold);
+ text-shadow: 2px 2px 0 var(--border-strong);
+ font-size: 120px;
+ font-weight: 700;
+ opacity: 0.12;
+ pointer-events: none;
+ animation: ren-flicker 6s ease-in-out infinite;
+}
+
+/* ─── BUTTONS as pressed gold foil ─── */
+:root[data-theme="renaissance"] .btn {
+ background: linear-gradient(180deg, #fbf3dc 0%, #e8c478 100%);
+ border: 1px solid var(--border-default);
+ color: var(--fg-default);
+ font-family: var(--font-display);
+ letter-spacing: 0.10em;
+ text-transform: uppercase;
+ font-size: 11px; font-weight: 600;
+ padding: 7px 14px;
+ box-shadow: 0 1px 0 #fbf3dc inset, 0 -1px 0 rgba(90, 50, 18, 0.2) inset, 0 2px 0 var(--border-strong);
+ transition: transform var(--dur-fast), box-shadow var(--dur-fast);
+}
+:root[data-theme="renaissance"] .btn:hover {
+ background: linear-gradient(180deg, var(--gold-bright), var(--gold));
+ box-shadow: 0 1px 0 #fff inset, 0 3px 0 var(--border-strong);
+}
+:root[data-theme="renaissance"] .btn:active {
+ transform: translateY(2px);
+ box-shadow: 0 1px 0 #fff inset, 0 0 0 var(--border-strong);
+}
+
+/* ─── INPUTS — ruled-line paper ─── */
+:root[data-theme="renaissance"] .input {
+ background:
+ repeating-linear-gradient(transparent, transparent 21px, rgba(138, 94, 28, 0.18) 21px, rgba(138, 94, 28, 0.18) 22px),
+ var(--bg-input);
+ border: 1px solid var(--border-default);
+ border-radius: var(--radius-sm);
+ font-family: var(--font-body);
+ font-size: 14px;
+ color: var(--fg-default);
+ padding: 6px 10px;
+}
+:root[data-theme="renaissance"] .input:focus {
+ outline: none; background: #fff;
+ box-shadow: 0 0 0 1px var(--gold), 0 0 0 2px var(--border-strong);
+}
+
+/* ─── ROWS — ink-spread on hover ─── */
+:root[data-theme="renaissance"] .row {
+ font-family: var(--font-body);
+ font-size: 15px;
+ color: var(--fg-default);
+ padding: 6px 10px;
+ position: relative;
+ background-image: linear-gradient(90deg, var(--bg-hover), var(--bg-hover));
+ background-size: 0% 100%;
+ background-repeat: no-repeat;
+ transition: background-size var(--dur-default) var(--ease-default), color var(--dur-fast);
+}
+:root[data-theme="renaissance"] .row:hover {
+ background-size: 100% 100%;
+ color: var(--crimson);
+}
+:root[data-theme="renaissance"] .row:hover::before {
+ content: '✦'; position: absolute; left: -2px; top: 50%; transform: translateY(-50%);
+ color: var(--gold); font-size: 10px;
+}
+
+/* ─── NODES as illuminated cards with red wax ─── */
+:root[data-theme="renaissance"] .node {
+ background: var(--bg-elevated);
+ border: 1.5px solid var(--border-strong);
+ border-radius: var(--radius-md);
+ font-family: var(--font-display);
+ font-size: 11px;
+ letter-spacing: 0.08em;
+ text-transform: uppercase;
+ color: var(--fg-default);
+ padding: 10px 14px;
+ box-shadow:
+ 0 0 0 1px var(--gold) inset,
+ 0 0 0 3px var(--bg-elevated) inset,
+ 0 0 0 4px var(--border-strong) inset,
+ 0 4px 0 var(--border-strong),
+ 0 6px 12px rgba(58, 32, 8, 0.25);
+ position: relative;
+ transition: transform var(--dur-default) var(--ease-emphasis);
+}
+:root[data-theme="renaissance"] .node:hover {
+ transform: translateY(-2px);
+ box-shadow:
+ 0 0 0 1px var(--gold-bright) inset,
+ 0 0 0 3px var(--bg-elevated) inset,
+ 0 0 0 4px var(--border-strong) inset,
+ 0 6px 0 var(--border-strong),
+ 0 10px 20px rgba(58, 32, 8, 0.35);
+}
+/* Wax seal corner */
+:root[data-theme="renaissance"] .node::after {
+ content: ''; position: absolute; top: -6px; right: -6px;
+ width: 16px; height: 16px;
+ background: radial-gradient(circle at 35% 30%, #c4202a, #5a0a08);
+ border-radius: 50%;
+ box-shadow: 0 1px 2px rgba(0,0,0,0.4);
+}
+
+/* ─── SQUARE NODES — guild emblems ─── */
+:root[data-theme="renaissance"] .sq-node-box {
+ background: linear-gradient(180deg, var(--bg-elevated), #d4b078);
+ border: 2px solid var(--border-strong);
+ border-radius: 4px;
+ box-shadow: 0 3px 0 var(--border-strong), inset 0 0 0 1px var(--gold);
+ color: var(--crimson);
+}
+:root[data-theme="renaissance"] .sq-node.selected .sq-node-box {
+ border-color: var(--gold);
+ box-shadow: 0 0 0 3px rgba(212, 160, 48, 0.5), 0 3px 0 var(--border-strong), inset 0 0 0 1px var(--gold);
+}
+:root[data-theme="renaissance"] .sq-node-pip {
+ border: 1px solid var(--border-strong);
+ box-shadow: 0 0 4px currentColor;
+}
+:root[data-theme="renaissance"] .sq-node-gear {
+ background: var(--gold);
+ color: var(--border-strong);
+ border: 1px solid var(--border-strong);
+ font-size: 10px;
+}
+:root[data-theme="renaissance"] .sq-node-handle.out { background: var(--crimson); }
+:root[data-theme="renaissance"] .sq-node-label {
+ color: var(--fg-default);
+ letter-spacing: 0.08em;
+ font-weight: 600;
+}
+
+/* ─── CATEGORY (palette) — illuminated section ─── */
+:root[data-theme="renaissance"] .cat {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+ border-radius: 2px;
+}
+:root[data-theme="renaissance"] .cat-head {
+ border-bottom: 1px solid var(--border-default);
+ background: linear-gradient(180deg, transparent, rgba(212, 160, 48, 0.08));
+}
+:root[data-theme="renaissance"] .cat-tile {
+ background: var(--gold);
+ border: 1px solid var(--border-strong);
+ color: var(--border-strong);
+}
+:root[data-theme="renaissance"] .cat-name {
+ font-family: var(--font-display);
+ letter-spacing: 0.10em;
+ text-transform: uppercase;
+ color: var(--crimson);
+}
+:root[data-theme="renaissance"] .cat-count {
+ background: var(--bg-active);
+ color: var(--fg-muted);
+ border: 1px solid var(--border-default);
+}
+
+/* ─── COMP ITEMS — entry cards ─── */
+:root[data-theme="renaissance"] .comp {
+ background: var(--bg-panel);
+ border: 1px solid var(--border-default);
+ border-radius: 2px;
+}
+:root[data-theme="renaissance"] .comp:hover {
+ background: var(--bg-hover);
+ border-color: var(--gold);
+}
+:root[data-theme="renaissance"] .comp-ico {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+ color: var(--crimson);
+}
+:root[data-theme="renaissance"] .comp-name {
+ font-family: var(--font-display);
+ font-weight: 600;
+ letter-spacing: 0.04em;
+}
+:root[data-theme="renaissance"] .comp-desc {
+ font-style: italic;
+ color: var(--fg-muted);
+}
+
+/* ─── MENU POP — parchment dropdown ─── */
+:root[data-theme="renaissance"] .menu-pop {
+ background: var(--bg-elevated);
+ border: 2px solid var(--border-strong);
+ box-shadow: inset 0 0 0 1px var(--gold), 0 8px 24px rgba(58,32,8,0.4);
+}
+:root[data-theme="renaissance"] .menu-pop-item {
+ font-family: var(--font-body);
+ font-size: 13px;
+}
+:root[data-theme="renaissance"] .menu-pop-item:hover {
+ background: var(--bg-hover);
+ color: var(--crimson);
+}
+
+/* ─── SETTINGS SECTIONS ─── */
+:root[data-theme="renaissance"] .settings-section {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+}
+:root[data-theme="renaissance"] .settings-section h3 {
+ color: var(--crimson);
+ font-family: var(--font-display);
+ border-bottom: 1px solid var(--gold);
+ padding-bottom: 8px;
+ letter-spacing: 0.06em;
+}
+:root[data-theme="renaissance"] .settings-summary {
+ background: var(--bg-panel);
+ border: 1px dashed var(--border-default);
+ font-family: var(--font-mono);
+ font-style: italic;
+}
+
+/* ─── CRED CARDS ─── */
+:root[data-theme="renaissance"] .cred-card {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+ border-radius: 2px;
+}
+:root[data-theme="renaissance"] .cred-card-head {
+ background: linear-gradient(180deg, transparent, rgba(212, 160, 48, 0.10));
+ border-bottom: 1px solid var(--border-default);
+}
+:root[data-theme="renaissance"] .cred-card .name {
+ font-family: var(--font-display);
+ letter-spacing: 0.08em;
+ text-transform: uppercase;
+ font-size: 12px;
+}
+:root[data-theme="renaissance"] .cred-tag {
+ font-family: var(--font-display);
+ letter-spacing: 0.08em;
+ font-size: 9px;
+}
+:root[data-theme="renaissance"] .cred-card-desc { font-style: italic; }
+
+/* Credential rows — sealed entries */
+:root[data-theme="renaissance"] .cred-row {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+ position: relative;
+}
+:root[data-theme="renaissance"] .cred-row::before {
+ content: '✦'; color: var(--gold); margin-right: 4px;
+}
+:root[data-theme="renaissance"] .cred-row .name {
+ font-family: var(--font-display);
+ font-size: 12px;
+ letter-spacing: 0.10em;
+}
+:root[data-theme="renaissance"] .cred-row .badge {
+ font-family: var(--font-display);
+ letter-spacing: 0.10em;
+ font-size: 9px;
+ padding: 3px 8px;
+}
+
+/* ─── PARAMETER PANEL COLS ─── */
+:root[data-theme="renaissance"] .param-col {
+ background: var(--bg-elevated);
+ border-right: 2px double var(--border-strong);
+}
+:root[data-theme="renaissance"] .param-col-head {
+ background: linear-gradient(180deg, transparent, rgba(212, 160, 48, 0.10));
+ border-bottom: 1px solid var(--gold);
+ font-family: var(--font-display);
+ color: var(--crimson);
+ letter-spacing: 0.10em;
+ text-transform: uppercase;
+}
+:root[data-theme="renaissance"] .json-block {
+ background: var(--bg-panel);
+ border: 1px solid var(--border-default);
+ font-family: var(--font-mono);
+ color: var(--fg-default);
+}
+:root[data-theme="renaissance"] .json-key { color: var(--crimson); font-style: italic; }
+:root[data-theme="renaissance"] .json-str { color: hsl(var(--success)); }
+:root[data-theme="renaissance"] .json-num { color: var(--gold-bright); }
+
+/* ─── CHAT TABS ─── */
+:root[data-theme="renaissance"] .chat-tab {
+ font-family: var(--font-display);
+ letter-spacing: 0.08em;
+ text-transform: uppercase;
+ font-size: 10px;
+}
+:root[data-theme="renaissance"] .chat-tab.active {
+ background: var(--gold);
+ color: var(--border-strong);
+}
+
+/* ─── CHAT MESSAGES — letter-style ─── */
+:root[data-theme="renaissance"] .chat-msg {
+ font-family: var(--font-body);
+ font-size: 14px;
+ border-radius: var(--radius-sm);
+}
+:root[data-theme="renaissance"] .chat-msg-user {
+ background: linear-gradient(180deg, var(--gold-bright), var(--gold));
+ color: var(--fg-default);
+ border: 1px solid var(--border-strong);
+}
+:root[data-theme="renaissance"] .chat-msg-bot {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-default);
+ position: relative;
+}
+:root[data-theme="renaissance"] .chat-msg-bot::before {
+ content: '✦'; color: var(--gold); margin-right: 6px;
+}
+
+/* ─── THEME SWITCHER chrome ─── */
+:root[data-theme="renaissance"] .theme-switcher {
+ background: linear-gradient(180deg, var(--bg-elevated), #e8c478);
+ border: 1.5px solid var(--border-strong);
+ box-shadow: 0 0 0 1px var(--gold) inset, 0 6px 16px rgba(58, 32, 8, 0.4);
+}
+
+/* ─── EMPTY STATE drop cap ─── */
+:root[data-theme="renaissance"] .empty-state .glyph {
+ font-family: var(--font-display);
+ font-size: 96px;
+ color: var(--gold);
+ text-shadow: 3px 3px 0 var(--border-strong);
+ font-weight: 700;
+}
+
+/* ─── STATUS BAR — illuminated footer rule ─── */
+:root[data-theme="renaissance"] .statusbar {
+ background: linear-gradient(180deg, var(--bg-panel), #d4b078);
+ border-top: 2px double var(--border-strong);
+ font-family: var(--font-mono);
+ color: var(--fg-muted);
+ font-style: italic;
+}
+:root[data-theme="renaissance"] .statusbar .pip {
+ background: hsl(var(--success));
+ box-shadow: 0 0 6px hsl(var(--success)), 0 0 0 1px var(--border-strong);
+}
+
+/* ─── MODAL — illuminated codex page ─── */
+:root[data-theme="renaissance"] .modal {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence baseFrequency='0.85' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.36 0 0 0 0 0.23 0 0 0 0 0.05 0 0 0 0.06 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>"),
+ var(--bg-elevated);
+ border: 2px solid var(--border-strong);
+ box-shadow:
+ inset 0 0 0 1px var(--gold),
+ inset 0 0 0 5px var(--bg-elevated),
+ inset 0 0 0 6px var(--gold),
+ 0 30px 80px rgba(58, 32, 8, 0.6);
+ padding: 8px;
+}
+:root[data-theme="renaissance"] .modal-head {
+ border-bottom: 2px double var(--border-strong);
+ padding: 16px 20px 14px;
+}
+:root[data-theme="renaissance"] .modal-title {
+ color: var(--fg-default);
+ font-family: var(--font-display);
+}
+:root[data-theme="renaissance"] .modal-foot {
+ border-top: 2px double var(--border-strong);
+}
+:root[data-theme="renaissance"] .field label {
+ color: #8a5e1c;
+}
+
+/* ─── COMMAND PALETTE — open scroll ─── */
+:root[data-theme="renaissance"] .cmdk {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence baseFrequency='0.85' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.36 0 0 0 0 0.23 0 0 0 0 0.05 0 0 0 0.06 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>"),
+ var(--bg-elevated);
+ border: 2px solid var(--border-strong);
+ box-shadow: inset 0 0 0 1px var(--gold), 0 30px 60px rgba(58, 32, 8, 0.5);
+}
+:root[data-theme="renaissance"] .cmdk input {
+ font-family: var(--font-display);
+ font-size: 14px;
+ letter-spacing: 0.06em;
+ border-bottom: 2px double var(--border-strong);
+ background: transparent;
+ color: var(--fg-default);
+}
+:root[data-theme="renaissance"] .cmdk-item {
+ font-family: var(--font-body);
+ font-size: 14px;
+}
+:root[data-theme="renaissance"] .cmdk-item.active {
+ background: linear-gradient(90deg, transparent, var(--bg-hover), transparent);
+ color: var(--crimson);
+}
+:root[data-theme="renaissance"] .cmdk-item.active::before {
+ content: '✦'; color: var(--gold); margin-right: 6px;
+}
+:root[data-theme="renaissance"] .cmdk-item kbd {
+ background: var(--bg-active);
+ border: 1px solid var(--border-default);
+ font-family: var(--font-mono);
+}
diff --git a/client/src/themes/rot.css b/client/src/themes/rot.css
index fc9030b1..aa727b9c 100644
--- a/client/src/themes/rot.css
+++ b/client/src/themes/rot.css
@@ -132,3 +132,93 @@
background: rgba(120, 200, 120, 0.4);
color: #14181a;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+:root[data-theme="rot"] .toolbar,
+:root[data-theme="rot"] .sidebar,
+:root[data-theme="rot"] .palette,
+:root[data-theme="rot"] .chat {
+ background:
+ linear-gradient(180deg, rgba(120,200,120,0.02), transparent),
+ var(--bg-panel);
+}
+:root[data-theme="rot"] .toolbar { border-bottom: 1px solid var(--border-strong); }
+:root[data-theme="rot"] .sidebar { border-right: 1px solid var(--border-strong); }
+:root[data-theme="rot"] .palette { border-left: 1px solid var(--border-strong); }
+:root[data-theme="rot"] .chat { border-top: 1px solid var(--border-strong); }
+
+/* CANVAS — flagstone crypt floor, candlelight pools */
+:root[data-theme="rot"] .canvas {
+ background:
+ radial-gradient(circle 200px at 25% 30%, rgba(232,168,56,0.06), transparent 70%),
+ radial-gradient(circle 180px at 78% 65%, rgba(232,168,56,0.05), transparent 70%),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='80' height='80'><g stroke='%234a6a4a' stroke-width='0.4' fill='none' opacity='0.25'><path d='M0 30 H80 M30 0 V80 M0 60 H80 M60 0 V80'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* TYPOGRAPHY — gothic */
+:root[data-theme="rot"] body { font-family: var(--font-body); color: var(--fg-default); font-size: 14px; line-height: 1.55; }
+:root[data-theme="rot"] h1, :root[data-theme="rot"] h2, :root[data-theme="rot"] h3,
+:root[data-theme="rot"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.04em; color: var(--bone); font-weight: 400;
+}
+
+/* SQUARE NODE — bone-pale tombstone */
+:root[data-theme="rot"] .sq-node-box {
+ background: linear-gradient(180deg, var(--bone), #a8a088);
+ border: 1px solid #2a2418; border-radius: 4px 4px 2px 2px;
+ box-shadow: inset 0 -2px 0 rgba(0,0,0,0.2), 0 4px 8px rgba(0,0,0,0.5);
+ color: var(--crypt);
+}
+:root[data-theme="rot"] .sq-node.selected .sq-node-box {
+ border-color: hsl(var(--accent)); box-shadow: 0 0 16px rgba(120,200,120,0.4), 0 4px 8px rgba(0,0,0,0.5);
+}
+:root[data-theme="rot"] .sq-node-gear { background: var(--crypt); color: var(--bone); border: none; }
+:root[data-theme="rot"] .sq-node-label { font-family: var(--font-display); color: var(--crypt); font-weight: 400; }
+:root[data-theme="rot"] .sq-node-handle.out { background: hsl(var(--accent)); box-shadow: 0 0 6px hsl(var(--accent)); }
+
+/* ACTIONS — guttering candleflame */
+:root[data-theme="rot"] .action-btn {
+ font-family: var(--font-display); font-size: 13px; letter-spacing: 0.04em; font-weight: 400;
+ border-radius: 2px; border-width: 1px;
+}
+:root[data-theme="rot"] .action-run { background: hsl(var(--success-soft)); color: hsl(var(--accent)); border-color: hsl(var(--success)); }
+:root[data-theme="rot"] .action-deploy { background: hsl(var(--info-soft)); color: hsl(var(--info)); border-color: hsl(var(--info)); }
+:root[data-theme="rot"] .action-save { background: hsl(var(--warning-soft)); color: var(--candle); border-color: var(--candle); }
+
+/* CARDS */
+:root[data-theme="rot"] .wf-card,
+:root[data-theme="rot"] .cat,
+:root[data-theme="rot"] .comp,
+:root[data-theme="rot"] .settings-section,
+:root[data-theme="rot"] .cred-card {
+ background: var(--bg-elevated); border: 1px solid var(--border-default); border-radius: 2px;
+}
+:root[data-theme="rot"] .wf-card.selected { border-color: hsl(var(--accent)); background: hsl(var(--success-soft)); }
+:root[data-theme="rot"] .cat-tile { background: var(--crypt); color: var(--bone); border: 1px solid var(--border-strong); }
+:root[data-theme="rot"] .cat-name { font-family: var(--font-display); color: var(--bone); font-weight: 400; }
+:root[data-theme="rot"] .comp-ico { background: var(--bg-panel); color: hsl(var(--accent)); border: 1px solid var(--border-strong); }
+
+/* CHAT */
+:root[data-theme="rot"] .chat-msg-user { background: hsl(var(--success-soft)); border: 1px solid hsl(var(--accent)); }
+:root[data-theme="rot"] .chat-msg-bot { background: var(--bg-elevated); border-left: 2px solid var(--candle); }
+
+/* STATUS BAR */
+:root[data-theme="rot"] .statusbar {
+ background: var(--bg-panel); border-top: 1px solid var(--border-strong);
+ font-family: var(--font-mono); color: var(--fg-muted);
+}
+:root[data-theme="rot"] .statusbar .pip { background: hsl(var(--accent)); box-shadow: 0 0 6px hsl(var(--accent)); }
+
+/* MODAL */
+:root[data-theme="rot"] .modal {
+ background: var(--bg-elevated); border: 1px solid var(--border-strong); border-radius: 4px;
+ box-shadow: 0 0 0 1px rgba(120,200,120,0.10), 0 30px 80px rgba(0,0,0,0.8);
+}
+:root[data-theme="rot"] .modal-head { border-bottom: 1px solid var(--border-default); }
+:root[data-theme="rot"] .modal-title { font-family: var(--font-display); color: var(--bone); font-weight: 400; }
+
+/* CMDK */
+:root[data-theme="rot"] .cmdk { background: var(--bg-elevated); border: 1px solid var(--border-strong); border-radius: 4px; }
+:root[data-theme="rot"] .cmdk-item.active { background: var(--bg-active); color: hsl(var(--accent)); }
diff --git a/client/src/themes/steampunk.css b/client/src/themes/steampunk.css
index 1eb9e313..1f4623b4 100644
--- a/client/src/themes/steampunk.css
+++ b/client/src/themes/steampunk.css
@@ -131,3 +131,116 @@
background: rgba(216, 168, 72, 0.5);
color: #2a1f12;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─────────────── */
+
+:root[data-theme="steampunk"] .toolbar,
+:root[data-theme="steampunk"] .sidebar,
+:root[data-theme="steampunk"] .palette,
+:root[data-theme="steampunk"] .chat {
+ background:
+ linear-gradient(180deg, rgba(216,168,72,0.04), transparent 30%, rgba(0,0,0,0.2)),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='l'><feTurbulence baseFrequency='0.7' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.20 0 0 0 0 0.13 0 0 0 0 0.06 0 0 0 0.5 0'/></filter><rect width='200' height='200' filter='url(%23l)'/></svg>"),
+ var(--bg-panel);
+}
+/* Riveted edges */
+:root[data-theme="steampunk"] .toolbar {
+ border-bottom: 4px ridge var(--border-strong);
+ box-shadow: inset 0 -3px 0 var(--copper);
+}
+:root[data-theme="steampunk"] .sidebar { border-right: 3px solid var(--border-strong); }
+:root[data-theme="steampunk"] .palette { border-left: 3px solid var(--border-strong); }
+:root[data-theme="steampunk"] .chat { border-top: 3px solid var(--border-strong); }
+
+/* Canvas — engine-room floor with bolt pattern */
+:root[data-theme="steampunk"] .canvas {
+ background:
+ radial-gradient(circle at 20% 20%, var(--copper) 0%, transparent 1.5%),
+ radial-gradient(circle at 80% 30%, var(--copper) 0%, transparent 1.5%),
+ radial-gradient(circle at 30% 80%, var(--copper) 0%, transparent 1.5%),
+ radial-gradient(circle at 90% 90%, var(--copper) 0%, transparent 1.5%),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='80' height='80'><g fill='%23b88838' opacity='0.10'><circle cx='40' cy='40' r='1.5'/><circle cx='10' cy='10' r='1'/><circle cx='70' cy='70' r='1'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* Typography */
+:root[data-theme="steampunk"] body { font-family: var(--font-body); color: var(--fg-default); }
+:root[data-theme="steampunk"] h1, :root[data-theme="steampunk"] h2, :root[data-theme="steampunk"] h3,
+:root[data-theme="steampunk"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.16em; text-transform: uppercase; color: hsl(var(--accent));
+}
+
+/* Square node — riveted brass plate */
+:root[data-theme="steampunk"] .sq-node-box {
+ background: linear-gradient(180deg, hsl(var(--accent)), var(--copper));
+ border: 2px solid var(--leather); border-radius: 4px;
+ box-shadow:
+ inset 0 0 0 1px hsl(var(--accent)),
+ inset 1px 1px 2px rgba(255,220,160,0.4),
+ inset -2px -2px 4px rgba(0,0,0,0.4),
+ 0 4px 0 var(--leather);
+ color: var(--leather);
+ position: relative;
+}
+:root[data-theme="steampunk"] .sq-node-box::before,
+:root[data-theme="steampunk"] .sq-node-box::after {
+ content: ''; position: absolute; width: 4px; height: 4px; border-radius: 50%;
+ background: radial-gradient(circle, var(--copper), var(--leather));
+ box-shadow: inset 0 0 0 1px rgba(0,0,0,0.4);
+}
+:root[data-theme="steampunk"] .sq-node-box::before { top: 3px; left: 3px; }
+:root[data-theme="steampunk"] .sq-node-box::after { bottom: 3px; right: 3px; }
+:root[data-theme="steampunk"] .sq-node.selected .sq-node-box {
+ box-shadow: inset 0 0 0 2px hsl(var(--accent)), 0 0 12px hsl(var(--accent)), 0 4px 0 var(--leather);
+}
+:root[data-theme="steampunk"] .sq-node-gear { background: var(--copper); color: hsl(var(--accent)); border: 1px solid var(--leather); }
+:root[data-theme="steampunk"] .sq-node-label { font-family: var(--font-display); letter-spacing: 0.10em; color: hsl(var(--accent)); }
+
+/* Actions — engraved brass plates */
+:root[data-theme="steampunk"] .action-btn {
+ font-family: var(--font-display); letter-spacing: 0.12em; text-transform: uppercase;
+ border-radius: 2px; border-width: 2px;
+ background: linear-gradient(180deg, rgba(216,168,72,0.20), rgba(216,168,72,0.05));
+}
+:root[data-theme="steampunk"] .action-run { background: linear-gradient(180deg, rgba(106,138,58,0.4), rgba(106,138,58,0.1)); color: #c8e08a; border-color: hsl(var(--success)); }
+:root[data-theme="steampunk"] .action-deploy { color: hsl(var(--accent)); border-color: hsl(var(--accent)); }
+:root[data-theme="steampunk"] .action-save { color: hsl(var(--accent)); border-color: hsl(var(--accent)); }
+
+/* Panels */
+:root[data-theme="steampunk"] .wf-card,
+:root[data-theme="steampunk"] .cat,
+:root[data-theme="steampunk"] .comp,
+:root[data-theme="steampunk"] .settings-section,
+:root[data-theme="steampunk"] .cred-card {
+ background: var(--bg-elevated); border: 1px solid var(--copper); border-radius: 2px;
+ box-shadow: inset 0 1px 0 rgba(255,220,160,0.10);
+}
+:root[data-theme="steampunk"] .cat-tile { background: hsl(var(--accent)); color: var(--leather); border: 1px solid var(--leather); border-radius: 2px; }
+:root[data-theme="steampunk"] .cat-name { font-family: var(--font-display); color: hsl(var(--accent)); }
+
+/* Chat */
+:root[data-theme="steampunk"] .chat-msg-user { background: rgba(216,168,72,0.16); border: 1px solid hsl(var(--accent)); color: hsl(var(--accent)); }
+:root[data-theme="steampunk"] .chat-msg-bot { background: var(--bg-elevated); border: 1px solid var(--copper); }
+
+/* Status bar — gauge readout */
+:root[data-theme="steampunk"] .statusbar {
+ background: linear-gradient(180deg, var(--bg-panel), var(--leather));
+ border-top: 3px ridge var(--border-strong);
+ font-family: var(--font-mono); color: hsl(var(--accent)); letter-spacing: 0.10em;
+}
+:root[data-theme="steampunk"] .statusbar .pip { background: hsl(var(--success)); box-shadow: 0 0 4px hsl(var(--success)); }
+
+/* Modal */
+:root[data-theme="steampunk"] .modal {
+ background: linear-gradient(180deg, var(--bg-elevated), var(--bg-panel));
+ border: 4px ridge var(--border-strong); border-radius: 4px;
+ box-shadow: 0 0 0 2px var(--leather), 0 30px 80px rgba(0,0,0,0.6);
+}
+:root[data-theme="steampunk"] .modal-head { border-bottom: 3px ridge var(--copper); }
+:root[data-theme="steampunk"] .modal-title { font-family: var(--font-display); color: hsl(var(--accent)); letter-spacing: 0.14em; }
+
+/* CMDK */
+:root[data-theme="steampunk"] .cmdk {
+ background: var(--bg-elevated); border: 4px ridge var(--border-strong); border-radius: 4px;
+}
+:root[data-theme="steampunk"] .cmdk-item.active { background: var(--bg-active); color: hsl(var(--accent)); border-left: 3px solid var(--copper); }
diff --git a/client/src/themes/surveillance.css b/client/src/themes/surveillance.css
index 28ab9a8e..8a5d89eb 100644
--- a/client/src/themes/surveillance.css
+++ b/client/src/themes/surveillance.css
@@ -137,3 +137,101 @@
:root[data-theme="surveillance"] ::-webkit-scrollbar-thumb {
background: #5a5e62;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+:root[data-theme="surveillance"] .toolbar,
+:root[data-theme="surveillance"] .sidebar,
+:root[data-theme="surveillance"] .palette,
+:root[data-theme="surveillance"] .chat { background: var(--bg-panel); }
+:root[data-theme="surveillance"] .toolbar { border-bottom: 1px solid var(--border-strong); }
+:root[data-theme="surveillance"] .sidebar { border-right: 1px solid var(--border-strong); }
+:root[data-theme="surveillance"] .palette { border-left: 1px solid var(--border-strong); }
+:root[data-theme="surveillance"] .chat { border-top: 1px solid var(--border-strong); }
+
+/* CANVAS — CCTV grid + crosshair */
+:root[data-theme="surveillance"] .canvas {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='1920' height='1080'><g stroke='%23e82626' stroke-width='1' fill='none' opacity='0.18'><path d='M40 40 H120 M40 40 V120 M1880 40 H1800 M1880 40 V120 M40 1040 H120 M40 1040 V960 M1880 1040 H1800 M1880 1040 V960'/><circle cx='960' cy='540' r='40' opacity='0.2'/><path d='M960 480 V600 M900 540 H1020' opacity='0.25'/></g><text x='80' y='80' fill='%23e82626' font-family='monospace' font-size='14' opacity='0.5'>● REC</text><text x='80' y='1020' fill='%23e82626' font-family='monospace' font-size='12' opacity='0.4'>CAM-04 / 19:42:08</text></svg>"),
+ repeating-linear-gradient(0deg, transparent 0, transparent 3px, rgba(106,204,106,0.04) 3px, rgba(106,204,106,0.04) 4px),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='40'><g stroke='%23888c90' stroke-width='0.4' fill='none' opacity='0.12'><path d='M0 20 H40 M20 0 V40'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* TYPOGRAPHY */
+:root[data-theme="surveillance"] body { font-family: var(--font-body); color: var(--fg-default); font-size: 13px; }
+:root[data-theme="surveillance"] h1, :root[data-theme="surveillance"] h2, :root[data-theme="surveillance"] h3,
+:root[data-theme="surveillance"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.10em; text-transform: uppercase; color: var(--fg-default);
+}
+
+/* SQUARE NODE — case file dossier */
+:root[data-theme="surveillance"] .sq-node-box {
+ background: var(--bg-elevated);
+ border: 1px solid var(--border-strong); border-radius: 0;
+ box-shadow: none;
+ color: var(--fg-default);
+ position: relative;
+}
+:root[data-theme="surveillance"] .sq-node-box::before {
+ content: ''; position: absolute; top: 4px; right: 4px; width: 6px; height: 6px;
+ background: hsl(var(--primary)); border-radius: 50%; box-shadow: 0 0 4px hsl(var(--primary));
+ animation: surv-blink 1.4s steps(2) infinite;
+}
+@keyframes surv-blink { 50% { opacity: 0.2; } }
+:root[data-theme="surveillance"] .sq-node.selected .sq-node-box {
+ border: 1px solid hsl(var(--primary)); box-shadow: 0 0 0 1px hsl(var(--primary)), 0 0 8px rgba(232,38,38,0.4);
+}
+:root[data-theme="surveillance"] .sq-node-pip { border-radius: 0; }
+:root[data-theme="surveillance"] .sq-node-gear { background: hsl(var(--primary)); color: white; border-radius: 0; border: none; }
+:root[data-theme="surveillance"] .sq-node-handle { border-radius: 0; background: var(--phosphor); }
+:root[data-theme="surveillance"] .sq-node-handle.out { background: hsl(var(--primary)); }
+:root[data-theme="surveillance"] .sq-node-label { font-family: var(--font-display); letter-spacing: 0.10em; font-size: 10px; text-transform: uppercase; }
+
+/* ACTIONS — terminal command */
+:root[data-theme="surveillance"] .action-btn {
+ font-family: var(--font-display); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
+ border-radius: 0; border-width: 1px;
+}
+:root[data-theme="surveillance"] .action-run { background: transparent; color: var(--phosphor); border-color: var(--phosphor); }
+:root[data-theme="surveillance"] .action-deploy { background: hsl(var(--primary)); color: white; border-color: hsl(var(--primary)); }
+:root[data-theme="surveillance"] .action-save { background: transparent; color: var(--amber); border-color: var(--amber); }
+:root[data-theme="surveillance"] .action-stop { background: hsl(var(--primary)); color: white; border-color: hsl(var(--primary)); }
+
+/* CARDS */
+:root[data-theme="surveillance"] .wf-card,
+:root[data-theme="surveillance"] .cat,
+:root[data-theme="surveillance"] .comp,
+:root[data-theme="surveillance"] .settings-section,
+:root[data-theme="surveillance"] .cred-card {
+ background: var(--bg-elevated); border: 1px solid var(--border-default); border-radius: 0;
+}
+:root[data-theme="surveillance"] .wf-card.selected { border: 1px solid hsl(var(--primary)); background: hsl(var(--danger-soft)); }
+:root[data-theme="surveillance"] .cat-tile { background: hsl(var(--primary)); color: white; border-radius: 0; }
+:root[data-theme="surveillance"] .cat-name { font-family: var(--font-display); }
+:root[data-theme="surveillance"] .comp-ico { background: var(--bg-panel); color: var(--phosphor); border: 1px solid var(--border-strong); border-radius: 0; }
+
+/* CHAT */
+:root[data-theme="surveillance"] .chat-msg { border-radius: 0; }
+:root[data-theme="surveillance"] .chat-msg-user { background: var(--bg-panel); border: 1px solid hsl(var(--primary)); }
+:root[data-theme="surveillance"] .chat-msg-bot { background: var(--bg-elevated); border-left: 3px solid var(--phosphor); border-top: 1px solid var(--border-default); border-right: 1px solid var(--border-default); border-bottom: 1px solid var(--border-default); }
+
+/* STATUS BAR */
+:root[data-theme="surveillance"] .statusbar {
+ background: hsl(var(--primary)); color: white; border-top: none;
+ font-family: var(--font-mono); letter-spacing: 0.10em; text-transform: uppercase;
+}
+:root[data-theme="surveillance"] .statusbar .pip { background: white; box-shadow: 0 0 4px white; border-radius: 0; }
+
+/* MODAL */
+:root[data-theme="surveillance"] .modal {
+ background: var(--bg-elevated); border: 1px solid hsl(var(--primary)); border-radius: 0;
+ box-shadow: 0 0 0 4px rgba(232,38,38,0.08), 0 30px 80px rgba(0,0,0,0.8);
+}
+:root[data-theme="surveillance"] .modal-head { border-bottom: 1px solid hsl(var(--primary)); background: var(--bg-panel); }
+:root[data-theme="surveillance"] .modal-title { font-family: var(--font-display); color: hsl(var(--primary)); letter-spacing: 0.14em; }
+
+/* CMDK */
+:root[data-theme="surveillance"] .cmdk { background: var(--bg-elevated); border: 1px solid hsl(var(--primary)); border-radius: 0; }
+:root[data-theme="surveillance"] .cmdk-item.active { background: hsl(var(--primary)); color: white; }
+:root[data-theme="surveillance"] .cmdk-item.active::before { content: '> '; }
diff --git a/client/src/themes/wasteland.css b/client/src/themes/wasteland.css
index ec0abe54..30fa45e5 100644
--- a/client/src/themes/wasteland.css
+++ b/client/src/themes/wasteland.css
@@ -130,3 +130,96 @@
background: rgba(232, 138, 40, 0.5);
color: #1a1410;
}
+
+/* ── Per-component decorations (Wave 16 port from handoff) ─── */
+
+:root[data-theme="wasteland"] .toolbar,
+:root[data-theme="wasteland"] .sidebar,
+:root[data-theme="wasteland"] .palette,
+:root[data-theme="wasteland"] .chat {
+ background:
+ linear-gradient(180deg, transparent 60%, rgba(0,0,0,0.3)),
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='300'><filter id='r'><feTurbulence baseFrequency='0.5' numOctaves='2'/><feColorMatrix values='0 0 0 0 0.54 0 0 0 0 0.22 0 0 0 0 0.10 0 0 0 0.18 0'/></filter><rect width='300' height='300' filter='url(%23r)'/></svg>"),
+ var(--bg-panel);
+}
+:root[data-theme="wasteland"] .toolbar { border-bottom: 2px solid var(--rust); box-shadow: inset 0 -1px 0 hsl(var(--accent)); }
+:root[data-theme="wasteland"] .sidebar { border-right: 2px solid var(--rust); }
+:root[data-theme="wasteland"] .palette { border-left: 2px solid var(--rust); }
+:root[data-theme="wasteland"] .chat { border-top: 2px solid var(--rust); }
+
+/* CANVAS — cracked earth */
+:root[data-theme="wasteland"] .canvas {
+ background:
+ url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><g stroke='%23e88a28' stroke-width='0.4' fill='none' opacity='0.10'><path d='M40 10 Q60 60 30 100 Q10 140 50 180 M120 0 Q140 80 100 140 M180 30 Q160 80 190 130'/></g></svg>"),
+ var(--bg-canvas);
+}
+
+/* TYPOGRAPHY — typewritten */
+:root[data-theme="wasteland"] body { font-family: var(--font-body); color: var(--fg-default); }
+:root[data-theme="wasteland"] h1, :root[data-theme="wasteland"] h2, :root[data-theme="wasteland"] h3,
+:root[data-theme="wasteland"] .v-display {
+ font-family: var(--font-display); letter-spacing: 0.08em; text-transform: uppercase; color: hsl(var(--accent));
+}
+
+/* SQUARE NODE — scrap metal plate, hand-stenciled */
+:root[data-theme="wasteland"] .sq-node-box {
+ background:
+ linear-gradient(180deg, rgba(232,140,40,0.06), transparent),
+ var(--bg-elevated);
+ border: 2px solid var(--rust); border-radius: 0;
+ box-shadow: inset 0 0 0 1px rgba(0,0,0,0.4), 2px 2px 0 var(--rust);
+ color: hsl(var(--accent));
+ position: relative;
+}
+:root[data-theme="wasteland"] .sq-node-box::before {
+ content: ''; position: absolute; inset: 2px;
+ background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='100'><filter id='s'><feTurbulence baseFrequency='2' numOctaves='1'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.18 0'/></filter><rect width='100' height='100' filter='url(%23s)'/></svg>");
+ pointer-events: none;
+}
+:root[data-theme="wasteland"] .sq-node.selected .sq-node-box { border-color: hsl(var(--accent)); box-shadow: 0 0 0 2px hsl(var(--info-soft)), 2px 2px 0 var(--rust); }
+:root[data-theme="wasteland"] .sq-node-gear { background: var(--rust); color: hsl(var(--accent)); border: 1px solid hsl(var(--accent)); border-radius: 0; }
+:root[data-theme="wasteland"] .sq-node-handle.out { background: hsl(var(--accent)); }
+:root[data-theme="wasteland"] .sq-node-label { font-family: var(--font-display); letter-spacing: 0.10em; }
+
+/* ACTIONS — stenciled */
+:root[data-theme="wasteland"] .action-btn {
+ font-family: var(--font-display); letter-spacing: 0.10em; text-transform: uppercase;
+ border-radius: 0; border-width: 2px; border-style: dashed;
+}
+:root[data-theme="wasteland"] .action-run { background: hsl(var(--success-soft)); color: hsl(var(--success)); border-color: hsl(var(--success)); border-style: solid; }
+:root[data-theme="wasteland"] .action-deploy { background: hsl(var(--info-soft)); color: hsl(var(--accent)); border-color: hsl(var(--accent)); border-style: solid; }
+:root[data-theme="wasteland"] .action-save { background: hsl(var(--warning-soft)); color: hsl(var(--warning)); border-color: hsl(var(--warning)); border-style: solid; }
+:root[data-theme="wasteland"] .action-stop { background: hsl(var(--danger-soft)); color: hsl(var(--danger)); border-color: hsl(var(--danger)); border-style: solid; }
+
+/* CARDS */
+:root[data-theme="wasteland"] .wf-card,
+:root[data-theme="wasteland"] .cat,
+:root[data-theme="wasteland"] .comp,
+:root[data-theme="wasteland"] .settings-section,
+:root[data-theme="wasteland"] .cred-card {
+ background: var(--bg-elevated); border: 1px solid var(--rust); border-radius: 0;
+}
+:root[data-theme="wasteland"] .wf-card.selected { border-color: hsl(var(--accent)); box-shadow: inset 3px 0 0 hsl(var(--accent)); }
+:root[data-theme="wasteland"] .cat-tile { background: var(--rust); color: hsl(var(--accent)); border-radius: 0; }
+:root[data-theme="wasteland"] .comp-ico { background: var(--bg-input); color: hsl(var(--accent)); border: 1px solid var(--rust); border-radius: 0; }
+
+/* CHAT */
+:root[data-theme="wasteland"] .chat-msg { border-radius: 0; }
+:root[data-theme="wasteland"] .chat-msg-user { background: hsl(var(--info-soft)); border: 1px solid hsl(var(--accent)); }
+:root[data-theme="wasteland"] .chat-msg-bot { background: var(--bg-elevated); border: 1px solid var(--rust); }
+
+/* STATUS BAR */
+:root[data-theme="wasteland"] .statusbar {
+ background: var(--bg-input); color: hsl(var(--accent)); border-top: 2px dashed var(--rust);
+ font-family: var(--font-mono); letter-spacing: 0.10em;
+}
+:root[data-theme="wasteland"] .statusbar .pip { background: var(--rad); box-shadow: 0 0 6px var(--rad); border-radius: 0; }
+
+/* MODAL */
+:root[data-theme="wasteland"] .modal { background: var(--bg-elevated); border: 3px solid hsl(var(--accent)); border-radius: 0; box-shadow: 6px 6px 0 var(--rust); }
+:root[data-theme="wasteland"] .modal-head { border-bottom: 2px dashed var(--rust); background: var(--bg-panel); }
+:root[data-theme="wasteland"] .modal-title { font-family: var(--font-display); color: hsl(var(--accent)); letter-spacing: 0.12em; }
+
+/* CMDK */
+:root[data-theme="wasteland"] .cmdk { background: var(--bg-elevated); border: 3px solid hsl(var(--accent)); border-radius: 0; }
+:root[data-theme="wasteland"] .cmdk-item.active { background: var(--bg-active); color: hsl(var(--accent)); border-left: 3px solid var(--rust); }
diff --git a/docs-internal/theme_system.md b/docs-internal/theme_system.md
index 9d374fa4..8202ac14 100644
--- a/docs-internal/theme_system.md
+++ b/docs-internal/theme_system.md
@@ -217,23 +217,78 @@ Result by theme (display font / tracking / case):
## What's done vs deferred
### Done
-- **Token contract**: all 10 themes ported in [client/src/themes/](../client/src/themes) (5 utopian + 5 dystopian)
+- **Token contract**: all 10 themes ported in [client/src/themes/](../client/src/themes) (5 utopian + 5 dystopian). 13 CSS files, 3,749 LOC total.
- **ThemeProvider** ([client/src/contexts/ThemeContext.tsx](../client/src/contexts/ThemeContext.tsx)) — 10-way `ThemeName`, `DARK_FAMILY` ⊃ `{dark, cyber, wasteland, rot, surveillance, steampunk}`, legacy `darkMode` localStorage migration on first load
- **ThemeSwitcher** — DropdownMenu grouped into System / Utopian / Dystopian sections, all 10 themes
- **Tailwind v4 `@theme inline`** exposing new-contract utilities (`bg-bg-app`, `text-fg-default`, `border-border-default`, `font-display`, `font-body`, `rounded-pill`)
-- **Decorative wrappers** — Dashboard root carries `app-frame`, the React Flow host carries `canvas-host`, every Modal carries `modal-frame`. Per-theme CSS targets these classes for outer ornaments (gilded corners, scanlines, riveted borders, REC dot, etc.)
+- **Decorative wrappers** — Dashboard root carries `app-frame`, the React Flow host carries `canvas-host` (aliased as `canvas` so handoff selectors resolve), every Modal carries `modal-frame`. Per-theme CSS targets these classes for outer ornaments (gilded corners, scanlines, riveted borders, REC dot, etc.)
+- **Per-component structural classNames** (W15) — every chrome / interactive / canvas component carries the handoff selector co-class so per-theme decorative rules resolve without component-level branching. See [Per-component decorations](#per-component-decorations) for the full list.
+- **Per-theme decorative CSS** (W16) — every per-component rule from `design_handoff_machinaos_themes/themes/*.css` is now ported into `client/src/themes/<theme>.css`. Each theme owns its panel textures, canvas decorations, node pseudo-element overlays, and keyframes. CSS bundle: 145 KB → 244 KB (+99 KB).
+- **Selection state** (W17, shipped as part of W15) — every canvas node component carries the `selected` co-class when React Flow's `selected` prop is true, activating per-theme selection effects (cyber-blink on Cyber sq-nodes, hanko seal on Edo sq-nodes, etc.).
+- **Sound event wiring** (W18) — 9 events (`click`, `hover`, `type`, `success`, `error`, `run`, `save`, `modalOpen`, `modalClose`) fire automatically across the React tree. See [Sound system → Event wiring](#event-wiring-w18).
+- **Reduced-motion accessibility** (W19) — `@media (prefers-reduced-motion: reduce)` block in [client/src/themes/base.css](../client/src/themes/base.css) disables every keyframe across all themes. See [Reduced motion](#reduced-motion).
+- **Sound throttling** (W19) — `type` and `hover` events throttled to a 30 ms last-fire window inside the engine to prevent OscillatorNode flooding. See [Throttling](#throttling).
- **Migrated chrome**: TopToolbar, WorkflowSidebar, ComponentPalette + ComponentItem + CollapsibleSection, ConsolePanel chrome, SettingsPanel, Modal, ParameterPanel modal title, AIResultModal title, OutputDisplayPanel title, InputSection title
- **New shell components**: StatusBar (fixed-bottom system line with WS connection / workflow / theme / clock), CommandPalette (`⌘K`), CommandPaletteHost (canonical command list with Workflow / Run / Open / View / Theme groups)
- **Google Fonts** — deferred-load `<link>` covers all 10 themes' typefaces (Cinzel, Cormorant Garamond, IM Fell English / SC, JetBrains Mono, Major Mono Display, VT323, Shippori Mincho, Sawarabi Mincho, Special Elite, Bevan, Lato, Pirata One, EB Garamond, UnifrakturCook, Anonymous Pro, IBM Plex Mono, Courier Prime, Space Mono)
-- **Sound contract** — [client/src/lib/sound.ts](../client/src/lib/sound.ts) ports the upstream WebAudio engine with all 10 packs (`parchment`, `marble`, `ink`, `clockwork`, `vibraphone`, `terminal`, `scrap`, `crypt`, `bell`, `telex`). [client/src/hooks/useSound.ts](../client/src/hooks/useSound.ts) reads `--sound-pack` from `:root` on theme change and mirrors the `soundEnabled` Zustand slice into `Sounds.setEnabled()`. ActionButton fires `play('click')` from its onClick wrapper, Modal fires `play('modalOpen' | 'modalClose')` on the `isOpen` transition. Settings panel ships the toggle (Audio section). Persists to `localStorage['machinaos-sound']`; default off (opt-in).
+- **Sound contract** — [client/src/lib/sound.ts](../client/src/lib/sound.ts) ports the upstream WebAudio engine with all 10 packs (`parchment`, `marble`, `ink`, `clockwork`, `vibraphone`, `terminal`, `scrap`, `crypt`, `bell`, `telex`). [client/src/hooks/useSound.ts](../client/src/hooks/useSound.ts) reads `--sound-pack` from `:root` on theme change and mirrors the `soundEnabled` Zustand slice into `Sounds.setEnabled()`. Settings panel ships the toggle (Audio section). Persists to `localStorage['machinaos-sound']`; default off (opt-in).
- **Canvas overlay packs** — [client/src/hooks/useAppTheme.ts](../client/src/hooks/useAppTheme.ts) extended from 2-way (`{light, dark}`) to 10-way: a `THEME_OVERRIDES` map applies a small overlay (primary, focus, focusRing, action colours, edge palette) on top of `lightColors` / `darkColors`. Existing call sites continue to read `theme.colors.X` and `theme.isDarkMode` unchanged; canvas selection rings, action buttons, and edge strokes pick up the active theme's accents under any of the 10 themes.
### Deferred (future PRs)
- **Per-theme icon sets** — the upstream [`app/icons.js`](../design_handoff_machinaos_themes/app/icons.js) ships 28-key glyph sets per theme (heraldic shields under Renaissance, wireframe + glow under Cyber, woodcut hatching under Plague, etc.). The current shell uses `lucide-react` icons under all themes via `currentColor`, which retints correctly via the bridge but doesn't carry per-theme glyph language. Migration recipe: build `client/src/icons/` with an `<Icon name>` component that reads the active theme via `useTheme()` and resolves to one of 10 SVG-string sets. Lucide stays as a fallback for missing keys.
-- **Per-component decorative class hooks** — the `.app-frame` / `.canvas-host` / `.modal-frame` wrappers are wired. A handful of finer-grained hooks remain (`.sq-node`, `.cat`, `.cmdk`, `.menu-pop`) — adding each to the matching React component is a one-line edit per surface and a no-op under themes that don't define decorations for it.
+- **Drop-cap `::first-letter`** — Renaissance `.v-display.drop-cap` selector ports verbatim but needs an HTML wrapper component before the rule resolves. Add a `<DisplayHeading dropCap>` primitive when next touching the chrome.
+- **Edge SVG filters** — Renaissance `.edge path { filter: url(#ink-blot) }` needs an inline `<svg><defs>` injected into the React tree.
+- **Cursor SVG reticles** — Cyber crosshair, Renaissance quill, Surveillance reticle: `cursor: url(...)` rules in per-theme CSS, low ROI.
- **Parameter panel internals** — `MiddleSection`, `MasterSkillEditor`, `ParameterRenderer` consume shadcn tokens through the bridge so they retint correctly, but their interior section headers don't yet carry the display-typography triplet. Apply the recipe (`font-display tracking-[var(--type-tracking-display)] text-fg-default [text-transform:var(--type-uppercase)]`) when next touched.
- **Credentials modal sub-panels** — `OAuthPanel`, `EmailPanel`, `ApiKeyPanel`, `QrPairingPanel` headers same pattern.
+## Per-component decorations
+
+Wave 15 added structural classNames across the React tree so the handoff CSS selectors resolve without component-level branching. Wave 16 ported the matching decorative rules from `design_handoff_machinaos_themes/themes/*.css` into `client/src/themes/<theme>.css`.
+
+### Class registry
+
+| Surface | className(s) | Component |
+|---|---|---|
+| Top toolbar | `.toolbar` | TopToolbar |
+| Sidebar | `.sidebar` | WorkflowSidebar |
+| Component palette | `.palette` | ComponentPalette |
+| Console / chat panel | `.chat`, `.chat-msg`, `.chat-msg-user`, `.chat-msg-bot` | ConsolePanel |
+| Status bar | `.statusbar`, `.pip` (connection dot) | StatusBar |
+| Modal | `.modal`, `.modal-frame`, `.modal-head` | Modal |
+| Collapsible section | `.cat`, `.cat-head`, `.cat-body` | CollapsibleSection |
+| Workflow card | `.wf-card` | WorkflowCard |
+| Palette tile | `.comp` | ComponentItem |
+| Interactive list rows | `.row` | WorkflowSidebar / ComponentItem |
+| shadcn Button | `.btn` (CVA base) | button.tsx |
+| ActionButton | `.action-btn .btn` (CVA base) | action-button.tsx |
+| Form field | `.input` | input.tsx, textarea.tsx |
+| Dropdown menu | `.menu-pop` (Content), `.menu-pop-item` (Item) | dropdown-menu.tsx |
+| Canvas host | `.canvas-host`, `.canvas` (alias) | Dashboard |
+| Generic canvas node | `.node`, `.selected` | AIAgentNode, GenericNode, TriggerNode, StartNode, ToolkitNode, TeamMonitorNode |
+| Agent node variant | `.node-agent` | AIAgentNode |
+| Trigger node variant | `.node-trigger` | TriggerNode |
+| Square canvas node | `.sq-node`, `.sq-node-box`, `.sq-node-pip`, `.sq-node-gear`, `.sq-node-handle.in`, `.sq-node-handle.out`, `.selected` | SquareNode |
+
+The `.selected` co-class is bound to React Flow's `selected` prop on every canvas node component, activating per-theme selection effects (Cyber `cyber-blink`, Edo hanko seal, Renaissance wax-seal stamp, etc.).
+
+### Decorative content per theme
+
+| Theme | Panel textures | Canvas decoration | Node pseudo overlay | Keyframes |
+|---|---|---|---|---|
+| renaissance | parchment + vellum noise | fleur-de-lis vignette + marginalia | wax seal (`.node::after`) | `ren-flicker` |
+| greek | marble veins | meander pattern | stelae shape | — |
+| edo | washi texture | ink-wash mountain (radial gradient) | hanko seal (`.sq-node.selected::before`) | — |
+| steampunk | leather grain | brass bolt grid | brass rivets (`.sq-node-box::before/::after`) | — |
+| atomic | flat solid | starburst + grid lines | boomerang corners | — |
+| cyber | neon glow grain | perspective grid + scanlines + status text | corner LED blink | `cyber-flicker`, `cyber-roll`, `cyber-blink`, `cyber-glitch` |
+| wasteland | dust + grain | cracked earth (SVG) | scrap noise (`.sq-node-box::before`) | — |
+| rot | gradient | flagstone + candlelight pools | bone gradient | — |
+| plague | parchment | red X pattern (SVG) | nailed nail (`.sq-node-box::after`) | — |
+| surveillance | solid | CCTV crosshair + REC label + phosphor scanlines | REC LED blink (`.sq-node-box::before`) | `surv-blink` |
+
+`var(--accent)` etc. handoff reads were wrapped to `hsl(var(--accent))` for shadcn-bridged tokens; theme-specific spot colours (`--gold`, `--crimson`, `--neon-magenta`, `--rec-red`) port verbatim as hex.
+
## Sound system
Each theme declares `--sound-pack: "<pack>"` in its `:root[data-theme="..."]` block. Pack names map to event tables in [client/src/lib/sound.ts](../client/src/lib/sound.ts):
@@ -252,14 +307,57 @@ Each theme declares `--sound-pack: "<pack>"` in its `:root[data-theme="..."]` bl
| surveillance | `telex` | Typewriter clack + Geiger tick |
| light / dark | (system fallback `parchment`/`terminal` if requested) | — |
-Wiring:
-1. Mount `useSoundSync()` once at the Dashboard root — done in [client/src/Dashboard.tsx](../client/src/Dashboard.tsx).
-2. Every `<ActionButton>` fires `play('click')` on click via the CVA primitive — call sites don't need to wrap.
-3. `<Modal>` fires `play('modalOpen' | 'modalClose')` on `isOpen` edges.
-4. Settings panel ships an Audio section with a Switch bound to `useAppStore.soundEnabled`.
+### Event wiring (W18)
+
+9 events fire automatically across the React tree — call sites do not need to wrap:
+
+| Event | Surface | File |
+|---|---|---|
+| `click` | shadcn Button onClick | [button.tsx](../client/src/components/ui/button.tsx) |
+| `click` | ActionButton (CVA primitive) | [action-button.tsx](../client/src/components/ui/action-button.tsx) |
+| `click` | DropdownMenuItem onSelect | [dropdown-menu.tsx](../client/src/components/ui/dropdown-menu.tsx) |
+| `click` | SelectItem onClick | [select.tsx](../client/src/components/ui/select.tsx) |
+| `hover` | Global capture-phase `mouseover` delegate matching `.btn, .action-btn, .row, .menu-pop-item, .wf-card, .comp, .cmdk-item, [data-sound-hover]` | [hooks/useSound.ts](../client/src/hooks/useSound.ts) |
+| `type` | Input onChange | [input.tsx](../client/src/components/ui/input.tsx) |
+| `type` | Textarea onChange | [textarea.tsx](../client/src/components/ui/textarea.tsx) |
+| `success` | Monkey-patched `toast.success` (sonner) — idempotent under React Strict Mode | [hooks/useSound.ts](../client/src/hooks/useSound.ts) (`patchToast()`) |
+| `error` | Monkey-patched `toast.error` (sonner) | [hooks/useSound.ts](../client/src/hooks/useSound.ts) |
+| `run` | `withSound('run', handleDeploy)` / `withSound('run', handleRun)` at TopToolbar `onDeploy` / `onRun` + CommandPaletteHost handlers | [Dashboard.tsx](../client/src/Dashboard.tsx) |
+| `save` | `withSound('save', handleSave)` at TopToolbar `onSave` + CommandPaletteHost + Ctrl/Cmd+S keyboard shortcut | [Dashboard.tsx](../client/src/Dashboard.tsx) |
+| `modalOpen` / `modalClose` | useEffect on `isOpen` edges in Modal | [Modal.tsx](../client/src/components/ui/Modal.tsx) |
+
+The hover delegate uses `mouseover` on capture phase + a `relatedTarget` filter so a hover only fires once per crossing-into-element (`mouseenter` doesn't bubble). `touchstart` is registered alongside on the same selector list for hybrid devices.
+
+`patchToast()` wraps sonner's `toast.success` / `toast.error` once at module load; the guard flag prevents Strict-Mode double-wrap. `withSound(event, handler)` is the convenience HOC exported from [useSound.ts](../client/src/hooks/useSound.ts) for `run` / `save` semantics — fires the sound, then defers to the original handler.
+
+Wiring summary:
+1. Mount `useSoundSync()` once at the Dashboard root — done in [Dashboard.tsx](../client/src/Dashboard.tsx).
+2. Settings panel ships an Audio section with a Switch bound to `useAppStore.soundEnabled`.
Adding a new sound event: extend `SoundEvent` in `lib/sound.ts`, add an entry per pack, fire `play('<event>')` from the handler.
+## Reduced motion
+
+[client/src/themes/base.css](../client/src/themes/base.css) ships a `@media (prefers-reduced-motion: reduce)` block that disables every keyframe across all themes when the user's OS-level "Reduce Motion" preference is on. Disabled animations:
+
+- `cyber-flicker`, `cyber-roll`, `cyber-blink`, `cyber-glitch` (Cyber)
+- `surv-blink` (Surveillance)
+- `ren-flicker` (Renaissance)
+- generic `.animate-pulse` (used by node execution pip)
+
+Plus any `transition` on canvas-host pseudo-elements that synthesise motion. Sounds are not motion — they remain enabled regardless. The user-facing audio toggle lives in Settings → Audio → Sound effects.
+
+Verify in Chrome DevTools → Rendering → "Emulate CSS media feature prefers-reduced-motion: reduce", or in OS settings (macOS: System Settings → Accessibility → Display → Reduce motion; Windows: Settings → Accessibility → Visual effects → Animation effects).
+
+## Throttling
+
+Two events flood under rapid input and are throttled inside the engine to prevent OscillatorNode flooding:
+
+- `type` — 30 ms last-fire window (protects against keystroke bursts)
+- `hover` — 30 ms last-fire window (protects against `mouseover` firing dozens of times during a fast cursor sweep)
+
+Implementation lives in [client/src/lib/sound.ts](../client/src/lib/sound.ts): `Sounds.play()` consults a `THROTTLE_MS` map per event name and a `lastFireMs` map keyed by event before each `OscillatorNode` schedule. Other events (`click`, `success`, `error`, `run`, `save`, `modalOpen`, `modalClose`) fire on every call.
+
## Canvas overlay packs (`useAppTheme`)
The hook returns a `theme` object with the same shape every call site already destructures — `theme.colors.X` and `theme.isDarkMode` continue to work. Under non-light/dark themes a small overlay merges into the base pack: