/* ─── Material Design Icons (SVG) ─── */
function MIcon({ name, size = 20, color = "currentColor", style = {}, ...rest }) {
  const paths = {
    // Outlined Material Design 24px paths
    schedule: <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm.5-13H11v6l5.25 3.15.75-1.23-4.5-2.67z" />,
    place: <path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z" />,
    terrain: <path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z" />,
    water_drop: <path d="M12 2.69l5.66 5.66c3.12 3.12 3.12 8.19 0 11.31-1.56 1.56-3.61 2.34-5.66 2.34s-4.1-.78-5.66-2.34c-3.12-3.12-3.12-8.19 0-11.31L12 2.69M12 0L4.93 7.07c-3.9 3.9-3.9 10.24 0 14.14 1.95 1.95 4.51 2.93 7.07 2.93s5.12-.98 7.07-2.93c3.9-3.9 3.9-10.24 0-14.14L12 0z" />,
    local_hospital: <path d="M19 3H5c-1.1 0-1.99.9-1.99 2L3 19c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-1 11h-4v4h-4v-4H6v-4h4V6h4v4h4v4z" />,
    flag: <path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z" />,
    arrow_forward: <path d="M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8z" />,
    arrow_back: <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20z" />,
    arrow_upward: <path d="M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8z" />,
    check: <path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z" />,
    close: <path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" />,
    add: <path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6z" />,
    menu: <path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z" />,
    lock: <path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zM12 17c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1s3.1 1.39 3.1 3.1v2z" />,
    info: <path d="M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z" />,
    warning: <path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z" />,
    description: <path d="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zM6 20V4h7v5h5v11H6z" />,
    family_restroom: <path d="M16 4c0-1.11.89-2 2-2s2 .89 2 2-.89 2-2 2-2-.89-2-2zm4 18v-6h2.5l-2.54-7.63A1.5 1.5 0 0 0 18.54 8h-1.08c-.8 0-1.45.55-1.62 1.27 1.13.18 2.05.95 2.43 2.01L20.21 16H20v6h-3.5v-6H15v-3.5c0-1.38-1.12-2.5-2.5-2.5h-1c-1.38 0-2.5 1.12-2.5 2.5V16H7.5v6H4v-6h-.5l1.41-4.05C5.21 11.39 4.79 11 4.34 11H3.46c-.41 0-.79.32-.97.79L0 18h2v6h18z" />,
    handshake: <path d="M16.48 10.41c-.39.39-1.04.39-1.43 0l-2.99-2.99-4.65 4.65c-.19.19-.45.29-.71.29s-.51-.1-.71-.29c-.39-.39-.39-1.02 0-1.41l5.36-5.36c.39-.39 1.02-.39 1.41 0l3.7 3.7c.4.39.4 1.02.02 1.41zm5.16 1.13l-3.36-3.36-1.06 1.06 3.34 3.36-1.86 1.86c-.39.39-.91.61-1.46.61-.55 0-1.07-.21-1.46-.61L13.65 12 8.99 16.66c-.39.39-1.02.39-1.41 0L5.39 14.46l-1.05 1.04 1.36 1.36c.39.39.39 1.04 0 1.43-.39.39-1.04.39-1.43 0l-1.41-1.42c-.78-.78-.78-2.05 0-2.83l9.2-9.19c.78-.78 2.05-.78 2.83 0l5.6 5.6c.78.78.78 2.05.01 2.84z" />,
    favorite: <path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z" />,
    payments: <path d="M2 6v12h20V6H2zm14 4c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3z" />,
    account_balance: <path d="M4 10v7h3v-7H4zm6 0v7h3v-7h-3zM2 22h19v-3H2v3zm14-12v7h3v-7h-3zm-4.5-9L2 6v2h19V6l-9.5-5z" />,
    share: <path d="M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92s2.92-1.31 2.92-2.92-1.31-2.92-2.92-2.92z" />,
    photo_camera: <path d="M9.4 10.5l4.77-8.26C13.47 2.09 12.75 2 12 2c-2.4 0-4.6.85-6.32 2.25l3.66 6.35.06-.1zM21.54 9c-.92-2.92-3.15-5.26-6-6.34L11.88 9h9.66zm.26 1h-7.49l.29.5 4.76 8.25C21 16.97 22 14.61 22 12c0-.69-.07-1.35-.2-2zM8.54 12l-3.9-6.75C3.01 7.03 2 9.39 2 12c0 .69.07 1.35.2 2h7.49l-1.15-2zm-6.08 3c.92 2.92 3.15 5.26 6 6.34L12.12 15H2.46zm11.27 0l-3.9 6.76c.7.15 1.42.24 2.17.24 2.4 0 4.6-.85 6.32-2.25l-3.66-6.35-.93 1.6z" />,
    bolt: <path d="M11 21h-1l1-7H7.5c-.58 0-.57-.32-.38-.66.19-.34.05-.08.07-.12C8.48 10.94 10.42 7.54 13 3h1l-1 7h3.5c.49 0 .56.33.47.51l-.07.15C12.96 17.55 11 21 11 21z" />,
    nature_people: <path d="M22.17 9.17C22.17 5.25 18.92 2 15 2s-7.17 3.25-7.17 7.17c0 3.55 2.66 6.5 6.08 7.04V19H6.5v-2.5h.25c.41 0 .75-.34.75-.75v-2.5c0-.41-.34-.75-.75-.75h-2.5c-.41 0-.75.34-.75.75v2.5c0 .41.34.75.75.75H4.5V19c0 1.1.9 2 2 2h7.41v1h2v-5.79c3.42-.54 6.26-3.49 6.26-7.04zM15 14.5c-3.04 0-5.5-2.46-5.5-5.5S11.96 3.5 15 3.5 20.5 6.04 20.5 9s-2.46 5.5-5.5 5.5z" />,
  };
  return (
    <svg width={size} height={size} viewBox="0 0 24 24" fill={color}
      style={{ display: "inline-block", verticalAlign: "middle", flexShrink: 0, ...style }}
      aria-hidden="true" {...rest}>
      {paths[name] || null}
    </svg>
  );
}

window.MIcon = MIcon;
