// shared.jsx — presentational primitives reused across every page. // Loaded from index.html as an ordered `text/babel` classic script (position 2 of 8). // Classic scripts share one global scope — see docs/engineering/Patterns.md §9. // ─── Shared Components ─────────────────────────────────────────────────────── const Logo = React.memo(function Logo({ light }) { return ( zensys ); }); const BUTTON_BASE_STYLE = { fontFamily: "'DM Sans', sans-serif", fontWeight: 600, border: "none", cursor: "pointer", borderRadius: 8, transition: "all 0.2s ease", display: "inline-flex", alignItems: "center", gap: 8, whiteSpace: "nowrap", }; const BUTTON_SIZES = { sm: { padding: "8px 16px", fontSize: 13 }, md: { padding: "12px 24px", fontSize: 14 }, lg: { padding: "16px 32px", fontSize: 16 }, }; const BUTTON_VARIANTS = { primary: { background: "#22c55e", color: "#000" }, secondary: { background: "transparent", color: "#fff", border: "1px solid rgba(255,255,255,0.2)", }, ghost: { background: "transparent", color: "#22c55e" }, outline: { background: "transparent", color: "#0a0a0a", border: "1px solid #ddd", }, }; const Button = React.memo(function Button({ children, variant = "primary", size = "md", style, ...props }) { return ( ); }); // Every caller gets label↔control association for free: the generated id is // wired to both halves, and an explicit `id` prop still wins for callers that // need to address the field from outside (#499). function Input({ label, id, ...props }) { const generatedId = useId(); const inputId = id || generatedId; return (