/* --- src/icons.jsx --- */
// Inline SVG icons — minimal, monoline
const Icon = ({ name, size=18, stroke=1.6, color='currentColor' }) => {
  const c = color, s = stroke;
  const props = { width:size, height:size, viewBox:'0 0 24 24', fill:'none', stroke:c, strokeWidth:s, strokeLinecap:'round', strokeLinejoin:'round' };
  switch(name){
    case 'home': return <svg {...props}><path d="M3 11l9-7 9 7"/><path d="M5 10v10h14V10"/></svg>;
    case 'grid': return <svg {...props}><rect x="3" y="3" width="7" height="7" rx="1"/><rect x="14" y="3" width="7" height="7" rx="1"/><rect x="3" y="14" width="7" height="7" rx="1"/><rect x="14" y="14" width="7" height="7" rx="1"/></svg>;
    case 'pulse': return <svg {...props}><path d="M3 12h4l2-6 4 12 2-6h6"/></svg>;
    case 'compare': return <svg {...props}><path d="M12 3v18"/><path d="M3 7h6l-3-4"/><path d="M21 17h-6l3 4"/></svg>;
    case 'layers': return <svg {...props}><path d="M12 3l9 5-9 5-9-5 9-5z"/><path d="M3 13l9 5 9-5"/><path d="M3 18l9 5 9-5"/></svg>;
    case 'doc': return <svg {...props}><path d="M14 3H6v18h12V7z"/><path d="M14 3v4h4"/><path d="M9 13h6"/><path d="M9 17h4"/></svg>;
    case 'megaphone': return <svg {...props}><path d="M3 11v2a2 2 0 002 2h2l8 4V5l-8 4H5a2 2 0 00-2 2z"/><path d="M19 8a4 4 0 010 8"/></svg>;
    case 'brain': return <svg {...props}><path d="M9 4a3 3 0 013 3v10a3 3 0 11-6 0 3 3 0 01-3-3 3 3 0 010-6 3 3 0 016 0z"/><path d="M15 4a3 3 0 00-3 3v10a3 3 0 106 0 3 3 0 003-3 3 3 0 000-6 3 3 0 00-6 0z"/></svg>;
    case 'chart': return <svg {...props}><path d="M3 3v18h18"/><path d="M7 15l4-4 3 3 5-7"/></svg>;
    case 'building': return <svg {...props}><path d="M3 21h18"/><path d="M5 21V5a2 2 0 012-2h6a2 2 0 012 2v16"/><path d="M15 9h4a2 2 0 012 2v10"/><path d="M8 7h2M8 11h2M8 15h2"/></svg>;
    case 'search': return <svg {...props}><circle cx="11" cy="11" r="7"/><path d="M20 20l-3.5-3.5"/></svg>;
    case 'bell': return <svg {...props}><path d="M6 8a6 6 0 1112 0c0 7 3 7 3 9H3c0-2 3-2 3-9z"/><path d="M10 21a2 2 0 004 0"/></svg>;
    case 'filter': return <svg {...props}><path d="M3 5h18l-7 9v6l-4-2v-4z"/></svg>;
    case 'arrow-up': return <svg {...props}><path d="M12 19V5"/><path d="M5 12l7-7 7 7"/></svg>;
    case 'arrow-down': return <svg {...props}><path d="M12 5v14"/><path d="M5 12l7 7 7-7"/></svg>;
    case 'arrow-right': return <svg {...props}><path d="M5 12h14"/><path d="M13 5l7 7-7 7"/></svg>;
    case 'check': return <svg {...props}><path d="M5 12l4 4 10-10"/></svg>;
    case 'plus': return <svg {...props}><path d="M12 5v14M5 12h14"/></svg>;
    case 'spark': return <svg {...props}><path d="M12 3v3M12 18v3M3 12h3M18 12h3M5.6 5.6l2.1 2.1M16.3 16.3l2.1 2.1M5.6 18.4l2.1-2.1M16.3 7.7l2.1-2.1"/></svg>;
    case 'shield': return <svg {...props}><path d="M12 3l8 3v6c0 5-3.5 8-8 9-4.5-1-8-4-8-9V6l8-3z"/></svg>;
    case 'flag': return <svg {...props}><path d="M5 21V4"/><path d="M5 4h12l-2 4 2 4H5"/></svg>;
    case 'download': return <svg {...props}><path d="M12 4v12"/><path d="M6 12l6 6 6-6"/><path d="M4 20h16"/></svg>;
    case 'play': return <svg {...props}><path d="M6 4l14 8-14 8z"/></svg>;
    case 'sort': return <svg {...props}><path d="M8 5v14M4 9l4-4 4 4"/><path d="M16 19V5M12 15l4 4 4-4"/></svg>;
    case 'dot': return <svg {...props}><circle cx="12" cy="12" r="4" fill={c}/></svg>;
    default: return null;
  }
};
window.Icon = Icon;


