/** * Platform detection — runs synchronously in `` before body rendering. * * Responsibilities: * - Detect macOS platform from user agent. * - Set `data-platform` on `` to enable platform-specific CSS styling. */ export function initPlatform() { if (/mac/i.test(navigator.platform)) { document.documentElement.dataset.platform = 'mac' } }